
:root {
  --ground-ink: #0E0F12;
  --on-ground-ink: #F2F1EC;
}

[data-theme="agx-light"] {
  color-scheme: light;
  --paper: #F5F3EE;
  --paper-warm: #EEEAE0;
  --paper-card: #FBFAF6;
  --ink: #14151A;
  --ink-soft: #2C2D34;
  --ink-mute: #6B6C75;
  --ink-faint: #A8A6A0;
  --rule: #D9D3C7;
  --rule-strong: #B5AE9F;
  --accent: #00A847;
  --accent-bright: #00C853;
  --accent-soft: #DBEFE2;
  --accent-glow: #C8F2D9;
  --focus: #007A33;
  --shadow: rgba(20, 21, 26, 0.16);
  --shadow-soft: rgba(20, 21, 26, 0.07);
  --px-opacity: 0.55;

  --canvas: #F5F3EE;
  --surface: #FBFAF6;
  --surface-muted: #EEEAE0;
  --line: #D9D3C7;
  --fg: #14151A;
  --fg-muted: #2C2D34;
  --fg-subtle: #62636C;
  --brand: #007A33;
  --brand-strong: #006E2E;
  --brand-fg: #F5F3EE;
  --positive: #007A33;  --positive-bg: #DBEFE2;
  --negative: #14151A;  --negative-bg: #EEEAE0;
  --caution:  #2C2D34;  --caution-bg:  #EEEAE0;
  --info:     #62636C;  --info-bg:     #EEEAE0;
  --scrim: 20, 21, 26;

  --move: #007A33;
  --move-deep: #006E2E;
  --move-fill: #00A847;
  --studio: #14151A;
  --studio-fg: #F5F3EE;
  --ai-native: #00A847;
  --ai-native-ink: #007A33;
  --ai-native-tint: #C8F2D9;
  --ai-native-wash: #DBEFE2;
  --incumbent: #6B6C75;
  --incumbent-ink: #2C2D34;
  --incumbent-tint: #B5AE9F;
  --incumbent-wash: #EEEAE0;
  --cyan: #00C853;
}

[data-theme="agx-dark"] {
  color-scheme: dark;
  --paper: #0E0F12;
  --paper-warm: #16181D;
  --paper-card: #181A20;
  --ink: #F2F1EC;
  --ink-soft: #D6D5CF;
  --ink-mute: #9A9A93;
  --ink-faint: #63645E;
  --rule: #2A2C33;
  --rule-strong: #3C3E47;
  --accent: #1FD968;
  --accent-bright: #00E25E;
  --accent-soft: #122A1C;
  --accent-glow: #16341F;
  --focus: #1FD968;
  --shadow: rgba(0, 0, 0, 0.5);
  --shadow-soft: rgba(0, 0, 0, 0.3);
  --px-opacity: 0.72;

  --canvas: #0E0F12;
  --surface: #181A20;
  --surface-muted: #16181D;
  --line: #2A2C33;
  --fg: #F2F1EC;
  --fg-muted: #D6D5CF;
  --fg-subtle: #9A9A93;
  --brand: #1FD968;
  --brand-strong: #00E25E;
  --brand-fg: #0E0F12;
  --positive: #1FD968;  --positive-bg: #122A1C;
  --negative: #F2F1EC;  --negative-bg: #16181D;
  --caution:  #D6D5CF;  --caution-bg:  #16181D;
  --info:     #9A9A93;  --info-bg:     #16181D;
  --scrim: 14, 15, 18;

  --move: #1FD968;
  --move-deep: #00E25E;
  --move-fill: #1FD968;
  --studio: #F2F1EC;
  --studio-fg: #0E0F12;
  --ai-native: #1FD968;
  --ai-native-ink: #00E25E;
  --ai-native-tint: #16341F;
  --ai-native-wash: #122A1C;
  --incumbent: #9A9A93;
  --incumbent-ink: #D6D5CF;
  --incumbent-tint: #3C3E47;
  --incumbent-wash: #16181D;
  --cyan: #00E25E;
}

