:root {
  --ink: #0f1110;
  --paper: #f2ead7;
  --bone: #fff8e5;
  --acid: #b7ff2a;
  --amber: #ffb000;
  --red: #ff4d38;
  --teal: #00d8aa;
  --line: rgba(15, 17, 16, 0.18);
  --shadow: 0 24px 70px rgba(15, 17, 16, 0.2);
  --radius: 8px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(90deg, rgba(15, 17, 16, 0.06) 1px, transparent 1px) 0 0 / 42px 42px,
    linear-gradient(0deg, rgba(15, 17, 16, 0.05) 1px, transparent 1px) 0 0 / 42px 42px,
    var(--paper);
  color: var(--ink);
  font-family: "Space Grotesk", sans-serif;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 20;
  opacity: 0.12;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(15, 17, 16, 0.8) 0 1px, transparent 1px),
    radial-gradient(circle at 80% 70%, rgba(15, 17, 16, 0.7) 0 1px, transparent 1px);
  background-size: 9px 11px, 13px 17px;
  mix-blend-mode: multiply;
}

#flow-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  opacity: 0.35;
  pointer-events: none;
}

.topbar,
main,
.footer {
  position: relative;
  z-index: 1;
}

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px clamp(18px, 4vw, 54px);
  border-bottom: 1px solid rgba(15, 17, 16, 0.16);
  background: rgba(242, 234, 215, 0.82);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  letter-spacing: 0;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 32px;
  background: var(--ink);
  color: var(--acid);
  border-radius: 4px;
  font-family: "Archivo Black", sans-serif;
  font-size: 14px;
}

.nav-links {
  display: flex;
  gap: 24px;
  align-items: center;
}

.nav-links a {
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
}

.nav-toggle {
  display: none;
}

.hero {
  min-height: 92vh;
  display: grid;
  align-items: center;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.75fr);
  gap: clamp(28px, 6vw, 86px);
  padding: 112px clamp(20px, 7vw, 92px) 52px;
  border-bottom: 2px solid var(--ink);
}

.hero-copy {
  max-width: 920px;
}

.eyebrow {
  margin: 0 0 14px;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2 {
  margin: 0;
  font-family: "Archivo Black", sans-serif;
  letter-spacing: 0;
  line-height: 0.92;
}

h1 {
  max-width: 11ch;
  font-size: clamp(58px, 13vw, 176px);
}

h2 {
  font-size: clamp(38px, 6vw, 88px);
}

h3 {
  margin: 0 0 12px;
  font-size: clamp(24px, 3vw, 38px);
}

.lede {
  max-width: 760px;
  margin: 24px 0 0;
  font-size: clamp(20px, 2.7vw, 31px);
  line-height: 1.18;
  font-weight: 600;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 13px 18px;
  border-radius: 6px;
  border: 2px solid var(--ink);
  color: var(--ink);
  text-decoration: none;
  font-weight: 900;
  box-shadow: 5px 5px 0 var(--ink);
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.button:hover {
  transform: translate(3px, 3px);
  box-shadow: 2px 2px 0 var(--ink);
}

.button.primary {
  background: var(--acid);
}

.button.secondary {
  background: var(--bone);
}

.hero-terminal {
  align-self: end;
  margin-bottom: 5vh;
  border: 2px solid var(--ink);
  background: rgba(15, 17, 16, 0.94);
  color: var(--bone);
  box-shadow: var(--shadow);
  transform: rotate(1.4deg);
}

.terminal-row {
  padding: 16px;
  border-bottom: 1px solid rgba(255, 248, 229, 0.16);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 14px;
}

.terminal-row:last-child {
  border-bottom: 0;
}

.terminal-row.muted {
  color: rgba(255, 248, 229, 0.64);
}

.terminal-row.status {
  color: var(--amber);
}

.terminal-row.success {
  color: var(--teal);
}

.terminal-row.ok {
  color: var(--acid);
}

.band {
  padding: clamp(64px, 10vw, 128px) clamp(20px, 7vw, 92px);
  border-bottom: 2px solid var(--ink);
}

.section-head {
  max-width: 980px;
}

.section-head p:not(.eyebrow) {
  max-width: 720px;
  font-size: 20px;
  line-height: 1.45;
}

.flow-band {
  background: rgba(255, 248, 229, 0.72);
}

.flow-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 16px;
  margin-top: 42px;
}

.step-card {
  grid-column: span 4;
  min-height: 240px;
  padding: 22px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  background: var(--bone);
  box-shadow: 8px 8px 0 var(--ink);
}

.step-card.tall {
  grid-column: span 3;
  min-height: 320px;
  background: var(--acid);
}

.step-card.wide {
  grid-column: span 5;
  background: var(--amber);
}

.step-card p {
  margin: 0;
  font-size: 18px;
  line-height: 1.38;
}

.step-index {
  display: block;
  margin-bottom: 24px;
  font-family: "Archivo Black", sans-serif;
  font-size: 44px;
}

.verifier-band {
  background: var(--ink);
  color: var(--bone);
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(320px, 1fr);
  gap: clamp(24px, 6vw, 72px);
  align-items: center;
}

.code-panel {
  border: 2px solid var(--bone);
  background: #080908;
  border-radius: var(--radius);
  box-shadow: 10px 10px 0 var(--acid);
  overflow: auto;
}

.code-panel pre {
  margin: 0;
  padding: clamp(20px, 4vw, 40px);
}

.code-panel code {
  color: var(--acid);
  font-size: clamp(15px, 1.8vw, 22px);
  line-height: 1.55;
}

.marquee {
  position: relative;
  overflow: hidden;
  border-bottom: 2px solid var(--ink);
  background: var(--red);
  color: var(--bone);
  font-family: "Archivo Black", sans-serif;
  white-space: nowrap;
}

.marquee div {
  width: max-content;
  padding: 18px 0;
  animation: roll 22s linear infinite;
}

@keyframes roll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.ship-band {
  background: rgba(242, 234, 215, 0.8);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 380px);
  gap: clamp(28px, 6vw, 80px);
}

