/* jubarte.pro — design system (from the Claude Design project "Jubarte").
   Graphite, 1px hairlines, mono eyebrows, rounded controls, max contrast. */

@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("/static/fonts/manrope-latin-wght-normal.woff2") format("woff2-variations");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("/static/fonts/manrope-latin-ext-wght-normal.woff2") format("woff2-variations");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url("/static/fonts/jetbrains-mono-latin-wght-normal.woff2") format("woff2-variations");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url("/static/fonts/jetbrains-mono-latin-ext-wght-normal.woff2") format("woff2-variations");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url("/static/fonts/source-serif-4-latin-opsz-normal.woff2") format("woff2-variations");
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url("/static/fonts/source-serif-4-latin-ext-opsz-normal.woff2") format("woff2-variations");
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  /* Graphite (light) and Night (dark), from the design's palette tweaks, in
     OKLCH. The page follows the browser's preference until the footer switch
     pins one (html[data-theme], restored before paint by the inline script in
     layout.ts). light-dark() resolves per element, so a subtree that sets
     color-scheme: light (a document page) keeps the light values. */
  color-scheme: light dark;
  --bg: light-dark(oklch(97% 0.003 106.4), oklch(20% 0.023 249));
  --ink: light-dark(oklch(18.2% 0 0), oklch(96.2% 0.008 241.7));
  /* Max text contrast: secondary text is ink too. The Graphite muted,
     oklch(41.2% 0.005 106.6), and Night's, oklch(77.2% 0.027 244.5), go here
     if that tweak is ever turned off. */
  --muted: var(--ink);
  --primary: light-dark(oklch(21.8% 0 0), oklch(79.1% 0.094 237.6));
  --primary-dark: light-dark(oklch(0% 0 0), oklch(86.2% 0.065 236));
  --deep: light-dark(oklch(20.5% 0 0), oklch(94.5% 0.013 244.3));
  --on-deep: light-dark(oklch(100% 0 0), oklch(22.7% 0.038 244.5));
  --on-deep-muted: light-dark(oklch(100% 0 0 / 0.65), oklch(22.7% 0.038 244.5 / 0.65));
  --line: light-dark(oklch(87.5% 0.005 106.5), oklch(33.4% 0.039 250.5));
  --line-strong: light-dark(oklch(73.3% 0.007 106.6), oklch(43.6% 0.043 246.4));
  --surface: light-dark(oklch(94.2% 0.004 106.5), oklch(23.9% 0.026 249));
  --surface2: light-dark(oklch(91.2% 0.005 106.5), oklch(17.5% 0.02 252.3));
  --hover: light-dark(oklch(92.4% 0.005 106.5), oklch(27.1% 0.029 246.9));
  --hl: light-dark(oklch(91.6% 0.128 94.1), oklch(40.5% 0.075 243));
  --hl-soft: light-dark(oklch(96.2% 0.062 95.4), oklch(28.4% 0.046 245.3));
  /* Primary button: brand color, so the call to action is the primary. */
  --cta: var(--primary);
  --on-cta: light-dark(oklch(100% 0 0), oklch(22.7% 0.038 244.5));
  --disabled: light-dark(oklch(48.5% 0.005 106.6), oklch(67.8% 0.028 244.6));
  --ins: light-dark(oklch(45.3% 0.209 262), oklch(83.2% 0.087 249.4));
  --ins-bg: light-dark(oklch(92.8% 0.034 267.6), oklch(30.6% 0.071 253.5));
  --del: light-dark(oklch(52.7% 0.199 27.5), oklch(79.4% 0.119 30));
  --del-bg: light-dark(oklch(93.6% 0.032 17.7), oklch(29.3% 0.073 28.4));
  --mov: light-dark(oklch(51% 0.13 150.7), oklch(81.9% 0.108 163.1));
  --mov-bg: light-dark(oklch(94.4% 0.031 154.2), oklch(31.8% 0.055 162.9));
  --shadow: light-dark(oklch(18.2% 0 0 / 0.4), oklch(0% 0 0 / 0.6));
  /* A document page is paper in either mode. */
  --page: oklch(100% 0 0);
  /* Rounded buttons; pages a little less. */
  --radius: 6px;
  --radius-page: 4px;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --serif: "Source Serif 4", Georgia, serif;
  --max: 1180px;
}
:root[data-theme="light"] {
  color-scheme: light;
}
:root[data-theme="dark"] {
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
html {
  /* A focused or targeted element scrolls clear of the sticky nav (2.4.11). */
  scroll-padding-top: 72px;
  /* Short pages (404, live) keep the scrollbar's room: the nav never shifts. */
  scrollbar-gutter: stable;
  /* The parts the browser draws take the palette too. */
  scrollbar-color: var(--line-strong) var(--bg);
  accent-color: var(--primary);
  caret-color: var(--primary);
}
html,
body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
a {
  color: var(--primary);
  text-decoration: none;
}
a:hover {
  color: var(--primary-dark);
}
/* A link inside a sentence is underlined, never told apart by colour alone
   (WCAG 1.4.1): in Graphite --primary is nearly ink. DESIGN.md's link rule —
   a Hairline Strong underline that takes the brand colour on hover. A 1px
   grey hairline cannot read as an insertion (coloured, tinted, --ins). */
:where(main) :is(p, li, dd, figcaption) a:not([class]) {
  text-decoration-line: underline;
  text-decoration-color: var(--line-strong);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}
:where(main) :is(p, li, dd, figcaption) a:not([class]):hover {
  text-decoration-color: currentColor;
}
::selection {
  background: var(--hl);
  color: var(--ink);
}
img,
svg {
  display: block;
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
  border-radius: 0;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: not-allowed;
}
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
summary::-webkit-details-marker {
  display: none;
}
[hidden] {
  display: none !important;
}
.skip-link {
  position: absolute;
  left: 12px;
  top: -64px;
  z-index: 100;
  padding: 10px 16px;
  background: var(--deep);
  color: var(--on-deep);
  font-size: 0.875rem;
  font-weight: 600;
}
.skip-link:focus {
  top: 12px;
}
main:focus {
  outline: none;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Rounded controls and panels; joined controls clip their inner buttons. */
.btn,
.chip-btn,
.seg,
.buckets,
.tag,
.pill,
.slot,
.swap-btn,
.field,
.textarea,
.side-btn,
.nav-links a.nav-pro,
.nav-menu summary,
.nav-menu-list,
.toast,
.code-block,
.cli-echo,
.phone-note,
.sim-caption,
.form-card,
.topic,
.browser-frame,
.app-window,
.theme-toggle {
  border-radius: var(--radius);
}
.seg:not(.jump-seg),
.buckets,
.browser-frame {
  overflow: hidden;
}
.keys-off .key-hint {
  display: none;
}
/* A ring outside a clipped joined control is cut off: draw it inside. */
.seg:not(.jump-seg) > button:focus-visible,
.buckets button:focus-visible {
  outline-offset: -3px;
}
.seg.jump-seg {
  border-radius: 0;
}
.seg.jump-seg > button {
  border-radius: var(--radius);
}
.check input {
  border-radius: 3px;
}
.app-bar {
  border-radius: var(--radius) var(--radius) 0 0;
}
.app-body {
  border-radius: 0 0 var(--radius) var(--radius);
}
.app-right {
  border-bottom-right-radius: var(--radius);
}

/* A document page is paper in either mode: light values, slightly rounded. */
.paper,
.sheet,
.page-img,
.pg,
.stack,
.page-thumb .thumb,
.more-thumb .pair {
  color-scheme: light;
  border-radius: var(--radius-page);
}

@keyframes jb-spin {
  to {
    transform: rotate(360deg);
  }
}
/* Pulses text ("Loading page…"): its dip keeps the words at 4.9:1 on the
   page white; at 0.25 they fell to 1.75:1 mid-pulse. */
@keyframes jb-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.6;
  }
}
@keyframes jb-float {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-14px) rotate(-1.5deg);
  }
}
@keyframes jb-float-sm {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-9px);
  }
}
@keyframes jb-float-dl {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}
@keyframes jb-turn {
  to {
    transform: rotate(360deg);
  }
}
/* The feed's refresh mark: one turn per new case (home.js). */
.feed-refresh {
  display: inline-flex;
  align-self: center;
  color: var(--primary);
  transition: opacity 0.2s;
}
.feed-refresh svg {
  width: 16px;
  height: 16px;
}
.feed-refresh.turning svg {
  animation: jb-turn 0.9s cubic-bezier(0.45, 0, 0.55, 1) infinite;
}
.feed-refresh.held {
  opacity: 0.35;
}
.feed-refresh[hidden] {
  display: none;
}
@keyframes jb-drift {
  0%,
  100% {
    transform: translateY(0) rotate(-6deg);
  }
  50% {
    transform: translateY(-14px) rotate(-3deg);
  }
}
/* Reduced motion, component by component: each moving thing gets a still
   form that keeps its meaning. Colour and opacity fades stay; they don't move. */
