/* Mechaneion tokens — one set for the claims screen, the law screen and the host strip.

   Set on a screen's :host, or on the element a host page marks .mechaneion-chrome, and never on the
   host page's own root, so a page linking mechaneion.css keeps its own colour scheme and properties.

   Three layers, read top to bottom:
   1. scale    — spacing, type, radius, lines, motion. Theme-independent.
   2. tone     — the raw palette, once for light and once for dark. Never read by a component.
   3. meaning  — what a component reads. Each is a public --mechaneion-* knob falling back to its tone. */

/* ---------------------------------------------------------------------------------------------- */
/* 1 · scale                                                                                       */
/* ---------------------------------------------------------------------------------------------- */
.mechaneion-chrome {
  /* The one size knob. Spacing is derived from it too, so a host that raises it for readability
     gets room in proportion instead of larger words in the same cramped boxes. */
  --size: var(--mechaneion-font-size, 16px);
  --unit: calc(var(--size) / 4);

  /* Spacing, named by step. At the default size these are 2 4 8 12 16 20 24 32 48 px. */
  --space-0: calc(var(--unit) * 0.5);
  --space-1: var(--unit);
  --space-2: calc(var(--unit) * 2);
  --space-3: calc(var(--unit) * 3);
  --space-4: calc(var(--unit) * 4);
  --space-5: calc(var(--unit) * 5);
  --space-6: calc(var(--unit) * 6);
  --space-7: calc(var(--unit) * 8);
  --space-8: calc(var(--unit) * 12);

  /* Control heights: every button, field, chip and switch sits on one of these, so a row of mixed
     controls shares a baseline without per-control padding arithmetic. 20 24 28 32 px. */
  --height-tag: calc(var(--unit) * 5);
  --height-chip: calc(var(--unit) * 6);
  --height-control-small: calc(var(--unit) * 7);
  --height-control: calc(var(--unit) * 8);
  /* The smallest box a thumb can press, 44px, which is where a control sits on a phone. It is a FLOOR and
     not a multiple of --unit like the four above it: a thumb does not get smaller when a reader asks for
     smaller type, so lowering --mechaneion-font-size must not take a press target below 44px. Raising it
     still grows this, so the proportion the scale promises is kept in the direction that is safe. */
  --height-tap: max(44px, calc(var(--unit) * 11));

  /* Type. Six sizes, each with the line height it is always set in. 12 13 14 15 18 22 px. */
  --text-xs: calc(var(--size) * 0.75);      /* uppercase label, mono id */
  --text-sm: calc(var(--size) * 0.8125);    /* meta line, tag, chip */
  --text-md: calc(var(--size) * 0.875);     /* body, comment, controls */
  --text-lg: calc(var(--size) * 0.9375);    /* a rule's Rule slot */
  --text-xl: calc(var(--size) * 1.125);     /* a claim's sentence, a rule's plain line */
  --text-2xl: calc(var(--size) * 1.375);    /* the page header, on both screens */
  --leading-xs: 1.35;
  --leading-sm: 1.4;
  --leading-md: 1.5;
  --leading-lg: 1.55;
  --leading-xl: 1.45;
  --leading-2xl: 1.25;
  --weight-regular: 400;
  --weight-medium: 500;
  --weight-strong: 600;
  --tracking-label: 0.06em;                 /* the only letter-spacing; uppercase labels only */

  /* Families: Geist and Geist Mono throughout (§6 ruling 40). The faces ship with the package and are registered on the
     document by the first mount (`registerFonts`); every stack names real fallbacks for a host that passes
     `fonts: false` and supplies none. --font-reading sets the words a person rules on: a claim's sentence, a rule's
     plain and rule slots. It is Geist too, and stays its own knob so an adopter may set a reading face apart. */
  --font-sans: var(--mechaneion-font-sans, "Geist", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif);
  --font-reading: var(--mechaneion-font-reading, "Geist", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif);
  --font-mono: var(--mechaneion-font-mono, "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace);

  /* Radius: 4 for a glyph-sized box, 6 for anything you press or type in, 10 for a card or a popover.
     A circle (the avatar, a status dot) is a shape, not a fourth radius. */
  --radius-small: 4px;
  --radius-control: 6px;
  --radius-card: 10px;

  --line-width: 1px;
  --edge-width: 3px;                        /* the card's state edge */
  --focus-width: 2px;
  --focus-offset: 2px;

  --disabled-opacity: 0.45;
  --motion-fast: 120ms;
}

/* ---------------------------------------------------------------------------------------------- */
/* 2 · tone — light is the base; dark replaces the tones and nothing else                          */
/* ---------------------------------------------------------------------------------------------- */
.mechaneion-chrome {
  color-scheme: light;
  /* Neutrals lean toward blue-violet (hue ~250) by a few points of chroma; never a pure grey. */
  --tone-ground: #F5F5F7;
  --tone-surface: #FAFAFB;
  --tone-surface-raised: #FFFFFF;
  --tone-hover: #EFEFF3;
  --tone-selected: #E7E7EE;
  --tone-line: #E2E2E8;
  --tone-line-strong: #C9CAD3;
  --tone-text: #1A1B21;
  --tone-text-dim: #565866;
  --tone-text-faint: #62646F;
  --tone-works: #0E7141;
  --tone-doesnt: #B0302A;
  --tone-vet-wrong: #912FCF;
  --tone-vet-good: #205BB5;
  --tone-comment: #A62D63;
  --tone-agent: #086872;
  /* Mechaneion's own mark, and nothing else: the mechane in bronze. */
  --tone-bronze: #8A5524;
  /* Not yet saved: no hue, the dim words' grey, because an unsaved change is not yet an answer (round 5 of "More room on a
     small screen", `mock5-tokens.css`, which moved it off violet to free violet's hue for plum, the vetted No). */
  --tone-unsaved: var(--tone-text-dim);
  --tone-shadow: 0 12px 32px -8px rgb(26 27 33 / 0.18), 0 2px 6px rgb(26 27 33 / 0.06);
  --tone-shadow-card: 0 1px 2px rgb(26 27 33 / 0.08), 0 4px 12px -4px rgb(26 27 33 / 0.12);
}

@media (prefers-color-scheme: dark) {
  .mechaneion-chrome:not([data-theme="light"]) {
    color-scheme: dark;
    --tone-ground: #0F1014;
    --tone-surface: #15161B;
    --tone-surface-raised: #1A1B21;
    --tone-hover: #212229;
    --tone-selected: #272831;
    --tone-line: #282932;
    --tone-line-strong: #3A3B47;
    --tone-text: #E9E9EE;
    --tone-text-dim: #A4A6B3;
    --tone-text-faint: #8F919F;
    --tone-works: #4DC38A;
    --tone-doesnt: #F0726B;
    --tone-vet-wrong: #BF6FFD;
    --tone-vet-good: #6FA6F2;
    --tone-comment: #EE8CC0;
    --tone-agent: #4FC4CC;
    --tone-bronze: #CD7F32;
    --tone-unsaved: var(--tone-text-dim);
    --tone-shadow: 0 16px 40px -8px rgb(0 0 0 / 0.6), 0 2px 6px rgb(0 0 0 / 0.3);
    --tone-shadow-card: 0 1px 2px rgb(0 0 0 / 0.4), 0 4px 12px -4px rgb(0 0 0 / 0.5);
  }
}

.mechaneion-chrome[data-theme="dark"] {
  color-scheme: dark;
  --tone-ground: #0F1014;
  --tone-surface: #15161B;
  --tone-surface-raised: #1A1B21;
  --tone-hover: #212229;
  --tone-selected: #272831;
  --tone-line: #282932;
  --tone-line-strong: #3A3B47;
  --tone-text: #E9E9EE;
  --tone-text-dim: #A4A6B3;
  --tone-text-faint: #8F919F;
  --tone-works: #4DC38A;
  --tone-doesnt: #F0726B;
  --tone-vet-wrong: #BF6FFD;
  --tone-vet-good: #6FA6F2;
  --tone-comment: #EE8CC0;
  --tone-agent: #4FC4CC;
  --tone-bronze: #CD7F32;
  --tone-unsaved: var(--tone-text-dim);
  --tone-shadow: 0 16px 40px -8px rgb(0 0 0 / 0.6), 0 2px 6px rgb(0 0 0 / 0.3);
  --tone-shadow-card: 0 1px 2px rgb(0 0 0 / 0.4), 0 4px 12px -4px rgb(0 0 0 / 0.5);
}

/* ---------------------------------------------------------------------------------------------- */
/* 3 · meaning — the only names a component reads                                                  */
/* ---------------------------------------------------------------------------------------------- */
.mechaneion-chrome {
  /* surfaces */
  --ground: var(--mechaneion-ink, var(--tone-ground));
  --surface: var(--mechaneion-panel, var(--tone-surface));
  --surface-raised: var(--mechaneion-panel-raised, var(--tone-surface-raised));
  --hover: var(--mechaneion-hover, var(--tone-hover));
  --selected: var(--mechaneion-selected, var(--tone-selected));
  --field: var(--ground);                   /* every text field and textarea, on both screens */
  --line: var(--mechaneion-line, var(--tone-line));
  --line-strong: var(--mechaneion-line-strong, var(--tone-line-strong));
  /* TWO HEIGHTS, and a surface wears the one for where it is. A popover floats over the page: menus, popovers, sheets,
     modals, a drawer, a toast, and the deck's card, which is in the hand rather than lying anywhere. A card lies at
     rest on the surface it is drawn on, close to it and lit from the same place, so its shadow is short and soft and
     still says it is a card and not a box drawn on the page. */
  --shadow-popover: var(--tone-shadow);
  --shadow-card: var(--tone-shadow-card);

  /* text */
  --text: var(--mechaneion-text, var(--tone-text));
  --text-dim: var(--mechaneion-text-dim, var(--tone-text-dim));
  --text-faint: var(--mechaneion-text-faint, var(--tone-text-faint));

  /* Each colour below means one thing on both screens.
     Nobody has answered: no hue at all — the absence of a decision is not a verdict. */
  --no-answer: var(--line-strong);
  /* A claim vetted worth asking that nobody has checked; a rule somebody says makes sense. */
  --vet-good: var(--mechaneion-vet-good, var(--tone-vet-good));
  /* Somebody says the claim itself is wrong; a rule somebody says does not make sense. */
  --vet-wrong: var(--mechaneion-vet-wrong, var(--tone-vet-wrong));
  --works: var(--mechaneion-mark-yes, var(--tone-works));
  --doesnt: var(--mechaneion-mark-no, var(--tone-doesnt));
  --comment: var(--mechaneion-comment, var(--tone-comment));
  --agent: var(--mechaneion-agent, var(--tone-agent));
  /* Mechaneion's mark, on either ground. It takes no host override: the hue is the product's own, where every
     token above it names something about the host's own data. */
  --bronze: var(--tone-bronze);
  /* A change made on this screen and not yet saved: no hue, since it is not yet an answer. */
  --unsaved: var(--mechaneion-unsaved, var(--tone-unsaved));

  /* The primary action has no hue: every hue on these screens is already an answer. */
  --accent: var(--mechaneion-accent, var(--text));
  --on-accent: var(--mechaneion-on-accent, var(--ground));
  /* One ring, host and component alike. High-contrast neutral, so it reads on every state edge. */
  --focus: var(--mechaneion-focus, var(--text));

  /* A pressed answer's ground: its own colour, faint, over the card. */
  --wash: 14%;

  /* The tree's bucket strip: quantities, drawn in the answer colours they count, lighter for the
     weaker version of the same answer. Unvetted has no hue, as every unanswered state. */
  --bucket-seen: var(--mechaneion-bucket-seen, var(--rung-safe));
  --bucket-solid: var(--mechaneion-bucket-solid, var(--works));
  /* Confirmed by hand where no test can ever hold it: green in full, the answer it counts, and apart from solid
     only in its count and its words. */
  --bucket-hand: var(--mechaneion-bucket-hand, var(--works));
  --bucket-said: var(--mechaneion-bucket-said, color-mix(in srgb, var(--works) 50%, var(--surface-raised)));
  --bucket-held: var(--mechaneion-bucket-held, var(--text-faint));
  --bucket-blank: var(--mechaneion-bucket-blank, var(--line));
  --bucket-red: var(--mechaneion-bucket-red, var(--doesnt));
  --bucket-yours: var(--mechaneion-bucket-yours, color-mix(in srgb, var(--doesnt) 50%, var(--surface-raised)));
  --bucket-unvetted: var(--mechaneion-bucket-unvetted, var(--line-strong));
  /* Assumed (CLAIMS 2.11): unvetted, held by a passing test the bar counts. No hue, as every unanswered state. */
  --bucket-assumed: var(--mechaneion-bucket-assumed, var(--line-strong));
  --bucket-law: var(--mechaneion-bucket-law, var(--vet-wrong));
  --bucket-broke: var(--mechaneion-bucket-broke, repeating-linear-gradient(135deg, var(--doesnt) 0 3px, var(--surface-raised) 3px 6px));
  --bucket-unsure: var(--mechaneion-bucket-unsure, repeating-linear-gradient(135deg, var(--text-faint) 0 3px, var(--surface-raised) 3px 6px));
  --bucket-moved: var(--mechaneion-bucket-moved, var(--hover));

  /* THE LADDER: how far along one thing is, drawn at the claim, the slice and the tier in ONE hue's
     ramp, so a rollup is not a second language. Neutral at the bottom, the screen's own 'works'
     green at the top, two steps between. This is what eleven greys could not do — a reader had to
     hold eleven inks to read one bar (§3, ruled 2026-09-19).

     **EACH STEP IS MIXED INTO THE STEP BELOW IT, never into a surface.** The first attempt mixed
     into '--surface-raised': '--works' at 22% over it is about #2A3B32 against '--line-strong''s
     #3A3B47, so rung 1 came out DARKER and greyer than rung 0 and the ramp went down before it went
     up — the eleven-grey complaint rebuilt in four inks, invisible in the CSS and obvious in the
     browser. Mixing into the rung below makes the ramp monotonic by construction. */
  --rung-none: var(--mechaneion-rung-none, var(--line-strong));
  --rung-vetted: var(--mechaneion-rung-vetted, color-mix(in srgb, var(--works) 30%, var(--line-strong)));
  --rung-almost: var(--mechaneion-rung-almost, color-mix(in srgb, var(--works) 62%, var(--line-strong)));
  --rung-works: var(--mechaneion-rung-works, var(--works));
  /* One step PAST the ramp's top, in the same hue: 'works' deepened towards the text colour, so 'extra safe' reads as
     further along the one ramp and never as a second kind of done. */
  --rung-safe: var(--mechaneion-rung-safe, color-mix(in srgb, var(--works) 70%, var(--text)));
  /* NOT on the ramp, beside it: 'needs you' is a queue, not a distance, so it is the screen's own no
     and never a late rung — which would read as nearly done. */
  --rung-needsyou: var(--mechaneion-rung-needsyou, var(--doesnt));
}

/* Mechaneion components — one of each, read by both screens and the host strip. Reads tokens.css only.

   §7 of the slices brief binds every rule here:
   - no hover, press, selected or open state changes a box's size, padding or border width; states
     change colour, background and inset shadows only, so nothing relayouts under a pressed pointer;
   - no percentage width inside a max-content track, no will-change: transform;
   - [hidden] wins over every display this file sets. */

/* ---------------------------------------------------------------------------------------------- */
/* base                                                                                            */
/* ---------------------------------------------------------------------------------------------- */
.mechaneion-chrome {
  font-family: var(--font-sans);
  font-size: var(--text-md);
  line-height: var(--leading-md);
  font-weight: var(--weight-regular);
  color: var(--text);
  background: var(--ground);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
:where(.mechaneion-chrome), :where(.mechaneion-chrome) *, :where(.mechaneion-chrome)::before, :where(.mechaneion-chrome) *::before, :where(.mechaneion-chrome)::after, :where(.mechaneion-chrome) *::after { box-sizing: border-box; }
:where(.mechaneion-chrome)[hidden], :where(.mechaneion-chrome) [hidden] { display: none !important; }
:where(.mechaneion-chrome) button, :where(.mechaneion-chrome) input, :where(.mechaneion-chrome) textarea, :where(.mechaneion-chrome) select { font: inherit; color: inherit; margin: 0; }
:where(.mechaneion-chrome) p, :where(.mechaneion-chrome) h1, :where(.mechaneion-chrome) h2, :where(.mechaneion-chrome) h3, :where(.mechaneion-chrome) h4, :where(.mechaneion-chrome) ol, :where(.mechaneion-chrome) ul, :where(.mechaneion-chrome) blockquote { margin: 0; }
:where(.mechaneion-chrome) details, :where(.mechaneion-chrome) summary { min-width: 0; }

:where(.mechaneion-chrome):focus-visible, :where(.mechaneion-chrome) :focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: var(--focus-offset); }
:where(.mechaneion-chrome):focus:not(:focus-visible), :where(.mechaneion-chrome) :focus:not(:focus-visible) { outline: none; }

/* A tone is one of the meanings in tokens.css; every coloured component reads --tone. */
:where(.mechaneion-chrome)[data-tone="none"], :where(.mechaneion-chrome) [data-tone="none"] { --tone: var(--no-answer); }
:where(.mechaneion-chrome)[data-tone="vet-good"], :where(.mechaneion-chrome) [data-tone="vet-good"] { --tone: var(--vet-good); }
:where(.mechaneion-chrome)[data-tone="vet-wrong"], :where(.mechaneion-chrome) [data-tone="vet-wrong"] { --tone: var(--vet-wrong); }
:where(.mechaneion-chrome)[data-tone="works"], :where(.mechaneion-chrome) [data-tone="works"] { --tone: var(--works); }
:where(.mechaneion-chrome)[data-tone="doesnt"], :where(.mechaneion-chrome) [data-tone="doesnt"] { --tone: var(--doesnt); }
:where(.mechaneion-chrome)[data-tone="comment"], :where(.mechaneion-chrome) [data-tone="comment"] { --tone: var(--comment); }
:where(.mechaneion-chrome)[data-tone="agent"], :where(.mechaneion-chrome) [data-tone="agent"] { --tone: var(--agent); }
:where(.mechaneion-chrome)[data-tone="unsaved"], :where(.mechaneion-chrome) [data-tone="unsaved"] { --tone: var(--unsaved); }

.label {
  font-size: var(--text-xs);
  line-height: var(--leading-xs);
  font-weight: var(--weight-strong);
  letter-spacing: var(--tracking-label);
  text-transform: uppercase;
  color: var(--text-faint);
}

/* HOW MANY COMMISSIONS SERVED A CLAIM, AND HOW MANY ARE ON THIS BOARD (claim 4GHS98): a quiet line of words under the
   chips of the ones a reader can open. Words and not chips, because neither number is a thing to press — the meta
   line's own size and dim, which is what the design system already says a count beside a claim reads as. One home for
   it, because both screens draw the same line. */
:where(.mechaneion-chrome) .cserved { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--space-2); }
:where(.mechaneion-chrome) .cserved__text { font-size: var(--text-sm); line-height: var(--leading-sm); color: var(--text-dim); }

