:root {
  --bg: #0A1426;
  --bg-2: #0D1A31;
  --panel: #0F1E38;
  --panel-2: #12244A;
  --line: #1E3054;
  --line-2: #2A4170;
  --text: #E8EFF8;
  --muted: #A3B4CE;
  --faint: #7D90B0;
  --accent: #2EE6F6;
  --accent-ink: #04121F;
  --accent-soft: rgba(46, 230, 246, 0.1);
  --ok: #5EEAA8;
  --warn: #FFB86B;
  --bad: #FF7A8A;
  --sans: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --rail: 236px;
  --gutter: 16px;
  color-scheme: dark;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 72px; }

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

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

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

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

.skip {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 100;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 8px 14px;
  font-family: var(--mono);
  font-size: 14px;
  text-decoration: none;
}
.skip:focus { top: 12px; }

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

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

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 20, 38, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: 60px;
  padding: 0 var(--gutter);
  max-width: 1440px;
  margin: 0 auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-family: var(--mono);
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.brand svg { width: 28px; height: 28px; flex: none; }
.brand .slash { color: var(--faint); }
.brand .sub { color: var(--accent); }

.topnav { display: none; gap: 4px; margin-left: 8px; }
.topnav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  padding: 6px 10px;
  border-radius: 4px;
}
.topnav a:hover { color: var(--text); background: var(--panel); }

.top-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  padding: 12px 16px;
  border-radius: 4px;
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.btn svg { width: 16px; height: 16px; flex: none; }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: #7DF0FA; }
.btn-ghost { color: var(--text); border-color: var(--line-2); background: transparent; }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.btn-sm { padding: 9px 12px; font-size: 13px; }
.hide-sm { display: none; }

.layout {
  max-width: 1440px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}

.rail { display: none; }

.content { min-width: 0; border-left: 0; }

.sec {
  position: relative;
  border-bottom: 1px solid var(--line);
  padding: 56px var(--gutter);
}

.sec-head {
  display: grid;
  gap: 12px;
  margin-bottom: 32px;
  max-width: 760px;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--mono);
  font-size: 13px;
  color: var(--accent);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.tag .idx { color: var(--faint); }

h1, h2, h3 { margin: 0; font-weight: 600; letter-spacing: -0.015em; line-height: 1.15; }
h1 { font-size: clamp(34px, 6.2vw, 64px); letter-spacing: -0.03em; line-height: 1.04; }
h2 { font-size: clamp(26px, 3.4vw, 38px); letter-spacing: -0.02em; }
h3 { font-size: 18px; line-height: 1.3; }
p { margin: 0; }
.lede { color: var(--muted); font-size: 17px; max-width: 62ch; }

.hero {
  padding-top: 48px;
  padding-bottom: 0;
  overflow: hidden;
  background-image:
    linear-gradient(to right, rgba(42, 65, 112, 0.35) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(42, 65, 112, 0.35) 1px, transparent 1px);
  background-size: 48px 48px;
  background-position: -1px -1px;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10, 20, 38, 0.2) 0%, rgba(10, 20, 38, 0.85) 70%, var(--bg) 100%);
  pointer-events: none;
}
.hero > * { position: relative; z-index: 1; }

.hero-grid { display: grid; gap: 40px; grid-template-columns: minmax(0, 1fr); }

.hero-copy { display: grid; gap: 22px; align-content: start; }
.hero h1 .accent { color: var(--accent); }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }

.term {
  border: 1px solid var(--line-2);
  background: var(--bg-2);
  border-radius: 6px;
  overflow: hidden;
  font-family: var(--mono);
  font-size: 13px;
  min-width: 0;
  box-shadow: 0 0 0 1px rgba(10, 20, 38, 0.6), 0 24px 60px -30px rgba(0, 0, 0, 0.8);
}
.term-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  font-size: 12px;
}
.term-bar .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }
.term-bar .right { margin-left: auto; color: var(--faint); }

