/* =============================================================
 * Betuwe Gif Vrij — shared stylesheet
 * One source of truth for tokens, layout primitives, and the
 * shared chrome (nav, footer, buttons, cards). Page-specific
 * styles still live in their own <style> blocks but should
 * reference the tokens defined here.
 * ============================================================= */

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

:root {
    /* ----- Brand colour palette ----- */
    --green-deep: #1a3a2a;
    --green-mid: #2d5a3f;
    --green-light: #4a8c5e;
    --green-pale: #e8f5e9;
    --earth: #8b6914;
    --earth-light: #f5e6c8;
    --cream: #faf8f2;
    --text: #1a1a1a;
    --text-light: #5a5a5a;
    --red-accent: #c62828;
    --white: #ffffff;
    --orange: #e65100;
    --amber: #f9a825;
    --gold: #b8860b;

    /* ----- Vertical rhythm tokens ----- */
    --space-section-sm: 3rem;
    --space-section-md: 5rem;
    --space-section-lg: 7rem;

    /* ----- Layout tokens ----- */
    --content-narrow: 720px;
    --content-medium: 900px;
    --content-wide: 1100px;

    /* ----- Misc tokens ----- */
    --radius-card: 12px;
    --radius-btn: 8px;
    --shadow-card: 0 1px 3px rgba(0,0,0,0.05);
    --shadow-card-hover: 0 6px 18px rgba(0,0,0,0.08);

    /* ----- Sticky nav height (used for scroll-margin) ----- */
    --nav-height: 56px;
}

/* ===== Base typography ===== */
html {
    scroll-behavior: smooth;
    /* Anchor offsets to clear the sticky nav. */
    scroll-padding-top: var(--nav-height);
}

body {
    font-family: 'Source Serif 4', Georgia, serif;
    color: var(--text);
    background: var(--cream);
    line-height: 1.7;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    font-family: 'Space Grotesk', sans-serif;
    line-height: 1.15;
}

a { color: var(--green-mid); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Generic section anchor compensation so jump-links don't disappear
 * under the sticky nav. Apply via class `.anchor-target`. */
.anchor-target { scroll-margin-top: calc(var(--nav-height) + 1rem); }
:target { scroll-margin-top: calc(var(--nav-height) + 1rem); }

/* ===== Section padding helpers ===== */
.section { padding: var(--space-section-md) 2rem; }
.section--sm { padding: var(--space-section-sm) 2rem; }
.section--lg { padding: var(--space-section-lg) 2rem; }
.section--pale { background: var(--green-pale); }
.section--dark { background: var(--green-deep); color: var(--white); }
.section--cream { background: var(--cream); }
.section--white { background: var(--white); }

/* ===== Navigation ===== */
.nav {
    background: var(--green-deep);
    padding: 0.6rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 3px solid var(--green-light);
    min-height: var(--nav-height);
}

.nav-brand {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--white);
    text-decoration: none;
    padding: 0.5rem 0.25rem;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
}
.nav-brand:hover { text-decoration: none; opacity: 0.9; }

.nav-links {
    display: flex;
    gap: 0.25rem;
    align-items: center;
}

.nav-links a {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255,255,255,0.85);
    text-decoration: none;
    padding: 0.65rem 0.85rem;
    border-radius: 6px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
    transition: background 0.15s, color 0.15s;
}
.nav-links a:hover { color: var(--white); background: rgba(255,255,255,0.08); text-decoration: none; }
.nav-links a.active { color: var(--green-light); font-weight: 700; }

/* ----- Mobile hamburger ----- */
.nav-toggle {
    display: none;
    background: transparent;
    border: 0;
    color: var(--white);
    padding: 0.55rem;
    width: 44px;
    height: 44px;
    cursor: pointer;
    border-radius: 6px;
}
.nav-toggle:hover { background: rgba(255,255,255,0.08); }
.nav-toggle svg { width: 22px; height: 22px; display: block; }

@media (max-width: 760px) {
    .nav-toggle { display: inline-flex; align-items: center; justify-content: center; }
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        align-items: stretch;
        background: var(--green-deep);
        padding: 0.5rem 0.75rem 1rem;
        gap: 0;
        border-bottom: 3px solid var(--green-light);
        box-shadow: 0 8px 20px rgba(0,0,0,0.18);
    }
    .nav-links.open { display: flex; }
    .nav-links a {
        width: 100%;
        padding: 0.85rem 1rem;
        font-size: 1rem;
    }
}

