/* AI Use Case Register Audit
   Plain CSS. No framework, no build step, no external calls (S12).
   Works on mobile and in dark mode. */

:root {
  --bg: #fbfbf9;
  --surface: #ffffff;
  --border: #d9d7d0;
  --ink: #1c1b18;
  --ink-soft: #57544c;
  --accent: #2f5d50;
  --flag: #8a5a10;
  --count: #1f5673;
  --caution: #8a4a2f;
  --teach: #4a3a7a;
  --calm: #4a5d2f;
  --tint: rgba(47, 93, 80, .07);
  --radius: 6px;
  --measure: 68ch;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14150f;
    --surface: #1d1e18;
    --border: #3a3b33;
    --ink: #eceadf;
    --ink-soft: #a8a498;
    --accent: #8fc4ae;
    --flag: #d7a75a;
    --count: #7db8d8;
    --caution: #e0a184;
    --teach: #b3a5e6;
    --calm: #b5c98d;
    --tint: rgba(143, 196, 174, .09);
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 system-ui, "Segoe UI", Helvetica, Arial, sans-serif;
}

.wrap { max-width: 1100px; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }

header { border-bottom: 1px solid var(--border); }

h1 { font-size: 1.45rem; line-height: 1.25; margin: 0 0 .35rem; text-wrap: balance; }
h2 { font-size: 1.15rem; margin: 2rem 0 .5rem; }
p, li { max-width: var(--measure); text-wrap: pretty; }
.lede { color: var(--ink-soft); margin: 0 0 1rem; text-wrap: balance; }

nav { display: flex; flex-wrap: wrap; gap: .5rem; margin: .75rem 0 0; }
nav a {
  display: inline-block;
  padding: .4rem .7rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--ink);
  text-decoration: none;
  font-size: .9rem;
}
nav a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--bg); }

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.1rem;
  margin: 1rem 0;
}

.caveat {
  border-left: 3px solid var(--flag);
  padding: .6rem .9rem;
  margin: .75rem 0;
  color: var(--ink-soft);
  font-size: .92rem;
}

.pending { color: var(--ink-soft); font-style: italic; }

table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.scroller { overflow-x: auto; }
th, td { text-align: left; padding: .5rem .6rem; border-bottom: 1px solid var(--border); vertical-align: top; }
th { font-weight: 600; color: var(--ink-soft); }

footer {
  border-top: 1px solid var(--border);
  margin-top: 2.5rem;
  padding-top: 1rem;
  color: var(--ink-soft);
  font-size: .85rem;
}
footer p { max-width: var(--measure); }

@media (max-width: 600px) {
  .wrap { padding: 1rem .9rem 2.5rem; }
  h1 { font-size: 1.25rem; }
}

/* Headline: the two computed numbers the site opens with. */
.headline { margin: 1.25rem 0 1.5rem; }
.pair { font-size: 1.15rem; line-height: 1.5; max-width: var(--measure); text-wrap: pretty; }
.fig {
  font-size: 1.9rem;
  font-weight: 650;
  color: var(--accent);
  display: inline-block;
  margin-right: .15rem;
}
.headline .pair { font-size: 1.3rem; }
.headline .fig { font-size: 2.4rem; }

.note { color: var(--ink-soft); font-size: .9rem; }
h3 { font-size: 1rem; margin: 1.25rem 0 .4rem; }

.controls label { display: block; font-size: .85rem; color: var(--ink-soft); margin: .6rem 0 .2rem; }
.controls input, .controls select {
  width: 100%; max-width: 32rem; padding: .45rem .55rem;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--bg); color: var(--ink); font: inherit;
}

button {
  padding: .5rem .9rem; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface); color: var(--ink); font: inherit; cursor: pointer;
}
button:hover { border-color: var(--accent); }

.bar {
  display: inline-block; width: 60px; height: .5rem; vertical-align: middle;
  background: var(--border); border-radius: 3px; overflow: hidden; margin-right: .4rem;
}
.bar > span { display: block; height: 100%; background: var(--accent); }

.finding { border-top: 1px solid var(--border); padding-top: .85rem; margin-top: .85rem; }
.finding:first-child { border-top: 0; padding-top: 0; margin-top: 0; }

.observation { border-left: 3px solid var(--accent); }

a { color: var(--accent); }

@media (max-width: 600px) {
  .headline .fig { font-size: 1.9rem; }
  .headline .pair { font-size: 1.1rem; }
  td, th { font-size: .85rem; }
}

.is-off { display: none; }

/* Shown only when the page could not read its data at all. */
.loadfail {
  border: 1px solid var(--flag);
  border-left-width: 4px;
  border-radius: var(--radius);
  background: var(--surface);
  padding: 1rem 1.1rem;
  margin: 0 0 1.5rem;
}
.loadfail p { margin: .5rem 0; }
.loadfail pre {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: .55rem .7rem;
  overflow-x: auto;
  font-size: .85rem;
}
.loadfail code { font-size: .9rem; }

/* Row detail: an entry opens to show its whole field set. */
tr.entry { cursor: pointer; }
tr.entry:hover td, tr.entry:focus td { background: var(--surface); }
tr.entry:focus { outline: 2px solid var(--accent); outline-offset: -2px; }
.tw { color: var(--ink-soft); font-size: .8rem; }

