:root {
  --accent: #2f6feb;
  --accent-strong: #1f5ad1;
  --accent-soft: rgba(47, 111, 235, 0.10);
  --accent-text: #1d56c9;
  --on-accent: #ffffff;

  --bg: #fbfcfe;
  --bg-alt: #f1f4f9;
  --surface: #ffffff;
  --text: #0f1726;
  --muted: #4a5568;
  --border: #dde3ec;
  --code-bg: #0e1522;
  --code-text: #e6edf7;
  --danger: #d1323b;
  --shadow: 0 1px 2px rgba(15, 23, 38, 0.06), 0 12px 32px -12px rgba(15, 23, 38, 0.18);
  --shadow-lg: 0 2px 4px rgba(15, 23, 38, 0.05), 0 40px 80px -30px rgba(15, 40, 100, 0.35);

  --radius: 14px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --accent-strong: #4a83f0;
    --accent-soft: rgba(80, 140, 255, 0.14);
    --accent-text: #7eaaff;

    --bg: #0b0f17;
    --bg-alt: #10161f;
    --surface: #141b26;
    --text: #e8edf5;
    --muted: #a3afc2;
    --border: #253043;
    --code-bg: #060a11;
    --code-text: #e6edf7;
    --danger: #ff6b72;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 32px -12px rgba(0, 0, 0, 0.6);
    --shadow-lg: 0 40px 80px -30px rgba(0, 0, 0, 0.8);
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-text); text-underline-offset: 3px; }
a:hover { color: var(--accent-strong); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

code, kbd {
  font-family: var(--mono);
  font-size: 0.88em;
  background: var(--accent-soft);
  padding: 0.1em 0.38em;
  border-radius: 5px;
  overflow-wrap: anywhere;
}
kbd { border: 1px solid var(--border); background: var(--surface); }

h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0; }
h2 { font-size: clamp(1.7rem, 1.2rem + 2vw, 2.4rem); max-width: 22ch; }
h3 { font-size: 1.08rem; letter-spacing: -0.01em; }
p { margin: 0.6em 0; }

.wrap { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 640px) { .wrap { padding: 0 28px; } }
.narrow { max-width: 820px; }

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

.skip {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--accent); color: var(--on-accent);
  padding: 10px 16px; border-radius: 8px; font-weight: 600; text-decoration: none;
}
.skip:focus { top: 12px; color: var(--on-accent); }

.topbar {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.topbar-inner { display: flex; align-items: center; gap: 20px; height: 60px; }
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--text); text-decoration: none; font-weight: 700; letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand:hover { color: var(--text); }
.brand-mark { width: 28px; height: 28px; flex: none; }
.brand-mark rect:first-child { fill: var(--accent); }
.brand-mark .bm-line { fill: none; stroke: #fff; stroke-width: 2.4; stroke-linecap: round; }

.nav { display: none; list-style: none; margin: 0 0 0 auto; padding: 0; gap: 4px; }
.nav a {
  display: block; padding: 6px 12px; border-radius: 8px;
  color: var(--muted); text-decoration: none; font-size: 0.94rem; font-weight: 500;
}
.nav a:hover { color: var(--text); background: var(--accent-soft); }
@media (min-width: 860px) { .nav { display: flex; } }

.lang { margin-left: auto; display: inline-flex; gap: 4px; }
@media (min-width: 860px) { .lang { margin-left: 8px; } }
.lang-btn {
  display: inline-flex; padding: 4px; border-radius: 7px; cursor: pointer;
  background: transparent; border: 1px solid transparent; opacity: 0.6;
}
.lang-btn:hover { opacity: 1; background: var(--accent-soft); }
.lang-btn[aria-pressed="true"] { opacity: 1; border-color: var(--accent); }
.lang-btn svg { width: 24px; height: 16px; display: block; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15); }

.gh-link {
  display: inline-flex; padding: 8px; border-radius: 8px; color: var(--text);
}
.gh-link:hover { background: var(--accent-soft); color: var(--text); }
.gh-link svg { width: 22px; height: 22px; }