/* ===== Buttons (single source of truth) ===== */
.btn,
.btn-primary,
.btn-secondary,
.btn-link {
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.2;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    padding: 0.85rem 1.6rem;
    border-radius: var(--radius-btn);
    min-height: 44px;
    border: 2px solid transparent;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.1s;
}
.btn:hover,
.btn-primary:hover,
.btn-secondary:hover,
.btn-link:hover { text-decoration: none; }

.btn-primary {
    color: var(--white);
    background: var(--green-mid);
    border-color: var(--green-mid);
}
.btn-primary:hover { background: var(--green-deep); border-color: var(--green-deep); color: var(--white); }
.btn-primary:active { transform: translateY(1px); }

.btn-secondary {
    color: var(--green-deep);
    background: transparent;
    border-color: var(--green-mid);
}
.btn-secondary:hover { background: var(--green-mid); color: var(--white); }

/* On dark backgrounds the secondary outline goes light */
.section--dark .btn-secondary,
.hero-dark .btn-secondary {
    color: var(--white);
    border-color: rgba(255,255,255,0.7);
}
.section--dark .btn-secondary:hover,
.hero-dark .btn-secondary:hover { background: var(--white); color: var(--green-deep); }

.btn-link {
    color: var(--green-mid);
    background: transparent;
    border: 0;
    padding: 0.4rem 0;
    min-height: auto;
    border-bottom: 2px solid var(--green-light);
    border-radius: 0;
}
.btn-link:hover { color: var(--green-deep); border-bottom-color: var(--green-deep); }

/* ===== Card primitives ===== */
.card {
    background: var(--white);
    border-radius: var(--radius-card);
    padding: 2rem;
    box-shadow: var(--shadow-card);
    border: 1px solid rgba(0,0,0,0.05);
}
.card--hover { transition: transform 0.18s, box-shadow 0.18s; }
.card--hover:hover { transform: translateY(-2px); box-shadow: var(--shadow-card-hover); }

.card-dark {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.12);
    border-radius: var(--radius-card);
    padding: 1.75rem;
}

/* ===== Section labels (eyebrow) ===== */
.section-label {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--green-light);
    margin-bottom: 1rem;
    display: inline-block;
}
.section--dark .section-label { color: var(--green-light); }

/* ===== Icons ===== */
.icon {
    width: 1.5em;
    height: 1.5em;
    flex-shrink: 0;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.75;
    stroke-linecap: round;
    stroke-linejoin: round;
    display: inline-block;
    vertical-align: middle;
}
.icon-tile {
    width: 44px;
    height: 44px;
    min-width: 44px;
    border-radius: 10px;
    background: var(--green-pale);
    color: var(--green-mid);
    display: inline-flex;
    align-items: center;
    justify-content: center;
}
.icon-tile .icon { width: 22px; height: 22px; }
.icon-tile--dark { background: rgba(255,255,255,0.08); color: var(--green-light); }
.icon-tile--earth { background: var(--earth-light); color: var(--earth); }

/* ===== Footer ===== */
.site-footer {
    background: var(--green-deep);
    color: rgba(255,255,255,0.75);
    padding: 3rem 1.5rem 2rem;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 0.9rem;
}
.site-footer-inner {
    max-width: var(--content-wide);
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: 2rem;
    align-items: start;
}
.site-footer h4 {
    font-size: 0.78rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--green-light);
    margin-bottom: 0.85rem;
    font-weight: 700;
}
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 0.5rem; }
.site-footer a {
    color: rgba(255,255,255,0.9);
    text-decoration: none;
    padding: 0.25rem 0;
    display: inline-block;
}
.site-footer a:hover { color: var(--white); text-decoration: underline; }
.site-footer .footer-brand {
    font-weight: 700;
    color: var(--white);
    font-size: 1rem;
    margin-bottom: 0.5rem;
    display: block;
}
.site-footer .footer-blurb { color: rgba(255,255,255,0.65); line-height: 1.6; max-width: 32ch; }
.site-footer-bottom {
    max-width: var(--content-wide);
    margin: 2.5rem auto 0;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.12);
    font-size: 0.78rem;
    color: rgba(255,255,255,0.55);
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.site-footer-soon { color: rgba(255,255,255,0.45); font-style: italic; }

@media (max-width: 720px) {
    .site-footer-inner { grid-template-columns: 1fr; gap: 1.75rem; }
}

/* ===== Visually-hidden helper ===== */
.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0,0,0,0);
    white-space: nowrap; border: 0;
}

/* ===== Reduced motion ===== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; animation: none !important; }
    html { scroll-behavior: auto; }
}
