@font-face {
  font-family: "Geist";
  src: url("assets/fonts/Geist-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Geist Mono";
  src: url("assets/fonts/GeistMono-Variable.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #0a0b0d;
  --bg-raised: #121417;
  --bg-card: #16181c;
  --border: #26292f;
  --border-hover: #383c44;
  --text: #edeef0;
  --text-dim: #a6abb3;
  --text-faint: #8a8f97;
  --accent: #4ade9a;
  --accent-2: #38bdf8;
  --accent-soft: rgba(74, 222, 154, 0.1);
  --accent-dim: #2f8f66;
  --gradient-brand: linear-gradient(135deg, var(--accent), var(--accent-2));
  --glow-shadow: 0 8px 30px -10px rgba(74, 222, 154, 0.35);
  --warn: #f5a623;
  --warn-soft: rgba(245, 166, 35, 0.1);
  --warn-dim: #8a6420;
  --focus-ring: #7ee0b8;
  --font-sans: "Geist", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "Geist Mono", ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --max-width: 960px;
  --nav-height: 64px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

  * {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-feature-settings: "ss01" 1;
}

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

a {
  color: inherit;
}

svg {
  display: block;
}

code {
  font-family: var(--font-mono);
}

.wrap {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.grad-text {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- scroll reveal ---------- */

.js-reveal .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

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

.js-reveal .reveal-group .reveal:nth-child(1) { transition-delay: 0s; }
.js-reveal .reveal-group .reveal:nth-child(2) { transition-delay: 0.06s; }
.js-reveal .reveal-group .reveal:nth-child(3) { transition-delay: 0.12s; }
.js-reveal .reveal-group .reveal:nth-child(4) { transition-delay: 0.18s; }
.js-reveal .reveal-group .reveal:nth-child(5) { transition-delay: 0.24s; }
.js-reveal .reveal-group .reveal:nth-child(6) { transition-delay: 0.3s; }

/* ---------- accessibility helpers ---------- */

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  top: -48px;
  left: 16px;
  z-index: 100;
  background: var(--accent);
  color: #05130c;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: 16px;
}

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
  border-radius: 4px;
}

.copy-btn:focus-visible,
.btn:focus-visible {
  outline-offset: 2px;
}

/* ---------- nav ---------- */

nav.site-nav {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(10, 11, 13, 0.75);
  backdrop-filter: blur(10px) saturate(140%);
  -webkit-backdrop-filter: blur(10px) saturate(140%);
  border-bottom: 1px solid var(--border);
}

nav.site-nav .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--nav-height);
  max-width: 1080px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 600;
  font-size: 16px;
  color: var(--text);
  letter-spacing: -0.01em;
}

.brand img {
  width: 26px;
  height: 26px;
  border-radius: 6px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 14px;
  color: var(--text-dim);
}

.nav-links a:not(.btn) {
  position: relative;
  text-decoration: none;
  transition: color 0.15s ease;
  padding-bottom: 2px;
}

.nav-links a:not(.btn)::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -3px;
  height: 2px;
  border-radius: 2px;
  background: var(--gradient-brand);
  transition: right 0.2s ease;
}

.nav-links a:not(.btn):hover {
  color: var(--text);
}

.nav-links a:not(.btn):hover::after,
.nav-links a.active::after {
  right: 0;
}

.nav-links a.active {
  color: var(--text);
}

.nav-gh {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--text);
  cursor: pointer;
}

.nav-toggle:hover {
  border-color: var(--border-hover);
}

.nav-toggle .icon-close {
  display: none;
}

.nav-toggle[aria-expanded="true"] .icon-menu {
  display: none;
}

.nav-toggle[aria-expanded="true"] .icon-close {
  display: block;
}

/* ---------- buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.15s ease, background 0.15s ease, box-shadow 0.2s ease;
  font-family: inherit;
}

.btn-primary {
  background: var(--gradient-brand);
  color: #05130c;
  box-shadow: 0 4px 20px -6px rgba(74, 222, 154, 0.45);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 28px -6px rgba(74, 222, 154, 0.6);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: transparent;
  border-color: var(--border);
  color: var(--text);
}

.btn-secondary:hover {
  border-color: var(--border-hover);
  background: var(--bg-raised);
}

.btn-nav {
  padding: 8px 14px;
  font-size: 13.5px;
}

/* ---------- hero ---------- */

header.hero {
  position: relative;
  padding: 108px 0 64px;
  text-align: center;
  overflow: hidden;
  background:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 42px 42px, 42px 42px;
  background-position: center, center;
  -webkit-mask-image: linear-gradient(180deg, #000 0%, #000 65%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, #000 65%, transparent 100%);
}

header.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 60% 55% at 50% 0%, transparent 0%, var(--bg) 100%);
  pointer-events: none;
  z-index: 1;
}

.hero-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(64px);
  pointer-events: none;
  z-index: 0;
  animation: drift 14s ease-in-out infinite alternate;
}

