:root {
  color-scheme: dark;
  --page: #111110;
  --surface-1: #1a1a19;
  --surface-2: #232321;
  --rule: #33332f;
  --grid: #2b2b28;
  --text-primary: #f0efec;
  --text-secondary: #c3c2b7;
  --text-muted: #898781;
  --majors: #3987e5;
  --hunters: #d95926;
  --scouts: #199e70;
  --ref: #898781;
  --gold: #e8c46a;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--page);
  color: var(--text-primary);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--text-primary); text-decoration-color: var(--text-muted); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--text-primary); }
strong { font-weight: 650; }

#progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0;
  background: linear-gradient(90deg, var(--majors), var(--scouts), var(--hunters));
  z-index: 50;
}

/* ---------- hero ---------- */
.hero {
  min-height: 100vh;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 6vh 20px 8vh;
  background:
    radial-gradient(1200px 600px at 50% 110%, rgba(57, 135, 229, 0.12), transparent 60%),
    radial-gradient(800px 400px at 15% -10%, rgba(217, 89, 38, 0.08), transparent 60%),
    var(--page);
}
.hero-inner { max-width: 900px; }
.kicker, .act {
  font-family: var(--sans);
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 14px;
}
.hero h1 {
  font-size: clamp(64px, 12vw, 148px);
  line-height: 0.95;
  margin: 0;
  font-weight: 600;
  letter-spacing: -0.02em;
}
.hero-sub { font-size: clamp(19px, 2.4vw, 25px); color: var(--text-secondary); margin: 18px 0 28px; }
.counter {
  font-family: var(--mono);
  font-size: clamp(26px, 4.6vw, 46px);
  display: flex; gap: 0.6em; justify-content: center; align-items: baseline;
  font-variant-numeric: tabular-nums;
}
.counter-from { color: var(--text-muted); }
.counter-arrow { color: var(--text-muted); font-size: 0.7em; }
.counter-to { color: var(--gold); min-width: 7.2ch; text-align: left; }
.hero-flock { margin: 36px auto 26px; display: flex; flex-wrap: wrap; justify-content: center; gap: 4px; max-width: 760px; }
.hero-flock svg { width: 34px; height: 34px; opacity: 0; transform: translateY(8px); animation: rise 600ms ease forwards; }
@keyframes rise { to { opacity: 1; transform: none; } }
.scroll-cue {
  display: inline-block; font-family: var(--sans); font-size: 15px; color: var(--text-secondary);
  text-decoration: none; border: 1px solid var(--rule); padding: 9px 18px; border-radius: 999px;
}
.scroll-cue:hover { border-color: var(--text-muted); color: var(--text-primary); }

/* ---------- chapters ---------- */
.chapter { padding: 12vh 20px 6vh; }
.prose { max-width: 680px; margin: 0 auto; }
.chapter > .prose + * { margin-top: 32px; }
h2 { font-size: clamp(34px, 5vw, 52px); line-height: 1.1; margin: 0 0 26px; font-weight: 600; letter-spacing: -0.01em; }
h3 { font-size: 25px; margin: 44px 0 12px; font-weight: 600; }
.lede { font-size: 23px; line-height: 1.5; color: var(--text-primary); }
p { margin: 0 0 18px; color: var(--text-secondary); }
p strong, p em { color: var(--text-primary); }
blockquote {
  margin: 16px 0 6px; padding: 2px 0 2px 18px; border-left: 2px solid var(--rule);
  font-style: italic; color: var(--text-primary); font-size: 18px;
}
blockquote cite {
  display: block; margin-top: 6px; font-style: normal; font-family: var(--sans); font-size: 13px;
  color: var(--text-muted);
}
.hint { text-align: center; font-family: var(--sans); font-size: 14px; color: var(--text-muted); }

