/* Ledger styling. Dense monospace scaffolding, one sans display face for
   claims and prose. Deliberately no color-coded badges, pills, or icons:
   record_state, freshness, and receipt results are plain text at the same
   weight as any other label, because none of them is a verdict on the
   mathematics. The only accent color is reserved for open invitations —
   an invitation to do work, not a judgment of a claim. */

:root {
  color-scheme: dark light;

  --bg: #111311;
  --bg-rail: #0c0e0c;
  --fg: #dfe2dd;
  --fg-strong: #ffffff;
  --fg-body: #eceeeb;
  --dim: #a8afa6;
  --muted: #7d857c;
  --rule: #2b2f2b;
  --hair: #212521;
  --edge: #3d4a3f;
  --note: #9ec4ad;

  --mono: ui-monospace, "SFMono-Regular", "SF Mono", Menlo, Consolas, monospace;
  --sans: system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;

  --frame: 1180px;
  --rail-w: 340px;
  --pad: 42px;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f7f7f4;
    --bg-rail: #eeeeea;
    --fg: #1d201c;
    --fg-strong: #000000;
    --fg-body: #1d201c;
    --dim: #3f453e;
    --muted: #6b7269;
    --rule: #d2d5cd;
    --hair: #e3e5de;
    --edge: #a9b6ab;
    --note: #2c5c44;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.65;
}

a { color: inherit; text-decoration-color: var(--muted); }
a:hover { color: var(--fg-strong); text-decoration-color: currentColor; }

code {
  font-family: var(--mono);
  font-size: 1em;
  word-break: break-all;
}

/* Record data carries bare repository URLs, arXiv links, and hashes: single
   unbreakable tokens that would otherwise overflow their grid column and
   bleed out of the evidence card. */
dl.facts dd,
.side-by-side p,
.row .v,
.meta,
.prose a,
.records-index .record-id { overflow-wrap: anywhere; }

/* ---------- frame ---------- */

.topline,
.shell,
.site-footer {
  max-width: var(--frame);
  margin: 0 auto;
}

.topline {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: baseline;
  gap: 10px 28px;
  padding: 20px 32px 18px;
  border-bottom: 1px solid var(--rule);
  font-size: 11.5px;
}

.wordmark {
  color: var(--fg-strong);
  letter-spacing: 0.14em;
  text-decoration: none;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 650;
}

.topline-meta { margin: 0; color: var(--muted); text-align: right; font-family: var(--mono); }

.shell { display: grid; grid-template-columns: minmax(0, 1fr); }

.shell.with-rail { grid-template-columns: minmax(0, 1fr) var(--rail-w); }
.shell.with-rail > main { border-right: 1px solid var(--rule); }

.rail { background: var(--bg-rail); }

.site-footer {
  padding: 18px 28px 34px;
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: 11.5px;
}

.site-footer p { margin: 0; max-width: 72ch; }

/* ---------- bands and labels ---------- */

.band {
  padding: 38px var(--pad) 42px;
  border-bottom: 1px solid var(--rule);
}

/* Compact band for metadata and less important sections */
.band-compact {
  padding: 24px var(--pad) 26px;
  border-bottom: 1px solid var(--rule);
}

.band-compact:last-child { border-bottom: 0; }

.band:last-child { border-bottom: 0; }

.index-start { background: var(--bg-rail); }
.index-start h1 { max-width: 25ch; margin: 0; color: var(--fg-strong); font-size: clamp(1.8rem, 4vw, 2.8rem); line-height: 1.1; letter-spacing: -.025em; font-weight: 500; }
.index-start .prose { max-width: 62ch; margin: 18px 0 0; }
.index-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 24px; }
.index-actions a { display: inline-block; padding: 10px 15px; border: 1px solid var(--edge); font-family: var(--mono); font-size: 12px; text-decoration: none; }
.index-action-primary {
  background: var(--note);
  border-color: var(--note) !important;
  color: var(--bg);
  font-size: 13px;
  font-weight: 600;
  padding: 12px 20px;
  letter-spacing: 0.02em;
}
.index-action-primary:hover {
  filter: brightness(1.1);
  color: var(--bg);
}
.index-action-secondary { color: var(--note); }
.index-start > .meta { max-width: 72ch; margin: 14px 0 0; }

.lbl {
  margin: 0 0 18px;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Minor label for less important sections — smaller, dimmer */
.lbl-minor {
  margin: 0 0 14px;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 75%, transparent);
}

.lbl-sub {
  margin: -8px 0 14px;
  font-family: var(--sans);
  font-size: 12px;
  color: var(--muted);
}

/* ---------- typography hierarchy ---------- */

