:root {
  color-scheme: dark;
  --bg: #070b12;
  --ink: #f7f9fb;
  --muted: #aab6c6;
  --quiet: #738197;
  --line: rgba(148, 163, 184, .20);
  --panel: rgba(15, 23, 42, .76);
  --panel-2: rgba(30, 41, 59, .68);
  --green: #7dd3a7;
  --cyan: #67e8f9;
  --amber: #fbbf24;
  --coral: #fb7185;
  --shadow: 0 24px 80px rgba(0, 0, 0, .28);
  --radius: 22px;
  --page: min(100% - clamp(28px, 6vw, 96px), 1560px);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 18% -8%, rgba(103, 232, 249, .13), transparent 34rem),
    radial-gradient(circle at 82% 0%, rgba(125, 211, 167, .10), transparent 30rem),
    linear-gradient(180deg, #070b12 0%, #09111d 50%, #070b12 100%);
  color: var(--ink);
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(rgba(255,255,255,.016) 1px, transparent 1px) 0 0 / 112px 112px,
    linear-gradient(90deg, rgba(255,255,255,.012) 1px, transparent 1px) 0 0 / 112px 112px;
  mask-image: linear-gradient(180deg, rgba(0,0,0,.60), rgba(0,0,0,.08));
}
a { color: inherit; text-decoration: none; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 24px;
  width: 100%;
  min-height: 72px;
  margin: 0;
  padding: 14px max(clamp(18px, 4vw, 56px), calc((100vw - 1560px) / 2));
  background: rgba(7, 11, 18, .90);
  border-bottom: 1px solid rgba(148, 163, 184, .18);
  backdrop-filter: blur(18px);
}
.brand { display: inline-flex; align-items: center; gap: 12px; margin-right: auto; font-weight: 850; letter-spacing: -.02em; }
.brand-mark {
  position: relative;
  width: 34px;
  aspect-ratio: 1;
  border: 1px solid rgba(103, 232, 249, .55);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(125, 211, 167, .22), rgba(103, 232, 249, .20)), #0b1220;
  box-shadow: 0 0 30px rgba(103, 232, 249, .18);
}
.brand-mark::after { content: ""; position: absolute; inset: 7px; border-radius: 8px; border: 1px solid rgba(251, 191, 36, .50); transform: rotate(45deg); }
.site-nav { display: flex; align-items: center; gap: 6px; }
.site-nav a, .nav-toggle { border: 1px solid transparent; border-radius: 999px; padding: 10px 13px; color: var(--muted); font: inherit; font-size: 14px; font-weight: 720; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); border-color: rgba(103, 232, 249, .30); background: rgba(103, 232, 249, .08); }
.site-nav .github-link { color: #04111a; background: linear-gradient(135deg, var(--green), var(--cyan)); border-color: transparent; font-weight: 850; box-shadow: 0 10px 30px rgba(103, 232, 249, .14); }
.nav-toggle { display: none; color: var(--ink); background: rgba(15, 23, 42, .70); }

.hero, .page-hero, .section, .metrics-strip, .site-footer { position: relative; width: var(--page); margin-inline: auto; }
.hero, .page-hero {
  isolation: isolate;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 32px;
  background:
    radial-gradient(circle at 78% 22%, rgba(103, 232, 249, .10), transparent 28rem),
    radial-gradient(circle at 16% 78%, rgba(125, 211, 167, .08), transparent 26rem),
    rgba(15, 23, 42, .52);
  box-shadow: var(--shadow);
}
.hero {
  min-height: clamp(560px, 70vh, 720px);
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(360px, .94fr);
  gap: clamp(28px, 4vw, 72px);
  align-items: center;
  margin-top: 22px;
  padding: clamp(42px, 5.6vw, 82px);
}
.page-hero { min-height: 400px; display: grid; align-items: end; margin-top: 22px; padding: 88px clamp(34px, 5vw, 72px) 56px; }
.mesh-canvas {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  opacity: .24;
  background:
    radial-gradient(circle at 72% 28%, rgba(103, 232, 249, .16), transparent 28rem),
    radial-gradient(circle at 40% 70%, rgba(125, 211, 167, .12), transparent 26rem),
    linear-gradient(135deg, rgba(15, 23, 42, .20), rgba(2, 6, 23, .72));
}
.hero-content, .page-hero > div, .hero-terminal { position: relative; min-width: 0; }
.hero-content { max-width: 780px; }

.eyebrow { margin: 0 0 14px; color: var(--amber); font-size: 12px; font-weight: 850; letter-spacing: .12em; text-transform: uppercase; }
h1, h2, h3, p { letter-spacing: -.01em; }
h1 { max-width: 820px; margin: 0; font-size: clamp(48px, 5.2vw, 86px); line-height: .96; }
.page-hero h1 { max-width: 1040px; font-size: clamp(48px, 4.8vw, 82px); }
h2 { margin: 0; font-size: clamp(36px, 3.8vw, 64px); line-height: 1.04; }
h3 { margin: 0 0 10px; font-size: 20px; line-height: 1.18; }
.hero-lede, .page-hero p:not(.eyebrow), .section p { color: var(--muted); line-height: 1.64; }
.hero-lede { max-width: 760px; margin: 22px 0 0; font-size: clamp(19px, 1.55vw, 24px); }
.page-hero p:not(.eyebrow) { max-width: 900px; font-size: 21px; }
.section p { font-size: 17px; }

.hero-actions, .callout { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.hero-actions { margin-top: 30px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; border: 1px solid rgba(226, 232, 240, .22); border-radius: 999px; padding: 0 20px; color: var(--ink); background: rgba(15, 23, 42, .72); font-weight: 820; backdrop-filter: blur(10px); transition: transform .18s ease, border-color .18s ease, background .18s ease; }
.button:hover { transform: translateY(-1px); border-color: rgba(103, 232, 249, .42); background: rgba(30, 41, 59, .86); }
.button.primary { color: #031119; background: linear-gradient(135deg, var(--green), var(--cyan)); border-color: transparent; }
.button.ghost { background: rgba(2, 6, 23, .42); }
.text-link { display: inline-flex; margin-top: 10px; color: var(--cyan); font-weight: 850; }
.text-link::after { content: "→"; margin-left: 8px; }

.hero-terminal, pre { border: 1px solid rgba(103, 232, 249, .18); border-radius: var(--radius); background: rgba(2, 6, 23, .72); box-shadow: var(--shadow); }
.hero-terminal { align-self: center; overflow: hidden; }
.terminal-bar { display: flex; gap: 8px; padding: 16px 18px; border-bottom: 1px solid rgba(148, 163, 184, .16); background: rgba(15, 23, 42, .72); }
.terminal-bar span { width: 10px; aspect-ratio: 1; border-radius: 50%; background: var(--coral); }
.terminal-bar span:nth-child(2) { background: var(--amber); }
.terminal-bar span:nth-child(3) { background: var(--green); }
pre { min-width: 0; margin: 0; overflow-x: auto; }
.hero-terminal pre { border: 0; border-radius: 0; background: transparent; box-shadow: none; }
code { display: block; min-width: 0; padding: 20px; color: #a7f3d0; font: 14px/1.68 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre; }
.inline-code { display: inline; padding: 2px 6px; border: 1px solid rgba(103, 232, 249, .18); border-radius: 7px; background: rgba(15, 23, 42, .68); color: var(--cyan); font-size: .92em; white-space: normal; }

.metrics-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; padding: 18px 0 0; }
.metrics-strip div, article, .pipeline-card, .timeline-item, .detail-panel { border: 1px solid rgba(148, 163, 184, .18); border-radius: var(--radius); background: linear-gradient(180deg, rgba(30, 41, 59, .72), rgba(15, 23, 42, .72)); box-shadow: 0 18px 54px rgba(0, 0, 0, .18); }
.metrics-strip div { min-height: 136px; padding: 26px; }
.metrics-strip strong { display: block; color: var(--cyan); font-size: 34px; line-height: 1; }
.metrics-strip span { display: block; margin-top: 12px; color: var(--muted); line-height: 1.42; }

.section { padding: clamp(64px, 8vw, 118px) 0; border-bottom: 1px solid rgba(148, 163, 184, .14); }
.section-heading { max-width: 1080px; margin-bottom: 34px; }
.compact-heading p:not(.eyebrow) { max-width: 860px; margin-top: 18px; }
.split-feature, .code-band, .detail-split { display: grid; grid-template-columns: minmax(0, .82fr) minmax(360px, 1.18fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.loop-grid, .feature-grid, .principle-grid, .detail-grid { display: grid; gap: 16px; }
.loop-grid, .principle-grid, .detail-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.feature-grid-4, .feature-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.principle-grid-tight { grid-template-columns: repeat(2, minmax(0, 1fr)); }
article { min-height: 220px; padding: 24px; }
article:hover { border-color: rgba(103, 232, 249, .30); background: linear-gradient(180deg, rgba(30, 41, 59, .86), rgba(15, 23, 42, .78)); }
article span, .detail-panel span { display: inline-flex; margin-bottom: 22px; border: 1px solid rgba(251, 191, 36, .24); border-radius: 999px; padding: 5px 10px; color: var(--amber); background: rgba(251, 191, 36, .08); font-size: 12px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
article p { margin-bottom: 0; }
.detail-panel { padding: 26px; }
.detail-panel ul { margin: 14px 0 0; padding-left: 20px; color: var(--muted); line-height: 1.7; }
.detail-panel li + li { margin-top: 8px; }

.dark-band { width: min(100% - clamp(22px, 4vw, 64px), 1640px); margin-top: 12px; margin-bottom: 12px; padding: clamp(54px, 7vw, 96px) clamp(24px, 4vw, 56px); border: 1px solid rgba(103, 232, 249, .16); border-radius: 32px; background: radial-gradient(circle at 14% 0%, rgba(103, 232, 249, .10), transparent 32rem), radial-gradient(circle at 80% 100%, rgba(125, 211, 167, .10), transparent 30rem), rgba(10, 15, 25, .88); box-shadow: var(--shadow); }
.callout { justify-content: space-between; gap: 24px; margin-top: 18px; margin-bottom: 42px; padding: clamp(34px, 5vw, 64px); border: 1px solid rgba(103, 232, 249, .20); border-radius: 32px; background: linear-gradient(135deg, rgba(125, 211, 167, .12), rgba(103, 232, 249, .07), rgba(196, 181, 253, .08)), rgba(15, 23, 42, .78); box-shadow: var(--shadow); }
.callout h2 { max-width: 980px; }
.pipeline-card { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; padding: 18px; }
.pipeline-card div { position: relative; min-height: 112px; padding: 18px; border: 1px solid rgba(148, 163, 184, .16); border-radius: 18px; background: rgba(2, 6, 23, .42); }
.pipeline-card div::after { content: ""; position: absolute; inset: auto 18px 16px 18px; height: 2px; border-radius: 999px; background: linear-gradient(90deg, var(--green), var(--cyan)); opacity: .72; }
.pipeline-card strong { display: block; color: var(--amber); font-size: 13px; letter-spacing: .08em; }
.pipeline-card span { display: block; margin-top: 12px; color: var(--ink); font-weight: 800; }
.rail { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin-bottom: 38px; }
.rail span { min-height: 78px; display: grid; place-items: center; border: 1px solid rgba(103, 232, 249, .22); border-radius: 18px; color: var(--ink); background: rgba(15, 23, 42, .70); text-align: center; font-weight: 820; padding: 12px; }
.architecture-copy { max-width: 980px; }
.timeline { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.timeline-item { min-height: 250px; padding: 24px; }
.timeline-item span { color: var(--cyan); font-weight: 900; }

.compat-matrix { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(110px, .35fr) minmax(260px, 1.2fr); border: 1px solid var(--line); border-radius: 24px; overflow: hidden; background: rgba(15, 23, 42, .76); box-shadow: var(--shadow); }
.compat-matrix > div { padding: 20px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.matrix-head { color: var(--amber); font-weight: 900; background: rgba(251, 191, 36, .08); }
.status { display: inline-flex; border-radius: 999px; padding: 6px 10px; font-size: 12px; font-weight: 900; }
.status.pass { color: #04111a; background: var(--green); }
.status.bounded { color: #161004; background: var(--amber); }
.status.planned { color: #04111a; background: var(--cyan); }
.steps { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.steps article { min-height: auto; padding: 0; overflow: hidden; }
.steps article span, .steps article h3, .steps article p { margin-left: 22px; margin-right: 22px; }
.steps article span { margin-top: 22px; }
.steps article p { margin-bottom: 18px; }
.steps pre { border-left: 0; border-right: 0; border-bottom: 0; border-radius: 0; box-shadow: none; }
.site-footer { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; padding: 30px 0 42px; color: var(--muted); }
.site-footer span { margin-right: auto; color: var(--ink); font-weight: 900; }

@media (min-width: 1800px) { :root { --page: min(100% - 144px, 1600px); } }
@media (max-width: 1180px) {
  .hero, .split-feature, .code-band, .detail-split { grid-template-columns: 1fr; }
  .feature-grid-4, .feature-grid, .timeline, .metrics-strip, .rail { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-content { max-width: 100%; }
}
@media (max-width: 760px) {
  :root { --page: min(100% - 24px, 1560px); }
  .site-header { align-items: center; min-height: 66px; padding-inline: 12px; }
  .nav-toggle { display: inline-flex; }
  .site-nav { display: none; position: absolute; inset: 68px 12px auto 12px; flex-direction: column; align-items: stretch; padding: 10px; border: 1px solid var(--line); border-radius: 18px; background: rgba(7, 11, 18, .98); box-shadow: var(--shadow); }
  .site-nav.open { display: flex; }
  .hero, .page-hero, .dark-band, .callout { border-radius: 24px; }
  .hero { min-height: auto; gap: 24px; margin-top: 12px; padding: 36px 22px; }
  .page-hero { min-height: 340px; margin-top: 12px; padding: 70px 22px 36px; }
  h1 { font-size: clamp(42px, 12vw, 64px); }
  .page-hero h1 { font-size: clamp(40px, 11vw, 56px); }
  h2 { font-size: clamp(32px, 9vw, 42px); }
  .eyebrow { font-size: 11px; overflow-wrap: anywhere; }
  .hero-lede, .page-hero p:not(.eyebrow) { font-size: 19px; }
  .hero-actions { display: grid; grid-template-columns: 1fr; }
  .hero-actions .button, .hero-terminal { width: 100%; }
  code { font-size: 13px; white-space: pre-wrap; overflow-wrap: anywhere; }
  .feature-grid-4, .feature-grid, .loop-grid, .principle-grid, .detail-grid, .timeline, .metrics-strip, .rail, .steps, .compat-matrix, .pipeline-card { grid-template-columns: 1fr; }
  .compat-matrix > div { border-right: 0; }
  .site-footer span { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } .button { transition: none; } }