.id {
  font-family: var(--font-mono);
  font-size: var(--text-xs);
  line-height: var(--leading-xs);
  color: var(--text-faint);
  font-variant-numeric: tabular-nums;
}
.num { font-variant-numeric: tabular-nums; }
:where(.mechaneion-chrome) code {
  font-family: var(--font-mono);
  font-size: var(--text-sm);
  padding-inline: var(--space-1);
  border-radius: var(--radius-small);
  background: var(--hover);
  color: var(--text);
  overflow-wrap: anywhere;
}

.icon {
  width: var(--text-md);
  height: var(--text-md);
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------------------------------------------------------------------------------------------- */
/* mark glyph — the shape says the answer, the tone says which question                            */
/* ---------------------------------------------------------------------------------------------- */
.mark {
  width: var(--text-md);
  height: var(--text-md);
  flex: none;
  fill: none;
  stroke: var(--text-dim);
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.mark[data-tone] { stroke: var(--tone); }
.mark[data-tone="none"] { stroke: var(--text-dim); stroke-dasharray: 2.4 2.2; }

/* ---------------------------------------------------------------------------------------------- */
/* tag — a state in words, in its colour                                                           */
/* ---------------------------------------------------------------------------------------------- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: var(--height-tag);
  padding-inline: var(--space-2);
  border-radius: var(--radius-small);
  font-size: var(--text-sm);
  line-height: 1;
  font-weight: var(--weight-strong);
  white-space: nowrap;
  color: var(--text-dim);
  background: var(--hover);
}
.tag[data-tone] { color: var(--tone); background: color-mix(in srgb, var(--tone) var(--wash), transparent); }
.tag[data-tone="none"] { color: var(--text-dim); background: var(--hover); }
/* Contested: a swatch of the stripes the card's edge carries, and the word in plain text. */
.tag[data-stripes] { color: var(--text); background: var(--hover); }
.tag[data-stripes]::before {
  content: "";
  width: var(--space-1);
  height: var(--space-3);
  border-radius: 1px;
  background: var(--stripes);
}

/* ---------------------------------------------------------------------------------------------- */
/* count badge                                                                                     */
/* ---------------------------------------------------------------------------------------------- */
.count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  min-width: var(--height-tag);
  height: var(--height-tag);
  padding-inline: var(--space-1);
  border-radius: 999px;
  font-size: var(--text-xs);
  line-height: 1;
  font-weight: var(--weight-strong);
  font-variant-numeric: tabular-nums;
  color: var(--text-dim);
  background: var(--hover);
}
.count[data-tone] { color: var(--tone); background: color-mix(in srgb, var(--tone) var(--wash), transparent); }
.count .icon { width: var(--text-xs); height: var(--text-xs); }

/* ---------------------------------------------------------------------------------------------- */
/* buttons                                                                                         */
/* ---------------------------------------------------------------------------------------------- */
/* A region whose contents somebody else draws, such as the sign-in panel an access module fills, gives a bare <button> the
   system button: inside that region only, and at zero specificity, so a class the drawer styles itself wins. */
.button, :where(.mechaneion-chrome) :where(.host-content) :where(button) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  height: var(--height-control);
  padding-inline: var(--space-3);
  border: var(--line-width) solid var(--line-strong);
  border-radius: var(--radius-control);
  background: var(--surface-raised);
  color: var(--text);
  font-size: var(--text-md);
  line-height: 1;
  font-weight: var(--weight-medium);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--motion-fast), border-color var(--motion-fast), color var(--motion-fast);
}
.button:hover:not(:disabled), :where(.mechaneion-chrome) :where(.host-content) :where(button:hover:not(:disabled)) { background: var(--hover); }
.button:active:not(:disabled), :where(.mechaneion-chrome) :where(.host-content) :where(button:active:not(:disabled)) { background: var(--selected); }
.button[data-size="small"] { height: var(--height-control-small); padding-inline: var(--space-2); font-size: var(--text-sm); }

.button[data-kind="primary"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.button[data-kind="primary"]:hover:not(:disabled) { background: color-mix(in srgb, var(--accent) 86%, var(--ground)); }
.button[data-kind="primary"]:active:not(:disabled) { background: color-mix(in srgb, var(--accent) 74%, var(--ground)); }

.button[data-kind="quiet"] { background: transparent; border-color: transparent; color: var(--text-dim); }
.button[data-kind="quiet"]:hover:not(:disabled) { background: var(--hover); color: var(--text); }
.button[data-kind="quiet"]:active:not(:disabled) { background: var(--selected); color: var(--text); }

.button:disabled, :where(.mechaneion-chrome) :where(.host-content) :where(button:disabled), .icon-button:disabled, .vote__option:disabled, .field:disabled, .switch__option:disabled {
  opacity: var(--disabled-opacity);
  cursor: not-allowed;
}

.icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-1);
  min-width: var(--height-control-small);
  height: var(--height-control-small);
  padding-inline: var(--space-1);
  border: var(--line-width) solid transparent;
  border-radius: var(--radius-control);
  background: transparent;
  color: var(--text-dim);
  font-size: var(--text-sm);
  line-height: 1;
  font-weight: var(--weight-strong);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  transition: background-color var(--motion-fast), color var(--motion-fast);
}
.icon-button:hover:not(:disabled) { background: var(--hover); color: var(--text); }
.icon-button:active:not(:disabled), .icon-button[aria-pressed="true"] { background: var(--selected); color: var(--text); }
/* The comment control of a half somebody commented on: its colour and its count, never an overlay. */
.icon-button[data-tone="comment"] { color: var(--comment); }
.icon-button[data-tone="comment"]:hover:not(:disabled) { color: var(--comment); }

/* ---------------------------------------------------------------------------------------------- */
/* vote pair — Worth asking? and Does it? on a claim, Plain line matches? on a rule                */
/* ---------------------------------------------------------------------------------------------- */
.vote { display: inline-flex; isolation: isolate; }
.vote__option {
  --answer: var(--text);
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  height: var(--height-control-small);
  padding-inline: var(--space-2) var(--space-3);
  border: var(--line-width) solid var(--line-strong);
  background: transparent;
  color: var(--text-dim);
  font-size: var(--text-sm);
  line-height: 1;
  font-weight: var(--weight-medium);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--motion-fast), color var(--motion-fast), box-shadow var(--motion-fast);
}
.vote__option:first-child { border-radius: var(--radius-control) 0 0 var(--radius-control); }
.vote__option:last-child { border-radius: 0 var(--radius-control) var(--radius-control) 0; margin-inline-start: calc(-1 * var(--line-width)); }
.vote__option[data-answer="good"] { --answer: var(--vet-good); }
.vote__option[data-answer="wrong"] { --answer: var(--vet-wrong); }
.vote__option[data-answer="yes"] { --answer: var(--works); }
.vote__option[data-answer="no"] { --answer: var(--doesnt); }
/* An answer GIVEN on a frozen card is drawn as the pressed answer it was, and is no control: no hover, no press, square
   corners nowhere, because it stands alone in its group. */
.vote__option:hover:not(:disabled):not([data-given]) { background: var(--hover); color: var(--text); }
.vote__option:active:not(:disabled):not([data-given]) { background: var(--selected); color: var(--text); }
.vote__option[data-given] { border-radius: var(--radius-control); margin-inline-start: 0; cursor: default; }
.vote__option[aria-pressed="true"], .vote__option[data-given] {
  z-index: 1;
  color: var(--answer);
  background: color-mix(in srgb, var(--answer) var(--wash), var(--surface-raised));
  border-color: color-mix(in srgb, var(--answer) 60%, var(--line-strong));
}
.vote__option[aria-pressed="true"]:hover:not(:disabled) { color: var(--answer); background: color-mix(in srgb, var(--answer) 20%, var(--surface-raised)); }
.vote__option:focus-visible { z-index: 2; }
/* A MARK THAT SAYS WHAT PRESSING IT DOES (PAGE 5.10, bug ND51E8): the word, then the ask's own outcome under it.
   The pair STACKS and each option takes the width, because an outcome is a sentence and two sentences side by side in
   a joined pill are unreadable at a thumb's width — the joined edge moves from left-and-right to top-and-bottom and
   nothing else about the pair changes. Only a pair whose marks carry an outcome is touched: every other .vote on
   every screen keeps the inline pill above, which is what [data-does] on both the group and the option is for. */
.vote[data-does] { display: grid; }
.vote__option[data-does] {
  flex-direction: column;
  align-items: start;
  gap: var(--space-0);
  height: auto;
  padding: var(--space-2) var(--space-3);
  white-space: normal;
  text-align: start;
  line-height: var(--leading-md);
}
.vote[data-does] .vote__option:first-child { border-radius: var(--radius-control) var(--radius-control) 0 0; }
.vote[data-does] .vote__option:last-child {
  border-radius: 0 0 var(--radius-control) var(--radius-control);
  margin-inline-start: 0;
  margin-block-start: calc(-1 * var(--line-width));
}
.vote__does { font-family: var(--font-reading); font-size: var(--text-sm); font-weight: var(--weight-regular); color: var(--text-dim); }
.vote__option[aria-pressed="true"] .vote__does { color: var(--text); }
/* Pressed here and not yet saved: a grey dot, so the answer keeps its own colour. */
.vote__option[data-unsaved]::after {
  content: "";
  position: absolute;
  top: calc(-1 * var(--space-1));
  right: calc(-1 * var(--space-1));
  width: var(--space-2);
  height: var(--space-2);
  border-radius: 50%;
  background: var(--unsaved);
  box-shadow: 0 0 0 var(--space-0) var(--surface-raised);
}

/* ---------------------------------------------------------------------------------------------- */
/* suggestions — an ask of PAGE 5.10's Choose shape, one of which may be taken                        */
/* ---------------------------------------------------------------------------------------------- */
/* THE VOTE PAIR'S SIBLING AND NOT A WIDENING OF IT: a mark is a word on one axis, a suggestion is a
   sentence — or two, where it would change something that exists — and there may be five of them. So
   they are rows in a column, full width, in the reading font a sentence is read in, and the pressed one
   is marked the way a pressed mark is: its own tone, washed, with a stronger edge. 'row-gap: 0' with one
   shared edge keeps them reading as one set of alternatives rather than five loose buttons.

   The number is drawn because the ask's own lines number them ('askLines'), so the suggestion he presses
   and the suggestion the record names are the same one by sight.

   NOT '.pick', WHICH IS TAKEN: the pass's scope sheet is '.pick' in 'deck-styles.ts' — a fixed, full-screen dialog —
   and this rule's border made it 861px tall in an 860px window. 'deck-browser.test.ts' caught it, which is the whole
   argument for naming a new control after the thing it is rather than after the act it takes. */
.suggestions { display: grid; grid-template-columns: minmax(0, 1fr); }
.suggestion {
  --answer: var(--works);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-1) var(--space-3);
  width: 100%;
  padding: var(--space-2) var(--space-3);
  border: var(--line-width) solid var(--line-strong);
  border-radius: 0;
  margin-block-start: calc(-1 * var(--line-width));
  background: transparent;
  color: var(--text);
  font-family: var(--font-reading);
  font-size: var(--text-md);
  line-height: var(--leading-md);
  text-align: start;
  cursor: pointer;
  transition: background-color var(--motion-fast), border-color var(--motion-fast);
}
.suggestion:first-child { margin-block-start: 0; border-radius: var(--radius-control) var(--radius-control) 0 0; }
.suggestion:last-child { border-radius: 0 0 var(--radius-control) var(--radius-control); }
.suggestion:only-child { border-radius: var(--radius-control); }
/* THE NUMBER IS A COLUMN AND THE SUGGESTION IS A COLUMN, and they are said that way rather than left to auto-placement.
   Measured in chrome-headless-shell at 900px on 2026-10-15: with the number spanning 'grid-row: 1 / -1' and the two
   halves of a suggestion as siblings, '-1' is the end of the EXPLICIT grid — which, with no rows declared, is the line
   after row 1 — so the number spanned one row, 'now' took row 1 column 2, and 'would say' wrapped under the number into
   row 2 column 1. A wrapper of its own is what makes the two halves one thing in one cell. */
.suggestion__n { grid-column: 1; color: var(--text-faint); font-family: var(--font-sans); font-size: var(--text-sm); font-weight: var(--weight-medium); }
.suggestion__body { grid-column: 2; display: grid; gap: var(--space-1); min-width: 0; }
.suggestion__was, .suggestion__words { display: grid; gap: var(--space-0); min-width: 0; overflow-wrap: anywhere; }
/* The two halves' labels are furniture and not reading, so they keep the sans face the pick's row does not. */
.suggestion .label { font-family: var(--font-sans); }
/* What it says NOW is the quieter half, as the claim card's own comparison draws it ('.cmp .old'): the
   half being left behind is dimmed, and the half it would become reads at full strength. */
.suggestion__was { color: var(--text-dim); }
.suggestion:hover:not(:disabled) { background: var(--hover); }
.suggestion[aria-pressed="true"] {
  color: var(--text);
  background: color-mix(in srgb, var(--answer) var(--wash), var(--surface-raised));
  border-color: color-mix(in srgb, var(--answer) 60%, var(--line-strong));
}
.suggestion:disabled { cursor: default; color: var(--text-dim); }

/* ---------------------------------------------------------------------------------------------- */
/* chip — a slice this one needs, or one waiting on it                                             */
/* ---------------------------------------------------------------------------------------------- */
.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  max-width: 100%;
  height: var(--height-chip);
  padding-inline: var(--space-2);
  border: var(--line-width) solid var(--line);
  border-radius: var(--radius-control);
  background: var(--surface-raised);
  color: var(--text);
  font-size: var(--text-sm);
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background-color var(--motion-fast), border-color var(--motion-fast);
}
.chip > .chip__text { overflow: hidden; text-overflow: ellipsis; }
.chip:hover { background: var(--hover); border-color: var(--line-strong); }
.chip:active { background: var(--selected); }
.chip[data-removable] { padding-inline-end: var(--space-0); cursor: default; }
.chip[data-removable]:hover { background: var(--surface-raised); border-color: var(--line); }
.chip__remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: calc(var(--height-chip) - var(--space-1) - 2 * var(--line-width));
  height: calc(var(--height-chip) - var(--space-1) - 2 * var(--line-width));
  border: 0;
  border-radius: var(--radius-small);
  background: transparent;
  color: var(--text-faint);
  cursor: pointer;
}
.chip__remove .icon { width: var(--text-xs); height: var(--text-xs); }
.chip__remove:hover { background: var(--hover); color: var(--text); }
.chip__remove:active { background: var(--selected); color: var(--text); }

/* ---------------------------------------------------------------------------------------------- */
/* fold — the one disclosure: a chevron that turns, a label, and optional quiet meta               */
/* Works on <details><summary class="fold__summary"> and on a <button aria-expanded>.              */
/* ---------------------------------------------------------------------------------------------- */
.fold__summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  column-gap: var(--space-2);
  min-height: var(--height-control-small);
  margin-inline: calc(-1 * var(--space-1));
  padding-inline: var(--space-1) var(--space-2);
  border: 0;
  border-radius: var(--radius-control);
  background: transparent;
  color: var(--text-dim);
  font-size: var(--text-md);
  line-height: var(--leading-sm);
  font-weight: var(--weight-medium);
  text-align: left;
  list-style: none;
  cursor: pointer;
  transition: background-color var(--motion-fast), color var(--motion-fast);
}
.fold__summary::-webkit-details-marker { display: none; }
/* Added for the law screen's build: the fold on a <button aria-expanded> inside a div.fold takes its column's width, as a
   <summary> does, so a one-line preview is cut at the column's edge instead of widening the button past it. */
div.fold { display: grid; grid-template-columns: minmax(0, 1fr); }
.fold__summary:hover { background: var(--hover); color: var(--text); }
.fold__chevron { transition: transform var(--motion-fast); color: var(--text-faint); }
details[open] > .fold__summary .fold__chevron,
.fold__summary[aria-expanded="true"] .fold__chevron { transform: rotate(90deg); }
.fold__meta { color: var(--text-faint); font-size: var(--text-sm); font-weight: var(--weight-regular); }
.fold__preview { flex: 1 1 12em; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--text-faint); font-weight: var(--weight-regular); }
details[open] > .fold__summary .fold__preview { display: none; }
.fold__body { padding-block-start: var(--space-2); padding-inline-start: calc(var(--text-md) + var(--space-2)); }