.text-primary {
  font-size: 16px;
  color: var(--fg-body);
  line-height: 1.65;
}

.text-secondary {
  font-size: 14px;
  color: var(--dim);
  line-height: 1.6;
}

.text-tertiary {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.5;
}

.prose {
  font-size: 15px;
  line-height: 1.7;
  color: var(--dim);
  text-wrap: pretty;
}

/* ---------- claim ---------- */

.record-hero {
  padding-top: 54px;
  padding-bottom: 50px;
  background: linear-gradient(180deg, var(--bg-rail), var(--bg));
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--note);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.claim-source { margin: 22px 0 0; }

h1.claim-text {
  margin: 0;
  font-family: var(--sans);
  max-width: 24ch;
  font-size: clamp(30px, 4.3vw, 48px);
  font-weight: 560;
  line-height: 1.12;
  letter-spacing: -0.035em;
  color: var(--fg-strong);
  text-wrap: pretty;
}

h1.claim-math {
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  padding-bottom: 6px;
}

.claim-math math {
  display: block;
  width: max-content;
  max-width: 100%;
  color: var(--fg-strong);
  font-size: clamp(13px, 2vw, 26px);
}

.credit { color: var(--dim); }

/* ---------- author priority ---------- */
/* Prominent display for author information — stands out as primary content */
.author-priority {
  padding: 20px 22px;
  margin: 18px 0 0;
  background: color-mix(in srgb, var(--note) 8%, var(--bg));
  border-left: 3px solid var(--note);
  border-radius: 0 4px 4px 0;
}

.author-priority .author-name {
  margin: 0 0 4px;
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 560;
  color: var(--fg-strong);
}

.author-priority .author-affiliation {
  margin: 0;
  font-size: 14px;
  color: var(--dim);
}

/* ---------- contribution ladder ---------- */
/* Three-tier visual hierarchy for contribution levels */
.contribution-ladder {
  display: flex;
  flex-direction: column;
  gap: 1px;
  background: var(--hair);
  border: 1px solid var(--hair);
  margin: 14px 0;
}

.contribution-tier {
  padding: 16px 18px;
  background: var(--bg);
}

/* Tier 1: Primary contribution — highest visual weight */
.contribution-tier-primary {
  background: color-mix(in srgb, var(--note) 6%, var(--bg));
  border-left: 3px solid var(--note);
}

.contribution-tier-primary .tier-label {
  color: var(--note);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin: 0 0 6px;
}

.contribution-tier-primary .tier-content {
  font-size: 16px;
  font-weight: 500;
  color: var(--fg-strong);
}

/* Tier 2: Secondary contribution — medium weight */
.contribution-tier-secondary .tier-label {
  color: var(--muted);
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 0 0 5px;
}

.contribution-tier-secondary .tier-content {
  font-size: 14px;
  color: var(--fg-body);
}

/* Tier 3: Tertiary contribution — lowest weight */
.contribution-tier-tertiary .tier-label {
  color: color-mix(in srgb, var(--muted) 80%, transparent);
  font-family: var(--mono);
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 4px;
}

.contribution-tier-tertiary .tier-content {
  font-size: 13px;
  color: var(--dim);
}

/* ---------- collapsible sections ---------- */
/* Muted collapsible for secondary/tertiary content */
details.secondary-content {
  margin: 14px 0;
}

details.secondary-content > summary {
  cursor: pointer;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 8px 0;
  list-style: none;
}

details.secondary-content > summary::-webkit-details-marker {
  display: none;
}

details.secondary-content > summary::before {
  content: "+";
  display: inline-block;
  width: 1.2em;
  color: var(--edge);
  font-weight: 400;
}

details.secondary-content[open] > summary::before {
  content: "-";
}

details.secondary-content > summary:hover {
  color: var(--dim);
}

details.secondary-content > .collapsible-body {
  padding: 12px 0 8px 1.2em;
  color: var(--dim);
  font-size: 13px;
  line-height: 1.6;
}

/* Tertiary collapsible — even more muted */
details.tertiary-content {
  margin: 10px 0;
}

details.tertiary-content > summary {
  cursor: pointer;
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: color-mix(in srgb, var(--muted) 80%, transparent);
  padding: 6px 0;
  list-style: none;
}

details.tertiary-content > summary::-webkit-details-marker {
  display: none;
}

details.tertiary-content > summary::before {
  content: "+";
  display: inline-block;
  width: 1.2em;
  color: var(--hair);
  font-weight: 400;
}

details.tertiary-content[open] > summary::before {
  content: "-";
}

details.tertiary-content > summary:hover {
  color: var(--muted);
}

