/* ==========================================================================
   Lower Palisades Restoration Project
   ========================================================================== */

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

/* --- Tokens --------------------------------------------------------------- */
:root {
    --ink: #08190f;
    --forest: #0f2d1e;
    --moss: #2f6b45;
    --fern: #4e9a68;
    --sage: #9dbba4;
    --sage-light: #dce9df;
    --bone: #ece7db;
    --paper: #f8f6f0;
    --white: #ffffff;
    --clay: #c2542a;
    --clay-bright: #e0703c;
    --gold: #d9a441;

    --text: #1d2b22;
    --text-muted: #5c6b61;
    --text-invert: #f1efe7;
    --text-invert-muted: #b3c4b7;

    --rule: rgba(15, 45, 30, 0.14);
    --rule-invert: rgba(241, 239, 231, 0.18);

    --font-display: "Fraunces", "Iowan Old Style", Georgia, serif;
    --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

    --shell: 1240px;
    --gutter: clamp(1.25rem, 4vw, 3.5rem);
    --band: clamp(4.5rem, 9vw, 8.5rem);
    --nav-h: 74px;

    --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* --- Base ----------------------------------------------------------------- */
html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--nav-h);
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.68;
    color: var(--text);
    background: var(--paper);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

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

a {
    color: inherit;
}

h1,
h2,
h3,
h4 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.08;
    letter-spacing: -0.015em;
    text-wrap: balance;
}

::selection {
    background: var(--gold);
    color: var(--ink);
}

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

/* --- Layout --------------------------------------------------------------- */
.shell {
    width: 100%;
    max-width: var(--shell);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.shell-narrow {
    max-width: 860px;
}

.band {
    padding-block: var(--band);
    position: relative;
}

.band--paper {
    background: var(--paper);
}

.band--bone {
    background: var(--bone);
}

.band--sage {
    background: var(--sage-light);
}

.band--forest {
    background: var(--forest);
    color: var(--text-invert);
}

.band--ink {
    background: var(--ink);
    color: var(--text-invert);
}

.band--forest h2,
.band--forest h3,
.band--ink h2,
.band--ink h3 {
    color: var(--white);
}

.band--forest a:not(.btn),
.band--ink a:not(.btn) {
    color: var(--sage);
}

.band--forest a:not(.btn):hover,
.band--ink a:not(.btn):hover {
    color: var(--white);
}

/* --- Section headers ------------------------------------------------------ */
.eyebrow {
    display: flex;
    align-items: center;
    gap: 0.9rem;
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--moss);
    margin-bottom: 1.35rem;
}

.band--forest .eyebrow,
.band--ink .eyebrow {
    color: var(--sage);
}

.eyebrow::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--rule);
}

.band--forest .eyebrow::after,
.band--ink .eyebrow::after {
    background: var(--rule-invert);
}

.band-title {
    font-size: clamp(2.1rem, 5vw, 3.4rem);
    max-width: 20ch;
}

.band-intro {
    margin-top: 1.5rem;
    max-width: 62ch;
    font-size: clamp(1.05rem, 1.6vw, 1.2rem);
    color: var(--text-muted);
}

.band--forest .band-intro,
.band--ink .band-intro {
    color: var(--text-invert-muted);
}

.band-head {
    margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

/* --- Buttons -------------------------------------------------------------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.95rem 1.9rem;
    font-family: var(--font-body);
    font-size: 0.86rem;
    font-weight: 650;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    text-decoration: none;
    border: 1.5px solid transparent;
    border-radius: 999px;
    cursor: pointer;
    transition: transform 0.25s var(--ease), background 0.25s var(--ease),
        color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.btn:hover {
    transform: translateY(-2px);
}

.btn--solid {
    background: var(--clay);
    color: var(--white);
}

.btn--solid:hover {
    background: var(--clay-bright);
}

.btn--leaf {
    background: var(--fern);
    color: var(--ink);
}

.btn--leaf:hover {
    background: var(--sage);
}

.btn--ghost {
    border-color: currentColor;
    color: inherit;
    background: transparent;
}

.btn--ghost:hover {
    background: currentColor;
    color: var(--forest);
}

.band--paper .btn--ghost:hover,
.band--bone .btn--ghost:hover {
    color: var(--paper);
}

.btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    margin-top: 2.25rem;
}

/* --- Navigation ----------------------------------------------------------- */
.masthead {
    position: fixed;
    inset: 0 0 auto 0;
    z-index: 1000;
    background: transparent;
    transition: background 0.35s var(--ease), box-shadow 0.35s var(--ease);
}

.masthead.is-stuck,
.masthead-solid .masthead {
    background: rgba(8, 25, 15, 0.94);
    backdrop-filter: blur(14px);
    box-shadow: 0 1px 0 var(--rule-invert);
}

.masthead-inner {
    max-width: var(--shell);
    margin-inline: auto;
    padding: 0 var(--gutter);
    height: var(--nav-h);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.7rem;
    text-decoration: none;
    color: var(--white);
    flex-shrink: 0;
}

.brand img {
    height: 38px;
    width: auto;
}

.brand-text {
    line-height: 1.1;
}

.brand-name {
    font-family: var(--font-display);
    font-size: clamp(0.72rem, 1.5vw, 1.02rem);
    font-weight: 600;
    letter-spacing: -0.01em;
    white-space: nowrap;
}

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

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    list-style: none;
}

