/* ============================================================
 * FIELDNOTE — the blog design language for useagency.dev
 * ------------------------------------------------------------
 * Every rule is scoped under ``.fieldnote`` so a post document can be
 * rendered INSIDE the app shell (marketing layout, real nav/footer)
 * without its base styles leaking onto the surrounding chrome. Token
 * blocks (:root/.dark) stay global — they are variables only.
 *
 * Extends marketing-v2 (the approved loop-engineering homepage,
 * PR #400) to long-form posts and use-case pages:
 *   - Pine palette: sage/paper ground, deep-pine panels, lime
 *     #C9FF3D accent (olive #41610B carries it on light ground)
 *   - Plus Jakarta Sans headlines; JetBrains Mono for eyebrows,
 *     section numbers, traces, and every measured value
 *   - Figures live on the homepage's #0E1712 panels (18px radius,
 *     #ffffff22 hairlines) — constant across both themes
 *   - Series colors are the app's --chart-* tokens, CVD-ordered:
 *     lime (agent) -> blue (studio) -> amber -> green
 *   - Theme: the app's .dark class; posts run the same bootstrap
 *     script the app ships (see _template.html)
 *
 * Living spec with component specimens and the legacy coverage
 * map: /blog/design-language (src/content/blog/_design-language.html).
 * Post skeleton: src/content/blog/_template.html.
 * ============================================================ */

/* ---- fonts — self-hosted latin variable subsets ---- */
@font-face {
  font-family: "Plus Jakarta Sans";
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url("/fonts/plus-jakarta-sans-latin-var.woff2") format("woff2");
}
@font-face {
  font-family: "JetBrains Mono";
  font-style: normal;
  font-weight: 100 800;
  font-display: swap;
  src: url("/fonts/jetbrains-mono-latin-var.woff2") format("woff2");
}

/* ---- tokens ----
 * Scoped to .fieldnote, not :root. Three of these names (--muted,
 * --accent, --card) also exist in the app's design system with
 * different meanings, so declaring them globally repainted the site
 * chrome on any page that loads this file — the nav's bg-muted pill
 * turned into fieldnote's muted *text* colour.
 */
.fieldnote {
  /* ground - light (mv2 light theme) */
  --bg: #f7faf1;
  --well: #f0f4ea;
  --ink: #101a12;
  --body: #4e5d54;
  --muted: #5f6f64;
  --line: #101a1220;
  --accent: #41610b;
  --accent-strong: #c9ff3d;
  --accent-text: #101a08;
  --hl-bg: #c9ff3d;
  --hl-ink: #101a08;
  --card: #ffffff;

  /* deterministic layer - constant in both themes (mv2 --panel) */
  --panel: #0e1712;
  --panel-mid: #142018;
  --panel-line: #ffffff22;
  --panel-grid: #ffffff14;
  --panel-ink: #f2f4ee;
  --panel-dim: #8a938b;

  /* series - the app's chart tokens, CVD-safe order */
  --s1: #c9ff3d; /* lime  - the agent  */
  --s2: #5fa8e8; /* blue  - the studio */
  --s3: #f5c13d; /* amber - third      */
  --s4: #4ade97; /* green - fourth     */
  --s2-band: rgba(95, 168, 232, 0.16);

  /* status - the mv2 trace colors; always icon + word */
  --ok: #7fc79a;
  --bad: #e8907f;
  --review: #f5c13d;

  --sans: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
}
.dark .fieldnote,
.fieldnote.dark {
  --bg: #08130f;
  --well: #12211b;
  --ink: #f1f6ee;
  --body: #9fb3a6;
  --muted: #9fb3a6;
  --line: #ffffff14;
  --accent: #c9ff3d;
  --hl-bg: transparent;
  --hl-ink: #c9ff3d;
  --card: #0e1712;
}

/* ---- base ---- */
.fieldnote * { box-sizing: border-box; }
html { scroll-behavior: smooth; }
.fieldnote {
  color: var(--body);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.7;
  padding: 0 24px 96px;
}

/* A document that ends on the full-bleed CTA band must not keep the
 * wrapper's bottom padding, or a strip of page ground shows between the
 * band and the site footer. Posts, which end in prose, keep it. */
.fieldnote:has(footer.uc) { padding-bottom: 0; }

/* Links to posts whose release day has not arrived. The route handler
 * strips the href and marks them; the affordance lives here rather than
 * in an injected <style>, because the page hosts a document's <body>
 * only — anything appended to </head> never reaches the browser. */
.fieldnote a[data-unpublished] { pointer-events: none; cursor: default; opacity: 0.55; }
.fieldnote a[data-unpublished] small::after { content: " · coming soon"; }
.fieldnote a[data-unpublished] .meta::after { content: " · coming soon"; }

/* `main` in a standalone file; `.doc` once hosted, where the layout owns
 * the <main> landmark and this element is demoted (see document.ts). Both
 * must keep the measure, the centring and the section counter. */
