:root {
  color-scheme: dark;
  --bg: #050a1b;
  --surface: rgba(13, 28, 62, 0.92);
  --surface-soft: rgba(18, 38, 78, 0.72);
  --line: rgba(137, 164, 220, 0.18);
  --text: #f4f7ff;
  --muted: #aebddb;
  --blue: #4e8cff;
  --cyan: #42d6ec;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(circle at 88% 0, rgba(52, 111, 241, 0.23), transparent 34rem),
    radial-gradient(circle at 8% 38%, rgba(34, 211, 238, 0.09), transparent 27rem),
    var(--bg);
  color: var(--text);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
}

a { color: #89ddff; }

.shell {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0 64px;
}

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 900;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  box-shadow: 0 10px 26px rgba(57, 131, 246, 0.27);
  color: #06142d;
}

.top nav {
  display: flex;
  align-items: center;
  gap: 18px;
  flex-wrap: wrap;
}

.top nav a {
  color: #a9bbdc;
  font-size: 13px;
  text-decoration: none;
}

.breadcrumbs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 42px 0 0;
  color: #7188af;
  font-size: 12px;
}

.breadcrumbs a { color: #91a9cf; text-decoration: none; }

.hero { max-width: 900px; padding: 38px 0 42px; }

.eyebrow {
  color: #67dcef;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.hero h1 {
  margin: 13px 0 17px;
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.03;
  letter-spacing: -0.05em;
}

.hero p {
  max-width: 790px;
  margin: 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.68;
}

.hero-actions, .cta-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.button {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.035);
  color: #dce8ff;
  font-weight: 800;
  text-decoration: none;
}

.button.primary {
  border: 0;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: #06142d;
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 22px;
  align-items: start;
}

.article, .toc, .faq, .related, .cta {
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(14, 27, 61, 0.94), rgba(7, 16, 38, 0.97));
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.18);
}

.article { padding: 30px; border-radius: 23px; }

.step { padding: 27px 0; border-bottom: 1px solid rgba(137, 164, 220, 0.12); }
.step:first-child { padding-top: 0; }
.step:last-child { padding-bottom: 0; border: 0; }

.step h2, .errors h2, .related h2, .faq h2, .cta h2 {
  margin: 0 0 13px;
  letter-spacing: -0.025em;
}

.step h2 { font-size: 23px; }

.number {
  display: inline-grid;
  width: 31px;
  height: 31px;
  margin-right: 9px;
  place-items: center;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: #05132b;
  font-size: 13px;
  vertical-align: 3px;
}

.step p, .step li, .errors p, .errors li, .faq p, .related p, .toc p, .cta p {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.72;
}

.step ul, .step ol, .errors ul { margin: 12px 0 0; padding-left: 22px; }
.step li + li, .errors li + li { margin-top: 7px; }

.code {
  margin: 14px 0;
  padding: 14px 16px;
  overflow-wrap: anywhere;
  border: 1px solid rgba(73, 194, 226, 0.2);
  border-radius: 13px;
  background: #040b1d;
  color: #7de1f3;
  font: 700 14px/1.55 ui-monospace, SFMono-Regular, Consolas, monospace;
}

.note {
  margin-top: 14px;
  padding: 15px 17px;
  border-radius: 13px;
  background: rgba(45, 116, 235, 0.11);
  color: #cadbfd;
  font-size: 14px;
  line-height: 1.6;
}

.note.warning { background: rgba(245, 158, 11, 0.1); color: #f5d9a1; }

.toc {
  position: sticky;
  top: 18px;
  padding: 22px;
  border-radius: 19px;
}

.toc h2 { margin: 0 0 13px; font-size: 17px; }
.toc > a { display: block; padding: 8px 0; color: #b4cdff; font-size: 13px; text-decoration: none; }
.toc .button { margin-top: 13px; }

.errors, .faq, .related, .cta {
  margin-top: 22px;
  padding: 30px;
  border-radius: 23px;
}

.errors { border: 1px solid rgba(245, 158, 11, 0.18); background: rgba(67, 42, 15, 0.28); }

.faq article + article, .related-grid a + a {
  margin-top: 19px;
  padding-top: 19px;
  border-top: 1px solid rgba(137, 164, 220, 0.12);
}

.faq h3 { margin: 0 0 7px; font-size: 16px; }
.faq p { margin: 0; }

.related-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.related-grid a {
  display: block;
  padding: 16px;
  border: 1px solid rgba(137, 164, 220, 0.14);
  border-radius: 14px;
  color: #d5e3ff;
  font-weight: 800;
  line-height: 1.45;
  text-decoration: none;
}
.related-grid a + a { margin: 0; }

.cta { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.cta p { max-width: 690px; margin: 0; }
.cta-actions { flex: 0 0 auto; margin: 0; }

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  margin-top: 32px;
  padding-top: 23px;
  border-top: 1px solid rgba(137, 164, 220, 0.12);
  color: #758caf;
  font-size: 12px;
}

.footer a { color: #9eb5df; text-decoration: none; }

@media (max-width: 900px) {
  .layout { grid-template-columns: 1fr; }
  .toc { position: static; }
  .cta { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 620px) {
  .shell { width: min(100% - 24px, 1120px); padding-top: 18px; }
  .top { align-items: center; }
  .top nav { justify-content: flex-end; gap: 12px; }
  .top nav a:nth-child(1),
  .top nav a:nth-child(3),
  .top nav a:nth-child(4) { display: none; }
  .top nav a { font-size: 12px; }
  .hero { padding: 32px 0; }
  .hero h1 { font-size: 38px; }
  .hero p { font-size: 16px; }
  .article, .errors, .faq, .related, .cta { padding: 21px; }
  .step h2 { font-size: 20px; }
  .related-grid { grid-template-columns: 1fr; }
}
