:root {
  --bg: #101A15;
  --surface: #16231C;
  --surface-2: #1B2B22;
  --chalk: #E9E4D6;
  --muted: #93A398;
  --faint: rgba(233, 228, 214, 0.14);
  --solved: #348AC9;
  --open: #B98A24;
  --danger: #C85850;
  --gold: #D8B25A;
  --serif: "Iowan Old Style", Palatino, "Palatino Linotype", Georgia, serif;
  --mono: "SF Mono", ui-monospace, Menlo, Consolas, monospace;
}
* { box-sizing: border-box; margin: 0; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { background: var(--bg); color: var(--chalk); font-family: var(--serif); font-size: 17px; line-height: 1.55; }
a { color: inherit; text-decoration-color: var(--faint); text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--gold); }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 2px; }
code { font-family: var(--mono); font-size: 0.85em; }
.wrap { max-width: 1060px; margin: 0 auto; padding: 0 24px; }

/* masthead + nav */
header.mast { border-bottom: 1px solid var(--faint); padding: 18px 0 14px; }
.mast .wrap { display: flex; align-items: baseline; gap: 18px; flex-wrap: wrap; }
.mast h1 { font-size: 20px; font-weight: 600; white-space: nowrap; }
.mast h1 .razor { font-style: italic; }
.mast h1 a { text-decoration: none; }
nav.pages { display: flex; gap: 4px; flex-wrap: wrap; margin-left: auto; font-family: var(--mono); font-size: 12.5px; }
nav.pages a { padding: 3px 11px; border-radius: 999px; text-decoration: none; color: var(--muted); border: 1px solid transparent; }
nav.pages a:hover { color: var(--chalk); border-color: var(--faint); }
nav.pages a.here { color: var(--gold); border-color: var(--gold); }

/* page head */
.pagehead { padding: 44px 0 6px; }
.pagehead h2 { font-size: clamp(26px, 4vw, 38px); font-weight: 500; font-style: italic; }
.pagehead p.lede { color: var(--muted); max-width: 48em; margin-top: 12px; font-size: 16.5px; }
.pagehead p.lede code { color: var(--chalk); }

section { padding: 40px 0 10px; }
.sec-head { display: flex; align-items: baseline; gap: 14px; border-bottom: 1px solid var(--faint); padding-bottom: 10px; margin-bottom: 22px; }
.sec-head h3 { font-size: 22px; font-weight: 500; font-style: italic; }
.sec-head .note { margin-left: auto; color: var(--muted); font-size: 14px; }

/* chips + badges */
.chip { display: inline-flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: 11px; letter-spacing: 0.06em; padding: 2px 9px; border-radius: 999px; border: 1px solid; text-transform: uppercase; white-space: nowrap; }
.chip.open   { color: var(--open);   border-color: var(--open); }
.chip.solved { color: var(--solved); border-color: var(--solved); }
.badge { display: inline-block; font-family: var(--mono); font-size: 10.5px; color: var(--muted); border: 1px solid var(--faint); border-radius: 4px; padding: 1px 7px; margin-right: 5px; }
.badge.gold { color: var(--gold); border-color: var(--gold); }
.badge.blue { color: var(--solved); border-color: var(--solved); }
.badge.red { color: var(--danger); border-color: var(--danger); }

/* cards */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 14px; }
.card { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; padding: 16px 18px 14px; display: flex; flex-direction: column; gap: 10px; transition: border-color 0.15s ease; }
.card:hover { border-color: rgba(233,228,214,0.3); }
.card .row1 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.card .hid { font-family: var(--mono); font-size: 12.5px; color: var(--muted); }
.card .pool { margin-left: auto; font-family: var(--mono); font-size: 12px; color: var(--gold); }
.card h4 { font-size: 16.5px; font-weight: 500; line-height: 1.3; }
.card pre { font-family: var(--mono); font-size: 11.5px; line-height: 1.5; color: var(--muted); background: var(--bg); border: 1px solid var(--faint); border-radius: 6px; padding: 9px 11px; overflow-x: auto; white-space: pre-wrap; word-break: break-word; }
.card .meta { font-family: var(--mono); font-size: 11.5px; color: var(--muted); display: flex; flex-direction: column; gap: 3px; }
.card .meta .ok { color: var(--solved); }
.card .meta .bad { color: var(--danger); }
.card.wide { grid-column: 1 / -1; }