/* ---------------------------------------------------------------------------------------------- */
/* segmented switch — host Claims · Law and every mode switch inside a screen                      */
/* ---------------------------------------------------------------------------------------------- */
.switch {
  display: inline-flex;
  gap: var(--space-0);
  height: var(--height-control);
  padding: var(--space-0);
  border: var(--line-width) solid var(--line);
  border-radius: var(--radius-control);
  background: var(--surface);
}
.switch__option {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding-inline: var(--space-3);
  border: 0;
  border-radius: calc(var(--radius-control) - var(--space-0));
  background: transparent;
  color: var(--text-dim);
  font-size: var(--text-md);
  line-height: 1;
  font-weight: var(--weight-medium);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color var(--motion-fast), color var(--motion-fast);
}
.switch__option:hover:not(:disabled) { color: var(--text); background: var(--hover); }
.switch__option:active:not(:disabled) { background: var(--selected); }
.switch__option[aria-selected="true"], .switch__option[aria-pressed="true"] {
  color: var(--text);
  background: var(--selected);
  box-shadow: inset 0 0 0 var(--line-width) var(--line-strong);
}

/* ---------------------------------------------------------------------------------------------- */
/* text field, select and textarea — one ground on both screens                                    */
/* ---------------------------------------------------------------------------------------------- */
.field {
  display: block;
  width: 100%;
  height: var(--height-control);
  padding-inline: var(--space-3);
  border: var(--line-width) solid var(--line-strong);
  border-radius: var(--radius-control);
  background: var(--field);
  color: var(--text);
  font-size: var(--text-md);
  line-height: var(--leading-md);
  transition: border-color var(--motion-fast);
}
.field::placeholder { color: var(--text-faint); opacity: 1; }
.field:hover:not(:disabled):not(:focus-visible) { border-color: var(--text-faint); }
.field[data-size="small"] { height: var(--height-control-small); padding-inline: var(--space-2); font-size: var(--text-sm); }
textarea.field {
  height: auto;
  min-height: calc(var(--text-md) * var(--leading-md) * 3 + var(--space-2) * 2 + 2px);
  padding-block: var(--space-2);
  resize: vertical;
}
select.field {
  appearance: none;
  padding-inline-end: var(--space-7);
  background-image:
    linear-gradient(45deg, transparent 50%, var(--text-dim) 50%),
    linear-gradient(135deg, var(--text-dim) 50%, transparent 50%);
  background-position: right calc(var(--space-3) + 4px) center, right var(--space-3) center;
  background-size: 4px 4px;
  background-repeat: no-repeat;
  cursor: pointer;
}
/* A small select keeps the room its arrow needs: .field[data-size="small"] would otherwise win on specificity. */
select.field[data-size="small"] { padding-inline-end: var(--space-7); }
/* A reason owed by a thumbs-down: the colour of the answer it is owed for. */
.field[data-owed] { border-color: var(--vet-wrong); }
/* Dashed as well as grey, so a field waiting to be saved never reads as one with the keyboard in it (`mock5-tokens.css`). */
.field[data-unsaved] { border-color: var(--unsaved); border-style: dashed; }
.field-note { display: flex; align-items: center; gap: var(--space-1); margin-top: var(--space-1); font-size: var(--text-sm); color: var(--text-dim); }
.field-note[data-tone] { color: var(--tone); }
.field-note .icon { width: var(--text-sm); height: var(--text-sm); }

/* ---------------------------------------------------------------------------------------------- */
/* menu / popover                                                                                  */
/* ---------------------------------------------------------------------------------------------- */
.menu {
  display: grid;
  gap: var(--space-0);
  min-width: calc(var(--size) * 15);
  padding: var(--space-1);
  border: var(--line-width) solid var(--line-strong);
  border-radius: var(--radius-card);
  background: var(--surface-raised);
  box-shadow: var(--shadow-popover);
}
.menu__head { display: grid; gap: var(--space-0); padding: var(--space-2) var(--space-3); }
.menu__name { font-weight: var(--weight-medium); }
.menu__sub { font-size: var(--text-sm); color: var(--text-dim); }
.menu__rule { height: var(--line-width); margin: var(--space-1) calc(-1 * var(--space-1)); border: 0; background: var(--line); }
.menu__item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  min-height: var(--height-control);
  padding-inline: var(--space-3);
  border: 0;
  border-radius: var(--radius-control);
  background: transparent;
  color: var(--text);
  font-size: var(--text-md);
  text-align: left;
  cursor: pointer;
}
.menu__item .icon { color: var(--text-dim); }
.menu__item:hover, .menu__item[aria-selected="true"] { background: var(--hover); }
.menu__item:active { background: var(--selected); }
.menu__item[aria-checked="true"]::after { content: "✓"; margin-inline-start: auto; color: var(--text-dim); }
.menu__item .menu__hint { margin-inline-start: auto; font-size: var(--text-sm); color: var(--text-faint); }

/* ---------------------------------------------------------------------------------------------- */
/* info mark — how-to words, drawn only when asked for (PAGE 5.21; info-mark.ts)                    */
/* ---------------------------------------------------------------------------------------------- */
/* The mark is the system's .icon-button, so it takes the thumb floor below with every other one. The words are fixed
   to the window and placed by info-mark.ts, so no box they open over is clipped or moved: open, they cover, and they
   never reflow what they explain. Their width and the glyph's size are tuning values the rule leaves to the build. */
.info { display: inline-flex; align-items: center; vertical-align: middle; max-width: 100%; }
.info__mark { flex: none; }
.info__mark[aria-expanded="true"] { background: var(--selected); color: var(--text); }
.info__words {
  position: fixed;
  z-index: 60;
  display: block;
  width: max-content;
  max-width: min(24rem, calc(100vw - 2 * var(--space-2)));
  padding: var(--space-2) var(--space-3);
  border: var(--line-width) solid var(--line-strong);
  border-radius: var(--radius-card);
  background: var(--surface-raised);
  box-shadow: var(--shadow-popover);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: var(--text-sm);
  line-height: var(--leading-sm);
  font-weight: var(--weight-regular);
  letter-spacing: normal;
  text-align: start;
  text-transform: none;
  white-space: normal;
  overflow-wrap: break-word;
}
/* The words' last line: a way to the mark's word in Words (NAMES 1.7), as the onboarding mockup drew it (be89d131). */
.info__wordslink {
  display: inline;
  min-width: 0;
  min-height: 0;
  margin-inline-start: .35em;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
/* A thing and the mark that explains it, on one line: a heading, a legend's name, a row's words. */
.info-lead { display: flex; align-items: center; gap: var(--space-1); min-width: 0; }
/* An iPad is a coarse pointer wider than a phone: the mark is a thumb's target there too. */
@media (pointer: coarse) {
  .info__mark { min-width: var(--height-tap); min-height: var(--height-tap); }
}

/* ---------------------------------------------------------------------------------------------- */
/* page header — the grouping's name or the book's, and its counts; one size on both screens       */
/* ---------------------------------------------------------------------------------------------- */
.page-header {
  display: flex;
  flex-wrap: wrap;
  align-items: last baseline;             /* the counts sit on the title's line, under an eyebrow too */
  gap: var(--space-1) var(--space-5);
  padding-block-end: var(--space-4);
  border-bottom: var(--line-width) solid var(--line);
}
.page-header__title {
  display: grid;
  gap: var(--space-0);
  font-size: var(--text-2xl);
  line-height: var(--leading-2xl);
  font-weight: var(--weight-strong);
  text-wrap: balance;
}
.page-header__title .id { font-weight: var(--weight-regular); }
.page-header__counts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-1) var(--space-4);
  font-size: var(--text-sm);
  color: var(--text-dim);
}
.page-header__counts b { font-weight: var(--weight-medium); color: var(--text); font-variant-numeric: tabular-nums; }

/* ---------------------------------------------------------------------------------------------- */
/* rail item — a book, a rule under it, the disagreements tray                                     */
/* ---------------------------------------------------------------------------------------------- */
.rail { display: grid; gap: var(--space-0); align-content: start; }
.rail-item {
  display: grid;
  grid-template-columns: var(--text-md) minmax(0, 1fr) auto;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
  min-height: var(--height-control);
  padding-inline: var(--space-2);
  border: 0;
  border-radius: var(--radius-control);
  background: transparent;
  color: var(--text);
  font-size: var(--text-md);
  line-height: var(--leading-sm);
  text-align: left;
  cursor: pointer;
  transition: background-color var(--motion-fast);
}
.rail-item:hover { background: var(--hover); }
.rail-item:active { background: var(--selected); }
.rail-item[aria-current="true"] { background: var(--selected); }
.rail-item[aria-expanded] .fold__chevron { transition: transform var(--motion-fast); color: var(--text-faint); }
.rail-item[aria-expanded="true"] .fold__chevron { transform: rotate(90deg); }
.rail-item__name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rail-item__meta { font-size: var(--text-sm); color: var(--text-faint); font-variant-numeric: tabular-nums; white-space: nowrap; }
.rail-item[data-level="rule"] { grid-template-columns: var(--text-md) 2.75em minmax(0, 1fr); min-height: var(--height-control-small); font-size: var(--text-sm); }
.rail-item[data-level="rule"][aria-current="true"] .id { color: var(--text); }
.rail-item[data-struck] .rail-item__name { color: var(--text-faint); }
.rail-group {
  display: grid;
  gap: var(--space-0);
  margin-inline-start: calc(var(--space-2) + var(--text-md) / 2);
  padding-inline-start: var(--space-2);
  border-inline-start: var(--line-width) solid var(--line);
}
.rail-group > .label { padding: var(--space-3) var(--space-2) var(--space-1); }
.rail-tray { margin-block-start: var(--space-3); padding-block-start: var(--space-3); border-top: var(--line-width) solid var(--line); }

/* ---------------------------------------------------------------------------------------------- */
/* card — one bordered box, its state on its edge                                                  */
/* ---------------------------------------------------------------------------------------------- */
.card {
  container: card / inline-size;
  position: relative;
  padding-block: var(--space-4);
  padding-inline: calc(var(--space-5) + var(--edge-width)) var(--space-5);
  border: var(--line-width) solid var(--line);
  border-inline-start-width: 0;           /* the edge stands in for the left border */
  border-radius: var(--radius-card);
  background: var(--surface-raised);
  overflow: clip;                         /* clips the edge to the card's curve; not a scroll box */
  transition: border-color var(--motion-fast), background-color var(--motion-fast);
}
.card::before {
  content: "";
  position: absolute;
  inset-block: 0;
  inset-inline-start: 0;
  width: var(--edge-width);
  background: var(--tone, var(--no-answer));
}
.card[data-stripes]::before { background: var(--stripes); }
.card[data-open] { border-color: var(--line-strong); }
/* Scrolled to from elsewhere: the focus ring, outside, the same on both screens. */
.card[data-revealed] { outline: var(--focus-width) solid var(--focus); outline-offset: var(--focus-offset); }
.card[data-struck] { background: transparent; border-style: dashed; }

.card-list { display: grid; gap: var(--space-4); }

/* ---------------------------------------------------------------------------------------------- */
/* host strip — the site shell above both screens                                                  */
/* ---------------------------------------------------------------------------------------------- */
.host-strip {
  container: strip / inline-size;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-3);
  min-height: calc(var(--size) * 3.5);
  padding-block: var(--space-2);
  padding-inline: var(--space-4);
  border-bottom: var(--line-width) solid var(--line);
  background: var(--surface);
}
.host-strip__doc { font-weight: var(--weight-strong); white-space: nowrap; }
.host-strip__spacer { flex: 1 1 0; }
.host-strip__setting { display: inline-flex; align-items: center; gap: var(--space-2); }
.host-strip__setting .field { width: auto; }
.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--height-control);
  height: var(--height-control);
  border: 0;
  border-radius: 50%;
  background: var(--selected);
  color: var(--text);
  font-size: var(--text-xs);
  font-weight: var(--weight-strong);
  cursor: pointer;
}
.avatar:hover { box-shadow: inset 0 0 0 var(--line-width) var(--line-strong); }
.avatar:active, .avatar[aria-expanded="true"] { background: var(--line-strong); }
@container strip (max-width: 440px) { .host-strip__doc { display: none; } .host-strip__setting .label { display: none; } }

/* ================================================================================================ */
/* compositions — layout only; everything visible is a component above                             */
/* ================================================================================================ */

/* claim card ------------------------------------------------------------------------------------ */
.claim { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-3) var(--space-6); }
.claim__main { display: grid; gap: var(--space-2); align-content: start; min-width: 0; }
.claim__sentence, .rule__plain {
  font-family: var(--font-reading);
  font-size: var(--text-xl);
  line-height: var(--leading-xl);
  font-weight: var(--weight-regular);
  color: var(--text);
  text-wrap: pretty;
  /* THE RATIFIABLE LINE IS SOMEBODY'S PROSE and may hold a token nothing can break — a class name, a url, an
     identifier. The claims screen says so for its sentence on '.ctext'; the law screen's '.rule__plain' said nothing,
     so one long word in a rule's plain line ran off the card and '.card''s 'overflow: clip' cut it off unseen. */
  overflow-wrap: anywhere;
}
.claim__verdict { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-2); }
.claim__line { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-2); font-size: var(--text-sm); color: var(--text-dim); }
.claim__line .id { overflow-wrap: anywhere; }
/* A quoted note or an objection: the icon beside the words, never on a line of its own. */
.claim__line[data-quote] { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start; color: var(--text); }
.claim__line[data-quote] > .icon { margin-block-start: 0.15em; }
.claim__quiet { justify-self: start; font-size: var(--text-sm); font-weight: var(--weight-regular); }
.claim__marks { display: inline-flex; gap: var(--space-0); }
.claim__marks .mark { width: var(--text-sm); height: var(--text-sm); }
.claim__rail {
  display: grid;
  grid-template-columns: auto auto var(--height-control-small);
  align-content: start;
  align-items: center;
  gap: var(--space-2);
}
.claim__rail > .label { justify-self: end; }
.claim__body { grid-column: 1 / -1; display: grid; gap: var(--space-5); padding-block-start: var(--space-4); border-top: var(--line-width) solid var(--line); }
.claim__section { display: grid; gap: var(--space-2); }
.claim__own { display: grid; gap: var(--space-1); justify-items: start; }
.claim__actions { display: flex; flex-wrap: wrap; gap: var(--space-2); }
/* NO WIDER THAN WHAT HOLDS IT, AND IT WRAPS RATHER THAN RUN OUT: a chip naming an agent by its whole name and the
   person it typed for, on the tray's page, was one unbreakable line 357px long, and on a phone the page clipped its
   last 20px off. It keeps one line wherever one line fits, so nothing changes where there is
   room; 'flex: none' so a chip in a row still holds its width while there is room for it and the row's other words
   give way first, as they did while it could not wrap at all. */
.agent-chip {
  display: inline-flex; align-items: center; gap: var(--space-1); flex: none; max-width: 100%;
  min-height: var(--height-tag); padding-inline: var(--space-2);
  border: var(--line-width) dashed var(--agent); border-radius: var(--radius-small);
  color: var(--agent); font-size: var(--text-sm); line-height: var(--leading-xs); overflow-wrap: anywhere;
}
.agent-chip .icon { width: var(--text-sm); height: var(--text-sm); }
/* The robot glyph (robotEl): an agent's hand, in the agent's colour, on either screen. */
.robot { color: var(--agent); flex: none; }

.people { display: grid; }
.person {
  display: grid;
  grid-template-columns: calc(var(--text-sm) * 2 + var(--space-1)) 8em minmax(0, 1fr);
  gap: var(--space-1) var(--space-3);
  align-items: baseline;
  padding-block: var(--space-2);
  border-top: var(--line-width) solid var(--line);
}
.person:first-child { border-top: 0; }
.person__name { font-weight: var(--weight-medium); }
.person__what { display: grid; gap: var(--space-2); color: var(--text-dim); }
.person__note { display: grid; gap: var(--space-0); color: var(--text); }
.person[data-agent] {
  margin-block: var(--space-1);
  padding-inline: var(--space-3);
  border: var(--line-width) dashed var(--agent);
  border-radius: var(--radius-control);
}
.person[data-agent] + .person { border-top: 0; }
.person__recorded { grid-column: 2 / -1; display: flex; align-items: center; gap: var(--space-1); font-size: var(--text-sm); color: var(--agent); }

@container card (max-width: 640px) {
  .claim { grid-template-columns: minmax(0, 1fr); }
  .claim__rail { justify-content: start; grid-template-columns: 7.5em auto var(--height-control-small); }
  .claim__rail > .label { justify-self: start; }
  .person { grid-template-columns: calc(var(--text-sm) * 2 + var(--space-1)) minmax(0, 1fr); }
  .person__what, .person__recorded { grid-column: 2; }
}

