/* =========================================================
   Tay-Sachs SK — taysachs.sk
   Palette & type derived from the printed pamphlet
   (Liberation Sans → Arimo, Liberation Mono → Roboto Mono)
   ========================================================= */

:root {
    /* Brand text colours */
    --navy:        #163859;
    --gold:        #7A6540;
    --brown:       #5B4A32;
    --ink:         #3A3730;
    --olive:       #5C6B3C;
    --green:       #3F6B45;
    --green-soft:  #6E9459;
    --near-black:  #2B2A26;
    --muted:       #6d6a60;

    /* Surfaces */
    --paper:       #FFFFFF;
    --cream-1:     #F8EFE1;
    --cream-2:     #EADFC6;
    --mint:        #EBF2E4;
    --mint-strong: #DFEAD5;
    --mint-border: #CBDEC0;
    --foot-bg:     #EEF3E7;
    --line:        #D7E4CE;

    /* Type */
    --font-sans: 'Arimo', Arial, Helvetica, sans-serif;
    --font-mono: 'Roboto Mono', 'Courier New', monospace;

    /* Layout */
    --container: 1140px;
    --radius:    12px;
    --radius-lg: 18px;
    --shadow-sm: 0 1px 3px rgba(22, 56, 89, 0.07);
    --shadow-md: 0 8px 28px rgba(22, 56, 89, 0.09);
    --header-h:  84px;
    --header-h-shrunk: 62px;
    --transition: 0.25s ease;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-sans);
    font-size: 1.0625rem;
    line-height: 1.65;
    color: var(--ink);
    background: var(--paper);
    overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

/* <picture> must not become the flex/grid item itself — display:contents keeps
   the inner <img> as the direct child, so every existing layout rule still
   targets the same box it did before WebP sources were added. */
picture { display: contents; }

a { color: var(--green); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--olive); }

ul, ol { list-style: none; }

button { font: inherit; cursor: pointer; border: none; background: none; }

:focus-visible {
    outline: 3px solid var(--green-soft);
    outline-offset: 2px;
    border-radius: 4px;
}

::selection { background: var(--mint-strong); color: var(--near-black); }

