/* ============================================================
   Raising Agents — v3 site
   base.css  ·  revised visual system
   2026-05 — replaces placeholder

   Notebook / paper-and-ink register.
   Class names preserved from the placeholder so HTML is portable.
   ============================================================ */

@import url("https://fonts.googleapis.com/css2?family=Source+Serif+4:ital,opsz,wght@0,8..60,400;0,8..60,500;0,8..60,600;0,8..60,700;1,8..60,400;1,8..60,500&family=JetBrains+Mono:wght@400;500;600&display=swap");

:root {
  /* ── paper & ink ──────────────────────────── */
  --paper:        #FAFAF7;     /* workshop near-white (was #F5F1E6) */
  --paper-2:      #EFEAD9;     /* deeper card paper */
  --paper-3:      #E8E1CC;     /* deepest, used rarely */
  --ink:          #1A1812;     /* warm near-black */
  --ink-2:        #46423B;     /* secondary text */
  --ink-3:        #726C5E;     /* muted, kickers, metadata */
  --ink-4:        #8A8275;     /* very muted, captions */
  --rule:         #DCD4BD;     /* primary divider */
  --rule-soft:    #E8E1CC;     /* soft divider */

  /* ── single accent: oxide red ─────────────── */
  --regression:   #9C3A24;     /* FAIL / regression / violation */
  --regression-2: #D67257;     /* lighter wash for backgrounds */
  --regression-wash: rgba(156, 58, 36, 0.07);
  --accent:       var(--regression); /* pen-marks default ink = regression red */

  /* ── semantic pen-mark colors ─────────────── */
  /* Use via data-pm-color="pass|neutral|fail" on any [data-pm] element.  */
  /* Palette: same temperature/saturation as regression, just hue-shifted. */
  --pen-fail:    var(--regression);          /* FAIL / regression (default) */
  --logo-accent: var(--regression);          /* nav mark dot — override per-page */
  --pen-pass:    oklch(0.58 0.09 150);       /* CONFIRMED / contract pass — dusty sage */
  --pen-neutral: oklch(0.52 0.07 244);       /* MEASURED / eval pass (naive) — dusty slate */
  --pen-muted:   var(--ink-3);               /* decorative botanical / background marks */

  /* ── code panel ───────────────────────────── */
  --code-bg:      #1A1812;
  --code-fg:      #E8E2D4;
  --code-dim:     #8E887B;
  --code-mark:    #D6B26B;     /* pale ochre for highlighted code */

  /* ── type stacks ──────────────────────────── */
  --serif: "Source Serif 4", "Source Serif Pro", "Charter",
           "Iowan Old Style", Georgia, serif;
  --sans:  -apple-system, BlinkMacSystemFont, "Inter",
           "Helvetica Neue", Arial, sans-serif;
  --mono:  "JetBrains Mono", "SF Mono", ui-monospace,
           Menlo, Consolas, monospace;

  /* ── layout ───────────────────────────────── */
  --max:          1180px;
  --max-prose:    720px;
  --max-wide:     1280px;
  --px:           clamp(20px, 5vw, 64px);
  --gutter:       clamp(20px, 3vw, 40px);
}

/* ============================================================
   Reset / base
   ============================================================ */

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-rendering: optimizeLegibility;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  font-optical-sizing: auto;
  line-height: 1.55;
  font-feature-settings: "kern", "liga", "calt";
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection { background: var(--ink); color: var(--paper); }

a {
  color: inherit;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  text-decoration-color: var(--ink-3);
  transition: text-decoration-color .15s, color .15s;
}
a:hover { text-decoration-color: var(--ink); }

img, svg { max-width: 100%; display: block; }

/* ============================================================
   Type scale
   ============================================================ */

h1, h2, h3, h4 {
  font-family: var(--serif);
  font-weight: 500;
  letter-spacing: -0.012em;
  line-height: 1.12;
  color: var(--ink);
  text-wrap: balance;
}

h1 {
  font-size: clamp(38px, 5.8vw, 68px);
  font-weight: 500;
  margin: 0 0 28px;
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(26px, 3.1vw, 36px);
  margin: 64px 0 18px;
  letter-spacing: -0.014em;
}

h3 {
  font-size: clamp(20px, 1.6vw, 22px);
  margin: 32px 0 10px;
  line-height: 1.25;
}

h4 {
  font-size: 19px;
  margin: 24px 0 8px;
  line-height: 1.3;
}