/* ---------- figures and charts ---------- */
.fig-frame, .chart-frame {
  max-width: 1000px; margin: 34px auto; padding: 0;
}
.fig-frame iframe {
  width: 100%; aspect-ratio: 16 / 10; border: 0; border-radius: 14px;
  background: transparent; display: block; color-scheme: dark;
}
.fig-frame.wide { max-width: 1120px; }
figcaption {
  font-family: var(--sans); font-size: 14px; line-height: 1.5; color: var(--text-muted);
  margin: 12px auto 0; max-width: 680px;
}
.chart-frame {
  background: var(--surface-1); border: 1px solid var(--rule); border-radius: 14px;
  padding: 20px 20px 14px; min-height: 380px; position: relative;
}
.chart-frame.tall { min-height: 620px; }
.chart-frame.short { min-height: 200px; }
.chart-title { font-family: var(--sans); font-size: 15px; font-weight: 600; color: var(--text-primary); margin: 0 0 2px; }
.chart-sub { font-family: var(--sans); font-size: 13px; color: var(--text-muted); margin: 0 0 10px; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 18px; font-family: var(--sans); font-size: 13px; color: var(--text-secondary); margin: 2px 0 8px; }
.legend span { display: inline-flex; align-items: center; gap: 7px; }
.legend i { width: 18px; height: 3px; border-radius: 2px; display: inline-block; }
.legend i.dot { width: 9px; height: 9px; border-radius: 50%; }
.legend i.dash { background: repeating-linear-gradient(90deg, var(--text-secondary) 0 4px, transparent 4px 7px) !important; height: 2px; }
svg text { font-family: var(--sans); }
.axis text { fill: var(--text-muted); font-size: 12px; }
.axis path, .axis line { stroke: var(--rule); }
.grid line { stroke: var(--grid); }
.grid path { display: none; }

/* ---------- tribes and cast ---------- */
.factions {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px;
  max-width: 1000px; margin: 30px auto 26px;
}
.faction {
  background: var(--surface-1); border: 1px solid var(--rule); border-radius: 14px; padding: 16px 18px;
  font-family: var(--sans);
}
.faction h4 { margin: 0 0 6px; font-size: 16px; display: flex; align-items: center; gap: 9px; }
.faction h4 i { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.faction p { font-size: 14px; line-height: 1.5; margin: 0; color: var(--text-muted); }
.cast-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px;
  max-width: 1120px; margin: 16px auto 0;
}
.bird-card {
  background: var(--surface-1); border: 1px solid var(--rule); border-radius: 12px;
  padding: 12px 12px 12px; cursor: pointer; text-align: left; color: inherit;
  font-family: var(--sans); transition: border-color 160ms ease, transform 160ms ease;
  display: flex; flex-direction: column; gap: 6px;
}
.bird-card:hover, .bird-card:focus-visible { border-color: var(--text-muted); transform: translateY(-2px); outline: none; }
.bird-card .who { display: flex; align-items: center; gap: 8px; }
.bird-card svg { width: 42px; height: 42px; flex: none; }
.bird-card .name { font-size: 15px; font-weight: 600; color: var(--text-primary); }
.bird-card .tribe { font-size: 11px; letter-spacing: 0.08em; text-transform: uppercase; }
.bird-card .dir { font-size: 12.5px; line-height: 1.4; color: var(--text-muted); }

/* ---------- scrollytelling ---------- */
.scrolly {
  display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: 36px;
  max-width: 1280px; margin: 40px auto 0;
}
.scrolly-steps { grid-column: 1; grid-row: 1; }
.scrolly-graphic { grid-column: 2; grid-row: 1; position: relative; }
.sticky { position: sticky; top: 9vh; margin: 0; min-height: 0; height: 82vh; }
.scrolly-steps { padding: 20vh 0 40vh; }
.step {
  background: var(--surface-1); border: 1px solid var(--rule); border-radius: 14px;
  padding: 18px 20px 12px; margin: 0 0 58vh; opacity: 0.35; transition: opacity 300ms ease, border-color 300ms ease;
  font-size: 17px;
}
.step.active { opacity: 1; border-color: var(--text-muted); }
.step p { color: var(--text-secondary); }
.stamp { font-family: var(--mono); font-size: 13px; color: var(--gold) !important; margin-bottom: 8px; }

/* ---------- minds ---------- */
.mind {
  max-width: 1120px; margin: 9vh auto 0; display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 34px; align-items: start;
}
.mind-head { display: flex; align-items: center; gap: 14px; margin-bottom: 14px; }
.mind-head svg { width: 72px; height: 72px; }
.mind-head h3 { margin: 0; font-size: 30px; }
.mind-head .tribe { font-family: var(--sans); font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; }
.mind-text p { font-size: 18px; }
.mind-side { display: flex; flex-direction: column; gap: 16px; }
.mind-side .chart-frame { margin: 0; min-height: 250px; }
.mind-side .fig-frame { margin: 0; }
.more-link {
  font-family: var(--sans); font-size: 14px; color: var(--text-secondary); background: none;
  border: 1px solid var(--rule); border-radius: 999px; padding: 7px 14px; cursor: pointer;
}
.more-link:hover { border-color: var(--text-muted); color: var(--text-primary); }

