/* Fineprint site: layout and components on the Stamped Ledger tokens (tokens.css, loaded first; see
   DESIGN.md). Colour, faces, radius, borders and shadows come only from the token variables. The
   approved home comp (design/comp-home.html) is the reference for layout, spacing and type sizes. */

/* --- Faces: self-hosted, Latin, variable (LICENSES.md beside them) ------------------------- */
@font-face { font-family: "Fraunces"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("fonts/fraunces-latin-opsz-normal.woff2") format("woff2"); }
@font-face { font-family: "Fraunces"; font-style: italic; font-weight: 100 900; font-display: swap; src: url("fonts/fraunces-latin-opsz-italic.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap; src: url("fonts/inter-latin-wght-normal.woff2") format("woff2"); }
@font-face { font-family: "JetBrains Mono"; font-style: normal; font-weight: 100 800; font-display: swap; src: url("fonts/jetbrains-mono-latin-wght-normal.woff2") format("woff2"); }

/* --- Base ------------------------------------------------------------------------------------ */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; caret-color: var(--accent); scrollbar-color: var(--ink-muted) var(--paper-sunken); }
body { background: var(--paper); min-height: 100vh; display: flex; flex-direction: column; }
main { flex: 1 0 auto; }
::selection { background: var(--accent); color: var(--accent-ink); }
a { text-underline-offset: 3px; }
a:hover { text-decoration-color: var(--accent); }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { display: block; max-width: 100%; height: auto; }
time, .num { font-variant-numeric: tabular-nums; }

.wrap { max-width: var(--content-max); margin: 0 auto; padding: 0 16px; }
@media (min-width: 700px) { .wrap { padding: 0 24px; } }
@media (min-width: 900px) { .wrap { padding: 0 var(--gutter); } }

.skip { position: absolute; left: 16px; top: -100px; z-index: 10; padding: 10px 14px; font: 500 14px/1 var(--font-body); color: var(--paper); background: var(--ink); border-radius: var(--r); text-decoration: none; }
.skip:focus { top: 12px; }

.label, .meta, .evidence, .origin, .notice, .meterline, .delta, .tag { font-family: var(--font-data); }
.label { font-size: 11.5px; line-height: 1.3; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); }
/* Read by a screen reader, not shown (the delta badge in words, table captions). */
.vh { position: absolute !important; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* --- Banner, header, nav --------------------------------------------------------------------- */
.notice { background: var(--ink); color: var(--paper); font-size: 11.5px; line-height: 1.5; letter-spacing: .04em; padding: 8px 0; }

.top { border-bottom: var(--border); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 24px; padding-top: 18px; padding-bottom: 16px; }
.wordmark { gap: 12px; font: 600 22px/1 var(--font-display); text-decoration: none; }
.stamp { display: inline-flex; align-items: center; gap: 6px; }
.stamp::before { content: none; } /* the stamp's words are in the markup, so they can say PAUSED */
.live { width: 7px; height: 7px; }
@keyframes pulse { 50% { opacity: .3; } }
nav ul { display: flex; gap: 4px; }
nav a { display: block; padding: 8px 10px; font: 500 14px/1 var(--font-body); text-decoration: none; border-bottom: 2px solid transparent; transition: border-color var(--dur-fast) var(--ease); }
nav a:hover { border-bottom-color: var(--rule); }
nav a[aria-current="page"] { border-bottom-color: var(--accent); }

/* --- Home: the opening (the site's one Persuade surface), the live line ----------------------------- */
/* The line, the lede and the two actions; beside them from 1100px (under them below that) the featured catch,
   the product itself, with the words kept in view beside it as it scrolls; under both, the live line, ruled
   like the foot of a ledger page. Below 1100px the live line comes straight after the words. */
.opening { display: grid; row-gap: 28px; padding-top: 40px; }
@media (min-width: 900px) { .opening { row-gap: 36px; padding-top: 64px; } }
@media (min-width: 1100px) {
  .opening.has-shot { grid-template-columns: minmax(0, 9fr) minmax(0, 11fr); grid-template-areas: "text shot"; column-gap: 48px; }
  .opening.has-shot .opening-text { grid-area: text; align-self: start; position: sticky; top: 32px; padding-top: 4px; }
  .opening.has-shot .featured { grid-area: shot; }
}
.hero { max-width: 16ch; text-wrap: balance; }
@media (min-width: 900px) { .hero { font-size: 52px; line-height: 1.02; } }
.lede { margin-top: 20px; max-width: 56ch; font-size: 17px; line-height: 1.5; color: var(--ink-soft); }
.opening .actions { margin-top: 28px; }
/* The live line is the last line of the opening's words, on its own row under the buttons at every width. */
.opening-text .liveline { margin-top: 28px; }
/* One line on a laptop; narrower, it breaks between its parts, never inside one. */
.liveline { padding-top: 12px; font: 500 12px/1.7 var(--font-data); letter-spacing: .06em; text-transform: uppercase; font-variant-numeric: tabular-nums; color: var(--ink-muted); border-top: var(--border); }
.liveline span { white-space: nowrap; }
.liveline span:first-child { color: var(--ink); }

.stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; align-content: start; }
@media (min-width: 900px) { .stats { grid-template-columns: 1fr; } }
.stat { padding: 12px 14px; }
.stat b { font-size: 30px; margin-bottom: 6px; }
.stat span { line-height: 1.2; opacity: .72; }
.stat.is-key span { opacity: .9; }

/* --- Sections and cards ---------------------------------------------------------------------- */
section { padding-top: 56px; }
section > h2 { margin-bottom: 16px; }
.meta { display: flex; flex-wrap: wrap; gap: 4px 12px; font-size: 11.5px; line-height: 1.3; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.meta span { color: var(--ink-muted); }
.evidence { margin-top: 12px; font: 400 11.5px/1.5 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); overflow-wrap: anywhere; }
.page-note { max-width: var(--measure); margin: -4px 0 16px; font: var(--t-small); color: var(--ink-muted); }

.btn { display: inline-block; padding: 11px 16px; text-decoration: none; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; }

/* --- Delta badge and tags (DESIGN.md "Catch card": ink on paper) ------------------------------ */
.delta, .tag { display: inline-block; padding: 5px 7px; font-size: 11.5px; font-weight: 400; line-height: 1; letter-spacing: .04em; font-variant-numeric: tabular-nums; white-space: nowrap; border: var(--hairline); border-color: var(--ink); border-radius: var(--r); background: var(--paper); }
/* A label, not a change: the same box, quieter. */
.tag { text-transform: uppercase; letter-spacing: .06em; color: var(--ink-muted); border-color: var(--ink-muted); }
.layout-note { margin-top: 6px; font: var(--t-small); color: var(--ink-muted); }
.meta.is-quiet { color: var(--ink-muted); }

