/* stephenbcastle.com — one stylesheet for the whole site.
   Dark by design (a deliberate single theme, not an omission): the books are
   deep-ocean and Arctic techno-thrillers and the site reads like a declassified
   briefing. Every colour below is a token; components use tokens only.
   Contrast checked against --bg: --text 16:1, --muted 8:1, --amber 10:1. */

/* ---------- Tokens ---------- */
:root {
  color-scheme: dark;

  --bg: #0a1118;            /* abyssal navy */
  --bg-raised: #0e1820;
  --surface: #111c24;       /* cards */
  --surface-2: #16242e;
  --line: #1e2d3a;
  --line-strong: #2b3f4f;

  --text: #f1f5f9;
  --muted: #94a3b8;
  --faint: #5b6b7b;

  --amber: #f5b727;         /* primary action */
  --amber-hover: #f8c84f;
  --on-amber: #0a1118;
  --teal: #14b8a6;          /* sonar / secondary */
  --teal-soft: rgba(20, 184, 166, 0.18);
  --green: #84cc16;         /* "out now" */
  --red: #f87171;           /* placeholder warnings only */

  --font-display: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --radius: 10px;
  --radius-sm: 6px;
  --gutter: clamp(16px, 4vw, 40px);
  --measure: 68ch;
  --max: 1180px;
}

/* ---------- Fonts (self-hosted, SIL OFL; see /fonts/LICENSE-*) ---------- */
@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/fonts/barlow-condensed-latin-600-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Barlow Condensed";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/barlow-condensed-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/fonts/jetbrains-mono-latin-500-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.6;
  /* depth: lighter slate at the surface, abyssal below, with a faint grid */
  background-image:
    linear-gradient(to right, rgba(148, 163, 184, 0.035) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(148, 163, 184, 0.035) 1px, transparent 1px),
    linear-gradient(180deg, #13212c 0%, var(--bg) 38%, #070c11 100%);
  background-size: 48px 48px, 48px 48px, 100% 100%;
  background-attachment: fixed;
  position: relative;
}
/* grain: a filter-generated noise tile, so the dark reads as material */
body::after {
  content: ""; position: fixed; inset: 0; z-index: 60; pointer-events: none; opacity: 0.045;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}
img, svg { max-width: 100%; height: auto; }
a { color: var(--teal); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--text); }
:focus-visible { outline: 2px solid var(--amber); outline-offset: 3px; border-radius: 2px; }
p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
ul, ol { margin: 0 0 1em; padding-left: 1.3em; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  line-height: 1.05;
  margin: 0 0 0.4em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.6rem, 7vw, 4.5rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.6rem); }
h3 { font-size: 1.4rem; }
.lede { font-size: 1.2rem; color: var(--muted); max-width: var(--measure); text-wrap: pretty; }
.measure { max-width: var(--measure); }

.skip-link {
  position: absolute; left: var(--gutter); top: -100px;
  background: var(--amber); color: var(--on-amber); padding: 8px 14px;
  border-radius: var(--radius-sm); font-weight: 700; z-index: 100;
}
.skip-link:focus { top: 12px; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* ---------- Layout ---------- */
.wrap {
  max-width: var(--max);
  margin-inline: auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
}
.section { padding-block: clamp(48px, 8vw, 96px); position: relative; }
.section + .section { border-top: 1px solid var(--line); }
/* every second section sits on a raised slab, so the page reads as bands */
main > .section:nth-of-type(even) {
  background: linear-gradient(180deg, rgba(22, 36, 46, 0.72), rgba(14, 24, 32, 0.35));
  box-shadow: inset 0 1px 0 rgba(148, 163, 184, 0.06);
}
/* bathymetric contours behind the hero and the Intel scope */
.contoured::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: url("/img/contours.svg") center / cover no-repeat;
  opacity: 0.24;
  -webkit-mask-image: linear-gradient(180deg, rgba(0,0,0,0.9), rgba(0,0,0,0.25) 70%, transparent);
  mask-image: linear-gradient(180deg, rgba(0,0,0,0.9), rgba(0,0,0,0.25) 70%, transparent);
}
.section-head { display: grid; gap: 6px; margin-bottom: 28px; }
.section-head h2 { margin: 0; }

