/* ==========================================================================
   The Gruff Report: site.css
   Brand tokens up top (from Lois's BRAND.md, Oct 19 2026). Swap here only.
   ========================================================================== */
:root {
  /* Colors */
  --navy: #0B1D3F;          /* page background */
  --navy-deep: #07142D;     /* bars, footer */
  --navy-raise: #12295A;    /* raised panels */
  --offwhite: #F4F1EA;      /* text, polaroid cards */
  --orange: #FF6A1A;        /* primary accent, buttons, lower-third tab */
  --orange-hover: #FF8442;
  --teal: #1A9AA8;          /* info, tags, data */
  --teal-light: #4CC3CF;    /* teal for small text on navy (contrast) */
  --gold: #E8B64C;          /* sparing accent: kickers, goat gags, tape */
  --ink: #0B1D3F;           /* dark text on light surfaces */
  --muted: rgba(244, 241, 234, .72);

  /* Type */
  --font-head: "Archivo Black", "Arial Black", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-meme: "Anton", Impact, "Arial Narrow Bold", sans-serif; /* meme captions only */

  /* Layout */
  --wrap: 1120px;
  --radius: 10px;
  --gap: clamp(1rem, 3vw, 2rem);
  --focus: 0 0 0 3px var(--navy), 0 0 0 6px var(--gold);
}

@font-face { font-family: "Archivo Black"; src: url("/assets/fonts/archivo-black-latin.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter"; src: url("/assets/fonts/inter-latin-400-600.woff2") format("woff2"); font-weight: 400 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Anton"; src: url("/assets/fonts/anton-latin.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body {
  margin: 0; color: var(--offwhite); font: 400 1rem/1.6 var(--font-body);
  background-color: var(--navy);
  /* subtle diagonal pinstripe, like the video backgrounds */
  background-image: repeating-linear-gradient(135deg, rgba(255,255,255,.025) 0 2px, transparent 2px 26px);
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--orange); text-underline-offset: .18em; }
a:hover { color: var(--orange-hover); }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 4px; }
h1, h2, h3 { font-family: var(--font-head); font-weight: 400; line-height: 1.08; margin: 0 0 .5em; letter-spacing: .005em; }
p { margin: 0 0 1em; }
.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 1rem; top: -4rem; z-index: 10; background: var(--orange); color: var(--ink); padding: .6rem 1rem; font-weight: 600; border-radius: 6px; }
.skip:focus { top: 1rem; }

/* ---------- Top bar ---------- */
.topbar { background: rgba(7, 20, 45, .92); border-bottom: 3px solid var(--teal); position: sticky; top: 0; z-index: 5; }
.topbar__in { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 64px; }
.brand { display: flex; align-items: center; gap: .6rem; color: var(--offwhite); text-decoration: none; }
.brand img { border-radius: 50%; border: 2px solid var(--orange); }
.brand__name { font-family: var(--font-head); text-transform: uppercase; font-size: 1rem; letter-spacing: .02em; }
.brand__name span { color: var(--teal-light); }
.nav { display: none; list-style: none; margin: 0; padding: 0; gap: 1.4rem; }
.nav a { color: var(--offwhite); text-decoration: none; font-weight: 600; font-size: .92rem; }
.nav a:hover { color: var(--orange); }
@media (min-width: 760px) { .nav { display: flex; } }

/* ---------- Kickers (Archivo Black on an orange / gold tab) ---------- */
.kicker {
  display: inline-block; font-family: var(--font-head); text-transform: uppercase; letter-spacing: .08em;
  font-size: .78rem; color: var(--ink); background: var(--orange); padding: .3rem .9rem .3rem .7rem; margin-bottom: 1rem;
  clip-path: polygon(0 0, 100% 0, calc(100% - 10px) 100%, 0 100%);
}
.kicker--gold { background: var(--gold); }

/* ---------- Buttons ---------- */
.btns { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.6rem; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .55rem; min-height: 48px; padding: .75rem 1.3rem;
  font: 600 1rem/1 var(--font-body); text-decoration: none; border-radius: 8px; border: 2px solid transparent; cursor: pointer;
  transition: background-color .15s, color .15s, transform .15s;
}
.btn--primary { background: var(--orange); color: var(--ink); }
.btn--primary:hover { background: var(--orange-hover); color: var(--ink); transform: translateY(-1px); }
.btn--ghost { border-color: var(--offwhite); color: var(--offwhite); }
.btn--ghost:hover { background: var(--offwhite); color: var(--ink); }