/* --- The change feed: catch cards (DESIGN.md "Catch card") ----------------------------------- */
.feed { display: grid; gap: 16px; }
/* Thumbnail and body side by side. The foot (badge row, evidence line) spans the whole card below 700px,
   so the evidence line is not squeezed into the narrow column beside the thumbnail. */
.catch { display: grid; grid-template-columns: 72px minmax(0, 1fr); column-gap: 14px; padding: 14px; }
.catch-foot { grid-column: 1 / -1; min-width: 0; }
@media (min-width: 700px) {
  .catch { grid-template-columns: 92px minmax(0, 1fr); column-gap: 18px; padding: 16px; }
  .catch > .thumb { grid-row: 1 / span 2; }
  .catch-foot { grid-column: 2; }
}
.catch:hover { transform: translate(-1px, -1px); box-shadow: var(--shadow-hover); }
.thumb { display: block; align-self: start; text-decoration: none; aspect-ratio: 1; overflow: hidden; background: var(--paper-sunken); border: var(--hairline); border-radius: var(--r); }
.thumb img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.thumb-none { display: flex; align-items: center; justify-content: center; height: 100%; padding: 4px; text-align: center; font: 500 11.5px/1.2 var(--font-data); letter-spacing: .04em; text-transform: uppercase; color: var(--ink-muted); }
.catch h3 { margin-top: 4px; font: 600 18px/1.3 var(--font-display); letter-spacing: -.01em; }
.catch h3 a { text-decoration: none; }
.catch h3 a:hover { text-decoration: underline; text-decoration-color: var(--accent); }
.summary { max-width: 68ch; margin-top: 4px; color: var(--ink-soft); display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.summary.is-pending { color: var(--ink-muted); }
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin-top: 10px; }
.origin { font-size: 11.5px; letter-spacing: .02em; color: var(--ink-muted); }

.empty { padding: 20px; max-width: 68ch; color: var(--ink-soft); }
.more { margin-top: 20px; }
.retired-note { margin-top: 24px; font: var(--t-small); color: var(--ink-muted); }

/* --- Page view: header ------------------------------------------------------------------------ */
.page-head { padding-top: 36px; }
@media (min-width: 900px) { .page-head { padding-top: 52px; } }
.page-head h1 { max-width: 28ch; text-wrap: balance; overflow-wrap: anywhere; }
.page-url { margin-top: 8px; font: var(--t-mono); overflow-wrap: anywhere; }
.page-url a { color: var(--ink-soft); }
.page-facts { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; margin-top: 14px; font: var(--t-small); color: var(--ink-soft); }
.page-kind { font: var(--t-label); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); }
.page-facts code { font-size: 12px; }
.page-tally { margin-top: 10px; font: 500 12px/1.5 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.state-line { width: fit-content; max-width: min(100%, 68ch); margin-top: 16px; padding: 10px 14px; font: var(--t-small); color: var(--ink); background: var(--paper-sunken); border: var(--border); border-radius: var(--r); }

/* --- Page view: timeline and as-of scrubber (DESIGN.md "Timeline", "Page as-of scrubber") ------ */
section.history { padding-top: 28px; }
.tl { display: grid; padding: 0; }
@media (min-width: 900px) { .tl { grid-template-columns: minmax(0, 1fr) 320px; } }
.tl-strip, .asof { padding: 16px; }
@media (min-width: 700px) { .tl-strip, .asof { padding: 18px 22px; } }
.asof { border-top: var(--hairline); }
@media (min-width: 900px) { .asof { border-top: 0; border-left: var(--hairline); } }
.tl-note { max-width: 60ch; font: var(--t-small); color: var(--ink-muted); }
/* The track: 2px ink. Its side margins are half a dot's target, so a dot at either end stays in the panel. */
.tl-track { position: relative; height: 2px; margin: 30px 12px 16px; background: var(--ink); }
.tl-track li { position: absolute; top: 1px; transform: translate(-50%, -50%); }
/* A 24px target around the 12px paper dot with its 2px ink border; the selected version is the filled accent dot. */
.dot { position: relative; display: block; width: 24px; height: 24px; border-radius: 50%; }
.dot::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: var(--paper); border: 2px solid var(--ink); transition: background-color var(--dur-fast) var(--ease); }
.dot:hover::before { background: var(--accent-wash); }
.dot.is-on::before { background: var(--accent); border-color: var(--accent); }
.dot:focus-visible { outline-offset: 0; }
.tl-ends { display: flex; justify-content: space-between; gap: 12px; font: 400 11.5px/1.3 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); }
.asof label { display: block; font: var(--t-h3); letter-spacing: -.01em; }
.asof-hint { margin-top: 2px; font: var(--t-small); color: var(--ink-muted); }
.asof-row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.asof .input { flex: 1 1 180px; width: auto; min-width: 0; font: var(--t-mono); font-size: 14px; }
.asof .btn { flex: 0 0 auto; }
.asof-note { max-width: 48ch; margin-top: 10px; font: var(--t-small); color: var(--ink-soft); }
.asof-note.field-error { color: var(--bad); }

/* --- Page view: the version list and the version card ------------------------------------------ */
/* The version card comes first (on a phone it is the thing itself, right under the timeline); from 900px the
   list takes the left column beside it. */