/* index overview cards */
.overview { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 14px; }
.overview .card h4 { font-size: 19px; font-style: italic; }
.overview .card p { color: var(--muted); font-size: 15px; flex: 1; }
.overview .card .go { font-family: var(--mono); font-size: 12.5px; color: var(--gold); text-decoration: none; }
.overview .card .go:hover { text-decoration: underline; }

/* stats */
.stats { display: flex; gap: 34px; margin-top: 26px; flex-wrap: wrap; }
.stat { font-family: var(--mono); font-size: 13px; color: var(--muted); }
.stat b { display: block; font-size: 26px; color: var(--chalk); font-weight: 500; }

/* controls */
.controls { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 18px; font-family: var(--mono); font-size: 13px; }
.controls label { color: var(--muted); }
.controls select, .controls input {
  background: var(--surface); color: var(--chalk); border: 1px solid var(--faint);
  border-radius: 6px; padding: 6px 10px; font-family: var(--mono); font-size: 13px;
}
.controls input { min-width: 180px; }

/* history timeline inside details */
details.hist { margin-top: 4px; }
details.hist summary { cursor: pointer; font-family: var(--mono); font-size: 11.5px; color: var(--muted); }
details.hist summary:hover { color: var(--chalk); }
.timeline { border-left: 2px solid var(--faint); margin: 10px 0 4px 5px; padding-left: 16px; display: flex; flex-direction: column; gap: 8px; }
.tl { font-family: var(--mono); font-size: 11.5px; color: var(--muted); position: relative; }
.tl::before { content: ""; position: absolute; left: -21px; top: 5px; width: 7px; height: 7px; border-radius: 50%; background: var(--bg); border: 1.5px solid var(--muted); }
.tl .k { color: var(--chalk); }
.tl.good::before { border-color: var(--solved); }
.tl.bad::before { border-color: var(--danger); }
.tl.gold::before { border-color: var(--gold); }

/* tables */
table.data { width: 100%; border-collapse: collapse; font-family: var(--mono); font-size: 12px; }
table.data th { text-align: left; color: var(--muted); font-weight: 400; text-transform: uppercase; letter-spacing: 0.06em; font-size: 10.5px; padding: 6px 10px; border-bottom: 1px solid var(--faint); }
table.data td { padding: 6px 10px; border-bottom: 1px solid rgba(233,228,214,0.06); }
table.data tr:hover td { background: var(--surface-2); }
.tablewrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; padding: 6px 8px 10px; }

