/* ==========================================================================
   Conductor by Min15x — styles.css
   Token system per Build Guide v2, Part 7. Every color/font traces to a var.
   Lane colors are product concepts, never decoration:
     decide-500   = Decide lane, CTA, decision memory
     delegate-500 = Delegate lane, integrations, execution proof
     defer-500    = Defer lane, secondary structure
   ========================================================================== */

:root {
  /* Color — core tokens (Part 7) */
  --ink-950:      #0A0C10;   /* primary background */
  --ink-800:      #14171D;   /* card / section background */
  --ink-700:      #1B1F27;   /* elevated surface, glass panels */
  --paper-100:    #ECEEF1;   /* primary text */
  --paper-500:    #8B909A;   /* secondary / muted text (AA on ink-950) */
  --decide-500:   #E8A23D;   /* amber — Decide lane, CTA, decision memory */
  --delegate-500: #4C8DFF;   /* blue — Delegate lane, integrations, execution */
  --defer-500:    #6B7280;   /* slate — Defer lane, secondary content */

  /* Derived tokens (alpha variants of the above, still named variables) */
  --line:         rgba(236, 238, 241, 0.09);
  --line-strong:  rgba(236, 238, 241, 0.18);
  --decide-soft:  rgba(232, 162, 61, 0.10);
  --decide-line:  rgba(232, 162, 61, 0.45);
  --delegate-soft: rgba(76, 141, 255, 0.10);
  --delegate-line: rgba(76, 141, 255, 0.45);
  --defer-soft:   rgba(107, 114, 128, 0.14);
  --header-bg:    rgba(10, 12, 16, 0.82);

  /* Type */
  --font-display: "Space Grotesk", "IBM Plex Sans", sans-serif;
  --font-body:    "IBM Plex Sans", sans-serif;
  --font-mono:    "IBM Plex Mono", monospace;

  /* Rhythm */
  --wrap: 1080px;
  --measure: 720px;
  --section-pad: 96px;
  --radius: 12px;
}

/* --------------------------------------------------------------------------
   Base
   -------------------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink-950);
  color: var(--paper-100);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Grain overlay — one global texture layer (Part 7, motion item 5) */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 1000;
  pointer-events: none;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.8' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
}

img { max-width: 100%; height: auto; }

a { color: var(--paper-100); text-decoration-color: var(--line-strong); text-underline-offset: 3px; }
a:hover { color: var(--decide-500); }

/* Visible keyboard focus on every interactive element */
a:focus-visible,
button:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--decide-500);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection { background: var(--decide-line); color: var(--ink-950); }

/* --------------------------------------------------------------------------
   Typography
   -------------------------------------------------------------------------- */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2.5rem, 6vw, 4.25rem); }
h2 { font-size: clamp(1.7rem, 3.4vw, 2.4rem); }
h3 { font-size: 1.2rem; letter-spacing: -0.01em; }

p { margin: 0 0 1.1em; }
ul, ol { margin: 0 0 1.1em; padding-left: 1.3em; }
li { margin-bottom: 0.45em; }

.lede { font-size: 1.15rem; color: var(--paper-100); }
.muted { color: var(--paper-500); }
.small { font-size: 0.9rem; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--paper-500);
  margin: 0 0 1.1em;
}

.mono { font-family: var(--font-mono); }

.num {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--decide-500);
  display: block;
  margin-bottom: 0.6em;
}

.tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 3px 9px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--paper-500);
  vertical-align: middle;
}
.tag-modeled { border-color: var(--decide-line); color: var(--decide-500); }
.tag-built { border-color: var(--delegate-line); color: var(--delegate-500); }

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.measure { max-width: var(--measure); }