.fieldnote :is(main, .doc) { max-width: 720px; margin: 0 auto; counter-reset: sec; }
.fieldnote a {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-color: var(--line);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  border-radius: 2px;
  transition: text-decoration-color 0.2s;
}
.fieldnote a:hover { text-decoration-color: var(--accent); }
.fieldnote a:focus-visible, .fieldnote summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  .fieldnote * { transition: none !important; animation: none !important; }
}

/* ================= C1 - post header ================= */
.fieldnote header.post, .fieldnote header.uc { padding: 76px 0 12px; }
.fieldnote .eye {
  font: 500 11px var(--mono);
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink);
  opacity: 0.58;
  margin: 0 0 26px;
}
.fieldnote h1 {
  font-size: clamp(40px, 6.4vw, 66px);
  font-weight: 600;
  line-height: 0.95;
  letter-spacing: -0.05em;
  color: var(--ink);
  margin: 0 0 22px;
  text-wrap: balance;
}
.fieldnote .standfirst {
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 1.55;
  color: var(--muted);
  margin: 0 0 22px;
  max-width: 570px;
  text-wrap: pretty;
}
.fieldnote .proofline {
  font: 500 10.5px var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 26px;
}
.fieldnote .byline {
  font: 400 12px var(--mono);
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

/* ================= C17 - header banner ================= */
.fieldnote figure.hero {
  width: min(940px, calc(100vw - 48px));
  margin: 30px 0 0 50%;
  transform: translateX(-50%);
  background: var(--panel);
  border: 1px solid var(--panel-line);
  border-radius: 18px;
  overflow: hidden;
}
.fieldnote figure.hero svg, .fieldnote figure.hero img { display: block; width: 100%; height: auto; }
.fieldnote figure.hero img.pixel { image-rendering: pixelated; }

/* ================= C2 - prose ================= */
.fieldnote h2 {
  counter-increment: sec;
  font-size: clamp(28px, 3.8vw, 40px);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -0.045em;
  color: var(--ink);
  margin: 72px 0 18px;
  text-wrap: balance;
}
/* The closing call to action is not a numbered section of the argument. */
.fieldnote footer h2 { counter-increment: none; }
.fieldnote footer h2::before { content: none; }
.fieldnote h2::before {
  content: counter(sec, decimal-leading-zero) " /";
  display: block;
  font: 500 10.5px var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink);
  opacity: 0.46;
  margin-bottom: 14px;
}
.fieldnote .mline {
  font: 500 12px var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 34px 0 10px;
}
.fieldnote h3 { font-size: 19px; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); margin: 32px 0 10px; }
.fieldnote p { margin: 0 0 18px; max-width: 640px; }
.fieldnote .lead { font-size: 19px; line-height: 1.6; }
.fieldnote .punch { font-weight: 600; color: var(--ink); max-width: 620px; }
.fieldnote strong { color: var(--ink); font-weight: 600; }
.fieldnote ol { padding-left: 22px; margin: 0 0 18px; }
.fieldnote ol li { margin-bottom: 8px; max-width: 600px; }
.fieldnote ul { list-style: none; padding: 0; margin: 22px 0; max-width: 640px; }
.fieldnote ul li { padding: 10px 0; margin: 0; border-top: 1px solid var(--line); }
.fieldnote ul li:last-child { border-bottom: 1px solid var(--line); }
.fieldnote ul li b { color: var(--ink); font-weight: 600; }
.fieldnote code {
  font-family: var(--mono);
  font-size: 0.82em;
  background: var(--well);
  color: var(--ink);
  padding: 0.125rem 0.375rem;
  border-radius: 0.375rem;
}

/* ================= C3 - quotes ================= */
.fieldnote blockquote { margin: 26px 0; padding: 2px 0 2px 22px; border-left: 2px solid var(--accent); max-width: 560px; }
.fieldnote blockquote p { margin: 0 0 6px; font-size: 18px; color: var(--ink); }
.fieldnote blockquote cite { font: 400 11.5px var(--mono); font-style: normal; letter-spacing: 0.04em; color: var(--muted); }
.fieldnote .pull {
  margin: 44px 0;
  font-size: clamp(24px, 3.2vw, 34px);
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.04em;
  color: var(--ink);
  max-width: 22ch;
  text-wrap: balance;
}
.fieldnote .pull b { font-weight: inherit; background: var(--hl-bg); color: var(--hl-ink); padding: 0 0.12em; }

/* ================= C4 - callout ================= */
.fieldnote .callout { margin: 26px 0; padding: 20px 24px; background: var(--well); border-radius: 16px; max-width: 640px; }
.fieldnote .callout .callout-tag {
  font: 500 10.5px var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  display: block;
  margin-bottom: 8px;
}
.fieldnote .callout p { max-width: none; }
.fieldnote .callout p:last-child { margin-bottom: 0; }
.fieldnote ul.callouts { border: none; max-width: 640px; }
.fieldnote ul.callouts li { display: flex; gap: 16px; align-items: baseline; padding: 12px 0; }
.fieldnote ul.callouts b {
  font: 500 10.5px var(--mono);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent);
  white-space: nowrap;
}