.detailrow > td { background: var(--surface); padding: .9rem 1rem; }
table.detail { margin-top: .5rem; }
table.detail th {
  width: 14rem; vertical-align: top; font-weight: 600;
  color: var(--ink-soft); white-space: nowrap;
}
table.detail td { white-space: pre-wrap; }
table.detail td.blank { color: var(--ink-soft); font-style: italic; }

/* A figure that leads to the entries it describes. */
a.drill { text-decoration: underline dotted; text-underline-offset: 3px; }
#from-finding { display: flex; gap: .6rem; align-items: center; flex-wrap: wrap; }

/* --- Readability pass -------------------------------------------------- */

/* The plain opening on each page: what you are looking at, before anything. */
.intro {
  border-left: 3px solid var(--accent);
  padding: .2rem 0 .2rem 1rem;
  margin: 0 0 2rem;
}
.intro p { font-size: 1.05rem; line-height: 1.65; }
.intro p:last-child { margin-bottom: 0; }

/* One plain sentence saying what to take away, before any number. */
.lead-in {
  font-size: 1.05rem;
  line-height: 1.6;
  margin: 0 0 .9rem;
  color: var(--ink);
}
h2 + .panel .lead-in, .panel > .lead-in:first-child { margin-top: 0; }

/* Qualifications sit below the point they qualify, quieter, never between a
   point and its explanation. Visible by default: never behind a control. */
.qualifier {
  font-size: .88rem;
  line-height: 1.55;
  color: var(--ink-soft);
  border-top: 1px solid var(--border);
  margin: 1.1rem 0 0;
  padding-top: .6rem;
}
.qualifier p { font-size: inherit; margin: .4rem 0; }
.qualifier p:first-child { margin-top: 0; }
.qualifier p:last-child { margin-bottom: 0; }
.qualifier + .qualifier { border-top: 0; margin-top: .2rem; padding-top: 0; }

/* Controls that teach: the reader changes something and watches the number. */
.teach {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: .9rem 1rem;
  margin: 1rem 0;
}
.teach label { display: block; font-size: .85rem; color: var(--ink-soft); margin-bottom: .5rem; }
.teach input[type="range"] { width: 100%; max-width: 28rem; accent-color: var(--accent); }
.readout { font-size: 1.02rem; margin: .7rem 0 .2rem; }
.readout strong { color: var(--accent); }
#empty-toggle[aria-pressed="true"] { border-color: var(--accent); color: var(--accent); }

/* The five shorter findings: heading and a sentence, opening in place. */
details.finding {
  border-top: 1px solid var(--border);
  padding: .7rem 0 .2rem;
}
details.finding > summary {
  cursor: pointer;
  font-weight: 600;
  list-style: revert;
}
details.finding > summary::marker { color: var(--ink-soft); }
details.finding .gist { display: block; color: var(--ink-soft); font-size: .92rem;
  font-weight: 400; margin: .3rem 0 0; }
details.finding[open] .gist { margin-bottom: .4rem; }
.finding-lead { border-top: 1px solid var(--border); padding-top: .9rem; margin-top: .9rem; }

/* --- Section colour, so a reader can tell one kind of thing from another --- */
.panel { border-left: 3px solid var(--border); }
.panel[data-kind="count"]   { border-left-color: var(--count); }
.panel[data-kind="gap"]     { border-left-color: var(--caution); }
.panel[data-kind="compare"] { border-left-color: var(--calm); }
.panel[data-kind="method"]  { border-left-color: var(--teach); }

.panel[data-kind="count"] .fig   { color: var(--count); }
.panel[data-kind="gap"] .fig     { color: var(--caution); }
.panel[data-kind="compare"] .fig { color: var(--calm); }

.teach { border-left: 3px solid var(--teach); background: var(--tint); }
.teach .readout strong { color: var(--teach); }
.teach input[type="range"] { accent-color: var(--teach); }

/* --- Tabs: one section at a time, so the page is not read all at once ---- */
.tabs {
  display: flex; flex-wrap: wrap; gap: .4rem;
  border-bottom: 1px solid var(--border);
  margin: 1.5rem 0 1.25rem; padding-bottom: .5rem;
}
.tabs button {
  border: 1px solid transparent; background: none; color: var(--ink-soft);
  padding: .45rem .75rem; border-radius: var(--radius);
  font: inherit; font-size: .92rem; cursor: pointer;
}
.tabs button:hover { color: var(--ink); background: var(--surface); }
.tabs button[aria-selected="true"] {
  background: var(--surface); border-color: var(--border);
  color: var(--ink); font-weight: 600;
}
.tabs button[aria-selected="true"]::before {
  content: ""; display: inline-block; width: .5rem; height: .5rem;
  border-radius: 50%; margin-right: .45rem; vertical-align: middle;
  background: var(--marker, var(--accent));
}
.tabpanel.is-off { display: none; }
.tabpanel > h2:first-child { margin-top: 0; }

@media (max-width: 600px) {
  .tabs { gap: .3rem; }
  .tabs button { font-size: .85rem; padding: .4rem .55rem; }
}

summary.tech {
  cursor: pointer; font-size: .85rem; color: var(--ink-soft);
  margin: .5rem 0 .2rem; font-weight: 500;
}
code { font-size: .92em; background: var(--surface); padding: .05rem .3rem; border-radius: 3px; }

/* --- Page four: the design view, visibly not a findings page -------------
   --design is the page's own colour, used by the navigation group label and
   the framing band. On the page body itself the two meanings below take over:
   --pub for the published register, --mine for the field set. */