.skip-link {
    position: absolute;
    top: -48px;
    left: 12px;
    z-index: 1001;
    background: var(--navy);
    color: #fff;
    padding: 10px 18px;
    border-radius: 0 0 8px 8px;
    transition: top 0.2s ease;
}
.skip-link:focus { top: 0; color: #fff; }

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Typography ---------- */
h1, h2, h3 { color: var(--navy); line-height: 1.2; font-weight: 700; }

.eyebrow {
    display: block;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 14px;
}

.section-title {
    font-size: clamp(1.65rem, 3.2vw, 2.25rem);
    margin-bottom: 12px;
}

.section-title::after {
    content: "";
    display: block;
    width: 56px;
    height: 3px;
    margin-top: 14px;
    border-radius: 2px;
    background: var(--line);
}

.section-title.is-centered { text-align: center; }
.section-title.is-centered::after { margin-left: auto; margin-right: auto; }

.section-lead {
    max-width: 42em;
    color: var(--ink);
    margin-bottom: 8px;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 28px;
    min-height: 48px;
    border-radius: 10px;
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.2;
    cursor: pointer;
    transition: background-color var(--transition), color var(--transition),
                border-color var(--transition), transform 0.15s ease, box-shadow var(--transition);
    touch-action: manipulation;
}
.btn:active { transform: scale(0.97); }

.btn-primary {
    background: var(--green);
    color: #fff;
    box-shadow: var(--shadow-sm);
}
.btn-primary:hover { background: #35593a; color: #fff; box-shadow: var(--shadow-md); }

.btn-outline {
    background: transparent;
    color: var(--navy);
    border: 2px solid rgba(22, 56, 89, 0.35);
}
.btn-outline:hover { border-color: var(--navy); color: var(--navy); background: rgba(22, 56, 89, 0.05); }

.btn-ghost {
    background: transparent;
    color: var(--green);
    padding: 14px 10px;
    font-weight: 600;
}
.btn-ghost:hover { color: var(--olive); }

.btn svg { flex: none; }

/* ---------- Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid transparent;
    transition: box-shadow var(--transition), border-color var(--transition);
}

.site-header.is-shrunk {
    box-shadow: var(--shadow-sm);
    border-bottom-color: var(--line);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    height: var(--header-h);
    transition: height var(--transition);
}

.site-header.is-shrunk .header-inner { height: var(--header-h-shrunk); }

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: none;
    min-width: 0;
}

.brand-mark {
    width: 52px;
    height: 52px;
    object-fit: contain;
    transition: width var(--transition), height var(--transition);
}
.site-header.is-shrunk .brand-mark { width: 40px; height: 40px; }

.brand-text { display: flex; flex-direction: column; line-height: 1.15; }

.brand-name {
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--navy);
    letter-spacing: 0.01em;
}

.brand-sub {
    font-size: 0.62rem;
    font-weight: 600;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    color: var(--gold);
}

.main-nav { min-width: 0; }

.main-nav ul {
    display: flex;
    align-items: center;
    gap: 3px;
}

.main-nav a {
    display: inline-block;
    padding: 9px 10px;
    border-radius: 8px;
    color: var(--near-black);
    font-weight: 500;
    font-size: 0.93rem;
    white-space: nowrap;
}

.main-nav a:hover { background: var(--mint); color: var(--green); }

.main-nav a.active {
    color: var(--green);
    background: var(--mint);
    font-weight: 600;
}

.header-tools { display: flex; align-items: center; gap: 14px; flex: none; }

/* Language switcher — button + dropdown */
.lang-switch { position: relative; }

.lang-current {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding: 7px 12px;
    background: var(--mint);
    border: 1px solid var(--mint-border);
    border-radius: 999px;
    color: var(--olive);
    font-size: 0.83rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    transition: background-color var(--transition), border-color var(--transition), color var(--transition);
}
.lang-current:hover { background: var(--mint-strong); border-color: var(--green-soft); color: var(--green); }
.lang-current[aria-expanded="true"] { background: var(--mint-strong); border-color: var(--green-soft); color: var(--green); }

.lang-flag {
    display: block;
    flex: none;
    width: 24px;
    height: 16px;
    border-radius: 3px;
    overflow: hidden;
    /* the flags are light-on-light; a hairline keeps them readable on mint */
    box-shadow: inset 0 0 0 1px rgba(22, 56, 89, 0.18);
}
.lang-flag svg { display: block; }

.lang-caret { flex: none; transition: transform var(--transition); }
.lang-current[aria-expanded="true"] .lang-caret { transform: rotate(180deg); }

.lang-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 120;
    min-width: 190px;
    padding: 6px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 12px;
    box-shadow: var(--shadow-md);
}
.lang-menu[hidden] { display: none; }

/* No JS: the toggle can never open the menu, so drop the button and lay the
   languages out inline. Changing language must not depend on scripting. */
html.no-js .lang-current { display: none; }
html.no-js .lang-menu[hidden] {
    display: flex;
    gap: 2px;
    position: static;
    min-width: 0;
    padding: 3px;
    background: var(--mint);
    border-color: var(--mint-border);
    border-radius: 999px;
    box-shadow: none;
}
html.no-js .lang-item { min-height: 38px; padding: 6px 10px; }
html.no-js .lang-name, html.no-js .lang-check { display: none; }

.lang-item {
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 44px;
    padding: 9px 12px;
    border-radius: 8px;
    color: var(--near-black);
    font-size: 0.95rem;
    font-weight: 500;
    white-space: nowrap;
}
.lang-item:hover { background: var(--mint); color: var(--green); }
.lang-item.is-active { color: var(--green); font-weight: 700; }

.lang-name { flex: 1; }
.lang-check { flex: none; color: var(--green); }

/* Opening animation, suppressed for users who ask for reduced motion */
@media (prefers-reduced-motion: no-preference) {
    .lang-menu { animation: lang-menu-in 0.16s ease-out; }
    @keyframes lang-menu-in {
        from { opacity: 0; transform: translateY(-6px); }
        to   { opacity: 1; transform: none; }
    }
}

/* Mobile nav toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 10px;
    border-radius: 8px;
}
.nav-toggle:hover { background: var(--mint); }

.nav-toggle-bar {
    display: block;
    width: 22px;
    height: 2px;
    border-radius: 2px;
    background: var(--navy);
    transition: transform 0.25s ease, opacity 0.2s ease;
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
    background: linear-gradient(135deg, var(--cream-1) 0%, var(--cream-2) 100%);
    overflow: hidden;
}

.hero-inner {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr;
    align-items: center;
    gap: 40px;
    /* padding-block only — shorthand here would wipe .container's side padding */
    padding-top: 72px;
    padding-bottom: 76px;
}