.history-grid { display: grid; gap: 24px; margin-top: 24px; }
@media (min-width: 900px) {
  .history-grid { grid-template-columns: 320px minmax(0, 1fr); gap: 28px; align-items: start; }
  .history-grid > .versions { grid-column: 1; grid-row: 1; }
  .history-grid > .vcard { grid-column: 2; grid-row: 1; }
}
.versions h2 { margin-bottom: 10px; }
.versions ol { background: var(--paper-raised); border: var(--border); border-radius: var(--r); box-shadow: var(--shadow); }
.versions li + li { border-top: var(--hairline); }
/* A row: the small screenshot beside its time and badge, the summary under both at full width. */
.vrow { display: grid; grid-template-columns: 56px minmax(0, 1fr); column-gap: 12px; padding: 12px 14px; color: inherit; text-decoration: none; transition: background-color var(--dur-fast) var(--ease); }
.vrow:hover { background: var(--paper); }
.vrow.is-on { background: var(--accent-wash); }
.vrow-shot { display: block; width: 56px; height: 56px; overflow: hidden; background: var(--paper-sunken); border: var(--hairline); border-radius: var(--r); }
.vrow-shot img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.vrow-head { display: flex; flex-direction: column; align-items: flex-start; gap: 7px; min-width: 0; padding-top: 2px; }
.vrow-time, .vcard-time { font-variant-numeric: tabular-nums; color: var(--accent); }
.vrow-time { font: 500 11.5px/1.3 var(--font-data); letter-spacing: .04em; }
.vrow-time.is-quiet { color: var(--ink-muted); }
/* A long badge ("+3 −4 blocks · +29 −10 ~39 facts") wraps inside the 320px list instead of running out of it. */
.vrow-head .delta { max-width: 100%; white-space: normal; line-height: 1.35; }
.vrow-sum { grid-column: 1 / -1; margin-top: 8px; font: var(--t-small); color: var(--ink-soft); overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.vrow-sum.is-pending { color: var(--ink-muted); }
/* Under a list cut to the newest versions: how many, and the JSON with every one. */
.older-note { max-width: var(--measure); margin-top: 10px; font: var(--t-small); color: var(--ink-muted); }
.pick .older-note { flex: 1 1 100%; margin-top: 0; }
.vrow:hover .vrow-sum { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 3px; }

.vcard { min-width: 0; padding: 18px; scroll-margin-top: 16px; }
@media (min-width: 700px) { .vcard { padding: 24px 28px; } }
.vcard-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 12px 20px; }
.vcard-head h2 { font: var(--t-h2); }
@media (max-width: 699.98px) { .vcard-head h2 { font-size: 22px; } }
.vcard-time { white-space: nowrap; }
.vcard-time.is-quiet { color: inherit; }
/* The as-of stamp: the header stamp's treatment, at the smallest text size the site allows. */
.stamp.is-asof { margin-top: 2px; padding: 6px 9px; font-size: 11.5px; white-space: nowrap; background: var(--paper-raised); }
.vcard .row { margin-top: 12px; }
.vcard-summary { max-width: 62ch; margin-top: 14px; font: 500 18px/1.4 var(--font-display); letter-spacing: -.01em; text-wrap: pretty; overflow-wrap: anywhere; }
@media (min-width: 700px) { .vcard-summary { font-size: 20px; line-height: 1.35; } }
.vcard-summary.is-pending { color: var(--ink-muted); }
.vcard .origin { display: block; margin-top: 6px; }
.vshot { margin-top: 22px; }
.vshot-link { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--paper-sunken); border: var(--border); border-radius: var(--r); }
.vshot-link img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
figcaption { margin-top: 8px; font: 400 11.5px/1.4 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); }
/* No screenshot: said in words, in the box the screenshot would fill, never a broken image. */
.vshot-none { display: flex; flex-direction: column; justify-content: center; gap: 8px; min-height: 180px; margin-top: 22px; padding: 20px; font: var(--t-small); color: var(--ink-soft); background: var(--paper-sunken); border: var(--hairline); border-radius: var(--r); }
@media (min-width: 700px) { .vshot-none { aspect-ratio: 16 / 10; min-height: 0; } }
.vshot-state { font: 500 14px/1.4 var(--font-data); letter-spacing: .02em; color: var(--ink); }
.vshot-links { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.vfacts { margin-top: 26px; }
.vfacts h3 { margin-bottom: 10px; }
.facts-note { padding: 12px 14px; font: var(--t-small); color: var(--ink-soft); background: var(--paper-sunken); border-radius: var(--r); }
.facts { font: var(--t-small); }
.facts .price { font: var(--t-mono); font-variant-numeric: tabular-nums; overflow-wrap: break-word; }
.facts .unit { color: var(--ink-muted); }
@media (max-width: 699.98px) { .facts .unit { display: block; } }
/* Row headers name a fact; tokens.css styles every th as a column label, so these are set back to text. */
.table tbody th { padding: 10px 12px; font: 600 13px/1.45 var(--font-body); letter-spacing: 0; text-transform: none; text-align: left; color: var(--ink); background: none; border-top: var(--hairline); overflow-wrap: break-word; }
@media (max-width: 699.98px) { .table th, .table td { padding: 8px 9px; } }
.vcard .actions { margin-top: 24px; }
.vlinks { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 16px; font: var(--t-small); }
.vtext { margin-top: 28px; padding-top: 20px; border-top: var(--hairline); }
.vtext .origin { margin-top: 4px; }
/* Up to a few hundred KB of recorded text: wrapped, never wider than the card, scrolled in its own box;
   #text lands with the heading above it in view. */
.vtext pre { max-height: 70vh; scroll-margin-top: 96px; margin: 12px 0 0; padding: 14px 16px; overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; color: var(--ink); background: var(--paper-sunken); border: var(--hairline); border-radius: var(--r); }

/* --- Page view: compare form ---------------------------------------------------------------------- */
.pick { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 16px; max-width: 780px; padding: 16px; }
.field { display: flex; flex: 1 1 220px; flex-direction: column; gap: 6px; min-width: 0; }
.field label { font: var(--t-label); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); }
.field select { font: var(--t-mono); font-size: 14px; }
.pick .btn { flex: 0 0 auto; }

/* --- Page view: the check log --------------------------------------------------------------------- */
.checks-line { font: 500 19px/1.35 var(--font-display); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.checks .page-note { max-width: 68ch; margin: 6px 0 0; }
/* As wide as its marks and key need, no wider: a tally, not a chart. */
.marks-panel { width: fit-content; min-width: min(100%, 360px); max-width: 100%; margin-top: 16px; padding: 18px 20px 16px; }
/* One mark a run, oldest first, on a common baseline: tall for a read that mattered (accent for a change,
   ink for the baseline, hollow for noise), short for one that found the page as it was. */
.marks { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 5px; }
.mark { position: relative; display: block; flex: none; width: 10px; height: 26px; border-radius: var(--r); background: var(--ink-faint); }
.mark-change { background: var(--accent); }
.mark-baseline { background: var(--ink); }
.mark-noise { background: transparent; border: var(--border); border-color: var(--ink-muted); }
.mark-unchanged { height: 10px; }
.mark-failed { height: 10px; background: transparent; border: var(--border); border-color: var(--ink-muted); }
/* A pulled check: a small ink dot under its mark. */
.mark.is-pulled::after { content: ""; position: absolute; left: 50%; bottom: -9px; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: var(--ink); }
.marks-key { display: flex; flex-wrap: wrap; gap: 10px 20px; margin-top: 22px; padding-top: 12px; font: 400 11.5px/1.3 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); border-top: var(--hairline); }
.marks-key li { display: inline-flex; align-items: center; gap: 8px; }
.marks-key .mark { width: 8px; }
.marks-key .mark-change, .marks-key .mark-noise, .marks-key .mark-baseline { height: 18px; }
.marks-key .mark.is-pulled { margin-bottom: 9px; }
.all-checks { margin-top: 18px; }
.all-checks summary { display: list-item; width: max-content; padding: 6px 0; font: 500 14px/1.4 var(--font-body); cursor: pointer; }
.all-checks summary:hover { text-decoration: underline; text-decoration-color: var(--accent); text-underline-offset: 3px; }
.checks-table { max-width: 780px; margin-top: 10px; font: var(--t-small); }
.checks-table .when { font: var(--t-mono); font-size: 12px; }