.hero-glow.a {
  width: 420px;
  height: 420px;
  top: -140px;
  left: 50%;
  margin-left: -360px;
  background: radial-gradient(circle, rgba(74, 222, 154, 0.32), transparent 70%);
}

.hero-glow.b {
  width: 380px;
  height: 380px;
  top: -120px;
  left: 50%;
  margin-left: 40px;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.28), transparent 70%);
  animation-delay: -7s;
}

@keyframes drift {
  from {
    transform: translate(0, 0) scale(1);
  }
  to {
    transform: translate(24px, 18px) scale(1.06);
  }
}

header.hero .wrap {
  position: relative;
  z-index: 2;
  max-width: 760px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid rgba(74, 222, 154, 0.25);
  padding: 5px 12px;
  border-radius: 999px;
  margin-bottom: 28px;
}

.eyebrow .dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--gradient-brand);
  flex-shrink: 0;
}

h1 {
  font-size: clamp(32px, 4.6vw, 50px);
  line-height: 1.15;
  letter-spacing: -0.03em;
  font-weight: 600;
  margin: 0 0 22px;
}

h1 .dim {
  color: var(--text-faint);
  font-weight: 500;
}

h1 code {
  font-size: 0.86em;
  font-weight: 600;
  padding: 0.1em 0.1em;
}

.lede {
  font-size: 17.5px;
  color: var(--text-dim);
  max-width: 620px;
  margin: 0 auto 36px;
}

.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 36px;
}

.hero-actions .btn svg {
  width: 16px;
  height: 16px;
}

/* ---------- code blocks ---------- */

.code-block {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  text-align: left;
  overflow: hidden;
}

.code-block .code-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 11.5px;
  color: var(--text-faint);
}

.code-block pre {
  margin: 0;
  padding: 16px 18px;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 13.5px;
  line-height: 1.7;
  color: #d3e6db;
}

.code-block .comment {
  color: var(--text-faint);
}

.copy-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 4px 9px;
  border-radius: 6px;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.copy-btn svg {
  width: 12px;
  height: 12px;
}

.copy-btn:hover {
  border-color: var(--border-hover);
  color: var(--text);
}

.copy-btn.copied {
  color: var(--accent);
  border-color: var(--accent-dim);
}

.install-block {
  max-width: 460px;
  margin: 0 auto;
}

/* ---------- sections ---------- */

section {
  padding: 72px 0;
  border-top: 1px solid var(--border);
  scroll-margin-top: var(--nav-height);
  position: relative;
}

.section-head {
  max-width: 620px;
  margin: 0 auto 40px;
  text-align: center;
}

.section-head .kicker {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 10px;
}

.section-head h2 {
  font-size: clamp(24px, 3vw, 33px);
  margin: 0 0 12px;
  letter-spacing: -0.02em;
  font-weight: 600;
}

.section-head p {
  color: var(--text-dim);
  margin: 0;
}

/* ---------- demo ---------- */

.demo-frame {
  border: 1px solid var(--border);
  border-radius: 12px;
  overflow: hidden;
  background: var(--bg-card);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.demo-frame:hover {
  border-color: var(--border-hover);
  box-shadow: var(--glow-shadow);
}

.demo-frame img {
  width: 100%;
}

/* ---------- terminal example ---------- */

.terminal {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  max-width: 720px;
  margin: 0 auto;
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}

.terminal:hover {
  border-color: var(--border-hover);
  box-shadow: var(--glow-shadow);
}

.terminal .code-head {
  padding: 10px 14px;
}

.terminal .dots {
  display: flex;
  gap: 6px;
}

.terminal .dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border-hover);
}

.terminal pre {
  margin: 0;
  padding: 20px 22px;
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.75;
  overflow-x: auto;
  color: #cfd3d8;
}

.terminal .prompt {
  color: var(--accent);
}

.terminal .hit-title {
  color: #f0f2f4;
}

.terminal .muted {
  color: var(--text-faint);
}

.cursor-blink {
  display: inline-block;
  width: 7px;
  height: 14px;
  margin-left: 2px;
  background: var(--accent);
  vertical-align: -2px;
  animation: blink 1s steps(1) infinite;
}

@keyframes blink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

/* ---------- feature grid ---------- */

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 22px;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: var(--glow-shadow);
}

.icon-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(74, 222, 154, 0.16), rgba(56, 189, 248, 0.12));
  border: 1px solid rgba(74, 222, 154, 0.18);
  color: var(--accent);
  margin-bottom: 16px;
}

.icon-chip svg {
  width: 18px;
  height: 18px;
}

.card h3 {
  font-size: 15.5px;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}

.card p {
  font-size: 13.5px;
  color: var(--text-dim);
  margin: 0;
  line-height: 1.6;
}

/* ---------- stats ---------- */

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-bottom: 32px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 26px 28px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.stat-card:hover {
  border-color: var(--border-hover);
  box-shadow: var(--glow-shadow);
}

.stat-card .num-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 4px;
}