:root { --design: #6a4a8a; }
@media (prefers-color-scheme: dark) { :root { --design: #c4a8e6; } }
.intro.design { border-left-color: var(--design); }

/* --- Colour on this page means two things and nothing else ----------------

   Blue is the published register: the file this project read, and anything
   that leads back to a finding about it. Purple is the field set: the author's
   own proposal, which is what this page is. Everything else on the page is
   neutral. Links take the blue, because every link on this page leads to the
   audit of the published register.

   Nothing else may borrow either colour. If a third thing needs telling apart,
   it is told apart by shape, weight or position, not by a third hue. */
.design-page {
  --pub: #17506c;
  --pub-soft: rgba(23, 80, 108, .07);
  --mine: #63437f;
  --mine-soft: rgba(99, 67, 127, .07);
}
@media (prefers-color-scheme: dark) {
  .design-page {
    --pub: #8cc4e2;
    --pub-soft: rgba(140, 196, 226, .10);
    --mine: #c9aeea;
    --mine-soft: rgba(201, 174, 234, .10);
  }
}
.design-page a { color: var(--pub); }
.design-page .halfmark { border-top-color: var(--mine); }
.design-page .halfmark-label { color: var(--mine); }
.design-page .intro.design { border-left-color: var(--mine); }

/* --- The lead ------------------------------------------------------------

   The first thing a stranger reads is the fact, not the project. No card, no
   rule, no label: one paragraph at reading size and one line saying what this
   page does about it. Everything self-descriptive sits below the forms. */
.lead { margin: .5rem 0 2rem; max-width: 46ch; }
.design-page h2:first-of-type {
  font-size: 1.6rem; line-height: 1.3; margin: .5rem 0 .75rem; max-width: 22ch;
}
.lead-fact { font-size: 1.15rem; line-height: 1.6; margin: 0 0 .9rem; text-wrap: pretty; }
.lead-fact [data-figure] { font-weight: 700; color: var(--pub); font-variant-numeric: tabular-nums; }
.lead-turn {
  font-size: 1rem; margin: 0; padding-top: .8rem;
  border-top: 2px solid var(--mine); color: var(--ink);
}
@media (min-width: 820px) { .lead { max-width: 52ch; } }
@media (max-width: 640px) {
  .design-page h2:first-of-type { font-size: 1.3rem; max-width: none; }
  .lead-fact { font-size: 1.05rem; }
}

/* --- Level one: the opening, and the forms -------------------------------

   The loudest things on the page. Large type, air around them, no card and no
   rule, so that the two things that carry the argument are the two things a
   reader sees before anything else resolves. */
.opening {
  display: grid; grid-template-columns: 1fr; gap: 1.25rem;
  margin: 1.5rem 0 1.75rem; align-items: center;
}
@media (min-width: 820px) { .opening { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 2.5rem; } }
.opening .pair { font-size: 1.45rem; line-height: 1.45; margin: 0 0 .6rem; text-wrap: pretty; }
.opening .fig { font-size: 2.6rem; color: var(--mine); font-variant-numeric: tabular-nums; }
.opening .qualifier { font-size: .92rem; line-height: 1.6; color: var(--ink-soft); margin: 0; max-width: 60ch; }
@media (max-width: 640px) {
  .opening .pair { font-size: 1.15rem; }
  .opening .fig { font-size: 1.9rem; }
}

/* One mark per box. Three kinds of empty, drawn three ways, because they are
   three different facts and the strip used to draw them as one. A solid
   outline means the register has the box. A dashed outline means it does not.
   A struck box means it has it and does not put it to this entry. The caption
   says the same split in words, so the strip is never the only place the fact
   is stated, and the shapes differ so nothing rests on colour. */
.slotfig { margin: 0; }
.slots { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .55rem; }
.slot {
  width: 1.65rem; height: 2.1rem; border-radius: 3px;
  border: 2px solid var(--pub); background: transparent;
}
.slot.from_source { background: var(--pub); }
.slot.not_collected { border-style: dashed; opacity: .75; }
.slot.blank_in_source { border-style: solid; }
.slot.does_not_apply {
  border-style: solid; opacity: .75;
  background-image: linear-gradient(to top right,
    transparent calc(50% - 1px), var(--pub) calc(50% - 1px),
    var(--pub) calc(50% + 1px), transparent calc(50% + 1px));
}
.slots-caption { font-size: .82rem; line-height: 1.5; color: var(--ink-soft); }

/* --- The drawn form ------------------------------------------------------

   Two copies of one form, label above box, laid out as a form is laid out. A
   box the published entry cannot answer is left empty with its outline intact,
   so the shape of the two forms differs before a word of either is read. */
.build { display: grid; grid-template-columns: 1fr; gap: 1.25rem; margin: 1rem 0 2.25rem; }
@media (min-width: 980px) {
  .build { grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 2rem; align-items: start; }
  .build-stage { position: sticky; top: 1rem; }
}

.switch { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .9rem; }
.switch-btn {
  font: inherit; font-size: .82rem; cursor: pointer;
  padding: .35rem .75rem; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface); color: var(--ink-soft);
}
.switch-btn[data-side="real"][aria-pressed="true"] {
  background: var(--pub); border-color: var(--pub); color: var(--bg); font-weight: 600;
}
.switch-btn[data-side="mine"][aria-pressed="true"] {
  background: var(--mine); border-color: var(--mine); color: var(--bg); font-weight: 600;
}
.switch-btn[data-side="both"][aria-pressed="true"] {
  background: var(--ink); border-color: var(--ink); color: var(--bg); font-weight: 600;
}
.switch-btn:focus-visible { outline: 2px solid var(--mine); outline-offset: 2px; }

.forms { display: grid; grid-template-columns: 1fr; gap: 1.25rem; }
@media (min-width: 620px) { .forms { grid-template-columns: 1fr 1fr; gap: 1rem; } }

/* Choosing a side leaves that form on its own. "Both" is the default and hides
   nothing; on a narrow screen, where the two forms stack, this is what lets a
   reader hold one of them at a time. */
.forms[data-side="real"] .formsheet.mine,
.forms[data-side="mine"] .formsheet.real { display: none; }
@media (min-width: 620px) {
  .forms[data-side="real"], .forms[data-side="mine"] { grid-template-columns: minmax(0, 34rem); }
}

.formsheet { min-width: 0; }
.formsheet-head {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; font-weight: 700;
  margin: 0 0 .1rem;
}
.formsheet.real .formsheet-head { color: var(--pub); }
.formsheet.mine .formsheet-head { color: var(--mine); }
.formsheet-sub { font-size: .78rem; color: var(--ink-soft); margin: 0 0 .7rem; }
.formsheet-body { display: flex; flex-direction: column; gap: .55rem; }

.ffield { display: flex; flex-direction: column; gap: .18rem; min-width: 0; }
.ffield-label {
  font-size: .72rem; font-weight: 600; color: var(--ink-soft); line-height: 1.3;
}
.ffield-n {
  display: inline-block; min-width: 1.15rem;
  font-variant-numeric: tabular-nums; color: var(--ink-soft);
}
.ffield-box {
  border: 1px solid var(--border); border-radius: 3px; background: var(--surface);
  padding: .4rem .5rem; font-size: .82rem; line-height: 1.4; min-height: 2.35rem;
  overflow-wrap: anywhere;
}
.formsheet.real .ffield-box { border-left: 3px solid var(--pub); }
.formsheet.mine .ffield-box { border-left: 3px solid var(--mine); }

/* An empty box reads as an empty box: its outline stays, its ground goes, and
   nothing is printed inside it. The run of them down the left form is the
   whole argument of this page, visible at any size and in a screenshot. */
.ffield-box.is-blank {
  background: transparent; border-style: dashed; border-left-style: dashed;
  border-color: var(--ink-soft); opacity: .55;
}
/* A box the register asks and the entry leaves empty is a different fact from a
   box the register never had. The outline stays solid, because the field does
   exist, and the caption underneath says which it is. */
.ffield-box.is-blank.blank_in_source {
  border-style: solid; border-left-style: solid; border-color: var(--ink-soft);
}
/* A box the register has and does not put to this entry is struck through, so
   it reads as a question that was not asked rather than one nobody answered. */
.ffield-box.is-blank.does_not_apply {
  border-style: solid; border-left-style: solid;
  background-image: linear-gradient(to top right,
    transparent calc(50% - 1px), var(--ink-soft) calc(50% - 1px),
    var(--ink-soft) calc(50% + 1px), transparent calc(50% + 1px));
}
.ffield-note { font-size: .68rem; color: var(--ink-soft); font-style: italic; }

/* Nine questions are nine rows, not one paragraph. Each carries its own answer
   or its own state, and a state is drawn as a marker rather than as words
   inside an answer, which is the distinction the whole field set rests on. */
.ffield-box.has-sub { padding: .3rem .4rem; }
.ffield-sub { list-style: none; margin: 0; padding: 0; display: flex;
  flex-direction: column; gap: .3rem; }
.fsub { display: flex; flex-direction: column; gap: .1rem;
  padding: .28rem .35rem; border-radius: 3px; background: var(--surface); }
.fsub.is-empty { background: transparent; border: 1px dashed var(--ink-soft); }
.fsub-label { font-size: .68rem; font-weight: 600; color: var(--ink-soft); line-height: 1.3; }
.fsub-value { font-size: .78rem; line-height: 1.4; overflow-wrap: anywhere; }
.fsub-state {
  align-self: flex-start; font-size: .7rem; font-style: italic;
  color: var(--ink-soft); border: 1px solid var(--ink-soft); border-radius: 2px;
  padding: .02rem .28rem;
}
.fsub-note { font-size: .66rem; color: var(--ink-soft); line-height: 1.35; }

.compare-note { display: flex; flex-direction: column; gap: .3rem; margin-top: .9rem; }

/* The reading steps. Each points at one box on both forms. */
.build-steps { list-style: none; margin: 0; padding: 0; }
.step { padding: .9rem 0 .9rem 1rem; border-left: 3px solid var(--border); max-width: 46ch; }
.step-field { margin: 0 0 .25rem; font-weight: 600; font-size: .95rem; }
.step-line { margin: 0; font-size: .9rem; line-height: 1.5; color: var(--ink-soft); }
.step-sum { border-left-color: var(--mine); }
@media (min-width: 980px) {
  .step { min-height: 42vh; display: flex; flex-direction: column; justify-content: center; }
}

/* --- Level two: the evidence, and the field set --------------------------

   Secondary. Bordered cards, smaller type, no large figures. These reward a
   reader who has stopped; they do not compete with the opening. */
.evidence { display: grid; gap: .9rem; margin: 1rem 0 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 620px) { .evidence { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .evidence { grid-template-columns: repeat(3, 1fr); } }

.evcard {
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: .8rem .85rem; background: var(--surface);
  display: flex; flex-direction: column; gap: .3rem;
}
.evcard-fig { margin: 0; font-size: 1.5rem; line-height: 1.1; font-variant-numeric: tabular-nums; }
.evcard-fig a { color: var(--pub); text-decoration: none; border-bottom: 2px solid transparent; }
.evcard-fig a:hover, .evcard-fig a:focus-visible { border-bottom-color: var(--pub); }
.evcard-of { font-size: .9rem; color: var(--ink-soft); font-weight: 400; }
.evcard-reads { margin: 0; font-size: .88rem; line-height: 1.45; }
.evcard-caveat {
  margin: .1rem 0 0; font-size: .76rem; line-height: 1.4; color: var(--ink-soft);
  border-top: 1px solid var(--border); padding-top: .35rem;
}

.fieldgrid { display: grid; gap: .7rem; grid-template-columns: 1fr; margin: 1rem 0 1.5rem; align-items: start; }
@media (min-width: 620px) { .fieldgrid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 980px) { .fieldgrid { grid-template-columns: repeat(3, 1fr); } }

.fieldcard { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); padding: .7rem .85rem; }
.fieldcard > summary {
  cursor: pointer; font-weight: 600; font-size: .9rem; line-height: 1.4;
  display: flex; gap: .5rem; align-items: baseline;
}
.fieldcard > summary:focus-visible { outline: 2px solid var(--mine); outline-offset: 3px; }
.fieldcard .num { color: var(--mine); font-variant-numeric: tabular-nums; font-size: .82rem; }
.fieldcard[open] { border-color: var(--mine); }
@media (min-width: 620px) { .fieldcard[open] { grid-column: 1 / -1; } }
.fieldcard-body { padding-top: .5rem; }
.fieldcard-body p { font-size: .9rem; }
.fieldcard .from { font-size: .84rem; color: var(--ink-soft); }

/* --- Level three: sources, limits, where to go next ----------------------

   Quiet. No card, no rule down the side, smaller and set back. A reader who
   squints should not see these at all. */
.design-page .panel.quiet {
  border: 0; border-top: 1px solid var(--border); border-radius: 0;
  background: transparent; padding: .8rem 0 0; margin-bottom: 1.5rem;
}
.design-page .panel.quiet, .design-page .panel.quiet p, .design-page .panel.quiet li,
.design-page .panel.quiet td, .design-page .panel.quiet th { font-size: .85rem; color: var(--ink-soft); }
.design-page .panel.quiet h3 { font-size: .88rem; margin: .9rem 0 .3rem; color: var(--ink); }
.design-page h2.h-quiet {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .08em;
  color: var(--ink-soft); margin: 1.75rem 0 0; border: 0; padding: 0;
}
.design-page h2.h-loud { font-size: 1.5rem; margin-top: 2.25rem; }
.onward { margin: 0 0 .75rem 1.1rem; padding: 0; }
.onward li { margin: .3rem 0; }

/* --- Motion --------------------------------------------------------------
   Each of these reveals a fact: the figure counts to its value while the boxes
   it counts empty out, the step in view marks the box it is about, and a card
   arrives as it is reached. Nothing here decorates. */
/* Slots fill one at a time. The resting state is the real split, so a reader
   who never reaches the strip, or who has asked for less motion, sees the same
   three solid marks. */
.slot { transition: background-color .3s ease; }

/* The boxes hold an outline while the slots fill and empty as the forms come
   into view. The resting state is the empty one, so a reader who triggers
   nothing sees the same two forms. */
.ffield-box.is-blank { transition: opacity .55s ease, border-color .55s ease; }
body.counting-rows .ffield-box.is-blank { opacity: 1; border-style: solid; }

.ffield { transition: opacity .25s ease; }
.forms.reading .ffield { opacity: .4; }
.forms.reading .ffield.lit { opacity: 1; }
.forms .ffield.lit .ffield-label { color: var(--mine); }

.step { transition: border-color .25s ease, opacity .25s ease; opacity: 1; }
@media (min-width: 980px) {
  .build-steps.armed .step { opacity: .5; }
  .build-steps.armed .step.here { opacity: 1; border-left-color: var(--mine); }
}

/* Cards arrive as they are reached. Scroll-driven, so it costs no script. The
   plain state is visible, so anything without support shows them all at once,
   which is the same page without the arrival. */
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .fieldcard, .evcard {
      animation: arrive linear both;
      animation-timeline: view();
      animation-range: entry 0% entry 55%;
    }
  }
}
@keyframes arrive {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

/* A reader who has asked for less motion gets none of it, with every figure,
   box, step and card present and readable. */
@media (prefers-reduced-motion: reduce) {
  .fieldcard, .evcard { animation: none; opacity: 1; transform: none; }
  .ffield, .step { transition: none; opacity: 1; }
  .slot { transition: none; }
  .ffield-box.is-blank { transition: none; }
  .forms.reading .ffield { opacity: 1; }
  .build-steps .step { opacity: 1; }
  .build-stage { position: static; }
  html { scroll-behavior: auto; }
}

/* --- Two halves of one project, said in the navigation ------------------- */
nav { display: flex; flex-wrap: wrap; gap: 1.5rem; align-items: flex-start; }
.navgroup { display: flex; flex-direction: column; gap: .3rem; }
.navgroup + .navgroup {
  padding-left: 1.5rem;
  border-left: 1px solid var(--border);
}
.navlabel {
  font-size: .72rem; text-transform: uppercase; letter-spacing: .07em;
  color: var(--ink-soft); font-weight: 600;
}
.navgroup.design .navlabel { color: var(--design); }
.navlinks { display: flex; flex-wrap: wrap; gap: .4rem; }
.navgroup.design a[aria-current="page"] {
  background: var(--design); border-color: var(--design); color: var(--bg);
}
.navgroup.design a { border-color: var(--design); }

@media (max-width: 700px) {
  nav { gap: 1rem; }
  .navgroup + .navgroup { padding-left: 0; border-left: 0; padding-top: .8rem; border-top: 1px solid var(--border); width: 100%; }
}

/* The band that marks page four as the other half rather than a fourth tab. */
.halfmark {
  border-top: 3px solid var(--design);
  padding: 1rem 0 1.25rem;
  margin: 0 0 1.5rem;
}
.halfmark-label {
  font-size: .72rem; text-transform: uppercase; letter-spacing: .09em;
  color: var(--design); font-weight: 700; margin: 0 0 .4rem;
}
.halfmark-line {
  font-size: 1.15rem; line-height: 1.55; margin: 0;
  max-width: var(--measure); text-wrap: pretty;
}

ol.subfields { margin: .4rem 0 .6rem 1.2rem; padding: 0; columns: 2; column-gap: 1.5rem; }
ol.subfields li { font-size: .9rem; margin: .12rem 0; break-inside: avoid; }
@media (max-width: 640px) { ol.subfields { columns: 1; } }

.convention {
  border-top: 1px solid var(--design);
  margin-top: 1.5rem;
  padding-top: 1rem;
}
.convention-label {
  font-size: .72rem; text-transform: uppercase; letter-spacing: .07em;
  color: var(--design); font-weight: 700; margin: 0 0 .3rem;
}
.convention h3 { margin-top: 0; }

/* --- The question summary ------------------------------------------------ */
.summary { margin: 1.75rem 0 2rem; }
.summary-lead { color: var(--ink-soft); font-size: .92rem; margin: 0 0 .75rem; }

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

.qrow-head {
  display: grid;
  grid-template-columns: 1.75rem minmax(0, 15rem) minmax(0, 1fr);
  gap: .2rem .9rem;
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  border-radius: 0;
  padding: .85rem .2rem;
  font: inherit;
  cursor: pointer;
  align-items: baseline;
}
.qrow-head:hover { background: var(--surface); }
.qrow-head:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.qrow-n { color: var(--ink-soft); font-variant-numeric: tabular-nums; font-size: .85rem; }
.qrow-q { font-weight: 600; }
.qrow-a { color: var(--ink-soft); font-size: .92rem; line-height: 1.5; text-wrap: pretty; }
.qrow-head[aria-expanded="true"] .qrow-q { color: var(--accent); }
.qrow-elsewhere {
  grid-column: 3; margin: 0 0 .8rem 17.65rem;
  font-size: .85rem; color: var(--ink-soft);
}

@media (max-width: 760px) {
  .qrow-head { grid-template-columns: 1.6rem minmax(0, 1fr); }
  .qrow-a { grid-column: 2; }
  .qrow-elsewhere { grid-column: 1 / -1; margin-left: 1.6rem; }
}

/* The five sections are always open: the owner ruled that they read as one
   continuous argument, so a reader who clicks nothing still gets all of it.
   The summary rows are links into the sections, not toggles over them. */
.qrow-head { display: block; text-decoration: none; color: inherit; cursor: pointer; }
.qrow-head:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.qsection { scroll-margin-top: 1rem; }

.handoff {
  border-top: 1px solid var(--border);
  padding-top: .8rem;
  margin: 1.5rem 0 0;
  color: var(--ink-soft);
  font-size: .92rem;
  font-style: italic;
}

/* --- The reading rail ---------------------------------------------------- */
.rail {
  position: fixed; left: max(.6rem, calc(50vw - 640px)); top: 50%;
  transform: translateY(-50%);
  display: flex; flex-direction: column; gap: .5rem; z-index: 5;
}
.railmark { display: flex; align-items: center; gap: .5rem; text-decoration: none; }
.railbar {
  display: block; width: 1.5rem; height: 2px; background: var(--border); border-radius: 2px;
  transition: background .15s, width .15s;
}
.railmark.here .railbar { background: var(--accent); width: 2.25rem; }
.railtext {
  font-size: .75rem; color: var(--ink-soft); opacity: 0; max-width: 0;
  overflow: hidden; white-space: nowrap; transition: opacity .15s;
}
.railmark:hover .railtext, .railmark:focus-visible .railtext { opacity: 1; max-width: 16rem; }
@media (max-width: 1100px) { .rail { display: none; } }

/* A published figure this project could not reproduce prints as that, never as
   a number. The failure to reconcile is the finding. */
.unreconciled { font-style: italic; color: var(--flag); }

/* A proposed field whose only evidence is a three-entry register carries that
   limit on the card itself. */
.rests-on {
  font-size: .82rem; line-height: 1.45; color: var(--ink-soft);
  border-left: 3px solid var(--flag); padding: .35rem .6rem; margin: .5rem 0 0;
}

/* --- The two cautions on the field set page ------------------------------

   These qualify the ten fields, so a reader who meets the field set without
   meeting them has taken more from the page than the work supports. They sit
   at the loud level rather than with the sources and limits: bordered, on a
   tinted ground, with the figure at reading size rather than in a caption.

   The border takes --mine, because both are statements about the author's own
   proposal rather than about the published register. */
.design-page .caution {
  border: 1px solid var(--border);
  border-left: 4px solid var(--mine);
  border-radius: var(--radius);
  background: var(--mine-soft);
  padding: 1.1rem 1.25rem .4rem;
  margin: 2rem 0;
}
.design-page .h-caution {
  margin: 0 0 .5rem;
  font-size: 1.15rem;
  color: var(--mine);
  border: 0;
  padding: 0;
}
.design-page .caution-lead {
  font-size: 1.02rem;
  line-height: 1.55;
  margin: 0 0 .9rem;
}
.design-page .caution-fig strong {
  font-size: 1.35rem;
  color: var(--mine);
  font-variant-numeric: tabular-nums;
}
.design-page .caution-take {
  border-top: 1px solid var(--border);
  padding-top: .7rem;
  margin-top: 1rem;
}
.design-page .misslist { margin: 0 0 1rem; padding-left: 1.1rem; }
.design-page .misslist li { margin-bottom: .45rem; max-width: var(--measure); }

@media (max-width: 600px) {
  .design-page .caution { padding: .9rem 1rem .3rem; }
}

/* --- A correction ---------------------------------------------------------

   A figure that was published and later changed. It sits where the wrong
   number sat, near the top, and it is marked out from the page around it
   without being an alarm. It stays until the owner says it goes. */
.correction {
  border: 1px solid var(--pub); border-left: 4px solid var(--pub);
  border-radius: 4px; padding: .7rem .85rem; margin: 0 0 1.4rem;
  background: color-mix(in srgb, var(--pub) 7%, transparent);
}
.correction p { margin: 0 0 .4rem; font-size: .88rem; line-height: 1.55; }
.correction p:last-child { margin-bottom: 0; }
.correction-head {
  font-weight: 600; font-size: .74rem; letter-spacing: .04em;
  text-transform: uppercase; color: var(--pub);
}

/* --- The short version ----------------------------------------------------

   One finding and one recommendation, before anything else on the page. A
   reader who stops after this should still have the point. */
.bottomline { margin: 0 0 1.4rem; padding: 0 0 .1rem; }
.bottomline-label {
  font-size: .72rem; letter-spacing: .06em; text-transform: uppercase;
  color: var(--ink-soft); margin: 0 0 .45rem;
}
.bottomline p + p { margin-top: .5rem; }
.bottomline p:not(.bottomline-label) { font-size: 1rem; line-height: 1.55; margin: 0; }

/* --- What the memorandum says --------------------------------------------

   A short term list rather than prose, because each line is a separate fact
   with a separate source and a reader should be able to check them one at a
   time. The rule sits in the list above the answer, so the order on the page
   is the order the reasoning ran in. */
.clockbox { margin: 1rem 0 .4rem; }
.clockbox h3 { font-size: .95rem; margin: 0 0 .5rem; }
.clocklist { margin: 0; display: grid; gap: .45rem; }
.clocklist dt {
  font-size: .72rem; font-weight: 600; letter-spacing: .03em;
  text-transform: uppercase; color: var(--ink-soft);
}
.clocklist dd { margin: .1rem 0 0; font-size: .88rem; line-height: 1.55; }

/* A text this project opened, against one it did not. */
.misslist .readmark {
  display: inline-block; font-size: .64rem; font-weight: 600; letter-spacing: .05em;
  text-transform: uppercase; border: 1px solid currentColor; border-radius: 2px;
  padding: .03rem .3rem; margin-right: .4rem; vertical-align: .08em;
}
.misslist li.not-read .readmark { opacity: .65; border-style: dashed; }
.misslist .covered {
  display: block; margin-top: .3rem; font-size: .82rem; line-height: 1.5;
  color: var(--ink-soft);
}
.misslist .covered-label {
  font-weight: 600; text-transform: uppercase; font-size: .66rem;
  letter-spacing: .04em; margin-right: .3rem;
}

/* --- Keeping a register current -------------------------------------------

   The fifth page. Nothing on it was counted from a published file, and the
   design says so before it says anything else: a standing panel at the top,
   the same panel again at the foot, and every mechanism carrying its own cost
   in the same position as the others so none can be read as free. */
.standing {
  border: 1px solid var(--ink-soft); border-left: 4px solid var(--ink-soft);
  border-radius: 4px; padding: .85rem 1rem; margin: 0 0 1.6rem;
}
.standing.closing { margin: 2rem 0 1.6rem; }
.standing p { margin: 0 0 .5rem; font-size: .9rem; line-height: 1.6; }
.standing p:last-child { margin-bottom: 0; }
.standing-label {
  font-weight: 600; font-size: .74rem; letter-spacing: .05em;
  text-transform: uppercase; color: var(--ink-soft);
}
.standing-lead { font-size: 1rem !important; }

.mechanisms { display: flex; flex-direction: column; gap: 1.1rem; margin: .4rem 0 1.4rem; }
.mech {
  border: 1px solid var(--border); border-radius: 4px;
  padding: .9rem 1rem; background: var(--surface);
}
.mech h3 { font-size: 1rem; margin: 0 0 .3rem; }
.mech-n {
  display: inline-block; min-width: 1.5rem; color: var(--ink-soft);
  font-variant-numeric: tabular-nums;
}
.mech-gap { margin: 0 0 .7rem 1.5rem; color: var(--ink-soft); font-size: .88rem; }
.mech-rows { margin: 0 0 .7rem 1.5rem; display: grid; gap: .4rem; }
.mech-rows dt {
  font-size: .68rem; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--ink-soft);
}
.mech-rows dd { margin: .1rem 0 0; font-size: .88rem; line-height: 1.55; }
.mech-trace {
  margin-left: 1.5rem; padding-top: .6rem; border-top: 1px solid var(--border);
}
.mech-trace p { margin: 0 0 .35rem; font-size: .82rem; line-height: 1.5; color: var(--ink-soft); }
.mech-trace p:last-child { margin-bottom: 0; }
.mech-label {
  display: block; font-weight: 600; font-size: .66rem; letter-spacing: .04em;
  text-transform: uppercase;
}
.signals { margin: .3rem 0 1.4rem 1.1rem; padding: 0; }
.signals li { margin-bottom: .4rem; line-height: 1.55; font-size: .92rem; }