.hero-title {
    font-size: clamp(2.4rem, 5.5vw, 3.6rem);
    letter-spacing: -0.01em;
    margin-bottom: 18px;
}

.hero-lead {
    font-size: clamp(1.05rem, 1.8vw, 1.22rem);
    color: var(--brown);
    max-width: 34em;
    margin-bottom: 30px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
}

.hero-figure { display: flex; justify-content: center; }

.hero-figure img {
    width: min(360px, 78%);
    filter: drop-shadow(0 18px 30px rgba(22, 56, 89, 0.12));
}

/* ---------- Sections ---------- */
.section { padding: 88px 0; }
.section-tight { padding: 64px 0; }
.section-alt { background: #FBF9F4; }

.section-head { margin-bottom: 40px; }
.section-head.is-centered { text-align: center; }
.section-head.is-centered .section-lead { margin-left: auto; margin-right: auto; }

.section-head-row {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    margin-bottom: 40px;
}

/* nowrap keeps it on one line beside a heading in .section-head-row;
   it has to be allowed to wrap on narrow screens. */
.section-more { font-weight: 600; white-space: nowrap; }
.section-more::after { content: " →"; }

/* ---------- Mission ---------- */
.mission-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px 40px;
    max-width: 940px;
}

.mission-item {
    position: relative;
    padding: 14px 0 14px 34px;
    border-bottom: 1px solid var(--line);
    font-size: 1.03rem;
}
.mission-item:nth-last-child(-n+2) { border-bottom: none; }

.mission-item::before {
    content: "";
    position: absolute;
    left: 6px;
    top: 24px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--green-soft);
}

/* ---------- Support strip ---------- */
.support-box {
    background: var(--mint);
    border: 1px solid var(--mint-border);
    border-radius: var(--radius-lg);
    padding: clamp(28px, 4vw, 48px);
}

.support-box .section-title { margin-bottom: 8px; }

.support-box p { max-width: 52em; }

.iban-box {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 22px;
    background: var(--paper);
    border: 1px solid var(--mint-border);
    border-radius: var(--radius);
    padding: 18px 24px;
    margin: 26px 0 20px;
    container-type: inline-size;
}

.iban-label {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--green);
}

.iban-value {
    font-family: var(--font-mono);
    font-size: clamp(0.95rem, 2.4vw, 1.25rem);
    font-weight: 500;
    color: var(--near-black);
    letter-spacing: 0.02em;
    overflow-wrap: anywhere;
}

/* An IBAN must never break across lines. It is monospace and 28 characters
   wide, so it always occupies 17.36em — dividing the container width by a
   slightly larger figure guarantees it fits on one line at the biggest size
   that container allows. Falls back to the clamp above without cq support. */
@supports (container-type: inline-size) {
    .iban-value {
        white-space: nowrap;
        overflow-wrap: normal;
        font-size: min(1.25rem, calc(100cqi / 18.2));
    }

    /* too tight to sit beside the label and the copy button — give it a row */
    @container (max-width: 640px) {
        .iban-value { flex-basis: 100%; }
        /* the button is then alone on the last row — centre it under the number */
        .iban-copy { margin-inline: auto; }
    }
}