/* Dossier eyebrow: mono, uppercase, teal rule */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal);
  display: inline-flex; align-items: center; gap: 10px;
}
.eyebrow::before { content: ""; width: 22px; height: 1px; background: var(--teal); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(10, 17, 24, 0.86);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px;
}
.brand {
  font-family: var(--font-display); font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.06em; font-size: 1.35rem; color: var(--text); text-decoration: none;
  display: inline-flex; align-items: center; gap: 10px;
}
.brand:hover { color: var(--amber); }
.brand svg { width: 28px; height: 28px; flex: none; }
.nav-toggle {
  display: none; background: none; border: 1px solid var(--line-strong); color: var(--text);
  border-radius: var(--radius-sm); padding: 8px; cursor: pointer; line-height: 0;
}
.nav-toggle svg { width: 22px; height: 22px; }
.nav-toggle .icon-close { display: none; }
.nav-toggle[aria-expanded="true"] .icon-menu { display: none; }
.nav-toggle[aria-expanded="true"] .icon-close { display: block; }
.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 6px; }
.site-nav a {
  display: block; padding: 8px 12px; text-decoration: none; color: var(--muted);
  font-family: var(--font-display); font-weight: 600; text-transform: uppercase;
  letter-spacing: 0.08em; font-size: 1.05rem; border-bottom: 2px solid transparent;
}
.site-nav a:hover { color: var(--text); }
.site-nav a[aria-current="page"] { color: var(--amber); border-bottom-color: var(--amber); }
@media (max-width: 760px) {
  .nav-toggle { display: inline-flex; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%;
    background: var(--bg-raised); border-bottom: 1px solid var(--line); }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; padding: 8px var(--gutter) 12px; }
  .site-nav a { padding: 12px 4px; border-bottom: 1px solid var(--line); }
  .site-nav a[aria-current="page"] { border-bottom-color: var(--amber); }
}

/* ---------- Buttons & badges ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px; border-radius: var(--radius-sm); text-decoration: none;
  font-family: var(--font-display); font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; font-size: 1.05rem; line-height: 1.1;
  border: 1px solid transparent; cursor: pointer; transition: background 120ms, color 120ms, border-color 120ms;
}
.btn svg { width: 18px; height: 18px; }
.btn-primary { background: var(--amber); color: var(--on-amber); }
.btn-primary:hover { background: var(--amber-hover); color: var(--on-amber); }
.btn-outline { background: transparent; color: var(--text); border-color: var(--line-strong); }
.btn-outline:hover { border-color: var(--amber); color: var(--amber); }
.btn-ghost { background: transparent; color: var(--muted); padding-inline: 8px; }
.btn-ghost:hover { color: var(--text); }
.btn[aria-disabled="true"] { opacity: 0.55; cursor: not-allowed; pointer-events: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase;
  padding: 4px 9px; border-radius: 4px; border: 1px solid var(--line-strong); color: var(--muted);
  justify-self: start; width: max-content;   /* never stretch inside a grid */
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-live { color: var(--green); border-color: rgba(132, 204, 22, 0.45); }
.badge-soon { color: var(--amber); border-color: rgba(245, 183, 39, 0.45); }
.badge-classified { color: var(--teal); border-color: rgba(20, 184, 166, 0.45); }