.nav-links a {
    position: relative;
    color: var(--text-invert);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    padding-block: 0.4rem;
    transition: color 0.25s var(--ease);
}

.nav-links a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 2px;
    background: var(--gold);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s var(--ease);
}

.nav-links a:hover,
.nav-links a.is-active {
    color: var(--white);
}

.nav-links a.is-active::after,
.nav-links a:hover::after {
    transform: scaleX(1);
}

.nav-cta {
    padding: 0.6rem 1.35rem;
    font-size: 0.74rem;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 0;
    background: none;
    border: none;
    cursor: pointer;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--white);
    transition: transform 0.3s var(--ease), opacity 0.2s var(--ease);
}

.nav-toggle.is-open span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.is-open span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.is-open span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* --- Hero ----------------------------------------------------------------- */
.hero {
    position: relative;
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
    background: var(--ink);
}

.hero-media {
    position: absolute;
    inset: 0;
}

.hero-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.06);
    animation: heroDrift 24s var(--ease) forwards;
}

@keyframes heroDrift {
    to {
        transform: scale(1);
    }
}

.hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
            180deg,
            rgba(8, 25, 15, 0.72) 0%,
            rgba(8, 25, 15, 0.25) 32%,
            rgba(8, 25, 15, 0.82) 78%,
            rgba(8, 25, 15, 0.97) 100%
        );
    pointer-events: none;
}

.hero-inner {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: var(--shell);
    margin-inline: auto;
    padding: calc(var(--nav-h) + 4rem) var(--gutter) clamp(3.5rem, 7vw, 6rem);
    color: var(--text-invert);
}

.hero-tag {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.26em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 1.6rem;
}

.hero h1 {
    font-size: clamp(2.6rem, 8.2vw, 6.4rem);
    color: var(--white);
    max-width: 15ch;
}

.hero h1 em {
    font-style: italic;
    color: var(--sage);
}

.hero-lede {
    margin-top: 1.75rem;
    max-width: 58ch;
    font-size: clamp(1.05rem, 1.9vw, 1.3rem);
    color: var(--text-invert-muted);
}

.hero-scroll {
    margin-top: clamp(2.5rem, 5vw, 4rem);
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.7rem;
    letter-spacing: 0.22em;
    text-transform: uppercase;
    color: var(--sage);
    text-decoration: none;
}

.hero-scroll span {
    display: inline-block;
    animation: nudge 2.2s var(--ease) infinite;
}

@keyframes nudge {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(5px); }
}

/* --- Mission -------------------------------------------------------------- */
.mission-statement {
    font-family: var(--font-display);
    font-size: clamp(1.7rem, 4.1vw, 3rem);
    line-height: 1.22;
    letter-spacing: -0.02em;
    max-width: 24ch;
}

.mission-body {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: clamp(2rem, 5vw, 4.5rem);
    align-items: start;
    margin-top: clamp(2rem, 4vw, 3rem);
}

.mission-body p + p {
    margin-top: 1.15rem;
}

.mission-body .support {
    color: var(--text-muted);
}

.history-summary {
    max-width: 62rem;
    margin-top: clamp(2rem, 4vw, 3rem);
}

/* --- Stats ---------------------------------------------------------------- */
.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 1px;
    background: var(--rule-invert);
    border-block: 1px solid var(--rule-invert);
}

.stat {
    background: var(--forest);
    padding: clamp(1.75rem, 3.5vw, 2.75rem) clamp(1.25rem, 2.5vw, 2rem);
}

.stat-figure {
    font-family: var(--font-display);
    font-size: clamp(2.3rem, 5vw, 3.4rem);
    line-height: 1;
    color: var(--gold);
    letter-spacing: -0.03em;
}

.stat-label {
    margin-top: 0.7rem;
    font-size: 0.9rem;
    color: var(--text-invert-muted);
}

/* --- Generic card grid ---------------------------------------------------- */
.grid {
    display: grid;
    gap: clamp(1.25rem, 2.5vw, 2rem);
}