/* --- A recorded block (src/site/blockText.tsx): text only, in the block's own shape ------------ */
:where(.diff-before, .diff-after, .diff-added, .diff-removed) > * + * { margin-top: 8px; }
.bt-p, .bt-list li, .bt-h { overflow-wrap: anywhere; }
.bt-h { font: 600 16px/1.35 var(--font-display); letter-spacing: -.01em; }
.bt-h1, .bt-h2 { font-size: 18px; }
.bt-list { padding-left: 1.25em; list-style: disc; }
ol.bt-list { list-style: decimal; }
.bt-list li + li { margin-top: 4px; }
.bt-list li::marker { color: var(--ink-muted); }
.bt-table { font: var(--t-mono); font-variant-numeric: tabular-nums; }
.bt-row { display: block; white-space: pre-wrap; overflow-wrap: anywhere; }
:where(.bt-p, .bt-list, .bt-h) code { font: var(--t-mono); font-size: .9em; overflow-wrap: anywhere; }
/* Where a long block was cut, and what was left out. Inline blocks, so a removed block's strike stays off them. */
.bt-cut, .bt-more { display: inline-block; color: var(--ink-muted); }
.bt-cut { font: 500 15px/1 var(--font-data); letter-spacing: .1em; }
.bt-more { font: var(--t-small); }

/* Word marks (the comp's del and ins), only inside a changed block's two sides: struck in muted ink on the
   before side, washed on the after side. */
.diff-before del { color: var(--ink-muted); text-decoration: line-through; text-decoration-thickness: 1px; }
.diff-after ins { color: var(--ink); text-decoration: none; background: var(--accent-wash); box-shadow: 0 0 0 2px var(--accent-wash); border-radius: 1px; }
/* Screen readers mostly do not say that text is struck or inserted, so each mark says it in generated text
   that is read but not seen (clipped to nothing, the .vh technique): "[removed: … ]", "[added: … ]". It
   lives here, not in the markup, so a mark holds only its words. */
.diff-before del::before, .diff-before del::after, .diff-after ins::before, .diff-after ins::after {
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap;
}
.diff-before del::before { content: " [removed: "; }
.diff-before del::after { content: " ] "; }
.diff-after ins::before { content: " [added: "; }
.diff-after ins::after { content: " ] "; }

/* --- Diff view (DESIGN.md "Diff view"): before and after in two columns, stacked on a phone --------- */
.pair { display: grid; gap: 12px; }
@media (min-width: 800px) { .pair { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; } }
.side { min-width: 0; }
.side .label { margin-bottom: 8px; }
/* A changed block: the before side sunken (its gone words struck), the after side raised with the accent bar
   (its new words washed). Only the words carry the change, never the whole block. */
.diff-before, .diff-after { padding: 12px 14px; font-size: 15px; line-height: 1.6; border-radius: var(--r); }
.diff-before { color: var(--ink-soft); background: var(--paper-sunken); }
.diff-after { color: var(--ink); background: var(--paper-raised); border: var(--hairline); border-left: 3px solid var(--accent); }
.diff-note { grid-column: 1 / -1; font: var(--t-small); color: var(--ink-muted); }
/* An added or a removed block (tokens.css: the wash with the bar, the sunken strike), at a reading measure. */
.diff-added, .diff-removed { max-width: 76ch; font-size: 15px; line-height: 1.6; border-radius: var(--r); }
.diff-added { padding: 10px 14px; color: var(--ink); }
.diff-removed { padding: 10px 14px; text-decoration-thickness: 1px; }
/* A run of added (or removed) blocks reads as one stretch: a hairline of paper between them, not a gap. */
.diff-added + .diff-added, .diff-removed + .diff-removed { margin-top: -12px; }

