:root {
  color-scheme: dark;
  --ink: #f6fbfd;
  --muted: #a8bdc8;
  --pale: #d6e5ea;
  --cyan: #48cbe8;
  --cyan-soft: #a5eef8;
  --night: #07131d;
  --night-2: #0a202d;
  --panel: #0d2b3a;
  --panel-2: #12384a;
  --line: rgba(165, 238, 248, 0.18);
  --coral: #ff756b;
  --focus: #ffd166;
  --paper: #e9f1f3;
  --paper-ink: #14252e;
  --paper-muted: #536a75;
  font-family: Poppins, Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 5.5rem; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 80% 4%, rgba(72, 203, 232, 0.11), transparent 30rem),
    linear-gradient(rgba(72, 203, 232, 0.028) 1px, transparent 1px),
    linear-gradient(90deg, rgba(72, 203, 232, 0.028) 1px, transparent 1px),
    var(--night);
  background-size: auto, 2.4rem 2.4rem, 2.4rem 2.4rem, auto;
  line-height: 1.65;
}

img { display: block; max-width: 100%; }
a { color: var(--cyan); text-underline-offset: 0.22em; }
a:hover { color: var(--focus); }
a:focus-visible,
.button:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 4px;
  border-radius: 0.2rem;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -6rem;
  z-index: 30;
  padding: 0.8rem 1rem;
  color: #111;
  background: var(--focus);
  font-weight: 900;
}
.skip-link:focus { top: 1rem; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(7, 19, 29, 0.93);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}
nav {
  max-width: 80rem;
  margin: 0 auto;
  padding: 0.82rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.72rem;
  color: var(--ink);
  text-decoration: none;
  font-weight: 900;
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 2.3rem;
  height: 2.3rem;
  border: 1px solid var(--cyan);
  color: var(--cyan);
  font: 900 0.7rem/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  box-shadow: inset 0 0 1.2rem rgba(72, 203, 232, 0.14);
}
.nav-links { display: flex; flex-wrap: wrap; gap: 0.65rem 1.2rem; }
.nav-links a { color: var(--pale); text-decoration: none; font-size: 0.92rem; font-weight: 760; }
.nav-links a:hover { color: var(--cyan); }