.grid--3 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid--2 {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.card {
    background: var(--white);
    border: 1px solid var(--rule);
    border-radius: 4px;
    padding: clamp(1.6rem, 3vw, 2.35rem);
    transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 18px 40px -24px rgba(8, 25, 15, 0.5);
}

.card h3 {
    font-size: 1.3rem;
    margin-bottom: 0.75rem;
}

.card p {
    color: var(--text-muted);
    font-size: 0.98rem;
}

.card-index {
    display: block;
    font-family: var(--font-display);
    font-size: 2.4rem;
    line-height: 1;
    color: var(--clay);
    margin-bottom: 1.1rem;
}

/* --- Issues --------------------------------------------------------------- */
.current-issues-layout {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(320px, 1.2fr);
    gap: clamp(3rem, 7vw, 7rem);
    align-items: end;
}

.issue-list {
    border-top: 1px solid var(--rule-invert);
}

.issue-detail {
    border-bottom: 1px solid var(--rule-invert);
}

.issue-detail summary {
    display: grid;
    grid-template-columns: 3rem minmax(0, 1fr) 2rem;
    gap: 1rem;
    align-items: baseline;
    padding: 1.3rem 0;
    cursor: pointer;
    list-style: none;
}

.issue-detail summary::-webkit-details-marker {
    display: none;
}

.issue-number {
    color: var(--sage);
    font-size: 0.7rem;
    font-weight: 650;
    letter-spacing: 0.12em;
}

.issue-detail summary strong {
    color: var(--white);
    font-family: var(--font-display);
    font-size: clamp(1.25rem, 2.2vw, 1.65rem);
    font-weight: 550;
    line-height: 1.2;
}

.issue-toggle {
    position: relative;
    width: 1.3rem;
    height: 1.3rem;
    align-self: center;
}

.issue-toggle::before,
.issue-toggle::after {
    content: "";
    position: absolute;
    inset: 50% auto auto 50%;
    width: 1rem;
    height: 1px;
    background: var(--gold);
    transform: translate(-50%, -50%);
}

.issue-toggle::after {
    transform: translate(-50%, -50%) rotate(90deg);
    transition: transform 180ms var(--ease);
}

.issue-detail[open] .issue-toggle::after {
    transform: translate(-50%, -50%) rotate(0);
}

.issue-content {
    padding: 0 0 1.5rem 4rem;
    color: var(--text-invert-muted);
}

.issue-content--media {
    display: grid;
    grid-template-columns: minmax(0, 0.8fr) minmax(220px, 1.2fr);
    gap: 1.5rem;
    align-items: start;
}

.issue-content figure {
    overflow: hidden;
    border-radius: 4px;
}

.issue-content img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.issue-content figcaption {
    padding-top: 0.65rem;
    color: var(--sage);
    font-size: 0.78rem;
}

.issue-content figcaption small {
    display: block;
    color: var(--text-invert-muted);
}

.issue-content figcaption a {
    color: var(--sage);
}

.invasive-gallery {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
    margin-top: 1.25rem;
}

.issue-list-wrap > .btn-row {
    margin-top: 1.5rem;
}

.plan-steps {
    list-style: none;
    counter-reset: plan-step;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    background: var(--rule-invert);
}

.plan-step {
    counter-increment: plan-step;
    padding: clamp(1.6rem, 3vw, 2.5rem);
    background: var(--bone);
}

.plan-step::before {
    content: "0" counter(plan-step);
    display: block;
    margin-bottom: 1.5rem;
    color: var(--clay);
    font-family: var(--font-display);
    font-size: 2rem;
}

.plan-step h3 {
    margin-bottom: 0.8rem;
    color: var(--text);
}

.plan-step p {
    color: var(--text-muted);
}

.organization-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1px;
    background: var(--rule);
}

.organization {
    display: block;
    padding: clamp(1.4rem, 3vw, 2rem);
    background: var(--paper);
    text-decoration: none;
}

.organization:hover {
    background: var(--white);
}

.organization strong {
    display: block;
    margin-bottom: 0.35rem;
    color: var(--forest);
    font-family: var(--font-display);
    font-size: 1.15rem;
}

.organization span {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.issue-icon {
    font-size: 1.6rem;
    display: block;
    margin-bottom: 0.9rem;
}

/* --- News ----------------------------------------------------------------- */
.news-list {
    border-top: 1px solid var(--rule);
}

.news-item {
    display: grid;
    grid-template-columns: 190px 1fr auto;
    gap: clamp(1rem, 3vw, 2.5rem);
    align-items: baseline;
    padding-block: clamp(1.6rem, 3vw, 2.4rem);
    border-bottom: 1px solid var(--rule);
    text-decoration: none;
    transition: padding-inline 0.3s var(--ease);
}

a.news-item:hover {
    padding-inline: 0.85rem;
    background: rgba(255, 255, 255, 0.55);
}

.news-meta {
    font-size: 0.74rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--moss);
}

.news-meta .news-kind {
    display: block;
    color: var(--clay);
    margin-bottom: 0.35rem;
}

.news-item h3 {
    font-size: clamp(1.2rem, 2.2vw, 1.6rem);
}

.news-item p {
    margin-top: 0.6rem;
    color: var(--text-muted);
    font-size: 0.98rem;
    max-width: 62ch;
}

.news-arrow {
    color: var(--clay);
    font-size: 1.3rem;
    transition: transform 0.3s var(--ease);
}

a.news-item:hover .news-arrow {
    transform: translateX(6px);
}