/* ================= C6 - the instrument panel ================= */
.fieldnote figure.panel {
  margin: 32px 0;
  background: var(--panel);
  border: 1px solid var(--panel-line);
  border-radius: 18px;
  padding: 24px 28px 20px;
  color: var(--panel-ink);
  font-family: var(--mono);
}
.fieldnote figure.panel.wide { width: min(940px, calc(100vw - 48px)); margin-left: 50%; transform: translateX(-50%); }
.fieldnote .panel-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font: 500 10px var(--mono);
  letter-spacing: 0.13em;
  text-transform: uppercase;
  margin-bottom: 18px;
}
.fieldnote .panel-head .fig { color: var(--s1); }
.fieldnote .panel-head .ctx { color: var(--panel-dim); }
.fieldnote .panel-title { font: 600 13.5px var(--mono); color: var(--panel-ink); margin: -8px 0 18px; }
.fieldnote figure.panel figcaption {
  font: 400 11.5px/1.7 var(--mono);
  color: var(--panel-dim);
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--panel-grid);
}
.fieldnote figure.panel figcaption b { color: var(--panel-ink); font-weight: 500; }
.fieldnote figure.panel code { background: var(--panel-mid); color: var(--panel-ink); }
.fieldnote .scroll { overflow-x: auto; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, 0.2) transparent; }

/* ================= C5 - stat row ================= */
.fieldnote .stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 2px; }
.fieldnote .stat { background: var(--panel-mid); border-radius: 10px; padding: 16px 16px 13px; }
.fieldnote .stat b {
  display: block;
  font-size: 26px;
  font-weight: 600;
  color: var(--s1);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
  font-family: var(--sans);
}
.fieldnote .stat span { font-size: 10.5px; color: var(--panel-dim); line-height: 1.5; display: block; margin-top: 5px; letter-spacing: 0.04em; }
/* semantic stat colors: caught = bad, iterations = review, shipped = ok */
.fieldnote .stat.bad b { color: var(--bad); }
.fieldnote .stat.review b { color: var(--review); }
.fieldnote .stat.info b { color: var(--s2); }
.fieldnote .stat.ok b { color: var(--ok); }

/* ================= C10 - chips & legend ================= */
.fieldnote .legend { display: flex; gap: 18px; flex-wrap: wrap; font-size: 11px; color: var(--panel-dim); margin: 0 0 16px; }
.fieldnote .legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.fieldnote .chip {
  display: inline-block;
  font-size: 10.5px;
  letter-spacing: 0.04em;
  border: 1px solid var(--panel-line);
  border-radius: 999px;
  padding: 2px 10px;
  color: var(--panel-dim);
  margin: 0 4px 4px 0;
}
.fieldnote .chip.status { border: none; font-weight: 500; padding-left: 9px; }
.fieldnote .chip.ok { background: rgba(127, 199, 154, 0.14); color: var(--ok); }
.fieldnote .chip.review { background: rgba(245, 193, 61, 0.13); color: var(--review); }
.fieldnote .chip.bad { background: rgba(232, 144, 127, 0.14); color: var(--bad); }
.fieldnote .chip.ok::before { content: "✓ "; }
.fieldnote .chip.bad::before { content: "✕ "; }
.fieldnote .chip.review::before { content: "◔ "; }

/* ================= C7 - bar chart ================= */
.fieldnote .plot {
  position: relative;
  height: 190px;
  display: grid;
  grid-auto-flow: column;
  align-items: end;
  gap: 22px;
  padding: 0 6px;
  border-bottom: 1px solid var(--panel-line);
  background: repeating-linear-gradient(to top, transparent 0 47px, var(--panel-grid) 47px 48px);
}
.fieldnote .grp { display: flex; align-items: flex-end; gap: 2px; height: 100%; }
.fieldnote .bar { flex: 1 1 24px; min-width: 14px; max-width: 36px; background: var(--s1); border-radius: 4px 4px 0 0; position: relative; }
.fieldnote .bar.s2 { background: var(--s2); }
.fieldnote .bar.s3 { background: var(--s3); }
.fieldnote .bar.s4 { background: var(--s4); }
.fieldnote .bar .v {
  position: absolute;
  top: -18px;
  left: 50%;
  transform: translateX(-50%);
  font-size: 11px;
  color: var(--panel-ink);
  font-variant-numeric: tabular-nums;
  opacity: 0;
  transition: opacity 120ms;
}
.fieldnote .bar:hover .v, .fieldnote .bar.show .v { opacity: 1; }
.fieldnote .refline { position: absolute; left: 0; right: 0; border-top: 1.5px dashed rgba(242, 244, 238, 0.4); }
.fieldnote .reftag {
  position: absolute;
  right: 6px;
  transform: translateY(-125%);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--panel-dim);
  background: var(--panel);
  padding: 0 4px;
  border-radius: 3px;
}
.fieldnote .axis {
  display: grid;
  grid-auto-flow: column;
  gap: 22px;
  padding: 8px 6px 0;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: var(--panel-dim);
  text-align: center;
}