.iban-copy {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 14px;
    min-height: 40px;
    border: 1px solid var(--mint-border);
    border-radius: 8px;
    background: var(--mint);
    color: var(--green);
    font-size: 0.87rem;
    font-weight: 600;
    transition: background-color var(--transition), border-color var(--transition);
}
.iban-copy:hover { background: var(--mint-strong); border-color: var(--green-soft); }

/* ---------- Cards ---------- */
.card {
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 30px;
    box-shadow: var(--shadow-sm);
    transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
}

a.card-link-wrap { color: inherit; display: block; height: 100%; }

.card:hover,
a.card-link-wrap:hover .card {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
    border-color: var(--mint-border);
}

/* ---------- News ---------- */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.news-card { display: flex; flex-direction: column; height: 100%; }

.news-date {
    font-size: 0.82rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 10px;
}

.news-card h3 {
    font-size: 1.12rem;
    margin-bottom: 10px;
    line-height: 1.35;
}

.news-card p { font-size: 0.96rem; color: var(--muted); flex: 1; }

.news-readmore {
    margin-top: 16px;
    font-weight: 600;
    font-size: 0.95rem;
}
.news-readmore::after { content: " →"; }

/* News list page */
.news-list { display: grid; gap: 24px; max-width: 860px; }

/* News article */
.article {
    max-width: 780px;
}
.article h1 { font-size: clamp(1.7rem, 3.5vw, 2.4rem); margin-bottom: 10px; }
.article-meta { color: var(--gold); font-weight: 600; font-size: 0.9rem; letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 28px; }
.article h2 { font-size: 1.35rem; margin: 32px 0 12px; color: var(--olive); }
.article p { margin-bottom: 16px; }
.article ul { margin: 0 0 16px; }
.article ul li {
    position: relative;
    padding: 4px 0 4px 26px;
}
.article ul li::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 13px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--green-soft);
}
.article a { text-decoration: underline; text-underline-offset: 3px; }

.back-link {
    display: inline-block;
    margin-bottom: 26px;
    font-weight: 600;
}
.back-link::before { content: "← "; }

/* ---------- Story ---------- */
.story-teaser {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 48px;
    align-items: center;
}

.story-photo {
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.story-photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }

.story-quote {
    font-size: clamp(1.1rem, 2vw, 1.3rem);
    color: var(--brown);
    line-height: 1.55;
    border-left: 3px solid var(--green-soft);
    padding-left: 22px;
    margin: 18px 0 26px;
    font-style: italic;
}

.story-name {
    font-weight: 700;
    color: var(--navy);
    font-size: 1.05rem;
}

/* Story full page */
.story-layout {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 48px;
    align-items: start;
}

.story-layout .story-photo { position: sticky; top: 110px; }

.story-body p { margin-bottom: 16px; }

.story-body .story-lead {
    font-size: 1.15rem;
    color: var(--brown);
}

/* ---------- Partners ---------- */
.partners-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 24px;
}

/* With 4 partners auto-fit lands on 3 + 1 orphan between ~770 and 1024px.
   Pair them up instead. */
@media (min-width: 601px) and (max-width: 1024px) {
    .partners-grid { grid-template-columns: repeat(2, 1fr); }
}

.partner-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    text-align: center;
    padding: 34px 26px;
    color: inherit;
}

.partner-card img {
    height: 54px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
}

.partner-card .partner-name { font-weight: 600; color: var(--navy); font-size: 0.98rem; }
.partner-card .partner-url { font-size: 0.87rem; color: var(--green); font-weight: 600; }

/* ---------- Page header (subpages) ---------- */
.page-head {
    background: linear-gradient(135deg, var(--cream-1) 0%, var(--cream-2) 100%);
    padding: 56px 0 52px;
}

.page-head h1 {
    font-size: clamp(2rem, 4.5vw, 2.9rem);
    margin-bottom: 10px;
}

.page-head .section-lead { color: var(--brown); margin-bottom: 0; }

/* ---------- Info page ---------- */
.info-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 56px;
    align-items: start;
}

.info-toc {
    position: sticky;
    top: 110px;
    border-left: 2px solid var(--line);
}