/* ---------- reveal ---------- */
.bignums {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; max-width: 1000px; margin: 0 auto 34px;
}
.bignum {
  background: var(--surface-1); border: 1px solid var(--rule); border-radius: 14px; padding: 16px 18px;
  font-family: var(--sans);
}
.bignum .who { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text-secondary); }
.bignum .who svg { width: 30px; height: 30px; }
.bignum .from { font-family: var(--mono); color: var(--text-muted); text-decoration: line-through; font-size: 18px; margin-top: 8px; }
.bignum .to { font-family: var(--mono); font-size: 34px; color: var(--text-primary); line-height: 1.2; }
.bignum .note { font-size: 12.5px; color: var(--text-muted); }

/* ---------- epilogue ---------- */
.flock { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 6px; margin: 10px 0 34px; }
.flock .b { transition: transform 1200ms cubic-bezier(.2,.7,.2,1), opacity 1200ms ease, filter 1200ms ease; }
.flock .b svg { width: 100%; height: auto; }
.flock.landed .b.fell { transform: translateY(26px) rotate(-150deg); opacity: 0.32; filter: grayscale(1); }
.flock.landed .b.rose { transform: translateY(-8px); }
.flock.landed .b.champ { transform: translateY(-14px) scale(1.18); }
.flock-key { font-family: var(--sans); font-size: 13px; color: var(--text-muted); margin: -18px 0 30px; }
.closing { font-size: 25px; line-height: 1.45; color: var(--text-primary); margin-top: 36px; }
.signoff { font-family: var(--sans); font-size: 14px; color: var(--text-muted); }

/* ---------- table ---------- */
.table-wrap { max-width: 1000px; margin: 26px auto 0; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 14px; font-variant-numeric: tabular-nums; }
th { text-align: left; color: var(--text-muted); font-weight: 600; font-size: 12px; letter-spacing: 0.04em; text-transform: uppercase; border-bottom: 1px solid var(--rule); padding: 8px 10px; }
td { border-bottom: 1px solid var(--grid); padding: 7px 10px; color: var(--text-secondary); }
td.num, th.num { text-align: right; }
td button { all: unset; cursor: pointer; color: var(--text-primary); display: inline-flex; align-items: center; gap: 8px; }
td button svg { width: 24px; height: 24px; }
td button:hover { text-decoration: underline; }

/* ---------- dossier ---------- */
.dossier { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; }
.dossier[hidden] { display: none; }
.dossier-backdrop { position: absolute; inset: 0; background: rgba(5, 5, 4, 0.72); backdrop-filter: blur(3px); }
.dossier-card {
  position: relative; width: min(960px, 94vw); max-height: 90vh; overflow: auto;
  background: var(--surface-1); border: 1px solid var(--rule); border-radius: 16px; padding: 26px 28px 30px;
  font-family: var(--sans); font-size: 15px; line-height: 1.55;
}
.dossier-close {
  position: sticky; top: 0; float: right; background: var(--surface-2); color: var(--text-primary);
  border: 1px solid var(--rule); border-radius: 50%; width: 34px; height: 34px; font-size: 20px; cursor: pointer;
}
.dossier h3 { margin: 0; font-family: var(--serif); font-size: 32px; }
.d-head { display: flex; gap: 16px; align-items: center; margin-bottom: 14px; }
.d-head svg { width: 84px; height: 84px; }
.d-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 14px 0 18px; }
.d-stat { background: var(--surface-2); border-radius: 10px; padding: 10px 12px; }
.d-stat .k { font-size: 11.5px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.06em; }
.d-stat .v { font-family: var(--mono); font-size: 21px; color: var(--text-primary); }
.d-stat .v.sealed { color: var(--text-muted); font-size: 16px; display: flex; gap: 6px; align-items: center; }
.dossier h4 { font-size: 13px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); margin: 22px 0 8px; }
.dossier p { color: var(--text-secondary); font-size: 15px; }
.thoughts { border-left: 1px solid var(--rule); margin-left: 6px; padding-left: 16px; }
.thought { position: relative; margin: 0 0 12px; color: var(--text-secondary); font-size: 14.5px; }
.thought::before { content: ""; position: absolute; left: -20.5px; top: 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--rule); }
.thought.sub::before { background: var(--gold); }
.thought .t { font-family: var(--mono); font-size: 12px; color: var(--text-muted); margin-right: 8px; }
.thought.sub .t { color: var(--gold); }
.evo { background: var(--surface-2); border-radius: 12px; padding: 10px 12px 4px; }

/* ---------- tooltip ---------- */
.tooltip {
  position: fixed; z-index: 80; pointer-events: none; max-width: 300px;
  background: #0b0b0a; border: 1px solid var(--rule); border-radius: 10px; padding: 9px 11px;
  font-family: var(--sans); font-size: 13px; line-height: 1.45; color: var(--text-secondary);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}