/* ---------- Cards ---------- */
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; display: grid; gap: 12px; align-content: start;
}
.card h3 { margin: 0; }
.card p { color: var(--muted); }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 620px) { .grid-3, .grid-2 { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Hero ---------- */
.hero { position: relative; overflow: hidden; padding-block: clamp(56px, 9vw, 128px); isolation: isolate; }
.hero::after {  /* light from the surface, falling on the cover */
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse 55% 60% at 72% 30%, rgba(20, 184, 166, 0.22), transparent 70%),
    radial-gradient(ellipse 40% 50% at 15% 90%, rgba(245, 183, 39, 0.07), transparent 70%);
}
.hero .wrap {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(28px, 5vw, 64px); align-items: center;
}
.hero-copy { display: grid; gap: 18px; }
.hero-copy h1 { margin: 0; font-size: clamp(3rem, 8.5vw, 5.6rem); }
.hero-copy h1::after { content: ""; display: block; width: 72px; height: 4px; background: var(--amber); margin-top: 18px; border-radius: 2px; }
.hero-copy .lede { font-size: clamp(1.1rem, 2vw, 1.35rem); }
.hero-art { position: relative; display: grid; place-items: center; }
.hero-art { perspective: 1400px; min-height: 420px; }
.hero-art .cover-main {
  width: min(100%, 340px); position: relative; z-index: 2;
  transform: rotateY(-9deg) rotateX(2deg);
  filter: drop-shadow(0 34px 44px rgba(0, 0, 0, 0.6));
  transition: transform 600ms cubic-bezier(.2,.7,.2,1);
}
.hero-art:hover .cover-main { transform: rotateY(-4deg) rotateX(1deg) translateY(-4px); }
.hero-art .cover-back {  /* the other books, peeking out behind */
  position: absolute; width: min(42%, 150px); z-index: 1; opacity: 0.85;
  filter: drop-shadow(0 18px 24px rgba(0, 0, 0, 0.5)) saturate(0.85);
}
.hero-art .cover-back-1 { left: 2%; bottom: 10%; transform: rotate(-8deg); }
.hero-art .cover-back-2 { right: 0; top: 4%; transform: rotate(7deg); }
.hero-art .cover-reflection {  /* a soft pool of light under the stack */
  position: absolute; left: 20%; right: 20%; bottom: -6%; height: 60px; z-index: 0;
  background: radial-gradient(ellipse at center, rgba(20, 184, 166, 0.28), transparent 70%);
  filter: blur(6px);
}
.sonar {
  position: absolute; inset: -20% -10%; z-index: -1; pointer-events: none; opacity: 0.55;
}
.sonar svg { width: 100%; height: 100%; }
.sonar .sweep { transform-origin: 50% 50%; animation: sweep 9s linear infinite; }
@keyframes sweep { to { transform: rotate(360deg); } }
/* a contact pings as the sweep crosses it: expanding ring, then silence */
.ping { transform-box: fill-box; transform-origin: center; animation: ping 9s ease-out infinite; opacity: 0; }
@keyframes ping {
  0%, 2%   { transform: scale(1); opacity: 0.9; }
  26%      { transform: scale(7); opacity: 0; }
  100%     { transform: scale(7); opacity: 0; }
}
/* Intel scope: contacts brighten as the beam passes, then fade */
.scope .contact { animation: contact-glow 9s ease-out infinite; opacity: 0.45; }
.scope .contact-1 { animation-delay: 4.4s; }
.scope .contact-2 { animation-delay: 8.5s; }
.scope .contact-3 { animation-delay: 1.8s; }
@keyframes contact-glow {
  0%   { opacity: 1; }
  45%  { opacity: 0.45; }
  100% { opacity: 0.45; }
}
/* cards rise into view as they scroll in (browsers without scroll-driven
   animations simply show them; reduced-motion disables everything) */
@supports (animation-timeline: view()) {
  .card, .contacts li, .dossier details {
    animation: rise linear both;
    animation-timeline: view();
    animation-range: entry 0% entry 60%;
  }
  @keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
}
.coords {
  position: absolute; font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.1em;
  color: var(--faint); pointer-events: none; user-select: none;
}
.coords-tl { left: var(--gutter); top: 14px; }
.coords-br { right: var(--gutter); bottom: 14px; }
@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: minmax(0, 1fr); }
  .hero-art { order: -1; min-height: 0; }
  .hero-art .cover-main { width: min(70%, 280px); transform: none; }
  .hero-art .cover-back { width: 26%; }
  .coords { display: none; }
}

/* ---------- Book covers ---------- */
.cover {
  display: block; aspect-ratio: 2 / 3; width: 100%; border-radius: 4px;
  background: var(--surface-2); border: 1px solid var(--line);
  box-shadow: 0 18px 30px rgba(0, 0, 0, 0.45);
  object-fit: cover;
}
.book-card { position: relative; }
.book-card .cover { width: min(100%, 240px); margin-inline: auto; }
.book-card .book-meta { display: grid; gap: 8px; }
.book-card .book-title { font-size: 1.6rem; margin: 0; }
.book-card .book-num { font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.14em; color: var(--faint); text-transform: uppercase; }
.book-card .btn-row { margin-top: 6px; }
.store-links { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 0.95rem; }

/* Book page */
.book-hero .wrap { grid-template-columns: minmax(0, 0.7fr) minmax(0, 1.3fr); }
.book-hero .cover { width: min(100%, 360px); }
.book-facts {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px;
  padding: 18px 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
}
.book-facts div { display: grid; gap: 2px; }
.book-facts dt { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); }
.book-facts dd { margin: 0; font-weight: 600; }
.prose { max-width: var(--measure); }
.wrap.prose { max-width: var(--max); }            /* a .wrap stays full width… */
.wrap.prose > * { max-width: var(--measure); }    /* …its text stays readable */
.prose p { text-wrap: pretty; }
.breadcrumbs { font-family: var(--font-mono); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; }
.breadcrumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; color: var(--faint); }
.breadcrumbs li + li::before { content: "/"; margin-right: 8px; color: var(--line-strong); }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--text); }