.info-toc a {
    display: block;
    padding: 8px 0 8px 18px;
    margin-left: -2px;
    border-left: 2px solid transparent;
    color: var(--muted);
    font-size: 0.94rem;
    font-weight: 500;
}

.info-toc a:hover { color: var(--green); }
.info-toc a.is-active { color: var(--green); border-left-color: var(--green); font-weight: 600; }

.info-content h2 {
    font-size: clamp(1.35rem, 2.4vw, 1.7rem);
    margin: 44px 0 14px;
    scroll-margin-top: 110px;
}
.info-content h2:first-of-type { margin-top: 0; }

.info-content h3 { font-size: 1.12rem; color: var(--olive); margin: 24px 0 8px; }

.info-content p { margin-bottom: 14px; max-width: 68ch; }

.info-content ul { margin-bottom: 16px; }
.info-content ul li {
    position: relative;
    padding: 4px 0 4px 26px;
    max-width: 66ch;
}
.info-content ul li::before {
    content: "";
    position: absolute;
    left: 4px;
    top: 13px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--green-soft);
}

.info-note {
    background: var(--mint);
    border: 1px solid var(--mint-border);
    border-radius: var(--radius);
    padding: 18px 22px;
    margin: 20px 0;
    font-size: 0.97rem;
}

/* Foreign orgs */
.orgs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.org-card { height: 100%; padding: 26px; }

.org-country {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 8px;
}

.org-card h3 { font-size: 1.05rem; line-height: 1.4; margin-bottom: 12px; }

.org-card .org-link { font-weight: 600; font-size: 0.93rem; overflow-wrap: anywhere; }
.org-card .org-link::after { content: " ↗"; }

/* ---------- Get involved ---------- */
.involved-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 28px;
    max-width: 920px;
    margin: 0 auto;
}

.doc-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    padding: 38px 34px;
    height: 100%;
}

.doc-icon {
    width: 56px;
    height: 56px;
    display: grid;
    place-items: center;
    background: var(--mint);
    border: 1px solid var(--mint-border);
    border-radius: 14px;
    color: var(--green);
}

.doc-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    width: 100%;
}

.doc-card h2 { font-size: 1.3rem; }
.doc-card p { color: var(--muted); font-size: 0.98rem; flex: 1; }

/* ---------- Support page ---------- */
.support-layout {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: start;
}

.detail-list { display: grid; gap: 0; container-type: inline-size; }

.detail-row {
    display: grid;
    /* flexible label column — a fixed 190px starves the value in a narrow card */
    grid-template-columns: minmax(130px, 190px) 1fr;
    gap: 8px 18px;
    padding: 13px 0;
    border-bottom: 1px solid var(--line);
}
.detail-row:last-child { border-bottom: none; }

.detail-label {
    font-size: 0.85rem;
    font-weight: 700;
    letter-spacing: 0.07em;
    text-transform: uppercase;
    color: var(--olive);
    padding-top: 2px;
}

.detail-value { color: var(--near-black); overflow-wrap: anywhere; }
.detail-value.mono { font-family: var(--font-mono); font-size: 0.98rem; }

/* The IBAN row spans the full width of the list instead of starting after the
   label column — 273px of monospace does not fit in what is left otherwise. */
.detail-row.is-stacked { grid-template-columns: 1fr; gap: 5px; }

@supports (container-type: inline-size) {
    .detail-value.mono {
        white-space: nowrap;
        overflow-wrap: normal;
        font-size: min(0.98rem, calc(100cqi / 17.8));
    }
}

/* ---------- About ---------- */
.about-layout {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 48px;
    align-items: start;
}

.values-card { padding: 34px; }
.values-card h2 { font-size: 1.3rem; margin-bottom: 10px; }

.values-list { display: grid; }

.value-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
}
.value-item:last-child { border-bottom: none; }

.value-icon {
    flex: none;
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    background: var(--mint);
    border: 1px solid var(--mint-border);
    border-radius: 12px;
    color: var(--green);
}

.value-name { font-weight: 600; color: var(--navy); }