/* leaderboards */
.anvils { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(440px, 100%), 1fr)); gap: 16px; }
.anvil { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; padding: 18px 20px; }
.anvil .row1 { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.anvil h4 { font-size: 19px; font-weight: 550; }
.anvil .ob { font-family: var(--mono); font-size: 11px; color: var(--muted); margin: 6px 0 4px; word-break: break-word; }
.lb { margin-top: 14px; }
.lb .lb-title { font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.lb .rowbar { display: grid; grid-template-columns: 150px 1fr 92px; align-items: center; gap: 10px; padding: 4px 0; border-radius: 4px; }
.lb .rowbar:hover { background: var(--surface-2); }
.lb .who { font-family: var(--mono); font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lb .who .crown { color: var(--gold); }
.lb .track { height: 14px; position: relative; }
.lb .bar { position: absolute; inset: 0 auto 0 0; border-radius: 0 4px 4px 0; background: var(--solved); min-width: 3px; }
.lb .rowbar.ref .bar { background: var(--muted); opacity: 0.55; }
.lb .val { font-family: var(--mono); font-size: 12px; color: var(--muted); text-align: right; }
.lb .val .speed { display: block; font-size: 10px; color: var(--gold); }
.anvil .foot { margin-top: 12px; font-family: var(--mono); font-size: 11px; color: var(--muted); }
.anvil .foot .ok { color: var(--solved); }

/* anvil lanes: one fixed color per lane, used in boards, charts, matrix */
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 2px; margin-right: 6px; vertical-align: baseline; }
.lanes-legend { display: flex; flex-wrap: wrap; gap: 4px 16px; margin: 8px 0 2px; }
.lanechip { font-family: var(--mono); font-size: 11px; color: var(--muted); white-space: nowrap; }
.lanechip a { color: var(--chalk); }

/* score-over-time chart: one per board, lower is better */
.chart { margin: 6px 0 2px; }
.chart svg { display: block; width: 100%; height: auto; }
.cgrid { stroke: var(--faint); stroke-width: 1; }
.ctick { font-family: var(--mono); font-size: 9.5px; fill: var(--muted); }
.clabel { font-family: var(--mono); font-size: 10.5px; }
.cpt { stroke: var(--surface); stroke-width: 1.5; }
.cpt:has(+ .chit:hover), .cpt:hover { r: 4.5px; }

/* the lane-by-rig matrix */
#matrix td.win { color: var(--gold); }
#matrix td, #matrix th { white-space: nowrap; }

/* worked-example walkthrough (overview) */
.walkthrough { border-left: 2px solid var(--faint); margin-left: 8px; padding-left: 26px; display: flex; flex-direction: column; gap: 26px; margin-top: 18px; }
.beat { position: relative; max-width: 46em; }
.beat::before { content: ""; position: absolute; left: -33px; top: 6px; width: 11px; height: 11px; border-radius: 50%; background: var(--bg); border: 2px solid var(--muted); }
.beat.good::before { border-color: var(--solved); }
.beat.bad::before  { border-color: var(--danger); }
.beat.gold::before { border-color: var(--gold); }
.beat .when { font-family: var(--mono); font-size: 11px; color: var(--muted); letter-spacing: 0.05em; text-transform: uppercase; }
.beat h4 { font-size: 18px; font-weight: 550; margin: 3px 0 6px; }
.beat p { color: var(--muted); font-size: 15.5px; }
.beat p code { color: var(--chalk); }
.beat .evs { margin-top: 8px; display: flex; gap: 6px; flex-wrap: wrap; }
.beat .ev { font-family: var(--mono); font-size: 10.5px; color: var(--muted); border: 1px solid var(--faint); border-radius: 4px; padding: 1px 7px; }

/* chalk graph */
.board { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; margin-top: 30px; padding: 10px 6px 2px; overflow-x: auto; }
.board svg { display: block; min-width: 640px; width: 100%; height: auto; }
.board .cap { font-family: var(--mono); font-size: 11.5px; color: var(--muted); padding: 8px 14px 12px; }
.gnode text { font-family: var(--mono); font-size: 12px; fill: var(--chalk); }
.gnode text.sub { fill: var(--muted); font-size: 10.5px; }
.gedge { stroke: var(--faint); stroke-width: 1.6; fill: none; }
.gedge.supersede { stroke: var(--danger); stroke-dasharray: 5 5; opacity: 0.75; }
.gedge-label { font-family: var(--mono); font-size: 10px; fill: var(--muted); }
@media (prefers-reduced-motion: no-preference) {
  .gedge { stroke-dasharray: 600; stroke-dashoffset: 600; animation: draw 1.4s ease forwards 0.2s; }
  .gedge.supersede { stroke-dasharray: 5 5; stroke-dashoffset: 0; animation: none; }
  @keyframes draw { to { stroke-dashoffset: 0; } }
}

/* entity links + detail pages */
a.cardlink { color: inherit; text-decoration: none; }
a.cardlink:hover { text-decoration: underline; text-underline-offset: 3px; }
.board svg a { cursor: pointer; }
a.idlink { color: var(--chalk); font-family: var(--mono); text-decoration: none; border-bottom: 1px dotted var(--faint); }
a.idlink:hover { border-bottom-color: var(--chalk); }
.detail-head .row1 { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.kv { display: grid; grid-template-columns: max-content 1fr; gap: 6px 18px; font-size: 14.5px; color: var(--muted); max-width: 52em; }
.kv .k { font-family: var(--mono); font-size: 12px; color: var(--muted); padding-top: 2px; }
.kv .v { color: var(--chalk); }
.leandef { margin-bottom: 14px; }
.leandef .name { font-family: var(--mono); font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.leandef pre { background: var(--surface); border: 1px solid var(--faint); border-radius: 8px; padding: 12px 16px; font-family: var(--mono); font-size: 12.5px; line-height: 1.65; overflow-x: auto; white-space: pre; color: var(--chalk); }

/* pinned lean source on sorry cards */
.card .leansrc { max-height: 340px; overflow: auto; margin-top: 8px; }

/* ledger */
.ledger { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; font-family: var(--mono); font-size: 12px; line-height: 1.75; padding: 14px 18px; max-height: 420px; overflow: auto; }
.ledger .l { display: flex; gap: 12px; color: var(--muted); white-space: nowrap; }
.ledger .seq { color: var(--faint); min-width: 3ch; text-align: right; }
.ledger .k { min-width: 16ch; }
.ledger .k.verdict-true { color: var(--solved); }
.ledger .k.verdict-false { color: var(--danger); }
.ledger .k.slash, .ledger .k.supersede { color: var(--danger); }
.ledger .k.payout, .ledger .k.fund { color: var(--gold); }

/* prose + code blocks (download / explainers) */
.prose { max-width: 48em; color: var(--muted); font-size: 16px; }
.prose h4 { color: var(--chalk); font-size: 18px; margin: 22px 0 8px; font-weight: 550; }
.prose p { margin-bottom: 12px; }
.prose strong { color: var(--chalk); font-weight: 550; }
.codeblock { background: var(--bg); border: 1px solid var(--faint); border-radius: 8px; padding: 12px 16px; font-family: var(--mono); font-size: 12.5px; line-height: 1.7; color: var(--chalk); overflow-x: auto; margin: 10px 0 16px; white-space: pre; }
.codeblock .c { color: var(--muted); }

.lede { color: var(--muted); max-width: 46em; margin-bottom: 22px; font-size: 16px; }
.lede code { color: var(--chalk); }
footer { border-top: 1px solid var(--faint); margin-top: 70px; padding: 26px 0 42px; color: var(--muted); font-size: 14px; }
footer .wrap { display: flex; gap: 24px; flex-wrap: wrap; }
footer .right { margin-left: auto; font-family: var(--mono); font-size: 12px; }

/* dataset banner: shown only on the demo dataset */
.dataset-banner { background: rgba(185, 138, 36, 0.12); border-bottom: 1px solid var(--open); }
.dataset-banner .wrap { padding: 8px 0; font-size: 13px; color: var(--muted); }
.dataset-banner strong { color: var(--open); }
.dataset-banner code { color: var(--chalk); }

/* corpus panel: recognized external bodies of verified work */
.corpus { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 14px; }
.corpus .card h4 a { text-decoration: none; }
.corpus .cstats { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 10px 0 8px; }
.corpus .cstats span { font-size: 13px; color: var(--muted); }
.corpus .cstats b { color: var(--chalk); font-weight: 600; margin-right: 5px; }
.corpus .src { font-size: 12px; color: var(--muted); font-family: var(--mono); overflow-wrap: anywhere; }

/* proposal cards on the frontier */
.card .prop-body { color: var(--muted); font-size: 14px; line-height: 1.55; overflow-wrap: anywhere; }

/* clumps: candidate statements grouped by proven equivalence */
.clump { border: 1px solid var(--faint); border-radius: 6px; padding: 10px 12px; margin: 10px 0; }
.clump .row1 { margin-bottom: 6px; }
.clump-member { padding: 6px 0 2px; border-top: 1px dashed var(--faint); }
.clump-member:first-of-type { border-top: 0; }
.clump-member .prop-body { margin: 3px 0 0; }

/* the terms glossary (index): one card per term instead of a wall of prose */
/* how.html: the path of one problem */
ol.path { list-style: none; counter-reset: step; margin: 4px 0 0; padding: 0; max-width: 52em; }
ol.path li { counter-increment: step; position: relative; padding: 0 0 24px 46px; }
ol.path li::before { content: counter(step); position: absolute; left: 0; top: -3px; width: 28px; height: 28px; border-radius: 50%; border: 1px solid var(--gold); color: var(--gold); font-family: var(--mono); font-size: 13px; display: flex; align-items: center; justify-content: center; }
ol.path li:not(:last-child)::after { content: ""; position: absolute; left: 14px; top: 29px; bottom: 3px; width: 1px; background: var(--faint); }
ol.path b { display: block; font-family: var(--mono); font-weight: 500; font-size: 13px; color: var(--gold); letter-spacing: 0.04em; margin-bottom: 4px; }
ol.path span { color: var(--muted); font-size: 15px; line-height: 1.55; }
ol.path code { color: var(--chalk); }
.tgroup { margin-top: 24px; }
.tgroup > h4 { font-family: var(--mono); font-size: 12px; font-weight: 500; letter-spacing: 0.07em; text-transform: uppercase; color: var(--chalk); margin: 0 0 12px; }

dl.terms { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 14px; margin: 0; }
dl.terms > div { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; padding: 14px 16px 12px; }
dl.terms dt { font-family: var(--mono); font-size: 12.5px; color: var(--gold); letter-spacing: 0.04em; margin-bottom: 7px; }
dl.terms dd { margin: 0; color: var(--muted); font-size: 14.5px; line-height: 1.55; }
dl.terms dd code { color: var(--chalk); }

/* lean syntax highlighting (hiLean in razor.js) */
.lk { color: #79A8CF; }
.lc { color: var(--muted); font-style: italic; opacity: 0.85; }
.lstr { color: var(--gold); }
.lsorry { color: var(--danger); font-weight: 600; }
a.mlink { color: var(--solved); text-decoration: underline dotted; text-underline-offset: 3px; }
a.mlink:hover { text-decoration-style: solid; text-decoration-color: var(--solved); }

/* rejected / forged chips */
.chip.bad { color: var(--danger); border-color: var(--danger); }

/* the informal statement, shown before the Lean */
.informal { color: var(--chalk); font-size: 15px; line-height: 1.5; max-width: 46em; }
.card .informal { color: var(--muted); font-size: 14px; }

/* featured problem (index) */
.featured { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; padding: 22px 24px 18px; margin-top: 26px; }
.featured h3 { font-size: 24px; font-weight: 500; font-style: italic; margin: 4px 0 8px; }
.featured .informal { margin: 8px 0 14px; }
.featured .parts { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 4px; }
.featured .part { font-family: var(--mono); font-size: 11.5px; border: 1px solid var(--faint); border-radius: 6px; padding: 4px 9px; color: var(--muted); text-decoration: none; }
.featured .part.solved { color: var(--solved); border-color: var(--solved); }
.featured .part.open { color: var(--open); border-color: var(--open); }
.featured .go { font-family: var(--mono); font-size: 12.5px; color: var(--gold); text-decoration: none; }
.featured .go:hover { text-decoration: underline; }

/* call-to-action row (index) */
.cta { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 20px; }
.cta a { font-family: var(--mono); font-size: 13px; text-decoration: none; border: 1px solid var(--faint);
  border-radius: 999px; padding: 7px 16px; color: var(--chalk); }
.cta a:hover { border-color: var(--gold); color: var(--gold); }
.cta a.primary { border-color: var(--gold); color: var(--gold); }

/* the open-window line under the stats */
.window-line { margin-top: 18px; font-family: var(--mono); font-size: 13px; color: var(--gold); }
.window-line a { color: inherit; }

/* progress bars: solved vs open, segment per part */
.progress { display: inline-flex; align-items: center; gap: 10px; }
.pbar { display: inline-flex; gap: 3px; width: 150px; }
.pbar i { display: block; height: 8px; flex: 1; border-radius: 2px; background: var(--faint); }
.pbar i.done { background: var(--solved); }
.pbar.cont { gap: 0; background: var(--faint); border-radius: 2px; overflow: hidden; }
.pbar.cont i { flex: none; border-radius: 0; }
.plabel { font-family: var(--mono); font-size: 11.5px; color: var(--muted); white-space: nowrap; }

/* the activity feed: log events as sentences */
.feed { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px; padding: 8px 18px; }
.feedrow { display: flex; align-items: baseline; gap: 14px; padding: 8px 0; border-top: 1px dashed var(--faint); font-size: 15px; }
.feedrow:first-child { border-top: 0; }
.feedrow .ft { font-family: var(--mono); font-size: 11px; color: var(--muted); min-width: 8.5ch; white-space: nowrap; }
.feedrow .fs { color: var(--muted); }
.feedrow .fs b, .feedrow .fs .idlink { color: var(--chalk); }
.feedrow .fseq { margin-left: auto; font-family: var(--mono); font-size: 10.5px; color: var(--faint); }
.feedrow.good .fs { color: var(--chalk); }
.feedrow.gold .ft { color: var(--gold); }
.feedrow.bad .ft { color: var(--danger); }

/* sorry families on the frontier */
.family { margin-bottom: 26px; }
.family-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; padding: 8px 2px 10px; }
.family-head h4 { font-size: 18px; font-weight: 500; font-style: italic; }
.family-head h4 a { text-decoration: none; }
.family-head h4 a:hover { text-decoration: underline; }
.family-head .fmeta { font-family: var(--mono); font-size: 11.5px; color: var(--muted); }
.family-head .progress { margin-left: auto; }

/* collapsed sort & filter controls: summary sits beside the search box,
   the selects wrap onto their own row when opened */
details.ctl { display: contents; }
details.ctl summary { cursor: pointer; font-family: var(--mono); font-size: 12.5px; color: var(--muted); padding: 6px 0; list-style-position: inside; }
details.ctl summary:hover { color: var(--chalk); }
details.ctl[open] summary { color: var(--chalk); }
details.ctl .ctl-body { flex: 1 0 100%; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

/* verify-it-yourself box on sorry pages */
.verify { margin-top: 10px; }
.verify .codeblock { margin: 8px 0 6px; }
.verify .note { font-size: 12.5px; color: var(--muted); font-family: var(--mono); overflow-wrap: anywhere; }

/* backlog rows on the frontier */
.backlog-row { display: flex; align-items: baseline; gap: 10px; padding: 7px 0 5px; border-top: 1px dashed var(--faint); }
.backlog-row:first-of-type { border-top: 0; }
.backlog-row .cardlink { flex: 1; }
.backlog-row .src-link { font-family: var(--mono); font-size: 11px; color: var(--muted); white-space: nowrap; }

/* splits: registered plans reducing a sorry to child sorries + a glue sorry */
.card .split { border: 1px solid var(--faint); border-left: 3px solid var(--open); border-radius: 6px;
  padding: 8px 12px; margin: 10px 0 0; display: flex; flex-direction: column; gap: 3px;
  font-size: 13px; color: var(--muted); }
.card .split .k { color: var(--chalk); font-family: var(--mono); }
.card .split .note { font-style: italic; }

/* anvil index: challenge cards */
.card.chal { gap: 8px; }
.card.chal h4 { font-size: 18px; }
.card.chal .champs { display: flex; flex-direction: column; gap: 3px; font-family: var(--mono); font-size: 12px; }
.card.chal .champs .crown { color: var(--gold); }
.card.chal .meta { margin-top: 2px; }
.chart.mini { margin: 2px 0 0; }
.chart.mini svg { height: 46px; width: 100%; }

/* anvil: champions table and boards-held column */
#champions .boards-held { font-size: 11px; color: var(--muted); max-width: 420px; white-space: normal; }

/* challenge page */
a.backlink { font-family: var(--mono); font-size: 12px; color: var(--muted); text-decoration: none; }
a.backlink:hover { color: var(--chalk); }
.lb.boardcard { background: var(--surface); border: 1px solid var(--faint); border-radius: 10px;
  padding: 14px 18px 12px; margin-top: 14px; }
.lb.boardcard .chart { margin-top: 10px; border-top: 1px dashed var(--faint); padding-top: 10px; }

/* a stat whose label is a link is an invitation; keep it quiet until hovered */
.stat a { color: inherit; text-decoration: underline dotted; text-underline-offset: 3px; }
.stat a:hover { color: var(--chalk); }

/* get-started details expanders */
.prose > details { border: 1px solid var(--faint); border-radius: 10px; padding: 10px 16px; margin: 10px 0; background: var(--surface); }
.prose > details summary { cursor: pointer; font-family: var(--mono); font-size: 13px; color: var(--chalk); padding: 2px 0; }
.prose > details summary:hover { color: var(--gold); }
.prose > details[open] summary { margin-bottom: 6px; }

/* one narrow-screen pass: the auto-fill grids already collapse on their own;
   these are the few fixed-width leftovers that do not */
@media (max-width: 640px) {
  .pagehead { padding-top: 18px; }
  .pagehead h2 { font-size: 24px; }
  .stats { gap: 14px; }
  .stat b { font-size: 21px; }
  .lb .rowbar { grid-template-columns: 92px 1fr 64px; gap: 6px; }
  .ledger { font-size: 11px; }
  .cta a { padding: 8px 12px; }
}

/* browser participation: curate button and the propose form */
.curate-btn { font-family: var(--mono); font-size: 12.5px; color: var(--gold); background: none;
  border: 1px solid var(--faint); border-radius: 8px; padding: 6px 12px; cursor: pointer; }
.curate-btn:hover { border-color: var(--gold); }
.curate-btn:disabled { opacity: 0.6; cursor: default; }
.curate-msg { font-family: var(--mono); font-size: 12px; color: var(--muted); margin-left: 10px; }
form.participate { display: flex; flex-direction: column; gap: 10px; max-width: 620px; }
form.participate label { font-family: var(--mono); font-size: 12.5px; color: var(--muted); display: flex; flex-direction: column; gap: 4px; }
form.participate input, form.participate textarea { font: 15px/1.5 var(--serif, serif); color: var(--chalk);
  background: var(--surface); border: 1px solid var(--faint); border-radius: 8px; padding: 8px 10px; }
form.participate input:focus, form.participate textarea:focus { outline: none; border-color: var(--gold); }
form.participate button { align-self: flex-start; font-family: var(--mono); font-size: 13px; color: var(--bg);
  background: var(--gold); border: none; border-radius: 8px; padding: 9px 16px; cursor: pointer; }
form.participate button:disabled { opacity: 0.6; cursor: default; }
form.participate .hp { position: absolute; left: -9999px; height: 0; overflow: hidden; }
.form-msg { font-family: var(--mono); font-size: 13px; }
.form-msg.ok { color: var(--gold); }
.form-msg.bad { color: var(--danger); }