.section { padding: var(--section-pad) 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-alt { background: var(--ink-800); }

.section-head { max-width: var(--measure); margin-bottom: 48px; }

/* Ambient gradient mesh — background atmosphere only (Part 7, item 4) */
.has-mesh { position: relative; overflow: hidden; }
.mesh { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.mesh::before,
.mesh::after {
  content: "";
  position: absolute;
  width: 55vw;
  height: 55vw;
  min-width: 480px;
  min-height: 480px;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.07;
}
.mesh::before {
  background: radial-gradient(circle, var(--decide-500), transparent 65%);
  top: -22%; left: -12%;
}
.mesh::after {
  background: radial-gradient(circle, var(--delegate-500), transparent 65%);
  bottom: -28%; right: -12%;
}
.has-mesh > .wrap { position: relative; z-index: 1; }

/* --------------------------------------------------------------------------
   Header / nav
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 64px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--paper-100);
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand:hover { color: var(--paper-100); }
.brand-mark { display: block; border-radius: 6px; }
.brand-by { color: var(--paper-500); font-weight: 500; font-size: 0.85em; }

.site-nav { display: flex; align-items: center; gap: 26px; }
.site-nav a {
  text-decoration: none;
  color: var(--paper-500);
  font-size: 0.95rem;
}
.site-nav a:hover { color: var(--paper-100); }
.site-nav a[aria-current="page"] {
  color: var(--paper-100);
  box-shadow: 0 2px 0 0 var(--decide-500);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  color: var(--paper-100);
  font-family: var(--font-mono);
  font-size: 0.85rem;
  padding: 8px 14px;
  cursor: pointer;
}
/* Without JS the nav is always visible and the toggle is useless — hide it */
html:not(.js) .nav-toggle { display: none; }

.btn-nav { padding: 4px 10px; font-size: 0.5rem; }
.site-nav .btn-primary,
.site-nav .btn-primary:hover { color: var(--ink-950); }

/* --------------------------------------------------------------------------
   Buttons — CTA vocabulary is fixed (Part 3). Primary is magnetic (item 6).
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: -0.01em;
  text-decoration: none;
  padding: 14px 24px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  white-space: nowrap;
}

.btn-primary {
  background: var(--decide-500);
  color: var(--ink-950);
}
.btn-primary:hover { color: var(--ink-950); background: var(--paper-100); }

.btn-secondary {
  background: transparent;
  color: var(--paper-100);
  border-color: var(--line-strong);
}
.btn-secondary:hover { color: var(--paper-100); border-color: var(--paper-500); }

/* Magnetic displacement is set inline by JS; transition only under fine pointer */
.btn-primary.magnetic { will-change: transform; }
.btn-primary.magnetic:not(:hover) {
  transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.cta-row { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero { padding: 120px 0 96px; }
.hero-stack { text-align: center; }
.hero-stack .eyebrow { margin-bottom: 20px; }
.hero-stack .hero-title { margin: 0 auto; max-width: 18em; }
.hero-stack .graph-wrap { max-width: 880px; margin: 48px auto 0; text-align: left; }
.hero-stack .hero-sub { margin: 40px auto 0; max-width: 36em; }
.hero-stack .cta-row { justify-content: center; margin-top: 32px; }
.hero-title { font-weight: 650; }
.hero-sub { font-size: 1.12rem; color: var(--paper-500); max-width: 34em; }
.hero-sub strong { color: var(--paper-100); font-weight: 500; }

/* --------------------------------------------------------------------------
   Cards, lanes, grids
   -------------------------------------------------------------------------- */

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
}

.card {
  background: var(--ink-800);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
}
.card h3 { margin-top: 0; }
.card p:last-child { margin-bottom: 0; }

.card-decide   { border-top: 2px solid var(--decide-500); }
.card-delegate { border-top: 2px solid var(--delegate-500); }
.card-defer    { border-top: 2px solid var(--defer-500); }

/* Card used as a link (404 guide) — drop anchor chrome, keep card surface */
a.card-link { display: block; text-decoration: none; color: var(--paper-100); }
a.card-link:hover { border-color: var(--line-strong); color: var(--paper-100); }

.lane {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.lane::before { content: ""; width: 9px; height: 9px; border-radius: 2px; }
.lane-decide   { color: var(--decide-500); }
.lane-decide::before   { background: var(--decide-500); }
.lane-delegate { color: var(--delegate-500); }
.lane-delegate::before { background: var(--delegate-500); }
.lane-defer    { color: var(--paper-500); }
.lane-defer::before    { background: var(--defer-500); }

/* --------------------------------------------------------------------------
   Stats — real numbers only; counters via JS (Part 7, item 3)
   -------------------------------------------------------------------------- */

.stat-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.stat {
  background: var(--ink-800);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px 28px;
}
.stat-value {
  font-family: var(--font-mono);
  font-size: clamp(1.9rem, 4vw, 2.6rem);
  font-weight: 500;
  letter-spacing: -0.03em;
  color: var(--paper-100);
  display: block;
  margin-bottom: 6px;
}
.stat-label { color: var(--paper-500); font-size: 0.92rem; margin: 0; }
.stat .tag { margin-top: 12px; }

/* --------------------------------------------------------------------------
   Numbered steps (How It Works, pipeline, roadmap — genuinely sequential only)
   -------------------------------------------------------------------------- */

.steps { list-style: none; padding: 0; margin: 0; counter-reset: step; }
.steps li {
  position: relative;
  padding: 26px 0 26px 76px;
  border-top: 1px solid var(--line);
  counter-increment: step;
}
.steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 0; top: 28px;
  font-family: var(--font-mono);
  font-size: 0.95rem;
  color: var(--decide-500);
}
.steps h3 { margin-bottom: 0.35em; }
.steps p:last-child { margin-bottom: 0; }

/* --------------------------------------------------------------------------
   Demo — directive in, typed cards out
   -------------------------------------------------------------------------- */

.demo-block {
  background: var(--ink-800);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px;
  margin-bottom: 24px;
}
.demo-directive {
  border-left: 3px solid var(--paper-500);
  padding: 4px 0 4px 20px;
  margin-bottom: 26px;
}
.demo-directive p { font-size: 1.05rem; margin: 0; }
.demo-directive .demo-src {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--paper-500);
  display: block;
  margin-top: 10px;
}
.demo-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.demo-card {
  background: var(--ink-700);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 20px;
}
.demo-card p { font-size: 0.95rem; margin-bottom: 0.6em; }
.demo-card .demo-meta {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--paper-500);
  margin: 0;
}
.demo-card .lane { margin-bottom: 10px; }

/* --------------------------------------------------------------------------
   Video (embedded demo) — fixed aspect ratio to prevent layout shift
   -------------------------------------------------------------------------- */

.video-wrap {
  aspect-ratio: 16 / 9;
  background: var(--ink-800);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}
.video-wrap iframe { display: block; width: 100%; height: 100%; border: 0; }

/* --------------------------------------------------------------------------
   Execution graph — the signature element (Part 7)
   Node/edge colors come from lane tokens via CSS, never inline hex.
   -------------------------------------------------------------------------- */

.graph-wrap {
  background: var(--ink-800);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.graph { display: block; width: 100%; height: auto; }
.graph-mobile { display: none; }
.graph-caption {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--paper-500);
  margin: 16px 4px 0;
}

.graph .node rect {
  fill: var(--ink-700);
  stroke: var(--line-strong);
  stroke-width: 1;
  rx: 8px;
}
.graph .node text {
  font-family: var(--font-mono);
  font-size: 13px;
  fill: var(--paper-100);
  text-anchor: middle;
  dominant-baseline: central;
}
.graph .node .node-sub {
  font-size: 10px;
  fill: var(--paper-500);
}
.graph .n-decide rect   { stroke: var(--decide-500); fill: var(--decide-soft); }
.graph .n-delegate rect { stroke: var(--delegate-500); fill: var(--delegate-soft); }
.graph .n-defer rect    { stroke: var(--defer-500); fill: var(--defer-soft); }
.graph .n-memory rect   { stroke: var(--decide-line); }
.graph .n-exec rect     { stroke: var(--delegate-line); }

.graph .edge {
  fill: none;
  stroke: var(--line-strong);
  stroke-width: 1.5;
}
.graph .edge-memory { stroke: var(--decide-line); stroke-dasharray: 4 4; }
.graph .edge-label {
  font-family: var(--font-mono);
  font-size: 10px;
  fill: var(--paper-500);
  text-anchor: middle;
}

/* Interactive variant (Product): hover/focus highlights downstream */
.graph .node { cursor: default; }
.graph-interactive .node { cursor: pointer; }
.graph .node.dim, .graph .edge.dim, .graph .edge-label.dim { opacity: 0.18; }
.graph .edge.hl { stroke: var(--decide-500); stroke-width: 2.5; }
.graph .node.hl rect { stroke: var(--decide-500); stroke-width: 2; }
.graph .node:focus-visible { outline: none; }
.graph .node:focus-visible rect {
  stroke: var(--decide-500);
  stroke-width: 2.5;
}

/* --------------------------------------------------------------------------
   Tables (comparison)
   -------------------------------------------------------------------------- */

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
table { width: 100%; border-collapse: collapse; font-size: 0.95rem; min-width: 640px; }
caption {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--paper-500);
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
}
th, td { text-align: left; padding: 14px 20px; vertical-align: top; }
thead th {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--paper-500);
  border-bottom: 1px solid var(--line-strong);
  font-weight: 500;
}
tbody tr + tr td { border-top: 1px solid var(--line); }
tbody th { font-weight: 600; color: var(--paper-100); }
td { color: var(--paper-500); }
td strong, tbody th { color: var(--paper-100); }