p {
  margin: 0 0 18px;
  max-width: 68ch;
  text-wrap: pretty;
}

ul, ol { margin: 0 0 22px; padding-left: 22px; }
ul li, ol li { margin: 8px 0; max-width: 66ch; }
ul li::marker { color: var(--ink-3); }

strong, b { font-weight: 600; color: var(--ink); }
em, i { font-style: italic; }

hr {
  border: none;
  border-top: 1px solid var(--rule);
  margin: 64px 0;
}

/* ============================================================
   Mono kicker — load-bearing across the whole site
   ============================================================ */

.kicker {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 18px;
  display: block;
}

.kicker .sep { color: var(--rule); margin: 0 8px; }
.kicker a { color: var(--ink-3); text-decoration-color: transparent; }
.kicker a:hover { color: var(--ink); text-decoration-color: var(--ink-3); }

/* ============================================================
   Code / mono inline
   ============================================================ */

code, pre, kbd, samp { font-family: var(--mono); font-size: 14px; }

code {
  background: var(--paper-3);
  padding: 1px 6px;
  border-radius: 2px;
  font-size: 0.86em;
  color: var(--ink);
  white-space: nowrap;
}

pre {
  background: var(--code-bg);
  color: var(--code-fg);
  padding: 22px 24px;
  border-radius: 4px;
  overflow-x: auto;
  margin: 22px 0 26px;
  font-size: 13.5px;
  line-height: 1.65;
  font-feature-settings: "calt" 0;
  border: 1px solid #2B271F;
}
pre code {
  background: transparent;
  padding: 0;
  color: inherit;
  font-size: inherit;
  white-space: pre;
}

/* code annotations inside pre */
pre .c-mark { color: var(--code-mark); }
pre .c-dim  { color: var(--code-dim); }
pre .c-fail { color: #E08A6F; }

/* ============================================================
   Blockquote (epigraph register)
   ============================================================ */

blockquote {
  margin: 26px 0;
  padding: 4px 0 6px 22px;
  border-left: 2px solid var(--ink);
  color: var(--ink);
  font-family: var(--serif);
  font-style: italic;
  font-size: 21px;
  line-height: 1.45;
  max-width: 64ch;
}

blockquote.flat {
  border-color: var(--rule);
  font-style: normal;
  font-size: 17px;
  color: var(--ink-2);
}

/* ============================================================
   Header
   ============================================================ */

.site-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 32px;
  padding: 22px var(--px) 20px;
  border-bottom: 1px solid var(--rule);
  background: var(--paper);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: saturate(140%) blur(6px);
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
  letter-spacing: -0.01em;
  text-decoration: none;
  color: var(--ink);
  white-space: nowrap;
}
.site-brand em {
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0;
}
.site-brand-mark {
  display: block;
  flex-shrink: 0;
  width: 24px;
  height: 24px;
}

.site-nav {
  display: flex;
  gap: 26px;
  justify-self: end;
  align-items: center;
}
.site-nav a {
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ink-2);
  text-decoration: none;
  padding: 6px 0;
  letter-spacing: -0.005em;
  position: relative;
}
.site-nav a:hover { color: var(--ink); }
.site-nav a.active {
  color: var(--ink);
  background: rgba(26, 24, 18, 0.07);
  border-radius: 4px;
  padding: 4px 8px;
  margin: -4px -8px;
}
.site-nav a.active::after { display: none; }

.site-cta {
  font-family: var(--sans);
  font-size: 13.5px;
  color: var(--ink);
  text-decoration: none;
  border: 1px solid var(--ink);
  padding: 7px 14px;
  border-radius: 2px;
  white-space: nowrap;
  transition: background .15s, color .15s;
}
.site-cta:hover { background: var(--ink); color: var(--paper); }

.lab-byline {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  color: var(--ink-4);
  margin: -8px 0 24px;
  max-width: none;
  display: block;
}
.lab-byline a {
  color: var(--ink-3);
  text-decoration: none;
}
.lab-byline a:hover { color: var(--ink); }
.lab-byline .sep { color: var(--rule); margin: 0 8px; }

/* ============================================================
   Layout
   ============================================================ */

main {
  padding: 72px var(--px) 120px;
  max-width: var(--max);
  margin: 0 auto;
}
main.prose      { max-width: var(--max-prose); }
main.prose-wide { max-width: 960px; }
main.wide       { max-width: var(--max-wide); }