/* ================= C8 - track chart ================= */
.fieldnote .tracks { display: grid; gap: 12px; }
.fieldnote .track { display: grid; grid-template-columns: 150px 1fr; gap: 12px; align-items: center; }
.fieldnote .track .feat { font-size: 11px; color: var(--panel-dim); letter-spacing: 0.04em; }
.fieldnote .rail { position: relative; height: 22px; background: var(--panel-mid); border-radius: 8px; }
.fieldnote .band { position: absolute; top: 3px; bottom: 3px; background: var(--s2-band); border: 1px solid var(--s2); border-radius: 6px; }
.fieldnote .dot {
  position: absolute;
  top: 50%;
  width: 10px;
  height: 10px;
  transform: translate(-50%, -50%);
  background: var(--s1);
  border-radius: 50%;
  box-shadow: 0 0 0 2px var(--panel);
}
.fieldnote .dot.out { background: var(--bad); }
.fieldnote .dot.out::after {
  content: "out of band";
  position: absolute;
  left: 14px;
  top: -2px;
  font-size: 10px;
  color: var(--bad);
  white-space: nowrap;
}

/* ================= C9 - data table ================= */
.fieldnote table.data { border-collapse: collapse; width: 100%; font-size: 12.5px; }
.fieldnote table.data th, .fieldnote table.data td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--panel-grid);
  font-variant-numeric: tabular-nums;
}
.fieldnote table.data th { font-size: 10px; letter-spacing: 0.13em; text-transform: uppercase; color: var(--panel-dim); font-weight: 500; }
.fieldnote table.data td { color: var(--panel-ink); }
.fieldnote table.data tr:last-child td { border-bottom: none; }
.fieldnote table.data .num { text-align: right; }
.fieldnote details.tbl summary { cursor: pointer; font-size: 11.5px; color: var(--panel-dim); padding: 10px 0 2px; list-style: none; }
.fieldnote details.tbl summary::before { content: "▸ "; color: var(--s1); }
.fieldnote details.tbl[open] summary::before { content: "▾ "; }

/* ================= C16 - run trace (the mv2 signature) ================= */
.fieldnote .trace { font: 400 12.5px/2.1 var(--mono); }
.fieldnote .trace .row { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fieldnote .trace .k { display: inline-block; width: 7.5em; color: var(--s1); }
.fieldnote .trace .r { color: var(--panel-ink); }
.fieldnote .trace .dim { color: var(--panel-dim); }
.fieldnote .trace .ok { color: var(--ok); }
.fieldnote .trace .bad { color: var(--bad); }

/* ================= C11 - process strip ================= */
.fieldnote .flow { display: flex; flex-wrap: wrap; gap: 26px 30px; }
.fieldnote .flow .step { position: relative; flex: 1 1 140px; min-width: 130px; background: var(--panel-mid); border-radius: 10px; padding: 14px 16px; }
.fieldnote .flow .step b {
  display: block;
  font: 500 10.5px var(--mono);
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--s1);
  margin-bottom: 6px;
}
.fieldnote .flow .step span { font-size: 11px; color: var(--panel-dim); line-height: 1.55; display: block; }
.fieldnote .flow .step:not(:last-child)::after {
  content: "→";
  position: absolute;
  right: -23px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--panel-dim);
  font-size: 14px;
}
.fieldnote .flow.loop .step:last-child::after {
  content: "⟲";
  position: absolute;
  right: -23px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--s1);
  font-size: 15px;
}
/* color-keyed loop stages */
.fieldnote .flow .step.k1 { box-shadow: inset 0 2px 0 var(--s1); }
.fieldnote .flow .step.k1 b { color: var(--s1); }
.fieldnote .flow .step.k2 { box-shadow: inset 0 2px 0 var(--s2); }
.fieldnote .flow .step.k2 b { color: var(--s2); }
.fieldnote .flow .step.k3 { box-shadow: inset 0 2px 0 var(--s3); }
.fieldnote .flow .step.k3 b { color: var(--s3); }
.fieldnote .flow .step.k4 { box-shadow: inset 0 2px 0 var(--s4); }
.fieldnote .flow .step.k4 b { color: var(--s4); }

/* ================= C12 - layer stack ================= */
.fieldnote .stack { display: grid; gap: 2px; }
.fieldnote .stack .layer {
  display: grid;
  grid-template-columns: 34px 1fr auto;
  gap: 12px;
  align-items: baseline;
  background: var(--panel-mid);
  border-radius: 10px;
  padding: 13px 16px;
}
.fieldnote .stack .layer .no { font-size: 10.5px; color: var(--panel-dim); letter-spacing: 0.1em; }
/* Card, layer and author titles are component labels, not sections of
 * the document. As <h4> they injected 33 entries into the heading
 * outline and produced h2 -> h4 skips on every content page; as <p> they
 * style identically and leave the outline to real section headings. */
.fieldnote .stack .layer :is(h4, .h4) { margin: 0; font: 600 12.5px var(--mono); color: var(--panel-ink); }
.fieldnote .stack .layer p { margin: 4px 0 0; font-size: 11px; color: var(--panel-dim); max-width: none; line-height: 1.55; }
.fieldnote .stack .layer .measure {
  font-size: 10px;
  letter-spacing: 0.05em;
  color: var(--panel-dim);
  border: 1px solid var(--panel-line);
  border-radius: 999px;
  padding: 2px 9px;
  white-space: nowrap;
}
.fieldnote .stack .layer.kept { box-shadow: inset 2px 0 0 var(--ok); }
.fieldnote .stack .layer.lost { box-shadow: inset 2px 0 0 var(--bad); opacity: 0.72; }