/* --------------------------------------------------------------------------
   FAQ (details/summary — interactive without JS)
   -------------------------------------------------------------------------- */

.faq details { border-top: 1px solid var(--line); }
.faq details:last-of-type { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer;
  list-style: none;
  position: relative;
  padding: 24px 48px 24px 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.12rem;
  letter-spacing: -0.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 8px;
  top: 24px;
  font-family: var(--font-mono);
  font-size: 1.2rem;
  color: var(--decide-500);
}
.faq details[open] summary::after { content: "–"; }
.faq .faq-a { padding: 0 48px 26px 0; }
.faq .faq-a p:last-child { margin-bottom: 0; }

/* --------------------------------------------------------------------------
   Build log
   -------------------------------------------------------------------------- */

.log-list article {
  border-top: 1px solid var(--line);
  padding: 22px 0;
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  gap: 24px;
}
.log-list article:last-child { border-bottom: 1px solid var(--line); }
.log-date {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--paper-500);
  padding-top: 2px;
}
.log-list h3 { font-size: 1.02rem; margin-bottom: 0.3em; }
.log-list p { margin: 0; color: var(--paper-500); font-size: 0.96rem; }

/* --------------------------------------------------------------------------
   CTA block
   -------------------------------------------------------------------------- */

.cta-block {
  padding: var(--section-pad) 0;
  background: var(--ink-800);
  border-top: 1px solid var(--line);
  text-align: left;
}
.cta-block .cta-row { margin-top: 32px; }

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 48px;
  background: var(--ink-950);
}
.footer-line { font-size: 1.1rem; font-family: var(--font-display); font-weight: 600; letter-spacing: -0.01em; }
.footer-line a { color: var(--decide-500); text-decoration: none; }
.footer-line a:hover { text-decoration: underline; }
.footer-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 20px;
  margin: 28px 0;
}
.footer-nav, .footer-social { display: flex; flex-wrap: wrap; gap: 22px; }
.footer-nav a, .footer-social a {
  color: var(--paper-500);
  text-decoration: none;
  font-size: 0.92rem;
}
.footer-nav a:hover, .footer-social a:hover { color: var(--paper-100); }
.footer-fine { color: var(--paper-500); font-size: 0.85rem; margin: 0; }