.log { list-style: none; margin: 0; padding: 10px 0; }
.log li {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: baseline;
  padding: 7px 14px;
  border-bottom: 1px dashed rgba(42, 65, 112, 0.5);
}
.log li:last-child { border-bottom: 0; }
.log .t { color: var(--faint); }
.log .ev { color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.log .ev span { color: var(--faint); }
.st {
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 2px 7px;
  border: 1px solid currentColor;
  border-radius: 3px;
  white-space: nowrap;
}
.st-q { color: var(--muted); }
.st-s { color: var(--accent); }
.st-d { color: var(--ok); }
.st-f { color: var(--bad); }
.st-h { color: var(--warn); }

.anim .log li { opacity: 0; transform: translateY(4px); animation: rise 0.5s ease forwards; }
.anim .log li:nth-child(1) { animation-delay: 0.2s; }
.anim .log li:nth-child(2) { animation-delay: 0.7s; }
.anim .log li:nth-child(3) { animation-delay: 1.3s; }
.anim .log li:nth-child(4) { animation-delay: 1.9s; }
.anim .log li:nth-child(5) { animation-delay: 2.4s; }
@keyframes rise { to { opacity: 1; transform: none; } }

.cursor { display: inline-block; width: 8px; height: 14px; background: var(--accent); vertical-align: -2px; animation: blink 1.1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.specs {
  margin: 48px calc(var(--gutter) * -1) 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  background: var(--bg);
}
.specs div {
  padding: 18px var(--gutter);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  min-width: 0;
}
.specs div:nth-child(2n) { border-right: 0; }
.specs div:last-child { border-bottom: 0; grid-column: 1 / -1; }
.specs dt { font-family: var(--mono); font-size: 12px; color: var(--faint); text-transform: uppercase; letter-spacing: 0.08em; }
.specs dd { margin: 6px 0 0; font-size: 15px; font-weight: 500; }

.split { display: grid; gap: 32px; grid-template-columns: minmax(0, 1fr); }

.points { list-style: none; padding: 0; margin: 0; display: grid; gap: 0; border-top: 1px solid var(--line); }
.points li { display: grid; grid-template-columns: 34px minmax(0, 1fr); gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.points .n { font-family: var(--mono); font-size: 13px; color: var(--accent); padding-top: 2px; }
.points strong { display: block; font-weight: 600; margin-bottom: 2px; }
.points span { color: var(--muted); }

.code {
  border: 1px solid var(--line-2);
  border-radius: 6px;
  background: #081122;
  overflow: hidden;
  min-width: 0;
}
.code-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 8px 8px 14px;
  border-bottom: 1px solid var(--line);
  background: var(--panel);
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
}
.code-head .method { color: var(--accent-ink); background: var(--accent); padding: 2px 6px; border-radius: 3px; font-weight: 500; }
.code-head .path { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.copy {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--line-2);
  border-radius: 4px;
  font-family: var(--mono);
  font-size: 12px;
  padding: 5px 9px;
  cursor: pointer;
  flex: none;
}
.copy:hover { color: var(--accent); border-color: var(--accent); }
.copy svg { width: 14px; height: 14px; }
pre {
  margin: 0;
  padding: 16px 14px;
  overflow-x: auto;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.7;
  color: var(--text);
  tab-size: 2;
}
@media (max-width: 559px) { pre { font-size: 12px; } }
.code + .code { margin-top: 12px; }
.k { color: var(--accent); }
.s { color: #9FE8C4; }
.v { color: var(--warn); }
.c { color: var(--faint); }
.p { color: var(--muted); }

.note { margin-top: 14px; font-size: 14px; color: var(--muted); }
.note code, p code, li code, dd code {
  font-family: var(--mono);
  font-size: 0.88em;
  color: var(--text);
  background: var(--panel);
  border: 1px solid var(--line);
  padding: 1px 5px;
  border-radius: 3px;
}

.flow {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  border: 1px solid var(--line);
  border-radius: 6px;
  overflow: hidden;
  margin-top: 28px;
}
.flow-step { padding: 16px; border-bottom: 1px solid var(--line); display: grid; gap: 6px; align-content: start; background: var(--bg-2); }
.flow-step:last-child { border-bottom: 0; }
.flow-step .st { justify-self: start; }
.flow-step p { color: var(--muted); font-size: 14px; }
.flow-end { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.flow-end > div { padding: 0 14px 0 0; display: grid; gap: 6px; align-content: start; justify-items: start; }
.flow-end > div + div { border-left: 1px solid var(--line); padding: 0 0 0 14px; }

.cards { display: grid; grid-template-columns: minmax(0, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.card { padding: 24px 20px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: grid; gap: 10px; align-content: start; }
.card svg { width: 28px; height: 28px; color: var(--accent); }
.card p { color: var(--muted); font-size: 15px; }

.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; border: 1px solid var(--line); border-radius: 6px; overflow: hidden; }
.steps li { display: grid; grid-template-columns: 56px minmax(0, 1fr); border-bottom: 1px solid var(--line); }
.steps li:last-child { border-bottom: 0; }
.steps .n { font-family: var(--mono); color: var(--accent); font-size: 13px; padding: 18px 0 0 16px; border-right: 1px solid var(--line); background: var(--bg-2); }
.steps .b { padding: 16px 18px; }
.steps .b p { color: var(--muted); font-size: 15px; margin-top: 4px; }

.price {
  border: 1px solid var(--accent);
  border-radius: 6px;
  padding: 24px 20px;
  background: linear-gradient(180deg, var(--accent-soft), transparent 80%);
  display: grid;
  gap: 14px;
  align-content: start;
}
.price .lbl { font-family: var(--mono); font-size: 12px; color: var(--accent); letter-spacing: 0.08em; text-transform: uppercase; }
.price .big { font-size: 26px; font-weight: 600; letter-spacing: -0.02em; line-height: 1.2; }
.price p { color: var(--muted); font-size: 15px; }
.price .btn { justify-self: start; }

.form-like {
  border: 1px solid var(--line-2);
  border-radius: 6px;
  background: #081122;
  font-family: var(--mono);
  font-size: 13px;
  overflow: hidden;
}
.form-like .row { display: grid; grid-template-columns: 1fr; gap: 4px; padding: 14px 16px; border-bottom: 1px dashed var(--line); }
.form-like .row:last-child { border-bottom: 0; }
.form-like .key { color: var(--faint); }
.form-like .val { color: var(--text); }
.form-like .val em { font-style: normal; color: var(--accent); }

.faq { border-top: 1px solid var(--line); max-width: 880px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  list-style: none;
  cursor: pointer;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 20px;
  gap: 16px;
  align-items: center;
  padding: 18px 0;
  font-weight: 500;
  font-size: 17px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { width: 18px; height: 18px; color: var(--accent); transition: transform 0.2s ease; }
.faq details[open] summary svg { transform: rotate(45deg); }
.faq .ans { padding: 0 36px 20px 0; color: var(--muted); }

.cta {
  display: grid;
  gap: 20px;
  padding: 56px var(--gutter);
  border-bottom: 1px solid var(--line);
  background-image:
    linear-gradient(to right, rgba(42, 65, 112, 0.3) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(42, 65, 112, 0.3) 1px, transparent 1px);
  background-size: 48px 48px;
}
.cta h2 { max-width: 20ch; }
.cta .row { display: flex; flex-wrap: wrap; gap: 10px; }

.foot {
  padding: 28px var(--gutter) 36px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px 28px;
  align-items: center;
  font-size: 14px;
  color: var(--muted);
}
.foot nav { display: flex; flex-wrap: wrap; gap: 8px 22px; }
.foot nav a { color: var(--muted); text-decoration: none; font-family: var(--mono); font-size: 13px; }
.foot nav a:hover { color: var(--accent); text-decoration: underline; }
.foot .copy-line { margin-right: auto; font-family: var(--mono); font-size: 13px; }

@media (min-width: 560px) {
  .hide-sm { display: inline-flex; }
  .specs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .specs div:nth-child(2n) { border-right: 1px solid var(--line); }
  .specs div:nth-child(3n) { border-right: 0; }
  .specs div:last-child { grid-column: auto; }
  .specs div:nth-child(n+4) { border-bottom: 0; }
  .specs div:nth-child(5) { border-right: 1px solid var(--line); }
  .specs div:last-child { border-right: 0; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .form-like .row { grid-template-columns: 170px minmax(0, 1fr); gap: 12px; }
}

@media (min-width: 760px) {
  :root { --gutter: 32px; }
  .topnav { display: flex; }
  .sec { padding-top: 80px; padding-bottom: 80px; }
  .hero { padding-top: 72px; padding-bottom: 0; }
  .flow { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .flow-step { border-bottom: 0; border-right: 1px solid var(--line); }
  .flow-step:last-child { border-right: 0; }
}

@media (min-width: 760px) and (max-width: 1039px) {
  .flow-end { grid-template-columns: 1fr; gap: 14px; }
  .flow-end > div { padding: 0; }
  .flow-end > div + div { border-left: 0; border-top: 1px solid var(--line); padding: 14px 0 0; }
}

@media (max-width: 399px) {
  .log li { grid-template-columns: 58px minmax(0, 1fr) auto; gap: 8px; padding: 7px 10px; }
  .log .ev .lg { display: none; }
}

@media (min-width: 1040px) {
  :root { --gutter: 48px; }
  .layout { grid-template-columns: var(--rail) minmax(0, 1fr); }
  .content { border-left: 1px solid var(--line); }
  .rail {
    display: block;
    position: sticky;
    top: 60px;
    align-self: start;
    height: calc(100vh - 60px);
    padding: 40px 20px 24px 24px;
  }
  .rail-label { font-family: var(--mono); font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--faint); margin: 0 0 14px; }
  .rail ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
  .rail a {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 6px;
    padding: 7px 10px 7px 10px;
    margin-left: -10px;
    border-left: 2px solid transparent;
    color: var(--muted);
    text-decoration: none;
    font-family: var(--mono);
    font-size: 13px;
  }
  .rail a .i { color: var(--faint); }
  .rail a:hover { color: var(--text); }
  .rail a[aria-current="true"] { color: var(--accent); border-left-color: var(--accent); background: var(--accent-soft); }
  .rail a[aria-current="true"] .i { color: var(--accent); }
  .rail-foot { position: absolute; left: 24px; right: 20px; bottom: 24px; font-family: var(--mono); font-size: 12px; color: var(--faint); border-top: 1px solid var(--line); padding-top: 14px; display: grid; gap: 4px; }
  .rail-foot b { color: var(--ok); font-weight: 500; }
  .hero-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: 48px; align-items: center; }
  .hero-copy { padding-bottom: 8px; }
  .specs { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .specs div, .specs div:nth-child(2n), .specs div:nth-child(3n), .specs div:nth-child(5) { border-right: 1px solid var(--line); border-bottom: 0; }
  .specs div:last-child { border-right: 0; }
  .split { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 56px; align-items: start; }
  .split.even { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .cards { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cta { grid-template-columns: minmax(0, 1fr) auto; align-items: end; padding-top: 88px; padding-bottom: 88px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .anim .log li { opacity: 1; transform: none; }
}

.auth {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
}
.auth-side {
  display: none;
  position: relative;
  border-right: 1px solid var(--line);
  background-image:
    linear-gradient(to right, rgba(42, 65, 112, 0.35) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(42, 65, 112, 0.35) 1px, transparent 1px);
  background-size: 48px 48px;
  background-position: -1px -1px;
  padding: 40px 48px;
}
.auth-side-inner { position: relative; height: 100%; display: grid; grid-template-rows: auto 1fr auto; gap: 32px; }
.auth-side .side-head { max-width: 16ch; align-self: end; margin: 0; font-weight: 600; line-height: 1.15; font-size: clamp(26px, 3.4vw, 38px); letter-spacing: -0.02em; color: var(--text); }
.auth-side .term { align-self: start; max-width: 520px; }
.auth-side .small { font-family: var(--mono); font-size: 12px; color: var(--faint); }

.auth-main { display: grid; grid-template-rows: auto 1fr auto; min-height: 100vh; }
.auth-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 16px var(--gutter); border-bottom: 1px solid var(--line); }
.auth-top .back { font-family: var(--mono); font-size: 13px; color: var(--muted); text-decoration: none; display: inline-flex; align-items: center; gap: 8px; padding: 6px 0; }
.auth-top .back:hover { color: var(--accent); }
.auth-top .back svg { width: 16px; height: 16px; }

.auth-body { display: grid; align-items: center; padding: 40px var(--gutter); }
.auth-card { width: 100%; max-width: 400px; margin: 0 auto; display: grid; gap: 28px; }
.auth-card header { display: grid; gap: 10px; }
.auth-card h1 { font-size: clamp(30px, 5vw, 40px); }
.auth-card header p { color: var(--muted); }

.field { display: grid; gap: 8px; }
.field-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
label { font-family: var(--mono); font-size: 13px; color: var(--text); }
.field-row a { font-size: 13px; font-family: var(--mono); }
input[type="email"], input[type="password"] {
  width: 100%;
  font: inherit;
  font-size: 16px;
  color: var(--text);
  background: #081122;
  border: 1px solid var(--line-2);
  border-radius: 4px;
  padding: 12px 14px;
  min-height: 48px;
}
input::placeholder { color: var(--faint); opacity: 1; }
input:hover { border-color: #3A5488; }
input:focus-visible { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }
.auth form { display: grid; gap: 18px; }
.auth form .btn { width: 100%; padding: 15px 16px; font-size: 15px; margin-top: 4px; }

.status {
  min-height: 0;
  font-size: 14px;
  color: var(--text);
}
.status:not(:empty) {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--line-2);
  border-left: 3px solid var(--accent);
  background: var(--panel);
  border-radius: 4px;
}
.status svg { width: 18px; height: 18px; color: var(--accent); margin-top: 2px; }
.auth-foot { padding: 20px var(--gutter); border-top: 1px solid var(--line); font-family: var(--mono); font-size: 12px; color: var(--faint); display: flex; flex-wrap: wrap; gap: 8px 20px; justify-content: space-between; }
.auth-foot a { color: var(--muted); }

@media (min-width: 1040px) {
  .auth { grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); }
  .auth-side { display: block; }
  .auth-main .auth-top .brand.only-sm { visibility: hidden; }
}
