:root {
  --bg: #f4f7fb;
  --surface: rgba(255, 255, 255, 0.94);
  --surface-strong: #ffffff;
  --border: #d8e1ed;
  --text: #102033;
  --muted: #5f7084;
  --accent: #1768ac;
  --accent-soft: #e8f1fc;
  --accent-strong: #0f4f9e;
  --shadow: 0 20px 46px rgba(16, 32, 51, 0.08);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "IBM Plex Sans", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(23, 104, 172, 0.12), transparent 24%),
    radial-gradient(circle at right center, rgba(23, 104, 172, 0.06), transparent 26%),
    linear-gradient(180deg, #fbfdff 0%, var(--bg) 100%);
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
}

.skip-link:focus {
  left: 16px;
  top: 16px;
  background: var(--text);
  color: white;
  padding: 10px 12px;
  border-radius: 10px;
  z-index: 20;
}

.container {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(12px);
  background: rgba(244, 247, 251, 0.82);
  border-bottom: 1px solid rgba(216, 225, 237, 0.7);
}

.nav-shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px 0;
}

.brand {
  font-weight: 700;
  text-decoration: none;
  letter-spacing: -0.02em;
  text-transform: lowercase;
}

nav {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

nav a {
  text-decoration: none;
  color: var(--muted);
  font-weight: 500;
}

body[data-page="home"] nav a[href="./"],
body[data-page="architecture"] nav a[href="../architecture/"],
body[data-page="benchmarks"] nav a[href="../benchmarks/"],
body[data-page="examples"] nav a[href="../examples/"] {
  color: var(--accent);
}

.hero,
.subpage-hero,
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

.hero {
  margin-top: 30px;
  border-radius: 30px;
  padding: 38px;
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(360px, 0.98fr);
  gap: 34px;
  align-items: center;
}

.subpage-hero {
  margin-top: 26px;
  border-radius: 30px;
  padding: 32px;
  background:
    linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(248,251,255,0.94) 100%);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-family: "IBM Plex Mono", monospace;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 12px;
}

h1, h2, h3, p, ul, ol, table {
  margin: 0;
}