/* slice header --------------------------------------------------------------------------------- */
.slice-header { container: slice / inline-size; display: grid; gap: var(--space-4); }
.slice-header__top { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-3); }
.slice-header__title { display: grid; gap: var(--space-0); font-size: var(--text-xl); line-height: var(--leading-xl); font-weight: var(--weight-strong); text-wrap: balance; }
.slice-header__lists { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: var(--space-4) var(--space-6); }
.slice-header__list { display: grid; gap: var(--space-2); align-content: start; }
.slice-header__chips { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.slice-header__floor { color: var(--text-dim); }
.slice-header__add { display: flex; gap: var(--space-2); max-width: 26em; }
@container slice (max-width: 640px) { .slice-header__lists { grid-template-columns: minmax(0, 1fr); } }

/* rule card ------------------------------------------------------------------------------------ */
.rule { display: grid; grid-template-columns: 3em minmax(0, 1fr); gap: var(--space-3); }
.rule__id { padding-block-start: var(--space-1); }
.rule__main { display: grid; gap: var(--space-3); min-width: 0; }
.rule__pair { display: grid; gap: var(--space-2); }
.rule__line {
  font-family: var(--font-reading);
  font-size: var(--text-lg);
  line-height: var(--leading-lg);
  color: var(--text-dim);
  text-wrap: pretty;
  /* Markdown brings its own '.md' wrapping; a struck rule's lead is a bare paragraph and does not. */
  overflow-wrap: anywhere;
}
.card[data-open] .rule__line { color: var(--text); }
.rule__labelled { display: grid; gap: var(--space-1); }
.rule__status { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-2) var(--space-4); font-size: var(--text-sm); color: var(--text-dim); font-variant-numeric: tabular-nums; }
.rule__status-words { min-width: 0; }
.rule__status-words > .mark { vertical-align: -0.15em; margin-inline-end: var(--space-1); }
.rule__body { display: grid; gap: var(--space-4); padding-block-start: var(--space-4); border-top: var(--line-width) solid var(--line); }
.rule__vet { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); }
/* A rule missing a slot it needs: loud by pattern and words, with no answer's colour. */
.rule__missing {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-0) var(--space-2);
  padding: var(--space-2) var(--space-3);
  border: var(--line-width) dashed var(--text-faint);
  border-radius: var(--radius-control);
  background: repeating-linear-gradient(135deg, var(--hover) 0 6px, transparent 6px 12px);
}
.rule__missing .icon { margin-block-start: 0.2em; color: var(--text); }
.rule__missing b { font-weight: var(--weight-strong); }
.rule__missing p { grid-column: 2; font-size: var(--text-sm); color: var(--text-dim); }
.claims-cited { display: grid; }
.claims-cited li { list-style: none; padding-block: var(--space-2); border-top: var(--line-width) solid var(--line); font-family: var(--font-reading); font-size: var(--text-md); line-height: var(--leading-md); }
.claims-cited li:first-child { border-top: 0; padding-block-start: 0; }
.claims-cited { padding: 0; }
/* Added for the law screen's build, undesigned: a claim listed under Checked by stands on its claim state's edge, the
   card's edge drawn inside the row so the row's top rule and the edge never meet; its state is in words beside it. */
.claims-cited li[data-tone] { padding-inline-start: calc(var(--edge-width) + var(--space-3)); box-shadow: inset var(--edge-width) 0 0 var(--tone); }
.claims-cited li:first-child[data-tone] { padding-block-start: var(--space-1); }
.claims-cited li .claim__line { font-family: var(--font-sans); }
/* A pointer that reaches no claim: loud by pattern and words, with no answer's colour, as .rule__missing is. */
.claims-cited li[data-loud] {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-2);
  font-family: var(--font-sans);
  background: repeating-linear-gradient(135deg, var(--hover) 0 6px, transparent 6px 12px);
}
.agents { display: grid; gap: var(--space-5); color: var(--text-dim); line-height: var(--leading-lg); }
.agents section { display: grid; gap: var(--space-2); }
.agents p, .agents li { overflow-wrap: anywhere; }
.agents b { color: var(--text); font-weight: var(--weight-strong); }
.agents s { color: var(--text-faint); }
.agents ul { display: grid; gap: var(--space-1); padding-inline-start: var(--space-4); }
.history { display: grid; padding: 0; }
.history > li { list-style: none; display: grid; grid-template-columns: 6.5em minmax(0, 1fr); gap: var(--space-1) var(--space-3); padding-block: var(--space-3); border-top: var(--line-width) solid var(--line); }
.history > li:first-child { border-top: 0; padding-block-start: 0; }
.history__what { color: var(--text); }
.history .fold__body { border-inline-start: var(--line-width) solid var(--line); margin-inline-start: calc(var(--text-md) / 2); padding-inline-start: var(--space-3); }
.said { display: grid; gap: var(--space-0); padding-inline-start: var(--space-3); border-inline-start: 2px solid var(--line-strong); color: var(--text); font-family: var(--font-reading); font-style: italic; }
.said cite { font-family: var(--font-sans); font-style: normal; font-size: var(--text-sm); color: var(--text-dim); }
@container card (max-width: 520px) {
  .rule { grid-template-columns: minmax(0, 1fr); gap: var(--space-1); }
  .history > li { grid-template-columns: minmax(0, 1fr); }
}

/* **THE ONE HOME FOR WHY A SINGLE-COLUMN GRID PINS ITS COLUMN**, and the screens' own sheets point here.

   A grid's implicit column is 'auto', so its MIN track sizing function is 'auto' too, which resolves to the widest
   minimum contribution of anything in it — a folded preview, a 'white-space: nowrap' line, one unbreakable word. The
   column then grows past the box, and everything in it is laid out against the wider figure. 'min-width: 0' on the
   GRID does not answer it: the container shrinks and its column does not. 'minmax(0, 1fr)' does, twice over — the
   column's min becomes 0, and with no 'auto' min, css-grid §6.6 stops giving the items in it an automatic minimum, so
   nothing inside can force it open. ('min-width: 0' on every item also holds it, for exactly the items that carry it.)

   Measured: one long comment made a maximized claim scroll sideways, because '.cline q', a deliberate one-line
   summary, carried its whole line's width up into the column of the fold it sits in ('.thread__body').
   'prose-shrinks-browser.test.ts' puts one long word in every prose slot of both screens and fails naming any
   column that grew. Every single-column grid in a composition is pinned to the width it is given. */
.claim__main, .claim__body, .claim__section, .people, .person__what, .rule__main, .rule__pair, .rule__labelled,
.rule__body, .agents, .agents section, .history > li > div, .card-list, .slice-header, .slice-header__list {
  grid-template-columns: minmax(0, 1fr);
}
.history > li > div { display: grid; gap: var(--space-1); min-width: 0; }

/* ---------------------------------------------------------------------------------------------- */
/* the thumb floor — on a phone every control the system defines is at least 44px tall             */
/* ---------------------------------------------------------------------------------------------- */
/* Claim Q7QH8P: *every control can be pressed with a thumb*. 44px is the floor, '--height-tap' is the token, and
   this is the one place the system's controls are put on it, so the press target and the pointer target are one
   declaration each and cannot come apart.

   **AND THIS ONE IS A MEDIA QUERY ON PURPOSE, which is the opposite of what the rest of this package does.**
   'styles.ts' and 'mount.ts' argue at length that a media query asks the WINDOW about a decision whose cost comes
   out of the COMPONENT'S own width — a 148px rail column eating a third of a 320px box — and they are right about
   that kind of decision. This is not that kind. A thumb belongs to the DEVICE. 44px is the right floor at 390px of
   window whether the component was given 390px or 200px of it, and it is the wrong floor on a 1440px desktop even
   when the component is mounted in a 320px column, because what is pressing there is a mouse. So the viewport is
   the correct box to ask, and a container query would be the wrong question asked precisely.

   **What it costs an adopter, named rather than discovered:** a page read in a browser window 700px wide or
   narrower — a laptop with a half-screen window, not only a phone — gets 44px controls where it used to get 32px.
   Above 700px nothing moves. 700px is the frame's own phone threshold in 'app-styles.ts', reused rather than
   doubled, because two numbers that must agree come apart.

   'min-height' rather than 'height', so a control whose content needs more room still grows, and so a control that
   sets 'height: auto' of its own — '.rule__id' in 'law-styles.ts' is one — is floored all the same. */
@media (max-width: 700px) {
  .button, :where(.mechaneion-chrome) :where(.host-content) :where(button), .button[data-size="small"],
  .icon-button, .vote__option, .switch__option, .field, select.field, .field[data-size="small"],
  .rule__id {
    min-height: var(--height-tap);
  }
  /* THE SYSTEM'S OTHER PRESSABLE ROWS: the fold's summary, a rail row — a book, a rule under it, a shelf — and a chip
     that is a button. Each was a control this sheet defines and left at the desk's floor: measured on the app's own
     page at 390x844 on 2026-10-11 (site/test/every-screen-phone-browser.test.ts), a rule's two folds were 28px, Law's
     book picker drew its books and shelves at 32px and its rules at 28px, and the chip on a claim card that opens a
     commission was 24px. The rule row is named with its level because its own floor above is the more
     specific selector. */
  .fold__summary, .rail-item, .rail-item[data-level="rule"], button.chip, .suggestion { min-height: var(--height-tap); }
  /* An icon-only control needs the floor in both directions: a 44px-tall sliver 28px wide is still a miss. */
  .icon-button { min-width: var(--height-tap); }
  /* The switch is the box its options sit in, so it grows to hold them at the floor rather than capping them at it:
     its own padding is on top, which is why there is no height named here at all. */
  .switch { height: auto; align-items: stretch; }
  /* A textarea is sized by its rows and is already far past the floor; pinning it would cap it. */
  textarea.field { min-height: 0; }

  /* THE PAGE HEADER, ONE SIZE DOWN, and it is here because it is the design system's and both screens wear it.
     Measured in chrome-headless-shell at 390x844 on 2026-10-05: the grouping's name at '--text-2xl' wrapped to three
     lines, 83px, with its counts stacked under it for another 90 — 173px of the window before the screen's own tools,
     on a screen where not one claim card was wholly inside it. The counts take the quiet size they wear everywhere
     else. Above 700px nothing moves. */
  .page-header__title { font-size: var(--text-lg); line-height: var(--leading-lg); }
  .page-header__counts { font-size: var(--text-xs); line-height: var(--leading-xs); gap: var(--space-0) var(--space-3); }
  /* The 20px column gap between the title and the counts was what put the counts on four lines at 320px. */
  .page-header { gap: var(--space-0) var(--space-3); }
}

@media (prefers-reduced-motion: reduce) {
  :where(.mechaneion-chrome), :where(.mechaneion-chrome) *, :where(.mechaneion-chrome)::before, :where(.mechaneion-chrome) *::before, :where(.mechaneion-chrome)::after, :where(.mechaneion-chrome) *::after { transition: none !important; scroll-behavior: auto !important; }
}


/* Pinned to its containing block's top corner: the rail's live region is the body's last child, and left at its static
   place it sat 1px below the window and gave the whole page a 1px scroll (measured at 1440x900 and 390x844). */
.sr { position: absolute; top: 0; left: 0; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---- the app's frame: a rail and a pane ----------------------------------------------------------- */
/* The app IS the window, edge to edge: no border and no radius. v6 draws it as a card inset in a pretend desktop window,
   and that card is the mockup's picture of a window, not a part of the app. Above a phone nothing outside it scrolls;
   the rail's open section and the pane each scroll inside themselves. **On a phone the document scrolls instead**, and
   the phone block at the end of this sheet says why.
   **And nothing can scroll them, which is what 'clip' says and 'hidden' does not** (task K91AMG). A box under 'hidden' is
   still a scroll box that only a thumb cannot move: a 'scrollIntoView' or a focus moves it whenever it has room, and a
   live region placed absolutely in a page counts toward the frame's height, not the pane's. Opening a commission at
   its top waiting card scrolled '.appmain' 270px up at 390, out from under the pane, where no thumb could bring it back:
   Work's tabs above the window and a blank band under the page. 'hidden' stays as the fallback for a browser without
   'clip', which shows nothing different until something scrolls it. */
.app { --rail-w: 320px; --st-in: var(--works); --st-live: var(--agent); --st-you: var(--vet-wrong); --st-bad: var(--doesnt);
  flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; overflow: hidden; overflow: clip; background: var(--surface-raised); }
/* The rail, its handle and the pane, under the header: the row the app used to be. */
.appmain { position: relative; flex: 1 1 auto; min-height: 0; display: flex; overflow: hidden; overflow: clip; }

/* ---- THE HEADER: ☰, the mark, the project, and whoever is signed in -------------------------------- */
/* ☰ is the header's first thing at every width, the rail's one button (PAGE 5.33). Mechaneion's mark follows it at every
   width and in every state, signed out included (EE19TS), and the project is BESIDE it rather than in place of it. The account is at the far right, which is what took the sign-in out of the
   rail. Nothing here scrolls. Above a phone nothing here moves either: the bar is the frame's one fixed row. On a phone
   it slides away while he scrolls down and comes back when he scrolls up (the phone block below). */
.appbar { flex: none; display: flex; align-items: center; gap: var(--space-3); min-height: var(--height-control);
  padding: var(--space-1) var(--space-3) var(--space-1) var(--space-2); border-bottom: var(--line-width) solid var(--line); background: var(--surface); }
.appbar .brand { flex: none; display: flex; align-items: center; gap: var(--space-2); min-width: 0; }
/* The one bronze thing on the page, and the one glyph with a stroke of its own (icons.ts). */
.appbar .brand__mark { width: calc(var(--size) * 1.375); height: calc(var(--size) * 1.375); color: var(--bronze); }
.appbar .brand__name { font-size: var(--text-lg); font-weight: var(--weight-strong); color: var(--text); white-space: nowrap; }
/* The project, named after the mark: a picker when the page can offer one, and the name alone when it cannot. */
.appbar__proj { position: relative; min-width: 0; display: flex; align-items: center; }
.appbar__proj:empty { display: none; }
.appbar .proj { min-width: 0; display: flex; align-items: center; gap: var(--space-1); min-height: var(--height-control-small);
  padding-inline: var(--space-2); border: 0; border-radius: var(--radius-control); background: transparent; color: var(--text); font: inherit; }
.appbar button.proj { cursor: pointer; }
.appbar button.proj:hover, .appbar button.proj[aria-expanded="true"] { background: var(--hover); }
.appbar .proj::before { content: ""; flex: none; width: var(--line-width); height: var(--text-md); margin-inline-end: var(--space-2); background: var(--line-strong); }
.appbar .proj__name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: var(--weight-medium); }
.appbar .proj__more { flex: none; display: inline-grid; color: var(--text-faint); }
.appbar .proj__more .icon { width: var(--text-sm); height: var(--text-sm); }
.projmenu { position: absolute; z-index: 45; top: calc(100% + var(--space-1)); inset-inline-start: var(--space-2); min-width: 16rem; }
.projmenu[hidden] { display: none; }
.projmenu .menu__item[aria-current="true"] { background: var(--selected); }
/* A project with an address is a link (ShellProjectChoice.href), drawn as the button beside it is. */
.projmenu a.menu__item { text-decoration: none; }
/* Whoever is signed in, hard against the window's right edge. */
.appbar__end { position: relative; margin-inline-start: auto; min-width: 0; max-width: 60%; display: flex; align-items: center; justify-content: flex-end; }

/* ---- THE TRAY: its button and badge in the header, just left of whoever is signed in, and its popover (tray-styles.ts) ---- */

/* the button, just left of whoever is signed in, and its count of what has not been opened */
.traybtn { position: relative; flex: none; display: inline-grid; place-items: center; width: var(--height-control); height: var(--height-control);
  margin-inline-end: var(--space-1); padding: 0; border: 0; border-radius: var(--radius-control); background: transparent; color: var(--text-dim); cursor: pointer; }
.traybtn .icon { width: var(--text-lg); height: var(--text-lg); }
.traybtn:hover, .traybtn[aria-expanded="true"] { background: var(--hover); color: var(--text); }
.traybtn:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -1px; }
.traybtn__badge { position: absolute; top: 1px; inset-inline-end: 0; min-width: 17px; height: 17px; padding: 0 5px; border-radius: 999px;
  font-size: calc(var(--size) * 0.6875); line-height: 17px; font-weight: 600; font-variant-numeric: tabular-nums; text-align: center;
  color: var(--ground); background: var(--bronze); box-shadow: 0 0 0 2px var(--surface); }
.traybtn__badge[hidden] { display: none; }
@media (pointer: coarse), (max-width: 700px) { .traybtn { width: var(--height-tap); height: var(--height-tap); } }

/* ---- tray (the mockup's, as written) ---- */
.traypop { --t-line-soft: color-mix(in srgb, var(--line) 37%, var(--surface)); --t-fg-dim: color-mix(in srgb, var(--text) 50%, var(--text-dim));
  --t-faint: color-mix(in srgb, var(--text-faint) 60%, var(--surface)); --t-bronze-lift: color-mix(in srgb, var(--bronze) 55%, var(--text));
  position: absolute; z-index: 45; top: calc(100% + var(--space-1)); inset-inline-end: 0; width: min(372px, calc(100vw - 32px));
  max-height: min(70vh, 560px); overflow-y: auto; overscroll-behavior: contain;
  background: var(--surface); border: 1px solid var(--line); border-radius: 13px; box-shadow: var(--shadow-popover); color: var(--text); text-align: start; }
.traypop[hidden] { display: none; }
.traypop__top { display: flex; align-items: center; gap: 10px; padding: 13px 15px; border-bottom: 1px solid var(--line); }
.traypop__title { font-size: var(--text-md); font-weight: 600; flex-grow: 1; min-width: 0; }
.traypop__count { font-size: calc(var(--size) * 0.6875); color: var(--ground); background: var(--bronze); border-radius: 999px; padding: 2px 8px; font-weight: 600; font-variant-numeric: tabular-nums; }
.traypop__seenall { font: inherit; font-size: var(--text-xs); background: none; border: none; color: var(--text-faint); cursor: pointer; padding: 4px 2px; min-height: 32px; }
.traypop__seenall:hover { color: var(--t-bronze-lift); }