details.tertiary-content > .collapsible-body {
  padding: 10px 0 6px 1.2em;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

/* ---------- visual grouping ---------- */
/* Primary block: hero + author-priority + main CTA — highest prominence */
.visual-group-primary {
  background: linear-gradient(180deg, var(--bg-rail), var(--bg));
}

/* Secondary block: provenance, evidence list — normal weight */
.visual-group-secondary {
  background: var(--bg);
}

/* Tertiary block: caveats, limits, technical details — muted */
.visual-group-tertiary {
  background: color-mix(in srgb, var(--bg) 98%, var(--bg-rail));
}

.visual-group-tertiary .lbl {
  font-size: 10px;
  color: color-mix(in srgb, var(--muted) 75%, transparent);
}

.problem-reference { background: var(--bg-rail); }
.problem-reference-value { margin: 0 0 6px; color: var(--fg-body); font-size: 15px; }

/* The reviewer map is the first practical reading aid on a record. Keep it
   quieter than the claim, but more prominent than hashes and receipts. */
.start-here { background: color-mix(in srgb, var(--bg-rail) 55%, var(--bg)); }
.review-map-main { max-width: 72ch; margin-bottom: 26px; }
.map-label {
  margin: 0 0 7px;
  color: var(--note);
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.review-map-group { max-width: 72ch; margin-top: 22px; }
.review-map-list { margin: 0; padding-left: 1.2rem; }
.review-map-list li { margin: 0 0 16px; padding-left: 4px; }
.review-map-list li:last-child { margin-bottom: 0; }
.review-map-list .prose { margin: 0; }
.review-map-list .meta, .review-map-main .meta { margin-top: 4px; }

.banner {
  margin: 0 0 20px;
  padding: 12px 14px;
  border: 1px solid var(--edge);
  font-size: 12.5px;
}

.banner strong { color: var(--fg-strong); font-weight: 500; }

/* ---------- attributed facts ---------- */

dl.facts {
  display: grid;
  grid-template-columns: 7.5rem minmax(0, 1fr);
  gap: 10px 20px;
  margin: 0;
}

dl.facts dt {
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

dl.facts dd { margin: 0; }

/* Secondary metadata — reduced visual weight */
.attribution, .locator, .meta {
  color: color-mix(in srgb, var(--muted) 90%, transparent);
  font-family: var(--mono);
  font-size: 11px;
  line-height: 1.5;
}

/* ---------- evidence ---------- */

ol.ledger {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: ev;
}

ol.ledger > li {
  display: grid;
  grid-template-columns: 1.9rem minmax(0, 1fr);
  gap: 0 14px;
  padding: 22px 0;
  border-top: 1px solid var(--rule);
}

ol.ledger > li:last-child { border-bottom: 1px solid var(--rule); }

ol.ledger > li::before {
  counter-increment: ev;
  content: counter(ev, decimal-leading-zero);
  color: var(--muted);
}

.evidence-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
  margin-bottom: 10px;
}

.evidence-head h3 {
  margin: 0;
  font-family: var(--sans);
  font-size: 18px;
  font-weight: 600;
  color: var(--fg-strong);
}

.evidence-head .kind { color: var(--muted); font-family: var(--mono); font-size: 11.5px; }

.side-by-side {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: 16px;
  margin: 0 0 12px;
}

.side-by-side > div {
  border-left: 1px solid var(--rule);
  padding-left: 12px;
}

.side-by-side h4 {
  margin: 0 0 4px;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.side-by-side p {
  margin: 0 0 8px;
  font-family: var(--sans);
  font-size: 15px;
  color: var(--dim);
}

.side-by-side p:last-child { margin-bottom: 0; }
.side-by-side code { font-size: 12px; color: var(--fg); }

.rows { display: flex; flex-direction: column; color: var(--dim); font-size: 13.5px; }

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  padding: 5px 0;
  border-top: 1px solid var(--hair);
}

.row:last-child { border-bottom: 1px solid var(--hair); }

.row .k {
  flex: none;
  width: 9rem;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12px;
}

.row .v { flex: 1 1 16rem; min-width: 0; }

.reported-note {
  margin: 0 0 8px;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--muted);
}

.assessment-target { margin: 0 0 8px; color: var(--muted); }

.author-response {
  margin-top: 10px;
  border-left: 1px solid var(--muted);
  padding-left: 12px;
}

.author-response h4 {
  margin: 0 0 3px;
  font-family: var(--mono);
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.author-response p {
  margin: 0;
  font-family: var(--sans);
  font-size: 13.5px;
  color: var(--dim);
}

/* ---------- digestion and importance ---------- */

.digestion-text {
  margin: 0 0 18px;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  color: var(--fg-body);
  text-wrap: pretty;
}

/* ---------- closing disclaimer ---------- */

/* Tertiary content — disclaimers and caveats, deliberately muted */
.what-this-does-not-establish {
  background: transparent;
}

.what-this-does-not-establish .lbl {
  font-size: 10px;
  color: color-mix(in srgb, var(--muted) 75%, transparent);
}

.what-this-does-not-establish ul {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-family: var(--sans);
  font-size: 11px;
  color: color-mix(in srgb, var(--muted) 85%, transparent);
  text-wrap: pretty;
  line-height: 1.5;
}

/* ---------- rail ---------- */

.rail .band { padding: 30px 28px 32px; }

.state-list { display: flex; flex-direction: column; margin: 0; }

.state-list > div {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 10px;
  padding: 7px 0;
  border-top: 1px solid var(--hair);
  font-family: var(--mono);
  font-size: 12px;
}

.state-list > div:last-child { border-bottom: 1px solid var(--hair); }
.state-list dt { color: var(--muted); }
.state-list dd { margin: 0; }

ul.invitations {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

ul.invitations li { border: 1px solid var(--edge); padding: 18px 18px 16px; }

.invitation-kind {
  margin: 0 0 8px;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--note);
}

.invitation-target {
  margin: 0 0 10px;
  font-family: var(--sans);
  font-size: 15px;
  color: var(--fg-body);
  text-wrap: pretty;
}

.invitation-origin { margin: 0; color: var(--muted); font-size: 11.5px; }

ul.roles {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 12px;
}

ul.roles li { padding: 7px 0; border-top: 1px solid var(--hair); }
ul.roles li:last-child { border-bottom: 1px solid var(--hair); }
ul.roles .role { color: var(--fg-body); }
ul.roles .role-meta { color: var(--muted); }

ul.history {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 14px;
  font-size: 12px;
}

ul.history .event-id { color: var(--fg-body); }
ul.history .event-meta { display: block; color: var(--muted); }
.history-note { display: block; margin-bottom: 5px; color: var(--fg-body); font-family: var(--sans); font-size: 13px; line-height: 1.5; }

/* ---------- index ---------- */

.records-index {
  list-style: none;
  margin: 0;
  padding: 0;
}

.records-index > li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 12rem;
  gap: 8px 24px;
  padding: 20px 0;
  border-top: 1px solid var(--rule);
}

.records-index > li:last-child { border-bottom: 1px solid var(--rule); }

.records-index .record-claim {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
  color: var(--fg-strong);
  text-wrap: pretty;
}

.records-index .record-claim a { text-decoration: none; }
.records-index .record-claim a:hover { text-decoration: underline; }
.records-index .claim-math-inline math { display: inline-block; max-width: 100%; vertical-align: middle; }
.records-index .record-id { margin: 8px 0 0; color: var(--muted); font-size: 11.5px; }
.records-index .record-actions { margin: 10px 0 0; font-size: 12px; }
.records-index .record-actions a { color: var(--accent); }
.records-index .record-state { margin: 0; color: var(--dim); font-size: 11.5px; }
.records-index .record-state span { display: block; }

.next-action { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--rule); }