/* --- How to read these numbers --------------------------------------------

   Five rules that apply to every figure on the site, published once. They used
   to sit under individual findings, two of them on three pages each. A reader
   who meets the same qualification four times stops reading qualifications,
   which is the opposite of what they are for.

   Drawn as a quiet panel rather than a warning. It is not a disclaimer; it is
   how the numbers work. */
.howread {
  border: 1px solid var(--border); border-radius: 4px;
  padding: 1rem 1.1rem; margin: 1.8rem 0;
  background: var(--surface);
}
.howread-head { font-size: 1.05rem; margin: 0 0 .4rem; }
.howread-lead { margin: 0 0 .9rem; color: var(--ink-soft); font-size: .92rem; line-height: 1.6; }
.howread-list { margin: 0; padding-left: 1.3rem; display: grid; gap: .8rem; }
.howread-list li { padding-left: .2rem; }
.howread-rule { margin: 0; font-size: .95rem; line-height: 1.55; }
.howread-where {
  margin: .25rem 0 0; font-size: .82rem; line-height: 1.5; color: var(--ink-soft);
}
.howread-label {
  display: block; font-weight: 600; font-size: .66rem; letter-spacing: .04em;
  text-transform: uppercase;
}

/* --- If you only do three -------------------------------------------------

   Numbered, because the order is the content. Each carries the same four lines
   in the same order so they can be read against each other, and the cost is
   one of them for the same reason it is on the mechanisms page. */