/* --- Video ---------------------------------------------------------------- */
.video-frame {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 4px;
    border: 1px solid var(--rule-invert);
    background: #000;
}

.video-frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

/* --- Timeline (desktop: horizontal rail) ---------------------------------- */
.timeline {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 0;
    border-top: 2px solid var(--rule-invert);
}

.timeline-item {
    padding: 2rem clamp(1rem, 2vw, 1.75rem) 0 0;
    position: relative;
}

.timeline-item::before {
    content: "";
    position: absolute;
    top: -7px;
    left: 0;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--gold);
}

.timeline-date {
    display: block;
    font-size: 0.72rem;
    font-weight: 650;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--gold);
    margin-bottom: 0.75rem;
}

.timeline-item p {
    color: var(--text-invert-muted);
    font-size: 0.96rem;
}

.history-banner {
    margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.history-banner img {
    width: 100%;
    aspect-ratio: 21 / 9;
    object-fit: cover;
    border-radius: 4px;
}

/* --- Split (text + image) ------------------------------------------------- */
.split {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(2rem, 5vw, 4.5rem);
    align-items: center;
}

.split--reverse .split-media {
    order: -1;
}

.split-text p + p {
    margin-top: 1.1rem;
}

.split-media img {
    width: 100%;
    border-radius: 4px;
}

.mission-context {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 1fr);
    grid-template-areas:
        "first map"
        "second map";
    gap: 1.1rem clamp(2.5rem, 6vw, 6rem);
    align-items: center;
}

.mission-copy--first {
    grid-area: first;
}

.mission-copy--second {
    grid-area: second;
}

.mission-map {
    grid-area: map;
}

.mission-map img {
    width: 100%;
    border-radius: 4px;
}

.split h3 {
    font-size: clamp(1.5rem, 3vw, 2.1rem);
    margin-bottom: 1.1rem;
}

/* --- Figures / galleries -------------------------------------------------- */
.figure-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: clamp(1.25rem, 2.5vw, 2rem);
}

figure img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border-radius: 4px;
}

figcaption {
    margin-top: 0.85rem;
    font-size: 0.88rem;
    color: var(--text-muted);
}

.band--forest figcaption,
.band--ink figcaption {
    color: var(--text-invert-muted);
}

figcaption small {
    display: block;
    opacity: 0.75;
    font-size: 0.8rem;
    margin-top: 0.15rem;
}

/* --- Personnel ------------------------------------------------------------ */
.person {
    display: grid;
    grid-template-columns: 380px 1fr;
    gap: clamp(2rem, 5vw, 4rem);
    align-items: start;
}

.person-photo img {
    width: 100%;
    aspect-ratio: 4 / 5;
    object-fit: cover;
    border-radius: 4px;
}

.person-name {
    font-size: clamp(1.9rem, 4vw, 2.7rem);
}

.person-role {
    margin-top: 0.55rem;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--clay);
}

.person-note {
    margin-top: 1.1rem;
    color: var(--text-muted);
}

.cred-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
    gap: clamp(1.5rem, 3vw, 2.25rem);
    margin-top: 2.25rem;
    padding-top: 2rem;
    border-top: 1px solid var(--rule);
}

.cred h4 {
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--moss);
    margin-bottom: 0.85rem;
}

.cred ul {
    list-style: none;
}

.cred li {
    font-size: 0.94rem;
    padding-block: 0.32rem;
    color: var(--text-muted);
}

/* --- Events --------------------------------------------------------------- */
.event-popup {
    position: fixed;
    top: calc(var(--nav-h) + 0.75rem);
    right: clamp(1rem, 3vw, 2rem);
    z-index: 900;
    width: min(340px, calc(100vw - 2rem));
    padding: 1.35rem 3.25rem 1.35rem 1.5rem;
    color: var(--text);
    background: var(--paper);
    border: 1px solid var(--rule);
    border-left: 5px solid var(--clay);
    border-radius: 10px;
    box-shadow: 0 14px 40px rgba(8, 25, 15, 0.24);
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 180ms var(--ease), transform 180ms var(--ease);
}

.event-popup[hidden] {
    display: none;
}

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