/* --- Compare view ---------------------------------------------------------------------------------- */
/* The page's name in the title is the way back to its history. */
.compare-head h1 a { text-decoration-color: var(--rule); text-underline-offset: 5px; }
.compare-head h1 a:hover { text-decoration-color: var(--accent); }
.compare-span { margin-top: 10px; font: 500 12px/1.5 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.compare-span time { color: var(--ink); }
.compare-lead { max-width: 68ch; margin-top: 20px; }
.compare-lead .row { margin: 0 0 10px; }
.compare-lead .vcard-summary { margin-top: 0; }
.compare-lead .origin { display: block; margin-top: 6px; }
.compare > .state-line { margin-top: 24px; }
section.facts-diff, section.diff, section.compare-shots { padding-top: 44px; }
.facts-diff .table { max-width: 780px; }
.facts-diff .facts-note { max-width: 68ch; }
.facts .what { font: var(--t-label); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); }
.facts .was { color: var(--ink-muted); }
/* The new price of a changed fact: the one accent figure on the screen. */
.facts .is-key { font-weight: 500; color: var(--accent); }
.diff-count { font: 500 19px/1.35 var(--font-display); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.diff > .page-note { max-width: 68ch; margin: 6px 0 0; }
section.diff-group { padding-top: 32px; }
.diff-section { margin-bottom: 14px; padding-bottom: 8px; font: var(--t-h3); letter-spacing: -.01em; overflow-wrap: anywhere; border-bottom: var(--hairline); }
.diff-blocks { display: grid; gap: 14px; }
.compare-shots .shots { grid-template-columns: minmax(0, 1fr); }
@media (min-width: 700px) { .compare-shots .shots { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.compare-links { margin-top: 28px; }
/* What the screen leaves out, said once under the blocks, with the way to the rest. */
.diff-rest { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; max-width: 68ch; margin-top: 28px; padding-top: 16px; font: var(--t-small); color: var(--ink-soft); border-top: var(--hairline); }

/* --- Screenshots side by side (the comp's .shots), each a figure; a missing one is said in words ------ */
.shots { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; margin-top: 24px; }
@media (min-width: 800px) { .shots { gap: 24px; } }
.shot { min-width: 0; }
.shot-link { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: var(--paper-sunken); border: var(--border); border-radius: var(--r); }
.shot-link img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.shot-none { display: flex; flex-direction: column; justify-content: center; gap: 6px; aspect-ratio: 16 / 10; padding: 12px; overflow: hidden; font: var(--t-small); color: var(--ink-soft); background: var(--paper-sunken); border: var(--hairline); border-radius: var(--r); }
.shot-none .vshot-state { font-size: 13px; }
.shot .evidence { margin-top: 6px; }

/* --- Home: the featured catch (design/comp-home.html "The latest catch, up close") ------------------- */
.feature { padding: 20px; }
@media (min-width: 700px) { .feature { padding: 28px; } }
/* Three lines at most, as in the comp: a long summary ends in an ellipsis on screen and is read whole by a screen
   reader; the full comparison shows it in full. */
.feature-summary { max-width: 62ch; margin-top: 10px; font: 500 20px/1.35 var(--font-display); letter-spacing: -.01em; text-wrap: pretty; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.feature .pair { margin-top: 24px; }
@media (max-width: 699.98px) { .feature-summary { font-size: 18px; } .feature .shot-none p + p { display: none; } }
/* In the opening, the catch is the product shot: no section gap above it, and its caption line says it is real. */
.opening .featured { padding-top: 0; }
.meta .caught { color: var(--accent); }
.meta .caught time { white-space: nowrap; }

/* --- Home: what it answers, a ruled row of three examples (no cards) ------------------------------------ */
.asks { display: grid; border-top: var(--border); }
.asks li { padding: 16px 0 18px; border-bottom: var(--hairline); }
@media (min-width: 760px) {
  .asks { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .asks li { padding: 18px 24px 4px 0; border-bottom: 0; }
  .asks li + li { padding-left: 24px; border-left: var(--hairline); }
}
.asks h3 { max-width: 26ch; font: 600 19px/1.3 var(--font-display); letter-spacing: -.01em; text-wrap: balance; }
.asks p { margin-top: 8px; font: 500 14px/1.45 var(--font-body); overflow-wrap: anywhere; }

/* --- Home: built for the bounty, each requirement beside its live proof ----------------------------------- */
.bounty .section-lede { margin-top: -6px; }
.reqs { margin-top: 22px; border-top: var(--border); }
.req { display: grid; gap: 4px; padding: 14px 0 16px; border-bottom: var(--hairline); }
@media (min-width: 900px) { .req { grid-template-columns: 240px minmax(0, 1fr) 170px; gap: 28px; align-items: baseline; padding: 16px 0 18px; } }
.req h3 { font: 600 18px/1.35 var(--font-display); letter-spacing: -.01em; }
.req-proof { max-width: 68ch; font-size: 15px; line-height: 1.55; color: var(--ink-soft); }
/* A live figure in a sentence of proof: ink, tabular, a step heavier than the words around it. */
.fig { font-weight: 600; font-variant-numeric: tabular-nums; color: var(--ink); }
.req-link { font: var(--t-small); }
@media (min-width: 900px) { .req-link { text-align: right; } }
.services-h { margin-top: 44px; font: 600 19px/1.3 var(--font-display); letter-spacing: -.01em; }
.services { max-width: 880px; margin-top: 14px; }
.services thead th { white-space: nowrap; }
.services tbody th { width: 12ch; vertical-align: top; font: 600 16px/1.45 var(--font-display); letter-spacing: -.01em; }
.services td { vertical-align: top; font-size: 15px; line-height: 1.5; color: var(--ink-soft); }
@media (max-width: 699.98px) { .services tbody th { width: 9ch; } }
.costline { margin-top: 18px; font: 500 12px/1.6 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.bounty-more { margin-top: 12px; font: 500 14px/1.45 var(--font-body); }

/* --- Home: the feed, with the stat blocks beside it (above it on a phone) -------------------------------- */
.feed-grid { display: grid; gap: 20px; }
@media (min-width: 900px) {
  .feed-grid { grid-template-columns: minmax(0, 1fr) 200px; gap: 40px; align-items: start; }
  .feed-grid > .stats { grid-column: 2; grid-row: 1; position: sticky; top: 24px; }
  .feed-grid > .feed-main { grid-column: 1; grid-row: 1; }
}
.feed-main { min-width: 0; }

/* --- Watchlist (src/site/views/watchlist.tsx) -------------------------------------------------- */
.watchlist .page-head .lede { margin-top: 14px; }
.watchlist section { scroll-margin-top: 16px; }
section.watching { padding-top: 44px; }
/* The table: dense and scannable on a desktop, ink border outside, hairlines inside; one card a row on a phone. */
.wl { font: var(--t-small); }
.wl thead th { white-space: nowrap; }
.wl tbody th, .wl td { vertical-align: top; }
.wl tbody tr { transition: background-color var(--dur-fast) var(--ease); }
.wl tbody tr:hover { background: var(--paper); }
.wl tbody .wl-page { width: 28%; min-width: 18ch; }
.wl-page a { font: 600 15px/1.3 var(--font-display); letter-spacing: -.01em; text-decoration: none; overflow-wrap: anywhere; }
.wl-page a:hover { text-decoration: underline; text-decoration-color: var(--accent); }
/* Kind and address on one line under the label; the address takes what is left and ends in an ellipsis, so it
   never widens the column (it is a zero-width flex item) and never breaks inside a word. */
.wl-meta { display: flex; gap: 10px; margin-top: 5px; font: 400 11.5px/1.4 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); }
.wl-kind { flex: none; text-transform: uppercase; letter-spacing: .06em; }
.wl-url { flex: 1 1 0; width: 0; min-width: 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.wl-status .chip { white-space: nowrap; }
.wl-note { display: block; margin-top: 3px; font: 400 11.5px/1.4 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); }
.wl-sched { min-width: 16ch; color: var(--ink-soft); }
.wl-freq, .wl-at { display: block; }
.wl-at { margin-top: 2px; font: 400 12px/1.45 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; white-space: nowrap; color: var(--ink-muted); }
.wl-sched.is-gone { color: var(--ink-muted); }
.wl-when { font: 400 12px/1.45 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.wl-d { white-space: nowrap; }
@media (min-width: 1100px) { .wl-when { white-space: nowrap; } }
/* A real change's time carries the accent, as on the catch cards and the version rows. */
.wl-when .is-change { color: var(--accent); }
.wl-none { font: var(--t-small); letter-spacing: 0; }
.wl td.num { font: 500 13px/1.45 var(--font-data); font-variant-numeric: tabular-nums; }
@media (max-width: 699.98px) {
  .wl thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .wl, .wl tbody { display: block; }
  .wl tbody tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 14px; padding: 14px; }
  .wl tbody tr + tr { border-top: var(--hairline); }
  .wl tbody th, .wl td { display: block; padding: 0; border-top: 0; }
  .wl tbody .wl-page { grid-column: 1; grid-row: 1; width: auto; min-width: 0; }
  .wl .wl-status { grid-column: 2; grid-row: 1; text-align: right; }
  .wl .wl-sched, .wl .wl-when { grid-column: 1 / -1; min-width: 0; }
  .wl .wl-sched { margin-top: 4px; }
  .wl td[data-label]::before { content: attr(data-label); display: inline-block; min-width: 13ch; margin-right: 6px; font: var(--t-label); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); }
  .wl td.num { margin-top: 4px; text-align: left; }
  .wl td.num::before { min-width: 0; }
  .wl td.num:last-child { text-align: right; }
}

/* The add form, with the slots and any refusal beside it (under it on a phone, the refusal first). */
section.add, section.find { padding-top: 64px; }
.add-grid { display: grid; gap: 16px; }
@media (min-width: 900px) {
  .add-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 360px); gap: 20px 36px; align-items: start; }
  .add-form { grid-column: 1; grid-row: 1 / span 2; }
  .refusal, .add-terms { grid-column: 2; }
  .add-grid:not(.has-refusal) .add-form { grid-row: 1; }
}
.add-form { display: grid; gap: 18px; max-width: 720px; padding: 20px; }
@media (min-width: 700px) { .add-form { padding: 24px; } }
.add-form .input { font: var(--t-mono); font-size: 14px; }
.add-form #label { font: var(--t-body); }
.add-form .btn { justify-self: start; }
.field-hint { font: var(--t-small); color: var(--ink-muted); }
.input[aria-invalid="true"] { border-color: var(--accent); }
.input:disabled { color: var(--ink-muted); background: var(--paper-sunken); border-color: var(--ink-muted); cursor: not-allowed; }
.btn:disabled, .btn:disabled:hover, .btn:disabled:active { color: var(--paper); background: var(--ink-muted); border-color: var(--ink-muted); box-shadow: none; transform: none; cursor: not-allowed; }
/* A refusal is stamped on the form, as a clerk would: the accent outline and the stamp, the reason in ink. */
.refusal { padding: 16px 18px 18px; background: var(--paper-raised); border: var(--border); border-color: var(--accent); border-radius: var(--r); }
.stamp.is-refused { padding: 6px 9px; font-size: 11.5px; background: var(--paper-raised); }
.refusal-text { max-width: 52ch; margin-top: 14px; font: 500 16px/1.45 var(--font-body); color: var(--ink); overflow-wrap: anywhere; }
.refusal-link { margin-top: 8px; font: var(--t-small); }
.add-terms { display: grid; gap: 14px; }
@media (min-width: 900px) { .add-terms { padding-top: 6px; } }
.terms-line { max-width: 32ch; font: 600 18px/1.35 var(--font-display); letter-spacing: -.01em; text-wrap: pretty; }
/* The four public slots as four boxes, ink when held, beside the line that says it in words. */
.slots { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font: 500 13px/1.45 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; }
.slots.is-full { padding: 10px 12px; background: var(--paper-sunken); border: var(--border); border-radius: var(--r); }
.slot-cells { display: inline-flex; flex: none; gap: 4px; }
.slot { width: 14px; height: 14px; background: var(--paper-raised); border: var(--border); border-radius: var(--r); }
.slot.is-held { background: var(--ink); }
.terms-more { max-width: 46ch; font: var(--t-small); color: var(--ink-muted); }

/* Find a site's small print: a GET form, then what the search found. */
.find-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 16px; max-width: 640px; padding: 16px; }
.find-form .field { flex: 1 1 240px; }
.find-form .input { font: var(--t-mono); font-size: 14px; }
.find-form .btn { flex: 0 0 auto; }
.find .state-line { margin-top: 20px; }
.found { margin-top: 28px; }
.found-line { font: 500 19px/1.35 var(--font-display); letter-spacing: -.01em; font-variant-numeric: tabular-nums; }
.found-list { max-width: 940px; margin-top: 12px; background: var(--paper-raised); border: var(--border); border-radius: var(--r); box-shadow: var(--shadow); }
.found-item { display: grid; gap: 12px 28px; padding: 14px 16px; }
.found-item + .found-item { border-top: var(--hairline); }
@media (min-width: 700px) { .found-item { grid-template-columns: minmax(0, 1fr) auto; align-items: center; padding: 16px 20px; } }
.found-main { min-width: 0; }
.found-title { overflow-wrap: anywhere; }
.found-url { margin-top: 3px; font: 400 12px/1.45 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); overflow-wrap: anywhere; }
.found-url a { color: inherit; }
.found-snippet { max-width: 68ch; margin-top: 6px; font: var(--t-small); color: var(--ink-soft); overflow-wrap: anywhere; }
.found-act .btn { padding: 9px 14px; font-size: 13px; white-space: nowrap; }
.found-known { font: 500 13px/1.4 var(--font-body); }