.tgroup { border-bottom: 1px solid var(--t-line-soft); }
.tgroup__head { display: flex; gap: 10px; padding: 12px 15px 9px; align-items: baseline; }
.tgroup__why { flex-grow: 1; min-width: 0; font-size: calc(var(--size) * 0.78125); color: var(--t-fg-dim); }
.tgroup__when { font-size: calc(var(--size) * 0.6875); color: var(--t-faint); flex: none; font-variant-numeric: tabular-nums; }
.tgroup__rows { padding: 0 15px 11px; display: flex; flex-direction: column; gap: 2px; }

.trow { display: flex; gap: 10px; align-items: flex-start; width: 100%; padding: 8px 10px; border: 0; border-radius: 8px; background: var(--surface-raised);
  font: inherit; text-align: start; text-decoration: none; color: inherit; cursor: pointer; }
.trow:hover { background: var(--hover); }
.trow--alone { margin: 0 15px 11px; width: calc(100% - 30px); }
/* A line told on its own straight under the top: the mockup's groups open with their head's 12px, so a lone row takes 11. */
.traypop__top + .tline > .trow--alone { margin-top: 11px; }
.traypop:focus { outline: none; }
.tdot { width: 6px; height: 6px; border-radius: 50%; flex: none; margin-top: 7px; }
.tdot--assigned { background: var(--vet-good); }
.tdot--back { background: var(--bronze); }
.tdot--told { background: var(--text-faint); }
.tdot--waiting { background: var(--rung-needsyou); }
.tline--waiting { margin-top: 11px; }
.trow__body { flex-grow: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.trow__what { font-size: var(--text-sm); line-height: 1.35; overflow-wrap: anywhere; }
.trow__kind { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 7px; font-size: calc(var(--size) * 0.65625); letter-spacing: 0.05em; text-transform: uppercase; color: var(--t-faint); font-weight: 600; }
.trow__note { font-size: var(--text-xs); line-height: 1.35; color: var(--text-faint); overflow-wrap: anywhere; }
.trow__n { font-size: calc(var(--size) * 0.71875); color: var(--text-faint); flex: none; font-variant-numeric: tabular-nums; margin-top: 2px; }
.trow__waiting { display: inline-flex; align-items: center; padding: 1px 6px; border-radius: var(--radius-small); letter-spacing: 0.03em;
  color: var(--rung-needsyou); background: color-mix(in srgb, var(--rung-needsyou) var(--wash), transparent); }
/* the line's dismiss: sees every thing in it without opening it (4BQFA2) */
.tline { position: relative; }
.tline__x { position: absolute; top: 8px; inset-inline-end: 10px; display: inline-grid; place-items: center; width: 24px; height: 24px; padding: 0;
  border: 0; border-radius: 6px; background: transparent; color: var(--t-faint); cursor: pointer; }
.tline__x:hover { background: var(--hover); color: var(--text); }
.tline__x .icon { width: 14px; height: 14px; }
.tgroup.tline .tline__x { top: 9px; }
.tgroup.tline .tgroup__head { padding-inline-end: 44px; }
.tline > .trow--alone { padding-inline-end: 36px; }
/* On a lone row the dismiss sits inside the row's own corner: the row's 15px margin, then 10px in. */
.tline > .trow--alone ~ .tline__x { inset-inline-end: 25px; }
.traypop__top + .tline > .trow--alone ~ .tline__x { top: 19px; }

.traypop__none { margin: 0; padding: 16px 15px; font-size: calc(var(--size) * 0.78125); color: var(--text-faint); }
.traypop__foot { padding: 11px 15px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.traypop__foot button { font: inherit; font-size: calc(var(--size) * 0.78125); color: var(--bronze); background: none; border: 0; padding: 4px 0; min-height: 32px; cursor: pointer; }
.traypop__foot button:hover { color: var(--t-bronze-lift); }
.traypop__foot span { font-size: calc(var(--size) * 0.71875); color: var(--t-faint); }
.trow:focus-visible, .traypop__seenall:focus-visible, .traypop__foot button:focus-visible, .tline__x:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -1px; }
/* IN A HAND THE POPOVER'S PRESSES ARE A THUMB'S FLOOR. Measured with a thumb at 390x844: the top's press that sees
   everything was 32px tall, and a line's dismiss a 24px square in the line's corner. The square becomes the line's
   whole top corner at 44px, and the words beside it give it the room. */
@media (pointer: coarse), (max-width: 700px) {
  .traypop__seenall, .traypop__foot button { min-height: var(--height-tap); }
  .tline__x, .tgroup.tline .tline__x { top: 0; inset-inline-end: 0; width: var(--height-tap); height: var(--height-tap); }
  .tgroup.tline .tgroup__head { padding-inline-end: calc(var(--height-tap) + var(--space-1)); }
  .tline > .trow--alone { padding-inline-end: calc(var(--height-tap) + var(--space-1)); }
  .tline > .trow--alone ~ .tline__x { inset-inline-end: 15px; }
  .traypop__top + .tline > .trow--alone ~ .tline__x { top: 11px; }
}

/* THE MARK ON THE PROJECT SWITCHER: a project whose tray holds something not yet opened */
.proj__lit, .menu__lit { flex: none; width: 7px; height: 7px; border-radius: 50%; background: var(--bronze); }
.proj__lit { margin-inline-start: var(--space-1); }
.menu__item .menu__lit { margin-inline-start: auto; }


/* ---- THE RAIL: commissions, always there ----------------------------------------------------------- */
.lrail { flex: none; width: var(--rail-w); min-width: 0; min-height: 0; display: flex; flex-direction: column; background: var(--surface); }
.icon-button .icon { width: var(--text-lg); height: var(--text-lg); }
/* **FOLDED TO ITS ICONS, on a computer** (PAGE 5.33): ☰ folds the rail to each section's glyph and back, as rail mockup B
   draws it (commission 54G34Y, '.rm[data-collapsed]' in rail-mock.ts at cb87b186), tokens only. Every row keeps its glyph
   and its count; its name is hidden to the eye and still said to a screen reader, and on hover or focus the rail's one
   label, '.rail-tip', says it beside the row (PAGE 5.21). Commissions' states fold into its count, and nothing drags the
   rail wider. The frame draws 'data-rail="folded"' only where the rail is no drawer, so the drawer is always the whole rail. */
.app[data-rail="folded"] .lrail { width: 60px; }
.app[data-rail="folded"] .handle { display: none; }
.app[data-rail="folded"] .lrail .rail-item { grid-template-columns: 1fr; justify-items: center; padding-inline: 0; position: relative; }
.app[data-rail="folded"] .lrail .rail-item__name { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.app[data-rail="folded"] .lrail .rail-item__meta { position: absolute; top: 1px; right: 4px; }
.app[data-rail="folded"] .lrail .rail-folder { grid-template-columns: minmax(0, 1fr); }
/* The Set up row (SETUP 6.15) folds to its ring, which draws its progress itself: its "1 of 4" is hidden to the eye as a
   name is, since it lay over the ring, and its tip says "Set up · 1 of 4", the row's own words open. */
.app[data-rail="folded"] .lrail .setup-row .rail-item__meta { width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.app[data-rail="folded"] .lrail .rail-fold { display: none; }
.app[data-rail="folded"] .lrail .rail-row { padding-inline-start: 0; }
.app[data-rail="folded"] .lrail .rail-row__n, .app[data-rail="folded"] .lrail .rail-count { min-width: 15px; height: 15px; padding: 0 4px; border-radius: 999px;
  background: var(--surface-raised); box-shadow: 0 0 0 1px var(--line); font-size: 10px; line-height: 15px; text-align: center; color: var(--text-dim); }
.app[data-rail="folded"] .lrail .acc__waits { min-width: 15px; height: 15px; line-height: 15px; padding: 0 4px; font-size: 10px; margin: 0; }
.app[data-rail="folded"] .foot__screens { flex-direction: column; padding-inline: var(--space-1); }
.app[data-rail="folded"] .scr span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.rail-count { font-size: var(--text-xs); color: var(--text-faint); font-variant-numeric: tabular-nums; }
.rail-tip { position: fixed; z-index: 60; transform: translateY(-50%); padding: 3px 8px; border-radius: var(--radius-control); background: var(--text); color: var(--ground);
  font-size: var(--text-xs); line-height: var(--leading-xs); white-space: nowrap; pointer-events: none; box-shadow: var(--shadow-popover); }
.rail-tip[hidden] { display: none; }

/* the drag handle on the rail's right edge: a hairline that thickens under the pointer, while dragging, and on focus */
.handle { flex: none; position: relative; z-index: 6; width: 11px; margin-inline: -5px; cursor: col-resize; touch-action: none; outline: none; }
.handle::before { content: ""; position: absolute; inset-block: 0; left: 5px; width: var(--line-width); background: var(--line);
  transition: background-color var(--motion-fast), box-shadow var(--motion-fast); }
.handle:hover::before { background: var(--line-strong); box-shadow: 0 0 0 1px var(--line-strong); }
.handle[data-dragging]::before { background: var(--text-dim); box-shadow: 0 0 0 1px var(--text-dim); }
.handle:focus-visible::before { background: var(--focus); box-shadow: 0 0 0 1px var(--focus); }
.handle__grip { position: absolute; top: 50%; left: 50%; width: 6px; height: 32px; transform: translate(-50%, -50%); border-radius: 3px;
  background: var(--surface-raised); box-shadow: inset 0 0 0 1px var(--line-strong); opacity: 0; pointer-events: none; transition: opacity var(--motion-fast); }
.handle:hover .handle__grip, .handle:focus-visible .handle__grip, .handle[data-dragging] .handle__grip { opacity: 1; }
.handle:focus-visible .handle__grip { box-shadow: inset 0 0 0 2px var(--focus); }
body[data-dragging], body[data-dragging] * { cursor: col-resize !important; user-select: none; }

/* ---- THE ACCORDION: Commissions, Claims, Law, in that order, ONE open at a time (ruled by Zack, 28 Sep) ------------- */
/* The open section takes the rail's remaining height and scrolls on its own; the headers below it sit just above the foot. */
/* v6: any section can close, down to none open, when the headers stack at the top and the rail below them is empty.
   A section is its header and its FOLD — the one wrapper around its list — laid straight into the column, so the open fold
   takes the remaining height. Opening, closing and switching animate the folds' heights (from script: see accAnimate). */
.acc { position: relative; flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.acc__sec { display: contents; }
.acc[data-none]::after { content: ""; flex: none; border-top: var(--line-width) solid var(--line); }
.acc__head { position: relative; flex: none; display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: var(--space-1); padding: var(--space-1) var(--space-2);
  border-top: var(--line-width) solid var(--line); cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none; }
.acc__fold { flex: 0 0 0; min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.acc__fold[hidden] { display: none; }
.acc__sec[data-open] > .acc__fold { flex: 1 1 0; }
/* v6: a header drags up or down to reorder the sections. The grip is a quiet handle in its left margin, shown under the pointer;
   the header's background is the drag surface (its chevron and name keep the pointer). Lifted, it floats on the popover's shadow. */
.acc__grip { position: absolute; left: 1px; top: 50%; width: 6px; height: 10px; margin-top: -5px; color: var(--text-faint); opacity: 0;
  pointer-events: none; transition: opacity var(--motion-fast); }
.acc__head:hover .acc__grip, .acc__head:has(:focus-visible) .acc__grip, .acc__head[data-lifted] .acc__grip { opacity: 1; }
@media (hover: none) { .acc__grip { opacity: 0.6; } }
.acc__head[data-lifted] { z-index: 5; transform: translateY(var(--lift, 0px)) scale(1.02); border-top-color: transparent; border-radius: var(--radius-control);
  background: var(--surface-raised); box-shadow: var(--shadow-popover), 0 0 0 var(--line-width) var(--line-strong); }
.acc__head[data-lifted] .acc__name:not([aria-current="page"]) { background: transparent; }
body[data-reordering], body[data-reordering] * { cursor: grabbing !important; user-select: none; -webkit-user-select: none; }
/* where it lands: a line across the rail with a ring at its start, drawn over the lifted header rather than under it */
.acc__drop { position: absolute; z-index: 6; left: var(--space-1); right: var(--space-2); height: 2px; border-radius: 1px; background: var(--focus); pointer-events: none; }
.acc__drop::before { content: ""; position: absolute; left: -4px; top: -3px; width: 8px; height: 8px; border: 2px solid var(--focus); border-radius: 50%; background: var(--surface); }
.acc__drop[hidden] { display: none; }
/* two targets, and they look it: the chevron is a small box of its own; the name is a wide row */
.acc__chev { display: inline-grid; place-items: center; width: var(--height-control-small); height: var(--height-control-small); padding: 0;
  border: var(--line-width) solid var(--line); border-radius: var(--radius-control); background: var(--surface-raised); color: var(--text-faint); cursor: pointer;
  transition: background-color var(--motion-fast), color var(--motion-fast), border-color var(--motion-fast); }
.acc__chev .icon { width: var(--text-sm); height: var(--text-sm); transition: transform var(--motion-fast); }
.acc__chev[aria-expanded="true"] { background: transparent; border-color: transparent; }
.acc__chev[aria-expanded="true"] .icon { transform: rotate(90deg); }
.acc__chev:hover { background: var(--hover); color: var(--text); border-color: var(--line-strong); }
.acc__name { min-width: 0; display: flex; align-items: center; gap: var(--space-2); min-height: var(--height-control); padding-inline: var(--space-2);
  border: 0; border-radius: var(--radius-control); background: transparent; color: var(--text); font: inherit; font-weight: var(--weight-strong); text-align: start; cursor: pointer; }
.acc__name:hover { background: var(--hover); }
.acc__name:active { background: var(--selected); }
.acc__name[aria-current="page"] { background: var(--selected); }
.acc__name .icon { color: var(--text-dim); }
.acc__sum { margin-inline-start: auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: var(--text-sm);
  font-weight: var(--weight-regular); color: var(--text-faint); font-variant-numeric: tabular-nums; }
/* How many things wait on him in the section, open or closed (claims K1GEK0, 0E1RHF): the tray badge's pill. */
.acc__waits { flex: none; min-width: 17px; height: 17px; margin-inline-start: var(--space-1); padding: 0 5px; border-radius: 999px;
  font-size: var(--text-xs); line-height: 17px; font-weight: 600; font-variant-numeric: tabular-nums; text-align: center;
  color: var(--ground); background: var(--bronze); }
.acc__pick { flex: none; display: block; padding: 0 var(--space-2) var(--space-1) calc(var(--space-2) + var(--height-control-small) + var(--space-1)); }
.acc__pick .field { width: 100%; }
.acc__body { flex: 1 1 0; min-height: 0; overflow-y: auto; overflow-x: hidden; padding: var(--space-1) var(--space-2) var(--space-4); }
.acc__quiet { font-style: italic; }
.acc > .acc__quiet { padding: var(--space-3) var(--space-2); }
.acc .rail { gap: 1px; }
.acc .rail-item { align-items: start; padding-block: var(--space-1); }
.acc .rail-item__name { white-space: normal; overflow-wrap: anywhere; }
/* v6: Claims in the rail is grouped by TIER (Zack, 28 Sep). Each tier is a heading that folds, drawn like a Law book in the
   same rail, and its slices sit under it in the same indented group Law's rules do. */
.acc__item { grid-template-columns: minmax(0, 1fr) auto; row-gap: var(--space-1); }
.acc__item .rail-item__meta { padding-top: 1px; }
.acc__item > .rungs { grid-column: 1 / -1; margin-bottom: 2px; }
/* An area's row (round five of the area page, approved 2026-10-22): its name, a thin bar of where its claims stand, and
   what waits there in the Areas screen's own words and tones. */
.acc__area > .acc__mbar { grid-column: 1 / -1; display: flex; gap: 1px; height: 4px; border-radius: 2px; overflow: hidden; background: var(--line); }
.acc__mbar > span { display: block; height: 100%; min-width: 2px; }
.acc__mbar > .s-green { background: var(--works); }
.acc__mbar > .s-vet { background: var(--vet-good); }
.acc__mbar > .s-mark { background: var(--agent); }
.acc__mbar > .s-unheld { background: var(--vet-wrong); }
.acc__mbar > .s-failing { background: var(--doesnt); }
.acc__area > .acc__words { grid-column: 1 / -1; font-size: var(--text-sm); line-height: var(--leading-sm); color: var(--text-dim); font-variant-numeric: tabular-nums; }
.acc__words .w-in-flight { color: var(--agent); font-weight: var(--weight-medium); }
.acc__words .w-for-you { color: var(--vet-wrong); font-weight: var(--weight-strong); }
.acc__words .w-bugs { color: var(--doesnt); font-weight: var(--weight-medium); }
.acc__words .w-none, .acc__words .dotsep { color: var(--text-faint); }
.acc .tierhead { align-items: center; row-gap: var(--space-1); padding-block: var(--space-1) var(--space-2); font-size: var(--text-sm); color: var(--text-dim); }
.tierhead b { font-weight: var(--weight-medium); color: var(--text); }
.tierhead > .rungs { grid-column: 2 / -1; }
.tierpass { font-size: var(--text-xs); line-height: var(--leading-xs); letter-spacing: var(--tracking-label); text-transform: uppercase; color: var(--works); }
.tier__fold { overflow: hidden; }
.tier__fold[hidden] { display: none; }
/* THE CLAIMS SCREEN'S OWN BAR — '.rungs', exactly as that screen draws it on a slice card and beside a tier, from the
   one sheet both draw it with (RUNGS_STYLES, rungs.ts). One bar, at the tier and at the slice, so a reader learns it once. */
.app { --rung-h: 8px; }
.rungs { display: flex; height: var(--rung-h); gap: var(--line-width); border-radius: var(--radius-small); overflow: hidden; background: var(--rung-none); }
.rungs > span { display: block; min-width: 0; }
.rungs > [data-rung="none"] { background: var(--rung-none); }
.rungs > [data-rung="vetted"] { background: var(--rung-vetted); }
.rungs > [data-rung="almost"] { background: var(--rung-almost); }
.rungs > [data-rung="works"] { background: var(--rung-works); }
.rungs > [data-rung="safe"] { background: var(--rung-safe); }
.rungs > [data-rung="needsyou"] { background: var(--rung-needsyou); }
.acc .rail-item[data-level="book"] { align-items: center; }
.acc .rail-item[data-level="book"] > .rail-item__name.id { font-size: var(--text-sm); color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acc .rail-item[data-level="rule"] { align-items: baseline; }
.acc .rail-item[data-level="rule"] .rail-item__name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.acc .rail-group { margin-block: 2px var(--space-2); }
/* Law's shelf: a small tray at the foot of the Law section */
.acc__tray { flex: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-1); padding: var(--space-2); border-top: var(--line-width) solid var(--line); }
.shelf { display: flex; align-items: center; justify-content: space-between; gap: var(--space-2); min-width: 0; min-height: var(--height-control-small); padding-inline: var(--space-2);
  border: var(--line-width) solid var(--line); border-radius: var(--radius-control); background: var(--surface-raised); color: var(--text-dim); font: inherit; font-size: var(--text-sm); cursor: pointer; }
.shelf:hover { background: var(--hover); color: var(--text); }
.shelf[aria-current="true"] { background: var(--selected); color: var(--text); }
.shelf__n { font-variant-numeric: tabular-nums; color: var(--text-faint); }

/* Law's own rail rows, as the law screen draws them (LAW_RAIL_STYLES): the section heads, the loud count, the markers. */
.rail-item__meta[data-loud] { color: var(--text); font-weight: var(--weight-strong); }
/* The robot on a rule an agent added alone takes a column of its own after the title, so the row stays one line. */
.rail-item[data-level="rule"] > .law__rail-agent { grid-row: 1; grid-column: 4; display: inline-flex; }
/* The forbids moved under a standing vetting: the same column trick as the robot, one further along, and faint —
   the vetting is not sent back, so the rail says look, never wrong. */
.rail-item[data-level="rule"] > .law__rail-moved { grid-row: 1; grid-column: 5; display: inline-flex; color: var(--text-faint); }
.law__rail-moved > .icon { width: var(--text-sm); height: var(--text-sm); }
/* The same index in the rail, where the heading is a label over its run and may be longer than the rail is wide. */
.law__rail-section { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---- rows of work: For you's lines and the Backlog tab's items (COMMISSIONS_RAIL_STYLES, v6's rail rows) ----
   They were the rail's Commissions section; the rail is For you, Work, Law and Settings now (PAGE 5.5), and the same rows
   are drawn in the frame's own pages, so the one sheet is scoped to those pages instead of to the rail. */

/* **The gap between groups is bigger than the gap inside one**, which is most of what makes a long list readable:
   2px between the lines of one commission, 8px between commissions, 20px between groups. */
.shellpage .bk { margin-block-end: var(--space-5); }
.shellpage .bk:last-child { margin-block-end: 0; }
/* A group's rows, hanging off a hairline, as .rail-group holds the Claims and Law rails' rows. */
.shellpage .bk__items { display: grid; gap: var(--space-2); margin-inline-start: calc(var(--space-2) + var(--text-md) / 2);
  padding-inline-start: var(--space-2); border-inline-start: var(--line-width) solid var(--line); }
.shellpage .bkh { margin: 0; font: inherit; }
.shellpage .row { position: relative; display: grid; grid-template-columns: minmax(0, 1fr); gap: 2px var(--space-2); width: 100%;
  padding: var(--space-2); border: 0; border-radius: var(--radius-control); background: transparent; color: inherit;
  font: inherit; text-align: start; cursor: pointer; }
/* **A ROW IS ONE COLUMN, AND ONLY A ROW WITH A GLYPH HAS A GLYPH'S COLUMN — WITH EVERY OTHER LINE OF IT IN THE SECOND**
   (bug 4S7S66). Nothing expands in a commission's row (QMBVA1), so its name and every line under it start at the row's
   own edge, each on its own grid row, and the width a chevron took goes back to the title; a loose row's glyph still
   has its column. The rail used to give EVERY row the glyph's column and take it away again kind by kind — a
   commission's row, For you's decisions row, the row for a commission it cannot read — and a row whose kind was not on
   that list put its first line in a column one em wide, a letter or two a line: the unreadable row measured 14px in a
   304px row (task EEJVT5), and when For you's row became a row per line under a new attribute, its titles did the same
   on Zack's rail. So the column follows the glyph itself, and a row of any kind, named or not, cannot have one without
   it. In a row that has it, the rule places every line but the glyph, not the lines it knows of: one line it did not
   name would otherwise take the glyph's cell on the next grid row. It outranks every .shellpage .row .x, so it cannot lose
   on source order, as a blanket child rule here once did, leaving a name in a nought-wide column 891px tall. */
.shellpage .row:has(> .gl) { grid-template-columns: var(--text-md) minmax(0, 1fr); }
.shellpage .row:has(> .gl) > :not(.gl) { grid-column: 2; }
/* For you's rows that are no commission's (WK1M80) are drawn in a commission's row's grammar, so their names are weighted
   as a commission's are: one fold, one weight for what each line is called. */
.shellpage .row[data-for-you-row] .nm { font-weight: var(--weight-strong); }
.shellpage .row:hover { background: var(--hover); }
.shellpage .row[aria-current="true"] { background: var(--selected); }
.shellpage .row[data-inside="true"] { background: color-mix(in srgb, var(--selected) 55%, transparent); }
.shellpage .row .nm { min-width: 0; overflow-wrap: anywhere; line-height: 1.3; }
/* **A commission's row leads with its NAME, so it is weighted like one** (37YBBY, his option A on the rail mockup):
   a loose row's label stays regular, so the rail reads as a list of names. Only a commission's row carries data-cm. */
.shellpage .row[data-cm] .nm { font-weight: var(--weight-strong); }
/* **A COMMISSION'S TITLE AND ITS KEY SHARE ONE LINE** (NKA5EA): the key is on the rail where a reader handed one can
   match it, and it takes no line of its own — the grammar ruled for a claim's key (2GBS5G). A second grid track was
   the other way to lay this out and is the wrong one: an auto track beside an fr one is sized first and eats it, which
   is the failure the .nm floor comment below records. So the pair is ONE grid child and the key flows inline after the
   title, wherever the title's last line ends. */
.shellpage .row .nmline { min-width: 0; overflow-wrap: anywhere; line-height: 1.3; }
.shellpage .row .nmline .id { margin-inline-start: var(--space-2); font-family: var(--font-mono); font-size: var(--text-xs);
  font-weight: var(--weight-regular); white-space: nowrap; color: var(--text-faint); }
.shellpage .row .mt { display: flex; flex-wrap: wrap; align-items: center; gap: 2px var(--space-2); font-size: var(--text-sm); line-height: 1.35; color: var(--text-faint); }
/* **A pip strip WRAPS in a 320px rail**, where it does not in the pane: measured in chrome-headless-shell at 1440x900
   over the live board of 2026-10-09, the 25 pips of *Zack signs up on a live Mechaneion* ran 6.83px past the rail's
   clipped edge, so its last three tasks were not drawn at all and nothing said so. */
.shellpage .row .pips { flex-wrap: wrap; min-width: 0; }
.shellpage .row .gl { color: var(--text-faint); text-align: center; line-height: 1.3; }
.shellpage .row .say { font-size: var(--text-sm); line-height: 1.35; color: var(--text-dim); }
.shellpage .row .say[data-tone] { color: var(--tone); }
.shellpage .row .flag { display: flex; gap: var(--space-1); align-items: flex-start; font-size: var(--text-sm); line-height: 1.35; font-weight: var(--weight-medium); color: var(--doesnt); }
.shellpage .row .flag .icon, .shellpage .row .offerline .icon { width: var(--text-sm); height: var(--text-sm); margin-top: 0.12em; }
.shellpage .row .offerline { display: flex; gap: var(--space-1); align-items: flex-start; font-size: var(--text-sm); line-height: 1.35; color: var(--unsaved); }
.shellpage .row[data-alarm="true"] { background: color-mix(in srgb, var(--doesnt) 7%, transparent); box-shadow: inset 2px 0 0 var(--doesnt); }
.shellpage .row[data-alarm="true"][aria-current="true"] { background: color-mix(in srgb, var(--doesnt) 13%, var(--selected)); }
/* **A row's tone, and data-s is now only ever a LOOSE row's** (QMBVA1): the rail drew a task's row and a served
   claim's, which carried landed, you, dropped and the two claim tones, and not one of them can be drawn here any more.
   What looseRow says is working, idle and none; the two below are the two that had a rule, and idle has never had one,
   which is a design question and not this change's to answer. */
.shellpage .row[data-s="working"] .gl, .shellpage .row[data-s="working"] .mt .w { color: var(--st-live); }
.shellpage .row[data-s="none"] .nm { color: var(--text-dim); }
/* A commission that is over, on the row itself: the wrapper that used to carry this held the row and what the chevron
   opened under it, and there is nothing under a row any more (QMBVA1). A finished rule sat here too, colouring the
   glyph in a commission's row — which has never had one, so nothing could ever have drawn it. */
.shellpage .row[data-end="dropped"] .nm { color: var(--text-faint); text-decoration: line-through; text-decoration-color: var(--line-strong); }
.shellpage .row[data-end="dropped"] { outline: var(--line-width) dashed var(--line-strong); outline-offset: -1px; }
.shellpage .row[hidden] { display: none; }

/* who has it — a name, and a dot for how its session is */
.own { display: inline-flex; align-items: center; gap: var(--space-1); color: var(--text); font-weight: var(--weight-medium); white-space: nowrap; }
.own::before { content: ""; flex: none; width: 0.55em; height: 0.55em; border-radius: 50%; background: var(--agent); }
.own[data-o="unreachable"]::before, .own[data-o="unknown"]::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--text-faint); }
.own[data-o="ended"] { color: var(--doesnt); }
.own__unread { color: var(--unsaved); font-weight: 600; }
.holder__unread { grid-column: 1 / -1; margin-top: 8px; }
.holder__unread ul { margin: 4px 0 0; padding-left: 18px; }
.holder__unread li { margin: 2px 0; }
.own[data-o="ended"]::before { background: var(--doesnt); }
.own[data-o="none"] { color: var(--text-faint); }
.own[data-o="none"]::before { background: var(--line-strong); }
.pips { display: inline-flex; gap: 2px; vertical-align: middle; }
.pips i { width: calc(var(--size) * 0.56); height: calc(var(--size) * 0.56); border-radius: 2px; background: var(--line-strong); }
.pips[data-big] i { width: calc(var(--size) * 0.85); height: calc(var(--size) * 0.85); border-radius: 3px; }
.pips i[data-s="landed"] { background: var(--st-in); }
.pips i[data-s="working"] { background: var(--st-live); }
.pips i[data-s="you"] { background: var(--st-you); }
.pips i[data-s="idle"] { background: transparent; box-shadow: inset 0 0 0 1.5px var(--st-bad); }
.pips i[data-s="none"] { background: transparent; box-shadow: inset 0 0 0 1.5px var(--line-strong); }
.pips i[data-s="dropped"] { background: repeating-linear-gradient(135deg, var(--text-faint) 0 1.5px, transparent 1.5px 3.5px); }
/* not in v6, which always knew: a task the facts here cannot place is a dotted outline, never drawn as idle (D44) */
.pips i[data-s="unknown"] { background: transparent; outline: 1.5px dotted var(--text-faint); outline-offset: -1.5px; }
.cnt { display: inline-flex; align-items: center; justify-content: center; min-width: 1.6em; height: 1.6em; padding: 0 .45em;
  border-radius: 999px; font-size: var(--text-xs); font-variant-numeric: tabular-nums; color: var(--tone, var(--text-dim));
  background: color-mix(in srgb, var(--tone, var(--text-faint)) 16%, transparent); }

/* every section heading folds in place and keeps its count; there is no bucket screen */
.shellpage .foldhead { display: flex; align-items: center; gap: var(--space-2); width: 100%; margin: 0 0 var(--space-1); padding: var(--space-2);
  border: 0; border-radius: var(--radius-control); background: transparent; color: var(--text-faint); font: inherit; font-size: var(--text-xs);
  font-weight: var(--weight-strong); letter-spacing: var(--tracking-label); text-transform: uppercase; text-align: start; cursor: pointer; }
.shellpage .foldhead:hover { background: var(--hover); color: var(--text-dim); }
.shellpage .foldhead .fold__chevron { display: inline-grid; transition: transform var(--motion-fast); }
.shellpage .foldhead .fold__chevron .icon { width: var(--text-sm); height: var(--text-sm); }
.shellpage .foldhead[aria-expanded="true"] .fold__chevron { transform: rotate(90deg); }
.shellpage .foldhead .hint { margin-inline-start: auto; font-weight: var(--weight-regular); letter-spacing: 0; text-transform: none; }
.shellpage .tray { margin-block-start: var(--space-4); padding-block-start: var(--space-2); border-top: var(--line-width) solid var(--line); }
.shellpage .tray__search { position: relative; margin: var(--space-1) var(--space-2) var(--space-3); }
.shellpage .tray__search .icon { position: absolute; left: var(--space-2); top: 50%; transform: translateY(-50%); color: var(--text-faint); pointer-events: none; }
.shellpage .tray__search .field { padding-inline-start: calc(var(--space-2) * 2 + var(--text-md)); }
.shellpage .tray__none { margin: 0 var(--space-2); font-size: var(--text-sm); color: var(--text-faint); }
.shellpage .tray__none[hidden] { display: none; }
.shellpage .row:focus-visible, .shellpage .foldhead:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -1px; }


/* ---- the rail: For you, Commissions and Work (PAGE 5.5), as the approved Work mockup draws a row -------
   Ported from .git/mechane-ci/work-mockup/styles.css, block 7 ("NEW"): tokens only. */
.lrail__sections { padding-top: var(--space-2); }
.lrail__sections > .rail { position: relative; gap: 1px; }
.lrail .rail-item { min-height: var(--height-control); font-weight: var(--weight-medium); touch-action: none; }
.lrail .rail-item .icon { color: var(--text-dim); }
.lrail .rail-item[aria-current="page"] { background: var(--selected); }
.lrail .rail-item[aria-current="page"] .icon { color: var(--text); }
.lrail .rail-item .rail-item__meta { display: inline-flex; }
.lrail .rail-item[data-lifted], .lrail .rail-folder[data-lifted] { position: relative; z-index: 5; transform: translateY(var(--lift, 0px)) scale(1.02); background: var(--surface-raised);
  box-shadow: 0 6px 18px rgb(0 0 0 / 0.14); border-radius: var(--radius-control); }
/* Work is a folder (PAGE 5.32), as rail mockup B draws it (commission 54G34Y, packages/shell/src/rail-mock.ts at cb87b186,
   .rm-folder and .rm-sub), tokens only. Its arrow, which folds it and changes nothing else (PAGE 5.6), is at the row's end
   where the mockup draws its chevron, pointing down while Work is open: a button of its own beside Work's, never over it,
   and the two read as one row, marked as one while the pane is on Work's screen with Work folded. */
.rail-folder { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: stretch; border-radius: var(--radius-control); }
.rail-folder:has(> .rail-item[aria-current="page"]) { background: var(--selected); }
.lrail .rail-folder > .rail-item[aria-current="page"] { background: transparent; }
.rail-fold { display: inline-grid; place-items: center; width: var(--height-control); padding: 0;
  border: 0; border-radius: var(--radius-control); background: transparent; color: var(--text-faint); cursor: pointer; touch-action: manipulation; }
.rail-fold:hover { background: var(--hover); color: var(--text); }
.rail-fold:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -2px; }
.rail-fold .icon { width: var(--text-md); height: var(--text-md); transition: transform var(--motion-fast); }
.rail-fold[aria-expanded="true"] .icon { transform: rotate(90deg); }
/* Its rows: the map, Claims, Law, Backlog, Ideas and Bugs, each a row of its own, set in under Work, each with its number. */
.rail-rows { display: grid; gap: 1px; margin: 1px 0 var(--space-2); }
.lrail .rail-row { padding-inline-start: calc(var(--space-2) + var(--space-3)); min-height: var(--height-control-small); font-size: var(--text-sm);
  font-weight: var(--weight-regular); touch-action: manipulation; }
.lrail .rail-row .icon { width: var(--text-sm); height: var(--text-sm); }
.rail-row__n { font-size: var(--text-xs); color: var(--text-faint); font-variant-numeric: tabular-nums; }
@media (prefers-reduced-motion: reduce) { .rail-fold .icon { transition: none; } }
/* Commissions' states under it (PAGE 5.31): a dot in the state's tone, its name, and how many — rail mockup B's
   .rm-state (commission 54G34Y, packages/shell/src/rail-mock.ts at cb87b186), tokens only. Stuck reads loudest and Done
   quietest; a name too long for the rail wraps rather than being cut ("Waiting on somebody else" takes two lines at 232px). */
.rail-states { display: grid; gap: 1px; margin: 1px 0 var(--space-2); }
.rail-state { display: grid; grid-template-columns: var(--text-md) minmax(0, 1fr) auto; align-items: center; gap: var(--space-2); width: 100%;
  min-height: var(--height-control-small); padding: 0 var(--space-2) 0 calc(var(--space-2) + var(--space-3)); border: 0; border-radius: var(--radius-control);
  background: transparent; color: var(--text-dim); font: inherit; font-size: var(--text-sm); text-align: left; cursor: pointer; touch-action: manipulation; }
.rail-state:hover { background: var(--hover); color: var(--text); }
.rail-state:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -2px; }
.rail-state[data-tone="alarm"] { color: var(--text); font-weight: var(--weight-medium); }
.rail-state[data-tone="quiet"] { color: var(--text-faint); }
.rail-state__name { overflow-wrap: anywhere; }
.rail-state__n { font-variant-numeric: tabular-nums; color: var(--text-faint); font-size: var(--text-xs); }
.rail-state__dot { justify-self: center; width: 8px; height: 8px; border-radius: 50%; background: var(--tone, var(--text-faint)); }

/* ---- the frame's own pages: For you, the backlog, and the Claims screen's choice of grouping ----------------
   The Commissions pane's column (COMMISSIONS_PANE_STYLES' .colwrap and .col) and its head (.phead .ptitle .pmeta), as the
   approved Work mockup ports them, scoped to .shellpage. */
/* An empty screen's how to start it (PAGE 5.2), on For you and on the Claims screen beside the frame; the board draws the
   same sheet in its own shadow root. */

.empty-how { display: grid; gap: var(--space-1); margin: var(--space-4) 0; padding: var(--space-4); border: var(--line-width) dashed var(--line-strong); border-radius: var(--radius-card); max-width: 620px; color: var(--text); }
.empty-how p { margin: 0; }
.empty-how__lead { font-weight: var(--weight-medium); }
.empty-how__body { display: grid; gap: var(--space-3); color: var(--text-dim); min-width: 0; }
.empty-how .empty-how__go { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); margin-top: var(--space-2); }
.empty-how__setup { display: inline-flex; align-items: center; min-height: var(--height-control); padding: 0 var(--space-3); border: var(--line-width) solid var(--text); border-radius: var(--radius-control); background: var(--text); color: var(--surface); font: inherit; font-size: var(--text-sm); cursor: pointer; }
.empty-how__setup:hover { opacity: .88; }
.empty-how__word { border: 0; padding: 0; background: none; color: var(--text); font: inherit; font-size: var(--text-sm); text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: 3px; cursor: pointer; min-height: 0; }
.empty-how__word:hover { text-decoration-color: currentColor; }

.shellpage { --gutter: var(--space-7); padding: var(--space-6) var(--gutter) var(--space-8); }
/* The Claims screen's choice of grouping (PAGE 5.32), over the screen: a line of the screen's, not a page of its own. */
.claimsgrouping.shellpage { padding-bottom: 0; }
.claimsgrouping[hidden] { display: none; }
@container pane (max-width: 640px) { .shellpage { --gutter: 16px; padding-top: var(--space-4); } }
.shellpage__col { --measure: calc(var(--text-lg) * 42);
  max-width: calc(var(--measure) + 3em + var(--space-3) + 2 * var(--space-5) + var(--edge-width) + var(--line-width));
  margin-inline: auto; min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-5); align-content: start; }
