:root {
  --ink: #111614;
  --ink-soft: #3c4641;
  --muted: #6f7773;
  --line: rgba(17, 22, 20, 0.12);
  --paper: #f7f8f6;
  --paper-alt: #eef2ef;
  --surface: rgba(255, 255, 255, 0.78);
  --accent: #2f7d67;
  --accent-dark: #1f5f4e;
  --amber: #b2773a;
  --red: #9d4b43;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --sans: "Geist", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  letter-spacing: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 24px;
  padding: 18px 32px;
  color: #eff4ef;
  background: linear-gradient(180deg, rgba(17, 22, 20, 0.78), rgba(17, 22, 20, 0));
}

.brand,
.nav-links,
.nav-action {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 700;
  font-size: 1rem;
}

.brand-mark {
  width: 28px;
  height: 28px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 3px;
}

.brand-mark span {
  display: block;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: rgba(255, 255, 255, 0.14);
}

.brand-mark span:nth-child(2) {
  background: var(--accent);
  border-color: rgba(255, 255, 255, 0.22);
}

.nav-links {
  justify-content: center;
  gap: 6px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, 0.13);
  background: rgba(17, 22, 20, 0.36);
  backdrop-filter: blur(16px);
}

.nav-links a {
  padding: 10px 13px;
  color: rgba(239, 244, 239, 0.82);
  font-size: 0.9rem;
  transition: color 180ms ease, background 180ms ease;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.1);
}

.nav-action {
  justify-self: end;
  padding: 0 16px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  color: #ffffff;
  background: rgba(255, 255, 255, 0.11);
  backdrop-filter: blur(16px);
  font-weight: 600;
  transition: transform 180ms ease, background 180ms ease;
}

.nav-action:active,
.button:active,
.stage-button:active {
  transform: translateY(1px) scale(0.99);
}

.hero {
  position: relative;
  min-height: 92dvh;
  overflow: hidden;
  display: grid;
  align-items: end;
  padding: 132px 32px 58px;
  color: #f4f7f4;
  background: #111614;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(17, 22, 20, 0.94) 0%, rgba(17, 22, 20, 0.72) 38%, rgba(17, 22, 20, 0.2) 100%),
    linear-gradient(180deg, rgba(17, 22, 20, 0.12) 0%, rgba(17, 22, 20, 0.72) 100%);
}

.hero-scene {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

#signal-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.scene-grid {
  position: absolute;
  inset: 118px 28px 36px 48%;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  grid-template-rows: auto 1fr;
  gap: 18px;
  transform: rotate(-2deg);
  opacity: 0.92;
}

.scene-panel {
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(244, 247, 244, 0.1);
  backdrop-filter: blur(18px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.14);
}

.command-panel {
  grid-column: span 2;
  padding: 18px;
}

.ledger-panel {
  padding: 18px;
  min-height: 270px;
}

.status-panel {
  align-self: end;
  padding: 22px;
  min-height: 214px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: rgba(47, 125, 103, 0.26);
}

.panel-topline,
.command-row,
.status-kicker {
  font-family: var(--mono);
  font-size: 0.75rem;
  text-transform: uppercase;
}

.panel-topline {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  color: rgba(244, 247, 244, 0.64);
  margin-bottom: 18px;
}

.command-row {
  display: grid;
  grid-template-columns: 10px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 14px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.13);
  color: rgba(244, 247, 244, 0.78);
}

.command-row strong {
  color: #ffffff;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--amber);
}

.command-row.active .dot {
  background: #64c2a6;
  animation: breathe 2.6s ease-in-out infinite;
}

.ledger-lines {
  display: grid;
  gap: 16px;
  margin-top: 34px;
}

.ledger-lines span {
  display: block;
  width: var(--w);
  height: 13px;
  background: rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

.ledger-lines span::after {
  content: "";
  position: absolute;
  inset: 0;
  transform: translateX(-100%);
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.34), transparent);
  animation: shimmer 4.8s ease-in-out infinite;
}

.status-panel strong {
  font-family: var(--mono);
  font-size: 4.25rem;
  line-height: 1;
  margin: 14px 0 8px;
}

.status-panel span:last-child {
  color: rgba(244, 247, 244, 0.76);
  max-width: 18ch;
}

.hero-copy {
  position: relative;
  z-index: 1;
  max-width: 760px;
}

.eyebrow {
  margin: 0 0 14px;
  font-family: var(--mono);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
}

.hero .eyebrow {
  color: #83d2ba;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 24px;
  font-size: 4.4rem;
  line-height: 0.96;
  font-weight: 700;
}

.hero-lede {
  max-width: 620px;
  color: rgba(244, 247, 244, 0.78);
  font-size: 1.12rem;
  line-height: 1.7;
}

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

.button {
  min-height: 48px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  font-weight: 700;
  border: 1px solid transparent;
  transition: transform 180ms ease, background 180ms ease, border-color 180ms ease;
}

.button.primary {
  color: #ffffff;
  background: var(--accent);
  border-color: rgba(255, 255, 255, 0.16);
}

.button.primary:hover,
.button.primary:focus-visible {
  background: var(--accent-dark);
}

.button.secondary {
  color: #f4f7f4;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.18);
}

.proof-strip {
  max-width: 1180px;
  margin: -24px auto 0;
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: #ffffff;
  border: 1px solid var(--line);
}

.proof-strip div {
  padding: 24px 28px;
  border-right: 1px solid var(--line);
}

.proof-strip div:last-child {
  border-right: 0;
}

.proof-strip strong {
  display: block;
  font-family: var(--mono);
  font-size: 1.7rem;
  margin-bottom: 6px;
}

.proof-strip span {
  color: var(--muted);
}

