/* ===================================================================
 * Natursite - overrides for the Abstract template
 *
 * Brand palette: #ACCF51 (green), #282828 (dark), #7A7A7A (text),
 * #EFEFEF (light background), #FFFFFF.
 * ------------------------------------------------------------------- */

:root {
    --ns-green      : #ACCF51;
    --ns-green-dark : #5f7a1f;  /* AA-contrast green for text on white */
    --ns-dark       : #282828;
    --ns-text       : #7A7A7A;
    --ns-light      : #EFEFEF;

    --color-body    : #ffffff;

    --color-text-light      : #6b6b6b;
    --color-btn-primary     : var(--ns-green);
    --color-btn-primary-text: var(--ns-dark);
    --color-btn-primary-hover     : var(--ns-dark);
    --color-btn-primary-hover-text: #ffffff;
    --color-btn-hover             : var(--ns-dark);
    --color-btn-stroke-hover      : var(--ns-dark);
}

a, a:visited { color: var(--ns-green-dark); }
a:hover, a:focus, a:active { color: var(--ns-dark); }

::selection { background: var(--ns-green); color: var(--ns-dark); }

/* skip link
 * ------------------------------------------------------------------- */
.skip-link {
    position: absolute;
    left: -9999px;
    top: 0;
    z-index: 1000;
    padding: 1.2rem 2rem;
    background: var(--ns-dark);
    color: #fff;
}
.skip-link:focus { left: 1.6rem; top: 1.6rem; color: #fff; }

/* ===================================================================
 * header
 * ------------------------------------------------------------------- */
.s-header {
    background-color: #ffffff;
    background-image: none;
}

.s-header__logo img {
    width: auto;
    height: 5.6rem;
}

.s-header__nav li a,
.s-header__nav li a:visited {
    color: var(--ns-dark);
}

.s-header__nav li.current > a,
.s-header__nav li a:hover,
.s-header__nav li a:focus {
    color: var(--ns-green-dark);
}

.s-header__nav-wrap {
    display: flex;
    align-items: center;
    margin-right: 4.8rem;
}

.s-header__social {
    display: flex;
    list-style: none;
    margin: 0 0 0 2rem;
    padding: 0;
}

.s-header__social li {
    margin: 0 0 0 .8rem;
    padding: 0;
}

.s-header__social a,
.s-footer__social a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3.2rem;
    height: 3.2rem;
    border-radius: 50%;
    background-color: #000;
    transition: background-color .3s;
}

.s-header__social a:hover,
.s-header__social a:focus,
.s-footer__social a:hover,
.s-footer__social a:focus {
    background-color: var(--ns-green);
}

.s-header__social svg,
.s-footer__social svg {
    width: 1.8rem;
    height: 1.8rem;
}

.s-header__social svg path,
.s-footer__social svg path {
    fill: #fff;
    transition: fill .3s;
}

.s-header__social a:hover svg path,
.s-header__social a:focus svg path,
.s-footer__social a:hover svg path,
.s-footer__social a:focus svg path {
    fill: #000;
}

.s-header__search-trigger:hover svg path,
.s-header__search-trigger:focus svg path {
    fill: var(--ns-green-dark);
}

/* header content matches the width of the masonry content below it:
 * same container width per breakpoint + the brick side padding (--ns-edge)
 * ------------------------------------------------------------------- */
.s-header__content {
    --ns-edge: var(--gutter-lg);
    max-width: 1440px;
    width: 94%;
    padding: 0 var(--ns-edge);
}

.s-header__logo { padding-left: 0; }
.s-header__search-trigger { right: calc(var(--ns-edge) - .8rem); }
.s-header__toggle-menu    { right: calc(var(--ns-edge) - 1rem); }

@media screen and (max-width: 1440px) {
    .s-header__content { width: 98%; }
}
@media screen and (max-width: 1400px) {
    .s-header__content { --ns-edge: var(--gutter-md); max-width: var(--width-max); width: 94%; }
}
@media screen and (max-width: 980px) {
    .s-header__content { max-width: 780px; width: 96%; }
}
@media screen and (max-width: 800px) {
    .s-header__content { --ns-edge: 1.6rem; }
    .s-header__logo { padding-left: 0; }
    .s-header__search-trigger { right: calc(var(--ns-edge) + 4.4rem); }
}
@media screen and (max-width: 700px) {
    .s-header__content { --ns-edge: 1.2rem; }
}
@media screen and (max-width: 600px) {
    .s-header__content { --ns-edge: calc(6vw + var(--gutter-mob)); max-width: 480px; width: 100%; }
    .s-header__logo { padding-left: 0; }
    .s-header__search-trigger { right: calc(var(--ns-edge) + 4.4rem); }
    .s-header__toggle-menu    { right: calc(var(--ns-edge) - 1rem); }
}
@media screen and (max-width: 400px) {
    .s-header__content { --ns-edge: 6vw; }
    .s-header__logo { padding-left: 0; }
}