/* ---------- narrow ---------- */

@media (max-width: 900px) {
  :root { --pad: 24px; }
  .topline { grid-template-columns: minmax(0, 1fr); padding: 18px 24px; }
  .topline-meta { text-align: left; }
  .topline-nav { grid-column: 1; }
  .record-hero { padding-top: 42px; padding-bottom: 40px; }
  .shell.with-rail { grid-template-columns: minmax(0, 1fr); }
  .shell.with-rail > main { border-right: 0; }
  .rail { border-top: 1px solid var(--rule); }
  dl.facts { grid-template-columns: minmax(0, 1fr); gap: 2px 0; }
  dl.facts dt { margin-top: 8px; }
  .row .k { width: auto; }
  .records-index > li { grid-template-columns: minmax(0, 1fr); }

  /* Compact bands on narrow screens */
  .band-compact { padding: 18px var(--pad) 20px; }

  /* Author priority adjustments */
  .author-priority { padding: 16px 18px; }
  .author-priority .author-name { font-size: 16px; }

  /* Contribution ladder stacks naturally */
  .contribution-tier { padding: 14px 16px; }
  .contribution-tier-primary .tier-content { font-size: 15px; }
}

/* --- plain-language summary -------------------------------------------------
   The first block on a record page, for a reader who does not know this
   project's vocabulary. Deliberately the calmest thing on the page: no
   accent border, no background tint, no colour that could be read as a
   status light. It reads as prose because it is prose — a restatement, not
   a finding. The only visual weight it carries is being first. */
.plain-summary dl.plain-summary-list {
  display: grid;
  grid-template-columns: minmax(0, 180px) minmax(0, 1fr);
  gap: 18px 30px;
  margin: 0 0 22px;
}