.tooltip b { color: var(--text-primary); }

/* ---------- small screens ---------- */
@media (max-width: 860px) {
  body { font-size: 18px; }
  .scrolly { grid-template-columns: 1fr; gap: 0; }
  .scrolly-graphic, .scrolly-steps { grid-column: 1; grid-row: 1; }
  .sticky { top: 0; height: 52vh; border-radius: 0 0 14px 14px; z-index: 5; }
  .scrolly-steps { padding: 58vh 0 30vh; position: relative; z-index: 6; pointer-events: none; }
  .scrolly-steps .step { pointer-events: auto; background: rgba(26, 26, 25, 0.96); }
  .step { margin-bottom: 70vh; }
  .mind { grid-template-columns: 1fr; }
  .factions, .bignums { grid-template-columns: 1fr; }
  .d-grid { grid-template-columns: 1fr 1fr; }
  .flock { grid-template-columns: repeat(8, minmax(0, 1fr)); }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-flock svg { opacity: 1; transform: none; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- fun: hopping birds ---------- */
@keyframes hop { 0%, 100% { transform: translateY(0); } 30% { transform: translateY(-7px) rotate(-6deg); } 55% { transform: translateY(0) rotate(0); } 70% { transform: translateY(-2px); } }
.bird-card:hover svg, .hero-flock svg:hover, .award:hover svg, .flock .b:hover svg { animation: hop 520ms ease; }
.hero-flock svg { cursor: default; }
.bird-card.picked { border-color: var(--gold); box-shadow: 0 0 0 1px var(--gold) inset; }
.bird-card.picked .name::after { content: " · your pick"; color: var(--gold); font-weight: 500; font-size: 12px; }

/* ---------- fun: back a bird ---------- */
.pick-prompt {
  max-width: 1000px; margin: 0 auto 12px; padding: 14px 18px; border-radius: 12px;
  border: 1px dashed var(--gold); color: var(--text-secondary); font-family: var(--sans); font-size: 15px; text-align: center;
}
.pick-prompt b { color: var(--gold); }
.pick-btn {
  font-family: var(--sans); font-size: 14px; font-weight: 600; cursor: pointer; margin: 2px 0 14px;
  background: transparent; color: var(--gold); border: 1px solid var(--gold); border-radius: 999px; padding: 8px 16px;
}
.pick-btn:hover, .pick-btn.on { background: var(--gold); color: #111110; }
.pick-note { color: var(--gold) !important; }
.pick-badge {
  position: fixed; left: 16px; bottom: 16px; z-index: 40; display: flex; align-items: center; gap: 8px;
  background: rgba(26, 26, 25, 0.94); border: 1px solid var(--gold); border-radius: 999px; padding: 4px 8px 4px 6px;
  font-family: var(--sans); font-size: 13px; color: var(--text-secondary); backdrop-filter: blur(4px);
}
.pick-badge[hidden] { display: none; }
.pick-badge b { color: var(--text-primary); }
.pick-badge button { all: unset; cursor: pointer; color: var(--text-muted); padding: 0 6px; font-size: 16px; }
.pick-result {
  max-width: 1000px; margin: 0 auto 34px; padding: 20px 22px; border-radius: 14px; border: 1px solid var(--gold);
  background: linear-gradient(180deg, rgba(232, 196, 106, 0.08), rgba(232, 196, 106, 0.02)); font-family: var(--sans);
  opacity: 0; transform: translateY(10px); transition: opacity 600ms ease, transform 600ms ease;
}
.pick-result.shown { opacity: 1; transform: none; }
.pick-result:empty { display: none; }
.pick-result p { font-size: 15px; color: var(--text-secondary); margin: 0 0 8px; }
.pick-head { font-family: var(--serif); font-size: 24px !important; color: var(--text-primary) !important; margin-bottom: 4px !important; }
.pick-who { display: flex; gap: 16px; align-items: center; }
.pick-who svg { width: 64px; height: 64px; flex: none; }

/* ---------- share ---------- */
.share-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.share {
  font-family: var(--sans); font-size: 14px; color: var(--text-primary); text-decoration: none; cursor: pointer;
  border: 1px solid var(--rule); background: var(--surface-1); border-radius: 999px; padding: 8px 16px;
}
.share:hover { border-color: var(--text-muted); }
.egg-hint { font-family: var(--sans); font-size: 13px; color: var(--text-muted); margin-top: 26px; }
kbd { font-family: var(--mono); font-size: 12px; border: 1px solid var(--rule); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px; color: var(--text-secondary); }

/* ---------- awards ---------- */
.awards-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; max-width: 1120px; margin: 30px auto 0; }
.award {
  all: unset; box-sizing: border-box; cursor: pointer; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px;
  background: var(--surface-1); border: 1px solid var(--rule); border-radius: 14px; padding: 18px 16px 16px; font-family: var(--sans);
  transition: border-color 160ms ease, transform 160ms ease;
}
.award:hover, .award:focus-visible { border-color: var(--gold); transform: translateY(-2px); }
.award-title { font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--gold); }
.award svg { width: 56px; height: 56px; }
.award-name { font-family: var(--serif); font-size: 21px; color: var(--text-primary); }
.award-line { font-size: 13.5px; line-height: 1.45; color: var(--text-muted); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--rule); padding: 30px 20px 90px; text-align: center; font-family: var(--sans); font-size: 13px; }
.site-footer p { color: var(--text-muted); max-width: 760px; margin: 0 auto 8px; }