/* 801-980: not enough room for social icons next to the nav (they stay in the footer) */
@media screen and (min-width: 801px) and (max-width: 980px) {
    .s-header__social { display: none; }
}

/* desktop: logo + nav on a single line */
@media screen and (min-width: 1101px) {
    .s-header__content { flex-wrap: nowrap; }
    .s-header__nav li  { padding: 0 .9rem; }
    .s-header__nav     { font-size: 1.5rem; white-space: nowrap; }
}

/* small desktop / landscape tablet: nav on its own line under the logo */
@media screen and (min-width: 801px) and (max-width: 1100px) {
    .s-header {
        height: auto;
        padding: 1.6rem 0 .4rem;
    }
    .s-header__content { flex-wrap: wrap; }
    .s-header__logo img { height: 4.8rem; }
    .s-header__nav-wrap {
        flex: 0 0 100%;
        justify-content: center;
        margin: .8rem 0 0;
        padding: 0;
    }
    .s-header__nav      { font-size: 1.4rem; white-space: nowrap; }
    .s-header__nav li   { padding: 0 .7rem; }
    .s-header__nav li a { line-height: 4.4rem; }
    .s-header__social   { margin-left: 1.2rem; }
    .s-header__search-trigger { top: 1.6rem; transform: none; margin-top: .6rem; }
}

@media screen and (max-width: 800px) {
    .s-header__logo img { height: 4.8rem; }

    /* mobile overlay menu */
    .s-header__nav-wrap {
        display: block;
        margin-right: 0;
    }
    .s-header__nav {
        margin-top: 10.4rem;
    }
    .s-header__social {
        margin: 0 6rem;
    }
    .s-header__social li { margin: 0 1.2rem 0 0; }
    .s-header__toggle-menu:hover span,
    .s-header__toggle-menu:hover span::before,
    .s-header__toggle-menu:hover span::after {
        background-color: var(--ns-green-dark);
    }
}

@media screen and (max-width: 400px) {
    .s-header__social { margin: 0 3.2rem; }
}

@media screen and (max-width: 600px) {
    .s-header__logo img { height: 4.2rem; }
}

/* ===================================================================
 * featured slider
 * ------------------------------------------------------------------- */
.f-slide__background img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* dark gradient from the bottom up, behind the bottom-left text */
.f-slide__overlay {
    background: linear-gradient(to top, rgba(0, 0, 0, .85) 0%, rgba(0, 0, 0, .55) 35%, rgba(0, 0, 0, .1) 75%, rgba(0, 0, 0, 0) 100%);
}

.featured-grid .entry__content:hover .f-slide__overlay {
    background-color: rgba(0, 0, 0, 0.15);
}

/* text block: bottom-left */
.f-slide {
    align-items: flex-end;
    justify-content: flex-start;
    text-align: left;
    padding: var(--vspace-1) 4.8rem 4rem;
}

.f-slide__content {
    max-width: 64rem;
}

.f-slide__meta {
    margin: 0 0 1.2rem;
}

.f-slide__meta li {
    margin: 0 1.2rem 0 0;
}

.f-slide__title {
    margin-bottom: 0;
}

/* soften the white text edges against the photo */
.f-slide__title,
.f-slide__meta time {
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25), 0 2px 16px rgba(0, 0, 0, 0.35);
}

@media screen and (max-width: 600px) {
    .f-slide { padding: var(--vspace-1) 2.4rem 2.8rem; }
    /* template moves the arrows to the bottom corners on mobile: put them at the top instead */
    .featured-post-nav button { top: 1.2rem; bottom: auto; }
}

.f-slide__meta {
    color: rgba(255, 255, 255, 0.85);
}

.f-slide__meta a,
.f-slide__meta a:visited {
    color: #fff;
}

.f-slide__cat,
.f-slide__cat:visited {
    display: inline-block;
    padding: .2rem 1.2rem;
    border-radius: 3px;
    background-color: var(--ns-green);
    color: var(--ns-dark) !important;
    font-size: 1.3rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.f-slide__cat:hover { background-color: #fff; }

.f-slide__title a,
.f-slide__title a:visited {
    color: #fff;
}

.f-slide__title a:hover,
.f-slide__title a:focus {
    color: var(--ns-green);
}

/* slider arrows: small, white, no box */
.featured-post-nav button {
    background-color: transparent;
    border: none;
    width: 4rem;
    height: 4rem;
}

.featured-post-nav__prev { left: 1.2rem; }
.featured-post-nav__next { right: 1.2rem; }

.featured-post-nav button svg {
    width: 2.4rem;
    height: 2.4rem;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.5));
}

.featured-post-nav button svg path {
    fill: #fff;
}

.featured-post-nav button:hover,
.featured-post-nav button:focus {
    background-color: transparent;
}