.section { margin: 0 0 88px; }
.section:last-child { margin-bottom: 0; }

.section-rule {
  border: none;
  border-top: 1px solid var(--rule);
  margin: 0 0 64px;
}

.breadcrumb {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--ink-3);
  margin-bottom: 32px;
}
.breadcrumb a {
  color: var(--ink-3);
  text-decoration-color: transparent;
}
.breadcrumb a:hover { color: var(--ink); text-decoration-color: var(--ink-3); }
.breadcrumb .sep { color: var(--rule); margin: 0 6px; }

/* ============================================================
   Hero
   ============================================================ */

.hero, .page-hero { padding: 16px 0 12px; }

.hero-title, .page-title {
  font-size: clamp(40px, 6.4vw, 76px);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.024em;
  margin: 14px 0 28px;
  max-width: 18ch;
  text-wrap: balance;
}

.hero-lede, .page-lede, .lede {
  font-family: var(--serif);
  font-size: clamp(19px, 1.55vw, 22px);
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 64ch;
  margin: 0 0 32px;
}

.subtitle {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(20px, 1.8vw, 24px);
  color: var(--ink-2);
  line-height: 1.35;
  margin: -14px 0 28px;
  max-width: 56ch;
}

/* ============================================================
   Buttons
   ============================================================ */

.hero-actions, .paper-actions, .page-cta, .actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 28px 0 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--ink);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  text-decoration: none;
  border-radius: 2px;
  transition: background .15s, color .15s, border-color .15s;
  cursor: pointer;
  white-space: nowrap;
}
.btn:hover { background: var(--ink); color: var(--paper); }

.btn-primary {
  background: var(--ink);
  color: var(--paper);
}
.btn-primary:hover { background: #000; }

.btn-ghost {
  border-color: var(--rule);
  color: var(--ink-2);
}
.btn-ghost:hover {
  border-color: var(--ink);
  background: transparent;
  color: var(--ink);
}

/* ============================================================
   Grid components — path-grid, evidence-grid, domain-grid
   ============================================================ */

.path-grid,
.domain-grid,
.evidence-grid,
.what-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 36px var(--gutter);
  margin: 28px 0 0;
}

@media (max-width: 960px) {
  .path-grid, .domain-grid, .evidence-grid, .what-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 640px) {
  .path-grid, .domain-grid, .evidence-grid, .what-grid {
    grid-template-columns: 1fr;
  }
}

.path-card,
.domain-card,
.evidence-card,
.what-card {
  border-top: 1px solid var(--ink);
  padding-top: 18px;
  position: relative;
}

.path-card h2,
.path-card h3,
.domain-card h3,
.what-card h3 {
  margin: 4px 0 12px;
  font-size: 21px;
  font-weight: 500;
}

.path-card h2 a,
.path-card h3 a,
.domain-card h3 a {
  text-decoration: none;
}

.num,
.path-card .num,
.domain-card .num,
.what-card .num {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--ink-3);
  margin: 0;
  text-transform: lowercase;
}

.path-meta, .domain-status {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-3);
  margin: 14px 0 4px;
  line-height: 1.55;
}
.path-link {
  display: inline-block;
  margin-top: 14px;
  font-family: var(--sans);
  font-size: 14px;
}

.path-card p,
.domain-card p,
.evidence-card p,
.what-card p {
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0 0 8px;
}

/* ============================================================
   Evidence cards — big mono numbers
   ============================================================ */

.evidence-card .num.big {
  font-family: var(--mono);
  font-size: clamp(28px, 3.4vw, 40px);
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 16px 0 14px;
  line-height: 1;
  text-transform: none;
}
.evidence-card p {
  font-size: 15.5px;
  line-height: 1.55;
}
.evidence-card p a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid var(--ink-3);
}
.evidence-card p a:hover {
  border-bottom-color: var(--ink);
}

.evidence-link {
  display: inline-block;
  margin-top: 32px;
  font-family: var(--sans);
  font-size: 14px;
}

/* ============================================================
   Paper card (papers index)
   ============================================================ */

.paper-card {
  border-top: 1px solid var(--ink);
  padding-top: 24px;
  margin-bottom: 64px;
}
.paper-card h3 {
  font-size: clamp(26px, 2.6vw, 30px);
  margin: 18px 0 8px;
}
.paper-card h3 a { text-decoration: none; }
.paper-card .subtitle { margin: 0 0 22px; font-size: 19px; }
.paper-card p { max-width: 64ch; }