[data-theme="agx-accessibility-light"] {
  color-scheme: light;
  --paper: #FFFFFF; --paper-warm: #EEEAE0; --paper-card: #FFFFFF;
  --ink: #14151A; --ink-soft: #14151A; --ink-mute: #2C2D34; --ink-faint: #6B6C75;
  --rule: #B5AE9F; --rule-strong: #6B6C75;
  --accent: #006E2E; --accent-bright: #008A3A; --accent-soft: #DBEFE2; --accent-glow: #C8F2D9;
  --focus: #006E2E; --shadow: rgba(20, 21, 26, 0.2); --shadow-soft: rgba(20, 21, 26, 0.1); --px-opacity: 0.4;
  --canvas: #FFFFFF; --surface: #FFFFFF; --surface-muted: #EEEAE0;
  --line: #6B6C75; --fg: #14151A; --fg-muted: #14151A; --fg-subtle: #2C2D34;
  --brand: #006E2E; --brand-strong: #14151A; --brand-fg: #FFFFFF;
  --positive: #006E2E; --positive-bg: #DBEFE2;
  --negative: #14151A; --negative-bg: #EEEAE0;
  --caution:  #14151A; --caution-bg:  #EEEAE0;
  --info:     #2C2D34; --info-bg:     #EEEAE0;
  --scrim: 20, 21, 26;
  --move: #006E2E; --move-deep: #14151A; --move-fill: #006E2E; --studio: #14151A; --studio-fg: #FFFFFF;
  --ai-native: #006E2E; --ai-native-ink: #006E2E; --ai-native-tint: #C8F2D9; --ai-native-wash: #DBEFE2;
  --incumbent: #2C2D34; --incumbent-ink: #14151A; --incumbent-tint: #B5AE9F; --incumbent-wash: #EEEAE0;
  --cyan: #008A3A;
}
[data-theme="agx-accessibility-dark"] {
  color-scheme: dark;
  --paper: #000000; --paper-warm: #16181D; --paper-card: #0E0F12;
  --ink: #FFFFFF; --ink-soft: #F2F1EC; --ink-mute: #D6D5CF; --ink-faint: #9A9A93;
  --rule: #9A9A93; --rule-strong: #D6D5CF;
  --accent: #1FD968; --accent-bright: #00E25E; --accent-soft: #122A1C; --accent-glow: #16341F;
  --focus: #00E25E; --shadow: rgba(0, 0, 0, 0.6); --shadow-soft: rgba(0, 0, 0, 0.4); --px-opacity: 0.6;
  --canvas: #000000; --surface: #0E0F12; --surface-muted: #16181D;
  --line: #9A9A93; --fg: #FFFFFF; --fg-muted: #F2F1EC; --fg-subtle: #D6D5CF;
  --brand: #1FD968; --brand-strong: #00E25E; --brand-fg: #000000;
  --positive: #1FD968; --positive-bg: #122A1C;
  --negative: #FFFFFF; --negative-bg: #16181D;
  --caution:  #F2F1EC; --caution-bg:  #16181D;
  --info:     #D6D5CF; --info-bg:     #16181D;
  --scrim: 0, 0, 0;
  --move: #1FD968; --move-deep: #00E25E; --move-fill: #1FD968; --studio: #FFFFFF; --studio-fg: #000000;
  --ai-native: #1FD968; --ai-native-ink: #00E25E; --ai-native-tint: #16341F; --ai-native-wash: #122A1C;
  --incumbent: #D6D5CF; --incumbent-ink: #FFFFFF; --incumbent-tint: #3C3E47; --incumbent-wash: #16181D;
  --cyan: #00E25E;
}