.featured-post-nav button:hover svg path,
.featured-post-nav button:focus svg path {
    fill: var(--ns-green);
}

/* ===================================================================
 * section intro (h1) inside masonry
 * ------------------------------------------------------------------- */
.bricks-wrapper .intro__box {
    display: flex;
    align-items: center;
    background-color: var(--ns-dark);
    padding: 4rem 3.2rem;
    min-height: 22rem;
    position: relative;
    overflow: hidden;
    border-radius: var(--ns-radius);
}

.bricks-wrapper .intro__box::before {
    content: "";
    position: absolute;
    left: 3.2rem;
    top: 4rem;
    width: 4.8rem;
    height: 4px;
    background-color: var(--ns-green);
}

.intro__title {
    color: #fff;
    font-size: 2.8rem;
    line-height: 1.3;
    margin: 2.4rem 0 0;
}

@media screen and (max-width: 600px) {
    .bricks-wrapper .intro__box { min-height: 0; padding: 3.6rem 2.4rem 3.2rem; }
    .bricks-wrapper .intro__box::before { left: 2.4rem; top: 3.6rem; }
    .intro__title { font-size: 2.4rem; }
}

/* ===================================================================
 * post cards
 * ------------------------------------------------------------------- */
.bricks-wrapper .entry__thumb img {
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 2;
    object-fit: cover;
}

.bricks-wrapper .entry__text {
    padding: 2rem 2.8rem 2.8rem;
    border: 1px solid var(--ns-light);
    border-top: 3px solid var(--ns-green);
}

.bricks-wrapper .entry__meta {
    color: var(--color-text-light);
}

.bricks-wrapper .entry__title {
    margin-bottom: 0;
}

.bricks-wrapper .entry__title a,
.bricks-wrapper .entry__title a:visited {
    color: var(--ns-dark);
}

.bricks-wrapper .entry__title a:hover,
.bricks-wrapper .entry__title a:focus {
    color: var(--ns-green-dark);
}

/* card hover: no "..." box, just a light 20% darkening */
.bricks-wrapper .entry__thumb .thumb-link::after {
    display: none;
}

.bricks-wrapper .entry__thumb .thumb-link::before {
    background: rgba(0, 0, 0, 0.2);
}

/* ===================================================================
 * footer
 * ------------------------------------------------------------------- */
.s-footer {
    --ns-footer-bg   : #1e1e1e;
    --ns-footer-field: #2e2e2e;
    background-color: var(--ns-footer-bg);
    color: #fff;
}