.mintwo { margin: .4rem 0 1rem; padding-left: 1.4rem; display: grid; gap: 1rem; }
.minitem { padding-left: .2rem; }
.minitem h3 { font-size: 1rem; margin: 0 0 .2rem; }
.minitem-ref {
  display: inline-block; margin-left: .5rem; font-weight: 400;
  font-size: .68rem; letter-spacing: .04em; text-transform: uppercase;
  color: var(--ink-soft);
}
.minitem-records { margin: 0 0 .6rem; font-size: .88rem; color: var(--ink-soft); }
.minitem-rows { margin: 0; display: grid; gap: .35rem; }
.minitem-rows dt {
  font-size: .66rem; font-weight: 600; letter-spacing: .04em;
  text-transform: uppercase; color: var(--ink-soft);
}
.minitem-rows dd { margin: .1rem 0 0; font-size: .88rem; line-height: 1.55; }

/* --- The closest call at each setting -------------------------------------

   What a pair at this threshold actually looks like. The entries are not
   named: two of the three marginal pairs carry product names the vendor list
   did not catch, and the wording the two share is both safe to publish and the
   more useful thing to see. */
.marginal { margin-top: .9rem; padding-top: .8rem; border-top: 1px solid var(--border); }
.marginal p { margin: 0 0 .4rem; font-size: .88rem; line-height: 1.55; }
.marginal-head, .marginal-label {
  font-weight: 600; font-size: .68rem !important; letter-spacing: .04em;
  text-transform: uppercase; color: var(--ink-soft);
}
.marginal-terms { display: flex; flex-wrap: wrap; gap: .3rem; }
.marginal-terms .term {
  border: 1px solid var(--ink-soft); border-radius: 2px;
  padding: .05rem .35rem; font-size: .78rem; color: var(--ink-soft);
}
.marginal-note { font-size: .8rem !important; color: var(--ink-soft); }

/* --- Who this is by -------------------------------------------------------

   At the top, because the only other mention is the footer credit and a reader
   reaches that last if at all. */
.whose {
  margin: 0 0 1.4rem; padding-bottom: 1rem;
  border-bottom: 1px solid var(--border);
  font-size: .92rem; line-height: 1.6; color: var(--ink-soft);
}
.whose strong { color: var(--ink); }
.whose a { margin-left: .3rem; white-space: nowrap; }

/* The dates beside the headline figure. A reader who stops after the short
   version should not leave thinking the work might not have been due yet. */
.bottomline-when { font-size: .88rem !important; color: var(--ink-soft); }
.bottomline-when strong { color: var(--ink); }