/* ---------- Hero ---------- */
.hero { padding: clamp(2rem, 6vw, 4.5rem) 0 clamp(2rem, 5vw, 3.5rem); }
.hero__in { display: grid; gap: 2.5rem; align-items: center; }
.hero__title { font-size: clamp(2.6rem, 10vw, 5.2rem); text-transform: uppercase; margin-bottom: .3em; }
.hero__title span { color: var(--teal-light); display: block; }
.hero__tagline { font-size: clamp(1.25rem, 3.2vw, 1.6rem); font-weight: 600; line-height: 1.35; max-width: 30ch; }
.hero__sub { color: var(--muted); max-width: 48ch; }
@media (min-width: 900px) { .hero__in { grid-template-columns: 1.25fr .75fr; } }

/* ---------- Polaroid "EXHIBIT" frame with gold tape ---------- */
.exhibit {
  position: relative; margin: 0; background: var(--offwhite); color: var(--ink); padding: 12px 12px 0;
  box-shadow: 0 14px 30px rgba(0,0,0,.4); border-radius: 2px;
}
.exhibit::before { /* gold tape */
  content: ""; position: absolute; top: -12px; left: 50%; width: 92px; height: 24px; transform: translateX(-50%) rotate(-2deg);
  background: rgba(232, 182, 76, .9); box-shadow: 0 1px 2px rgba(0,0,0,.25);
}
.exhibit img { width: 100%; }
.exhibit figcaption {
  font-family: var(--font-head); text-transform: uppercase; text-align: center; letter-spacing: .02em;
  font-size: 1rem; padding: .7rem .4rem .8rem; color: var(--ink);
}
.exhibit p { margin: -.4rem 0 0; padding: 0 .4rem 1rem; text-align: center; font-size: .9rem; color: #3a4560; }
.exhibit--hero { width: min(64vw, 360px); justify-self: center; transform: rotate(2deg); }
.exhibit--hero figcaption { font-size: 1.25rem; }

/* ---------- Newsletter ---------- */
.newsletter { background: var(--navy-deep); border-top: 4px solid var(--orange); border-bottom: 1px solid rgba(255,255,255,.08); padding: 2rem 0; }
.newsletter__in { display: grid; gap: 1.2rem; align-items: center; }
.newsletter__title { font-size: clamp(1.3rem, 3.4vw, 1.75rem); margin-bottom: .3em; }
.newsletter__note { color: var(--muted); margin: 0; }
.nl-form { display: flex; flex-wrap: wrap; gap: .7rem; }
.nl-form input[type="email"] {
  flex: 1 1 240px; min-height: 48px; padding: .7rem 1rem; font: 400 1rem var(--font-body); color: var(--ink);
  background: var(--offwhite); border: 2px solid var(--offwhite); border-radius: 8px;
}
.nl-form input[type="email"]::placeholder { color: #5b6478; }
.nl-form input[type="email"]:focus-visible { border-color: var(--gold); }
.nl-form .btn { flex: 0 0 auto; }
.hp { position: absolute !important; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
@media (min-width: 900px) { .newsletter__in { grid-template-columns: 1fr 1fr; } }

/* ---------- Sections ---------- */
.section { padding: clamp(3rem, 7vw, 5rem) 0; }
.section--stripe { background: rgba(7, 20, 45, .55); }
.section__title { font-size: clamp(1.8rem, 5vw, 2.8rem); text-transform: uppercase; }
.section__lede { color: var(--muted); max-width: 52ch; margin-bottom: 2.2rem; }

/* ---------- Lower third (navy bar, orange left tab) ---------- */
.lower-third { background: var(--navy-deep); border-left: 8px solid var(--orange); padding: .8rem 1rem; margin-bottom: 1.2rem; }
.lower-third__l1 { font-weight: 600; font-size: 1.1rem; line-height: 1.3; margin: 0 0 .2rem; }
.lower-third__l2 { font-weight: 400; opacity: .7; font-size: .9rem; margin: 0; }
.lower-third--past { border-left-color: var(--teal); }
.lower-third--past .lower-third__l1 { font-size: 1rem; }

/* ---------- Latest episode / click-to-load player ---------- */
.episode { display: grid; gap: 2rem; align-items: start; }
.player { position: relative; aspect-ratio: 16 / 9; background: #000; border-radius: var(--radius); overflow: hidden; box-shadow: 0 12px 30px rgba(0,0,0,.4); }
.player__btn { display: block; position: relative; width: 100%; height: 100%; }
.player__btn img { width: 100%; height: 100%; object-fit: cover; transition: filter .2s; }
.player__btn:hover img { filter: brightness(.85); }
.player__play { position: absolute; inset: 0; display: grid; place-items: center; }
.player__play svg { width: 84px; height: auto; filter: drop-shadow(0 4px 10px rgba(0,0,0,.5)); transition: transform .15s; }
.player__btn:hover .player__play svg, .player__btn:focus-visible .player__play svg { transform: scale(1.08); }
.player__btn:focus-visible { box-shadow: inset 0 0 0 4px var(--gold); }
.player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.episode__note { font-size: .85rem; color: var(--muted); }
.textlink { font-weight: 600; }
@media (min-width: 1000px) { .episode { grid-template-columns: 1.35fr 1fr; } }

/* ---------- Coverage cards ---------- */
.cards { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--gap); grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.card { background: var(--navy-raise); border-radius: var(--radius); overflow: hidden; border: 1px solid rgba(255,255,255,.08); display: flex; flex-direction: column; }
.card img { aspect-ratio: 16 / 9; object-fit: cover; width: 100%; }
.card__body { padding: 1.1rem 1.2rem 1.3rem; }
.card h3 { font-size: 1.15rem; margin: .7rem 0 .5rem; }
.card p { color: var(--muted); margin: 0; font-size: .95rem; }
.covers__note { margin: 1.4rem 0 0; }
.tag { display: inline-block; font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--ink); background: var(--teal-light); padding: .2rem .55rem; border-radius: 4px; }
.tag--gold { background: var(--gold); }
.stat { aspect-ratio: 16 / 9; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .2rem;
  background: linear-gradient(160deg, #0f2550, var(--navy-deep)); border-bottom: 4px solid var(--teal); }
.stat__num { font-family: var(--font-head); font-size: 3.4rem; line-height: 1; color: var(--offwhite); }
.stat__lbl { font-size: .8rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em; color: var(--teal-light); }
.card--hay .stat { border-bottom-color: var(--gold); }
.meme { font-family: var(--font-meme); text-transform: uppercase; font-size: 2.2rem; line-height: 1; color: var(--offwhite); letter-spacing: .03em;
  text-shadow: 2px 2px 0 #000, -2px 2px 0 #000, 2px -2px 0 #000, -2px -2px 0 #000; }
.bales { font-size: 1.6rem; letter-spacing: .25em; color: var(--gold); line-height: 1.2; }
.bales span { color: rgba(232,182,76,.25); }
.card--hay .stat__lbl { color: var(--gold); }

/* ---------- Meet the Herd ---------- */
.herd { list-style: none; margin: 0 auto; max-width: 960px; padding: 1rem 0 0; display: grid; gap: 2.2rem 1.4rem; grid-template-columns: repeat(2, 1fr); }
.herd .exhibit { padding: 8px 8px 0; }
.herd .exhibit figcaption { font-size: .82rem; padding: .55rem .2rem .5rem; }
.herd .exhibit p { font-size: .8rem; }
.herd li:nth-child(odd) .exhibit { transform: rotate(-1.5deg); }
.herd li:nth-child(even) .exhibit { transform: rotate(1.5deg); }
@media (min-width: 700px) { .herd { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Sponsors ---------- */
.sponsors { display: grid; gap: 2rem; align-items: center; }
.sponsors p { color: var(--muted); max-width: 60ch; }
.contact-card { background: var(--offwhite); color: var(--ink); border-radius: var(--radius); padding: 1.6rem; border-top: 8px solid var(--orange); display: grid; gap: .9rem; justify-items: start; }
.contact-card__lbl { font-family: var(--font-head); text-transform: uppercase; letter-spacing: .06em; font-size: .85rem; margin: 0; }
.contact-card__mail { color: var(--ink); font-weight: 600; font-size: clamp(1.05rem, 3.6vw, 1.3rem); word-break: break-all; }
.contact-card__mail:hover { color: #B83E00; }
.contact-card .btn:focus-visible { box-shadow: 0 0 0 3px var(--offwhite), 0 0 0 6px var(--navy); }
@media (min-width: 900px) { .sponsors { grid-template-columns: 1.4fr 1fr; } }

/* ---------- Footer ---------- */
.footer { background: var(--navy-deep); border-top: 4px solid var(--teal); padding: 2.5rem 0; box-shadow: inset 0 4px 0 var(--orange); }
.footer__in { display: grid; gap: 1rem; text-align: center; justify-items: center; }
.footer__signoff { font-family: var(--font-head); font-size: clamp(1.05rem, 3vw, 1.35rem); margin: 0; }
.footer__signoff span { color: var(--orange); }
.footer__links { list-style: none; display: flex; gap: 1.5rem; padding: 0; margin: 0; }
.footer__links a { color: var(--offwhite); font-weight: 600; }
.footer__links a:hover { color: var(--orange); }
.footer__small { color: var(--muted); font-size: .85rem; margin: 0; max-width: 60ch; }

/* ---------- 404 ---------- */
.notfound { min-height: 70vh; display: grid; place-items: center; text-align: center; padding: 3rem 0; }
.notfound .exhibit { width: 220px; margin: 0 auto 2rem; transform: rotate(-2deg); }
.notfound .btns { justify-content: center; }

/* ---------- Story links & sources (main page + /sources/) ---------- */
.episode__sources { list-style: none; margin: 0 0 1.2rem; padding: 0; display: grid; gap: .4rem; }
.src-hero { padding-bottom: 1rem; }
.src-toc { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.src-toc a { font-weight: 600; }
.src-toc span { color: var(--muted); }
.src-list { padding-top: 1rem; }
.src-ep { background: rgba(7, 20, 45, .55); border: 1px solid rgba(255,255,255,.08); border-radius: var(--radius);
  padding: clamp(1rem, 3vw, 2rem); margin-bottom: 2.5rem; scroll-margin-top: 84px; }
.src-ep .lower-third { margin-bottom: 1.4rem; }
.src-ep h2.lower-third__l1 { font-family: var(--font-body); font-weight: 600; font-size: clamp(1.15rem, 3vw, 1.45rem); line-height: 1.3; margin: .3rem 0 0; }
.src-ep .lower-third__l2 .tag { opacity: 1; vertical-align: 1px; }
.src-ep__yt { margin: -.4rem 0 1.2rem; }
.src-topic { font-size: 1.05rem; text-transform: uppercase; letter-spacing: .02em; color: var(--gold); margin: 1.6rem 0 .6rem; }
.src-stories { list-style: none; margin: 0; padding: 0; display: grid; gap: .9rem; }
.src-story { border-left: 3px solid var(--teal); padding-left: .9rem; }
.src-story p { margin: 0 0 .35rem; }
.src-story__fallback { font-size: .85rem; color: var(--muted); }
.src-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem; }
.src-links a { display: inline-block; font-size: .82rem; font-weight: 600; text-decoration: none; color: var(--offwhite);
  border: 1px solid rgba(76, 195, 207, .6); border-radius: 999px; padding: .2rem .7rem; }
.src-links a:hover { background: var(--teal-light); color: var(--ink); }
.src-ep__top { margin: 1.6rem 0 0; font-size: .85rem; }
.nav a[aria-current="page"] { color: var(--orange); }

/* Sources archive (collapsed episodes, month headings) */
.src-month { font-family: var(--font-body); font-size: 1.15rem; font-weight: 600; color: var(--gold); margin: 2rem 0 .8rem; }
.src-ep--fold { padding: 0; margin-bottom: .7rem; }
.src-ep--fold > summary { cursor: pointer; list-style: none; padding: .9rem 1.1rem; display: flex; flex-wrap: wrap; gap: .3rem .8rem; align-items: baseline; }
.src-ep--fold > summary::-webkit-details-marker { display: none; }
.src-ep--fold > summary::before { content: "\25B8"; color: var(--orange); }
.src-ep--fold[open] > summary::before { content: "\25BE"; }
.src-ep--fold > summary:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
.src-ep__date { font-weight: 600; white-space: nowrap; }
.src-ep__name { flex: 1 1 14rem; }
.src-ep__count { font-size: .82rem; color: var(--muted); white-space: nowrap; }
.src-ep--fold[open] { padding-bottom: 1.2rem; }
.src-ep--fold > :not(summary) { margin-left: clamp(1rem, 3vw, 2rem); margin-right: clamp(1rem, 3vw, 2rem); }
.src-archive-link { margin: 0 0 2rem; }