.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 48px; padding: 0 22px; border-radius: 12px;
  font-weight: 650; font-size: 1rem; text-decoration: none;
  transition: transform 0.12s ease, background-color 0.12s ease, box-shadow 0.12s ease;
}
.btn svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.btn svg.fill { stroke: none; }
.btn-primary {
  background: var(--accent); color: var(--on-accent);
  box-shadow: 0 1px 0 rgba(255,255,255,0.15) inset, 0 8px 24px -8px rgba(47, 111, 235, 0.7);
}
.btn-primary:hover { background: #2560d6; color: var(--on-accent); transform: translateY(-1px); }
.btn-ghost { background: var(--surface); color: var(--text); border: 1px solid var(--border); }
.btn-ghost:hover { color: var(--text); border-color: var(--accent); transform: translateY(-1px); }
@media (max-width: 479px) { .btn { width: 100%; } }
@media (prefers-reduced-motion: reduce) { .btn { transition: none; } .btn:hover { transform: none; } }

.hero {
  position: relative;
  padding: 64px 0 0;
  background:
    radial-gradient(60% 50% at 50% 0%, rgba(47, 111, 235, 0.16), transparent 70%),
    linear-gradient(var(--bg), var(--bg));
  overflow: hidden;
}
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image:
    linear-gradient(var(--border) 1px, transparent 1px),
    linear-gradient(90deg, var(--border) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(70% 55% at 50% 10%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(70% 55% at 50% 10%, #000 20%, transparent 75%);
  opacity: 0.55;
}
.hero-inner { position: relative; text-align: center; display: flex; flex-direction: column; align-items: center; }
.eyebrow {
  display: inline-block; margin: 0 0 18px;
  font-size: 0.82rem; font-weight: 600; letter-spacing: 0.02em; color: var(--accent-text);
  background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  padding: 5px 14px; border-radius: 999px;
}
.hero h1 { font-size: clamp(2.4rem, 1.4rem + 5vw, 4.4rem); letter-spacing: -0.035em; font-weight: 800; }
.tagline {
  font-size: clamp(1.15rem, 1rem + 0.9vw, 1.5rem); font-weight: 600; color: var(--text);
  max-width: 34ch; margin: 18px auto 0; line-height: 1.35;
}
.lede { color: var(--muted); max-width: 58ch; margin: 14px auto 0; }
.hero .cta { justify-content: center; }
.fine { color: var(--muted); font-size: 0.86rem; margin-top: 16px; }

.shot {
  margin: 0; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--border); background: var(--surface); box-shadow: var(--shadow);
}
.shot-hero { position: relative; margin: 52px auto 0; max-width: 1040px; box-shadow: var(--shadow-lg); border-bottom-left-radius: 0; border-bottom-right-radius: 0; border-bottom: 0; }
.shot-chrome { display: flex; gap: 7px; padding: 11px 14px; border-bottom: 1px solid var(--border); background: var(--bg-alt); }
.shot-chrome span { width: 11px; height: 11px; border-radius: 50%; background: var(--border); }
.shot-chrome span:first-child { background: #ff5f57; }
.shot-chrome span:nth-child(2) { background: #febc2e; }
.shot-chrome span:nth-child(3) { background: #28c840; }

.section { padding: 88px 0; border-top: 1px solid var(--border); }
.section.alt { background: var(--bg-alt); }
.kicker {
  margin: 0 0 10px; font-size: 0.8rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.12em; color: var(--accent-text);
}
.section-lede { color: var(--muted); max-width: 62ch; margin-top: 14px; }
.note {
  margin-top: 28px; padding: 16px 18px; border-radius: 12px; color: var(--muted);
  background: var(--surface); border: 1px solid var(--border); font-size: 0.95rem;
}
.note b { color: var(--text); }
.note-warn { border-left: 4px solid #d99a00; }
.h-sub { margin-top: 36px; font-size: 1.2rem; }

.grid { list-style: none; padding: 0; margin: 40px 0 0; display: grid; gap: 16px; }
.features { grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px 22px 18px; transition: border-color 0.15s ease, transform 0.15s ease;
}
.card:hover { border-color: color-mix(in srgb, var(--accent) 50%, var(--border)); }
.card p { color: var(--muted); font-size: 0.95rem; margin-bottom: 0; }
.ic {
  width: 40px; height: 40px; padding: 9px; margin-bottom: 14px; border-radius: 10px;
  background: var(--accent-soft); stroke: var(--accent-text); fill: none;
  stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round;
}

.steps { list-style: none; padding: 0; margin: 40px 0 0; display: grid; gap: 20px; }
@media (min-width: 900px) { .steps { grid-template-columns: repeat(3, 1fr); } }
.step {
  position: relative; background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 22px; display: flex; gap: 14px;
}
.step-n {
  flex: none; width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 800; font-size: 0.95rem;
  background: var(--accent); color: var(--on-accent);
}
.step-body { min-width: 0; display: flex; flex-direction: column; }
.step-body p { color: var(--muted); font-size: 0.95rem; }
.step-body b { color: var(--text); }
.shot-sm { margin-top: auto; box-shadow: none; }
.step-body p + .shot-sm { margin-top: 14px; }

.quick {
  margin-top: 48px; padding: 28px; border-radius: 20px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 12%, var(--surface)), var(--surface) 60%);
  border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--border));
}
@media (min-width: 640px) { .quick { padding: 36px; } }
.quick-head h3 { font-size: clamp(1.35rem, 1.1rem + 1vw, 1.7rem); margin-top: 10px; }
.quick-head p { color: var(--muted); }
.badge {
  display: inline-block; font-size: 0.75rem; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--on-accent); background: var(--accent); padding: 3px 10px; border-radius: 999px;
}
.quick-flow {
  list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 12px; counter-reset: q;
}
@media (min-width: 760px) { .quick-flow { grid-template-columns: repeat(3, 1fr); } }
.quick-flow li {
  counter-increment: q; position: relative;
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 16px 16px 14px;
}
.quick-flow li::before {
  content: counter(q); position: absolute; top: 14px; right: 16px;
  font-weight: 800; font-size: 1.4rem; color: color-mix(in srgb, var(--accent) 40%, transparent);
}
.who { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--accent-text); }
.quick-flow p { margin: 6px 0 0; font-size: 0.95rem; }
.quick-facts { list-style: none; padding: 0; margin: 22px 0 0; display: grid; gap: 10px; }
.quick-facts li { display: flex; gap: 12px; align-items: flex-start; font-size: 0.96rem; }
.quick-facts svg {
  flex: none; width: 22px; height: 22px; margin-top: 2px;
  fill: none; stroke: var(--accent-text); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round;
}
.quick-limit {
  margin: 22px 0 0; padding: 12px 16px; border-radius: 10px; font-size: 0.93rem; color: var(--muted);
  border-left: 3px solid #d4a017; background: color-mix(in srgb, #d4a017 10%, var(--surface));
}
.quick-limit b { color: var(--text); }