.shellpage .phead { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-2); }
.shellpage .ptitle { margin: 0; font-family: var(--font-reading); font-size: var(--text-2xl); line-height: var(--leading-2xl); font-weight: var(--weight-strong); text-wrap: balance; overflow-wrap: anywhere; }
.shellpage .ptitle:focus { outline: none; }
.shellpage .pmeta { margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2) var(--space-3); font-size: var(--text-sm); color: var(--text-dim); }
.shellpage .note { margin: 0; font-size: var(--text-sm); line-height: var(--leading-sm); color: var(--text-dim); }
.shellpage .acount { font-size: var(--text-sm); color: var(--text-faint); white-space: nowrap; font-variant-numeric: tabular-nums; font-weight: var(--weight-regular); }
.claimsgrouping__pick { display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-sm); color: var(--text-dim); }
.claimsgrouping__pick .field { min-width: 0; max-width: 100%; }
@media (pointer: coarse), (max-width: 700px) { .claimsgrouping__pick .field { min-height: var(--height-tap); } }
/* For you: what you were told since you were last here, then what waits on you. */
.shellpage .box { display: grid; gap: var(--space-2); padding: var(--space-3) var(--space-4); border: var(--line-width) solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.fy-since__title, .fy-wait__title, .bl-group__title { margin: 0; font-size: var(--text-md); line-height: var(--leading-md); font-weight: var(--weight-strong); }
.fy-since__list { margin: 0; padding: 0; list-style: none; display: grid; gap: var(--space-2); }
.fy-since__item { display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-1) var(--space-3); font-size: var(--text-sm); line-height: var(--leading-sm); }
.fy-since__when { color: var(--text-faint); white-space: nowrap; }
/* An assignment's note: its own row under the line's words, quieter than they are. */
.fy-since__note { flex-basis: 100%; color: var(--text-dim); }
/* **A line of "Since you were last here" opens what it is about** (bug 0H1SBD): the words read as the line, and the press is the whole of it. */
.fy-since__line { all: unset; box-sizing: border-box; display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-1) var(--space-3); width: 100%; min-height: var(--height-tap); align-items: center; }
button.fy-since__line { cursor: pointer; }
button.fy-since__line:hover .fy-since__what { text-decoration: underline; }
button.fy-since__line:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: 2px; border-radius: var(--radius-card); }
.shellpage section { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--space-2); }
.fy-wait__title, .bl-group__title { display: flex; align-items: baseline; justify-content: space-between; gap: var(--space-3); }
.fy-wait__n { color: var(--vet-wrong); font-variant-numeric: tabular-nums; }
.fy-lines { display: grid; gap: var(--space-1); }
.fy-lines > .row { border: var(--line-width) solid var(--line); background: var(--surface); }

