:root {
  --bg: #08090c;
  --bg-soft: #0d0f14;
  --surface: #11141b;
  --surface-2: #171b24;
  --border: #232936;
  --text: #e8ebf2;
  --muted: #9aa4b5;
  --accent: #4f8cff;
  --accent-2: #38d39f;
  --warn: #f2b34b;
  --danger: #ff6b6b;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
  --radius: 16px;
  --radius-sm: 10px;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  color-scheme: dark;
}

@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f7f8fb;
    --bg-soft: #ffffff;
    --surface: #ffffff;
    --surface-2: #f1f4f9;
    --border: #dde3ee;
    --text: #141821;
    --muted: #5b6678;
    --accent: #1f66e5;
    --accent-2: #0f9d72;
    --warn: #a86800;
    --danger: #c92a2a;
    --shadow: 0 18px 50px rgba(20, 28, 45, 0.1);
    color-scheme: light;
  }
}

[data-theme="light"] {
  --bg: #f7f8fb;
  --bg-soft: #ffffff;
  --surface: #ffffff;
  --surface-2: #f1f4f9;
  --border: #dde3ee;
  --text: #141821;
  --muted: #5b6678;
  --accent: #1f66e5;
  --accent-2: #0f9d72;
  --warn: #a86800;
  --danger: #c92a2a;
  --shadow: 0 18px 50px rgba(20, 28, 45, 0.1);
  color-scheme: light;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(900px 500px at 70% -10%, rgba(79, 140, 255, 0.16), transparent 60%),
    radial-gradient(600px 400px at 10% 10%, rgba(56, 211, 159, 0.08), transparent 55%),
    var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

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

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--surface);
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 100;
}
.skip:focus { left: 8px; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 14px clamp(16px, 4vw, 40px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-weight: 700;
  letter-spacing: -0.02em;
}
.brand:hover { text-decoration: none; }
.brand-mark {
  display: inline-grid;
  place-items: center;
  min-width: 34px;
  height: 30px;
  padding: 0 7px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  color: var(--accent-2);
  font-family: var(--mono);
  font-size: 13px;
}
.brand-name { font-size: 17px; }

.nav {
  display: flex;
  align-items: center;
  gap: 18px;
  font-size: 14px;
}
.nav a { color: var(--muted); }
.nav a:hover { color: var(--text); }
.nav-gh {
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
}
.theme-toggle {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--surface);
  color: var(--muted);
  cursor: pointer;
}
.theme-toggle:hover { color: var(--text); }

main {
  width: min(1120px, calc(100% - clamp(32px, 8vw, 80px)));
  margin: 0 auto;
  padding: clamp(48px, 8vw, 96px) 0 24px;
}

.hero { max-width: 850px; }
.eyebrow {
  margin: 0 0 18px;
  color: var(--accent-2);
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
h1 {
  margin: 0;
  font-size: clamp(40px, 7vw, 76px);
  line-height: 1.02;
  letter-spacing: -0.045em;
  font-weight: 780;
}
.accent {
  background: linear-gradient(100deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.lede {
  max-width: 680px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: clamp(17px, 2.2vw, 20px);
}

.install-line {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 30px;
  padding: 10px 10px 10px 16px;
  width: fit-content;
  max-width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.install-line code {
  font-size: clamp(13px, 2vw, 15px);
  overflow-wrap: anywhere;
}
.copy {
  border: 1px solid var(--border);
  background: var(--surface-2);
  color: var(--muted);
  border-radius: 8px;
  padding: 7px 12px;
  font: inherit;
  font-size: 13px;
  cursor: pointer;
}
.copy:hover { color: var(--text); }
.copy.done { color: var(--accent-2); border-color: var(--accent-2); }

.cta-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 18px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font-size: 14px;
  font-weight: 600;
}
.button:hover { text-decoration: none; border-color: var(--muted); }
.button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}
.button.primary:hover { filter: brightness(1.07); }

.stats {
  display: flex;
  gap: clamp(20px, 5vw, 56px);
  flex-wrap: wrap;
  margin: 44px 0 0;
  padding: 0;
  list-style: none;
}
.stats li { display: flex; flex-direction: column; }
.stats strong {
  font-size: clamp(24px, 4vw, 34px);
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.stats span { color: var(--muted); font-size: 13px; }

.terminal-wrap { margin: clamp(40px, 7vw, 72px) 0 0; }
.terminal {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  box-shadow: var(--shadow);
  overflow: hidden;
}
.terminal-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
  background: var(--bg-soft);
}
.terminal-bar span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--border);
}
.terminal-bar span:first-child { background: #ff5f57; }
.terminal-bar span:nth-child(2) { background: #febc2e; }
.terminal-bar span:nth-child(3) { background: #28c840; }
.terminal-bar em {
  margin-left: 8px;
  color: var(--muted);
  font-family: var(--mono);
  font-size: 12px;
  font-style: normal;
}
.terminal pre {
  margin: 0;
  padding: clamp(18px, 3vw, 28px);
  overflow-x: auto;
  font-size: clamp(12px, 1.8vw, 14px);
  line-height: 1.75;
}
.prompt { color: var(--accent-2); }
.dim { color: var(--muted); }
.ok { color: var(--accent-2); }

.section { margin-top: clamp(72px, 10vw, 120px); }
.section-head { max-width: 720px; margin-bottom: 28px; }
h2 {
  margin: 0;
  font-size: clamp(28px, 4.5vw, 44px);
  letter-spacing: -0.035em;
  line-height: 1.1;
}
.section-head p, .muted { color: var(--muted); }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 16px;
}
.card {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.card h3 { margin: 12px 0 8px; font-size: 17px; letter-spacing: -0.01em; }
.card p { margin: 0; color: var(--muted); font-size: 14.5px; }
.icon {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 1px solid var(--border);
  border-radius: 9px;
  background: var(--surface-2);
  color: var(--accent);
  font-size: 16px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
table { width: 100%; border-collapse: collapse; min-width: 560px; }
th, td { padding: 14px 18px; text-align: left; border-bottom: 1px solid var(--border); font-size: 14.5px; }
th { color: var(--muted); font-weight: 600; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; }
tbody tr:last-child td { border-bottom: 0; }
.yes { color: var(--accent-2); }
.warn { color: var(--warn); }
.no { color: var(--danger); }
.fineprint {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 13.5px;
  max-width: 820px;
}

.install-grid { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.install-card pre {
  margin: 12px 0;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-soft);
  overflow-x: auto;
  font-size: 13px;
}
.agents {
  margin-top: 18px;
  padding: 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}
.agents h3 { margin: 0 0 6px; }
.agents pre {
  margin: 14px 0;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-soft);
  overflow-x: auto;
  font-size: 13px;
}

.safety-list {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
  max-width: 900px;
}
.safety-list li {
  padding: 16px 18px;
  border: 1px solid var(--border);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--muted);
  font-size: 14.5px;
}
.safety-list strong { color: var(--text); }

.links-section { padding-bottom: 24px; }
.doc-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}
.doc-links a {
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 13.5px;
}
.doc-links a:hover { border-color: var(--accent); text-decoration: none; }

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  width: min(1120px, calc(100% - clamp(32px, 8vw, 80px)));
  margin: 0 auto;
  padding: 28px 0 40px;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 13px;
}
.site-footer .brand-mark { margin-right: 8px; }
.footer-links { display: flex; gap: 16px; }
.footer-links a { color: var(--muted); }

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

@media (max-width: 720px) {
  .nav a:not(.nav-gh) { display: none; }
  .stats { gap: 22px; }
  .site-footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
