/* agentimus.io shared styles.
   One typeface (Archivo, two widths), colours taken from the logo, tone steps instead of
   borders and shadows. Every colour is a token; components only reference tokens. */

:root {
  --paper: #f1f2ed;      /* the ground */
  --paper-2: #e4e7de;    /* one tone step: sheets, rows, panels */
  --paper-3: #d6dbcf;    /* hover on paper-2 */
  --ink: #0c2416;        /* text, from the logo's dark green */
  --ink-2: #475a4d;      /* secondary text, 6.5:1 on paper */
  --forest: #0c2a18;     /* dark field */
  --forest-2: #143a24;   /* tone step on forest */
  --on-forest: #e9f1ea;
  --on-forest-2: #a8beaf;
  --mint: #cbefd5;       /* light field */
  --signal: #22c55e;     /* the logo green: main button and the strike line, nothing else */
  --signal-hover: #45d97b;
  --on-signal: #062012;
  --mark: #4ade80;       /* the logo glyph green, for marks on forest */
  --link: #157a3d;       /* green that passes contrast on paper, for inline links */

  --font: "Archivo", "Helvetica Neue", Arial, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.6vw, 1.5rem);
  --step-head: clamp(2rem, 1.25rem + 2.7vw, 3.5rem);
  --step-display: clamp(2.5rem, 1rem + 5.4vw, 5.5rem);

  --gutter: clamp(20px, 5vw, 72px);
  --maxw: 1320px;
  --radius: 4px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: var(--step-body);
  line-height: 1.55;
  font-kerning: normal;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}
img, svg, video, iframe { display: block; max-width: 100%; }
h1, h2, h3, h4, p, ul, ol, figure, blockquote, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1, h2, h3, h4 { text-wrap: balance; hyphens: none; }
p { text-wrap: pretty; }
a { color: inherit; }
button { font: inherit; color: inherit; }
::selection { background: var(--signal); color: var(--on-signal); }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 2px; }
.field-forest :focus-visible, .on-forest :focus-visible { outline-color: var(--mark); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: var(--radius); }
.skip:focus { top: 12px; }

/* Inline links inside running text */
.prose a, a.inline {
  color: var(--link);
  text-decoration: underline;
  text-decoration-thickness: 0.07em;
  text-underline-offset: 0.2em;
}
.prose a:hover, a.inline:hover { color: var(--ink); }
.field-forest .prose a, .field-forest a.inline { color: var(--mark); }
.field-forest .prose a:hover, .field-forest a.inline:hover { color: var(--on-forest); }

/* ---------- Type ---------- */
.display {
  font-size: var(--step-display);
  font-weight: 760;
  font-stretch: 106%;
  line-height: 1;
  letter-spacing: -0.025em;
  margin-left: -0.04em;
}
.h2 {
  font-size: var(--step-head);
  font-weight: 740;
  font-stretch: 104%;
  line-height: 1.02;
  letter-spacing: -0.022em;
}
.h3 {
  font-size: clamp(1.25rem, 1.1rem + 0.5vw, 1.5rem);
  font-weight: 680;
  font-stretch: 100%;
  line-height: 1.22;
  letter-spacing: -0.01em;
}
.lead { font-size: var(--step-lead); line-height: 1.4; }
.muted { color: var(--ink-2); }
.small { font-size: var(--step-small); line-height: 1.45; }
.num { font-variant-numeric: tabular-nums lining-nums; }
.field-forest .muted { color: var(--on-forest-2); }

/* ---------- Layout ---------- */
.wrap { max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(72px, 9vw, 144px); }
.field-paper2 { background: var(--paper-2); }
.field-mint { background: var(--mint); }
.field-forest { background: var(--forest); color: var(--on-forest); }