@media (prefers-reduced-motion: reduce) {
  /* Decorative drift and float stop where they stand. */
  .watermark,
  .feed-refresh.turning svg,
  .app-icon.float,
  .whale-float,
  .whale-float-sm {
    animation: none;
  }
  /* Pulses hold at full strength; the words beside them already say "working". */
  .sheet .pending span,
  .pg:not(.missing)::before {
    animation: none;
  }
  /* A spinner that cannot spin reads as a frozen ring, so it becomes an ellipsis. */
  .spinner {
    animation: none;
    width: auto;
    height: auto;
    border: 0;
    border-radius: 0;
  }
  .spinner::before {
    content: "…";
  }
  /* A button's label already says "Redlining…", so its spinner just goes. */
  .btn .spinner {
    display: none;
  }
  /* The swap button flips at once instead of turning. */
  .swap-btn {
    transition: none;
  }
}

/* ── type ─────────────────────────────────────────────────────────────── */
.mono {
  font-family: var(--mono);
}
/* A filename or a hash has no space to break at; on a phone it widened the
   Benchmark page to 608px. Break inside it only when the line would overflow. */
.code-inline,
.section-head code,
.note code,
.mono {
  overflow-wrap: break-word;
}
.eyebrow {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.kicker {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
/* The bench badge (bench-viewer's renderBadge): the jubarte theme's own rule
 * (themes/jubarte.css) — the eyebrow's declarations under the badge's class. */
.bench-badge {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.label {
  display: block;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.h1 {
  font-weight: 700;
  letter-spacing: -0.03em;
  font-size: clamp(1.875rem, 4.4vw, 3rem);
  line-height: 1.05;
  margin-top: 18px;
  text-wrap: balance;
}
.h2 {
  font-size: clamp(1.75rem, 3.4vw, 2.375rem);
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.1;
  margin-top: 20px;
  text-wrap: balance;
}
.lead {
  font-size: 1.0625rem;
  line-height: 1.55;
  color: var(--muted);
  margin-top: 16px;
  max-width: 62ch;
  text-wrap: pretty;
}
.muted {
  color: var(--muted);
}
.small {
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--muted);
  text-wrap: pretty;
}
.note {
  font-size: 0.8125rem;
  line-height: 1.6;
  color: var(--muted);
  margin-top: 36px;
  max-width: 75ch;
  text-wrap: pretty;
}
/* Home's strip caption spans the section: the notes' measure keeps it readable. */
.strip-note {
  max-width: 75ch;
}
.code-inline,
.section-head code,
.note code {
  font-family: var(--mono);
  font-size: 0.86em;
  color: var(--ink);
}
.hl {
  /* A marker stroke, not a selection box: it stops short of the line's top and
     bottom, and its ends are uneven. In Night the full-height block read as
     selected text. */
  background: linear-gradient(to bottom, transparent 0 12%, var(--hl) 12% 93%, transparent 93%);
  color: var(--ink);
  padding: 0 0.22em;
  margin: 0 -0.08em;
  border-radius: 0.5em 0.18em 0.42em 0.14em / 0.7em 0.25em 0.55em 0.2em;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}
.dagger {
  color: var(--muted);
  font-weight: 400;
}

/* ── layout ───────────────────────────────────────────────────────────── */
.wrap {
  max-width: var(--max);
  width: 100%;
  margin: 0 auto;
  padding-left: 32px;
  padding-right: 32px;
}
main.wrap {
  flex: 1;
  padding-top: 56px;
  padding-bottom: 80px;
  position: relative;
  z-index: 1;
}
.page-bg {
  position: relative;
  overflow: hidden;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.watermark {
  position: absolute;
  right: -120px;
  bottom: 40px;
  width: 620px;
  height: auto;
  color: var(--ink);
  opacity: 0.04;
  pointer-events: none;
  z-index: 0;
  animation: jb-drift 16s ease-in-out infinite;
}
/* Home: the whale low behind the hero's words, fainter than elsewhere. */
.watermark.hero-mark {
  left: -160px;
  right: auto;
  bottom: -90px;
  width: 640px;
  opacity: 0.035;
}
.watermark.top {
  top: 80px;
  bottom: auto;
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  flex-wrap: wrap;
  border-bottom: 1px solid var(--line);
  padding-bottom: 14px;
}
/* The mono kicker belongs to the page head (.eyebrow) alone; a section opens
   with a plain heading and its facts in mono, not another tracked label. */
.section-head > :first-child {
  font-family: var(--sans);
  font-size: 1.1875rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
  text-wrap: balance;
}
.section-head > :last-child:not(:first-child) {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--muted);
}
.cells {
  display: grid;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.cells.no-top {
  border-top: 0;
}
.cells > * {
  background: var(--bg);
  min-width: 0;
}
/* Emitted by bench-viewer's render.js (the /benchmark headline cards). */
.cols-auto-200 {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}
.cols-auto-220 {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.cols-auto-240 {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.cols-auto-260 {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.cols-auto-280 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}
.cell-pad {
  padding: 26px 24px 28px;
}
/* The recommended card is marked by the highlighter, not a side stripe. */
.featured {
  background: var(--hl-soft);
}
.row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}
.mt-12 {
  margin-top: 12px;
}
.mt-18 {
  margin-top: 18px;
}
.mt-24 {
  margin-top: 24px;
}
.mt-28 {
  margin-top: 28px;
}
.mt-36 {
  margin-top: 36px;
}
.mt-40 {
  margin-top: 40px;
}
.mt-56 {
  margin-top: 56px;
}
.mt-64 {
  margin-top: 64px;
}
.mt-72 {
  margin-top: 72px;
}
.scroll-x {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

/* ── buttons ──────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--sans);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.3;
  padding: 12px 20px;
  border: 1px solid transparent;
  text-align: center;
  transition:
    background 0.15s ease,
    color 0.15s ease,
    border-color 0.15s ease;
}
/* One solid button: the brand colour (Arthur's "primary button = brand
   colour"). Deep is the app's title bar, not a button. */
.btn-primary,
.btn-cta {
  color: var(--on-cta);
  background: var(--cta);
  border-color: var(--cta);
}
.btn-primary:hover:not(:disabled),
.btn-cta:hover:not(:disabled) {
  color: var(--on-cta);
  background: var(--primary-dark);
  border-color: var(--primary-dark);
}
.btn-outline {
  color: var(--primary);
  background: var(--bg);
  border-color: var(--primary);
}
.btn-outline:hover:not(:disabled) {
  background: var(--hover);
}
.btn-ghost {
  color: var(--ink);
  background: var(--bg);
  border-color: var(--line);
}
.btn-ghost:hover:not(:disabled) {
  background: var(--hover);
}
.btn-text {
  color: var(--ink);
  padding-left: 6px;
  padding-right: 6px;
}
/* Disabled is an outline in every variant: a filled gray read as an enabled
   primary (2.7:1 against it in Graphite, 1.5:1 in Night). */
.btn:disabled,
.btn[aria-disabled="true"] {
  color: var(--disabled);
  background: var(--surface);
  border-color: var(--line-strong);
  border-style: dashed;
}
.btn-sm {
  font-size: 0.8125rem;
  padding: 9px 16px;
}
.btn-lg {
  padding: 13px 22px;
}
.chip-btn {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 9px 12px;
  background: var(--bg);
  color: var(--ink);
  border: 1px solid var(--line);
}
.chip-btn:hover:not(:disabled):not(.dark) {
  background: var(--hover);
}
.chip-btn.dark:hover:not(:disabled) {
  background: var(--primary);
  border-color: var(--primary);
}
.chip-btn:disabled {
  color: var(--disabled);
  border-color: var(--line);
}
.chip-btn.dark,
.chip-btn[aria-pressed="true"].dark {
  background: var(--deep);
  color: var(--on-deep);
  border-color: var(--deep);
}
/* Pressed is an ink frame on the hover fill: the highlighter marks claims only. */
.chip-btn[aria-pressed="true"]:not(.dark) {
  background: var(--hover);
  color: var(--ink);
  border-color: var(--ink);
}
.seg {
  display: flex;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.seg > button {
  font-family: var(--sans);
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 10px 16px;
  background: var(--bg);
  color: var(--muted);
  border: 0;
  white-space: nowrap;
}
.seg > button[aria-pressed="true"] {
  background: var(--deep);
  color: var(--on-deep);
}
.seg.mono-seg > button {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.06em;
  font-weight: 400;
  padding: 8px 12px;
}
/* The App page's state jumps: separate buttons, not a joined control. */
.seg.jump-seg {
  gap: 8px;
  background: none;
  border: 0;
}
.seg.jump-seg > button {
  padding: 7px 11px;
  border: 1px solid var(--line);
}
.seg.jump-seg > button[aria-pressed="true"] {
  border-color: var(--deep);
}
.spinner {
  width: 14px;
  height: 14px;
  border: 2px solid color-mix(in oklch, currentColor 35%, transparent);
  border-top-color: currentColor;
  border-radius: 50%;
  display: inline-block;
  animation: jb-spin 0.7s linear infinite;
}

/* ── tags ─────────────────────────────────────────────────────────────── */
.tag {
  display: inline-block;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 9px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: var(--bg);
}
/* A state (clean, published, 7 pages): neutral, a stronger frame than a plain tag. */
.tag.state {
  color: var(--ink);
  border-color: var(--line-strong);
}
.tag.blue {
  color: var(--primary);
}
.tag.ins {
  background: var(--ins-bg);
  color: var(--ins);
  border-color: var(--ins-bg);
}
.tag.del {
  background: var(--del-bg);
  color: var(--del);
}
.tag.mov {
  background: var(--mov-bg);
  color: var(--mov);
}
.tag.fmt {
  background: var(--surface);
  color: var(--muted);
}
.tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

/* ── nav ──────────────────────────────────────────────────────────────── */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
.site-nav .wrap {
  /* The mobile menu hangs from the bar's bottom edge, not from its button. */
  position: relative;
  padding-top: 14px;
  padding-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
}
.brand:hover {
  color: var(--ink);
}
/* The illustrated whale keeps its blues; in Night a rim lifts its dark body
   off the dark page. */
.whale-body {
  stroke: light-dark(transparent, color-mix(in oklch, var(--primary) 55%, transparent));
  stroke-width: 3;
}
.brand-mark .mk-body {
  fill: var(--primary);
}
.brand-mark .mk-fin {
  fill: color-mix(in oklch, var(--primary) 45%, var(--bg));
}
.brand-mark .mk-eye {
  fill: var(--bg);
}
.brand-word {
  font-family: var(--mono);
  font-size: 0.875rem;
  letter-spacing: 0.06em;
  font-weight: 500;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.nav-links a {
  /* A 24px target at least (WCAG 2.2 2.5.8): the extra height goes above the
     word, so the underline keeps its place. */
  display: inline-block;
  padding-top: 7px;
  color: var(--muted);
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
}
.nav-links a:hover {
  color: var(--ink);
}
.nav-links a[aria-current="page"] {
  color: var(--ink);
  border-bottom-color: var(--primary);
}
/* PRO, the paid app, in inverted colours: the page's ink as the fill. */
.nav-links a.nav-pro {
  font-weight: 800;
  color: var(--bg);
  background: var(--ink);
  border: 1px solid var(--ink);
  padding: 7px 12px;
  letter-spacing: 0.12em;
}
.nav-links a.nav-pro:hover {
  color: var(--bg);
  background: color-mix(in oklch, var(--ink) 82%, var(--bg));
}
.nav-links a.nav-pro[aria-current="page"] {
  color: var(--on-cta);
  background: var(--primary);
  border-color: var(--primary);
}
.nav-menu {
  display: none;
}
.nav-menu summary {
  list-style: none;
  cursor: pointer;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary);
  border: 1px solid var(--primary);
  padding: 8px 12px;
  user-select: none;
}
/* A sheet pulled down from the bar: flush with its bottom rule (which it
   covers), open at the top, lifted off the page by a shadow. */
.nav-menu-list {
  position: absolute;
  right: 18px;
  top: 100%;
  background: var(--bg);
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: 0 24px 48px -28px var(--shadow);
  overflow: hidden;
  min-width: 240px;
  display: flex;
  flex-direction: column;
  z-index: 50;
}
.nav-menu-list a {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--ink);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.nav-menu-list a:last-child {
  border-bottom: 0;
}
.nav-menu-list a[aria-current="page"] {
  color: var(--primary);
}
.nav-menu-list a.nav-pro {
  font-weight: 800;
  color: var(--bg);
  background: var(--ink);
  letter-spacing: 0.08em;
}
.nav-menu-list a.nav-pro[aria-current="page"] {
  color: var(--on-cta);
  background: var(--primary);
}
.nav-menu-list a[aria-current="page"]::after {
  content: "";
  width: 6px;
  height: 6px;
  background: var(--primary);
}

/* ── footer ───────────────────────────────────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--line);
  position: relative;
  z-index: 1;
}
.site-footer .wrap {
  padding-top: 28px;
  padding-bottom: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.site-footer nav {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}
.site-footer a {
  color: var(--muted);
}
/* On touch, standalone links (not links inside prose) get a 44px target. */
@media (pointer: coarse) {
  .site-footer nav a,
  .hero-meta a,
  .section-head > a,
  a.small-mono,
  .t-row a,
  .contact-mail {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
  .chip-btn,
  .seg > button,
  .buckets button,
  .side-btn,
  .nav-menu summary,
  .theme-toggle {
    min-height: 44px;
  }
  /* min-* wins over the base rule's 34px size, which comes later in the file. */
  .swap-btn {
    min-width: 44px;
    min-height: 44px;
  }
}
.site-footer a:hover {
  color: var(--ink);
}
/* The light/dark switch: its label names the mode a click turns on. */
.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border: 1px solid var(--line-strong);
  background: var(--bg);
  color: var(--ink);
  font: inherit;
  letter-spacing: inherit;
  text-transform: inherit;
}
.theme-toggle:hover {
  background: var(--hover);
}
.theme-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid currentColor;
  background: linear-gradient(90deg, currentColor 50%, transparent 50%);
}
.theme-toggle .to-light,
:root[data-theme="dark"] .theme-toggle .to-dark {
  display: none;
}
:root[data-theme="dark"] .theme-toggle .to-light {
  display: inline;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .to-dark {
    display: none;
  }
  :root:not([data-theme="light"]) .theme-toggle .to-light {
    display: inline;
  }
}

/* ── page header block ────────────────────────────────────────────────── */
.page-head {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  justify-content: space-between;
  align-items: flex-end;
}
.page-head > div:first-child {
  max-width: 720px;
}
/* The App and Demo heads are narrower than the rest (their designs). */
.head-app {
  gap: 24px;
}
.head-app > div:first-child {
  max-width: 640px;
}
.head-app .h1 {
  font-size: clamp(1.875rem, 4.4vw, 2.75rem);
  margin-top: 16px;
}
.head-app .lead {
  font-size: 1rem;
  margin-top: 14px;
  max-width: none;
}
.head-demo > div:first-child {
  max-width: 680px;
}
.head-demo .h1 {
  line-height: 1.1;
}
.head-demo .lead {
  max-width: 60ch;
}
/* Download: copy beside the floating app icon, ruled off from the cards. */
.head-download {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(220px, 0.7fr);
  gap: 40px;
  align-items: center;
  border-bottom: 1px solid var(--line);
  padding-bottom: 48px;
}
.head-download .lead {
  max-width: 58ch;
}
.head-download .app-icon {
  justify-self: center;
}
.pill {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--primary-dark);
  background: var(--hl-soft);
  padding: 8px 12px;
}

/* ── drop slots ───────────────────────────────────────────────────────── */
.slots {
  display: grid;
  grid-template-columns: 1fr 44px 1fr;
  align-items: stretch;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.slot {
  background: var(--bg);
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 176px;
  padding: 34px 14px 24px;
  text-align: center;
  cursor: pointer;
  border: 0;
  width: 100%;
  transition: background 0.15s ease;
}
.slot.dashed {
  border: 1px dashed var(--line-strong);
}
.slot:hover {
  background: var(--hover);
}
.slot.filled {
  background: var(--surface);
}
.slot.over {
  background: var(--hl);
}
.slot-label {
  position: absolute;
  top: 12px;
  left: 16px;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
}
.slot-icon {
  width: 34px;
  height: 34px;
  color: var(--primary);
}
.slot-name {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  overflow-wrap: break-word;
  line-height: 1.4;
}
.slot-meta {
  display: block;
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--muted);
  margin-top: 6px;
}
.swap-btn {
  align-self: center;
  justify-self: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--primary);
  display: grid;
  place-items: center;
  transition: transform 0.35s cubic-bezier(0.25, 1, 0.5, 1);
}
.swap-btn:hover {
  background: var(--hover);
}
.swap-btn.flipped {
  transform: rotate(180deg);
}
.swap-btn svg {
  width: 15px;
  height: 15px;
}
.field {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 14px;
  border: 1px solid var(--line);
  background: var(--bg);
}
.field > span:first-child {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}
.field input {
  flex: 1;
  min-width: 60px;
  padding: 12px 0;
  font-size: 0.875rem;
  background: none;
  border: none;
  outline: none;
}
.field:focus-within {
  border-color: var(--primary);
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
::placeholder {
  color: var(--disabled);
  opacity: 1;
}
.field .hint {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary);
  white-space: nowrap;
}
.input,
.select,
.textarea {
  width: 100%;
  font-size: 0.9375rem;
  color: var(--ink);
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 12px 13px;
}
.input:focus,
.select:focus,
.textarea:focus {
  border-color: var(--primary);
}
.textarea {
  line-height: 1.55;
  resize: vertical;
}
.check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.875rem;
  cursor: pointer;
}
.check input {
  appearance: none;
  width: 16px;
  height: 16px;
  border: 1px solid var(--primary);
  background: var(--bg);
  display: inline-grid;
  place-items: center;
  margin: 0;
  flex: none;
}
.check input:checked {
  background: var(--primary);
}
.check input:checked::after {
  content: "✓";
  color: var(--on-cta);
  font-size: 0.6875rem;
  line-height: 1;
}
/* "Preview as soon as the documents are in": a line of its own above the run button. */
.check.instant {
  display: flex;
  align-items: flex-start;
  margin: 0.75rem 0;
  font-size: 0.8125rem;
  line-height: 1.45;
}
.check.instant input {
  margin-top: 0.125rem;
}

/* ── paper preview (redline) ──────────────────────────────────────────── */
.paper {
  border: 1px solid var(--line-strong);
  background: var(--page);
  max-height: 430px;
  overflow-y: auto;
  padding: 40px 48px;
  font-family: var(--serif);
  font-size: 1rem;
  line-height: 1.75;
  color: var(--ink);
}
.paper p {
  margin: 0 0 14px;
}
.paper .doc-title {
  text-align: center;
  font-weight: 600;
  margin-bottom: 2px;
}
.paper .doc-sub {
  text-align: center;
  font-size: 0.8125rem;
  color: var(--muted);
  margin-bottom: 20px;
}
.paper .doc-h {
  font-weight: 600;
  margin-bottom: 6px;
}
.paper .doc-more {
  font-family: var(--sans);
  font-size: 0.75rem;
  color: var(--muted);
  border-top: 1px solid var(--line);
  padding-top: 12px;
}
ins,
.ins {
  color: var(--ins);
  background: var(--ins-bg);
  text-decoration: underline;
  text-underline-offset: 2px;
}
del,
.del {
  color: var(--del);
  background: var(--del-bg);
  text-decoration: line-through;
}
.mov {
  color: var(--mov);
  background: var(--mov-bg);
  text-decoration: underline double;
  text-underline-offset: 2px;
}
.fmtchg {
  border-bottom: 1px dotted var(--muted);
}

/* ── empty / result panels ────────────────────────────────────────────── */
.empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 14px;
  min-height: 360px;
  color: var(--muted);
}
.empty p {
  font-size: 0.9375rem;
  color: var(--ink);
}
.empty .mono {
  font-size: 0.6875rem;
}
.result-head {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
}
.result-file {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}
.check-ico {
  width: 28px;
  height: 28px;
  color: var(--primary);
  flex: none;
}
.result-file strong {
  display: block;
  font-size: 0.9375rem;
  font-weight: 600;
  overflow-wrap: anywhere;
}
.result-file .mono {
  font-size: 0.6875rem;
  color: var(--muted);
}
.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  z-index: 60;
  background: var(--deep);
  color: var(--on-deep);
  font-size: 0.8125rem;
  padding: 12px 18px;
  max-width: 92vw;
}
/* Kept in the accessibility tree while empty, so the live region announces. */
.toast.off {
  opacity: 0;
  pointer-events: none;
}
.toast[data-kind="error"]::before,
.toast[data-kind="warn"]::before {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.toast[data-kind="error"]::before {
  content: "Error · ";
}
.toast[data-kind="warn"]::before {
  content: "Note · ";
}
.toast.inside {
  position: absolute;
  bottom: 22px;
  z-index: 5;
}

/* ── page thumbnails (mini layouts) and real page images ─────────────── */
.sheet {
  background: var(--page);
  border: 1px solid var(--line);
  aspect-ratio: 8.5 / 11;
  overflow: hidden;
  position: relative;
}
.sheet .pending {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  padding: 12px;
}
.sheet .pending span {
  animation: jb-pulse 1.2s ease-in-out infinite;
}
.page-img {
  position: relative;
  overflow: hidden;
  background: var(--page);
}
.page-img > img {
  position: absolute;
  left: 0;
  width: 100%;
  height: auto;
  max-width: none;
  user-select: none;
  -webkit-user-drag: none;
}

/* ── tables ───────────────────────────────────────────────────────────── */
.t-row {
  display: grid;
  gap: 0 14px;
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
  align-items: center;
}
.t-row.head {
  padding: 12px 0 10px;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.t-row:not(.head):hover {
  background: var(--hover);
}
.num {
  font-family: var(--mono);
  font-size: 0.8125rem;
  text-align: right;
}
.bar {
  height: 10px;
  background: var(--surface);
}
.bar > div {
  height: 100%;
  background: var(--line-strong);
}
.bar.hi > div {
  background: var(--primary);
}
.bar.thin {
  height: 6px;
  margin-top: 4px;
}

/* ── shared bits the pages use ─────────────────────────────────────── */
.strong {
  font-weight: 600;
}
.ink,
.ink-strong {
  color: var(--ink);
}
.ink-strong {
  font-weight: 500;
}
.blue,
.mono.blue {
  color: var(--primary);
}
.kicker.blue {
  color: var(--primary);
}
.kicker.ink {
  color: var(--ink);
}
.r {
  text-align: right;
}
/* Red means deleted; a warning is marked with a sign, not a revision colour. */
.warn {
  font-weight: 700;
}
.warn::before {
  content: "≠ ";
}
.gap-8 {
  gap: 8px;
}
.gap-10 {
  gap: 10px;
}
.small-mono {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.section-title {
  font-size: 1.1875rem;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.body-muted {
  font-size: 0.9375rem;
  line-height: 1.6;
  color: var(--muted);
  text-wrap: pretty;
}
.note-title {
  font-size: 1rem;
  font-weight: 600;
  margin-top: 20px;
}
.kicker + .note-title {
  margin-top: 12px;
}
.cell-pad > .note-title:first-child {
  margin-top: 0;
}
/* Home: one command block with a tab per surface, not four look-alike cards. */
.installer {
  max-width: 780px;
}
.installer-tabs {
  margin-top: 0;
}
.installer-panel .code-block {
  font-size: 0.875rem;
  margin-top: 18px;
}
.surface-title {
  font-size: 1.125rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  margin-top: 14px;
}
.code-block {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--ink);
  margin-top: 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 10px 12px;
  line-height: 1.6;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
/* A command word wraps whole; one longer than the line still breaks inside. */
.tok {
  display: inline-block;
  max-width: 100%;
}
.head-rule {
  border-bottom: 1px solid var(--line);
  padding-bottom: 28px;
}
.btn-text.small-mono {
  padding: 0;
  border: 0;
  background: none;
  color: var(--primary);
}
.pg {
  position: relative;
  overflow: hidden;
  background: var(--page);
  width: 100%;
}
/* Until the strip paints, the page says so: the image covers this label. */
.pg:not(.missing)::before {
  content: "Loading page…";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  color: var(--muted);
  animation: jb-pulse 1.2s ease-in-out infinite;
}
.pg > img {
  position: absolute;
  left: 0;
  width: 100%;
  height: auto;
  max-width: none;
  user-select: none;
  -webkit-user-drag: none;
}
.pg.missing {
  aspect-ratio: 8.5 / 11;
  display: grid;
  place-items: center;
  background: var(--surface);
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  text-align: center;
  padding: 12px;
}

/* ── home ─────────────────────────────────────────────────────────────── */
.hero {
  position: relative;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.hero-grid {
  position: relative;
  z-index: 1;
  padding-top: 72px;
  padding-bottom: 64px;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(280px, 0.85fr);
  gap: 48px;
  align-items: center;
}
.rule-eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
}
.rule-eyebrow > span {
  display: inline-block;
  width: 26px;
  height: 1px;
  background: var(--primary);
}
.hero-h1 {
  font-weight: 700;
  letter-spacing: -0.034em;
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  line-height: 1.08;
  margin-top: 26px;
  max-width: 14ch;
  text-wrap: pretty;
}
.hero-lead {
  font-size: clamp(1.0625rem, 2vw, 1.3125rem);
  line-height: 1.45;
  color: var(--muted);
  margin-top: 26px;
  max-width: 52ch;
  text-wrap: pretty;
}
.hero-meta {
  display: flex;
  gap: 28px;
  flex-wrap: wrap;
  margin-top: 40px;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
/* The hero's marked-up clause: the paper a lawyer would receive. */
.hero-redline {
  align-self: center;
}
.redline-paper {
  max-height: none;
  overflow: visible;
  padding: 36px 40px 28px;
  font-size: 0.96875rem;
  line-height: 1.8;
  border-color: var(--ink);
}
.redline-paper p:last-child {
  margin-bottom: 0;
}
.hero-redline figcaption {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
  margin-top: 14px;
}
.redline-note {
  flex: 1 1 240px;
  font-size: 0.75rem;
  color: var(--muted);
}
.band {
  border-bottom: 1px solid var(--line);
}
.paper-band {
  background: var(--surface);
}
.band-pad {
  padding-top: 88px;
  padding-bottom: 88px;
}
.band-pad-sm {
  padding-top: 48px;
  padding-bottom: 52px;
}
.band-pad-md {
  padding-top: 64px;
  padding-bottom: 64px;
}
.feed-grid {
  display: grid;
  grid-template-columns: minmax(200px, 1fr) minmax(0, 2.2fr);
  gap: 32px;
  margin-top: 28px;
  align-items: start;
}
.feed-path {
  font-family: var(--mono);
  font-size: 0.75rem;
  margin-top: 10px;
  word-break: break-all;
  line-height: 1.5;
}
.feed-scores {
  margin-top: 26px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.feed-scores > div {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 10px;
}
.feed-scores dt {
  font-size: 0.8125rem;
  color: var(--muted);
}
.feed-scores dd {
  font-family: var(--mono);
  font-size: 0.8125rem;
  text-align: right;
}
.feed-scores .ours dt {
  font-weight: 600;
  color: var(--primary);
}
.feed-scores .ours dd {
  color: var(--primary);
  font-weight: 500;
}
/* Download: the Mac app's facts, label beside value, one ruled row each. */
.spec > div {
  display: grid;
  grid-template-columns: minmax(130px, 0.28fr) minmax(0, 1fr);
  gap: 18px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.spec dt {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 3px;
}
.spec dd {
  font-size: 0.9375rem;
  line-height: 1.5;
}
.dev-lead {
  max-width: 68ch;
}
.feed-sheets {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.strip-col {
  min-width: 0;
}
.strip-col figcaption {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.strip-col .sheet {
  margin-top: 8px;
}
.sheet .pg {
  position: absolute;
  inset: 0;
}
.bench-grid {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(0, 1.6fr);
  gap: 56px;
  align-items: start;
}
.bench-groups {
  display: flex;
  flex-direction: column;
  gap: 40px;
}
.group-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 0.9375rem;
  font-weight: 600;
}
.bars {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}
.bar-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr) 64px;
  gap: 14px;
  align-items: center;
  font-size: 0.8125rem;
  color: var(--muted);
}
.bar-row > span:first-child {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.bar-row.ours {
  color: var(--primary);
  font-weight: 600;
}

/* ── live ─────────────────────────────────────────────────────────────── */
.live-soon {
  margin-top: 36px;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
}
.live-whale {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.soon-title {
  font-size: clamp(1.625rem, 3vw, 2.125rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-top: 18px;
}
.phase-list {
  list-style: none;
  display: flex;
  flex-direction: column;
}
.phase-list li {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}
.phase-list li strong {
  display: block;
  font-size: 0.875rem;
}
.phase-list li .small {
  display: block;
}
.phase-n {
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--primary);
  padding-top: 3px;
}

/* ── demo ─────────────────────────────────────────────────────────────── */
.phone-note {
  margin-top: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 16px 18px;
  font-size: 0.8125rem;
  line-height: 1.55;
  color: var(--ink);
}
.phone-note .kicker {
  display: block;
  margin-bottom: 6px;
}
.tabs {
  display: flex;
  gap: 0;
  margin-top: 40px;
  border-bottom: 1px solid var(--line);
}
.tabs [role="tab"] {
  font-size: 0.875rem;
  font-weight: 600;
  padding: 12px 18px;
  background: none;
  border: 0;
  border-bottom: 2px solid transparent;
  color: var(--muted);
  white-space: nowrap;
  margin-bottom: -1px;
}
.tabs [role="tab"][aria-selected="true"] {
  color: var(--ink);
  border-bottom-color: var(--primary);
}
.demo-grid {
  display: grid;
  grid-template-columns: minmax(300px, 440px) minmax(0, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-top: 0;
}
.demo-grid > * {
  background: var(--bg);
  min-width: 0;
}
.demo-controls {
  padding: 28px 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.demo-preview {
  padding: 28px 30px 32px;
  display: flex;
  flex-direction: column;
  background: var(--surface);
}
.status {
  min-height: 1.6em;
}
.sample-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
}
.sample-row .small {
  flex: 1 1 200px;
}
.how-it-runs summary {
  cursor: pointer;
  font-size: 0.8125rem;
  font-weight: 600;
}
.status details {
  margin-top: 6px;
}
.status summary {
  cursor: pointer;
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.status pre {
  margin-top: 6px;
  font-family: var(--mono);
  font-size: 0.6875rem;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.slot.bad {
  outline: 2px dashed var(--ink);
  outline-offset: -4px;
}
.steps {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  border-top: 1px solid var(--line);
  padding-top: 16px;
  font-size: 0.8125rem;
  color: var(--muted);
}
.steps li {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 8px;
}
.steps li > span:first-child {
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--primary);
  padding-top: 2px;
}
.seg-2 > button {
  flex: 1;
}
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  align-items: end;
}
.cli-echo {
  font-family: var(--mono);
  font-size: 0.6875rem;
  line-height: 1.6;
  color: var(--on-deep);
  background: var(--deep);
  padding: 12px 14px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.page-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 16px;
  margin-top: 18px;
  max-height: 640px;
  overflow-y: auto;
}
.page-thumb .thumb {
  aspect-ratio: 8.5 / 11;
  background: var(--page);
  border: 1px solid var(--line);
  display: grid;
  place-items: center;
  overflow: hidden;
}
.page-thumb .thumb .spinner {
  border-color: var(--line);
  border-top-color: var(--primary);
}
.page-thumb canvas {
  width: 100%;
  height: auto;
}
.page-thumb figcaption {
  font-size: 0.6875rem;
  color: var(--muted);
  margin-top: 6px;
  letter-spacing: 0.08em;
}
.page-thumb.failed .thumb::after {
  content: "could not draw";
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--muted);
}
#r-result,
#a-result {
  transition: opacity 0.2s ease;
}

/* ── the result's documents (site/doc-view.ts, static/js/doc-view.js) ── */
.doc-view {
  margin-top: 18px;
  container-type: inline-size;
}
.doc-view-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  margin-bottom: 12px;
}
.doc-view-tools [hidden] {
  display: none;
}
.doc-panes {
  display: grid;
  gap: 16px;
}
.doc-view[data-layout="side"] .doc-panes {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
.doc-view[data-layout="side"][data-pages="3"] .doc-panes {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.doc-view-tools .doc-views + .doc-pages {
  margin-right: auto;
}
/* 3-page side by side takes the page's whole width: the controls move above
   the result. Keyed on the choice (data-side), never on the measured layout. */
.app-body:has(:not([hidden]) > .doc-view[data-side="true"][data-pages="3"]),
.demo-grid:has(:not([hidden]) > .doc-view[data-side="true"][data-pages="3"]) {
  grid-template-columns: minmax(0, 1fr);
}
.doc-pages [data-swap] {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.doc-pages [data-swap] svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
/* Each pane's zoom: −, the zoom (pressing it fits the page again), +. */
.doc-zoom {
  display: inline-flex;
  flex: none;
  margin-left: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.doc-zoom:empty {
  display: none;
}
.doc-zoom button {
  min-width: 28px;
  padding: 6px 8px;
  border: 0;
  background: transparent;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 0.6875rem;
  cursor: pointer;
}
.doc-zoom button + button {
  border-left: 1px solid var(--line);
}
.doc-zoom .folio-zoom-level {
  min-width: 48px;
}
.doc-zoom button:hover:not(:disabled),
.doc-zoom button[aria-pressed="true"] {
  color: var(--ink);
}
.doc-zoom button:disabled {
  cursor: default;
  opacity: 0.5;
}
.doc-zoom button:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: -2px;
}
.doc-pane {
  margin: 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
}
.doc-pane[hidden] {
  display: none;
}
.doc-cap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.doc-cap .doc-cap-label {
  min-width: 0;
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.doc-review {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  white-space: nowrap;
}
.doc-review svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.doc-review[aria-expanded="true"],
.chip-btn.doc-review[aria-expanded="true"]:hover:not(:disabled) {
  background: var(--deep);
  border-color: var(--deep);
  color: var(--on-deep);
}
.doc-review:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
/* Side by side in a narrow column: the button keeps its icon and its name. */
@container (max-width: 820px) {
  .doc-view[data-layout="side"] .doc-review span {
    display: none;
  }
}
/* A phone: the review button is its icon, so the caption keeps room. */
@media (max-width: 480px) {
  .doc-review span {
    display: none;
  }
}
/* Three panes: the review button is its icon, so each caption keeps room. */
.doc-view[data-layout="side"][data-pages="3"] .doc-review span {
  display: none;
}
/* A document drawn by the Folio viewer: the frame is the page area. */
.paper.doc-paper.folio-host {
  --folio-height: clamp(420px, 72vh, 900px);
  padding: 0;
  max-height: none;
  overflow: hidden;
  border-radius: var(--radius-page);
}
.paper .folio-unavailable {
  margin: 0;
  font-family: var(--sans);
  font-size: 0.875rem;
  color: var(--muted);
}
.stale {
  opacity: 0.55;
}
.paper p.blank {
  min-height: 1em;
}
.paper .moveins,
.paper .movedel {
  color: var(--mov);
  background: var(--mov-bg);
}
.paper .moveins {
  text-decoration: underline double;
  text-underline-offset: 2px;
}
.paper .movedel {
  text-decoration: line-through double;
}
.tag.del,
.tag.mov {
  border-color: var(--line);
}
/* The chips are the legend: each count wears its revision's mark. An
   insertion or deletion is marked once, a move twice. */
.tag.ins {
  text-decoration: underline;
  text-underline-offset: 3px;
}
.tag.del {
  text-decoration: line-through;
}
.tag.mov {
  text-decoration: underline double;
  text-underline-offset: 3px;
}
.chips > .tag {
  padding: 6px 11px;
  letter-spacing: 0.08em;
}

/* ── benchmark ────────────────────────────────────────────────────────── */
.intro {
  max-width: 760px;
}
.intro .lead {
  max-width: 75ch;
}
.headline-v {
  display: flex;
  align-items: baseline;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 14px;
}
.headline-v > span:first-child {
  font-variant-numeric: tabular-nums;
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--primary);
}
.headline-v .mono {
  font-size: 0.75rem;
  /* a flex item stops at its longest word (a 40-char hash) unless let shrink */
  min-width: 0;
}
.bench-table,
.score-table,
.dl-table {
  min-width: 720px;
}
.bench-cols {
  grid-template-columns: 34px minmax(170px, 1.1fr) minmax(200px, 1.6fr) 70px 70px 70px 60px;
}
.bench-cols .r,
.bench-cols .num {
  text-align: right;
}
/* The featured row is a flat Highlighter Soft fill (DESIGN.md), not a fade. */
.t-row.ours {
  background: var(--hl-soft);
}
.tool-name {
  font-size: 0.875rem;
  font-weight: 600;
}
.t-row.ours .tool-name {
  color: var(--primary);
}
.tool-pin {
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--muted);
  margin-top: 2px;
}
.bar-cell {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.bar-note {
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--muted);
  max-width: 75ch;
}
.num.failed {
  font-weight: 700;
}
.state-name {
  font-size: 0.875rem;
  font-weight: 600;
}
.state-rows {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}
.state-row > div:first-child {
  display: flex;
  justify-content: space-between;
  font-size: 0.8125rem;
  color: var(--muted);
}
.state-row.ours > div:first-child {
  color: var(--primary);
  font-weight: 600;
}
.browser-frame {
  border: 1px solid var(--line);
  background: var(--bg);
}
.typical-case {
  display: block;
  color: inherit;
  text-decoration: none;
}
.typical-sides {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  padding: 14px;
}
.typical-side {
  margin: 0;
}
.typical-side img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  background: var(--page);
}
.typical-side figcaption {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding-top: 6px;
  font-size: 0.8125rem;
}
@media (max-width: 720px) {
  .typical-sides {
    grid-template-columns: 1fr;
  }
}
.browser-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 14px;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
.browser-bar > span:not(.url) {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--line-strong);
}
.browser-bar .url {
  margin-left: 10px;
  flex: 1;
  font-family: var(--mono);
  font-size: 0.6875rem;
  color: var(--muted);
  background: var(--bg);
  border: 1px solid var(--line);
  padding: 5px 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── cases ────────────────────────────────────────────────────────────── */
body.bare {
  min-height: 0;
}
.cases main.wrap {
  padding-top: 28px;
  padding-bottom: 72px;
}
.cases.embed main.wrap {
  padding-top: 18px;
  padding-bottom: 24px;
}
.side {
  position: sticky;
  top: 76px;
  max-height: calc(100vh - 100px);
  overflow: auto;
  border: 1px solid var(--line);
  background: var(--bg);
}
.cases.embed .side {
  top: 12px;
}
.keys {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 12px;
  font-size: 0.75rem;
  color: var(--muted);
}
.keys dt {
  font-family: var(--mono);
  color: var(--ink);
}
.tag.link {
  color: var(--primary);
}
.stack {
  position: relative;
  background: var(--page);
}
.stack > .pg.under {
  position: absolute;
  inset: 0;
}
.stack > .pg.under ~ .pg.over {
  position: relative;
}
.more {
  margin-top: 26px;
}
.scores {
  margin-top: 36px;
}
.t-row.oracle .strong .mono {
  font-weight: 400;
  font-size: 0.6875rem;
}

/* ── app window ───────────────────────────────────────────────────────── */
.sim-ctl {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.sim-ctl .label {
  margin: 0 4px 0 8px;
}
#sim {
  padding: 9px 16px;
  font-size: 0.8125rem;
  background: var(--deep);
  border-color: var(--deep);
}
#sim.on {
  background: var(--primary);
  border-color: var(--primary);
}
.sim-dot {
  display: inline-block;
  width: 0;
  height: 0;
  border-left: 8px solid var(--on-deep);
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
}
#sim.on .sim-dot {
  border: 0;
  width: 8px;
  height: 8px;
  background: var(--on-deep);
}
.app-window {
  margin-top: 36px;
  background: var(--surface2);
  padding: 40px 24px;
  border: 1px solid var(--line);
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.app-window > .app-bar,
.app-window > .app-body {
  width: 1060px;
  max-width: 100%;
}
.app-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 11px 18px;
  background: var(--deep);
  color: var(--on-deep);
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
}
.app-title {
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-deep);
}
.app-bar .mono {
  color: var(--on-deep-muted);
}
.lights {
  display: flex;
  gap: 8px;
}
.lights > span {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: oklch(69.4% 0.196 26.4);
}
.lights > span:nth-child(2) {
  background: oklch(83.5% 0.161 80.9);
}
.lights > span:nth-child(3) {
  background: oklch(72.8% 0.217 144.7);
}
.app-body {
  display: grid;
  grid-template-columns: minmax(300px, 456px) minmax(0, 1fr);
  background: var(--surface);
  border: 1px solid var(--line);
  border-top: 0;
  box-shadow: 0 24px 60px -30px var(--shadow);
}
.app-left {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.app-hero {
  text-align: center;
  padding: 30px 24px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.app-word {
  font-weight: 700;
  font-size: 1.875rem;
  letter-spacing: -0.03em;
  line-height: 1;
  margin-top: 8px;
}
.app-hero p {
  font-size: 0.875rem;
  color: var(--muted);
  margin-top: 10px;
  line-height: 1.5;
}
.app-sec {
  padding: 16px 32px 0;
}
/* The app window's controls follow the App design, not the Demo's: shorter
   slots with a wider swap column, and the controls' native line height. */
.app-window .slots {
  grid-template-columns: 1fr 48px 1fr;
}
.app-window .slot {
  min-height: 168px;
  padding: 30px 16px;
}
.app-window .slot-label {
  top: 14px;
}
.app-window .swap-btn {
  width: 36px;
  height: 36px;
}
.app-window .field {
  padding: 0 15px;
}
.app-window .field input,
.app-window .app-actions .btn {
  line-height: normal;
}
/* Redline / Convert to PDF: the window's two modes. */
.app-modes {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-bottom: 12px;
}
.app-window .slots.single {
  grid-template-columns: 1fr;
}
.field select {
  flex: 1;
  min-width: 60px;
  padding: 12px 0;
  font-size: 0.875rem;
  background: none;
  border: none;
  outline: none;
  cursor: pointer;
}
/* Two pages a row in the window's preview pane: big enough to read the marks. */
.app-pages {
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  max-height: 560px;
}
.app-window .field-file input {
  font-family: var(--mono);
  font-size: 0.8125rem;
  padding: 11px 0;
}
.app-window .app-right {
  padding: 32px 36px;
}
.app-window .result-file {
  gap: 13px;
}
.app-window .check-ico {
  width: 30px;
  height: 30px;
}
.app-notes {
  margin-top: 40px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}
.app-notes > div {
  padding: 24px 22px 26px;
}
.app-notes .note-title {
  font-size: 0.9375rem;
}
.app-notes .small {
  margin-top: 8px;
}
.app-sec:last-child {
  padding-bottom: 30px;
}
.app-hero + .app-sec {
  padding-top: 22px;
}
.app-sec .field + .app-actions {
  margin-top: 14px;
}
.app-actions + .field {
  margin-top: 10px;
}
.app-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.app-actions > .btn {
  flex: 1 1 auto;
  font-size: 0.8125rem;
  padding: 11px 16px;
}
.app-actions > .btn-cta {
  flex: 1 1 100%;
  padding: 13px 20px;
}
.app-right {
  padding: 26px 28px;
  border-left: 1px solid var(--line);
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: var(--bg);
}
.stale-note {
  margin-top: 12px;
  font-size: 0.8125rem;
  font-weight: 600;
}
.sim-caption {
  position: absolute;
  left: 42px;
  top: 92px;
  z-index: 6;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--deep);
  color: var(--on-deep);
  padding: 16px 20px;
  max-width: min(440px, 88%); /* stays inside the left pane, off the result */
}
.sim-caption .mono {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--on-deep);
  white-space: nowrap;
  padding-top: 4px;
}
.sim-caption > span:last-child {
  font-size: 1.1875rem;
  font-weight: 600;
  line-height: 1.35;
  letter-spacing: -0.01em;
}

/* ── contact ──────────────────────────────────────────────────────────── */
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 520px);
  gap: 56px;
  align-items: start;
}
.contact-grid .cells {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  margin-top: 40px;
}
.contact-grid .cells > .cell-pad {
  padding: 22px 22px 24px;
}
.contact-grid .h1 {
  font-size: clamp(2.125rem, 5vw, 3.5rem);
  letter-spacing: -0.032em;
  line-height: 1.02;
  margin-top: 20px;
}
.contact-grid .lead {
  font-size: 1.125rem;
  line-height: 1.5;
  margin-top: 24px;
  max-width: 50ch;
}
.contact-mail {
  display: inline-block;
  font-size: 1.125rem;
  font-weight: 600;
  margin-top: 10px;
}
.form-card {
  border: 1px solid var(--line);
  background: var(--bg);
  padding: 24px 26px 28px;
}
.form-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 20px;
}
/* Form rows: a label above a bordered control. Not .field, which is the
   app window's inline label-and-input row and strips its input's border. */
.form-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}
.form-field > span:first-child {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}
.form-body legend {
  font-family: var(--mono);
  font-size: 0.6875rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}
.topics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.topic {
  position: relative;
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 11px 10px;
  background: var(--bg);
  color: var(--muted);
  cursor: pointer;
}
.topic input {
  appearance: none;
  width: 10px;
  height: 10px;
  border: 1px solid var(--primary);
  margin: 0;
  flex: none;
}
.topic input:checked {
  background: var(--primary);
}
.topic:has(input:checked) {
  background: var(--hover);
  color: var(--ink);
  border-color: var(--ink);
}
.topic:has(input:focus-visible) {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}
.sent {
  padding: 40px 0 16px;
}

/* ── download ─────────────────────────────────────────────────────────── */
.app-icon {
  width: 168px;
  height: 168px;
  display: block;
}
.app-icon.float {
  animation: jb-float-dl 6s ease-in-out infinite;
}
.whale-float {
  animation: jb-float 5.5s ease-in-out infinite;
}
.whale-float-sm {
  animation: jb-float-sm 5.5s ease-in-out infinite;
}
.cols-auto-300 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}
.dl-cols {
  grid-template-columns: minmax(160px, 1fr) minmax(260px, 2fr) 80px 70px 100px;
}
.dl-cols a.mono {
  font-size: 0.75rem;
  word-break: break-all;
}
.t-row.pending {
  color: var(--muted);
}
.two-col-release {
  display: grid;
  grid-template-columns: minmax(240px, 0.8fr) minmax(0, 1.6fr);
  gap: 48px;
  align-items: start;
}
.releases {
  border-top: 1px solid var(--line);
}
.release {
  display: grid;
  grid-template-columns: 70px 100px minmax(0, 1fr);
  gap: 14px;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  align-items: baseline;
}
.release .mono {
  font-size: 0.75rem;
}