/* --- About (src/site/views/about.tsx): a Read surface. The world owns the frame (the ruled openers, the cards,
   the slip, the diagram); the reading column stays calm, at 16px and the 68ch measure. -------------------- */
.about-head .lede { max-width: 60ch; }
.since { margin-top: 18px; font: 500 12px/1.5 var(--font-data); letter-spacing: .06em; text-transform: uppercase; font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.since time { color: var(--ink); }
.paused-note { max-width: 60ch; margin-top: 12px; color: var(--ink-soft); }

/* The contents: a list under the opening on a phone, a sticky rail beside the column from 1000px. */
.about-grid { display: grid; }
@media (min-width: 1000px) { .about-grid { grid-template-columns: 180px minmax(0, 1fr); gap: 56px; align-items: start; } }
.toc { margin-top: 28px; padding: 14px 0 12px; border-top: var(--border); border-bottom: var(--hairline); }
@media (min-width: 1000px) { .toc { position: sticky; top: 24px; margin-top: 60px; padding: 0 0 0 14px; border: 0; border-left: var(--hairline); } }
.toc-title { font: var(--t-label); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); }
.toc ol { display: grid; margin-top: 8px; }
.toc a { display: block; padding: 5px 0; font: 500 14px/1.35 var(--font-body); color: var(--ink-soft); text-decoration: none; }
.toc a:hover { color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); }

.about-body { min-width: 0; font-size: 16px; line-height: 1.6; }
.about section { scroll-margin-top: 8px; }
.about-body > section:first-child { padding-top: 44px; }
.section-lede { max-width: var(--measure); color: var(--ink-soft); }
.about .n { font: 500 13px/1.7 var(--font-data); font-variant-numeric: tabular-nums; color: var(--accent); }