:root {
  --report-blue:   var(--incumbent);
  --report-teal:   var(--accent-bright);
  --report-amber:  var(--rule-strong);
  --report-red:    var(--fg-muted);
  --report-purple: var(--accent);

  --accent-strong: var(--brand-strong);
  --accent-fg: var(--brand-fg);

  --font-display: 'Bricolage Grotesque', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'Geist', -apple-system, system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;
  --f-sans: var(--font-body);
  --f-display: var(--font-display);
  --f-serif: var(--font-display);
  --f-mono: var(--font-mono);

  --fs-kicker: clamp(0.6875rem, 0.66rem + 0.14vw, 0.75rem);
  --fs-small:  clamp(0.8125rem, 0.79rem + 0.12vw, 0.875rem);
  --fs-body:   clamp(0.9375rem, 0.90rem + 0.19vw, 1.0625rem);
  --fs-lead:   clamp(1.0625rem, 0.98rem + 0.42vw, 1.375rem);
  --fs-h3:     clamp(1.125rem, 1.04rem + 0.42vw, 1.4375rem);
  --fs-h2:     clamp(1.9rem, 4.5vw, 3.1rem);
  --fs-h1:     clamp(2.6rem, 6.5vw, 5rem);
  --fs-stat:   clamp(1.75rem, 1.24rem + 2.5vw, 3.25rem);
  --step-h1: var(--fs-h1);
  --step-h2: var(--fs-h2);
  --step-section: clamp(70px, 10vw, 130px);

  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
  --r-pill: 999px;

  --u: 8px;
  --max: 1180px;
  --maxw: var(--max);
  --gutter: clamp(20px, 5vw, 64px);

  --transition: 0.25s ease;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

@property --angle {
  syntax: '<angle>';
  inherits: false;
  initial-value: 0deg;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
:target, [id] { scroll-margin-top: 96px; }

body {
  margin: 0;
  background: var(--canvas);
  color: var(--fg);
  font-family: var(--f-sans);
  font-size: var(--fs-body);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4, .lead, blockquote p { text-wrap: balance; }
p, li, dd { text-wrap: pretty; }

h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--f-display);
  font-weight: 600;
  line-height: 1.08;
  letter-spacing: -0.022em;
}
h1 { font-size: var(--fs-h1); line-height: 0.98; letter-spacing: -0.038em; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); letter-spacing: -0.012em; line-height: 1.25; }
p  { margin: 0 0 1em; }
a  { color: inherit; }

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

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 999;
  background: var(--brand); color: var(--brand-fg);
  padding: 12px 20px; border-radius: 0 0 var(--r-md) 0;
  font-weight: 600; text-decoration: none;
}
.skip:focus { left: 0; }

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 3px;
}

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1 !important; transform: none !important; }
}

.wrap { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(56px, 9vw, 128px); }
.section + .section { border-top: 1px solid var(--line); }
.stack > * + * { margin-top: calc(var(--u) * 2); }

.grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
.g-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 880px) { .g-3, .g-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .g-2, .g-3, .g-4 { grid-template-columns: 1fr; } }

.kicker {
  font-family: var(--f-mono);
  font-size: var(--fs-kicker);
  font-weight: 500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--fg-subtle);
  margin: 0 0 calc(var(--u) * 1.5);
}
.lead { font-size: var(--fs-lead); line-height: 1.45; color: var(--fg-muted); max-width: 62ch; }
.muted { color: var(--fg-muted); }
.subtle { color: var(--fg-subtle); font-size: var(--fs-small); }
.mono { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
.measure { max-width: 68ch; }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: clamp(20px, 2.6vw, 32px);
}
.card h3 { margin-bottom: calc(var(--u) * 1.25); }
.card p:last-child { margin-bottom: 0; }

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 13px 22px;
  border: 1px solid transparent;
  border-radius: var(--r-md);
  font: inherit; font-weight: 600;
  text-decoration: none; cursor: pointer;
  transition: background 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.2s var(--ease);
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brand); color: var(--brand-fg); }
.btn-primary:hover { background: var(--brand-strong); }
.btn-ghost { background: transparent; color: var(--fg); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--fg-subtle); background: var(--surface-muted); }

.tag {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--f-mono); font-size: var(--fs-kicker);
  letter-spacing: 0.08em; text-transform: uppercase; font-weight: 500;
  padding: 5px 10px; border-radius: var(--r-sm);
  background: var(--surface-muted); color: var(--fg-muted);
  border: 1px solid var(--line);
}
.tag-proven { background: var(--positive-bg); color: var(--positive); border-color: transparent; }
.tag-progress { background: transparent; color: var(--fg-subtle); border-color: var(--line); }
.tag-draft { background: var(--negative-bg); color: var(--negative); border-color: transparent; }

.stat .n {
  display: block;
  font-family: var(--f-display);
  font-size: var(--fs-stat);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
}
.stat .l {
  display: block;
  margin-top: 10px;
  font-size: var(--fs-small);
  color: var(--fg-muted);
  line-height: 1.35;
}