.event-popup-label {
    margin-bottom: 0.45rem;
    color: var(--clay);
    font-size: 0.68rem;
    font-weight: 650;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.event-popup h2 {
    font-size: 1.65rem;
}

.event-popup-details {
    display: grid;
    gap: 0.15rem;
    margin: 0.75rem 0 1rem;
    color: var(--text-muted);
    font-size: 0.86rem;
    line-height: 1.45;
}

.event-popup-close {
    position: absolute;
    top: 0.85rem;
    right: 0.85rem;
    width: 32px;
    height: 32px;
    border: 0;
    color: var(--text-muted);
    background: transparent;
    font: 400 1.6rem/1 var(--font-body);
    cursor: pointer;
}

.event-popup-close:hover {
    color: var(--clay);
}

.event-popup-link {
    color: var(--moss);
    font-size: 0.78rem;
    font-weight: 650;
    letter-spacing: 0.07em;
    text-transform: uppercase;
}

.calendar-layout {
    display: grid;
    gap: clamp(1.5rem, 3vw, 2.5rem);
    align-items: stretch;
}

.events-page {
    padding-top: var(--nav-h);
}

.events-title {
    margin-bottom: clamp(2rem, 4vw, 3rem);
    font-size: clamp(2.5rem, 6vw, 4.5rem);
}

.calendar {
    padding: clamp(1rem, 2.5vw, 1.75rem);
    background: var(--paper);
    border: 1px solid var(--rule);
    border-radius: 4px;
}

.calendar-header {
    display: grid;
    grid-template-columns: 40px 1fr 40px;
    gap: 0.75rem;
    align-items: center;
    margin-bottom: 1.25rem;
}

.calendar-month {
    text-align: center;
    font-size: clamp(1.5rem, 3vw, 2rem);
}

.calendar-nav {
    width: 40px;
    height: 40px;
    border: 1px solid var(--rule);
    border-radius: 50%;
    color: var(--forest);
    background: transparent;
    cursor: pointer;
}

.calendar-nav:hover {
    color: var(--paper);
    background: var(--moss);
    border-color: var(--moss);
}

.calendar-weekdays,
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
}

.calendar-weekdays {
    padding-bottom: 0.55rem;
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 650;
    letter-spacing: 0.08em;
    text-align: center;
    text-transform: uppercase;
}

.calendar-day {
    position: relative;
    min-height: clamp(88px, 10vw, 132px);
    padding: 0.55rem;
    border: 0;
    border-top: 1px solid var(--rule);
    color: var(--text);
    background: transparent;
    font: inherit;
    text-align: left;
}

.calendar-day-number {
    display: block;
    font-weight: 650;
}

button.calendar-day {
    cursor: pointer;
}

button.calendar-day:hover {
    color: var(--forest);
    background: rgba(87, 122, 84, 0.12);
}

.calendar-day.is-outside {
    color: rgba(47, 52, 45, 0.35);
}

.calendar-day.has-event::after {
    content: "";
    position: absolute;
    right: 0.55rem;
    bottom: 0.55rem;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--clay);
}

.calendar-day.has-event {
    font-weight: 700;
}

.event-card-list {
    display: grid;
    gap: 1rem;
    margin-top: clamp(2rem, 4vw, 3rem);
}

.event-card {
    display: grid;
    grid-template-columns: minmax(150px, 0.35fr) 1fr auto;
    gap: clamp(1rem, 3vw, 2rem);
    align-items: center;
    padding: clamp(1.25rem, 3vw, 2rem);
    color: var(--text);
    background: var(--paper);
    border: 1px solid var(--rule);
    border-left: 5px solid var(--clay);
    border-radius: 4px;
    text-decoration: none;
    scroll-margin-top: calc(var(--nav-h) + 2rem);
}

.event-card:hover,
.event-card:focus {
    background: var(--white);
    box-shadow: 0 10px 30px rgba(8, 25, 15, 0.12);
}

.event-card-date {
    color: var(--clay);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.event-card h3 {
    font-size: clamp(1.45rem, 3vw, 2rem);
}

.event-card-location {
    margin-top: 0.35rem;
    color: var(--moss);
    font-weight: 650;
}

.event-card .event-desc {
    margin-top: 0.75rem;
    color: var(--text-muted);
}

.event-card-arrow {
    color: var(--moss);
    font-size: 1.4rem;
}

/* --- Signup / Join -------------------------------------------------------- */
.signup {
    margin-top: 2rem;
    max-width: 540px;
}

.signup-label {
    display: block;
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--sage);
    margin-bottom: 0.6rem;
}