/* ============================================================
   Thesis block
   ============================================================ */

.thesis { margin: 32px 0; max-width: 70ch; }
.thesis .big,
.thesis-statement {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(24px, 2.6vw, 32px);
  line-height: 1.32;
  color: var(--ink);
  letter-spacing: -0.01em;
  margin: 10px 0 24px;
  max-width: 26ch;
}

/* ============================================================
   Featured demo card (Lab)
   ============================================================ */

.demo-card.featured {
  border-top: 1px solid var(--ink);
  border-bottom: 1px solid var(--ink);
  padding: 22px 0 28px;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: var(--gutter);
}
@media (max-width: 800px) {
  .demo-card.featured { grid-template-columns: 1fr; }
}
.demo-card h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(24px, 2.4vw, 30px);
  letter-spacing: -0.015em;
  line-height: 1.18;
  margin: 4px 0 14px;
  max-width: 22ch;
}
.demo-card h3 a { text-decoration: none; }
.demo-meta {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-3);
  margin: 14px 0 12px;
  letter-spacing: 0.04em;
}
.demo-card .demo-side {
  border-left: 1px solid var(--rule);
  padding-left: var(--gutter);
}
@media (max-width: 800px) {
  .demo-card .demo-side { border-left: none; padding-left: 0; }
}

/* ============================================================
   Data tables — research artifacts
   ============================================================ */

.data-wrap {
  margin: 24px 0 32px;
  overflow-x: auto;
}

table.data {
  border-collapse: collapse;
  width: 100%;
  font-family: var(--mono);
  font-size: 13.5px;
  line-height: 1.5;
  table-layout: auto;
}

table.data thead th {
  font-family: var(--mono);
  font-weight: 500;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  text-align: left;
  padding: 0 14px 12px;
  border-bottom: 1px solid var(--ink);
  white-space: nowrap;
}
table.data thead th.num,
table.data tbody td.num { text-align: right; }

table.data tbody td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--rule-soft);
  vertical-align: middle;
  color: var(--ink-2);
}
table.data tbody td:first-child,
table.data thead th:first-child { padding-left: 0; }
table.data tbody td:last-child,
table.data thead th:last-child { padding-right: 0; }

table.data tbody tr.hi td {
  background: rgba(26, 24, 18, 0.04);
  color: var(--ink);
  font-weight: 600;
  border-bottom-color: var(--ink);
  border-top: 1px solid var(--ink);
}
table.data tbody tr.hi td:first-child {
  position: relative;
}

/* inline F1 bar visualization */
.f1-cell {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
}
.f1-bar {
  display: inline-block;
  width: 64px;
  height: 6px;
  background: var(--rule-soft);
  position: relative;
  border-radius: 1px;
}
.f1-bar::after {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: var(--w, 0%);
  background: var(--ink-3);
}
tr.hi .f1-bar::after { background: var(--ink); }

.tabular { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }

/* small caption under tables */
.data-caption {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  margin-top: 8px;
}

/* ============================================================
   Trace diff — the headline visual on /lab/opbr.html
   ============================================================ */

.trace-diff {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  margin: 32px 0 24px;
  border: 1px solid var(--rule);
  background: var(--paper-2);
  border-radius: 4px;
  overflow: hidden;
}
@media (max-width: 800px) {
  .trace-diff { grid-template-columns: 1fr; }
}

.trace-col {
  padding: 24px 26px 26px;
  border-right: 1px solid var(--rule);
  background: var(--paper-2);
  position: relative;
}
.trace-col:last-child { border-right: none; }
@media (max-width: 800px) {
  .trace-col { border-right: none; border-bottom: 1px solid var(--rule); }
  .trace-col:last-child { border-bottom: none; }
}

.trace-col.regression {
  background:
    linear-gradient(to right, var(--regression-wash), transparent 6px),
    var(--paper-2);
}