/* How a change is recorded: the five steps, the diagram beside them (under them on a phone). */
.flow { display: grid; gap: 28px; }
@media (min-width: 760px) { .flow { grid-template-columns: minmax(0, 1fr) minmax(260px, 320px); gap: 40px; align-items: start; } }
.flow-steps { border-top: var(--border); }
.flow-steps li { display: grid; grid-template-columns: 26px minmax(0, 1fr); padding: 14px 0 16px; border-bottom: var(--hairline); }
.flow-steps h3 { font: 600 18px/1.35 var(--font-display); letter-spacing: -.01em; }
.flow-steps p { max-width: 62ch; margin-top: 4px; font-size: 15px; line-height: 1.55; color: var(--ink-soft); }
.flow-figure { justify-self: center; width: 100%; max-width: 360px; }
@media (min-width: 760px) { .flow-figure { position: sticky; top: 24px; padding-top: 4px; } }
.flow-svg { display: block; width: 100%; height: auto; overflow: visible; }
.flow-box { fill: var(--paper-raised); stroke: var(--ink); stroke-width: 1.5px; }
.flow-box.is-key { stroke: var(--accent); stroke-width: 2px; }
.flow-box.is-aside { fill: var(--paper); stroke: var(--ink-muted); stroke-dasharray: 4 3; }
.flow-line { fill: none; stroke: var(--ink); stroke-width: 1.5px; }
.flow-headshape { fill: var(--ink); }
.flow-t { font: 600 14px var(--font-body); fill: var(--ink); }
.flow-t.is-small { font-size: 13px; }
.flow-t.is-key { fill: var(--accent); }
.flow-s { font: 400 12px var(--font-data); letter-spacing: .02em; fill: var(--ink-muted); }

/* One change, start to finish: four annotated steps, the note beside the record from 900px. */
.trail { margin-top: 24px; border-top: var(--border); }
.trail-step { display: grid; gap: 14px; padding: 22px 0 26px; border-bottom: var(--hairline); }
@media (min-width: 900px) { .trail-step { grid-template-columns: 236px minmax(0, 1fr); gap: 28px; } }
.trail-note { display: grid; grid-template-columns: 26px minmax(0, 1fr); align-content: start; }
.trail-note .n { grid-row: 1 / span 2; }
.trail-note h3 { font: 600 18px/1.35 var(--font-display); letter-spacing: -.01em; }
.trail-note p { max-width: 56ch; margin-top: 6px; font: 400 14px/1.5 var(--font-body); color: var(--ink-soft); }
.trail-body { min-width: 0; font-size: 15px; line-height: 1.55; }
.trail-body .shots { margin-top: 0; }
.trail-body .actions { margin-top: 18px; }
.trail-link { margin-top: 12px; font: var(--t-small); }
/* The check, as a slip from the ledger: what was read, when, how, against what. */
.slip { max-width: 560px; background: var(--paper-raised); border: var(--border); border-radius: var(--r); box-shadow: var(--shadow); }
.slip > div { display: grid; grid-template-columns: 14ch minmax(0, 1fr); gap: 12px; padding: 10px 14px; }
.slip > div + div { border-top: var(--hairline); }
.slip dt { padding-top: 2px; font: var(--t-label); letter-spacing: .06em; text-transform: uppercase; color: var(--ink-muted); }
.slip dd { margin: 0; min-width: 0; font: var(--t-mono); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.slip dd > a:first-child { font: 600 16px/1.35 var(--font-display); letter-spacing: -.01em; }
.slip dd.is-change { color: var(--accent); }
.slip-url { display: block; margin-top: 2px; font-size: 12px; color: var(--ink-muted); }
.slip-url a { color: inherit; }

/* How TinyFish is used: dense on a desktop, one card a row on a phone. */
.uses { margin-top: 22px; font: var(--t-small); }
.uses thead th { white-space: nowrap; }
.uses tbody th, .uses tfoot th { width: 12ch; vertical-align: top; font: 600 16px/1.35 var(--font-display); letter-spacing: -.01em; }
.uses td { vertical-align: top; }
.uses-does { max-width: 60ch; font-size: 14px; line-height: 1.5; color: var(--ink-soft); }
.uses .uses-fig { width: 24ch; text-align: right; }
.uses-usd { display: block; font: 500 15px/1.35 var(--font-data); font-variant-numeric: tabular-nums; color: var(--ink); }
.uses-note { display: block; margin-top: 3px; font: 400 11.5px/1.45 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; color: var(--ink-muted); }
.uses tfoot th, .uses tfoot td { padding: 12px; vertical-align: top; border-top: var(--border); }
.uses tfoot th { text-transform: none; color: var(--ink); background: none; }
@media (max-width: 699.98px) {
  .uses thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  .uses, .uses tbody, .uses tfoot { display: block; }
  .uses tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 6px 14px; padding: 14px; }
  .uses tbody tr + tr { border-top: var(--hairline); }
  .uses tfoot tr { border-top: var(--border); }
  .uses tbody th, .uses tfoot th, .uses td, .uses tfoot td { display: block; width: auto; padding: 0; border-top: 0; }
  .uses .uses-fig { grid-column: 2; grid-row: 1; width: auto; }
  .uses .uses-does { grid-column: 1 / -1; }
  .uses-note { max-width: 24ch; margin-left: auto; }
}
.keyline { max-width: 34ch; margin-top: 22px; font: 600 21px/1.3 var(--font-display); letter-spacing: -.015em; text-wrap: balance; }