/* ================= C13 - card grid ================= */
.fieldnote .cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(185px, 1fr)); gap: 2px; counter-reset: card; }
.fieldnote .card { background: var(--panel-mid); border-radius: 10px; padding: 16px; }
.fieldnote .card :is(h4, .h4) { margin: 0 0 6px; font: 600 12.5px var(--mono); color: var(--panel-ink); }
.fieldnote .card p { margin: 0; font-size: 11.5px; line-height: 1.6; color: var(--panel-dim); max-width: none; }
.fieldnote .cards.numbered .card::before {
  counter-increment: card;
  content: counter(card, decimal-leading-zero);
  display: block;
  font-size: 10px;
  letter-spacing: 0.13em;
  color: var(--panel-dim);
  margin-bottom: 10px;
  font-family: var(--mono);
}
.fieldnote .cards.numbered .card:nth-child(1)::before { color: var(--s1); }
.fieldnote .cards.numbered .card:nth-child(2)::before { color: var(--s2); }
.fieldnote .cards.numbered .card:nth-child(3)::before { color: var(--s3); }
.fieldnote .card.win { box-shadow: inset 0 2px 0 var(--ok); }
.fieldnote .card.lose { box-shadow: inset 0 2px 0 var(--bad); }
.fieldnote .card .big {
  font-size: 26px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.03em;
  display: block;
  margin: 2px 0 6px;
  font-family: var(--sans);
}
.fieldnote .card.win .big { color: var(--ok); }
.fieldnote .card.lose .big { color: var(--bad); }
.fieldnote .card .ver {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--s2);
  border: 1px solid var(--panel-line);
  border-radius: 5px;
  padding: 2px 7px;
  margin-bottom: 10px;
}

/* ================= C14 - domain media ================= */
.fieldnote .gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; }
.fieldnote .shot { margin: 0; }
.fieldnote .shot svg, .fieldnote .shot img { width: 100%; height: auto; display: block; border-radius: 10px; }
.fieldnote .shot img { image-rendering: pixelated; }
.fieldnote .shot figcaption { font-size: 10.5px; color: var(--panel-dim); line-height: 1.55; margin-top: 9px; border: none; padding: 0; }
.fieldnote .shot figcaption b {
  display: block;
  margin-bottom: 3px;
  font-size: 10px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  font-weight: 500;
}
.fieldnote .shot.rejected figcaption b { color: var(--bad); }
.fieldnote .shot.accepted figcaption b { color: var(--ok); }

.fieldnote .board { display: grid; grid-template-columns: repeat(12, 22px); gap: 2px; width: max-content; margin: 0 auto; }
.fieldnote .board i { width: 22px; height: 22px; border-radius: 5px; background: var(--panel-mid); position: relative; }
.fieldnote .board i.c1 { background: var(--s1); }
.fieldnote .board i.c2 { background: var(--s2); }
.fieldnote .board i.c3 { background: var(--s3); }
.fieldnote .board i.c4 { background: var(--s4); }
.fieldnote .board i.goal::after { content: ""; position: absolute; inset: 6px; border-radius: 50%; background: var(--panel); opacity: 0.85; }
.fieldnote .board i.void { background: transparent; }

.fieldnote .mount {
  display: grid;
  place-items: center;
  min-height: 220px;
  border: 1.5px dashed var(--panel-line);
  border-radius: 12px;
  font-size: 11.5px;
  color: var(--panel-dim);
  text-align: center;
  line-height: 1.8;
  letter-spacing: 0.04em;
}

/* ================= C15 - series footer + CTA ================= */
.fieldnote footer.post, .fieldnote footer.uc { margin-top: 88px; padding-top: 26px; border-top: 1px solid var(--line); }
/* The use-case page ends on a call to action, not a footnote: full-bleed
 * accent band, dark ink, inverted button. Post footers keep the rule
 * above. */