.trace-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--rule);
}
.trace-label {
  font-family: var(--serif);
  font-size: 17px;
  font-weight: 500;
  color: var(--ink);
}
.trace-tag {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.trace-col.regression .trace-tag { color: var(--regression); }

.trace-step {
  display: grid;
  grid-template-columns: 28px 18px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
  font-family: var(--mono);
  font-size: 13.5px;
  line-height: 1.4;
  position: relative;
}

.trace-step .step-n {
  color: var(--ink-4);
  font-size: 11px;
  letter-spacing: 0.04em;
  text-align: right;
  padding-right: 4px;
}

/* markers: open circle = precondition; filled square = consequential commit */
.trace-step .marker {
  width: 9px;
  height: 9px;
  border: 1.5px solid var(--ink-3);
  border-radius: 50%;
  background: transparent;
  justify-self: center;
}
.trace-step.consequential .marker {
  width: 10px;
  height: 10px;
  border: 0;
  background: var(--ink);
  border-radius: 1px;
}
.trace-col.regression .trace-step.consequential .marker {
  background: var(--regression);
}
.trace-step.entry .marker,
.trace-step.exit .marker {
  border: none;
  background: var(--ink-4);
  width: 5px;
  height: 5px;
  border-radius: 50%;
}

.trace-step .tool {
  color: var(--ink);
  letter-spacing: -0.005em;
}
.trace-step .result {
  color: var(--ink-3);
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: lowercase;
}
.trace-step .result.success { color: var(--ink-2); }

.trace-step.consequential .tool { font-weight: 600; }
.trace-col.regression .trace-step.consequential .tool { color: var(--regression); }
.trace-col.regression .trace-step.consequential::before {
  content: "";
  position: absolute;
  left: -26px;
  top: 0;
  bottom: -8px;
  width: 2px;
  background: var(--regression);
}
/* violation span: from the consequential step down through unmet preconditions */
.trace-col.regression .trace-step.in-violation::before {
  content: "";
  position: absolute;
  left: -26px;
  top: -8px;
  bottom: 0;
  width: 2px;
  background: var(--regression);
  opacity: 0.4;
}

.trace-verdict {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.03em;
  line-height: 1.7;
  color: var(--ink-3);
}
.trace-verdict .v-row { display: flex; gap: 14px; }
.trace-verdict .v-label { color: var(--ink-3); min-width: 96px; }
.trace-verdict .v-pass { color: var(--ink); font-weight: 600; }
.trace-verdict .v-fail { color: var(--regression); font-weight: 600; }

/* footer of the diff: explainer */
.trace-foot {
  grid-column: 1 / -1;
  background: var(--paper);
  border-top: 1px solid var(--rule);
  padding: 16px 26px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--ink-3);
  display: flex;
  gap: 26px;
  flex-wrap: wrap;
  align-items: center;
}
.trace-foot .legend-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.trace-foot .leg-marker {
  display: inline-block;
  width: 9px; height: 9px;
  border: 1.5px solid var(--ink-3);
  border-radius: 50%;
}
.trace-foot .leg-marker.consequential {
  background: var(--ink);
  border: none;
  border-radius: 1px;
  width: 10px; height: 10px;
}
.trace-foot .leg-marker.regression {
  background: var(--regression);
  border: none;
  border-radius: 1px;
  width: 10px; height: 10px;
}