.plain-summary dl.plain-summary-list > div {
  display: contents;
}

.plain-summary dt {
  margin: 0;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--dim);
}

.plain-summary dd {
  margin: 0;
  max-width: 62ch;
  color: var(--fg-body);
  font-size: 16px;
  line-height: 1.7;
}

/* --- author relationship and review coverage -----------------------------
   These answer two questions that must survive screenshots: did the author
   participate, and how much work was actually done? Neither uses a badge,
   colour, percentage, or whole-paper score. */
.relationship-value,
.coverage-boundary {
  margin: 0 0 8px;
  max-width: 68ch;
  font-family: var(--sans);
  color: var(--fg-body);
  font-size: 15.5px;
  line-height: 1.7;
}

.record-relationship { background: var(--bg-rail); }

.coverage-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  margin: 0 0 16px;
  background: var(--hair);
  border: 1px solid var(--hair);
}

.coverage-list > div {
  padding: 18px;
  background: var(--bg);
}

.coverage-list dt {
  color: var(--muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.coverage-list dd {
  margin: 4px 0 0;
  color: var(--fg-strong);
  font-size: 24px;
  font-weight: 560;
}

.coverage-boundary strong { font-weight: 500; }

@media (max-width: 720px) {
  .plain-summary dl.plain-summary-list {
    grid-template-columns: minmax(0, 1fr);
    gap: 2px 0;
  }
  .plain-summary dt { margin-top: 10px; }
  .coverage-list { grid-template-columns: minmax(0, 1fr); }
}

/* --- site nav ---------------------------------------------------------------
   Text links, no buttons, no accent. Sits under the wordmark rather than
   beside it so that a narrow screen does not have to choose between the
   project name and the way out of the page. */
.topline-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 18px;
  grid-column: 1 / -1;
  margin-top: 4px;
  font-family: var(--sans);
  font-size: 13px;
}

.topline-nav a { color: var(--dim); }
.topline-nav a:hover { color: var(--fg-strong); }

/* The message body offered when no contact address is configured. Rendered as
   text to be copied, not as a link, because there is nowhere for a link to
   go. */
pre.mail-template {
  margin: 12px 0 0;
  padding: 14px 16px;
  border: 1px solid var(--hair);
  background: var(--bg-rail);
  color: var(--fg-body);
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-x: auto;
}

/* --- actionable invitations -------------------------------------------------
   The instructions are expanded rather than hidden behind a disclosure
   control: the rail is the place a helper looks for something to do, and a
   task whose contents are one click away is a task most people never read.
   The action is a text link, not a button — nothing here is urgent and
   nothing is a call to action. */
.invitation-task {
  margin: 8px 0 0;
  padding: 10px 0 0;
  border-top: 1px solid var(--hair);
}

.invitation-how-label {
  margin: 0 0 6px;
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--note);
}

.invitation-how {
  margin: 0;
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.6;
  color: var(--fg-body);
  overflow-wrap: anywhere;
  word-break: break-word;
}

.invitation-target { overflow-wrap: anywhere; word-break: break-word; }

.invitation-respond {
  margin: 8px 0 0;
  font-size: 13px;
}

/* --- status board -----------------------------------------------------------
   No status dots, no green, no red, no ordering by how well a row is doing.
   Every one of those is a verdict wearing a colour, and a reader who wants a
   ranking has to make it themselves — which is the correct amount of work for
   a judgement this project does not make.

   Placeholder rows are dimmed slightly and nothing more. They are not hidden:
   nine empty rows is the honest picture of how much of the release anyone here
   has examined. */
ol.board-rows {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1px;
  background: var(--hair);
  border: 1px solid var(--hair);
}

.board-row {
  padding: 18px 20px;
  background: var(--bg);
}

.board-row-head h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
  color: var(--fg-strong);
}

.board-row-record { margin: 4px 0 10px; font-size: 13px; }

.board-row-claim {
  margin: 8px 0 4px;
  max-width: 68ch;
  color: var(--fg-body);
  line-height: 1.6;
}

.board-row-artifacts,
.board-row-status { margin: 10px 0 6px; }

.board-row-empty {
  margin: 8px 0 0;
  max-width: 68ch;
  color: var(--muted);
  line-height: 1.6;
}

.board-row-placeholder .board-row-head h2 {
  color: var(--muted);
  font-weight: 400;
  font-family: var(--mono);
  font-size: 14px;
}

/* --- glossary ---------------------------------------------------------------
   Terms in the page are links, not <abbr>: `title` alone is unreachable by
   keyboard in every major browser, so it fails exactly the readers most likely
   to need the definition. The dotted underline says "there is more here"
   without turning the label into a call to action. */