/* ---------- Intel: sonar scope ---------- */
.scope-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 0.6fr); gap: 32px; align-items: start; }
.scope { aspect-ratio: 1; width: 100%; max-width: 640px; margin-inline: auto; }
.scope svg { width: 100%; height: 100%; display: block; }
.contacts { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.contacts li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start;
  padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.contacts .dot { width: 12px; height: 12px; border-radius: 50%; margin-top: 6px; box-shadow: 0 0 0 4px var(--teal-soft); }
.contacts .dot-amber { background: var(--amber); box-shadow: 0 0 0 4px rgba(245, 183, 39, 0.2); }
.contacts .dot-teal { background: var(--teal); }
.contacts .dot-faint { background: var(--faint); box-shadow: 0 0 0 4px rgba(91, 107, 123, 0.2); }
.contacts .label { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); }
.contacts strong { font-family: var(--font-display); text-transform: uppercase; font-size: 1.2rem; letter-spacing: 0.03em; }
.contacts a { text-decoration: none; }
@media (max-width: 820px) { .scope-wrap { grid-template-columns: minmax(0, 1fr); } }

/* Fact vs fiction tabs — plain details/summary, no script */
.dossier details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.dossier details + details { margin-top: 10px; }
.dossier summary {
  cursor: pointer; list-style: none; padding: 16px 20px; display: flex; justify-content: space-between; align-items: center; gap: 12px;
  font-family: var(--font-display); font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; font-size: 1.15rem;
}
.dossier summary::-webkit-details-marker { display: none; }
.dossier summary svg { width: 18px; height: 18px; color: var(--muted); transition: transform 150ms; }
.dossier details[open] summary svg { transform: rotate(180deg); }
.dossier .body { padding: 0 20px 18px; display: grid; gap: 14px; }
.fvf { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.fvf > div { padding: 14px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--bg-raised); }
.fvf .eyebrow { margin-bottom: 8px; }
.fvf .fiction .eyebrow { color: var(--amber); }
.fvf .fiction .eyebrow::before { background: var(--amber); }
.fvf p { color: var(--muted); font-size: 0.98rem; margin: 0; }
@media (max-width: 620px) { .fvf { grid-template-columns: minmax(0, 1fr); } }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); gap: clamp(24px, 4vw, 48px); align-items: start; }
.portrait { width: 100%; max-width: 380px; aspect-ratio: 4 / 5; border-radius: var(--radius); border: 1px solid var(--line); background: var(--surface-2); object-fit: cover; }
@media (max-width: 760px) { .about-grid { grid-template-columns: minmax(0, 1fr); } .portrait { max-width: 300px; } }

.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.contact-list li { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding: 14px 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.contact-list .label { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); min-width: 7rem; }
.contact-list a { font-weight: 600; }

/* ---------- Placeholder marker (removed before launch; check-site counts them) ---------- */
.placeholder-note {
  font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--red); border: 1px dashed var(--red); border-radius: var(--radius-sm); padding: 6px 10px; display: inline-block;
}

/* ---------- Band CTA ---------- */
.band { background: var(--surface); border-block: 1px solid var(--line); }
.band .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; padding-block: 36px; }
.band h2 { margin: 0; font-size: clamp(1.6rem, 3vw, 2.2rem); }
.band p { margin: 4px 0 0; color: var(--muted); }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 40px 48px; color: var(--muted); font-size: 0.95rem; }
.site-footer .wrap { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(2, minmax(0, 1fr)); gap: 28px; }
.site-footer h2 { font-size: 0.78rem; font-family: var(--font-mono); letter-spacing: 0.14em; color: var(--faint); margin-bottom: 10px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); }
.site-footer .brand { font-size: 1.15rem; margin-bottom: 8px; }
.site-footer .colophon { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-top: 18px; display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; font-size: 0.85rem; color: var(--faint); }
.site-footer .colophon a { color: var(--muted); }
@media (max-width: 700px) { .site-footer .wrap { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Utility ---------- */
.icon { width: 1em; height: 1em; vertical-align: -0.15em; }
.text-muted { color: var(--muted); }
.mt-0 { margin-top: 0; }
.center { text-align: center; }
.stack { display: grid; gap: 16px; }
.not-found { min-height: 60vh; display: grid; place-items: center; text-align: center; }
.not-found .code { font-family: var(--font-mono); color: var(--teal); letter-spacing: 0.2em; }

/* SVG text inside the scopes (presentation attributes can't reach the font tokens) */
.scope .scope-text, .scope text { font-family: var(--font-mono); }
.eyebrow.code { color: var(--teal); }