.fieldnote footer.uc {
  width: 100vw;
  margin-inline: calc(50% - 50vw);
  margin-top: 96px;
  padding: 72px 24px 60px;
  border-top: 0;
  background: var(--accent-strong);
  color: var(--accent-text);
  text-align: center;
}
.fieldnote footer.uc h2 { color: inherit; max-width: 20ch; margin-inline: auto; }
.fieldnote footer.uc p { color: inherit; max-width: 60ch; margin-inline: auto; }
.fieldnote footer.uc .cta-row { justify-content: center; margin-top: 30px; }
.fieldnote footer.uc .button {
  background: var(--accent-text);
  border-color: var(--accent-text);
  color: var(--accent-strong);
}
/* 9.36:1 on the accent band. */
.fieldnote footer.uc .textlink { color: #34410c; }
.fieldnote footer.uc .textlink:hover { color: var(--accent-text); }
.fieldnote footer.uc .footer-note { color: #3d4a12; margin-top: 34px; }
.fieldnote .series-nav { display: flex; gap: 14px; justify-content: space-between; flex-wrap: wrap; margin-bottom: 24px; }
.fieldnote .series-nav a {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px 20px;
  color: inherit;
  flex: 1 1 250px;
  text-decoration: none;
  transition: border-color 0.25s, transform 0.25s;
}
.fieldnote .series-nav a:hover { border-color: var(--ink); transform: translateY(-2px); }
.fieldnote .series-nav small {
  display: block;
  font: 500 9.5px var(--mono);
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 7px;
}
.fieldnote .series-nav span { font-size: 15.5px; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); }
.fieldnote .cta-row { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; margin: 0 0 24px; }
.fieldnote .button {
  height: 46px;
  display: inline-flex;
  align-items: center;
  padding: 0 21px;
  border-radius: 999px;
  background: var(--accent-strong);
  color: var(--accent-text);
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
}
.fieldnote .button:hover { filter: brightness(1.05); }
/* Contrast is stated, not dimmed. `opacity` blends the inherited colour
 * toward whatever is behind it, so the effective ratio depends on the
 * ground and cannot be reasoned about: this rule measured 3.94:1 on the
 * page and 3.4:1 on the accent band, both below the 4.5 AA floor, while
 * every token it inherited from passes on its own. */
.fieldnote .textlink { color: var(--muted); text-decoration: none; font-size: 13px; }
.fieldnote .textlink:hover { color: var(--ink); }
.fieldnote .footer-note {
  font: 400 10px var(--mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

/* series list — the use-case "read the series" block */
.fieldnote .series-list { display: grid; gap: 14px; margin: 40px 0 0; }
/* Three-across variant: the entry point to a series reads as a choice of
 * routes, so the posts sit side by side rather than as a reading order.
 * Breaks the 720px measure the same way a wide panel does. */
.fieldnote .series-list.cols {
  width: min(940px, calc(100vw - 48px));
  margin-left: 50%;
  transform: translateX(-50%);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.fieldnote .series-list.cols a {
  grid-template-columns: minmax(0, 1fr);
  align-content: start;
  gap: 10px;
}
@media (max-width: 760px) {
  .fieldnote .series-list.cols { grid-template-columns: minmax(0, 1fr); }
}
.fieldnote .series-list a {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 18px;
  align-items: baseline;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 22px 24px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.25s, transform 0.25s;
}
.fieldnote .series-list a:hover { border-color: var(--ink); transform: translateY(-2px); }
.fieldnote .series-list .no { font: 500 11px var(--mono); letter-spacing: 0.1em; color: var(--muted); }
.fieldnote .series-list h3 { margin: 0 0 6px; font-size: 19px; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); }
.fieldnote .series-list p { margin: 0 0 10px; font-size: 14px; line-height: 1.6; color: var(--muted); max-width: none; }
.fieldnote .series-list .meta {
  font: 500 9.5px var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  opacity: 0.8;
}

/* ================= C18 - page hero =================
 * Full-bleed hero for post and capability pages, matching the
 * marketing sub-page pattern (the retired /integrations hero):
 * ambient field + accent glow, a pill badge, one big centered
 * headline, a dek, and a meta row. Sits OUTSIDE <main> in the
 * document so it can break the 720px measure; the negative margin
 * cancels the body gutter rather than using 100vw (no scrollbar
 * overflow).
 */
.fieldnote .page-hero {
  position: relative;
  /* full-bleed out of any container, without 100vw scrollbar overflow */
  margin-inline: calc(50% - 50vw);
  width: 100vw;
  padding: 116px 24px 64px;
  text-align: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}
.fieldnote .page-hero .hero-art {
  display: block;
  width: min(940px, 100%);
  margin: 34px auto 0;
  aspect-ratio: 40 / 13;
  object-fit: cover;
  /* pixel-art derivatives are tiny grids scaled up — keep blocks crisp */
  image-rendering: pixelated;
  /* No frame and no ground: the art carries its own alpha, so the
   * unresolved passes fade into the page rather than into a panel. */
  background: none;
}
.fieldnote .page-hero .hero-art.tall { aspect-ratio: 16 / 9; }
.fieldnote .page-hero .hero-glow {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 62% 46% at 50% 0%, rgba(201, 255, 61, 0.13) 0%, transparent 62%);
}
.fieldnote .hero-inner { position: relative; z-index: 1; max-width: 840px; margin: 0 auto; }
.fieldnote .hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--accent);
  border-radius: 999px;
  padding: 5px 14px;
  margin: 0 0 26px;
  font: 500 10.5px var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
  background: color-mix(in srgb, var(--accent-strong) 10%, transparent);
}
.fieldnote .hero-badge::before { content: "◆"; font-size: 8px; }
.fieldnote .page-hero h1 {
  font-size: clamp(38px, 5.6vw, 62px);
  line-height: 0.98;
  letter-spacing: -0.05em;
  margin: 0 0 22px;
}
.fieldnote .hero-dek {
  font-size: clamp(17px, 1.6vw, 20px);
  line-height: 1.55;
  color: var(--muted);
  /* 704 in the 840px hero leaves ~8% of side margin, down from ~13%.
   * Post heroes are unaffected: .page-hero.split sets its own measure. */
  max-width: 704px;
  margin: 0 auto 26px;
  text-wrap: pretty;
}
.fieldnote .hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 10px 20px;
  font: 400 12px var(--mono);
  color: var(--muted);
}
.fieldnote .hero-meta .sep { opacity: 0.4; }
/* The hero centres its contents; the CTA row is a flex box, so it needs
 * telling separately. */