a.term {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dotted var(--edge);
}

a.term:hover,
a.term:focus { color: var(--fg-strong); border-bottom-color: var(--fg-strong); }

dl.glossary { margin: 0; }

dl.glossary > div {
  padding: 12px 0;
  border-top: 1px solid var(--hair);
}

dl.glossary > div:first-child { border-top: none; }
dl.glossary > div:target { border-left: 2px solid var(--note); padding-left: 12px; }

dl.glossary dt {
  margin: 0 0 4px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--fg-strong);
}

dl.glossary dd {
  margin: 0;
  max-width: 66ch;
  color: var(--fg-body);
  line-height: 1.6;
}

/* --- copy-status export -----------------------------------------------------
   Selectable text, not a button: these pages ship default-src 'none' with no
   script, and a copy button would mean admitting JavaScript to every record
   page to save one keystroke. The box makes the boundaries of the selection
   obvious, which is the part a person actually needs. */
details.copy-status { margin: 0; }

details.copy-status > summary {
  cursor: pointer;
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--note);
}

.copy-status-help {
  margin: 8px 0 6px;
  font-size: 13px;
  color: var(--muted);
  max-width: 62ch;
}

pre.copy-status-text {
  margin: 0;
  padding: 14px 16px;
  border: 1px solid var(--hair);
  background: var(--bg-rail);
  color: var(--fg-body);
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-x: auto;
  user-select: all;
}

/* --- suggested wording ------------------------------------------------------
   Set as a quotation rather than a headline: it is a sentence offered for
   someone else's prose, not a statement the site is making in its own voice. */
.accurate-wording-value {
  margin: 0 0 8px;
  padding-left: 14px;
  border-left: 2px solid var(--edge);
  max-width: 62ch;
  font-family: var(--sans);
  font-size: 17px;
  color: var(--fg-body);
  line-height: 1.6;
}

/* --- formalization handoff --------------------------------------------------
   A practical bridge from an informal claim to a formalizer. Keep it calm and
   factual: the work-state describes the artifact, never the mathematics. */
.handoff-intro { margin: 0 0 16px; max-width: 68ch; color: var(--fg-body); line-height: 1.6; }
.handoff-facts { margin-bottom: 18px; }
.handoff-group { margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--hair); }
.handoff-group .review-map-list { margin-bottom: 0; }

details.technical-details {
  margin-top: 12px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 11.5px;
}

details.technical-details summary { cursor: pointer; }

/* --- translated summaries ---------------------------------------------------
   Each is its own block with its own attribution. dir="rtl" is set from the
   record's lang tag, so an Arabic strip reads right-to-left while the English
   attribution line under it stays left-to-right. */
.plain-summary-translation {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--hair);
}

.plain-summary-translation[dir="rtl"] dl.plain-summary-list { text-align: right; }

/* --- orientation ------------------------------------------------------------
   Long-form prose for somebody who arrived from a headline. Wider measure than
   a record's fields and no columns: this page is read top to bottom, which is
   the one page here that is. */
.orientation-heading {
  margin: 0 0 10px;
  font-size: 17px;
  font-weight: 600;
  color: var(--fg-strong);
}

.orientation-section .prose { max-width: 68ch; line-height: 1.7; }

ul.orientation-next {
  margin: 0;
  padding-left: 18px;
  max-width: 68ch;
  line-height: 1.7;
}

/* --- component dates --------------------------------------------------------
   Three dates, side by side, with nothing computed from them. There is no
   combined "release date" here on purpose: whichever component this strip
   chose would become the date people quoted, and which one counts as the
   release is a judgement the reader makes, not the page. A missing component
   is a dash — flat, unstyled, the same weight as a present one, because an
   absent date is not a worse state, only an unrecorded one. */

/* Date vector — reduced visual weight as metadata */
dl.date-vector {
  display: flex;
  flex-wrap: wrap;
  gap: 3px 22px;
  margin: 12px 0 4px;
}