h1 {
  font-size: clamp(2.25rem, 4vw, 4.1rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

h2 {
  font-size: clamp(1.65rem, 2vw, 2.2rem);
  line-height: 1.1;
  letter-spacing: -0.03em;
}

h3 {
  font-size: 1.12rem;
  margin-bottom: 10px;
}

.lead,
.card p,
.card li,
.copyright {
  color: var(--muted);
  line-height: 1.7;
}

.lead {
  margin-top: 18px;
  font-size: 1.07rem;
  max-width: 640px;
}

.hero-note,
.section-kicker,
.media-caption,
.detail-list p {
  color: var(--muted);
  line-height: 1.7;
}

.hero-note {
  margin-top: 16px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.93rem;
}

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

.actions a,
.button-link {
  text-decoration: none;
  color: white;
  background: var(--accent);
  border-radius: 999px;
  padding: 12px 16px;
  font-weight: 600;
}

.actions a.secondary {
  background: #dfe8f4;
  color: var(--text);
}

.hero-highlights {
  margin: 22px 0 0;
  padding-left: 18px;
  display: grid;
  gap: 10px;
  color: var(--muted);
}

.section {
  margin-top: 56px;
}

.section-intro,
.section-head {
  margin-bottom: 18px;
}

.section-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
}

.text-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.section-kicker {
  margin: 0 0 18px;
  max-width: 760px;
  font-size: 1rem;
}

.grid {
  display: grid;
  gap: 18px;
}

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

.three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.four {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.card {
  border-radius: 24px;
  padding: 24px;
  position: relative;
}

.visual-card {
  overflow: hidden;
}

.visual-card img,
.visual-card video,
.hero-card img,
.hero-card video {
  width: 100%;
  border-radius: 20px;
  border: 1px solid rgba(216, 225, 237, 0.85);
  background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
}

.visual-card video {
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.hero-card {
  align-self: stretch;
  display: grid;
  align-items: center;
}

.hero-preview {
  display: grid;
  gap: 10px;
  padding: 16px;
  border-radius: 24px;
  border: 1px solid rgba(216, 225, 237, 0.9);
  background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(247,250,254,0.96) 100%);
  box-shadow: var(--shadow);
}

.hero-preview-head {
  margin-bottom: 0;
}

.hero-preview video {
  aspect-ratio: 16 / 9.1;
  object-fit: cover;
}

.hero-preview-caption {
  margin-top: 2px;
  font-size: 0.92rem;
}

.media-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 12px;
  margin-bottom: 14px;
}

.media-eyebrow {
  margin: 0 0 6px;
  color: var(--accent);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.media-tag {
  border: 1px solid var(--border);
  background: #f4f8fe;
  color: var(--accent-strong);
  border-radius: 999px;
  padding: 6px 10px;
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.76rem;
  white-space: nowrap;
}

.media-caption {
  margin-top: 14px;
  font-size: 0.97rem;
}

.detail-list {
  margin-top: 16px;
  display: grid;
  gap: 8px;
}

.stats-grid {
  margin-top: 18px;
  margin-bottom: 0;
}

.stat-card {
  display: grid;
  gap: 6px;
  min-height: 108px;
  align-content: center;
  background: linear-gradient(180deg, rgba(255,255,255,0.98) 0%, rgba(245,249,255,0.95) 100%);
  padding: 18px;
  box-shadow: none;
}

.stat-value {
  font-size: clamp(1.8rem, 3vw, 2.5rem);
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--accent-strong);
  font-weight: 700;
}

.stat-label {
  color: var(--muted);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.86rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.table-wrap {
  overflow-x: auto;
  margin-top: 14px;
  border: 1px solid #e4ebf3;
  border-radius: 16px;
  background: white;
}

.flow-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.flow-card {
  background: var(--surface-strong);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 12px;
  min-height: 126px;
  align-content: start;
}

.flow-card strong {
  color: var(--accent);
  font-family: "IBM Plex Mono", monospace;
  font-size: 1rem;
}

.flow-card span {
  color: var(--text);
  font-weight: 600;
  line-height: 1.35;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
  min-width: 420px;
}

th, td {
  padding: 10px 8px;
  text-align: left;
  border-bottom: 1px solid #e4ebf3;
}

th {
  color: var(--accent-strong);
  font-family: "IBM Plex Mono", monospace;
  font-size: 0.83rem;
  background: #f4f8fe;
}

.plain-list {
  padding-left: 18px;
  display: grid;
  gap: 10px;
}

.site-footer {
  margin-top: 28px;
  padding: 24px 0 42px;
  border-top: 1px solid rgba(216, 225, 237, 0.8);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr auto;
  gap: 22px;
  align-items: start;
}

.site-footer nav {
  display: grid;
  gap: 8px;
}

.hero-copy {
  display: grid;
  align-content: center;
}

.hero-card {
  min-height: 100%;
}

.media-grid,
.feature-grid,
.balanced-grid {
  align-items: stretch;
}

.single-card-grid {
  margin-top: 18px;
}

.core-idea-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(320px, 0.88fr);
  gap: 22px;
  align-items: start;
}

.core-idea-copy {
  display: grid;
  gap: 18px;
}

.process-visual {
  align-self: stretch;
}

.benchmark-shell {
  display: grid;
  gap: 20px;
}

.benchmark-top {
  align-items: stretch;
}

.benchmark-copy,
.benchmark-visual,
.benchmark-table-card,
.scope-grid .card,
.feature-grid .card,
.balanced-grid .card {
  height: 100%;
}

.benchmark-copy {
  display: grid;
  align-content: start;
}

.benchmark-table-card {
  padding-top: 20px;
}

.table-head {
  margin-bottom: 8px;
}

.scope-grid {
  align-items: stretch;
}

@media (max-width: 1080px) {
  .hero,
  .two,
  .four,
  .three,
  .footer-grid,
  .flow-grid,
  .core-idea-shell {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 820px) {
  .nav-shell,
  .section-head {
    align-items: start;
    flex-direction: column;
  }

  .container {
    width: min(1180px, calc(100% - 24px));
  }

  .hero,
  .subpage-hero,
  .card {
    padding: 20px;
  }

  .hero-preview {
    padding: 14px;
  }

  .hero-highlights {
    margin-top: 18px;
  }

  .section {
    margin-top: 40px;
  }

  .media-header {
    flex-direction: column;
  }
}