.fieldnote .page-hero .cta-row { justify-content: center; margin-bottom: 26px; }
.fieldnote .page-hero .proofline {
  margin-bottom: 22px;
  /* the prose measure applies to <p>, which left-aligns the block
   * inside the centred hero even though its text-align is center */
  max-width: none;
}
/* The answer to the headline's claim, carried in the headline itself.
 * --accent is olive on light and lime on dark, so it stays legible in
 * both themes; the marketing lime alone would vanish on the cream. */
.fieldnote .page-hero h1 .answer {
  display: block;
  color: var(--accent);
}
@media (max-width: 640px) {
  .fieldnote .page-hero { padding: 96px 20px 44px; }
}

/* ================= C19 - author ================= */
.fieldnote .author-row { display: inline-flex; align-items: center; gap: 10px; }
.fieldnote .avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--accent-strong);
  color: var(--accent-text);
  font: 700 11px var(--mono);
  letter-spacing: 0;
  flex: none;
}
.fieldnote .author-card {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  margin: 64px 0 0;
}
.fieldnote .author-card .avatar { width: 46px; height: 46px; font-size: 15px; }
.fieldnote .author-card .who { flex: 1; }
.fieldnote .author-card :is(h4, .h4) {
  margin: 0 0 2px;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.fieldnote .author-card .role {
  font: 500 10.5px var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 10px;
}
.fieldnote .author-card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--muted);
  max-width: none;
}

/* ================= C20 - capability index ================= */
.fieldnote .uc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
  margin: 40px 0 0;
}
.fieldnote .uc-card {
  display: block;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 26px 26px 22px;
  text-decoration: none;
  color: inherit;
  transition: border-color 0.25s, transform 0.25s;
}
.fieldnote .uc-card:hover { border-color: var(--ink); transform: translateY(-2px); }
.fieldnote .uc-card h3 { margin: 14px 0 6px; font-size: 19px; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); }
.fieldnote .uc-card p { margin: 0; font-size: 14px; line-height: 1.6; color: var(--muted); max-width: none; }
.fieldnote .uc-card .stat {
  display: block;
  margin-top: 16px;
  font: 500 10px var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink);
  opacity: 0.6;
}
.fieldnote .uc-card .glyph { display: block; width: 34px; height: 34px; color: var(--ink); opacity: 0.85; }
.fieldnote .uc-card.soon { opacity: 0.62; pointer-events: none; }
.fieldnote .uc-card.soon .stat { color: var(--accent); opacity: 1; }

/* ================= C18b - split hero =================
 * The post hero as one dark panel: type on the left, the pass art on
 * the right, sharing the frame but never overlapping. No scrim is
 * needed, so every pass stays visible — the alternative (type over the
 * art) covers exactly the early passes the art is about.
 *
 * Capability pages keep the centred `.page-hero` above; only posts opt
 * in by adding `.split`.
 */
.fieldnote .page-hero.split {
  background: var(--panel);
  border-bottom: 1px solid var(--panel-line);
  padding: 0;
  text-align: left;
}
.fieldnote .page-hero.split .hero-glow {
  background: radial-gradient(
    ellipse 55% 75% at 78% 50%,
    color-mix(in srgb, var(--post-hue, var(--accent-strong)) 12%, transparent) 0%,
    transparent 68%
  );
}
.fieldnote .page-hero.split .hero-inner {
  max-width: 1160px;
  display: grid;
  grid-template-columns: 45fr 55fr;
  align-items: center;
  gap: 40px;
  padding: 60px 24px 64px;
  text-align: left;
}
.fieldnote .page-hero.split .hero-badge {
  color: var(--post-hue, var(--accent-strong));
  border-color: color-mix(in srgb, var(--post-hue, var(--accent-strong)) 45%, transparent);
  background: color-mix(in srgb, var(--post-hue, var(--accent-strong)) 12%, transparent);
}
.fieldnote .page-hero.split h1 {
  color: var(--panel-ink);
  font-size: clamp(30px, 3.5vw, 46px);
  margin-bottom: 18px;
}
.fieldnote .page-hero.split .hero-dek {
  color: #9fb3a6;
  margin: 0 0 22px;
  max-width: 44ch;
  font-size: clamp(15.5px, 1.25vw, 17.5px);
}
.fieldnote .page-hero.split .hero-meta {
  justify-content: flex-start;
  color: var(--panel-dim);
}
.fieldnote .page-hero.split .hero-meta .avatar {
  background: var(--post-hue, var(--accent-strong));
  color: #101a08;
}
.fieldnote .page-hero.split .proofline { color: var(--post-hue, var(--accent-strong)); }
.fieldnote .page-hero.split .hero-art {
  width: 100%;
  max-width: none;
  margin: 0;
  aspect-ratio: auto;
  border: 0;
  border-radius: 14px;
  background: transparent;
}
@media (max-width: 860px) {
  .fieldnote .page-hero.split .hero-inner {
    grid-template-columns: 1fr;
    gap: 28px;
    padding: 44px 20px 48px;
  }
  .fieldnote .page-hero.split h1 { font-size: clamp(28px, 7vw, 36px); }
}