/* --------------------------------------------------------------------------
   Page hero (interior pages)
   -------------------------------------------------------------------------- */

.page-hero { padding: 96px 0 64px; }
.page-hero h1 { max-width: 16em; }
.page-hero .lede { max-width: 36em; color: var(--paper-500); }

/* Founder */
.founder {
  display: grid;
  grid-template-columns: 180px minmax(0, 1fr);
  gap: 36px;
  align-items: start;
}
.founder img {
  border-radius: var(--radius);
  border: 1px solid var(--line);
  display: block;
}

/* Provenance note used under modeled claims */
.provenance {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--paper-500);
  border-left: 2px solid var(--decide-line);
  padding-left: 14px;
  margin-top: 18px;
}

/* Split block: de-risked vs not */
.split-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* --------------------------------------------------------------------------
   Motion (Part 7 — this list is exhaustive, nothing outside it)
   Items 1, 2, 7 live here gated behind JS + no-preference.
   Items 3, 6 are JS-driven with final values as the no-JS/reduce default.
   Items 4, 5 degrade to static by simply not animating.
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: no-preference) {

  html { scroll-behavior: smooth; }

  /* 1. Scroll-triggered reveals */
  html.js [data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
    transition-delay: var(--rd, 0ms);
  }
  html.js [data-reveal].revealed { opacity: 1; transform: translateY(0); }

  /* 2. Signature execution-graph draw-in (pathLength=1 makes this generic) */
  html.js [data-graph] .edge {
    stroke-dasharray: 1;
    stroke-dashoffset: 1;
    transition: stroke-dashoffset 0.5s ease-out;
    transition-delay: var(--d, 0ms);
  }
  html.js [data-graph] .edge-memory { stroke-dasharray: 4 4; } /* keep pattern */
  html.js [data-graph] .node,
  html.js [data-graph] .edge-label {
    opacity: 0;
    transition: opacity 0.4s ease-out;
    transition-delay: var(--d, 0ms);
  }
  html.js [data-graph].on .edge { stroke-dashoffset: 0; }
  html.js [data-graph].on .node,
  html.js [data-graph].on .edge-label { opacity: 1; }
  html.js [data-graph].on .node.dim,
  html.js [data-graph].on .edge.dim { opacity: 0.18; }

  /* 4. Ambient gradient mesh drift — transform only */
  .mesh::before { animation: mesh-a 26s ease-in-out infinite alternate; }
  .mesh::after  { animation: mesh-b 32s ease-in-out infinite alternate; }

  /* 7. Variable-weight hero headline */
  html.js .hero-title { font-weight: 350; transition: font-weight 0.6s ease-out; }
  html.js .hero-title.w-on { font-weight: 650; }
}

