@import url('https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;600&family=IBM+Plex+Sans:wght@400;500;600;700&display=swap');

:root {
  color-scheme: dark;
  --bg: #0d0d0d;
  --paper: #141414;
  --ink: #ececec;
  --muted: #a6a6a6;
  --accent: #d8d8d8;
  --accent-dark: #bcbcbc;
  --accent-cyan: #83cecb;
  --accent-amber: #d6bd86;
  --accent-lilac: #b1a8d3;
  --line: #545454;
  --line-soft: #2a2a2a;
  --grid: rgba(255, 255, 255, 0.05);
  --shadow: 0 14px 30px rgba(0, 0, 0, 0.4);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 12% 0%, rgba(131, 206, 203, 0.1) 0%, rgba(13, 13, 13, 0) 42%),
    radial-gradient(circle at 86% 8%, rgba(214, 189, 134, 0.08) 0%, rgba(13, 13, 13, 0) 38%),
    radial-gradient(circle at 52% 26%, rgba(177, 168, 211, 0.045) 0%, rgba(13, 13, 13, 0) 48%),
    linear-gradient(180deg, #111111 0%, #0b0b0b 100%),
    repeating-linear-gradient(0deg, var(--grid) 0 1px, transparent 1px 30px),
    repeating-linear-gradient(90deg, var(--grid) 0 1px, transparent 1px 30px);
  min-height: 100vh;
}

body.home {
  position: relative;
}

body.home::before,
body.home::after {
  content: "";
  position: fixed;
  pointer-events: none;
  z-index: 0;
}