/* Section head: heading on the left, the supporting line on the right, bottoms aligned */
.sh {
  display: grid;
  gap: 20px 48px;
  margin-bottom: clamp(40px, 5vw, 72px);
}
.sh > p { max-width: 46ch; }
@media (min-width: 900px) {
  .sh { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: end; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 14px 26px;
  border-radius: 999px;
  border: 0;
  background: var(--signal);
  color: var(--on-signal);
  font-size: 1.0625rem;
  font-weight: 650;
  font-stretch: 104%;
  line-height: 1.2;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.18s var(--ease), transform 0.18s var(--ease);
}
.btn:hover { background: var(--signal-hover); }
.btn:active { transform: scale(0.98); }
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: #1d3d29; }
.btn-ghost { background: var(--paper-2); color: var(--ink); }
.btn-ghost:hover { background: var(--paper-3); }
.field-paper2 .btn-ghost { background: var(--paper-3); }
.field-paper2 .btn-ghost:hover { background: #c9cfc1; }
.field-forest .btn-ghost { background: var(--forest-2); color: var(--on-forest); }
.field-forest .btn-ghost:hover { background: #1d4a30; }
.btn svg { width: 20px; height: 20px; flex: none; }
.btn-sm { min-height: 44px; padding: 10px 20px; font-size: 1rem; }

/* A text link with an underline that sits clear of the descenders */
.tlink {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 650;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.3em;
  text-decoration-color: var(--signal);
  transition: text-decoration-color 0.18s var(--ease), color 0.18s var(--ease);
}
.tlink:hover { text-decoration-color: currentColor; }
.tlink svg { width: 20px; height: 20px; flex: none; }

.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; }

/* ---------- Navigation ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--paper);
  transition: background-color 0.2s var(--ease);
}
.nav.is-scrolled { background: var(--paper-2); }
.nav-in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 72px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-size: 1.3rem;
  font-weight: 800;
  font-stretch: 116%;
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.brand img { width: 30px; height: 30px; }
.brand span span { color: var(--link); }
.field-forest .brand span span { color: var(--mark); }
.nav-links { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 34px); }
.nav-links a { text-decoration: none; font-weight: 550; color: var(--ink); font-size: 1rem; white-space: nowrap; }
.nav-links a:hover, .nav-links a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.35em; text-decoration-color: var(--signal); }
.nav-cta { display: inline-flex; flex: none; white-space: nowrap; }
.menu-btn {
  display: none;
  min-height: 44px;
  padding: 8px 18px;
  border: 0;
  border-radius: 999px;
  background: var(--paper-2);
  font-weight: 650;
  cursor: pointer;
}
@media (max-width: 1099px) {
  .menu-btn { display: inline-flex; align-items: center; }
  .nav-cta { display: none; }
  .nav-links {
    display: none;
    position: absolute;
    left: 0; right: 0; top: 72px;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px var(--gutter) 28px;
    background: var(--paper-2);
  }
  .nav-links.is-open { display: flex; }
  .nav-links a { padding: 14px 0; font-size: 1.375rem; font-weight: 700; font-stretch: 110%; }
  .nav-links .btn { margin-top: 12px; font-size: 1.0625rem; }
}
@media (min-width: 1100px) { .nav-links .btn { display: none; } }

/* ---------- Hero ---------- */
.hero { padding-block: clamp(40px, 6vw, 88px) clamp(56px, 7vw, 104px); }
.hero h1 { max-width: 19ch; }
.hero-under {
  display: grid;
  gap: 28px 64px;
  margin-top: clamp(28px, 3.5vw, 48px);
}
.hero-under .lead { max-width: 44ch; }
.promises { display: flex; flex-wrap: wrap; gap: 6px 22px; margin-top: 18px; color: var(--ink-2); font-size: var(--step-small); }
.promises li { display: inline-flex; align-items: center; gap: 7px; }
.promises svg { width: 16px; height: 16px; color: var(--link); flex: none; }
@media (min-width: 900px) {
  .hero-under { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; }
}

/* ---------- Unchecked to-do list (problems) ---------- */
.todo { display: grid; gap: 36px 56px; }
@media (min-width: 760px) { .todo { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .todo { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.todo li { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 4px 16px; }
.todo .box { width: 22px; height: 22px; margin-top: 3px; border: 2.5px solid var(--ink); border-radius: 3px; }
.todo .h3 { margin-bottom: 6px; }
.todo p { color: var(--ink-2); }

/* ---------- Services: one row per kind of build ---------- */
.svc { display: grid; gap: 18px 48px; padding-block: clamp(32px, 4vw, 52px); }
.svc + .svc { border-top: 3px solid var(--ink); }
.svc-name { font-size: clamp(1.75rem, 1.2rem + 1.8vw, 2.5rem); font-weight: 740; font-stretch: 104%; line-height: 1; letter-spacing: -0.025em; }
.svc-line { font-size: var(--step-lead); font-weight: 650; line-height: 1.3; margin-bottom: 10px; }
.svc-body p:not(.svc-line) { color: var(--ink-2); max-width: 46ch; }
.svc-eg li { position: relative; padding-left: 22px; }
.svc-eg li + li { margin-top: 10px; }
.svc-eg li::before { content: ""; position: absolute; left: 0; top: 0.68em; width: 10px; height: 3px; background: var(--ink); }
.svc-name a {
  text-decoration: underline;
  text-decoration-thickness: 4px;
  text-underline-offset: 0.14em;
  text-decoration-color: var(--signal);
  transition: text-decoration-color 0.18s var(--ease);
}
.svc-name a:hover { text-decoration-color: var(--ink); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips a {
  display: inline-flex; align-items: center; min-height: 40px; padding: 8px 16px;
  border-radius: 999px; background: var(--paper-2); text-decoration: none; font-weight: 600; font-size: 0.975rem;
  transition: background-color 0.18s var(--ease);
}
.chips a:hover { background: var(--paper-3); }
@media (min-width: 900px) {
  .svc { grid-template-columns: minmax(0, 4fr) minmax(0, 4fr) minmax(0, 4fr); align-items: start; }
}
/* ---------- Results ---------- */
.feature {
  display: grid;
  gap: 32px 64px;
  padding: clamp(24px, 4vw, 56px);
  border-radius: var(--radius);
  background: var(--paper-2);
}
@media (min-width: 1000px) { .feature { grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); align-items: end; } }
.kind { font-weight: 650; color: var(--ink-2); font-size: var(--step-small); margin-bottom: 12px; }
.feature .h2 { font-size: clamp(1.75rem, 1.2rem + 2vw, 2.75rem); margin-bottom: 16px; }
.feature p.muted { max-width: 48ch; }
.bignums { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.bignum { font-size: clamp(2.5rem, 1.2rem + 3.4vw, 4.5rem); font-weight: 800; font-stretch: 116%; line-height: 0.95; letter-spacing: -0.03em; font-variant-numeric: tabular-nums lining-nums; }
.bignum + p { margin-top: 8px; color: var(--ink-2); font-weight: 550; }
.ledger { margin-top: clamp(24px, 3vw, 40px); }
.row {
  display: grid;
  gap: 10px 32px;
  padding: 24px 0;
  text-decoration: none;
}
.row + .row { border-top: 3px solid var(--paper-2); }
.row .h3 { margin-bottom: 6px; }
.row p.muted { max-width: 54ch; }
.row-nums { display: flex; gap: 32px; }
.row-num { font-size: clamp(1.75rem, 1.3rem + 1.2vw, 2.5rem); font-weight: 800; font-stretch: 112%; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums lining-nums; }
.row-num + span { display: block; margin-top: 6px; font-size: var(--step-small); color: var(--ink-2); font-weight: 550; }
.row .tlink { align-self: center; justify-self: start; }
@media (min-width: 1000px) {
  .row { grid-template-columns: minmax(0, 2.2fr) minmax(0, 5fr) minmax(0, 4fr) auto; align-items: center; }
  .row .kind { margin-bottom: 0; }
}
a.row:hover .h3 { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.25em; text-decoration-color: var(--signal); }
.nda { display: flex; align-items: center; gap: 10px; margin-top: 24px; color: var(--ink-2); font-size: var(--step-small); }
.nda svg { width: 16px; height: 16px; flex: none; }

/* ---------- Quotes (mint field) ---------- */
.quotes { display: grid; gap: 48px 64px; }
@media (min-width: 1000px) { .quotes { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); } }
.quote-big blockquote p {
  font-size: clamp(1.5rem, 1.05rem + 1.7vw, 2.25rem);
  font-weight: 600;
  font-stretch: 104%;
  line-height: 1.22;
  letter-spacing: -0.012em;
}
.quote-small blockquote p { font-size: var(--step-lead); font-weight: 550; line-height: 1.35; }
.quote-small + .quote-small { margin-top: 40px; }
.quote-big figcaption, .quote-small figcaption { margin-top: 18px; }
.quote-big figcaption b, .quote-small figcaption b { display: block; font-weight: 700; }
.quote-big figcaption span, .quote-small figcaption span { color: var(--ink-2); font-size: var(--step-small); }
.field-mint .muted, .field-mint figcaption span { color: #35503f; }

/* ---------- Steps ---------- */
.steps { display: grid; gap: 40px 40px; counter-reset: step; }
@media (min-width: 700px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.steps li { counter-increment: step; }
.steps li::before {
  content: counter(step);
  display: block;
  margin-bottom: 14px;
  font-size: clamp(3rem, 2rem + 3vw, 4.5rem);
  font-weight: 800;
  font-stretch: 116%;
  line-height: 0.9;
  letter-spacing: -0.03em;
  color: var(--link);
}
.steps .h3 { margin-bottom: 8px; }
.steps p { color: var(--ink-2); }
.after-steps { display: grid; gap: 32px 64px; margin-top: clamp(48px, 6vw, 80px); }
@media (min-width: 1000px) { .after-steps { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: center; } }

/* ---------- Who builds ---------- */
.about { display: grid; gap: 40px 80px; }
@media (min-width: 1000px) { .about { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; } }
.about .lead { margin-top: 20px; max-width: 34ch; }
.about-note { display: flex; gap: 10px; align-items: flex-start; margin-top: 28px; font-weight: 600; max-width: 40ch; }
.about-note svg { width: 18px; height: 18px; flex: none; margin-top: 3px; color: var(--link); }
.about-roles { display: grid; gap: 28px 40px; }
@media (min-width: 640px) { .about-roles { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.about-roles li { padding-top: 16px; border-top: 3px solid var(--ink); }
.about-roles b { display: block; font-size: 1.125rem; font-weight: 700; }
.about-roles span { display: block; margin-top: 6px; color: var(--ink-2); }
.roles { background: var(--paper-2); border-radius: var(--radius); padding: clamp(24px, 3vw, 36px); }
.roles li + li { margin-top: 18px; }
.roles b { display: block; font-weight: 700; font-stretch: 106%; }
.roles span { color: var(--ink-2); }
.roles .solo { margin-top: 24px; padding-top: 20px; border-top: 3px solid var(--ink); font-weight: 600; }

/* ---------- Tools list ---------- */
.tools { display: flex; flex-wrap: wrap; gap: 4px 0; font-size: clamp(1.25rem, 1rem + 1vw, 1.875rem); font-weight: 650; font-stretch: 108%; line-height: 1.35; letter-spacing: -0.01em; }
.tools li:not(:last-child)::after { content: ","; margin-right: 0.4em; color: var(--ink-2); }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 40px 80px; }
@media (min-width: 1000px) {
  .faq { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
  .faq-head { position: sticky; top: 112px; align-self: start; }
}
.faq-head .h2 { margin-bottom: 16px; }
.qa + .qa { border-top: 3px solid var(--paper-3); }
.field-paper2 .qa + .qa { border-top-color: var(--paper); }
.qa summary {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 28px;
  gap: 20px;
  align-items: center;
  padding: 22px 0;
  cursor: pointer;
  list-style: none;
  font-size: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  font-weight: 650;
  line-height: 1.35;
}
.qa summary::-webkit-details-marker { display: none; }
.qa summary i { position: relative; width: 28px; height: 28px; border-radius: 999px; background: var(--ink); }
.qa summary i::before, .qa summary i::after { content: ""; position: absolute; left: 8px; right: 8px; top: 12.5px; height: 3px; background: var(--paper); transition: transform 0.25s var(--ease); }
.qa summary i::after { transform: rotate(90deg); }
.qa[open] summary i::after { transform: rotate(0deg); }
.qa summary:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.25em; text-decoration-color: var(--signal); }
.qa .ans { padding: 0 48px 24px 0; color: var(--ink-2); max-width: 66ch; }

/* ---------- Articles (cards are filled in by assets/articles.js) ---------- */
.posts { display: grid; gap: 32px; }
@media (min-width: 700px) { .posts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .posts { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.post { display: flex; flex-direction: column; text-decoration: none; }
.post-cover { aspect-ratio: 16 / 9; overflow: hidden; border-radius: var(--radius); background: var(--forest); display: grid; place-items: center; }
.post-cover img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s var(--ease); }
.post-cover img.post-mark { width: 64px; height: 64px; object-fit: contain; }
.post:hover .post-cover img:not(.post-mark) { transform: scale(1.03); }
.post-meta { margin-top: 16px; color: var(--ink-2); font-size: var(--step-small); }
.post .h3 { margin-top: 6px; }
.post:hover .h3 { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 0.25em; text-decoration-color: var(--signal); }
.post p { margin-top: 10px; color: var(--ink-2); }
.hidden { display: none !important; }

/* ---------- Closing call to action and footer (one forest field) ---------- */
.close { padding-block: clamp(80px, 10vw, 160px) clamp(56px, 6vw, 88px); }
.close .display { max-width: 16ch; }
.close-under { display: grid; gap: 32px 64px; margin-top: clamp(28px, 3vw, 44px); }
@media (min-width: 1000px) { .close-under { grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); align-items: start; } }
.close-under .lead { max-width: 44ch; color: var(--on-forest-2); }
.close-steps { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 20px; font-weight: 600; }
.close-steps li { display: inline-flex; gap: 8px; align-items: center; }
.close-steps svg { width: 18px; height: 18px; color: var(--mark); }
.close .actions { margin-bottom: 16px; }
.close .small { color: var(--on-forest-2); }

/* Contact form under the closing call to action. Posts to /api/contact. */
.close-form { display: grid; gap: 24px 64px; margin-top: clamp(48px, 6vw, 80px); padding-top: clamp(32px, 4vw, 48px); border-top: 3px solid var(--forest-2); }
@media (min-width: 1000px) { .close-form { grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); align-items: start; } }
.close-form .h3 { margin-bottom: 10px; }
.close-form .small { max-width: 44ch; }
.cform { display: grid; gap: 16px; }
.cf-row { display: grid; gap: 16px; }
@media (min-width: 560px) { .cf-row { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.cf-field { display: grid; gap: 6px; font-size: var(--step-small); font-weight: 600; color: var(--on-forest-2); }
.cf-field b { font-weight: 600; color: var(--mark); }
.cf-field input, .cf-field textarea {
  width: 100%; min-height: 48px; padding: 12px 14px; border: 0; border-bottom: 3px solid var(--on-forest-2); border-radius: var(--radius) var(--radius) 0 0;
  background: var(--forest-2); color: var(--on-forest); font: inherit; font-size: 1rem; font-weight: 400; line-height: 1.4;
}
.cf-field textarea { min-height: 128px; resize: vertical; }
.cf-field input:focus-visible, .cf-field textarea:focus-visible { outline-offset: 0; }
.cf-field input:-webkit-autofill { -webkit-text-fill-color: var(--on-forest); box-shadow: 0 0 0 100px var(--forest-2) inset; caret-color: var(--on-forest); }
.cf-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.cf-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.cf-status { font-size: var(--step-small); color: var(--on-forest-2); }
.cf-status.is-error { color: var(--on-forest); font-weight: 600; }
.cf-done { max-width: 36ch; font-size: var(--step-lead); line-height: 1.4; }
.btn:disabled { opacity: 0.6; cursor: default; }

.foot { padding-block: clamp(48px, 6vw, 72px) 40px; }
.foot-grid { display: grid; gap: 40px 32px; padding-top: clamp(40px, 5vw, 64px); border-top: 3px solid var(--forest-2); }
@media (min-width: 640px) { .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .foot-grid { grid-template-columns: minmax(0, 3fr) repeat(4, minmax(0, 1.5fr)); } }
.foot-about p { margin-top: 16px; max-width: 32ch; color: var(--on-forest-2); }
.foot h2 { font-size: 1rem; font-weight: 700; font-stretch: 106%; margin-bottom: 14px; }
.foot li + li { margin-top: 10px; }
.foot a { text-decoration: none; color: var(--on-forest-2); }
.foot a:hover { color: var(--on-forest); text-decoration: underline; text-underline-offset: 0.25em; }
.socials { display: flex; gap: 10px; margin-top: 22px; }
.socials a { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 999px; background: var(--forest-2); color: var(--on-forest); }
.socials a:hover { background: #1d4a30; }
.socials svg { width: 20px; height: 20px; }
.legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; margin-top: 56px; color: var(--on-forest-2); font-size: var(--step-small); }
.legal div { display: flex; flex-wrap: wrap; gap: 8px 24px; }

/* ---------- Mobile bar with the two actions ---------- */
.mbar { display: none; }
@media (max-width: 767px) {
  .mbar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 60;
    display: flex; gap: 10px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
    background: var(--paper-2);
    transform: translateY(110%);
    transition: transform 0.3s var(--ease);
  }
  .mbar.is-on { transform: none; }
  .mbar .btn { flex: 1; min-height: 50px; }
  .mbar .btn-ghost { flex: 0 0 56px; padding: 0; background: var(--paper-3); }
  body.has-mbar { padding-bottom: 76px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

/* =====================================================================
   Inner pages: services, case studies, industries, articles, legal
   ===================================================================== */

/* Page hero */
.page-hero { padding-block: clamp(28px, 4vw, 56px) clamp(56px, 7vw, 104px); }
.page-hero-grid { display: grid; gap: 40px 64px; }
@media (min-width: 1000px) { .page-hero-grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: start; } }
.page-hero .lead { margin-top: 24px; max-width: 46ch; }
.page-hero .actions { margin-top: 32px; }
.title {
  font-size: clamp(2.25rem, 1rem + 4.2vw, 4.25rem);
  font-weight: 760;
  font-stretch: 106%;
  line-height: 1;
  letter-spacing: -0.025em;
  margin-left: -0.03em;
}
.crumb { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-bottom: clamp(18px, 2.4vw, 28px); font-size: var(--step-small); color: var(--ink-2); }
.crumb a { color: var(--ink); font-weight: 600; text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--signal); text-underline-offset: 0.25em; }
.crumb a:hover { text-decoration-color: var(--ink); }
.note { margin-top: 20px; font-size: var(--step-small); color: var(--ink-2); max-width: 60ch; }
.field-forest .note { color: var(--on-forest-2); }

/* Interface fragments: small, honest pictures of the systems we build */
.ui { background: #fbfbf8; border-radius: 8px; overflow: hidden; font-size: 0.9375rem; line-height: 1.45; color: var(--ink); }
.ui-bar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 4px 12px; padding: 12px 16px; background: var(--forest); color: var(--on-forest); font-weight: 650; font-size: 0.875rem; }
.ui-bar small { display: block; font-weight: 500; color: var(--on-forest-2); font-size: 0.8125rem; }
.live { display: inline-flex; align-items: center; gap: 6px; font-size: 0.75rem; font-weight: 700; color: var(--mark); white-space: nowrap; }
.live::before { content: ""; width: 7px; height: 7px; border-radius: 999px; background: var(--mark); }
.ui-body { display: grid; gap: 10px; padding: 16px; }
.msg { max-width: 86%; padding: 10px 14px; border-radius: 14px; }
.msg.in { justify-self: start; background: var(--paper-2); border-bottom-left-radius: 4px; }
.msg.out { justify-self: end; background: var(--mint); border-bottom-right-radius: 4px; }
.msg small, .ui-meta { display: block; margin-top: 4px; font-size: 0.75rem; color: var(--ink-2); }
.who { font-size: 0.75rem; font-weight: 700; color: var(--ink-2); }
.ui-done { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: 6px; background: var(--mint); font-weight: 600; font-size: 0.875rem; }
.ui-done svg { width: 16px; height: 16px; flex: none; margin-top: 2px; color: var(--link); }
.ui-list > * { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; padding: 10px 0; }
.ui-list > * + * { border-top: 1px solid var(--paper-2); }
.ui-list b { font-weight: 650; }
.ui-table { width: 100%; border-collapse: collapse; font-size: 0.875rem; }
.ui-table th { text-align: left; font-weight: 600; color: var(--ink-2); padding: 6px 10px 6px 0; }
.ui-table td { padding: 9px 10px 9px 0; border-top: 1px solid var(--paper-2); vertical-align: top; }
.ui-table .r { text-align: right; padding-right: 0; font-variant-numeric: tabular-nums; }
.ui-table tfoot td { font-weight: 750; border-top: 2px solid var(--ink); }
.tag { display: inline-block; padding: 2px 9px; border-radius: 999px; background: var(--paper-2); font-size: 0.75rem; font-weight: 650; white-space: nowrap; }
.tag.ok { background: var(--mint); }
.tag.warn { background: #f1e3a6; }
.ui-cols { display: grid; gap: 10px; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.ui-col { background: var(--paper-2); border-radius: 6px; padding: 10px; display: grid; gap: 8px; align-content: start; }
.ui-col > b { font-size: 0.8125rem; }
.ui-card { background: #fbfbf8; border-radius: 4px; padding: 8px 10px; font-size: 0.8125rem; }
.ui-card span { display: block; color: var(--ink-2); font-size: 0.75rem; }
.redact { background: var(--ink); color: var(--ink); border-radius: 2px; user-select: none; }

/* Figures: a number set large with its label under it */
.figs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 32px; }
@media (min-width: 900px) { .figs.four { grid-template-columns: repeat(4, minmax(0, 1fr)); } .figs.three { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.fig b { display: block; font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.75rem); font-weight: 800; font-stretch: 112%; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums lining-nums; }
.fig span { display: block; margin-top: 8px; font-size: var(--step-small); color: var(--ink-2); font-weight: 550; }
.figs.big .fig b { font-size: clamp(2.25rem, 1.4rem + 2.6vw, 3.75rem); }
.field-forest .fig span { color: var(--on-forest-2); }
.under { margin-top: 24px; }

/* Items: a heading and a sentence under a thick bar */
.items { display: grid; gap: 36px 48px; }
@media (min-width: 700px) { .items { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .items.three { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.items > li, .items > div { padding-top: 18px; border-top: 3px solid var(--ink); }
.field-forest .items > li, .field-forest .items > div { border-top-color: var(--mark); }
.items .h3 { margin-bottom: 8px; }
.items p { color: var(--ink-2); }
.items p + p { margin-top: 10px; }
.field-forest .items p { color: var(--on-forest-2); }
.items .tlink { margin-top: 12px; }

/* Two-column text block */
.split { display: grid; gap: 32px 72px; }
@media (min-width: 1000px) { .split { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; } }
.prose p { max-width: 64ch; }
.prose p + p { margin-top: 1em; }

/* Before and after */
.story { display: grid; gap: 16px; }
@media (min-width: 1000px) { .story { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); } }
.story > div { padding: clamp(24px, 3vw, 40px); border-radius: var(--radius); }
.before { background: var(--paper-2); }
.field-paper2 .before { background: var(--paper); }
.after { background: var(--forest); color: var(--on-forest); }
.story .h3 { margin-bottom: 14px; }
.before p { color: var(--ink-2); }
.after .figs { margin-top: 28px; }
.after .fig span { color: var(--on-forest-2); }
.after .tlink { margin-top: 24px; }
.olist { display: grid; gap: 14px; counter-reset: n; }
.olist > li { counter-increment: n; display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; }
.olist > li::before { content: counter(n); display: grid; place-items: center; width: 28px; height: 28px; border-radius: 999px; background: var(--ink); color: var(--paper); font-weight: 800; font-size: 0.875rem; }
.field-forest .olist > li::before, .after .olist > li::before { background: var(--mark); color: var(--forest); }

/* Comparison table */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.compare { width: 100%; min-width: 640px; border-collapse: collapse; }
.compare th, .compare td { text-align: left; vertical-align: top; padding: 16px 20px 16px 0; }
.compare thead th { font-size: 1.125rem; font-weight: 780; font-stretch: 108%; border-bottom: 3px solid var(--ink); }
.compare thead th a { text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--signal); text-underline-offset: 0.25em; }
.compare tbody th { font-weight: 650; width: 22%; }
.compare tbody tr + tr > * { border-top: 3px solid var(--paper-2); }
.field-paper2 .compare tbody tr + tr > * { border-top-color: var(--paper); }
.compare td { color: var(--ink-2); }
.compare .is-this { color: var(--ink); font-weight: 600; }
.compare .num { font-size: 1.25rem; font-weight: 780; color: var(--ink); font-variant-numeric: tabular-nums; }

/* Case study: one row per automation, text on the left, the system on the right */
.casestep { display: grid; gap: 28px 64px; padding-block: clamp(40px, 5vw, 72px); }
.casestep + .casestep { border-top: 3px solid var(--ink); }
.casestep:first-child { padding-top: 0; }
@media (min-width: 1000px) { .casestep { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; } }
.casestep .h2 { font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.25rem); margin-bottom: 16px; }
.casestep p.muted { max-width: 54ch; }
.casestep .figs { margin-top: 24px; }
.step-of { margin-bottom: 10px; font-size: var(--step-small); font-weight: 650; color: var(--ink-2); }

/* Rows of projects, each with its system beside it */
.proj { display: grid; gap: 28px 64px; padding-block: clamp(40px, 5vw, 64px); }
.proj + .proj { border-top: 3px solid var(--ink); }
@media (min-width: 1000px) { .proj { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); align-items: start; } }
.proj .h2 { font-size: clamp(1.625rem, 1.2rem + 1.5vw, 2.5rem); margin-bottom: 12px; }
.proj .h2 a { text-decoration: none; }
.proj .h2 a:hover { text-decoration: underline; text-decoration-thickness: 3px; text-decoration-color: var(--signal); text-underline-offset: 0.15em; }
.proj p.muted { max-width: 54ch; }
.proj .figs { margin-top: 24px; }
.proj .tlink { margin-top: 24px; }
.group-title { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 8px 24px; margin-top: clamp(48px, 6vw, 96px); padding-bottom: 16px; border-bottom: 3px solid var(--ink); }
.group-title + .proj { border-top: 0; }

/* Plain list of related pages */
.related a { display: grid; gap: 4px 32px; padding: 20px 0; text-decoration: none; }
.related a + a { border-top: 3px solid var(--paper-2); }
.field-paper2 .related a + a { border-top-color: var(--paper); }
@media (min-width: 900px) { .related a { grid-template-columns: minmax(0, 2fr) minmax(0, 6fr) auto; align-items: baseline; } }
.related .h3 { font-size: 1.25rem; }
.related a:hover .h3 { text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--signal); text-underline-offset: 0.25em; }

/* Legal and other long reading */
.doc { max-width: 72ch; }
.doc h2 { font-size: clamp(1.375rem, 1.15rem + 0.8vw, 1.75rem); font-weight: 780; font-stretch: 108%; line-height: 1.2; margin: 2em 0 0.6em; }
.doc p, .doc li { color: var(--ink-2); }
.doc p + p { margin-top: 0.9em; }
.doc ul { margin-top: 0.8em; display: grid; gap: 8px; }
.doc ul li { position: relative; padding-left: 22px; }
.doc ul li::before { content: ""; position: absolute; left: 0; top: 0.68em; width: 10px; height: 3px; background: var(--ink); }
.doc b, .doc strong { color: var(--ink); }
.doc a { color: var(--link); text-decoration: underline; text-underline-offset: 0.2em; }

.field-paper2 .chips a { background: var(--paper); }
.field-paper2 .chips a:hover { background: var(--paper-3); }
.field-paper2 .ui { background: #fbfbf8; }
.after .ticks svg { color: var(--mark); }
@media (min-width: 1100px) { .items.four { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.sheet { background: var(--paper-2); border-radius: var(--radius); padding: clamp(24px, 3vw, 40px); }
.field-paper2 .sheet { background: var(--paper); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; }
.tags .tag { background: var(--paper-2); font-size: 0.8125rem; padding: 4px 12px; }
.figs.long .fig span { font-size: 1rem; line-height: 1.45; }
.sheet.figs .fig b { font-size: clamp(2rem, 1.3rem + 1.8vw, 3rem); }
.ui-bar .redact { background: var(--on-forest-2); color: var(--on-forest-2); }
.split .h2 { font-size: clamp(2rem, 1.3rem + 2vw, 3rem); }
.proj .fig b, .casestep .fig b { font-size: clamp(1.5rem, 1.1rem + 0.9vw, 2rem); }
.fig b { overflow-wrap: normal; }
.tag { flex: none; }
.ui-col .fig b { font-size: 1.75rem; }
.proj .fig b { white-space: nowrap; font-size: clamp(1.375rem, 1rem + 0.8vw, 1.75rem); }
.qa div.ans > * + * { margin-top: 0.8em; }
.total-line { margin-top: 24px; padding-top: 18px; border-top: 3px solid var(--ink); }
.after .total-line { border-top-color: var(--mark); }
.total-line b { display: block; font-size: clamp(1.75rem, 1.3rem + 1.4vw, 2.5rem); font-weight: 800; font-stretch: 112%; letter-spacing: -0.02em; line-height: 1.05; font-variant-numeric: tabular-nums; }
.total-line span { display: block; margin-top: 6px; }
.story dl { display: grid; gap: 16px; }
.story dt { font-weight: 700; }
.story dd { margin-top: 4px; color: var(--ink-2); }
.after dd, .after .total-line span { color: var(--on-forest-2); }
.before .total-line span { color: var(--ink-2); }
.yes { color: var(--link); font-weight: 700; }
.no { color: var(--ink-2); }

.compare .yes { color: var(--link); font-weight: 700; }
.ui-bar .tag { color: var(--ink); }

.title.long { font-size: clamp(2rem, 1rem + 3.2vw, 3.75rem); max-width: 22ch; }
.case-hero .lead { max-width: 60ch; }
.case-hero .sheet { margin-top: clamp(32px, 4vw, 56px); }
.math { margin-top: 32px; padding: 20px 24px; border-radius: var(--radius); background: var(--paper); max-width: 72ch; }
.field-paper2 .math { background: var(--paper); }
.math b { color: var(--ink); }
.ui-who { display: flex; align-items: center; gap: 10px; }
.ui-who i { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 999px; background: var(--paper-2); font-style: normal; font-size: 0.75rem; font-weight: 700; flex: none; }

/* Grid items may shrink below their content width; wide tables scroll inside their panel */
.casestep > *, .proj > *, .story > *, .split > *, .about > *, .page-hero-grid > *, .faq > * { min-width: 0; }
.ui-body { overflow-x: auto; }

/* =====================================================================
   Governance components (November 2026 revamp)
   ===================================================================== */

/* Reference chips: article and section numbers, set in mono */
.ref {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 3px;
  background: var(--paper-2);
  color: var(--ink);
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.6;
  letter-spacing: 0;
  white-space: nowrap;
}
.field-paper2 .ref, .sheet .ref { background: var(--paper); }
.field-forest .ref { background: var(--forest-2); color: var(--on-forest); }
.refs { display: flex; flex-wrap: wrap; gap: 6px; }
.mono { font-family: var(--mono); font-size: 0.92em; letter-spacing: 0; }

/* Homepage hero on the dark field */
.hero.field-forest { padding-top: clamp(48px, 7vw, 104px); }
.hero.field-forest .lead { color: var(--on-forest-2); }
.hero.field-forest .lead b { color: var(--on-forest); font-weight: 600; }
.hero.field-forest .promises { color: var(--on-forest-2); }
.hero.field-forest .promises svg { color: var(--mark); }
.hero.field-forest .tlink { color: var(--on-forest); }
.hero h1 { max-width: 17ch; }

/* News and research ledger: one sourced item per row */
.news-item { display: grid; gap: 12px 48px; padding-block: clamp(24px, 3vw, 36px); }
.news-item + .news-item { border-top: 3px solid var(--ink); }
.field-forest .news-item + .news-item { border-top-color: var(--forest-2); }
.news-fig b { display: block; font-size: clamp(2rem, 1.4rem + 2vw, 3.25rem); font-weight: 760; font-stretch: 104%; line-height: 1; letter-spacing: -0.02em; font-variant-numeric: tabular-nums lining-nums; }
.news-fig span { display: block; margin-top: 8px; color: var(--ink-2); font-size: var(--step-small); font-weight: 550; max-width: 24ch; }
.news-item .h3 { margin-bottom: 8px; }
.news-item p.muted { max-width: 60ch; }
.news-src { font-size: var(--step-small); color: var(--ink-2); }
.news-src b { display: block; color: var(--ink); font-weight: 650; }
.news-src a { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; color: var(--ink); font-weight: 650; text-decoration: underline; text-decoration-thickness: 2px; text-decoration-color: var(--signal); text-underline-offset: 0.25em; }
.news-src a:hover { text-decoration-color: currentColor; }
.news-src a svg { width: 13px; height: 13px; }
.field-forest .news-fig span, .field-forest .news-src { color: var(--on-forest-2); }
.field-forest .news-src b, .field-forest .news-src a { color: var(--on-forest); }
@media (min-width: 1000px) {
  .news-item { grid-template-columns: minmax(0, 3fr) minmax(0, 6fr) minmax(0, 3fr); align-items: start; }
}
.news-note { margin-top: 28px; font-size: var(--step-small); color: var(--ink-2); max-width: 70ch; }

/* Controls table: what we build and the rules it supports */
.controls { min-width: 760px; }
.controls tbody th { width: 24%; }
.controls td .refs { gap: 5px; }
.controls td p { color: var(--ink-2); }
.controls td p + .refs { margin-top: 8px; }

/* Governance section on case studies: a definition grid under thick bars */
.gov { display: grid; gap: 0 56px; }
@media (min-width: 900px) { .gov { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.gov > div { padding: 20px 0 24px; border-top: 3px solid var(--ink); }
.gov dt { font-weight: 700; font-stretch: 102%; font-size: 1.125rem; }
.gov dd { margin: 8px 0 0; color: var(--ink-2); max-width: 58ch; }
.gov dd + dd { margin-top: 10px; }
.gov-maps { margin-top: clamp(28px, 3vw, 40px); padding: clamp(20px, 3vw, 32px); border-radius: var(--radius); background: var(--paper); }
.field-paper2 .gov-maps { background: var(--paper); }
.gov-maps h3 { margin-bottom: 14px; }
.gov-maps ul { display: grid; gap: 12px; }
.gov-maps li { display: grid; gap: 4px 20px; }
@media (min-width: 900px) { .gov-maps li { grid-template-columns: minmax(0, 3fr) minmax(0, 7fr); align-items: baseline; } }
.gov-maps li b { font-weight: 650; }
.gov-maps li span { color: var(--ink-2); }
.gov-note { margin-top: 18px; font-size: var(--step-small); color: var(--ink-2); max-width: 72ch; }

/* What we do and don't claim */
.claims { display: grid; gap: 40px 72px; }
@media (min-width: 1000px) { .claims { grid-template-columns: minmax(0, 6fr) minmax(0, 6fr); } }
.claims h3 { margin-bottom: 16px; }
.claims li { position: relative; padding-left: 30px; }
.claims li + li { margin-top: 14px; }
.claims li svg { position: absolute; left: 0; top: 4px; width: 18px; height: 18px; color: var(--mark); }
.claims .not li::before { content: ""; position: absolute; left: 2px; top: 0.7em; width: 14px; height: 3px; background: var(--on-forest-2); }

/* Footer: a plain (non-link) list */
.foot-plain li { color: var(--on-forest-2); }
.foot h2 { color: var(--on-forest); }
@media (min-width: 1100px) { .foot-grid { grid-template-columns: minmax(0, 3fr) minmax(0, 2.4fr) minmax(0, 1.6fr) minmax(0, 1.6fr); } }

/* Data card beside each project on the case study hub */
.datacard { background: var(--paper-2); border-radius: 8px; padding: clamp(20px, 2.4vw, 28px); }
.datacard h4 { font-size: 0.9375rem; font-weight: 700; margin-bottom: 4px; }
.datacard p { color: var(--ink-2); font-size: 0.9375rem; line-height: 1.45; }
.datacard > div + div { margin-top: 14px; padding-top: 14px; border-top: 3px solid var(--paper); }
.datacard .refs { margin-top: 6px; }
.datacard .ref { background: var(--paper); }

/* Masking example: the same prompt before and after */
.mask-pair { display: grid; gap: 10px; }
.mask-pair .label { font-family: var(--mono); font-size: 0.75rem; font-weight: 600; color: var(--ink-2); margin-bottom: 4px; }
.mask-pair .box { padding: 12px 14px; border-radius: 6px; background: var(--paper-2); line-height: 1.5; }
.mask-pair .box.sent { background: var(--mint); }
.pii { background: #f1e3a6; padding: 0 3px; border-radius: 2px; }
.tok { font-family: var(--mono); font-size: 0.85em; background: var(--forest); color: var(--on-forest); padding: 1px 5px; border-radius: 3px; white-space: nowrap; }

.gov-maps .ref { background: var(--paper-2); margin-left: 4px; }
.related .sh { align-items: baseline; }
.tags .tag.ok { background: var(--mint); }

/* =====================================================================
   Diagrams and data graphics (November 2026)
   ===================================================================== */

/* Flow diagram: columns of nodes joined by arrows. Rows on wide screens,
   a vertical stack on phones. Each page sets --cols for its column widths. */
.flow { display: grid; gap: 0; margin: 0; }
.flow-col { display: grid; gap: 8px; align-content: center; min-width: 0; }
.flow-label { font-family: var(--mono); font-size: 0.75rem; font-weight: 600; color: var(--ink-2); letter-spacing: 0; }
.flow-col.zone { padding: 14px; border: 2px dashed var(--ink-2); border-radius: 10px; }
.field-forest .flow-col.zone { border-color: var(--on-forest-2); }
.node { padding: 12px 14px; border-radius: 6px; background: #fbfbf8; line-height: 1.35; }
.node b { display: block; font-weight: 650; font-size: 0.9375rem; }
.node span { display: block; margin-top: 2px; font-size: 0.8125rem; color: var(--ink-2); }
.node .refs { margin-top: 8px; gap: 4px; }
.node .ref { font-size: 0.6875rem; padding: 1px 6px; }
.node.ctl { background: var(--forest); color: var(--on-forest); }
.node.ctl span { color: var(--on-forest-2); }
.node.ctl .ref { background: var(--forest-2); color: var(--on-forest); }
.node.ok { background: var(--mint); }
.node.ok .ref { background: #fbfbf8; }
.node.store { background: var(--paper-3); }
.node.no { background: transparent; outline: 2px dashed var(--paper-3); outline-offset: -2px; }
.node.no b { text-decoration: line-through; text-decoration-thickness: 2px; text-decoration-color: var(--ink-2); color: var(--ink-2); }
.field-paper2 .node.store { background: var(--paper); }
.field-paper2 .node.no { outline-color: var(--paper); }
.flow-arrow { position: relative; min-height: 48px; display: flex; align-items: center; justify-content: flex-start; padding-left: 28px; }
.flow-arrow::before { content: ""; position: absolute; left: 13px; top: 6px; bottom: 12px; width: 2px; background: var(--ink-2); }
.flow-arrow::after { content: ""; position: absolute; left: 8px; bottom: 4px; border-top: 9px solid var(--ink-2); border-left: 6px solid transparent; border-right: 6px solid transparent; }
.flow-arrow span { font-family: var(--mono); font-size: 0.6875rem; color: var(--ink-2); line-height: 1.3; }
.flow-arrow i { position: absolute; left: 10px; top: 6px; width: 8px; height: 8px; border-radius: 99px; background: var(--signal); opacity: 0; }
@media (min-width: 900px) {
  .flow { grid-template-columns: var(--cols); align-items: center; }
  .flow-arrow { min-height: 0; height: 100%; padding: 0 6px; justify-content: center; align-items: center; }
  .flow-arrow::before { left: 6px; right: 14px; top: 50%; bottom: auto; width: auto; height: 2px; }
  .flow-arrow::after { left: auto; right: 4px; bottom: auto; top: calc(50% - 5px); border-top: 6px solid transparent; border-bottom: 6px solid transparent; border-left: 10px solid var(--ink-2); border-right: 0; }
  .flow-arrow span { position: absolute; left: 4px; right: 4px; bottom: calc(50% + 8px); text-align: center; }
  .flow-arrow i { top: calc(50% - 3px); left: 6px; }
}
@media (prefers-reduced-motion: no-preference) {
  .flow-arrow i { animation: packet-down 2.6s var(--ease) infinite; }
  @media (min-width: 900px) { .flow-arrow i { animation-name: packet-right; } }
  .flow-arrow:nth-of-type(4n) i { animation-delay: 1.3s; }
}
@keyframes packet-down { 0% { opacity: 0; transform: translateY(0); } 20% { opacity: 1; } 70% { opacity: 1; transform: translateY(18px); } 100% { opacity: 0; transform: translateY(22px); } }
@keyframes packet-right { 0% { opacity: 0; left: 6px; } 20% { opacity: 1; } 75% { opacity: 1; left: calc(100% - 22px); } 100% { opacity: 0; left: calc(100% - 22px); } }
.flow-wrap { padding: clamp(18px, 2.6vw, 32px); border-radius: 10px; background: var(--paper-2); }
.field-paper2 .flow-wrap { background: var(--paper); }
.flow-cap { margin-top: 14px; font-size: var(--step-small); color: var(--ink-2); max-width: 72ch; }
.flow-key { display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 14px; font-size: 0.8125rem; color: var(--ink-2); }
.flow-key span { display: inline-flex; align-items: center; gap: 6px; }
.flow-key i { width: 14px; height: 14px; border-radius: 3px; display: inline-block; }
.flow-key .k-ctl { background: var(--forest); }
.flow-key .k-ok { background: var(--mint); }
.flow-key .k-no { outline: 2px dashed var(--ink-2); outline-offset: -2px; }
.flow-key .k-zone { border: 2px dashed var(--ink-2); border-radius: 3px; }

/* Timeline: dated milestones on a proportional track (wide), a rail (narrow) */
.tl { position: relative; margin: 0; }
.tl ol { display: grid; gap: 18px; padding-left: 26px; border-left: 3px solid var(--ink); }
.tl li { position: relative; }
.tl li::before { content: ""; position: absolute; left: -34px; top: 4px; width: 13px; height: 13px; border-radius: 99px; background: var(--paper); border: 3px solid var(--ink); }
.tl li.is-past::before { background: var(--ink); }
.tl time { display: block; font-family: var(--mono); font-size: 0.8125rem; font-weight: 600; }
.tl b { display: block; font-weight: 650; line-height: 1.3; margin-top: 2px; }
.tl span { display: block; font-size: var(--step-small); color: var(--ink-2); margin-top: 2px; }
.tl .tl-moved b::after { content: " (moved)"; font-weight: 500; color: var(--ink-2); }
.tl-now { font-family: var(--mono); font-size: 0.75rem; font-weight: 600; color: var(--link); }
.tl ol .tl-now-item::before { background: var(--signal); border-color: var(--signal); }
@media (min-width: 1000px) {
  .tl { height: 230px; }
  .tl ol { position: absolute; inset: 0; display: block; padding: 0; border: 0; }
  .tl ol::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 3px; background: var(--ink); }
  .tl li { position: absolute; left: var(--x); width: 15ch; transform: translateX(-7px); }
  .tl li::before { left: 0; top: auto; }
  .tl li:nth-child(odd) { bottom: calc(50% + 22px); }
  .tl li:nth-child(even) { top: calc(50% + 22px); }
  .tl li:nth-child(odd)::before { bottom: -29px; }
  .tl li:nth-child(even)::before { top: -29px; }
  .tl li::after { content: ""; position: absolute; left: 6px; width: 2px; height: 16px; background: var(--ink); }
  .tl li:nth-child(odd)::after { bottom: -16px; }
  .tl li:nth-child(even)::after { top: -16px; }
  .tl li.tl-right { transform: translateX(calc(-100% + 7px)); text-align: right; }
  .tl li.tl-right::before { left: auto; right: 0; }
  .tl li.tl-right::after { left: auto; right: 6px; }
}

/* Horizontal bars (one series): the value sets the width, labels sit outside the bar */
.bars { display: grid; gap: 18px; margin: 0; }
.bar-row { display: grid; gap: 6px 20px; }
.bar-row > p { font-weight: 600; line-height: 1.3; }
.bar-row > p span { display: block; font-weight: 500; font-size: var(--step-small); color: var(--ink-2); }
.bar-track { display: flex; align-items: center; gap: 12px; }
.bar { height: 28px; width: var(--w); min-width: 6px; background: var(--forest); border-radius: 0 4px 4px 0; }
.bar-val { font-weight: 760; font-variant-numeric: tabular-nums lining-nums; white-space: nowrap; }
.bar-val small { font-weight: 550; color: var(--ink-2); font-size: var(--step-small); }
@media (min-width: 900px) { .bar-row { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); align-items: center; } }
@media (prefers-reduced-motion: no-preference) {
  .js .bars.is-armed .bar { width: 6px; }
  .js .bars .bar { transition: width 0.9s var(--ease); }
}

.graphic-sec .sh { margin-bottom: clamp(28px, 3.5vw, 48px); }
.bar { flex: none; }
@media (min-width: 1000px) {
  .tl { height: 320px; }
  .tl ol { left: 10px; right: 10px; }
  .tl li { width: 17ch; }
}
.node.no b { text-decoration: none; color: var(--ink); }
.node.no b::before { content: "\2715"; display: inline-block; margin-right: 8px; font-size: 0.8em; color: #9a3b2e; }
.flow-wrap .ref { background: var(--paper-2); }
.field-paper2 .flow-wrap .node.no .ref, .flow-wrap .node.no .ref { background: var(--paper-2); }
.field-paper2 .flow-wrap .node.store { background: var(--paper-2); }
@media (max-width: 899px) {
  .bar-val { white-space: normal; min-width: 0; line-height: 1.2; }
  .bar-val small { display: block; }
}
@media (max-width: 999px) { .tl li::before { left: -37px; } }

/* Grouped platform list ("Where it runs") */
.stack { display: grid; gap: 28px 40px; }
@media (min-width: 640px) { .stack { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .stack { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.stack > div { padding-top: 16px; border-top: 3px solid var(--ink); }
.stack h3 { font-family: var(--mono); font-size: 0.8125rem; font-weight: 600; color: var(--ink-2); margin-bottom: 12px; letter-spacing: 0; }
.stack ul { display: flex; flex-wrap: wrap; gap: 8px; }
.stack li { padding: 6px 12px; border-radius: 999px; background: var(--paper); font-weight: 600; font-size: 0.9375rem; line-height: 1.3; }
.stack-more { margin-top: 28px; color: var(--ink-2); }
.bignum { white-space: nowrap; }
.foot-plain li.more { font-style: italic; }

/* Homepage hero: text left, illustration right */
.hero-grid { display: grid; gap: 48px 72px; align-items: center; }
@media (min-width: 1000px) { .hero-grid { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); } }
.hero-grid .display { font-size: clamp(2.5rem, 1.2rem + 4vw, 4.75rem); max-width: 14ch; }
.hero-grid .lead { margin-top: clamp(20px, 2.4vw, 32px); max-width: 46ch; }
.hero-grid .actions { margin-top: 32px; }
.hero-art { margin: 0; max-width: 520px; width: 100%; justify-self: center; }
.hero-art svg { width: 100%; height: auto; overflow: visible; }
.ha-text { font: 500 20px var(--font); }
.ha-small { font: 500 16px var(--font); }
.ha-title { font: 700 20px var(--font); }
.ha-mono { font: 500 13px var(--mono); }
.ha-pii { font: 500 16px var(--mono); }
@media (prefers-reduced-motion: reduce) { .ha-packet { display: none; } }
@media (prefers-reduced-motion: no-preference) {
  .ha-gate { animation: gate-pulse 3.2s ease-in-out infinite; }
}
@keyframes gate-pulse { 0%, 100% { stroke-opacity: 1; } 50% { stroke-opacity: 0.45; } }

/* Section head with just a heading and a button under it */
.sh.sh-stack { display: block; }
.sh.sh-stack .btn { margin-top: 24px; }
.field-paper2 .sh-stack .btn-ghost { background: var(--paper); }
.field-paper2 .sh-stack .btn-ghost:hover { background: var(--paper-3); }