dl.date-vector > div {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

dl.date-vector dt {
  color: color-mix(in srgb, var(--muted) 80%, transparent);
  font-family: var(--mono);
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

dl.date-vector dd {
  margin: 0;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--dim);
}

.date-vector-caption {
  max-width: 68ch;
  font-size: 11px;
  color: color-mix(in srgb, var(--muted) 85%, transparent);
  line-height: 1.5;
}

/* The Palomar caveat. Rendered from the code for every registry entry and
   never from the record, so it cannot be shortened or dropped by an editor;
   it is styled as plain body text rather than as a warning banner, because a
   coloured box would read as a verdict on the entry rather than a description
   of what the entry is. */
.registry-caveat {
  margin: 10px 0 0;
  max-width: 68ch;
  border-left: 1px solid var(--hair);
  padding-left: 12px;
  color: var(--muted);
  line-height: 1.6;
}

.board-row-digestion { margin: 8px 0 4px; font-size: 13px; }

/* A task nobody wrote. Marked in words rather than by colour: the derived
   rows are not more urgent or less real than the invited ones, they simply
   have no author, and a badge that shouted would imply otherwise. */
.task-origin-derived {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
}

/* Reading rhythm: retain the ledger, give long mathematical records room. */
:root { --frame: 1280px; --rail-w: 370px; }
a { text-underline-offset: .2em; }
a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--note);
  outline-offset: 5px;
}
:target { scroll-margin-top: 24px; }
.shell > main, .rail, .ledger li > div { min-width: 0; }
.topline-nav { gap: 10px 22px; padding-top: 12px; line-height: 1.6; }
.record-hero { padding-top: 44px; padding-bottom: 36px; }
h1.claim-text {
  max-width: 36ch;
  font-size: clamp(26px, 2.7vw, 36px);
  line-height: 1.32;
  letter-spacing: -.025em;
  text-wrap: pretty;
}
h1.claim-math { max-width: 100%; }
.record .prose, .relationship-value, .coverage-boundary,
.facts dd, .side-by-side p { font-size: 16px; line-height: 1.8; }
.record .prose { max-width: 68ch; }
.lbl { color: var(--dim); margin-bottom: 22px; }
.record-nav {
  display: flex; flex-wrap: wrap; gap: 10px 24px;
  padding: 18px var(--pad); border-bottom: 1px solid var(--rule);
  font-family: var(--mono); font-size: 12px;
}
.claim-source { line-height: 1.8; }
.claim-source .locator { display: block; margin-top: 6px; }
.date-vector { gap: 16px 32px; padding-top: 20px; border-top: 1px solid var(--hair); }
.date-vector-caption { margin-top: 16px; line-height: 1.7; }
.plain-summary-list { grid-template-columns: 1fr; gap: 8px; }
.plain-summary-list dd { font-size: 18px; line-height: 1.75; }
.facts { gap: 24px 24px; }
.facts dd > .attribution, .facts dd > div > .attribution {
  display: block; margin-top: 10px;
}
.attribution, .locator, .meta { line-height: 1.75; }
.ledger > li { padding-top: 30px; padding-bottom: 30px; }
.evidence-head { gap: 8px 16px; margin-bottom: 18px; }
.evidence-head h3 { line-height: 1.4; }
.evidence-head .kind { overflow-wrap: anywhere; }
.reported-note { padding-left: 14px; border-left: 2px solid var(--rule); line-height: 1.7; }
.rail .band { padding: 30px 26px; }
.invitations li { padding: 20px; }
.invitation-target { font-size: 17px; line-height: 1.55; }
.invitation-how { font-size: 15px; line-height: 1.8; }
.invitation-respond { line-height: 1.8; }
.state-list > div { gap: 16px; }
.state-list dd { text-align: right; overflow-wrap: anywhere; }
.history li { padding-top: 16px; padding-bottom: 16px; }
.history-note { line-height: 1.75; }
.records .record-claim { line-height: 1.55; }
.records .record-actions { color: var(--note); }
.what-this-does-not-establish ul { line-height: 1.8; }
@media (max-width: 1050px) {
  .shell.with-rail { grid-template-columns: minmax(0, 1fr); }
  .shell.with-rail > main { border-right: 0; }
  .rail { border-top: 1px solid var(--rule); }
  .rail .band { padding: 30px var(--pad); }
  .invitations { max-width: 72ch; }
}
@media (max-width: 600px) {
  :root { --pad: 20px; }
  .band { padding-top: 28px; padding-bottom: 30px; }
  .record-hero { padding-top: 32px; }
  .topline { padding-left: 20px; padding-right: 20px; }
  .topline-nav { gap: 10px 18px; font-size: 12px; }
  .facts { gap: 6px; }
  .facts dd { margin-bottom: 18px; }
  .ledger > li { grid-template-columns: 1.2rem minmax(0, 1fr); gap: 10px; }
  .side-by-side { grid-template-columns: minmax(0, 1fr); }
  .side-by-side > div + div { border-left: 0; padding-left: 0; }
  .record-nav { gap: 12px 20px; }
}
/* --- task cards -------------------------------------------------------------
   Card-based layout for the tasks list. More scannable than a table. */