main { overflow: hidden; }
.hero,
.section {
  max-width: 80rem;
  margin: 0 auto;
  padding: 6.2rem 1.5rem;
}
.hero {
  min-height: calc(100vh - 4.2rem);
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(26rem, 1.05fr);
  align-items: center;
  gap: clamp(2.5rem, 6vw, 6rem);
  padding-top: 7.3rem;
  padding-bottom: 7.3rem;
}
.hero-copy { position: relative; z-index: 2; }
.eyebrow {
  margin: 0 0 1rem;
  color: var(--coral);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
h1, h2, h3 { line-height: 1.08; letter-spacing: -0.035em; }
h1 { margin: 0; max-width: 12ch; font-size: clamp(3rem, 6.6vw, 6.2rem); }
h2 { margin: 0; max-width: 17ch; font-size: clamp(2.25rem, 4.7vw, 4.5rem); }
h3 { margin: 0 0 0.72rem; font-size: 1.35rem; }
.lede {
  max-width: 44rem;
  margin: 2rem 0;
  color: var(--pale);
  font-size: clamp(1.12rem, 2vw, 1.42rem);
}
.actions { display: flex; flex-wrap: wrap; gap: 0.82rem; margin: 2.1rem 0 1.3rem; }
.button {
  display: inline-block;
  padding: 0.9rem 1.2rem;
  border: 2px solid var(--cyan);
  font-weight: 850;
  text-decoration: none;
}
.button.primary { color: #06131c; background: var(--cyan); }
.button.primary:hover { color: #111; background: var(--focus); border-color: var(--focus); }
.button.secondary { color: var(--cyan); background: rgba(7, 19, 29, 0.45); }
.button.secondary:hover { color: var(--focus); border-color: var(--focus); }
.quiet { color: var(--muted); font-size: 0.93rem; }

.hero-visual {
  position: relative;
  margin: 0;
  border: 1px solid rgba(72, 203, 232, 0.38);
  background: #02090e;
  box-shadow: 0 2rem 6rem rgba(0, 0, 0, 0.48), 0 0 0 0.7rem rgba(72, 203, 232, 0.025);
}
.hero-visual::before {
  content: "SCOPE · SOURCE · TIME · AUTHORITY";
  position: absolute;
  z-index: 1;
  top: -1.5rem;
  right: 0;
  color: var(--cyan-soft);
  font: 800 0.67rem/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  letter-spacing: 0.1em;
}
.hero-visual::after {
  content: "";
  position: absolute;
  left: -0.55rem;
  bottom: -0.55rem;
  width: 4.5rem;
  height: 4.5rem;
  border-left: 2px solid var(--coral);
  border-bottom: 2px solid var(--coral);
  pointer-events: none;
}
.hero-visual img { width: 100%; height: auto; }

.section { border-top: 1px solid var(--line); }
.section-heading { max-width: 55rem; margin-bottom: 3.1rem; }
.section-heading > p:last-child { color: var(--muted); font-size: 1.08rem; }

.modes-section { max-width: none; padding-left: max(1.5rem, calc((100vw - 77rem) / 2)); padding-right: max(1.5rem, calc((100vw - 77rem) / 2)); }
.mode-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}
.mode-grid article {
  min-height: 14rem;
  padding: 1.35rem;
  border: 1px solid var(--line);
  background: linear-gradient(145deg, rgba(18, 56, 74, 0.82), rgba(8, 28, 40, 0.78));
}
.mode-grid article > span {
  display: block;
  margin-bottom: 3rem;
  color: var(--cyan-soft);
  font: 850 0.7rem/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.mode-grid article:nth-child(5) { border-color: rgba(255, 117, 107, 0.48); }
.mode-grid article:nth-child(5) > span { color: var(--coral); }
.mode-grid p { color: var(--muted); }

.state-section { display: grid; grid-template-columns: minmax(16rem, 0.62fr) minmax(0, 1.38fr); gap: clamp(2rem, 6vw, 6rem); align-items: start; }
.state-section .section-heading { position: sticky; top: 7rem; margin-bottom: 0; }
.record-ledger { border-top: 1px solid var(--line); }
.record-ledger article {
  display: grid;
  grid-template-columns: minmax(9rem, 0.35fr) minmax(11rem, 0.45fr) minmax(0, 1fr);
  gap: 1rem;
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--line);
  align-items: start;
}
.kind {
  color: var(--cyan-soft);
  font: 800 0.72rem/1.4 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}
.record-ledger strong { color: var(--pale); }
.record-ledger p { margin: 0; color: var(--muted); }

.spine-section {
  max-width: none;
  padding-left: max(1.5rem, calc((100vw - 77rem) / 2));
  padding-right: max(1.5rem, calc((100vw - 77rem) / 2));
  display: grid;
  grid-template-columns: minmax(18rem, 0.72fr) minmax(0, 1.28fr);
  gap: clamp(2rem, 6vw, 6rem);
  background: var(--paper);
  color: var(--paper-ink);
}
.spine-copy .eyebrow { color: #9d3831; }
.spine-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1px; background: rgba(20, 37, 46, 0.2); border: 1px solid rgba(20, 37, 46, 0.2); }
.spine-fields p { margin: 0; padding: 1.2rem; background: #f8fbfc; }
.spine-fields strong { display: block; margin-bottom: 0.45rem; color: #0d6075; }
.spine-fields span { display: block; color: var(--paper-muted); }

.compile-section { position: relative; }
.compiler { display: grid; grid-template-columns: 1fr auto 1fr; gap: 1.5rem; align-items: stretch; }
.compiler-pass { padding: 1.55rem; border: 1px solid var(--line); background: rgba(13, 43, 58, 0.82); }
.compiler-pass p { color: var(--muted); }
.pass-label { display: block; margin-bottom: 3.2rem; color: var(--cyan-soft); font: 850 0.7rem/1 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: 0.1em; }
.compiler-arrow { align-self: center; color: var(--coral); font-size: 2rem; font-weight: 900; }
.packet-inputs { display: flex; flex-wrap: wrap; gap: 0.65rem; margin-top: 1.35rem; }
.packet-inputs span { padding: 0.55rem 0.72rem; border: 1px solid var(--line); color: var(--pale); background: rgba(7, 24, 34, 0.72); font-size: 0.88rem; }

.forget-section { max-width: none; padding-left: max(1.5rem, calc((100vw - 77rem) / 2)); padding-right: max(1.5rem, calc((100vw - 77rem) / 2)); background: #091e2a; }
.forget-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
.forget-grid article { min-height: 14rem; padding: 1.35rem; border-top: 3px solid var(--cyan); background: rgba(18, 56, 74, 0.66); }
.forget-grid article:nth-child(3) { border-color: var(--coral); }
.forget-grid p { color: var(--muted); }
.custody-note { margin-top: 1rem; padding: 1.35rem; border: 1px solid rgba(255, 117, 107, 0.46); background: rgba(255, 117, 107, 0.07); }
.custody-note strong { color: var(--coral); }
.custody-note p { margin-bottom: 0; color: var(--pale); }

.prompt-section { max-width: 68rem; }
.prompt-section blockquote {
  margin: 2rem 0;
  padding: 1.6rem 1.8rem;
  border-left: 0.42rem solid var(--coral);
  background: rgba(18, 56, 74, 0.76);
  color: var(--pale);
  font-size: clamp(1.05rem, 2vw, 1.28rem);
  box-shadow: 0 1.5rem 4rem rgba(0, 0, 0, 0.22);
}
.prompt-section code { color: var(--cyan-soft); font-weight: 850; }
.prompt-section > p { color: var(--muted); }

footer { padding: 2.5rem 1.5rem; text-align: center; color: var(--muted); background: #02080d; border-top: 1px solid var(--line); }
footer p { margin: 0.35rem 0; }
footer strong { color: var(--pale); }

@media (max-width: 68rem) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-copy { max-width: 56rem; }
  .hero-visual { max-width: 58rem; }
  .mode-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .state-section, .spine-section { grid-template-columns: 1fr; }
  .state-section .section-heading { position: static; }
  .forget-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 48rem) {
  .site-header { position: static; backdrop-filter: none; }
  nav { flex-direction: column; align-items: flex-start; }
  .hero, .section { padding-top: 4.5rem; padding-bottom: 4.5rem; }
  .hero { grid-template-columns: minmax(0, 1fr); }
  .mode-grid, .forget-grid, .spine-fields { grid-template-columns: 1fr; }
  .record-ledger article { grid-template-columns: 1fr; gap: 0.35rem; }
  .compiler { grid-template-columns: 1fr; }
  .compiler-arrow { transform: rotate(90deg); justify-self: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