.ship-list {
  margin-top: 34px;
  border-top: 2px solid var(--ink);
}

.ship-list div {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 18px;
  padding: 22px 0;
  border-bottom: 2px solid var(--ink);
}

.ship-list strong {
  font-family: "Archivo Black", sans-serif;
  font-size: 24px;
}

.ship-list span {
  font-size: 19px;
  line-height: 1.35;
}

.deploy-note {
  align-self: start;
  position: sticky;
  top: 100px;
  padding: 22px;
  border: 2px solid var(--ink);
  border-radius: var(--radius);
  background: var(--acid);
  box-shadow: 8px 8px 0 var(--ink);
}

.deploy-note span {
  display: block;
  font-weight: 900;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.14em;
}

.deploy-note strong {
  display: block;
  margin-top: 16px;
  font-size: 26px;
  overflow-wrap: anywhere;
}

.deploy-note p {
  margin-bottom: 0;
  line-height: 1.4;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 24px clamp(20px, 7vw, 92px);
  background: var(--ink);
  color: var(--bone);
  font-weight: 700;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 520ms ease, transform 520ms ease;
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 840px) {
  .topbar {
    padding: 14px 18px;
  }

  .nav-toggle {
    display: inline-grid;
    place-items: center;
    width: 44px;
    height: 40px;
    border: 2px solid var(--ink);
    border-radius: 4px;
    background: var(--bone);
  }

  .nav-toggle span {
    display: block;
    width: 20px;
    height: 2px;
    margin: 3px 0;
    background: var(--ink);
    transition: transform 180ms ease;
  }

  body.nav-open {
    overflow: hidden;
  }

  body.nav-open .nav-toggle span:first-child {
    transform: translateY(4px) rotate(45deg);
  }

  body.nav-open .nav-toggle span:last-child {
    transform: translateY(-4px) rotate(-45deg);
  }

  .nav-links {
    position: fixed;
    inset: 69px 12px auto;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 16px;
    border: 2px solid var(--ink);
    background: var(--bone);
    box-shadow: 8px 8px 0 var(--ink);
  }

  body.nav-open .nav-links {
    display: flex;
  }

  .nav-links a {
    padding: 14px;
    border-bottom: 1px solid var(--line);
  }

  .hero,
  .split,
  .ship-band {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: auto;
    padding-top: 104px;
  }

  .hero-terminal {
    margin-bottom: 0;
    transform: none;
  }

  .flow-grid {
    grid-template-columns: 1fr;
  }

  .step-card,
  .step-card.tall,
  .step-card.wide {
    grid-column: auto;
    min-height: 0;
  }

  .ship-list div {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .deploy-note {
    position: static;
  }

  .footer {
    flex-direction: column;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    transition-duration: 1ms !important;
  }
}