@keyframes mesh-a {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(6vw, 4vh, 0); }
}
@keyframes mesh-b {
  from { transform: translate3d(0, 0, 0); }
  to   { transform: translate3d(-5vw, -4vh, 0); }
}

/* --------------------------------------------------------------------------
   Responsive — 375 / 768 / 1440 per DoD
   -------------------------------------------------------------------------- */

@media (max-width: 900px) {
  :root { --section-pad: 64px; }
  .hero { padding: 72px 0 64px; }
  .hero-stack .graph-wrap { margin-top: 32px; }
  .grid-3, .stat-row { grid-template-columns: 1fr; }
  .grid-2, .split-2 { grid-template-columns: 1fr; }
  .demo-cards { grid-template-columns: 1fr; }
  .founder { grid-template-columns: 1fr; }
  .founder img { max-width: 220px; }
  .log-list article { grid-template-columns: 1fr; gap: 6px; }

  /* Mobile nav: collapsed only when JS is available */
  html.js .nav-toggle { display: block; }
  html.js .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--ink-800);
    border-bottom: 1px solid var(--line);
    padding: 12px 24px 20px;
  }
  html.js .site-nav.open { display: flex; }
  html.js .site-nav a { padding: 12px 0; font-size: 1rem; }
  html.js .site-nav a[aria-current="page"] { box-shadow: none; color: var(--decide-500); }
  html.js .btn-nav { margin-top: 12px; justify-content: center; }

  /* No-JS mobile: nav renders as a plain stacked list under the bar */
  html:not(.js) .header-inner { flex-wrap: wrap; padding: 12px 0; }
  html:not(.js) .site-nav { flex-wrap: wrap; gap: 16px; }
}

/* Compact execution-graph variant for mobile: swapped via CSS, no scaling, no scroll */
@media (max-width: 600px) {
  .graph-desktop { display: none; }
  .graph-mobile { display: block; }
  .graph-wrap { padding: 16px; }
}

@media (max-width: 480px) {
  body { font-size: 16px; }
  .btn { width: 100%; justify-content: center; }
  .site-nav .btn, .header-inner .btn { width: auto; }
  .steps li { padding-left: 56px; }
}