.signup-row {
    display: flex;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.signup input[type="email"] {
    flex: 1 1 240px;
    min-width: 0;
    padding: 0.8rem 1rem;
    font-family: inherit;
    font-size: 1rem;
    color: var(--white);
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid var(--rule-invert);
    border-radius: 4px;
    transition: border-color 0.25s var(--ease), background 0.25s var(--ease);
}

.signup input[type="email"]::placeholder {
    color: var(--text-invert-muted);
}

.signup input[type="email"]:focus {
    border-color: var(--gold);
    background: rgba(255, 255, 255, 0.12);
    outline: none;
}

.signup .btn {
    border-radius: 4px;
    padding: 0.8rem 1.6rem;
}

.signup-note {
    margin-top: 1.15rem;
    font-size: 0.9rem;
    color: var(--text-invert-muted);
}

.email-contact {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    white-space: nowrap;
}

.email-contact .resource-group,
.email-contact .signup-note {
    margin: 1.15rem 0 0;
}

.toast {
    position: fixed;
    z-index: 1200;
    right: var(--gutter);
    bottom: var(--gutter);
    max-width: min(24rem, calc(100vw - 2 * var(--gutter)));
    padding: 1rem 1.25rem;
    border-left: 4px solid var(--gold);
    border-radius: 4px;
    color: var(--white);
    background: var(--moss);
    box-shadow: 0 1rem 2.5rem rgba(8, 25, 15, 0.28);
    opacity: 0;
    transform: translateY(0.75rem);
    transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

.toast[hidden] {
    display: none;
}

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

.hp {
    position: absolute;
    left: -5000px;
}

.nav-locked {
    overflow: hidden;
}

/* --- Partners ------------------------------------------------------------- */
.partner-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1px;
    background: var(--rule);
    border: 1px solid var(--rule);
    border-radius: 4px;
    overflow: hidden;
}

.partner {
    background: var(--paper);
    padding: clamp(1.5rem, 3vw, 2.1rem);
    text-decoration: none;
    display: block;
    transition: background 0.25s var(--ease);
}

.partner:hover {
    background: var(--white);
}

.partner-name {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 600;
    line-height: 1.2;
}

.partner-kind {
    display: block;
    margin-top: 0.6rem;
    font-size: 0.78rem;
    color: var(--text-muted);
}

/* --- Socials / reading ---------------------------------------------------- */
.link-list {
    list-style: none;
    border-top: 1px solid var(--rule-invert);
}

.link-list li {
    border-bottom: 1px solid var(--rule-invert);
}

.link-list a {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1.5rem;
    padding-block: 1.15rem;
    text-decoration: none;
    font-size: clamp(1rem, 1.8vw, 1.15rem);
    transition: padding-inline 0.3s var(--ease);
}

.link-list a:hover {
    padding-inline: 0.7rem;
}

.link-list .link-kind {
    flex-shrink: 0;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: var(--gold);
}

.resource-group {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--sage);
    margin-bottom: 0.9rem;
}

.band--sage .resource-group {
    color: var(--moss);
}

.band--sage .link-list {
    border-top-color: var(--rule);
}

.band--sage .link-list li {
    border-bottom-color: var(--rule);
}

.band--sage .link-list .link-kind {
    color: var(--clay);
}

.resource-group + .link-list {
    margin-bottom: clamp(2.25rem, 4vw, 3rem);
}

.resource-group + .link-list:last-child {
    margin-bottom: 0;
}

.social-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: clamp(2rem, 4vw, 3rem);
}

.social-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.35rem 0;
    border-bottom: 1px solid transparent;
    color: var(--text-invert-muted);
    font-size: 0.88rem;
    letter-spacing: 0.05em;
    text-decoration: none;
    transition: border-color 0.25s var(--ease), color 0.25s var(--ease);
}

.social-chip svg {
    width: 1.45rem;
    height: 1.45rem;
    fill: currentColor;
}

.social-chip:hover {
    border-color: var(--gold);
    color: var(--white);
}

.footer-socials {
    margin: 0;
    padding-top: 1.75rem;
}

/* --- Contact -------------------------------------------------------------- */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: clamp(1.5rem, 3vw, 2.5rem);
}

.contact-block h3 {
    font-family: var(--font-body);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--moss);
    margin-bottom: 0.8rem;
}

.contact-block p,
.contact-block a {
    font-size: 1.02rem;
}

.contact-lede {
    font-family: var(--font-display);
    font-size: clamp(1.5rem, 3.2vw, 2.2rem);
    line-height: 1.25;
    max-width: 22ch;
    margin-bottom: clamp(2rem, 4vw, 3rem);
}

/* --- Footer --------------------------------------------------------------- */
.site-footer {
    background: var(--ink);
    color: var(--text-invert-muted);
    padding-block: clamp(3rem, 6vw, 4.5rem) 2rem;
}

.footer-top {
    display: grid;
    grid-template-columns: 1.4fr 1fr 1fr;
    gap: clamp(2rem, 4vw, 3.5rem);
    padding-bottom: 2.5rem;
    border-bottom: 1px solid var(--rule-invert);
}

.footer-mark {
    font-family: var(--font-display);
    font-size: 1.5rem;
    color: var(--white);
    margin-bottom: 0.9rem;
}

.footer-col h4 {
    font-family: var(--font-body);
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--sage);
    margin-bottom: 1rem;
}

.footer-col ul {
    list-style: none;
}

.footer-col li {
    padding-block: 0.28rem;
}

.footer-col a {
    text-decoration: none;
    font-size: 0.92rem;
    transition: color 0.25s var(--ease);
}

.footer-col a:hover {
    color: var(--white);
}

.footer-bottom {
    padding-top: 1.75rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 2rem;
    justify-content: space-between;
    font-size: 0.82rem;
}