.stat-card .num {
  font-family: var(--font-mono);
  font-size: 42px;
  font-weight: 700;
  line-height: 1;
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.stat-card .label {
  font-size: 13.5px;
  color: var(--text-dim);
}

.stat-card .sub {
  font-size: 12px;
  color: var(--text-faint);
  margin-bottom: 16px;
}

.stat-bar {
  position: relative;
  height: 8px;
  border-radius: 999px;
  background: var(--bg-raised);
  overflow: visible;
}

.stat-bar .fill {
  height: 100%;
  border-radius: 999px;
  background: var(--gradient-brand);
  width: var(--pct, 0%);
  transition: width 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.js-reveal .stat-bar .fill {
  width: 0%;
}

.js-reveal .reveal.is-visible .stat-bar .fill {
  width: var(--pct, 0%);
}

.stat-bar .target-line {
  position: absolute;
  top: -4px;
  bottom: -4px;
  left: 70%;
  width: 2px;
  background: var(--text-faint);
  opacity: 0.6;
}

.stat-bar .target-line::after {
  content: ">70% target";
  position: absolute;
  top: -20px;
  left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text-faint);
  white-space: nowrap;
}

.caveat {
  font-size: 13px;
  color: var(--text-faint);
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
  line-height: 1.7;
}

.caveat a {
  color: var(--text-dim);
}

table.latency {
  width: 100%;
  max-width: 500px;
  margin: 40px auto 0;
  border-collapse: collapse;
  font-size: 13.5px;
  font-family: var(--font-mono);
}

table.latency caption {
  text-align: left;
  font-family: var(--font-sans);
  font-size: 12px;
  color: var(--text-faint);
  margin-bottom: 10px;
}

table.latency th,
table.latency td {
  padding: 9px 12px;
  border-bottom: 1px solid var(--border);
  text-align: left;
}

table.latency th {
  color: var(--text-faint);
  font-weight: 500;
  font-size: 11.5px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

table.latency td:last-child,
table.latency th:last-child {
  text-align: right;
  color: var(--text);
}

table.latency tr:last-child td {
  border-bottom: none;
  color: var(--accent);
  font-weight: 600;
}

/* ---------- honesty / where it breaks ---------- */

section.honesty {
  background: linear-gradient(180deg, var(--warn-soft), transparent 40%);
}

.honesty .section-head .kicker {
  color: var(--warn);
}

.honesty-list {
  max-width: 720px;
  margin: 0 auto;
  display: grid;
  gap: 12px;
}

.honesty-item {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-left: 2px solid var(--warn-dim);
  border-radius: 8px;
  padding: 16px 18px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.honesty-item:hover {
  border-color: var(--border-hover);
  border-left-color: var(--warn);
  transform: translateX(2px);
}

.honesty-item .mark {
  flex-shrink: 0;
  color: var(--warn);
  margin-top: 1px;
}

.honesty-item .mark svg {
  width: 16px;
  height: 16px;
}

.honesty-item p {
  margin: 0;
  font-size: 13.5px;
  color: var(--text-dim);
  line-height: 1.65;
}

.honesty-item strong {
  color: var(--text);
}

/* ---------- quickstart ---------- */

.quickstart-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 44px;
}

.quickstart-grid .code-block {
  height: 100%;
}

/* ---------- commands table ---------- */

.cmd-list {
  max-width: 620px;
  margin: 0 auto;
  font-family: var(--font-mono);
  font-size: 13.5px;
}

.cmd-list dt {
  color: var(--accent);
  margin-top: 14px;
  font-weight: 600;
}

.cmd-list dd {
  margin: 4px 0 0;
  color: var(--text-dim);
  font-family: var(--font-sans);
  font-size: 13.5px;
}

/* ---------- footer ---------- */

footer {
  border-top: 1px solid var(--border);
  padding: 40px 0;
}

footer .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 13px;
  color: var(--text-faint);
}

footer .foot-links {
  display: flex;
  gap: 20px;
}

footer a {
  text-decoration: none;
  color: var(--text-faint);
  transition: color 0.15s ease;
}

footer a:hover {
  color: var(--text-dim);
}

/* ---------- responsive ---------- */
/* breakpoints: 1024 / 768 / 375, per standard device tiers */

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

@media (max-width: 768px) {
  .nav-links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 8px 24px 20px;
    transform: translateY(-8px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.15s ease, transform 0.15s ease, visibility 0.15s;
  }

  .nav-links.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
  }

  .nav-links a:not(.btn) {
    padding: 13px 2px;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
  }

  .nav-links a:not(.btn)::after {
    display: none;
  }

  .nav-links .nav-gh {
    border-bottom: 1px solid var(--border);
  }

  .nav-links .btn-nav {
    margin-top: 14px;
    justify-content: center;
  }

  .nav-toggle {
    display: inline-flex;
  }

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

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

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

  header.hero {
    padding: 64px 0 44px;
  }

  section {
    padding: 56px 0;
  }

  footer .wrap {
    flex-direction: column;
    text-align: center;
  }
}

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