.values-note {
    margin-top: 14px;
    font-size: 0.92rem;
    font-style: italic;
    color: var(--brown);
}

.about-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
}

.about-cards .doc-card h3 { font-size: 1.18rem; color: var(--navy); }

.stats-row {
    display: flex;
    flex-wrap: wrap;
    gap: 20px 56px;
    margin: 22px 0 26px;
}

.stat { display: flex; flex-direction: column; gap: 4px; }

.stat-num {
    font-size: clamp(1.7rem, 3.4vw, 2.3rem);
    font-weight: 700;
    color: var(--navy);
    line-height: 1.1;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--olive);
    font-weight: 600;
}

/* ---------- Contact ---------- */
.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    gap: 48px;
    align-items: start;
}

.contact-card { padding: 36px; }
.contact-card h2 { font-size: 1.35rem; margin-bottom: 22px; }

/* Form */
.form-grid { display: grid; gap: 18px; }

.form-field label {
    display: block;
    font-weight: 600;
    font-size: 0.93rem;
    color: var(--navy);
    margin-bottom: 7px;
}

.form-field .req { color: var(--green); }

.form-field input,
.form-field textarea {
    width: 100%;
    padding: 13px 16px;
    min-height: 48px;
    border: 1px solid var(--mint-border);
    border-radius: 10px;
    background: var(--paper);
    font: inherit;
    color: var(--near-black);
    transition: border-color var(--transition), box-shadow var(--transition);
}

.form-field textarea { resize: vertical; min-height: 140px; }

.form-field input:focus,
.form-field textarea:focus {
    outline: none;
    border-color: var(--green-soft);
    box-shadow: 0 0 0 3px rgba(110, 148, 89, 0.22);
}

.form-field input.is-invalid,
.form-field textarea.is-invalid { border-color: #b3452e; }

.form-error-msg {
    display: none;
    color: #9c3a24;
    font-size: 0.87rem;
    margin-top: 6px;
}
.form-field.has-error .form-error-msg { display: block; }

.form-status {
    display: none;
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 0.97rem;
    font-weight: 500;
}
.form-status.is-success { display: block; background: var(--mint); border: 1px solid var(--mint-border); color: var(--green); }
.form-status.is-error   { display: block; background: #F9ECE7; border: 1px solid #E5C4B8; color: #9c3a24; }

.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; overflow: hidden; }

/* ---------- Footer ---------- */
.site-footer {
    background: var(--foot-bg);
    border-top: 1px solid var(--line);
    margin-top: 96px;
}

.footer-grid {
    display: grid;
    grid-template-columns: auto 1.2fr 0.7fr 1fr;
    gap: 48px;
    padding: 56px 24px 44px;
}

.footer-logo-link { display: inline-block; }
.footer-logo-link img { width: 150px; height: auto;}

.footer-mission {
    font-size: 0.95rem;
    color: var(--muted);
    max-width: 34em;
}

.footer-heading {
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--olive);
    margin-bottom: 16px;
}

.footer-links { display: grid; gap: 8px; }
.footer-links a { color: var(--ink); font-size: 0.96rem; }
.footer-links a:hover { color: var(--green); }

.footer-address {
    font-style: normal;
    font-size: 0.96rem;
    line-height: 1.8;
    color: var(--ink);
}

.footer-bottom { border-top: 1px solid var(--line); }

.footer-bottom-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    padding-top: 18px;
    padding-bottom: 18px;
}

.footer-copy { font-size: 0.9rem; color: var(--muted); }

.footer-credit {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--muted);
}

.footer-credit-link { display: inline-flex; align-items: center; opacity: 0.75; transition: opacity var(--transition); }
.footer-credit-link:hover { opacity: 1; }
.footer-credit-link img { height: 16px; width: auto; }