.s-footer p { color: #fff; }

.s-footer__logo img {
    width: auto;
    height: 7.2rem;
}

.s-footer__social {
    display: flex;
    list-style: none;
    margin: var(--vspace-0_75) 0 0 0 !important;
}

.s-footer__social li {
    margin: 0 1rem 0 0;
}

/* dark footer: invert the social icons so they stay visible */
.s-footer__social a { background-color: #fff; }
.s-footer__social svg path { fill: #000; }
.s-footer__social a:hover,
.s-footer__social a:focus { background-color: var(--ns-green); }

.s-footer__main ul a,
.s-footer__main ul a:visited {
    color: #fff;
}

.s-footer__main ul a:hover,
.s-footer__main ul a:focus {
    color: var(--ns-green);
}

.s-footer__subscribe h2 {
    color: #fff;
    font-size: var(--text-size);
    font-weight: 600;
    margin-top: 0;
    padding-bottom: var(--vspace-0_5);
    margin-bottom: var(--vspace-0_5);
    border-bottom: 3px solid var(--ns-green);
    display: inline-block;
}

.s-footer__subscribe p {
    margin-bottom: var(--vspace-0_75);
}

.s-footer__subscribe strong {
    color: #fff;
}

.newsletter-form input[type="text"],
.newsletter-form input[type="email"] {
    width: 100%;
    margin-bottom: 1.2rem;
    background-color: var(--ns-footer-field);
    color: #fff;
    border: 1px solid transparent;
    padding: .8rem 2rem;
}

.newsletter-form input::placeholder { color: rgba(255, 255, 255, 0.65); }

.newsletter-form input:focus {
    border-color: var(--ns-green);
    background-color: var(--ns-footer-field);
    color: #fff;
}

.newsletter-form .btn {
    width: 100%;
    margin: 0;
}

.newsletter-form .btn:hover,
.newsletter-form .btn:focus {
    background-color: #fff;
    border-color: #fff;
    color: var(--ns-dark);
}

.s-footer__bottom {
    padding-top: var(--vspace-0_5);
}

.ss-copyright span { color: #fff; }
.ss-copyright span::after { color: rgba(255, 255, 255, 0.3); }

.ss-copyright a,
.ss-copyright a:visited {
    color: #fff;
}

.ss-copyright a:hover,
.ss-copyright a:focus {
    color: var(--ns-green);
}

.ss-go-top a {
    background-color: var(--ns-green);
}

.ss-go-top svg path { fill: var(--ns-dark); }

@media screen and (max-width: 800px) {
    .s-footer__subscribe { margin-top: var(--vspace-0_5); }
}

/* accessible hidden text
 * ------------------------------------------------------------------- */
.hide-content {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* rounded article cards
 * ------------------------------------------------------------------- */
:root { --ns-radius: 25px; }

.bricks-wrapper .entry__thumb {
    border-radius: var(--ns-radius) var(--ns-radius) 0 0;
    overflow: hidden;
}

.bricks-wrapper .entry__text {
    border-radius: 0 0 var(--ns-radius) var(--ns-radius);
}

.bricks-wrapper .featured-grid .entry__content {
    border-radius: var(--ns-radius);
    overflow: hidden;
}

/* ===================================================================
 * cookie banner
 * ------------------------------------------------------------------- */
.cookie-banner {
    z-index: 500;
    position: fixed;
    left: 1.6rem;
    right: 1.6rem;
    bottom: 1.6rem;
    max-width: 96rem;
    margin: 0 auto;
    background-color: var(--ns-dark);
    color: #fff;
    border-radius: var(--ns-radius);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.25);
    opacity: 0;
    transform: translateY(1.6rem);
    transition: opacity .3s ease, transform .3s ease;
}

.cookie-banner.is-visible {
    opacity: 1;
    transform: none;
}

.cookie-banner__inner {
    display: flex;
    align-items: center;
    gap: 2.4rem;
    padding: 2rem 2.8rem;
}

.cookie-banner__text {
    flex: 1;
    margin: 0;
    font-size: 1.5rem;
    line-height: 1.6;
    color: #fff;
}

.cookie-banner__text a,
.cookie-banner__text a:visited {
    color: var(--ns-green);
    text-decoration: underline;
}

.cookie-banner__text a:hover { color: #fff; }

.cookie-banner__actions {
    display: flex;
    gap: 1.2rem;
    flex-shrink: 0;
}

.cookie-banner__btn {
    margin: 0;
    height: 4.8rem;
    line-height: 4.8rem;
    padding: 0 2.4rem;
}

.cookie-banner__btn:not(.btn--primary) {
    background-color: transparent;
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
}

.cookie-banner__btn:not(.btn--primary):hover,
.cookie-banner__btn:not(.btn--primary):focus {
    background-color: #fff;
    border-color: #fff;
    color: var(--ns-dark);
}

@media screen and (max-width: 700px) {
    .cookie-banner__inner {
        flex-direction: column;
        align-items: stretch;
        gap: 1.6rem;
        padding: 2rem;
    }
    .cookie-banner__actions > * { flex: 1; }
}

/* rounded buttons (green primary buttons + matching secondary)
 * ------------------------------------------------------------------- */
.btn,
button.btn,
input[type="submit"].btn {
    border-radius: var(--ns-radius);
}

/* ===================================================================
 * single article
 * ------------------------------------------------------------------- */
.s-content--single {
    padding-top: var(--vspace-1_5);
}

.s-content--single .s-content__media {
    margin-bottom: var(--vspace-1_5);
}

.s-content__post-thumb img {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    max-height: 52rem;
    object-fit: cover;
    border-radius: var(--ns-radius);
}

.s-content__title--post {
    color: var(--ns-dark);
    margin-bottom: var(--vspace-0_5);
}

.s-content__post-meta {
    margin-bottom: var(--vspace-1_5);
}

.s-content__post-meta .cat a,
.s-content__post-meta .cat a:visited {
    display: inline-block;
    padding: .2rem 1.2rem;
    margin-right: .6rem;
    border-radius: var(--ns-radius);
    background-color: var(--ns-green);
    color: var(--ns-dark);
    font-size: 1.3rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .05em;
}

.s-content__post-meta .cat a::after { content: none; }
.s-content__post-meta .cat a:hover { background-color: var(--ns-dark); color: #fff; }

/* article body */
.s-content__body {
    color: #3d3d3d;
}

.s-content__body h2,
.s-content__body h3 {
    color: var(--ns-dark);
}

.s-content__body a,
.s-content__body a:visited {
    color: var(--ns-green-dark);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

.s-content__body a:hover,
.s-content__body a:focus {
    color: var(--ns-dark);
}

/* inline images: never wider than the text column, tall images capped */
.s-content__primary .s-content__body img {
    display: block;
    /* width set in WordPress (--w), capped by the column and by 80vh of height (--r = width / height);
       height follows from the width/height attributes, so space is reserved before the image loads */
    width: min(var(--w, 100%), 100%, calc(80vh * var(--r, 100)));
    max-width: 100%;
    height: auto;
    margin: var(--vspace-1) auto;
    border-radius: var(--ns-radius);
}

.s-content__body .alignleft  { float: left;  margin: .8rem 2.4rem 1.6rem 0; }
.s-content__body .alignright { float: right; margin: .8rem 0 1.6rem 2.4rem; }

.s-content__body blockquote {
    border-left: 4px solid var(--ns-green);
    border-radius: 0 var(--ns-radius) var(--ns-radius) 0;
    background-color: #f7f9f0;
    padding: 2.4rem 3.2rem;
}

.s-content__body hr {
    border-color: var(--ns-light);
}

/* tables: scroll horizontally on small screens */
.s-content__body table {
    display: block;
    overflow-x: auto;
    width: 100%;
    border-collapse: collapse;
    font-size: 1.5rem;
    margin-bottom: var(--vspace-1);
}

.s-content__body th,
.s-content__body td {
    padding: 1.2rem 1.6rem;
    border-bottom: 1px solid var(--ns-light);
    text-align: left;
    vertical-align: top;
    min-width: 14rem;
}

.s-content__body th {
    background-color: var(--ns-dark);
    color: #fff;
    font-weight: 600;
}

/* share
 * ------------------------------------------------------------------- */
.s-share {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 1.6rem;
    margin: var(--vspace-1_5) 0 var(--vspace-1);
    padding-top: var(--vspace-1);
    border-top: 1px solid var(--ns-light);
}

.s-share__label {
    font-weight: 600;
    color: var(--ns-dark);
}

.s-share__list {
    display: flex;
    gap: 1rem;
    list-style: none;
    margin: 0;
}

.s-share__list li { margin: 0; padding: 0; }

.s-share__link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    border-radius: 50%;
    background-color: #000;
    transition: background-color .3s;
}

.s-share__link svg { width: 2rem; height: 2rem; }
.s-share__link svg path { fill: #fff; transition: fill .3s; }
.s-share__link:hover,
.s-share__link:focus { background-color: var(--ns-green); }
.s-share__link:hover svg path,
.s-share__link:focus svg path { fill: #000; }

/* related posts
 * ------------------------------------------------------------------- */
.s-related {
    padding-top: var(--vspace-2);
}

.s-related .row {
    max-width: var(--row-max-width);
}

.s-related__title {
    color: var(--ns-dark);
    margin-bottom: var(--vspace-1);
}

.s-related__item {
    margin-bottom: var(--vspace-1_5);
}

.s-related__thumb {
    display: block;
    overflow: hidden;
    border-radius: var(--ns-radius) var(--ns-radius) 0 0;
}

.s-related__thumb img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 3 / 2;
    object-fit: cover;
    margin: 0;
    transition: transform .5s ease;
}

.s-related__item:hover .s-related__thumb img { transform: scale(1.05); }

.s-related__text {
    padding: 1.6rem 2.4rem 2.4rem;
    border: 1px solid var(--ns-light);
    border-top: 3px solid var(--ns-green);
    border-radius: 0 0 var(--ns-radius) var(--ns-radius);
}

.s-related__text .entry__meta {
    font-size: var(--text-sm);
    color: var(--color-text-light);
    margin-bottom: .4rem;
}

.s-related__text .entry__title {
    font-size: 1.9rem;
    line-height: 1.4;
    font-weight: 500;
    margin: 0;
}

.s-related__text .entry__title a,
.s-related__text .entry__title a:visited { color: var(--ns-dark); }
.s-related__text .entry__title a:hover { color: var(--ns-green-dark); }

/* equal-height related cards */
.s-related__item { display: flex; flex-direction: column; }
.s-related__text { flex: 1; }

/* pagination
 * ------------------------------------------------------------------- */
.pgn__num {
    border-radius: 50%;
    color: var(--ns-dark);
}

.pgn__num:hover,
.pgn__num:focus {
    background-color: var(--ns-green);
    color: var(--ns-dark);
}

.pgn__num.current,
.pgn__num.current:hover {
    background-color: var(--ns-dark);
    color: #fff;
}

.pgn__prev:hover svg path,
.pgn__next:hover svg path {
    fill: var(--ns-green-dark);
}

/* ===================================================================
 * sticky header
 * Fixed at the top; the page reserves its full height (--ns-header-h)
 * so nothing jumps. After scrolling down, js adds .is-scrolled and the
 * header eases into a compact version.
 * ------------------------------------------------------------------- */
:root {
    --ns-header-h: 12.8rem;
    --ns-header-h-compact: 8rem;
    --ns-ease: cubic-bezier(0.25, 0.8, 0.25, 1);
}

html { scroll-padding-top: calc(var(--ns-header-h-compact) + 1.6rem); }

body { padding-top: var(--ns-header-h); }

.s-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 400;
    height: var(--ns-header-h);
    transition: height .4s var(--ns-ease), box-shadow .4s var(--ns-ease), padding .4s var(--ns-ease);
}

.s-header__logo img {
    transition: height .4s var(--ns-ease);
}

.s-header.is-scrolled {
    height: var(--ns-header-h-compact);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.08);
}

.s-header.is-scrolled .s-header__logo img { height: 4.4rem; }

/* 801-1100: logo + nav on two rows */
@media screen and (min-width: 801px) and (max-width: 1100px) {
    :root { --ns-header-h: 12rem; --ns-header-h-compact: 9.6rem; }
    .s-header { height: var(--ns-header-h); }
    .s-header__nav li a { transition: line-height .4s var(--ns-ease); }
    .s-header__search-trigger { transition: top .4s var(--ns-ease); }
    .s-header.is-scrolled { padding-top: .8rem; }
    .s-header.is-scrolled .s-header__logo img { height: 3.6rem; }
    .s-header.is-scrolled .s-header__nav-wrap { margin-top: .2rem; }
    .s-header.is-scrolled .s-header__nav li a { line-height: 3.6rem; }
    .s-header.is-scrolled .s-header__search-trigger { top: .6rem; }
}

@media screen and (max-width: 800px) {
    :root { --ns-header-h-compact: 7.2rem; }
    .s-header.is-scrolled .s-header__logo img { height: 3.8rem; }
}

@media screen and (max-width: 600px) {
    :root { --ns-header-h: 11.2rem; --ns-header-h-compact: 6.8rem; }
    .s-header.is-scrolled .s-header__logo img { height: 3.4rem; }
}

@media screen and (max-width: 400px) {
    :root { --ns-header-h: 10rem; }
}

@media (prefers-reduced-motion: reduce) {
    .s-header,
    .s-header__logo img,
    .s-header__nav li a,
    .s-header__search-trigger { transition: none; }
}

/* search overlay hint (template text, translated) */
.s-header__search-form::after { content: "Pulsa Intro para buscar."; }

/* video embeds in articles */
.s-content__body .video-container {
    margin: var(--vspace-1) 0;
    border-radius: var(--ns-radius);
    background-color: #000;
}

/* ===================================================================
 * main menu hover: 1px line grows under the text (desktop only)
 * grows in from the left, leaves to the right
 * ------------------------------------------------------------------- */
@media screen and (min-width: 801px) {
    .s-header__nav > li > a {
        position: relative;
    }

    .s-header__nav > li > a::after {
        content: "";
        position: absolute;
        left: 0;
        right: 0;
        bottom: calc(50% - 1em);
        height: 1px;
        background-color: currentColor;
        transform: scaleX(0);
        transform-origin: right center;
        transition: transform .4s var(--ns-ease);
    }

    .s-header__nav > li > a:hover::after,
    .s-header__nav > li > a:focus-visible::after,
    .s-header__nav > li.current > a::after,
    .s-header__nav > li > a[aria-current="page"]::after {
        transform: scaleX(1);
        transform-origin: left center;
    }

    /* replace the template's 2px "current" bar with the line above */
    .s-header__nav li.current > a::before { display: none; }

    .s-header__nav li a { transition: color .3s var(--ns-ease); }
}

@media (prefers-reduced-motion: reduce) {
    .s-header__nav > li > a::after { transition: none; }
}

/* ===================================================================
 * breadcrumbs (single article, above the featured image)
 * ------------------------------------------------------------------- */
.breadcrumbs {
    margin: 0 0 var(--vspace-0_75);
    font-size: 1.4rem;
    line-height: 1.6;
}

.breadcrumbs__list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
}

.breadcrumbs__item {
    display: flex;
    align-items: center;
    min-width: 0;
    margin: 0;
    padding: 0;
    color: var(--color-text-light);
}

/* separator */
.breadcrumbs__item + .breadcrumbs__item::before {
    content: "";
    display: inline-block;
    width: .6rem;
    height: .6rem;
    margin: 0 1.2rem 0 1rem;
    border-top: 1px solid currentColor;
    border-right: 1px solid currentColor;
    transform: rotate(45deg);
    opacity: .6;
}

.breadcrumbs__item a,
.breadcrumbs__item a:visited {
    color: var(--ns-dark);
    background-image: linear-gradient(currentColor, currentColor);
    background-size: 0 1px;
    background-position: left bottom;
    background-repeat: no-repeat;
    transition: background-size .4s var(--ns-ease), color .3s var(--ns-ease);
}

.breadcrumbs__item a:hover,
.breadcrumbs__item a:focus-visible {
    color: var(--ns-green-dark);
    background-size: 100% 1px;
}

/* current page: one line, ellipsis if too long */
.breadcrumbs__item--current {
    flex: 1 1 0;
    display: block;
    min-width: 12rem;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.breadcrumbs__item--current::before {
    vertical-align: middle;
    position: relative;
    top: -.1rem;
}

/* ===================================================================
 * category archive
 * ------------------------------------------------------------------- */
.intro__text {
    color: rgba(255, 255, 255, 0.75);
    font-size: 1.5rem;
    line-height: 1.6;
    margin: 1.2rem 0 0;
}

.bricks-wrapper .intro__box { flex-direction: column; align-items: flex-start; justify-content: center; }
.intro__title { text-align: left; width: 100%; }

.s-bricks--archive {
    padding-top: 2.4rem;
}

/* breadcrumbs aligned with the cards: same side padding as .bricks-wrapper .brick */
.masonry__crumbs { padding: 0 var(--gutter-lg); }
.masonry__crumbs .breadcrumbs { margin-bottom: var(--vspace-0_75); }

@media screen and (max-width: 1400px) { .masonry__crumbs { padding: 0 var(--gutter-md); } }
@media screen and (max-width: 800px)  { .masonry__crumbs { padding: 0 1.6rem; } }
@media screen and (max-width: 700px)  { .masonry__crumbs { padding: 0 1.2rem; } }
@media screen and (max-width: 600px)  { .masonry__crumbs { padding: 0 var(--gutter-mob); } }
@media screen and (max-width: 400px)  { .masonry__crumbs { padding: 0; } }

/* ===================================================================
 * card intro animation: short 30px slide-up, faster
 * (replaces the template's 150% / 1s fadeInUp; stagger is set in js/main.js)
 * ------------------------------------------------------------------- */
@keyframes nsFadeInUp {
    from {
        opacity: 0;
        visibility: visible;
        transform: translate3d(0, 30px, 0);
    }
    to {
        opacity: 1;
        visibility: visible;
        transform: translate3d(0, 0, 0);
    }
}

.animated {
    animation-name: nsFadeInUp;
    animation-duration: .5s;
    animation-timing-function: var(--ns-ease);
}

@media (prefers-reduced-motion: reduce) {
    .animate-this { opacity: 1; visibility: visible; }
    .animated { animation: none; }
}

/* WordPress image captions */
.s-content__body figure {
    max-width: 100%;
    margin: var(--vspace-1) auto;
    text-align: center;
}

.s-content__body figure img { margin: 0 auto var(--vspace-0_25); }

.s-content__body figcaption {
    font-size: 1.4rem;
    line-height: 1.5;
    color: var(--color-text-light);
}

/* TikTok embed: centred, without the article blockquote styling;
 * before consent it shows the quote text + link */
.s-content__body blockquote.tiktok-embed {
    max-width: 60.5rem !important;
    min-width: 0 !important;
    margin: var(--vspace-1) auto;
    padding: 0;
    border: 0;
    border-radius: var(--ns-radius);
    background: none;
    font-size: 1.5rem;
}

.s-content__body blockquote.tiktok-embed p,
.s-content__body blockquote.tiktok-embed section {
    font-size: 1.5rem;
    line-height: 1.6;
    text-align: center;
}

/* responsive images: the build wraps each <img> in a <picture>; let the <img> keep its layout */
picture { display: contents; }
/* the template's reset makes <source> a block: with display:contents on <picture> it would become a flex/grid item */
picture source { display: none; }

/* ===================================================================
 * simple pages (Contacto, Quiénes Somos): text column + image column
 * ------------------------------------------------------------------- */
.s-page {
    --row-max-width: 1200px;
    padding-top: var(--vspace-1_5);
}

.s-page .breadcrumbs { margin-bottom: var(--vspace-1); }

.s-page__row { align-items: flex-start; }

.s-page__title {
    color: var(--ns-dark);
    margin-top: 0;
    margin-bottom: var(--vspace-0_75);
}

.s-page__main p a,
.s-page__main p a:visited {
    color: var(--ns-green-dark);
    text-decoration: underline;
    text-underline-offset: 3px;
}

.contact-form { margin-top: var(--vspace-1); }

.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
    width: 100%;
    margin-bottom: 1.2rem;
    background-color: var(--ns-light);
    border: 1px solid transparent;
    padding: .8rem 2rem;
    color: var(--ns-dark);
}

.contact-form textarea {
    min-height: 16rem;
    padding-top: 1.6rem;
    resize: vertical;
}

.contact-form input:focus,
.contact-form textarea:focus {
    border-color: var(--ns-green);
    background-color: #fff;
}

.contact-form .btn {
    width: 100%;
    margin: .4rem 0 0;
}

.s-page__media img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--ns-radius);
}

@media screen and (max-width: 800px) {
    .s-page__media { margin-top: var(--vspace-1_5); }
}

.s-page__main h2 {
    color: var(--ns-dark);
    margin-top: 0;
}

/* signature: round avatar + name */
.s-page__signature {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-top: var(--vspace-1);
}

.s-page__signature img {
    width: 9.6rem;
    height: 9.6rem;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.s-page__signature p { margin: 0; }

/* intro block button (404 page) */
.intro__btn {
    margin: var(--vspace-0_75) 0 0;
}

.intro__box .intro__btn:hover,
.intro__box .intro__btn:focus {
    background-color: #fff;
    border-color: #fff;
    color: var(--ns-dark);
}

/* wide intro block (404): 3 of 4 columns on wide screens, full width when the grid has 3 columns or fewer */
.bricks-wrapper .entry--intro-wide { width: 75%; }

.bricks-wrapper .entry--intro-wide .intro__box {
    min-height: 0;
    padding: 4.8rem 4.8rem 4.4rem;
}

.bricks-wrapper .entry--intro-wide .intro__box::before { left: 4.8rem; top: 4.8rem; }

.bricks-wrapper .entry--intro-wide .intro__title {
    font-size: 4rem;
    margin-top: 2.8rem;
}

.bricks-wrapper .entry--intro-wide .intro__text { font-size: 1.8rem; }

@media screen and (max-width: 1400px) {
    .bricks-wrapper .entry--intro-wide { width: 100%; }
}

@media screen and (max-width: 600px) {
    .bricks-wrapper .entry--intro-wide .intro__box { padding: 3.6rem 2.4rem 3.2rem; }
    .bricks-wrapper .entry--intro-wide .intro__box::before { left: 2.4rem; top: 3.6rem; }
    .bricks-wrapper .entry--intro-wide .intro__title { font-size: 2.8rem; }
    .bricks-wrapper .entry--intro-wide .intro__text { font-size: 1.6rem; }
}

/* ===================================================================
 * search page: CSS grid with the same columns as the masonry archives
 * ------------------------------------------------------------------- */
.bricks-wrapper.search-results {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    column-gap: calc(var(--gutter-lg) * 2);
    row-gap: 4rem;
    align-items: start;
    padding: 0 var(--gutter-lg);
}

.bricks-wrapper.search-results .brick {
    float: none;
    width: auto;
    padding: 0;
    margin: 0;
}

.bricks-wrapper.search-results .entry--intro-wide { grid-column: span 3; }

.s-search__form {
    position: relative;
    width: 100%;
    max-width: 56rem;
    margin-top: var(--vspace-0_75);
}

.s-search__form input[type="search"] {
    width: 100%;
    margin: 0;
    padding: 1.2rem 6rem 1.2rem 2.4rem;
    border: 1px solid transparent;
    border-radius: var(--ns-radius);
    background-color: #fff;
    color: var(--ns-dark);
}

.s-search__form input[type="search"]:focus { border-color: var(--ns-green); }

.s-search__submit {
    position: absolute;
    top: 50%;
    right: .6rem;
    transform: translateY(-50%);
    width: 4.4rem;
    height: 4.4rem;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background-color: var(--ns-green);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.s-search__submit svg { width: 2rem; height: 2rem; }
.s-search__submit svg path { fill: var(--ns-dark); }
.s-search__submit:hover { background-color: var(--ns-dark); }
.s-search__submit:hover svg path { fill: #fff; }

.s-search__more {
    text-align: center;
    margin: var(--vspace-1_5) 0 var(--vspace-1);
}

@media screen and (max-width: 1400px) {
    .bricks-wrapper.search-results {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        column-gap: calc(var(--gutter-md) * 2);
        padding: 0 var(--gutter-md);
    }
}

@media screen and (max-width: 980px) {
    .bricks-wrapper.search-results { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .bricks-wrapper.search-results .entry--intro-wide { grid-column: span 2; }
}

@media screen and (max-width: 800px) {
    .bricks-wrapper.search-results { column-gap: 3.2rem; padding: 0 1.6rem; }
}

@media screen and (max-width: 600px) {
    .bricks-wrapper.search-results { grid-template-columns: minmax(0, 1fr); row-gap: 3.6rem; padding: 0 var(--gutter-mob); }
    .bricks-wrapper.search-results .entry--intro-wide { grid-column: auto; }
}

@media screen and (max-width: 400px) {
    .bricks-wrapper.search-results { padding: 0; }
}

/* legal / long text pages: comfortable reading width */
.s-legal__body {
    max-width: 80rem;
}

.s-legal__body h2 {
    font-size: var(--text-xl);
    margin-top: var(--vspace-1_5);
}

/* message page (Confirmar): centred dark card */
.s-message { padding-top: var(--vspace-2); padding-bottom: var(--vspace-2); }

.bricks-wrapper .s-message__box {
    max-width: 72rem;
    margin: 0 auto;
    min-height: 0;
    padding: 4.8rem;
}

.bricks-wrapper .s-message__box::before { left: 4.8rem; top: 4.8rem; }
.s-message__box .intro__title { font-size: 4rem; margin-top: 2.8rem; }
.s-message__box .intro__text { font-size: 1.8rem; }

@media screen and (max-width: 600px) {
    .bricks-wrapper .s-message__box { padding: 3.6rem 2.4rem 3.2rem; }
    .bricks-wrapper .s-message__box::before { left: 2.4rem; top: 3.6rem; }
    .s-message__box .intro__title { font-size: 2.8rem; }
    .s-message__box .intro__text { font-size: 1.6rem; }
}