.paths {
  margin: 40px 0 0; padding: 24px 12px; border-radius: var(--radius);
  background: var(--bg-alt); border: 1px solid var(--border);
}
.paths-svg { display: block; width: 100%; max-width: 760px; height: auto; margin: 0 auto; font-family: var(--font); }
.node rect { fill: var(--surface); stroke: var(--border); stroke-width: 1.5; }
.node-server rect { stroke: var(--accent); stroke-width: 2; }
.n-title { text-anchor: middle; font-size: 17px; font-weight: 700; fill: var(--text); }
.n-sub { text-anchor: middle; font-size: 13px; fill: var(--muted); font-family: var(--mono); }
.link { fill: none; stroke-width: 3; stroke-linecap: round; stroke-linejoin: round; }
.l1 { stroke: var(--accent); }
.l2 { stroke: var(--accent); stroke-dasharray: 9 7; opacity: 0.8; }
.l3 { stroke: var(--muted); stroke-dasharray: 2 7; }
.tag { fill: var(--accent); }
.tag-n { text-anchor: middle; font-size: 14px; font-weight: 800; fill: #fff; }
.l-label { text-anchor: middle; font-size: 13px; fill: var(--muted); }
.l-left { text-anchor: start; }

.path-list { margin: 28px 0 0; padding: 0; list-style: none; counter-reset: p; display: grid; gap: 14px; }
@media (min-width: 860px) { .path-list { grid-template-columns: repeat(3, 1fr); } }
.path-list li {
  counter-increment: p; position: relative; padding-left: 40px; color: var(--muted); font-size: 0.96rem;
}
.path-list li::before {
  content: counter(p); position: absolute; left: 0; top: 0;
  width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent); color: #fff; font-weight: 800; font-size: 0.85rem;
}
.path-list b { color: var(--text); }

.sec { grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 28px 32px; }
.sec li { padding-top: 16px; border-top: 2px solid var(--accent); }
.sec p { color: var(--muted); font-size: 0.94rem; margin-bottom: 0; }