/* --- Reveal on scroll ----------------------------------------------------- */
.reveal {
    opacity: 0;
    transform: translateY(26px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

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


/* ==========================================================================
   SUBPAGE HEADER
   ========================================================================== */

.page-hero {
    background: var(--ink);
    color: var(--paper);
    padding: calc(var(--nav-h) + clamp(3.5rem, 8vw, 7rem)) 0 clamp(3rem, 6vw, 5rem);
}

.page-hero .shell {
    max-width: 62rem;
}

.page-hero--centered {
    text-align: center;
}

.page-hero .eyebrow {
    color: var(--sage);
}

.page-title {
    font-family: var(--font-display);
    font-weight: 500;
    font-size: clamp(2.4rem, 6vw, 4.4rem);
    line-height: 1.06;
    margin: 0.4rem 0 1.25rem;
}

.page-lede {
    max-width: 46ch;
    font-size: clamp(1.02rem, 1.6vw, 1.24rem);
    line-height: 1.65;
    color: var(--sage);
}


/* ==========================================================================
   RESPONSIVE — device tiers
   --------------------------------------------------------------------------
   >= 1025px      desktop   full horizontal nav, multi-column, horizontal timeline
   769 - 1024px   tablet    burger nav, two-up grids, vertical timeline
   481 - 768px    mobile    single column, stacked meta, full-bleed rhythm
   <= 480px       phone     tightened type, full-width actions
   ========================================================================== */

/* --- Desktop: keep the nav from crowding at the low end ------------------- */
@media (min-width: 1025px) and (max-width: 1160px) {
    .nav {
        gap: 1.1rem;
    }

    .nav-links {
        gap: 1.05rem;
    }

    .nav-links a {
        font-size: 0.78rem;
    }

    .nav-cta {
        padding: 0.55rem 1.1rem;
        font-size: 0.7rem;
    }
}

/* --- Tablet and below ----------------------------------------------------- */
@media (max-width: 1024px) {
    .nav-toggle {
        display: flex;
    }

    .nav {
        position: fixed;
        inset: var(--nav-h) 0 auto 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: rgba(8, 25, 15, 0.985);
        backdrop-filter: blur(14px);
        padding: 1.25rem var(--gutter) 2rem;
        border-top: 1px solid var(--rule-invert);
        transform: translateY(-12px);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.28s var(--ease), transform 0.28s var(--ease);
        max-height: calc(100svh - var(--nav-h));
        overflow-y: auto;
        overscroll-behavior: contain;
    }

    .nav.is-open {
        transform: none;
        opacity: 1;
        pointer-events: auto;
    }

    .nav-links {
        flex-direction: column;
        align-items: stretch;
        gap: 0;
    }

    .nav-links a {
        display: block;
        padding-block: 0.95rem;
        font-size: 1rem;
        border-bottom: 1px solid var(--rule-invert);
    }

    .nav-links a::after {
        display: none;
    }

    .nav-links a.is-active {
        color: var(--gold);
    }

    .nav-cta {
        margin-top: 1.35rem;
        justify-content: center;
        font-size: 0.8rem;
        padding: 0.85rem 1.5rem;
    }

    /* Two-column blocks collapse */
    .mission-body,
    .current-issues-layout,
    .split,
    .person {
        grid-template-columns: 1fr;
    }

    .split--reverse .split-media {
        order: 0;
    }

    .person-photo img {
        aspect-ratio: 16 / 10;
    }

    .stats {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-top {
        grid-template-columns: 1fr 1fr;
    }

    .footer-intro {
        grid-column: 1 / -1;
    }

    .hero {
        min-height: 88vh;
        min-height: 88svh;
    }

    /* Timeline flips from a horizontal rail to a vertical one */
    .timeline {
        grid-template-columns: 1fr;
        border-top: 0;
        border-left: 2px solid var(--rule-invert);
        padding-left: 1.85rem;
    }

    .timeline-item {
        padding: 0 0 2rem 0;
    }

    .timeline-item:last-child {
        padding-bottom: 0;
    }

    .timeline-item::before {
        top: 5px;
        left: calc(-1.85rem - 7px);
    }
}

/* --- Mobile --------------------------------------------------------------- */
@media (max-width: 768px) {
    :root {
        --nav-h: 64px;
        --band: clamp(3.25rem, 11vw, 4.75rem);
    }

    .brand img {
        height: 32px;
    }

    .hero {
        min-height: 92vh;
        min-height: 92svh;
    }

    .hero-media img {
        object-position: right center;
        transform: none;
    }

    .hero h1 {
        font-size: clamp(2.35rem, 10.5vw, 3.4rem);
    }

    .hero-lede {
        font-size: 1.02rem;
    }

    .hero-tag {
        font-size: 0.65rem;
        letter-spacing: 0.18em;
        margin-bottom: 1.1rem;
    }

    .hero-scroll {
        display: none;
    }

    .mission-statement {
        max-width: none;
    }

    .band-title {
        max-width: none;
    }

    /* News: meta stacks above the headline, arrow is redundant on touch */
    .news-item {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .news-arrow {
        display: none;
    }

    .event-popup {
        top: calc(var(--nav-h) + 0.65rem);
        right: 0.5rem;
        bottom: auto;
        left: 0.5rem;
        display: grid;
        grid-template-columns: 1fr auto;
        column-gap: 0.75rem;
        width: auto;
        padding: 0.7rem 2.5rem 0.7rem 0.9rem;
        border-left-width: 4px;
        border-radius: 7px;
    }

    .event-popup-label,
    .event-popup h2 {
        grid-column: 1 / -1;
    }

    .event-popup-label {
        margin-bottom: 0.15rem;
        font-size: 0.6rem;
        line-height: 1.2;
    }

    .event-popup h2 {
        font-size: 1.05rem;
        line-height: 1.15;
    }

    .event-popup-details {
        display: block;
        margin: 0.3rem 0 0;
        font-size: 0.74rem;
        line-height: 1.25;
    }

    #eventPopupLocation {
        display: none;
    }

    .event-popup-link {
        align-self: end;
        font-size: 0.68rem;
        line-height: 1.25;
        white-space: nowrap;
    }

    .event-popup-close {
        top: 0.35rem;
        right: 0.35rem;
        width: 28px;
        height: 28px;
        font-size: 1.35rem;
    }

    .calendar-day {
        min-height: 58px;
        padding: 0.4rem;
        font-size: 0.82rem;
    }

    .event-card {
        grid-template-columns: 1fr auto;
    }

    .event-card-date {
        grid-column: 1 / -1;
    }

    .calendar-day.has-event::after {
        right: 0.4rem;
        bottom: 0.4rem;
        width: 7px;
        height: 7px;
    }

    .issue-content--media {
        grid-template-columns: 1fr;
    }

    .invasive-gallery {
        grid-template-columns: 1fr;
    }

    .cred-grid {
        grid-template-columns: repeat(auto-fit, minmax(215px, 1fr));
    }

    .partner-grid {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    }

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

    .footer-top {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    /* Link rows stack label over title */
    .link-list a {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.3rem;
        padding-block: 1rem;
    }

    .link-list .link-kind {
        order: -1;
    }

    /* Signup stacks into a conventional full-width form */
    .signup {
        max-width: none;
    }

    .signup-row {
        flex-direction: column;
        gap: 0.55rem;
    }

    .signup input[type="email"],
    .signup .btn {
        flex: none;
        width: 100%;
        min-height: 48px;
        justify-content: center;
    }

    figure img {
        aspect-ratio: 3 / 2;
    }

    .history-banner img {
        aspect-ratio: 16 / 9;
    }

    .mission-context {
        grid-template-columns: 1fr;
        grid-template-areas:
            "first"
            "map"
            "second";
        gap: 1.5rem;
    }

    .photo-carousel {
        grid-template-columns: 1fr;
        display: grid;
    }

    .photo-carousel figure {
        grid-area: 1 / 1;
        opacity: 0;
        visibility: hidden;
        transition: opacity 1s ease, visibility 1s ease;
    }

    .photo-carousel figure.is-active {
        z-index: 1;
        opacity: 1;
        visibility: visible;
    }

    .split {
        gap: 2rem;
    }
}

/* --- Small phone ---------------------------------------------------------- */
@media (max-width: 480px) {
    .stats,
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .grid--2,
    .grid--3,
    .plan-steps,
    .organization-grid,
    .partner-grid,
    .cred-grid {
        grid-template-columns: 1fr;
    }

    .issue-content {
        padding-left: 0;
    }

    .hero h1 {
        font-size: 2.3rem;
    }

    .band-title {
        font-size: clamp(1.8rem, 8.5vw, 2.3rem);
    }

    .mission-statement {
        font-size: 1.55rem;
    }

    .eyebrow {
        font-size: 0.66rem;
        letter-spacing: 0.16em;
        gap: 0.7rem;
    }

    .btn-row {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-row .btn {
        width: 100%;
        justify-content: center;
    }

    figure img {
        aspect-ratio: 4 / 3;
    }

    .social-row {
        gap: 0.5rem;
    }
}

/* --- Short landscape (phones held sideways) ------------------------------- */
@media (orientation: landscape) and (max-height: 560px) {
    .hero {
        min-height: auto;
    }

    .hero-inner {
        padding-block: calc(var(--nav-h) + 2.25rem) 2.75rem;
    }

    .hero-scroll {
        display: none;
    }

    .nav {
        max-height: calc(100svh - var(--nav-h));
    }
}

/* --- Touch devices: drop hover-only motion -------------------------------- */
@media (hover: none) {
    .btn:hover,
    .card:hover,
    .issue-card:hover {
        transform: none;
    }

    a.news-item:hover {
        padding-inline: 0;
        background: none;
    }

    a.news-item:hover .news-arrow,
    .link-list a:hover {
        transform: none;
        padding-inline: 0;
    }

    .btn--ghost:hover {
        background: transparent;
        color: inherit;
    }
}

/* --- Reduced motion ------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .photo-carousel figure {
        transition: none;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .reveal {
        opacity: 1;
        transform: none;
    }
}