/* What counts as noise: each kind with its count, then what is kept but labelled. */
.noise { margin-top: 20px; border-top: var(--border); }
.noise-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 16px; padding: 14px 0 16px; border-bottom: var(--hairline); }
@media (min-width: 700px) { .noise-row { grid-template-columns: 190px 96px minmax(0, 1fr); gap: 24px; align-items: baseline; } }
.noise dt { font: 600 17px/1.35 var(--font-display); letter-spacing: -.01em; }
.noise dd { margin: 0; }
.noise-n { font: 500 14px/1.4 var(--font-data); font-variant-numeric: tabular-nums; white-space: nowrap; }
.noise-text { grid-column: 1 / -1; max-width: 62ch; font-size: 15px; line-height: 1.55; color: var(--ink-soft); }
@media (min-width: 700px) { .noise-text { grid-column: auto; } }
.kept-h { margin-top: 40px; font: 600 19px/1.3 var(--font-display); letter-spacing: -.01em; }
.kept { display: grid; gap: 16px; margin-top: 14px; }
@media (min-width: 900px) { .kept { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; align-items: start; } }
.kept-item { padding: 16px 18px 18px; font-size: 15px; line-height: 1.55; background: var(--paper-raised); border: var(--border); border-radius: var(--r); box-shadow: var(--shadow); }
.kept-item > * + * { margin-top: 10px; }
.kept-item > p { max-width: 60ch; color: var(--ink-soft); }
.kept-tag { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.kept-n { font: 500 13px/1.3 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; color: var(--ink); }
.kept-link { font: var(--t-small); }
.kept-link a { color: var(--ink); }
.kept-pages { display: grid; gap: 10px; padding-top: 10px; border-top: var(--hairline); }
.kept-pages a { font: 600 16px/1.35 var(--font-display); letter-spacing: -.01em; }
.kept-line { display: block; margin-top: 2px; font: var(--t-small); color: var(--ink-soft); }
.kept-count { display: block; margin-top: 2px; font: 400 12px/1.45 var(--font-data); letter-spacing: .02em; font-variant-numeric: tabular-nums; color: var(--ink-muted); }

/* Honest limits: one ruled list at the reading measure. */
.limits { max-width: var(--measure); border-top: var(--border); }
.limits li { padding: 13px 0 14px; color: var(--ink-soft); border-bottom: var(--hairline); }
.limits b { font-weight: 600; color: var(--ink); }

/* Use the data: each endpoint, what it returns, and its command. */
.endpoints { margin-top: 20px; border-top: var(--border); }
.endpoints li { padding: 16px 0 18px; border-bottom: var(--hairline); }
.endpoints h3 { font: 500 14px/1.45 var(--font-data); letter-spacing: 0; overflow-wrap: anywhere; }
.endpoints h3 code { font: inherit; }
.verb { display: inline-block; margin-right: 4px; padding: 3px 5px 2px; font-size: 11.5px; line-height: 1; letter-spacing: .06em; vertical-align: 1px; color: var(--paper); background: var(--ink); border-radius: var(--r); }
.endpoints p { max-width: 68ch; margin-top: 4px; font-size: 15px; line-height: 1.55; color: var(--ink-soft); }
.endpoints p code, .endpoints-note code { padding: 1px 4px; font-size: 12.5px; color: var(--ink); background: var(--paper-sunken); border-radius: var(--r); }
.cmd { position: relative; max-width: 860px; margin-top: 10px; }
/* The Copy button (enhance.js) has its place kept from the first paint, beside the command, so nothing moves
   when it is added. */
.cmd pre { margin: 0; padding: 10px 82px 10px 14px; white-space: pre-wrap; overflow-wrap: anywhere; font: var(--t-mono); color: var(--ink); background: var(--paper-sunken); border: var(--hairline); border-radius: var(--r); }
.copy { position: absolute; top: 5px; right: 5px; padding: 7px 10px; font: 500 12px/1 var(--font-body); color: var(--ink); background: var(--paper-raised); border: var(--border); border-radius: var(--r); cursor: pointer; transition: background-color var(--dur-fast) var(--ease); }
.copy:hover { background: var(--paper); }
.copy.is-done { color: var(--paper); background: var(--ink); }
/* On a phone the command keeps the whole width, and the row under it is kept for its button. */
@media (max-width: 699.98px) {
  .cmd { padding-bottom: 36px; }
  .cmd pre { padding-right: 14px; }
  .copy { top: auto; right: auto; bottom: 0; left: 0; }
}
.endpoints-note { max-width: 68ch; margin: 16px 0 0; }

.credit { margin-top: 64px; padding-top: 20px; font: italic 400 18px/1.5 var(--font-display); color: var(--ink-soft); border-top: var(--border); }
.credit a { font-style: normal; font: 500 14px/1.5 var(--font-body); color: var(--ink); }
.credit a.by { font: inherit; color: inherit; }

/* --- The screenshot lightbox (public/assets/enhance.js): the full image over the page, no blur ------- */
.lightbox { width: min(1120px, calc(100vw - 32px)); max-width: none; max-height: calc(100vh - 32px); padding: 0; color: var(--ink); background: var(--paper-raised); border: var(--border); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.lightbox[open] { display: flex; flex-direction: column; animation: lightbox-in var(--dur) var(--ease); }
.lightbox::backdrop { background: color-mix(in srgb, var(--ink) 80%, transparent); }
@keyframes lightbox-in { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .lightbox[open] { animation: none; } }
.lightbox-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding: 10px 12px 10px 16px; border-bottom: var(--border); }
.lightbox-caption { flex: 1 1 16ch; min-width: 0; font: 400 12px/1.4 var(--font-data); letter-spacing: .02em; color: var(--ink-muted); }
.lightbox-open { font: var(--t-small); }
.lightbox-close { padding: 8px 12px; font-size: 13px; }
.lightbox-frame { flex: 1 1 auto; min-height: 0; overflow: auto; overscroll-behavior: contain; background: var(--paper-sunken); }
.lightbox-frame img { width: 100%; height: auto; }

/* --- Status chips (tokens.css has ok, warn, bad) --------------------------------------------- */
.chip.muted { color: var(--ink-muted); }

/* --- 404 and error ---------------------------------------------------------------------------- */
.lost { padding-top: 64px; }
.lost .lede { margin-top: 16px; }

/* --- Footer: the spend meter ------------------------------------------------------------------ */
footer { margin-top: 72px; padding: 20px 0 40px; border-top: var(--border); }
footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 24px; }
.meterline { font-size: 12px; font-weight: 500; line-height: 1.5; letter-spacing: .02em; font-variant-numeric: tabular-nums; }
footer ul { display: flex; flex-wrap: wrap; gap: 4px 18px; font-size: 13px; }

/* Waiting: while a new version's screenshot is being taken and the page reloads itself, a bar keeps
   moving and a clock counts. A pressed button says what it is doing and cannot be pressed twice. */
.vshot-none .bar { position: relative; height: 6px; max-width: 320px; overflow: hidden; background: var(--rule); border-radius: var(--r); }
.vshot-none .bar::after { content: ""; position: absolute; top: 0; bottom: 0; left: 0; width: 34%; background: var(--accent); }
.vshot-none .clock { font: 500 13px/1.4 var(--font-data); color: var(--ink); font-variant-numeric: tabular-nums; }
form[aria-busy="true"] button[aria-disabled="true"] { cursor: progress; pointer-events: none; }
form[aria-busy="true"] button[aria-disabled="true"]::after { content: ""; display: inline-block; width: .85em; height: .85em; margin-left: .6em; vertical-align: -.1em; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; }
@media (prefers-reduced-motion: no-preference) {
  .vshot-none .bar::after { animation: bar-run 1.6s var(--ease) infinite; }
  @keyframes bar-run { from { transform: translateX(-100%); } to { transform: translateX(300%); } }
  form[aria-busy="true"] button[aria-disabled="true"]::after { animation: spin .7s linear infinite; }
  @keyframes spin { to { transform: rotate(360deg); } }
}
/* With motion turned off the bar stands still as a faint full track; the clock still counts. */
@media (prefers-reduced-motion: reduce) { .vshot-none .bar::after { width: 100%; opacity: .4; } }