/* ── legal ────────────────────────────────────────────────────────────── */
.legal {
  max-width: 780px;
}
.legal h2 {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 34px 0 10px;
  letter-spacing: -0.01em;
}
.legal p,
.legal li {
  font-size: 0.9375rem;
  line-height: 1.7;
  color: var(--ink);
  margin-bottom: 12px;
  /* 1ch is a Manrope zero, wider than its average letter: 72ch set 94
     characters a line; 56ch sets a median of 72. */
  max-width: 56ch;
}
.legal ul {
  padding-left: 22px;
}
.legal .h1 + .small {
  margin-bottom: 28px;
}

/* ── 429 page ─────────────────────────────────────────────────────────── */
.limit-page {
  padding-top: 96px;
  padding-bottom: 96px;
  max-width: 760px;
}
.limit-page .btn {
  margin-top: 28px;
}

/* ── responsive (the design's data-mq rules) ─────────────────────────── */
@media (max-width: 760px) {
  .wrap {
    padding-left: 18px;
    padding-right: 18px;
  }
  main.wrap {
    padding-top: 36px;
    padding-bottom: 48px;
  }
  .nav-links {
    display: none;
  }
  .nav-menu {
    display: block;
  }
  /* Stacked, the hero ends in the redline paper: the whale moves up behind
     the headline instead. */
  .watermark.hero-mark {
    top: 40px;
    bottom: auto;
    left: -200px;
    width: 520px;
  }
  .m-hide {
    display: none !important;
  }
  .m-show {
    display: block !important;
  }
  .m-stack {
    grid-template-columns: minmax(0, 1fr) !important;
  }
  .m-two {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
  .m-three {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
  }
  /* Three ~100px columns: "WORD · ORACLE" fits on one line with tighter tracking. */
  .strip-col figcaption {
    letter-spacing: 0.02em;
  }
  .m-col {
    flex-direction: column !important;
    align-items: stretch !important;
  }
  .m-tight {
    padding: 14px 10px !important;
  }
  .m-pad {
    padding-left: 18px !important;
    padding-right: 18px !important;
  }
  .paper {
    padding: 24px 20px;
  }
}
.m-show {
  display: none;
}

/* ── responsive, page level ──────────────────────────────────────────── */
@media (max-width: 760px) {
  .hero-grid {
    padding-top: 44px;
    padding-bottom: 40px;
  }
  .band-pad {
    padding-top: 56px;
    padding-bottom: 56px;
  }
  .side {
    position: static;
    max-height: none;
  }
  /* Cases on a phone: the benchmark switch on its own row, then one row of
     filters, scores, prev, random, next (no keyboard, so no key hints), then
     the position. */
  .tb-bench {
    flex: 1 0 100%;
  }
  .tb-nav,
  .tb-views {
    display: contents;
  }
  .tb-views > * {
    order: 1;
  }
  .tb-nav > .chip-btn {
    order: 2;
  }
  .key-hint {
    display: none;
  }
  #toggle-keys {
    display: none;
  }
  #pos {
    order: 3;
    flex: 1 0 100%;
  }
  #pos:empty {
    display: none;
  }
  /* The pages lead; the case's name, tags and links follow them. */
  /* The overlay switch on its own row; a narrower zoom and the page turner
     share the next one. */
  .zoom-row {
    flex: 1 1 0;
    flex-wrap: nowrap;
    min-width: 0;
    gap: 8px;
  }
  .tabs [role="tab"] {
    flex: 1;
    padding-left: 8px;
    padding-right: 8px;
    white-space: normal;
  }
  .app-right {
    border-left: 0;
    border-top: 1px solid var(--line);
  }
  .app-sec {
    padding-left: 18px;
    padding-right: 18px;
  }
  .sim-caption {
    left: 18px;
    right: 18px;
    top: 60px;
  }
  .sim-caption > span:last-child {
    font-size: 1rem;
  }
  .two-col {
    grid-template-columns: 1fr;
  }
  .bar-row {
    grid-template-columns: 110px minmax(0, 1fr) 56px;
  }
  .release {
    grid-template-columns: 60px minmax(0, 1fr);
  }
  .release .small {
    grid-column: 1 / -1;
  }
  .demo-controls,
  .demo-preview {
    padding: 20px 18px 24px;
  }
}
@media (max-width: 1000px) {
  .contact-grid,
  .two-col-release {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The renderer owns its physical paper and scrolls inside the isolated frame. */
.paper.reader-host {
  padding: 0;
  max-height: none;
  overflow: hidden;
  background: transparent;
}

/* ── benchmark: the method grid and the earlier runs ─────────────────── */
/* Five method notes in an auto-fit grid left one alone on its last row, the
   grid's line colour filling the gap. Five lay out as three over two, or
   two by two with the last across, or one column. */
@media (min-width: 960px) {
  .cols-auto-240:has(> :nth-child(5):last-child) {
    grid-template-columns: repeat(6, 1fr);
  }
  .cols-auto-240:has(> :nth-child(5):last-child) > :nth-child(-n + 3) {
    grid-column: span 2;
  }
  .cols-auto-240:has(> :nth-child(5):last-child) > :nth-child(n + 4) {
    grid-column: span 3;
  }
}
@media (min-width: 560px) and (max-width: 959.98px) {
  .cols-auto-240:has(> :nth-child(5):last-child) {
    grid-template-columns: repeat(2, 1fr);
  }
  .cols-auto-240:has(> :nth-child(5):last-child) > :last-child {
    grid-column: 1 / -1;
  }
}

/* The release's own tables lead; the runs on earlier document sets sit
   under one closed disclosure, each table keeping its own stamp. */
.earlier-runs > summary {
  cursor: pointer;
  min-height: 44px;
  align-items: center;
}
.earlier-runs > summary > :first-child::before {
  content: "▸";
  display: inline-block;
  width: 1.1em;
  color: var(--muted);
  font-family: var(--mono);
}
.earlier-runs[open] > summary > :first-child::before {
  content: "▾";
}
.earlier-runs > summary:hover > :first-child {
  color: var(--primary);
}