/* ============================================================
   Verdict pills (inline status)
   ============================================================ */

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 3px 8px;
  border: 1px solid var(--ink);
  border-radius: 2px;
  color: var(--ink);
  background: var(--paper);
  white-space: nowrap;
}
.pill.pass { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.pill.fail { background: var(--regression); color: var(--paper); border-color: var(--regression); }
.pill.warn { background: var(--paper); color: var(--ink); }
.pill.muted { color: var(--ink-3); border-color: var(--rule); }

/* ============================================================
   Subscribe form
   ============================================================ */

.subscribe-form { max-width: 520px; margin-top: 8px; }
.subscribe-form label {
  display: block;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}
.subscribe-row { display: flex; gap: 8px; }
.subscribe-row input {
  flex: 1;
  border: 1px solid var(--ink);
  background: var(--paper);
  padding: 11px 14px;
  font: inherit;
  font-family: var(--sans);
  font-size: 14.5px;
  border-radius: 2px;
  color: var(--ink);
}
.subscribe-row input::placeholder { color: var(--ink-4); }
.subscribe-row input:focus {
  outline: 2px solid var(--ink);
  outline-offset: 1px;
}
.subscribe-row button {
  background: var(--ink);
  color: var(--paper);
  border: 1px solid var(--ink);
  padding: 11px 18px;
  font-family: var(--sans);
  font-size: 14.5px;
  border-radius: 2px;
  cursor: pointer;
  white-space: nowrap;
}
.subscribe-row button:hover { background: #000; }
.subscribe-meta {
  font-family: var(--sans);
  font-size: 13.5px;
  color: var(--ink-3);
  margin-top: 10px;
  max-width: 60ch;
}

/* ============================================================
   Curriculum / lifecycle / issue lists
   ============================================================ */

.curriculum, .lifecycle, .issue-list, .feature-list {
  list-style: none;
  padding: 0;
  margin: 24px 0 0;
}
.curriculum li, .lifecycle li, .issue-list li, .feature-list li {
  border-top: 1px solid var(--rule);
  padding: 22px 0 24px;
  max-width: none;
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 28px;
}
.curriculum li:last-child, .lifecycle li:last-child { border-bottom: 1px solid var(--rule); }
.curriculum .module,
.lifecycle .step,
.issue-list .label,
.feature-list .label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  padding-top: 2px;
}
.curriculum h3,
.lifecycle h3,
.issue-list h3,
.feature-list h3 {
  margin: 0 0 8px;
  font-size: 20px;
  font-weight: 500;
}
.curriculum p,
.lifecycle p,
.issue-list p,
.feature-list p {
  margin: 0;
  color: var(--ink-2);
  font-size: 16px;
}

@media (max-width: 640px) {
  .curriculum li, .lifecycle li, .issue-list li, .feature-list li {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

/* ============================================================
   Status note (sidebar callout)
   ============================================================ */

.status-note {
  background: var(--paper-2);
  border-left: 2px solid var(--ink);
  padding: 16px 20px;
  font-size: 15.5px;
  line-height: 1.5;
  color: var(--ink-2);
  max-width: 64ch;
  margin: 24px 0;
}
.status-note strong { color: var(--ink); }
.status-note code {
  background: var(--paper-3);
  font-size: 12.5px;
}

/* ============================================================
   "What this is" mini block, prereqs, etc.
   ============================================================ */

.prereq-list { padding-left: 22px; }
.prereq-list li { max-width: 66ch; }

.empty-archive {
  color: var(--ink-3);
  font-style: italic;
  font-family: var(--serif);
  max-width: 64ch;
}

/* ============================================================
   "Next" label
   ============================================================ */

.next {
  font-family: var(--mono);
  font-size: 13px;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
}
.next a { color: var(--ink); }

/* ============================================================
   Watch strip (homepage)
   ============================================================ */

.watch-strip {
  background: var(--paper-2);
  border-top: 1px solid var(--rule);
  border-bottom: 1px solid var(--rule);
  margin: 0 calc(-1 * var(--px));
  padding: 64px var(--px);
}
.watch-strip .watch-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: var(--gutter);
}
@media (max-width: 800px) {
  .watch-strip .watch-inner { grid-template-columns: 1fr; }
}
.watch-strip h2 { margin: 6px 0 14px; }

/* ============================================================
   Footer
   ============================================================ */

.site-footer {
  border-top: 1px solid var(--rule);
  padding: 56px var(--px) 64px;
  background: var(--paper);
  margin-top: 0;
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 2fr 1fr;
  gap: var(--gutter);
  align-items: start;
}
@media (max-width: 800px) {
  .footer-inner { grid-template-columns: 1fr; gap: 36px; }
}
.footer-brand {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
  color: var(--ink);
  margin-bottom: 12px;
  text-decoration: none;
  display: inline-block;
}
.footer-brand em { font-style: italic; font-weight: 400; }
.footer-tagline {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  max-width: 36ch;
  line-height: 1.6;
}
.footer-tagline code {
  color: var(--regression);
  background: none;
  font-size: inherit;
  letter-spacing: inherit;
}

/* ── pm-think: inline handwritten thought-note ────────────── */
/* Caveat italic aside, sits in document flow like a margin idea. */
.pm-think {
  display: block;
  font-family: "Caveat", cursive;
  font-size: 18px;
  font-weight: 500;
  color: var(--ink-3);
  line-height: 1.3;
  margin: 10px 0 6px;
  transform: rotate(-0.6deg);
  transform-origin: left center;
  opacity: 0.85;
  pointer-events: none;
}
.pm-think code {
  color: var(--regression);
  font-family: "Caveat", cursive;
  font-size: inherit;
  background: none;
  font-weight: 600;
}
.footer-nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 28px;
}
.footer-nav .col {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.footer-nav .col-label {
  font-family: var(--mono);
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-4);
  margin-bottom: 6px;
}
.footer-nav a {
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ink-2);
  text-decoration: none;
}
.footer-nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.footer-legal {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  line-height: 1.7;
}