.row:focus-visible, .cd:focus-visible, .crumbs button:focus-visible, .chev:focus-visible, .foldhead:focus-visible, .acc__chev:focus-visible, .acc__name:focus-visible,
.mini__line:focus-visible, .scr:focus-visible, .user:focus-visible, .toggle:focus-visible, .rail-item:focus-visible, .shelf:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -1px; }
.foldsum { margin: 0 var(--space-2) var(--space-2); font-size: var(--text-sm); color: var(--text-dim); }

/* ---- THE RAIL'S FOOT: compact cards, the screen icons, and the user row — never more than a third ---- */
.foot { flex: 0 0 auto; max-height: 34%; min-height: 0; display: flex; flex-direction: column; border-top: var(--line-width) solid var(--line); }
.foot__screens { flex: none; display: flex; align-items: stretch; gap: var(--space-1); padding: var(--space-2); }

.scrgrp { display: flex; gap: var(--space-1); min-width: 0; flex: var(--n, 1) 1 0; }
.scr { flex: 1 1 0; min-width: 0; display: inline-grid; justify-items: center; gap: 2px; padding: var(--space-1) 2px 3px;
  border: 0; border-radius: var(--radius-control); background: transparent; color: var(--text-dim); font: inherit; font-size: var(--text-xs);
  line-height: 1.2; cursor: pointer; }
.scr .icon { width: var(--text-lg); height: var(--text-lg); }
.scr span { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.scr:hover { background: var(--hover); color: var(--text); }
.scr:active { background: var(--selected); }
.scr[aria-current="page"] { background: var(--selected); color: var(--text); font-weight: var(--weight-medium); }
.scr__rule { flex: none; width: var(--line-width); margin-block: var(--space-2); background: var(--line-strong); }
/* Actions sits in the row as an icon like the screens, but it opens a popover rather than the pane */
.scr[data-actions] { position: relative; }
.scr[data-actions][aria-expanded="true"] { background: var(--selected); color: var(--text); }
.scr[data-new]::after { content: ""; position: absolute; top: 3px; right: calc(50% - var(--text-lg) / 2 - 5px); width: 7px; height: 7px; border-radius: 50%;
  background: var(--doesnt); box-shadow: 0 0 0 2px var(--surface); }

/* The user row is in the header's right end now, so it is as wide as the name needs and no wider. */
.user { flex: 0 1 auto; min-width: 0; display: flex; align-items: center; gap: var(--space-2); min-height: calc(var(--size) * 2.25); padding: var(--space-1);
  border: 0; border-radius: var(--radius-control); background: transparent; color: var(--text); font: inherit; text-align: start; cursor: pointer; }
.user:hover, .user[aria-expanded="true"] { background: var(--hover); }
.av { flex: none; display: inline-grid; place-items: center; width: calc(var(--size) * 1.75); height: calc(var(--size) * 1.75); border-radius: 50%;
  background: var(--text); color: var(--ground); font-size: var(--text-xs); font-weight: var(--weight-strong); }
.av[data-local] { background: var(--selected); color: var(--text-dim); box-shadow: inset 0 0 0 1px var(--line-strong); }
.av[data-small] { width: calc(var(--size) * 1.35); height: calc(var(--size) * 1.35); font-size: calc(var(--size) * 0.6); }
.user__txt { min-width: 0; display: grid; line-height: 1.25; }
.user__name { font-weight: var(--weight-medium); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user__sub { font-size: var(--text-xs); color: var(--text-faint); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* the user row is the one button for you: it opens your menu, and Settings… is the first thing in it */
.user__more { flex: none; display: inline-grid; margin-inline: auto var(--space-1); color: var(--text-faint); }
.user:hover .user__more, .user[aria-expanded="true"] .user__more { color: var(--text-dim); }
/* It drops DOWN from the header, where it rose from the foot, and hangs off the right edge the row is against. */
.usermenu { position: absolute; z-index: 45; inset-inline-end: 0; top: calc(100% + var(--space-1)); min-width: 17rem; max-width: min(24rem, 90vw); }
/* **Everything in it fits the menu and wraps there**, never runs past its edge: the page's own controls in it hold
   "Download everything in this project", a button that will not wrap, and it made the menu's one column 335.5px at every
   phone width while the menu was 286 to 334px — so its head, its rules and Settings, its first item, ran past the side
   of a menu that scrolled sideways (site/test/every-screen-phone-browser.test.ts, once Settings moved into it). */
.usermenu { grid-template-columns: minmax(0, 1fr); }
.usermenu__account .info-lead .button { height: auto; min-height: var(--height-control-small); padding-block: var(--space-1); line-height: var(--leading-sm); white-space: normal; text-align: start; }
/* Settings is a press a thumb makes on a phone (PAGE 5.5: it is the account menu's first item), so it is a thumb's height there. */
@media (pointer: coarse), (max-width: 700px) { .usermenu .menu__item { min-height: var(--height-tap); } }
.menu__subs { font-size: var(--text-xs); line-height: var(--leading-xs); color: var(--text-faint); }
.usermenu__note { padding: var(--space-1) var(--space-3) var(--space-2); font-size: var(--text-sm); line-height: var(--leading-sm); color: var(--text-dim); }

.menu__item:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -2px; }

/* ---- THE PANE: one centred column, whatever it is showing ------------------------------------------- */
/* **It scrolls up and down and NEVER sideways, and 'overflow-x' says so** (bug 6F0FGX). A box that scrolls on one axis
   computes 'auto' on the other, so with 'overflow-y' alone the pane was a sideways scroller by accident: content wider
   than it by however little let Zack's thumb drag the whole pane sideways while the bars above and below stayed put —
   his picture of a commission's page, on Chrome on iOS, is exactly that. Anything genuinely too wide is still
   the phone check's 'cut' (packages/rulings/test-support/phone.ts), which reads this box as the clipper it always was;
   site/test/no-sideways-phone-browser.test.ts drags it. The same holds for every surface a thumb drags: '.setwin__main'
   below, and '#alarm' in the site page. */
.panecol { flex: 1 1 auto; min-width: 0; min-height: 0; display: flex; flex-direction: column; overflow-y: auto; overflow-x: hidden; container: pane / inline-size;
  background: var(--surface-raised); }
/* ☰ (PAGE 5.33): the header's first thing at every width, a control's size at a desk and a thumb's on a touch screen or
   a phone, so it is one size either side of the width where the rail becomes a drawer (PAGE 5.14). */
.appbar__menu { display: inline-grid; place-items: center; position: relative; flex: none; min-width: var(--height-control); min-height: var(--height-control); margin-inline-end: calc(var(--space-1) * -1); }
@media (pointer: coarse), (max-width: 700px) { .appbar__menu { min-width: var(--height-tap); min-height: var(--height-tap); } }
/* For you's count on ☰ while the drawer it opens is closed (claim BQA73Q): the folded rail's pill, on ☰'s corner, moving nothing. */
.appbar__waits { position: absolute; top: 2px; right: 2px; margin: 0; min-width: 15px; height: 15px; padding: 0 4px; font-size: 10px; line-height: 15px; pointer-events: none; }

/* ---- Actions: a popover from its icon, not a screen ------------------------------------------------ */
.actpop { position: fixed; z-index: 45; display: flex; flex-direction: column; width: min(calc(var(--size) * 28), calc(100vw - 32px)); max-height: min(72vh, 640px);
  border: var(--line-width) solid var(--line-strong); border-radius: var(--radius-card); background: var(--surface-raised); box-shadow: var(--shadow-popover); }
.actpop__head { flex: none; display: flex; align-items: center; gap: var(--space-2); padding: var(--space-2) var(--space-2) var(--space-2) var(--space-4); border-bottom: var(--line-width) solid var(--line); }
.actpop__head h2 { font-size: var(--text-md); font-weight: var(--weight-strong); }
.actpop__head .icon-button { margin-inline-start: auto; }
.actpop__intro { flex: none; display: grid; gap: var(--space-1); padding: var(--space-3) var(--space-4) 0; }
.actpop__list { flex: 1 1 auto; min-height: 0; overflow-y: auto; display: grid; gap: var(--space-3); align-content: start; padding: var(--space-3) var(--space-4) var(--space-4); }
.actpop__problem { margin: 0; padding: var(--space-2) var(--space-3); border: var(--line-width) solid color-mix(in srgb, var(--doesnt) 45%, var(--line));
  border-radius: var(--radius-control); background: color-mix(in srgb, var(--doesnt) 6%, var(--surface)); font-size: var(--text-sm); line-height: var(--leading-sm); color: var(--text); }
.act { display: grid; gap: var(--space-2); padding: var(--space-3); border: var(--line-width) solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.act[data-refused] { border-color: color-mix(in srgb, var(--doesnt) 45%, var(--line)); background: color-mix(in srgb, var(--doesnt) 6%, var(--surface)); }
.act__top { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-2); }
.act__what { font-weight: var(--weight-strong); }
.act__when { margin-inline-start: auto; font-size: var(--text-sm); color: var(--text-faint); font-variant-numeric: tabular-nums; white-space: nowrap; }
.act__where { font-size: var(--text-sm); color: var(--text-dim); }
.reply { margin: 0; padding: var(--space-2) var(--space-3); border-radius: var(--radius-control); background: var(--ground); border: var(--line-width) solid var(--line);
  font-family: var(--font-mono); font-size: var(--text-sm); line-height: var(--leading-sm); white-space: pre-wrap; overflow-wrap: anywhere; color: var(--text); }
.act__foot { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2); }

/* ---- A small modal: the Commissions screen's dialogs, and the options and switches Settings draws ------------- */
.scrim2 { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 16px; background: rgb(15 16 20 / 0.24); }
.modal { width: min(calc(var(--size) * 27), 100%); max-height: calc(100dvh - 32px); overflow-y: auto; display: grid; gap: var(--space-4);
  padding: var(--space-3) var(--space-5) var(--space-5); border: var(--line-width) solid var(--line-strong); border-radius: calc(var(--radius-card) + 2px);
  background: var(--surface-raised); box-shadow: var(--shadow-popover); }
.modal__head { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 2px var(--space-2); }
.modal__head h2 { font-size: var(--text-lg); font-weight: var(--weight-strong); }
.modal__whose { grid-column: 1; display: flex; align-items: center; gap: var(--space-2); font-size: var(--text-sm); color: var(--text-dim); }
.modal__head .icon-button { grid-column: 2; grid-row: 1 / span 2; align-self: start; }
.modal fieldset { margin: 0; padding: 0; border: 0; display: grid; gap: var(--space-2); min-width: 0; }
.modal legend { padding: 0; margin-bottom: var(--space-2); font-weight: var(--weight-medium); }
.opts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-1); }
.opts[data-n="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.opt { position: relative; display: grid; justify-items: center; align-content: start; gap: var(--space-1); padding: var(--space-2) var(--space-1);
  border: var(--line-width) solid var(--line); border-radius: var(--radius-control); background: var(--surface); color: var(--text-dim);
  font-size: var(--text-xs); line-height: 1.25; text-align: center; cursor: pointer; }
.opt:hover { background: var(--hover); }
.opt:has(input:checked) { background: var(--selected); color: var(--text); border-color: var(--line-strong); box-shadow: inset 0 0 0 var(--line-width) var(--line-strong); }
.opt:has(input:focus-visible) { outline: var(--focus-width) solid var(--focus); outline-offset: var(--focus-offset); }
.opt input { position: absolute; top: 0; left: 0; width: 1px; height: 1px; margin: 0; opacity: 0; pointer-events: none; }
.opt b { font-family: var(--font-reading); color: var(--text); line-height: 1; font-weight: var(--weight-medium); }
.opt > b.w { font-family: var(--font-sans); font-size: var(--text-sm); }
.measure { position: relative; display: block; width: 100%; height: 22px; }
.measure i { position: absolute; top: 2px; bottom: 2px; left: 50%; width: var(--w); transform: translateX(-50%); border-radius: 2px;
  background: repeating-linear-gradient(to bottom, var(--text-faint) 0 2px, transparent 2px 5px); }