body.home::before {
  inset: 6vh 8vw 8vh;
  opacity: 0.26;
  background:
    radial-gradient(circle at 9% 14%, rgba(255, 255, 255, 0.24) 0 1px, transparent 2px),
    radial-gradient(circle at 24% 31%, rgba(255, 255, 255, 0.22) 0 1px, transparent 2px),
    radial-gradient(circle at 41% 20%, rgba(255, 255, 255, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 57% 37%, rgba(255, 255, 255, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 73% 23%, rgba(255, 255, 255, 0.22) 0 1px, transparent 2px),
    radial-gradient(circle at 88% 41%, rgba(255, 255, 255, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 15% 62%, rgba(255, 255, 255, 0.22) 0 1px, transparent 2px),
    radial-gradient(circle at 34% 74%, rgba(255, 255, 255, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 52% 66%, rgba(255, 255, 255, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 70% 79%, rgba(255, 255, 255, 0.2) 0 1px, transparent 2px),
    radial-gradient(circle at 86% 68%, rgba(255, 255, 255, 0.22) 0 1px, transparent 2px),
    repeating-linear-gradient(31deg, rgba(255, 255, 255, 0.075) 0 1px, transparent 1px 74px),
    repeating-linear-gradient(-31deg, rgba(255, 255, 255, 0.07) 0 1px, transparent 1px 74px),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 112px);
  transform: rotate(-3.5deg) scale(1.06);
  mask-image: radial-gradient(circle at 52% 45%, rgba(0, 0, 0, 0.95) 0%, rgba(0, 0, 0, 0.58) 58%, transparent 84%);
}

body.home::after {
  inset: 0;
  background:
    radial-gradient(ellipse at 50% 38%, rgba(255, 255, 255, 0.05) 0%, rgba(255, 255, 255, 0) 62%),
    linear-gradient(180deg, rgba(0, 0, 0, 0.02) 0%, rgba(0, 0, 0, 0.42) 100%);
}

.container {
  max-width: 1160px;
  margin: 0 auto;
  padding: 34px 22px 72px;
  position: relative;
  z-index: 1;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 20px;
}

.topbar-motto {
  margin: 0;
  border: 1.5px solid #686868;
  background:
    linear-gradient(120deg, rgba(131, 206, 203, 0.12) 0%, rgba(255, 255, 255, 0.04) 52%, rgba(214, 189, 134, 0.12) 100%),
    #1a1a1a;
  color: #d8d8d8;
  padding: 10px 12px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  line-height: 1.28;
  max-width: 440px;
}

.brand {
  display: inline-flex;
  align-items: flex-start;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
}

.brand-mark {
  width: 20px;
  height: 14px;
  border-radius: 0;
  background: linear-gradient(135deg, var(--accent-cyan) 0%, #dddddd 48%, var(--accent-amber) 100%);
  border: 1.5px solid #7d7d7d;
  margin-top: 2px;
}

.brand-copy {
  display: inline-flex;
  flex-direction: column;
  gap: 1px;
}

.brand-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: #c4c4c4;
}

.brand-sub {
  font-family: "IBM Plex Mono", monospace;
  font-size: 9px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #9f9f9f;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.nav a {
  text-decoration: none;
  color: var(--ink);
  border: 1.5px solid var(--line);
  background: rgba(26, 26, 26, 0.95);
  border-radius: 0;
  padding: 10px 16px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  transition: background-color 140ms ease, color 140ms ease, transform 140ms ease;
}

.nav a.active {
  background: var(--accent);
  color: #101010;
  border-color: var(--accent);
}

.nav a:hover {
  background: #2a2a2a;
  transform: translateY(-1px);
}

.nav a.active:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

.hero {
  border: 1.5px solid var(--line);
  border-radius: 0;
  background: var(--paper);
  box-shadow: var(--shadow);
  padding: 28px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 10px;
  height: 100%;
  background: linear-gradient(180deg, #f0f0f0 0%, #adadad 100%);
}

.hero::after {
  content: "";
  position: absolute;
  top: 16px;
  right: 16px;
  width: clamp(134px, 23vw, 252px);
  height: 64px;
  border-top: 1px solid rgba(255, 255, 255, 0.38);
  border-right: 1px solid rgba(255, 255, 255, 0.38);
  background:
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.12) 0 1px, transparent 1px 28px),
    repeating-linear-gradient(180deg, rgba(255, 255, 255, 0.1) 0 1px, transparent 1px 18px);
  opacity: 0.3;
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero-art {
  position: absolute;
  inset: 22px 14px auto auto;
  width: 288px;
  height: 170px;
  pointer-events: none;
  z-index: 0;
  opacity: 0.66;
}

.hero-lattice {
  width: 100%;
  height: 100%;
  display: block;
}

.hero-lattice .hl-frame {
  fill: rgba(255, 255, 255, 0.015);
  stroke: rgba(235, 235, 235, 0.38);
  stroke-width: 1.2;
}

.hero-lattice .hl-grid {
  stroke: rgba(224, 224, 224, 0.11);
  stroke-width: 1;
}

.hero-lattice .hl-converge {
  fill: none;
  stroke: rgba(222, 222, 222, 0.54);
  stroke-width: 1.95;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hero-lattice .hl-converge.strong {
  stroke: rgba(131, 206, 203, 0.84);
  stroke-width: 2.2;
}

.hero-lattice .hl-converge.warm {
  stroke: rgba(214, 189, 134, 0.62);
  stroke-width: 2;
}

.hero-lattice .hl-mesh {
  fill: none;
  stroke: rgba(210, 210, 210, 0.26);
  stroke-width: 1.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.hero-lattice .hl-glow {
  fill: url(#hl-light);
  opacity: 0.95;
  filter: url(#hl-blur);
}

.hero-lattice .hl-core {
  fill: #f4f8ff;
  stroke: rgba(255, 255, 255, 0.88);
  stroke-width: 1.1;
}

.hero-lattice .hl-node {
  fill: #dbdbdb;
  stroke: #101010;
  stroke-width: 1;
  opacity: 0.95;
}

.hero-lattice .hl-node.major {
  fill: #f1f1f1;
  stroke: #0f0f0f;
}

.badge {
  display: inline-block;
  position: relative;
  border: 1.5px solid var(--line);
  border-radius: 0;
  padding: 7px 12px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.11em;
  color: var(--ink);
  background: #1f1f1f;
}

.badge::before {
  content: "";
  position: absolute;
  left: -11px;
  top: 3px;
  bottom: 3px;
  width: 2px;
  background: rgba(255, 255, 255, 0.42);
}

.badge::after {
  content: "";
  position: absolute;
  left: calc(100% + 14px);
  top: 50%;
  width: min(36vw, 340px);
  height: 1px;
  transform: translateY(-50%);
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.62), rgba(255, 255, 255, 0.06));
}

h1 {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: clamp(40px, 5.4vw, 66px);
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.025em;
  margin: 16px 0 12px;
  max-width: 18ch;
}

h2 {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: clamp(30px, 3.8vw, 42px);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}

h3 {
  margin: 0 0 8px;
  font-size: 20px;
  line-height: 1.22;
  letter-spacing: -0.01em;
}

p {
  color: #d5d5d5;
  line-height: 1.62;
  margin: 0 0 14px;
}

a {
  color: #d8d8d8;
}

a:hover {
  color: #f2f2f2;
}

.sub {
  font-size: 19px;
  max-width: 820px;
}

.hero-local {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 18px 0 0;
  padding: 6px 10px;
  border: 1.5px solid #696969;
  background:
    linear-gradient(90deg, rgba(131, 206, 203, 0.2), rgba(214, 189, 134, 0.14)),
    #1d1d1d;
  color: #efefef;
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  list-style: none;
  padding: 0;
  margin: 16px 0 0;
}

.chips li {
  border: 1.5px solid var(--line);
  border-radius: 0;
  padding: 7px 11px;
  font-size: 11px;
  font-family: "IBM Plex Mono", monospace;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  background: #1e1e1e;
  color: var(--ink);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 22px 0 0;
}

.cta {
  text-decoration: none;
  border: 1.5px solid var(--line);
  border-radius: 0;
  padding: 12px 18px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px;
  transition: transform 140ms ease, background-color 140ms ease, color 140ms ease;
}

.cta.primary {
  color: #101010;
  background: var(--accent);
  border-color: var(--accent);
}

.cta.secondary {
  color: var(--ink);
  background: #1c1c1c;
}

.cta:hover {
  transform: translateY(-1px);
}

.cta.primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
}

.lattice-ribbon {
  position: relative;
  min-height: 164px;
  margin: 20px 0 8px;
  overflow: hidden;
  border-radius: 0;
  border: 1.5px solid var(--line);
  background:
    linear-gradient(135deg, #171717 0%, #121212 62%, #0f0f0f 100%),
    repeating-linear-gradient(90deg, rgba(221, 221, 221, 0.14) 0 1px, transparent 1px 34px);
  box-shadow: var(--shadow);
}

.ribbon-wave,
.ribbon-dots {
  display: none;
}

.ribbon-nav {
  position: relative;
  z-index: 2;
  min-height: 164px;
  align-items: center;
  justify-content: center;
  align-content: center;
  gap: 14px;
  padding: 22px 18px;
}

.ribbon-nav a {
  min-width: 132px;
  min-height: 46px;
  justify-content: center;
  padding: 12px 20px;
  font-size: 13px;
  line-height: 1;
  background: #202020;
}

.section {
  margin-top: 28px;
}

.grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.component-grid {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.mode-grid {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.flow-grid {
  grid-template-columns: repeat(auto-fit, minmax(420px, 1fr));
}

.flow-components {
  margin-top: 28px;
}

.card {
  border: 1.5px solid var(--line);
  border-radius: 0;
  padding: 18px;
  background: #171717;
  box-shadow: var(--shadow);
}

.feature-card {
  display: flex;
  flex-direction: column;
}

.feature-matrix {
  margin-top: 6px;
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 8px;
}

.feature-tile {
  border: 1.5px solid #6e6e6e;
  background: #1d1d1d;
  padding: 9px 8px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.26;
  color: #e0e0e0;
}

.feature-tile.tile-major {
  grid-column: span 3;
  background:
    linear-gradient(130deg, rgba(131, 206, 203, 0.18) 0%, rgba(131, 206, 203, 0.04) 100%),
    #1e1e1e;
  border-color: rgba(131, 206, 203, 0.55);
}

.feature-tile.tile-wide {
  grid-column: span 4;
  background:
    linear-gradient(130deg, rgba(177, 168, 211, 0.18) 0%, rgba(177, 168, 211, 0.04) 100%),
    #1e1e1e;
  border-color: rgba(177, 168, 211, 0.52);
}

.feature-tile.tile-mid {
  grid-column: span 2;
  background:
    linear-gradient(130deg, rgba(214, 189, 134, 0.16) 0%, rgba(214, 189, 134, 0.04) 100%),
    #1d1d1d;
  border-color: rgba(214, 189, 134, 0.48);
}

.section .card {
  position: relative;
  overflow: hidden;
}

.section .card::before,
.section .card::after {
  display: none;
}

.kicker {
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: #dcdcdc;
  text-shadow: 0 0 0 rgba(0, 0, 0, 0.1);
  font-weight: 600;
  margin-bottom: 9px;
}

.component-card p {
  margin-bottom: 10px;
}

.mode-card p {
  margin-bottom: 12px;
}

.flow-card {
  padding: 14px;
}

.flow-card h3 {
  margin-bottom: 10px;
  font-size: 20px;
}

.flow-svg {
  width: calc(100% + 2px);
  max-width: none;
  margin: 0 -1px;
  height: auto;
  display: block;
  border: 1.5px solid var(--line);
  border-radius: 0;
  background: #121212;
}

.flow-svg .lane-bg {
  stroke: #222;
  stroke-width: 1;
}

.flow-svg .lane-left {
  fill: #161616;
}

.flow-svg .lane-mid {
  fill: #141414;
}

.flow-svg .lane-right {
  fill: #181818;
}

.flow-svg text {
  font-size: 13.5px;
  font-weight: 500;
  letter-spacing: 0.01em;
  fill: #e3e3e3;
}

.flow-svg .flow-node {
  stroke: #8a8a8a;
  stroke-width: 1.8;
}

.flow-svg .orchestrator-node {
  fill: #dbdbdb;
  stroke: #f3f3f3;
  stroke-width: 1.9;
}

.flow-svg .method-node {
  fill: #202020;
}

.flow-svg .sink-node {
  fill: #1c1c1c;
}

.flow-svg .input-node {
  fill: #232323;
}

.flow-svg .flow-node-title {
  font-size: 14.8px;
  font-weight: 700;
  fill: #0f0f0f;
}

.flow-svg .section-label {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11.8px;
  font-weight: 600;
  letter-spacing: 0.08em;
  fill: #b8c0c9;
}

.flow-svg .flow-line {
  stroke: #8f8f8f;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

.flow-svg .spine-line {
  stroke-width: 3;
}

.flow-svg .method-link {
  stroke-width: 2.4;
}

.flow-svg .branch-line {
  stroke: #a5a5a5;
  stroke-width: 2.2;
}

.flow-svg .bus-line {
  stroke: #a5a5a5;
  stroke-width: 2.8;
}

.flow-svg .bus-branch {
  stroke: #a5a5a5;
  stroke-width: 2.1;
}

.flow-svg .feedback-line {
  stroke: #8f8f8f;
  stroke-width: 2;
  stroke-dasharray: 7 5;
}

.flow-caption {
  margin-top: 14px;
  line-height: 1.68;
}

.spec-list,
.step-list {
  margin: 0 0 14px;
  padding-left: 19px;
  color: #d5d5d5;
  line-height: 1.58;
}

pre {
  margin: 0;
  padding: 13px 15px;
  border-radius: 0;
  border: 1.5px solid var(--line);
  background: #131313;
  overflow-x: auto;
}

pre code {
  font-size: 12.5px;
  line-height: 1.54;
  color: #e0e0e0;
}

.muted-note {
  font-size: 13px;
  color: var(--muted);
}

.timeline {
  display: grid;
  gap: 15px;
}

.update-card {
  border: 1.5px solid var(--line);
  border-radius: 0;
  padding: 18px;
  background: #171717;
  box-shadow: var(--shadow);
}

.update-meta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1.5px solid var(--line);
  border-radius: 0;
  padding: 6px 10px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: #e3e3e3;
  background: #202020;
  margin-bottom: 10px;
}

.update-card ul {
  margin: 0;
  padding-left: 18px;
  color: #d5d5d5;
  line-height: 1.58;
}

.spotlight {
  border-left: 3px solid var(--accent);
  padding-left: 12px;
}

.footer {
  margin-top: 30px;
  padding-top: 14px;
  border-top: 1.5px solid var(--line);
  font-size: 13px;
  color: #cfcfcf;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.architecture-board {
  padding: 14px;
}

.arch-svg {
  width: 100%;
  height: auto;
  display: block;
  border: 1.5px solid var(--line);
  background: #121212;
}

.arch-svg text {
  font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
  font-size: 16px;
  fill: #e4e4e4;
}

.arch-svg .arch-title {
  font-family: "IBM Plex Mono", monospace;
  font-size: 15px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.arch-svg .arch-small {
  font-size: 13px;
  fill: #aeaeae;
}

.arch-svg .arch-frame {
  fill: #202020;
  stroke: #8f8f8f;
  stroke-width: 2;
}

.arch-svg .arch-ingress {
  fill: #1b1b1b;
}

.arch-svg .arch-policy {
  fill: #212121;
}

.arch-svg .arch-providers {
  fill: #171717;
}

.arch-svg .arch-loop {
  fill: #1e1e1e;
}

.arch-svg .arch-memory {
  fill: #1a1a1a;
}

.arch-svg .arch-ops {
  fill: #222222;
}

.arch-svg .arch-chip {
  fill: #171717;
  stroke: #8f8f8f;
  stroke-width: 1.6;
}

.arch-svg .arch-step {
  fill: #181818;
  stroke: #8f8f8f;
  stroke-width: 1.8;
}

.arch-svg .arch-line {
  stroke: #aaaaaa;
  stroke-width: 2.1;
  fill: none;
}

.arch-grid {
  align-items: start;
}

.arch-caption {
  margin-top: 12px;
}

@media (max-width: 980px) {
  .flow-grid {
    grid-template-columns: 1fr;
  }

  .ribbon-nav {
    justify-content: flex-start;
  }

  .ribbon-nav a {
    min-width: 118px;
  }
}

@media (max-width: 700px) {
  .container {
    padding: 20px 14px 38px;
  }

  .topbar {
    flex-direction: column;
    align-items: flex-start;
  }

  .topbar-motto {
    max-width: none;
    width: 100%;
    font-size: 10px;
  }

  .hero {
    padding: 18px;
  }

  .hero::before {
    width: 8px;
  }

  .hero::after {
    display: none;
  }

  .hero-art {
    inset: auto 2px 6px auto;
    width: 166px;
    height: 98px;
    opacity: 0.42;
  }

  .lattice-ribbon {
    min-height: 176px;
    margin-top: 15px;
  }

  .ribbon-nav {
    min-height: 176px;
    justify-content: flex-start;
    align-content: flex-start;
    gap: 10px;
    padding: 14px 10px;
  }

  .ribbon-nav a {
    font-size: 12px;
    min-height: 40px;
    min-width: 108px;
    padding: 10px 14px;
  }

  .sub {
    font-size: 17px;
  }

  .feature-matrix {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .feature-tile.tile-major,
  .feature-tile.tile-wide,
  .feature-tile.tile-mid {
    grid-column: span 1;
  }

  .badge::after {
    display: none;
  }
}