.code {
  position: relative; margin-top: 28px; border-radius: 12px;
  background: var(--code-bg); border: 1px solid #1d2738; box-shadow: var(--shadow);
}
.code pre {
  margin: 0; padding: 18px 18px 60px; overflow-x: auto;
  font-family: var(--mono); font-size: 0.9rem; line-height: 1.6; color: var(--code-text);
}
.code code {
  background: none; padding: 0; font-size: inherit; color: inherit;
  white-space: pre-wrap; overflow-wrap: anywhere; word-break: break-all;
}
@media (min-width: 640px) { .code pre { padding: 20px 110px 20px 22px; } }
.copy {
  position: absolute; right: 10px; bottom: 10px;
  display: inline-flex; align-items: center; gap: 6px;
  font: 600 0.85rem var(--font); color: #e6edf7;
  background: rgba(255, 255, 255, 0.08); border: 1px solid rgba(255, 255, 255, 0.16);
  padding: 7px 12px; border-radius: 8px; cursor: pointer;
}
@media (min-width: 640px) { .copy { top: 12px; bottom: auto; } }
.copy:hover { background: rgba(255, 255, 255, 0.16); }
.copy.done { background: #1f7a3d; border-color: #2ea05a; }
.copy svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.copy-status { min-height: 0; margin: 0; }

.checks { list-style: none; padding: 0; margin: 22px 0 8px; display: grid; gap: 8px; }
.checks li { position: relative; padding-left: 30px; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: 0.35em; width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent-soft)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232f6feb' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 12 4 4 8-8'/%3E%3C/svg%3E")
    center / 12px no-repeat;
}

.cta-alt { margin: 14px 0 0; font-size: 0.93rem; }
.cta-alt a { color: var(--muted); }
.cta-alt a:hover { color: var(--accent-text); }

.downloads { grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }
.dl-card {
  display: flex; flex-direction: column; min-width: 0;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 22px;
}
.dl-card.is-yours { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
.dl-card h3 { font-size: 1.2rem; }
.dl-req { margin: 4px 0 0; font-size: 0.86rem; font-weight: 600; color: var(--accent-text); }
.dl-does { font-size: 0.95rem; }
.dl-hint { font-size: 0.88rem; color: var(--muted); margin-top: 0; }
.dl-action { margin-top: auto; padding-top: 14px; }
.dl-btn { width: 100%; }
.dl-meta { min-height: 1.3em; margin: 8px 0 0; font-size: 0.82rem; color: var(--muted); text-align: center; overflow-wrap: anywhere; }
.code.compact { margin: 4px 0 0; box-shadow: none; }
.code.compact pre { padding: 12px 14px 50px; font-size: 0.8rem; }
.code.compact .copy { top: auto; bottom: 8px; right: 8px; }
.sums-link { display: inline-block; margin-top: 6px; font-weight: 600; }

.faq { margin-top: 32px; display: grid; gap: 10px; }
.faq details {
  background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 0 18px;
}
.faq details[open] { border-color: color-mix(in srgb, var(--accent) 45%, var(--border)); }
.faq summary {
  cursor: pointer; list-style: none; padding: 16px 28px 16px 0; font-weight: 650; position: relative;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 2px; top: 50%; width: 9px; height: 9px; margin-top: -7px;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg);
  transition: transform 0.15s ease;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq summary:focus-visible { outline-offset: 2px; }
.faq details p { margin: 0 0 16px; color: var(--muted); }

.final {
  padding: 80px 0; text-align: center; border-top: 1px solid var(--border);
  background: radial-gradient(50% 80% at 50% 100%, rgba(47, 111, 235, 0.16), transparent 70%);
}
.final h2 { margin: 0 auto; }
.final p { color: var(--muted); }
.final .cta { justify-content: center; }

.footer { border-top: 1px solid var(--border); padding: 28px 0; font-size: 0.93rem; }
.footer-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 24px; }
.footer-brand { margin: 0; font-weight: 700; }
.footer-copy { margin-left: 10px; font-weight: 400; color: var(--muted); white-space: nowrap; }
.footer-links { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 20px; margin: 0; padding: 0; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--accent-text); text-decoration: underline; }

@media (max-width: 639px) {
  body { font-size: 16px; }
  .hero { padding-top: 44px; }
  .shot-hero { margin-top: 36px; }
  .section { padding: 64px 0; }
  .topbar-inner { gap: 8px; }
  .brand { min-width: 0; }
  .brand span { font-size: 0.92rem; overflow: hidden; text-overflow: ellipsis; }
  .gh-link { padding: 6px; }
}