/* The marketing nav is fixed and transparent until scrolled, so its ink
 * would sit dark-on-dark over this panel. Start the panel below the nav
 * and let the page ground stay behind it. */
.fieldnote .page-hero.split { margin-top: 3.5rem; }
/* Emphasis inside the dek inherits the light-ground ink otherwise. */
.fieldnote .page-hero.split strong,
.fieldnote .page-hero.split .hero-dek strong { color: var(--panel-ink); }

/* The hero is a full-bleed panel; the article needs air under it rather
 * than butting the first paragraph against the panel edge. */
/* Demoted to .doc once hosted — see document.ts. */
.fieldnote .page-hero + :is(main, .doc) { padding-top: 60px; }
@media (max-width: 860px) {
  .fieldnote .page-hero + :is(main, .doc) { padding-top: 40px; }
}

/* The byline avatar may be an image (an agent's mark) or a monogram.
 * Pixel marks are square: a circular crop takes the antenna and the
 * head's corners with it, so image avatars get a soft square instead. */
.fieldnote img.avatar { object-fit: cover; background: var(--panel); border-radius: 7px; }
.fieldnote .author-card img.avatar { border-radius: 12px; }

/* The layer stack was sized for a two-digit number and a short chip.
 * Posts put a label in .no ("03 · Progression") and a full sentence in
 * .measure, which overflowed the panel and collided with the copy. */
.fieldnote .stack .layer {
  grid-template-columns: 118px minmax(0, 1fr);
  grid-template-areas: "no body" ". meas";
  gap: 0 14px;
  align-items: start;
  padding: 15px 18px 14px;
}
.fieldnote .stack .layer .no {
  grid-area: no;
  white-space: nowrap;
  padding-top: 1px;
  font-size: 10px;
}
/* The middle cell is the only child element without a class of its own. */
.fieldnote .stack .layer > div { grid-area: body; min-width: 0; }
.fieldnote .stack .layer .measure {
  grid-area: meas;
  margin-top: 12px;
  padding: 9px 0 0;
  border: 0;
  border-top: 1px solid var(--panel-line);
  border-radius: 0;
  max-width: none;
  white-space: normal;
  text-align: left;
  line-height: 1.55;
  letter-spacing: 0;
}
.fieldnote .stack .layer .measure::before {
  content: "MEASURED";
  /* Overridable: the slot holds a measurement in a post, but other
   * pages use it for a precondition or a status. */
  display: block;
  margin-bottom: 3px;
  font-size: 9px;
  letter-spacing: 0.14em;
  color: var(--s1);
}
.fieldnote .stack .layer .measure[data-label]::before { content: attr(data-label); }
@media (max-width: 760px) {
  .fieldnote .stack .layer {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas: "no" "body" "meas";
    gap: 6px 0;
  }
}

/* ================= C21 - annotated board =================
 * A real level rendered from its audit record, with numbered pins so a
 * list of criteria can point at the part of the board each one is about.
 * The board is an inline <svg class="lvl">; only the frame is styled here.
 */
.fieldnote .hyp-board { display: grid; grid-template-columns: minmax(0, auto) minmax(0, 1fr); gap: 26px; align-items: start; }
.fieldnote .hyp-board .board-wrap { min-width: 0; }
.fieldnote svg.lvl {
  display: block;
  width: 100%;
  max-width: 312px;
  height: auto;
  overflow: visible;
}
/* Same renderer without the annotation layer, shown on its own. */
.fieldnote svg.lvl.plain { max-width: 340px; margin: 6px auto 0; }
@media (max-width: 760px) {
  .fieldnote .hyp-board { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .fieldnote .hyp-board svg.lvl { max-width: 100%; }
}
.fieldnote .hyp-board ol.hyp-legend { list-style: none; padding: 0; margin: 0; max-width: none; }
.fieldnote .hyp-board ol.hyp-legend li {
  display: flex; gap: 11px; align-items: baseline;
  padding: 9px 0; margin: 0; border: 0;
  font: 400 12px/1.6 var(--sans); color: var(--panel-dim); max-width: none;
}
.fieldnote .hyp-board ol.hyp-legend li + li { border-top: 1px solid var(--panel-grid); }
.fieldnote .hyp-board ol.hyp-legend b {
  flex: none; width: 18px; height: 18px; border-radius: 50%;
  background: var(--panel-ink); color: var(--panel);
  display: grid; place-items: center; font: 700 10px var(--mono);
}
.fieldnote .hyp-board ol.hyp-legend em { color: var(--panel-ink); font-style: normal; font-weight: 600; }
@media (max-width: 760px) {
  .fieldnote .hyp-board { grid-template-columns: 1fr; gap: 18px; }
}