.task-cards {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

.task-card {
  background: var(--bg-rail);
  border: 1px solid var(--hair);
  border-radius: 8px;
  transition: all 0.15s ease;
}

.task-card:hover {
  border-color: var(--edge);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.task-card-link {
  display: block;
  padding: 20px;
  text-decoration: none;
  color: inherit;
}

.task-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.task-icon {
  font-size: 20px;
}

.task-status {
  font-family: var(--mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 4px;
  background: var(--hair);
  color: var(--dim);
}

.task-status-open {
  background: color-mix(in srgb, var(--note) 15%, transparent);
  color: var(--note);
}

.task-status-taken {
  background: color-mix(in srgb, var(--muted) 20%, transparent);
  color: var(--muted);
}

.task-card-title {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
  color: var(--fg-body);
}

.task-card-record {
  margin: 0 0 12px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
}

.task-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  color: var(--dim);
}

.task-effort, .task-prereq {
  display: flex;
  align-items: center;
  gap: 4px;
}

.task-cards-derived {
  margin-top: 16px;
}

.task-card-derived {
  opacity: 0.7;
}

.task-card-derived:hover {
  opacity: 1;
}

/* --- global hover effects and breathing ------------------------------------*/

/* Links with subtle underline animation */
a {
  transition: color 0.15s ease;
}

/* Cards and interactive elements */
.records-index > li {
  transition: background 0.15s ease;
}

.records-index > li:hover {
  background: var(--bg-rail);
}

/* Buttons with hover lift */
.button, .index-action-primary, .index-action-secondary {
  transition: all 0.15s ease;
}

.button:hover, .index-action-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.index-action-secondary:hover {
  background: color-mix(in srgb, var(--note) 10%, transparent);
}

/* More breathing room */
.band {
  padding: 44px var(--pad) 48px;
}

.band-compact {
  padding: 28px var(--pad) 32px;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Focus states for accessibility */
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--note);
  outline-offset: 2px;
}

/* Nav icons */
.topline-nav a::before {
  margin-right: 6px;
  opacity: 0.6;
}





/* Responsive adjustments */
@media (max-width: 720px) {
  .task-cards {
    grid-template-columns: 1fr;
  }
}

/* Task contribution guidance */
.task-detail-1 {margin-bottom: 8px;}
.task-detail-2 {border-left: 2px solid var(--edge); padding-left: 14px; margin: 0 0 12px;}
.task-detail-3 {margin-top: 18px;}
.task-detail-4 {padding: 14px 0; border-top: 1px solid var(--hair);}
.task-detail-5 {color: var(--note); font-family: var(--mono); font-size: 12px; margin-bottom: 6px;}
.task-detail-6 {margin: 0; max-width: 60ch;}
.task-detail-7 {margin: 0 0 8px;}
.task-detail-8 {padding: 14px 0; border-top: 1px solid var(--hair);}
.task-detail-9 {color: var(--note); font-family: var(--mono); font-size: 12px; margin-bottom: 6px;}
.task-detail-10 {margin: 0; max-width: 60ch;}
.task-detail-11 {margin: 0 0 8px;}
.task-detail-12 {padding: 14px 0; border-top: 1px solid var(--hair); border-bottom: 1px solid var(--hair);}
.task-detail-13 {color: var(--note); font-family: var(--mono); font-size: 12px; margin-bottom: 6px;}
.task-detail-14 {margin: 0; max-width: 60ch;}
.task-detail-15 {margin: 0 0 8px;}
.task-detail-16 {max-width: 60ch;}

/* Readable task metadata, consistent with the quiet record layout. */
.task-card-record { font-family: var(--sans); font-size: 13px; overflow-wrap: anywhere; }
.task-card-meta { font-size: 13px; gap: 8px 16px; }
.task-status { font-size: 12px; }
.task-card-header { gap: 12px; }
.task-kind { font-size: 13px; color: var(--dim); }
.task-card:hover { transform: none; box-shadow: none; }

/* A task's category describes what it checks; its kind describes the method. */
.task-category { color: var(--note); }
.task-check-records { list-style: none; margin: 18px 0 0; padding: 0; }
.task-check-record { border-top: 1px solid var(--hair); padding: 18px 0 8px; }
.task-check-record p { max-width: 72ch; }
.task-check-record p:first-child { margin-top: 0; }
.task-check-record p:last-child { margin-bottom: 0; }
.task-discussion .button { display: inline-block; margin-top: 4px; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}

/* Long source strings and equations stay within narrow reading columns. */
.shell main, .shell aside { min-width: 0; }
.record { overflow-wrap: anywhere; }
.record pre, .record math[display="block"] { max-width: 100%; overflow-x: auto; }
@media (max-width: 720px) {
  .record { overflow-x: auto; }
  .record .band { padding-top: 28px; padding-bottom: 30px; }
}