/* ============================================================
   Designer-overview specific
   ============================================================ */

.swatch-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
  margin: 22px 0 12px;
}
@media (max-width: 720px) { .swatch-grid { grid-template-columns: repeat(3, 1fr); } }
.swatch {
  border: 1px solid var(--rule);
  border-radius: 3px;
  overflow: hidden;
  background: var(--paper);
}
.swatch .chip { height: 84px; }
.swatch .meta {
  padding: 10px 12px 12px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.02em;
  color: var(--ink-3);
  line-height: 1.5;
}
.swatch .meta b { color: var(--ink); font-weight: 600; }

.type-row {
  border-top: 1px solid var(--rule);
  padding: 22px 0 28px;
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 24px;
  align-items: baseline;
}
.type-row .label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.type-row .specimen { color: var(--ink); }

.wordmark-demo {
  font-family: var(--serif);
  font-size: clamp(48px, 7vw, 96px);
  font-weight: 500;
  letter-spacing: -0.018em;
  color: var(--ink);
  line-height: 1;
  margin: 24px 0;
}
.wordmark-demo em { font-style: italic; font-weight: 400; letter-spacing: 0; }

.wordmark-small {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 500;
  letter-spacing: -0.01em;
}
.wordmark-small em { font-style: italic; font-weight: 400; }

.spec-card {
  border-top: 1px solid var(--ink);
  padding-top: 18px;
}
.spec-card .label {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 8px;
}

/* ============================================================
   Mobile navigation — hamburger + overlay
   ============================================================ */

.nav-hamburger {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 6px;
  flex-direction: column;
  gap: 5px;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
}
.nav-hamburger span {
  display: block;
  width: 20px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.22s ease, opacity 0.22s ease;
  transform-origin: center;
}
@media (max-width: 800px) {
  .nav-hamburger { display: flex; }
  .site-header.nav-open .nav-hamburger span:nth-child(1) {
    transform: translateY(6.5px) rotate(45deg);
  }
  .site-header.nav-open .nav-hamburger span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
  }
  .site-header.nav-open .nav-hamburger span:nth-child(3) {
    transform: translateY(-6.5px) rotate(-45deg);
  }
}

.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--paper);
  z-index: 49;
  padding: 72px var(--px) 48px;
  flex-direction: column;
  overflow-y: auto;
}
@media (max-width: 800px) {
  body.nav-open .nav-overlay { display: flex; }
  body.nav-open { overflow: hidden; }
}
.nav-overlay a {
  font-family: var(--serif);
  font-size: clamp(26px, 5.5vw, 38px);
  font-weight: 400;
  letter-spacing: -0.01em;
  color: var(--ink-2);
  text-decoration: none;
  padding: 18px 0;
  border-bottom: 1px solid var(--rule);
  transition: color 0.15s;
  display: block;
}
.nav-overlay a:first-child { border-top: 1px solid var(--rule); }
.nav-overlay a:hover { color: var(--ink); }
.nav-overlay a.active { color: var(--ink); font-style: italic; }
.nav-overlay .nav-overlay-cta {
  margin-top: 32px;
  font-family: var(--sans);
  font-size: 14px;
  color: var(--ink);
  border: 1px solid var(--ink);
  padding: 12px 18px;
  border-radius: 2px;
  text-align: center;
  text-decoration: none;
  display: block;
  transition: background 0.15s, color 0.15s;
}
.nav-overlay .nav-overlay-cta:hover {
  background: var(--ink);
  color: var(--paper);
}

/* ============================================================
   Responsive
   ============================================================ */

@media (max-width: 800px) {
  body { font-size: 17px; }
  .site-header { grid-template-columns: 1fr; gap: 12px; padding: 14px var(--px); }
  .site-nav { display: none; }
  .site-cta { display: none; }
  main { padding: 48px var(--px) 80px; }
  .section { margin-bottom: 64px; }
  blockquote { font-size: 18px; }
}

/* keyboard focus — visible ring for keyboard users, hidden for mouse */
:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}
:focus:not(:focus-visible) { outline: none; }

/* print: keep it clean */
@media print {
  .site-header, .site-footer, .actions, .hero-actions { display: none; }
  body { background: white; color: black; }
  pre { background: #1A1812; }
}