/* ---------- easter egg ---------- */
.moon-layer { position: fixed; inset: 0; z-index: 90; pointer-events: none; overflow: hidden; }
.moon { position: absolute; right: 8vw; top: 9vh; width: 120px; height: 120px; border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #fff8dc, #e8c46a 60%, #b8913a); box-shadow: 0 0 60px rgba(232, 196, 106, 0.45);
  animation: moonrise 5s ease forwards; }
.moon-text { position: absolute; left: 50%; top: 42vh; transform: translateX(-50%); font-family: var(--serif); font-size: clamp(26px, 5vw, 48px);
  color: var(--text-primary); text-align: center; animation: fadeio 5s ease forwards; text-shadow: 0 2px 20px #000; }
.moon-text span { display: block; font-size: 0.55em; color: var(--gold); }
.flyer { position: absolute; left: -60px; animation-name: fly; animation-timing-function: cubic-bezier(.3,.1,.5,1); animation-fill-mode: forwards; }
@keyframes fly { 0% { transform: translate(0, 0) rotate(-8deg); } 50% { transform: translate(55vw, -6vh) rotate(4deg); } 100% { transform: translate(115vw, -30vh) rotate(-14deg); } }
@keyframes moonrise { 0% { opacity: 0; transform: translateY(40px); } 20%, 80% { opacity: 1; transform: none; } 100% { opacity: 0; } }
@keyframes fadeio { 0%, 100% { opacity: 0; } 15%, 80% { opacity: 1; } }
@media (max-width: 860px) {
  .pick-who { flex-direction: column; align-items: flex-start; }
}

/* ---------- writeups (Markdown + KaTeX) ---------- */
.md { color: var(--text-secondary); font-size: 15px; line-height: 1.6; }
.md p, .md li { color: var(--text-secondary); }
.md ul, .md ol { padding-left: 22px; margin: 0 0 12px; }
.md li { margin: 4px 0; }
.md h3, .md h4 { font-family: var(--sans); font-size: 14px; letter-spacing: 0.04em; color: var(--text-primary); text-transform: none; margin: 18px 0 6px; }
.md strong { color: var(--text-primary); }
.md code { font-family: var(--mono); font-size: 13px; background: var(--surface-2); border-radius: 4px; padding: 1px 5px; }
.md table { width: 100%; border-collapse: collapse; margin: 10px 0 16px; font-size: 13px; display: block; overflow-x: auto; }
.md th, .md td { border-bottom: 1px solid var(--rule); padding: 6px 8px; text-align: left; white-space: nowrap; }
.md th { color: var(--text-muted); font-weight: 600; text-transform: none; letter-spacing: 0; font-size: 12.5px; }
.md .katex { color: var(--text-primary); font-size: 1.04em; }
.md .katex-display { overflow-x: auto; overflow-y: hidden; padding: 4px 0; margin: 10px 0; }
.md .katex-display > .katex { white-space: nowrap; }
details.maths { margin: 16px 0 6px; border: 1px solid var(--rule); border-radius: 12px; background: var(--surface-2); }
details.maths summary { cursor: pointer; padding: 12px 14px; font-weight: 600; color: var(--gold); list-style: none; }
details.maths summary::-webkit-details-marker { display: none; }
details.maths summary::before { content: "▸ "; }
details.maths[open] summary::before { content: "▾ "; }
details.maths summary span { font-weight: 400; color: var(--text-muted); font-size: 13px; margin-left: 8px; }
details.maths .md { padding: 0 16px 14px; max-height: 70vh; overflow-y: auto; }