.modal__note { font-size: var(--text-sm); line-height: var(--leading-sm); color: var(--text-dim); }
/* Settings: a large window over the screen you are on, its sections listed down its left side and the chosen one
   beside them, scrolling on its own (task 8S9J38; Zack, 2026-11-03: "fairly large, think Claude Code desktop app").
   Every control in it is the system's own — .opts, .sub, .toggle, .button, .field — and nothing about how one looks
   is new: what is here is the window, its list, and that no control is wider than what it belongs to.
   It was a page in the pane for a day, and drew unstyled there: its element carried .pane__slot, which the page's own
   sheet makes display: contents, so the box these rules gave it — its padding, its measure, its gaps — was never drawn. */
.setwin__scrim { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: var(--space-5);
  background: rgb(15 16 20 / 0.45); }
.setwin__scrim[hidden] { display: none; }
.setwin { position: relative; width: min(1280px, 90vw); height: min(880px, 88dvh); display: grid; grid-template-columns: 232px minmax(0, 1fr);
  overflow: hidden; border: var(--line-width) solid var(--line-strong); border-radius: calc(var(--radius-card) + 6px);
  background: var(--surface-raised); box-shadow: var(--shadow-popover); }
.setwin[hidden] { display: none; }
.setwin__side { display: flex; flex-direction: column; gap: var(--space-5); min-height: 0; overflow-y: auto; padding: var(--space-5) var(--space-3);
  border-right: var(--line-width) solid var(--line); background: var(--surface); }
.setwin__h1 { margin: 0; padding-inline: var(--space-2); font-family: var(--font-reading); font-size: var(--text-xl); line-height: var(--leading-xl);
  font-weight: var(--weight-strong); }
.setwin__h1:focus { outline: none; }
.setwin__nav { display: grid; gap: var(--space-5); }
.setwin__group { display: grid; gap: 2px; }
.setwin__group[hidden], .setwin__tab[hidden], .setwin__panes[hidden], .setwin__pane[hidden] { display: none; }
.setwin__glabel { margin: 0 0 var(--space-1); padding-inline: var(--space-2); font-size: var(--text-xs); line-height: var(--leading-xs);
  font-weight: var(--weight-medium); letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-faint); }
.setwin__tab { display: flex; align-items: center; width: 100%; min-height: var(--height-control); padding: 0 var(--space-2); border: 0;
  border-radius: var(--radius-control); background: transparent; color: var(--text-dim); font: inherit; font-size: var(--text-sm); text-align: start; cursor: pointer; }
.setwin__tab:hover { background: var(--hover); color: var(--text); }
.setwin__tab[aria-current="true"] { background: var(--selected); color: var(--text); font-weight: var(--weight-medium); }
.setwin__tab:focus-visible { outline: var(--focus-width) solid var(--focus); outline-offset: -2px; }
.setwin__whose { margin-top: auto; padding-inline: var(--space-2); display: flex; align-items: flex-start; gap: var(--space-2);
  font-size: var(--text-xs); line-height: var(--leading-xs); color: var(--text-dim); }
.setwin__whose > .av { flex: none; }
.setwin__main { min-width: 0; min-height: 0; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; }
.setwin__close { position: absolute; top: var(--space-3); right: var(--space-3); z-index: 1; }
.setwin__pane { display: grid; gap: var(--space-5); align-content: start; max-width: 46rem; padding: var(--space-6) var(--space-7) var(--space-7); }
.setwin__head { padding-bottom: var(--space-3); border-bottom: var(--line-width) solid var(--line); }
.setwin__h2 { margin: 0; min-width: 0; font-family: var(--font-reading);
  font-size: var(--text-xl); line-height: var(--leading-xl); font-weight: var(--weight-strong); }
.setwin__body { display: grid; gap: var(--space-5); align-content: start; }
.setwin fieldset { margin: 0; padding: 0; border: 0; display: grid; gap: var(--space-2); min-width: 0; }
.setwin legend { padding: 0; margin-bottom: var(--space-2); font-size: var(--text-md); font-weight: var(--weight-medium); color: var(--text); }
/* A legend holding a name and the info mark beside it is a row the width of its words (PAGE 5.21). */
.setwin legend.info-lead { width: max-content; max-width: 100%; }
/* A choice is as wide as its words, and the row of them no wider than its choices. */
.setwin .opts { grid-template-columns: repeat(4, 6.5rem); justify-content: start; }
.setwin .opts[data-n="3"] { grid-template-columns: repeat(3, 9.5rem); }
.setwin .subs { max-width: 40rem; }
/* Answering (WAITING 1.8, CLAIMS 2.12): a choice another switch holds, and the bar to somebody who does not run the
   project, cannot be pressed, and every choice of it but the one it is on is greyed, as the design's Custom picture draws
   a held switch. What LAW 1.23 names is three switches that are on and cannot move. */
.setwin .opt:has(input:disabled) { cursor: default; }
.setwin .opt:has(input:disabled:not(:checked)) { opacity: 0.4; }
.answering__about, .answering__fixed, .answering__bar { display: grid; gap: var(--space-2); align-content: start; }
.answering__fixed .toggle[aria-disabled="true"] { opacity: 0.55; cursor: default; }
/* The three that cannot move carry no glyph, so their rows have no glyph column: each name starts where its section's
   label and the why under it start, rather than after an empty space (task HMP89G). */
.answering__fixed .sub { grid-template-columns: minmax(0, 1fr) auto; padding-inline: 0; }
.answering__fixed .sub__head { grid-column: 1; }
.answering__fixed .toggle { grid-column: 2; }
/* The dial's four names each on one line (task HMP89G): a column is never narrower than its name, which keeps its words
   together, so Decisions only does not break where Every step, The result and Custom do not. */
.setwin [data-answering-dial] .opt > b.w { white-space: nowrap; }
.setwin [data-answering-dial] .opts { grid-template-columns: repeat(4, minmax(min-content, 6.5rem)); }
/* The pane of a person subscribed to no screens (v6's "No screens") */
.pane__none { padding: var(--space-6) var(--space-5); max-width: 42em; }
.pane__none h1 { margin: 0 0 var(--space-3); font-family: var(--font-reading); font-size: var(--text-2xl); line-height: var(--leading-2xl); font-weight: var(--weight-strong); }
.pane__none p { color: var(--text-dim); line-height: var(--leading-md); }
/* Your screens: the repo's packages, and whether this person is subscribed to each (v6) */
.subs { display: grid; border: var(--line-width) solid var(--line); border-radius: var(--radius-card); background: var(--surface); }
.sub { display: grid; grid-template-columns: var(--text-md) minmax(0, 1fr) auto; gap: 2px var(--space-3); align-items: center; padding: var(--space-2) var(--space-3);
  border-top: var(--line-width) solid var(--line); }
.sub:first-child { border-top: 0; }
.sub > .icon { color: var(--text-dim); }
.sub__name { font-weight: var(--weight-medium); }
/* The screen's name and the info mark saying what it is for (PAGE 5.21), in the name's column. */
.sub__head { grid-column: 2; }
.toggle { grid-column: 3; grid-row: 1; position: relative; flex: none; width: calc(var(--size) * 2.25); height: calc(var(--size) * 1.3); padding: 0;
  border: var(--line-width) solid var(--line-strong); border-radius: 999px; background: var(--hover); cursor: pointer; transition: background-color var(--motion-fast), border-color var(--motion-fast); }
.toggle::after { content: ""; position: absolute; top: 2px; left: 2px; width: calc(var(--size) * 1.3 - 6px); height: calc(var(--size) * 1.3 - 6px); border-radius: 50%;
  background: var(--surface-raised); box-shadow: 0 0 0 var(--line-width) var(--line-strong); transition: transform var(--motion-fast); }
.toggle[aria-checked="true"] { background: var(--text); border-color: var(--text); }
.toggle[aria-checked="true"]::after { transform: translateX(calc(var(--size) * 0.95)); box-shadow: none; }

.toast { position: fixed; left: 50%; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%); z-index: 60;
  width: max-content; max-width: calc(100% - 32px); padding: var(--space-2) var(--space-4); border-radius: var(--radius-control);
  background: var(--text); color: var(--ground); font-size: var(--text-sm); line-height: var(--leading-sm); box-shadow: var(--shadow-popover); }
.drawerscrim { display: none; }
/* A press that cannot be taken back reads as one (the mockup draws it on its editor card; it is the design system's). */
.button[data-kind="danger"] { color: var(--doesnt); border-color: color-mix(in srgb, var(--doesnt) 55%, var(--line-strong)); }

/* ---- THE RAIL'S DRAWER, below the rail's own width (PAGE 5.14, PAGE 5.33) ----------------------------------
   On a phone and an iPad held upright the rail is a drawer behind ☰, opening UNDER the header over a dimmed page, so ☰
   stays where it was and the header still works; the pane has the screen. '--rail-drawer-top' is the header's foot, which
   the frame measures as the drawer opens (`placeDrawer` in @mechaneion/shell). A finger moving it puts it where the
   finger is ('data-drawer-drag' and an inline transform, `drawerSwipe`), the page dimming as it comes.
   **Nothing outside the rail lays out differently at this width** (PAGE 5.14): only the rail, its handle and the dimmed
   page beside it are in this block, which rail-drawer-browser.test.ts holds by reading every other box either side. */
@media (max-width: 1100px) {
  .handle { display: none !important; }
  .lrail, .app[data-rail="folded"] .lrail { position: fixed; inset-block: var(--rail-drawer-top, 0px) 0; inset-inline-start: 0; z-index: 40; display: flex;
    width: min(86vw, 340px); height: auto; border-inline-end: var(--line-width) solid var(--line-strong); box-shadow: var(--shadow-popover);
    transform: translateX(-104%); visibility: hidden; transition: transform 180ms ease, visibility 0s linear 180ms; }
  .app[data-drawer="open"] .lrail { transform: none; visibility: visible; transition: transform 180ms ease; }
  .app[data-drawer="open"] .drawerscrim, .app[data-drawer-drag] .drawerscrim { display: block; position: fixed; inset: var(--rail-drawer-top, 0px) 0 0; z-index: 39; background: rgb(15 16 20 / 0.32); }
  .app[data-drawer-drag] .lrail { visibility: visible; transition: none; }
  .app[data-drawer-drag] .drawerscrim { opacity: var(--drawer-drag, 0); }
  /* Every row in the drawer is a thumb's target: For you, Commissions and Work, Commissions' states, Work's rows and its arrow. */
  .lrail .rail-item, .rail-state, .lrail .rail-row { min-height: var(--height-tap); }
  .rail-fold { width: var(--height-tap); }
}
@media (prefers-reduced-motion: reduce) { .lrail, .app[data-drawer="open"] .lrail { transition: none !important; } }

/* ---- phone: one header row, and the document scrolls ------------------------------------------------------
   Zack approved the mobile boards on 2026-10-05: the header collapses to one 44px row and nothing is cut off at 320px.
   The rail is the drawer above, behind ☰, which replaced the bar of tabs along the foot (PAGE 5.33).

   **Every control in this block sits on '--height-tap', which is 44px and a floor.** That is the claim: *every
   control can be pressed with a thumb*. The desktop sizes ('--height-control', '--height-control-small') are
   pointer sizes and stay what they are above 700px; this block is the only place they are raised, so a press target
   and a pointer target are one declaration each and cannot come apart. */
@media (max-width: 700px) {
  /* The header is ONE 44px row: ☰, the mark, the project, the account. The padding goes rather than the row growing, so
     the bar is 44px tall and the two controls in it are 44px targets filling it. */
  .appbar { gap: var(--space-2); min-height: var(--height-tap); padding: 0 var(--space-2); }
  /* THE WORDMARK GOES AND THE MARK NEVER DOES (EE19TS; Zack, 2026-10-03: the mark shows wherever you are in
     Mechaneion). Hiding the word is what buys the project its room on a 320px screen. */
  .appbar .brand__name { display: none; }
  .appbar .proj, .appbar .user { min-height: var(--height-tap); }
  /* The avatar keeps the size the design drew it; the button around it is the 44px target. */
  .appbar .user { padding-block: 0; }
  /* **On a phone the header names the project and the person, whole, and nothing else of theirs** (bug CXWH08: Zack's
     iPhone cut the project to "Me…" and him to "Zack / Signe…"). How he is signed in, and the menu's arrow, give their
     width to the project: the menu itself still says how he is signed in, and the whole button still opens it. */
  .appbar .user__sub, .appbar .user__more { display: none; }
  /* And when the two cannot both fit, the project gives way and never the person: a name is short, and "Y…" is nobody. */
  .appbar .user { flex-shrink: 0; }

  /*
    **ON A PHONE THE DOCUMENT SCROLLS, NOT THE PANE, so the browser's own bars tuck away** (task SE6G7J). Zack, on
    Chrome on iOS: *"between that and the header and footer we have you just can't really see much of anything"*.
    A phone's browser folds its own toolbars away only when the DOCUMENT scrolls, and the pane scrolling inside a
    frame that fitted the window meant the browser never saw anything scroll, so its bar stayed for good under ours.

    So here the app, the row under the header and the pane are as tall as what is in them, and the page scrolls. Each
    of them still clips sideways (**'overflow-x: clip'**, and the app 'overflow: clip'), which is what keeps the app's promise that nothing scrolls sideways
    (bug 6F0FGX) and that code can scroll none of them (task K91AMG): 'clip' is no scroller, so it neither takes a thumb
    nor a 'scrollIntoView', and beside a 'visible' axis it stays 'clip' (beside 'auto' it would compute to 'hidden').
    A browser without 'clip' drops the line and keeps 'visible', which still scrolls the page and is all it loses.
    'clip' is also what leaves the sticky header and every sticky head inside a screen pinned to the WINDOW: none of
    these boxes is a scroller any more.

    **And the header gives the page its room while he scrolls down** (`data-bars="away"`, set by the frame as he
    scrolls, @mechaneion/shell's `slidingBars`), and comes back when he scrolls up, at the top, when the keyboard
    reaches it, and while the rail's drawer or Settings is open. Sticky rather than fixed, so at the top of the page it
    sits in its own place and covers nothing. Its room is published as `--mechaneion-frame-top` on the document,
    which the page's scroll padding and every sticky head in a screen read, so nothing pins itself under the header or
    scrolls into view behind it.
  */
  .appmain, .panecol { overflow: visible; overflow-x: clip; }
  /* **The app clips on both axes**, so nothing slid off the window's edge can lengthen the page: a transform counts
     toward what a page scrolls. The page still scrolls, as 'clip' is no scroller. */
  .app { overflow: visible; overflow: clip; }
  .appbar { position: sticky; top: 0; z-index: 38; transition: transform 180ms ease; }
  .app[data-bars="away"] .appbar { transform: translateY(-100%); }
  /* Reduced motion: shown or hidden, never slid. */
  @media (prefers-reduced-motion: reduce) { .appbar { transition: none; } }
  /* **The header's inbox goes on a phone** (task SE6G7J): For you, on the rail in the drawer behind ☰, carries what
     waits on him, and the two badges counting differently (the tray what he was told and has not opened, For you what waits on him)
     read as one count that disagreed with itself. Above a phone the rail's For you and this button are both there. */
  .appbar .traybtn { display: none; }

  .actpop { left: 16px !important; right: 16px; top: auto !important; bottom: 16px !important; width: auto; }
  /* Every remaining control in the frame, on the one floor. ☰ (its own rule, beside it above), the chevron beside each
     section name, the name itself, Law's shelf and the foot's screen icons were 26 to 38px tall — each of them drawn,
     each of them a miss waiting to happen. The glyphs inside them keep the size the design drew; only the boxes grow.
     The rail's own rows are on the floor wherever the rail is a drawer (above). */
  .acc__head { padding-block: var(--space-0); }
  .acc__chev { width: var(--height-tap); height: var(--height-tap); }
  .acc__name { min-height: var(--height-tap); }
  .acc__pick { padding-inline-start: calc(var(--space-2) + var(--height-tap) + var(--space-1)); }
  .shelf { min-height: var(--height-tap); }
  .scr { min-height: var(--height-tap); padding-block: var(--space-1); }
  /* A tier head is a row a thumb picks a slice or a book with, so it is a target too. */
  .acc .rail-item { min-height: var(--height-tap); }
  /* A phone's Settings is the whole screen: the title, then the sections, then the one chosen. The sections wrap, each
     group's name leading its own lines, and never scroll sideways: a row that did ran past the window's edge at every
     phone width and cut the last section's name (task 5ENCR4). */
  .setwin__scrim { padding: 0; place-items: stretch; }
  .setwin { width: 100%; height: 100%; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); border: 0; border-radius: 0; }
  .setwin__side { gap: var(--space-2); overflow: visible; padding: var(--space-3) var(--space-3) 0; border-right: 0; border-bottom: var(--line-width) solid var(--line); }
  .setwin__h1 { min-height: var(--height-tap); display: flex; align-items: center; padding-inline-end: calc(var(--height-tap) + var(--space-2)); }
  .setwin__nav { display: grid; gap: 0; padding-bottom: var(--space-2); }
  .setwin__group { display: flex; flex-wrap: wrap; align-items: center; gap: 0 var(--space-1); min-width: 0; }
  .setwin__glabel { margin: 0; padding-inline: 0 var(--space-1); }
  .setwin__tab { width: auto; min-height: var(--height-tap); white-space: nowrap; }
  .setwin__whose { display: none; }
  .setwin__close { width: var(--height-tap); height: var(--height-tap); }
  .setwin__pane { padding: var(--space-4) var(--space-4) var(--space-6); }
  .setwin .opts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .setwin .opts[data-n="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .setwin [data-answering-dial] .opts { grid-template-columns: repeat(4, minmax(min-content, 1fr)); }
}