.systems-section,
.workflow-section,
.delivery-section {
  max-width: 1180px;
  margin: 0 auto;
  padding: 116px 32px 0;
}

.section-heading {
  max-width: 760px;
  margin-bottom: 36px;
}

.section-heading.compact {
  max-width: 680px;
}

h2 {
  font-size: 3.1rem;
  line-height: 1.04;
  margin-bottom: 0;
}

.systems-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.85fr 0.9fr;
  grid-auto-rows: minmax(230px, auto);
  gap: 14px;
}

.system-card {
  border: 1px solid var(--line);
  background: #ffffff;
  padding: 28px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  transition: transform 220ms ease, border-color 220ms ease;
}

.system-card:hover {
  transform: translateY(-3px);
  border-color: rgba(47, 125, 103, 0.38);
}

.system-card.wide {
  grid-column: span 2;
  background: linear-gradient(135deg, #ffffff, #eef2ef);
}

.system-card.tall {
  grid-row: span 2;
  background: #17201c;
  color: #f4f7f4;
}

.system-index {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 0.8rem;
  margin-bottom: 34px;
}

.system-card.tall .system-index {
  color: #83d2ba;
}

.system-card h3 {
  font-size: 1.34rem;
  margin-bottom: 10px;
}

.system-card p,
.workflow-copy p,
.delivery-list p {
  color: var(--muted);
  line-height: 1.65;
  margin-bottom: 0;
}

.system-card.tall p {
  color: rgba(244, 247, 244, 0.72);
}

.workflow-section {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 56px;
  align-items: start;
}

.workflow-copy {
  position: sticky;
  top: 110px;
}

.workflow-board {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding: 12px;
  background: #ffffff;
  border: 1px solid var(--line);
}

.stage-button {
  min-height: 48px;
  border: 1px solid var(--line);
  background: #f8faf8;
  color: var(--ink-soft);
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: background 180ms ease, color 180ms ease, transform 180ms ease;
}

.stage-button.active {
  color: #ffffff;
  background: var(--ink);
}

.stage-output {
  grid-column: 1 / -1;
  min-height: 310px;
  padding: 34px;
  border: 1px solid var(--line);
  background:
    linear-gradient(135deg, rgba(47, 125, 103, 0.1), transparent 48%),
    #f7f8f6;
}

.stage-output span {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 0.9rem;
}

.stage-output strong {
  display: block;
  max-width: 520px;
  margin: 42px 0 18px;
  font-size: 2rem;
  line-height: 1.12;
}

.stage-output p {
  max-width: 540px;
  color: var(--muted);
  line-height: 1.7;
}

.delivery-section {
  padding-bottom: 96px;
}

.delivery-list {
  list-style: none;
  padding: 0;
  margin: 38px 0 0;
  border-top: 1px solid var(--line);
}

.delivery-list li {
  display: grid;
  grid-template-columns: 160px 240px 1fr;
  gap: 32px;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}

.delivery-list span {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 0.86rem;
}

.delivery-list strong {
  font-size: 1.16rem;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 28px 32px;
  color: rgba(244, 247, 244, 0.74);
  background: var(--ink);
}

.site-footer span {
  color: #ffffff;
  font-weight: 700;
}

@keyframes breathe {
  0%,
  100% {
    transform: scale(0.92);
    opacity: 0.64;
  }
  50% {
    transform: scale(1.35);
    opacity: 1;
  }
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  48%,
  100% {
    transform: translateX(100%);
  }
}

@media (max-width: 960px) {
  .site-header {
    grid-template-columns: 1fr auto;
    padding: 14px 18px;
  }

  .nav-links {
    display: none;
  }

  .hero {
    min-height: 94dvh;
    padding: 112px 22px 44px;
  }

  .hero::after {
    background:
      linear-gradient(180deg, rgba(17, 22, 20, 0.74), rgba(17, 22, 20, 0.94)),
      linear-gradient(90deg, rgba(17, 22, 20, 0.44), rgba(17, 22, 20, 0.2));
  }

  .scene-grid {
    inset: 110px 18px 180px 18px;
    transform: rotate(-1deg);
    opacity: 0.48;
  }

  h1 {
    font-size: 3rem;
  }

  h2 {
    font-size: 2.35rem;
  }

  .proof-strip {
    margin: 0;
    grid-template-columns: 1fr;
    border-left: 0;
    border-right: 0;
  }

  .proof-strip div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .systems-section,
  .workflow-section,
  .delivery-section {
    padding-left: 20px;
    padding-right: 20px;
  }

  .systems-grid,
  .workflow-section {
    grid-template-columns: 1fr;
  }

  .system-card.wide,
  .system-card.tall {
    grid-column: auto;
    grid-row: auto;
  }

  .workflow-copy {
    position: static;
  }

  .delivery-list li {
    grid-template-columns: 1fr;
    gap: 8px;
  }
}

@media (max-width: 620px) {
  .nav-action {
    min-height: 38px;
    padding: 0 12px;
    font-size: 0.86rem;
  }

  .brand span:last-child {
    display: none;
  }

  .scene-grid {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }

  .command-panel {
    grid-column: auto;
  }

  .ledger-panel,
  .status-panel {
    display: none;
  }

  h1 {
    font-size: 2.45rem;
  }

  .hero-lede {
    font-size: 1rem;
  }

  .hero-actions,
  .button {
    width: 100%;
  }

  .workflow-board {
    grid-template-columns: 1fr;
  }

  .stage-output {
    min-height: 280px;
    padding: 24px;
  }

  .stage-output strong {
    font-size: 1.55rem;
  }

  .site-footer {
    flex-direction: column;
  }
}