/* ---------- Reveal animations ---------- */
.reveal {
    opacity: 0;
    transform: translateY(22px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.16s; }
.reveal-d3 { transition-delay: 0.24s; }

html.no-js .reveal { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
    .reveal { opacity: 1; transform: none; }
}

/* ---------- Responsive ---------- */
/* Horizontal nav only fits while the container is near its 1140px max —
   below that the 8 links collide with the language switcher, so switch to
   the drawer. */
@media (max-width: 1140px) {
    .nav-toggle { display: flex; }

    .main-nav {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--paper);
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow-md);
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    .main-nav.is-open { max-height: 480px; overflow-y: auto; }

    .main-nav ul {
        flex-direction: column;
        align-items: stretch;
        gap: 2px;
        padding: 14px 20px 20px;
    }

    .main-nav a { display: block; padding: 12px 14px; font-size: 1rem; }
}

/* Tablet. Two-column layouts have to give up here: below ~1024px the
   narrower column gets too tight to hold a form or a label/value table
   without wrapping every value onto 3-4 lines. */
@media (max-width: 1024px) {
    .info-layout { grid-template-columns: 1fr; gap: 32px; }
    .info-toc { display: none; }

    .story-layout { grid-template-columns: 300px 1fr; gap: 36px; }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 28px;
        padding-top: 48px;
        padding-bottom: 56px;
        text-align: center;
    }

    .hero-lead { margin-left: auto; margin-right: auto; }
    .hero-actions { justify-content: center; }
    .hero-figure { order: -1; }
    .hero-figure img { width: min(240px, 55%); margin-top: 15px; }

    .support-layout,
    .contact-layout,
    .about-layout { grid-template-columns: 1fr; gap: 32px; }

    /* Once these collapse to one column the prose column spans the full
       container — cap the measure so tablet lines stay readable. */
    .about-layout > div > p,
    .support-layout > div > p { max-width: 68ch; }

    /* 4 columns leaves the address column ~200px, which shreds it */
    .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 36px 40px; }
}

@media (max-width: 880px) {
    :root { --header-h: 70px; --header-h-shrunk: 60px; }

    .section { padding: 64px 0; }
    .section-tight { padding: 48px 0; }

    .mission-grid { grid-template-columns: 1fr; gap: 0; }
    .mission-item { border-bottom: 1px solid var(--line); }
    .mission-item:last-child { border-bottom: none; }
    .mission-item:nth-last-child(2) { border-bottom: 1px solid var(--line); }

    .story-teaser,
    .story-layout { grid-template-columns: 1fr; gap: 28px; }

    .story-layout .story-photo { position: static; max-width: 420px; }
    .story-teaser .story-photo { max-width: 420px; margin: 0 auto; }

    .involved-grid { grid-template-columns: 1fr; }

    .footer-grid { grid-template-columns: 1fr; gap: 32px; padding: 44px 24px 36px; }
    .footer-brand { text-align: center; }
    .footer-logo-link img { width: 116px; margin-top: 15px;}
}

@media (max-width: 480px) {
    body { font-size: 1rem; }

    .container { padding: 0 18px; }

    .header-inner { gap: 12px; }
    .header-tools { gap: 8px; }

    .brand { gap: 9px; }
    .brand-sub { display: none; }
    .brand-name { font-size: 1rem; }
    .brand-mark { width: 38px; height: 38px; }
    .site-header.is-shrunk .brand-mark { width: 34px; height: 34px; }

    .lang-current { gap: 6px; padding-left: 10px; padding-right: 10px; }

    .hero-actions { flex-direction: column; align-items: stretch; }
    .hero-actions .btn { width: 100%; }

    .card, .contact-card { padding: 24px 20px; }
    .doc-card { padding: 28px 22px; }
    .doc-actions { flex-direction: column; align-items: stretch; }
    .doc-actions .btn { width: 100%; }

    .detail-row { grid-template-columns: 1fr; gap: 2px; padding: 11px 0; }

    .iban-box { padding: 16px 18px; }

    .section-more { white-space: normal; }

    .footer-bottom-inner { flex-direction: column; text-align: center; }
}

/* Very small phones (iPhone SE / 320px): the wordmark no longer fits next to
   the language switcher and burger, so fall back to the logo mark alone. */
@media (max-width: 380px) {
    .brand-text { display: none; }
    /* flag + caret alone; the code is redundant next to the flag */
    .lang-code { display: none; }
}