table.tbl { width: 100%; border-collapse: collapse; font-size: var(--fs-small); }
table.tbl th, table.tbl td {
  text-align: left; padding: 14px 16px;
  border-bottom: 1px solid var(--line); vertical-align: top;
}
table.tbl th {
  font-family: var(--f-mono); font-size: var(--fs-kicker);
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--fg-subtle); font-weight: 500;
}
table.tbl tbody tr:hover { background: var(--surface-muted); }
.tbl-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

blockquote.pull {
  margin: 0; padding: 4px 0 4px clamp(20px, 2.4vw, 32px);
  border-left: 3px solid var(--brand);
}
blockquote.pull p {
  font-size: var(--fs-lead); line-height: 1.35;
  letter-spacing: -0.015em; margin-bottom: 0.6em;
}
blockquote.pull cite { font-style: normal; font-size: var(--fs-small); color: var(--fg-subtle); }

.topbar {
  position: sticky; top: 0; z-index: 90;
  display: flex; align-items: center; gap: clamp(16px, 3vw, 40px);
  padding: 14px var(--gutter);
  background: color-mix(in srgb, var(--canvas) 88%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar .brand {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--f-display);
  font-weight: 600; letter-spacing: -0.02em; text-decoration: none; white-space: nowrap;
}
.topbar .brand .mk { font-size: 1.0625rem; }
@media (max-width: 1040px) { .topbar .brand .subtle { display: none; } }
.topnav { margin-left: auto; display: flex; align-items: center; gap: clamp(12px, 1.6vw, 24px); }
.topnav a {
  font-family: var(--f-mono); font-size: var(--fs-kicker);
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--fg-subtle); text-decoration: none; white-space: nowrap;
  transition: color 0.2s var(--ease);
}
.topnav a:hover { color: var(--fg); }
.topnav a.on { color: var(--brand); font-weight: 600; }
@media (max-width: 1080px) {
  .topnav { overflow-x: auto; scrollbar-width: none; }
  .topnav::-webkit-scrollbar { display: none; }
}
@media (max-width: 660px) {
  .topnav {
    mask-image: linear-gradient(90deg, #000 86%, transparent);
    -webkit-mask-image: linear-gradient(90deg, #000 86%, transparent);
  }
}

.sidenav {
  position: fixed; right: calc(var(--u) * 2.4); top: 50%;
  transform: translateY(-50%);
  z-index: 80;
  display: flex; flex-direction: column;
  transition: opacity 0.4s var(--ease);
}
.sidenav a {
  display: flex; align-items: center; justify-content: flex-end; gap: 12px;
  padding: calc(var(--u) * 0.75) 0;
  text-decoration: none; color: var(--fg-subtle);
  font-family: var(--f-mono); font-size: var(--fs-kicker);
  letter-spacing: 0.08em; text-transform: uppercase;
}
.sidenav .lbl {
  white-space: nowrap; opacity: 0; transform: translateX(10px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}
.sidenav:hover .lbl, .sidenav:focus-within .lbl { opacity: 1; transform: none; }
.sidenav .dot {
  width: 8px; height: 8px; flex: 0 0 8px; border-radius: 50%;
  background: var(--line);
  transition: background 0.25s var(--ease), transform 0.3s var(--ease), box-shadow 0.25s var(--ease);
}
.sidenav a:hover { color: var(--fg); }
.sidenav a:hover .dot { background: var(--fg-subtle); }
.sidenav a.on { color: var(--brand); }
.sidenav a.on .dot {
  background: var(--brand);
  transform: scale(1.55);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 18%, transparent);
}
.sidenav--invert a { color: rgba(255, 255, 255, 0.66); }
.sidenav--invert .dot { background: rgba(255, 255, 255, 0.34); }
.sidenav--invert a:hover { color: #fff; }
.sidenav--invert a:hover .dot { background: rgba(255, 255, 255, 0.75); }
.sidenav--invert a.on { color: #fff; }
.sidenav--invert a.on .dot {
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.22);
}

@media (max-width: 1180px) { .sidenav { display: none; } }

.progress {
  position: fixed; top: 0; left: 0; height: 2px; width: 0;
  background: var(--brand); z-index: 95;
  transition: width 0.1s linear;
}

.hero { position: relative; isolation: isolate; overflow: hidden; }
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-scrim {
  position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(100deg,
      rgba(var(--scrim), 0.92) 0%,
      rgba(var(--scrim), 0.78) 38%,
      rgba(var(--scrim), 0.32) 72%,
      rgba(var(--scrim), 0.20) 100%),
    linear-gradient(180deg, rgba(var(--scrim), 0.55) 0%, rgba(var(--scrim), 0.10) 30%);
}
@media (max-width: 820px) {
  .hero-scrim {
    background:
      linear-gradient(180deg,
        rgba(var(--scrim), 0.86) 0%,
        rgba(var(--scrim), 0.74) 55%,
        rgba(var(--scrim), 0.42) 100%);
  }
}
.hero-inner {
  position: relative;
  padding-block: clamp(72px, 12vw, 148px);
  color: #fff;
}
.hero h1 { color: #fff; max-width: 24ch; }
.hero .lead { color: rgba(255, 255, 255, 0.92); max-width: 46ch; }
.hero .kicker { color: rgba(255, 255, 255, 0.72); }

.chaps { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.chaps li {
  display: grid;
  grid-template-columns: 2.5ch minmax(0, 1fr) auto;
  gap: 14px;
  align-items: baseline;
  padding: 11px clamp(16px, 2.2vw, 26px);
  font-size: var(--fs-small);
}
.chaps li + li { border-top: 1px solid var(--line); }
.chaps__n,
.chaps__d {
  font-family: var(--f-mono);
  font-size: var(--fs-kicker);
  color: var(--fg-subtle);
  font-variant-numeric: tabular-nums;
}
.chaps__t { color: var(--fg); }
.chaps__foot {
  margin: 0;
  padding: 11px clamp(16px, 2.2vw, 26px) 14px;
  border-top: 1px solid var(--line);
  background: var(--surface-muted);
  font-family: var(--f-mono);
  font-size: var(--fs-kicker);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--fg-subtle);
}

.pivot {
  background: var(--studio);
  color: var(--studio-fg);
  padding-block: clamp(64px, 10vw, 132px);
  text-align: center;
}
.pivot__k {
  font-family: var(--f-mono);
  font-size: var(--fs-kicker);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  opacity: 0.72;
  margin: 0 0 calc(var(--u) * 2.5);
}
.pivot__l {
  font-family: var(--f-display);
  font-size: clamp(1.125rem, 0.98rem + 0.72vw, 1.6rem);
  line-height: 1.42;
  letter-spacing: -0.014em;
  max-width: 40ch;
  margin: 0 auto;
  text-wrap: balance;
}
.pivot__cue {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: clamp(32px, 4vw, 52px);
  padding: 14px 26px 18px;
  border: 1px solid currentColor;
  border-radius: var(--r-pill);
  font-weight: 600;
  text-decoration: none;
  color: inherit;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}
.pivot__cue:hover {
  background: color-mix(in srgb, var(--studio-fg) 12%, transparent);
  transform: translateY(2px);
}
.pivot__cue svg { animation: nudge 2.4s var(--ease) infinite; }

@keyframes nudge {
  0%, 62%, 100% { transform: translateY(0); opacity: 0.65; }
  78%           { transform: translateY(5px); opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .pivot__cue svg { animation: none; opacity: 1; }
}
.pivot + .section { border-top: 0; }

.rule { height: 1px; background: var(--line); border: 0; margin-block: calc(var(--u) * 4); }
.flow > * + * { margin-top: calc(var(--u) * 3); }
.row { display: flex; flex-wrap: wrap; gap: calc(var(--u) * 1.5); align-items: center; }

.reveal { opacity: 0; transform: translateY(16px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); }
.reveal.in { opacity: 1; transform: none; }

.draftbar {
  background: var(--caution-bg); color: var(--caution);
  font-family: var(--f-mono); font-size: var(--fs-kicker);
  letter-spacing: 0.1em; text-transform: uppercase;
  text-align: center; padding: 9px var(--gutter);
  border-bottom: 1px solid var(--line);
}

footer.site {
  padding-block: clamp(40px, 6vw, 72px);
  border-top: 1px solid var(--line);
  color: var(--fg-subtle); font-size: var(--fs-small);
}

@media print {
  .topbar, .sidenav, .progress, .draftbar, .btn { display: none !important; }
  .section { padding-block: 24px; break-inside: avoid; }
  body { background: #fff; color: #000; }
}
