:root {
  color-scheme: light;
  --ink: #13202e;
  --muted: #566273;
  --line: #d8e0ea;
  --paper: #ffffff;
  --wash: #f5f7fa;
  --blue: #1f6feb;
  --teal: #0f766e;
  --amber: #b45309;
  --green: #15803d;
  --shadow: 0 18px 50px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  max-width: 100%;
  scroll-behavior: smooth;
}

body {
  max-width: 100%;
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.55;
}

a {
  color: var(--blue);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.page-shell {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 0;
  max-width: 1480px;
  margin: 0 auto;
}

.page-content {
  min-width: 0;
}

.side-nav {
  position: sticky;
  top: 96px;
  align-self: start;
  display: flex;
  flex-direction: column;
  gap: 6px;
  max-height: calc(100vh - 112px);
  padding: 24px 18px;
}

.side-nav a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 750;
}

.side-nav a:hover {
  color: var(--ink);
  background: var(--wash);
  text-decoration: none;
}

.side-nav a.active {
  color: #ffffff;
  background: var(--ink);
}

.page-note {
  margin: 22px 0;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-left: 5px solid var(--blue);
  border-radius: 8px;
  color: var(--muted);
  background: var(--wash);
  font-size: 16px;
}

.page-note strong {
  color: var(--ink);
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 72px;
  padding: 0 32px;
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
}

.brand,
nav {
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand,
nav,
.hero > *,
.section > *,
.status-band > *,
.download-card,
.os-panel,
.sub-panel,
.config-grid article,
.manager-notes article,
.steps article {
  min-width: 0;
}

.brand {
  color: var(--ink);
  font-weight: 800;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--ink);
  font-size: 14px;
}

nav a {
  color: var(--muted);
  font-size: 15px;
  font-weight: 650;
  white-space: nowrap;
}

.hero {
  display: grid;
  grid-template-columns: minmax(320px, 0.82fr) minmax(360px, 1fr);
  gap: 48px;
  align-items: center;
  max-width: 1240px;
  min-height: 620px;
  margin: 0 auto;
  padding: 72px 32px 42px;
}

.hero h1,
.section h2 {
  margin: 0;
  line-height: 1.05;
  letter-spacing: 0;
}

.hero h1 {
  max-width: 760px;
  font-size: clamp(42px, 6vw, 74px);
}

.section h2 {
  font-size: clamp(32px, 4vw, 52px);
}

.eyebrow,
.label {
  margin: 0 0 12px;
  color: var(--teal);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lede {
  max-width: 700px;
  color: var(--muted);
  font-size: 21px;
}

.hero-actions,
.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: #ffffff;
  font-weight: 750;
  max-width: 100%;
  text-align: center;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.button:hover {
  border-color: var(--blue);
  text-decoration: none;
}

.button.primary {
  border-color: var(--blue);
  color: #ffffff;
  background: var(--blue);
}

.relay-map {
  display: block;
  width: 100%;
  max-width: 100%;
  min-height: 300px;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
  background: var(--wash);
}

.status-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  max-width: 1180px;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: var(--line);
}

.status-band > div {
  padding: 22px 24px;
  background: #ffffff;
}

.label {
  display: block;
  margin-bottom: 8px;
  color: var(--amber);
}

.section {
  max-width: 1240px;
  margin: 0 auto;
  padding: 84px 32px;
}

.section-heading {
  max-width: 820px;
  margin-bottom: 28px;
}

.section-heading p:not(.eyebrow) {
  color: var(--muted);
  font-size: 18px;
}

.download-grid,
.os-docs,
.config-grid,
.manager-notes,
.wide-stack,
.steps {
  display: grid;
  gap: 18px;
}

.download-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.download-card,
.os-panel,
.config-grid article,
.manager-notes article,
.wide-stack article,
.steps article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #ffffff;
}

.download-card,
.config-grid article,
.manager-notes article,
.wide-stack article,
.steps article {
  padding: 24px;
}

.download-card {
  display: flex;
  flex-direction: column;
  min-height: 292px;
}

.download-card p {
  flex: 1;
  color: var(--muted);
}

.manager-card {
  border-top: 5px solid var(--blue);
}

.card-head h3,
.config-grid h3,
.manager-notes h3,
.steps h3 {
  margin: 10px 0;
  font-size: 22px;
  letter-spacing: 0;
}

.os-badge {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 8px;
  color: var(--teal);
  background: #e6f5f3;
  font-size: 13px;
  font-weight: 800;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr);
  gap: 36px;
  align-items: start;
}

.steps article {
  display: grid;
  grid-template-columns: 48px 1fr;
  column-gap: 16px;
}

.steps p,
.manager-notes p,
.config-grid p,
.wide-stack p,
.os-docs p {
  color: var(--muted);
}

.step-num {
  grid-row: span 2;
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  color: #ffffff;
  background: var(--green);
  font-weight: 800;
}

.os-docs {
  grid-template-columns: minmax(0, 1fr);
}

.os-panel {
  overflow: hidden;
}

.os-panel summary {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 64px;
  padding: 0 24px;
  cursor: pointer;
  font-size: 22px;
  font-weight: 800;
  list-style: none;
}

.os-icon {
  display: block;
  width: 38px;
  height: 38px;
  object-fit: contain;
  flex: 0 0 auto;
}

.os-panel summary::-webkit-details-marker {
  display: none;
}

.os-panel summary::after {
  content: "+";
  margin-left: auto;
  color: var(--blue);
  font-size: 28px;
  line-height: 1;
}

.os-panel[open] summary {
  border-bottom: 1px solid var(--line);
}

.os-panel[open] summary::after {
  content: "-";
}

.os-panel-body {
  padding: 22px 24px 24px;
}

.sub-panel {
  margin-top: 22px;
  background: var(--wash);
}

.sub-panel summary {
  display: flex;
  align-items: center;
  min-height: 54px;
  padding: 0 18px;
  cursor: pointer;
  font-size: 18px;
  font-weight: 800;
  list-style: none;
}

.sub-panel summary::-webkit-details-marker {
  display: none;
}

.sub-panel summary::after {
  content: "+";
  margin-left: auto;
  color: var(--blue);
  font-size: 24px;
  line-height: 1;
}

.sub-panel[open] summary {
  border-bottom: 1px solid var(--line);
}

.sub-panel[open] summary::after {
  content: "-";
}

.sub-panel-body {
  padding: 18px;
}

.config-grid,
.manager-notes {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.wide-stack {
  grid-template-columns: minmax(0, 1fr);
}

pre {
  overflow-x: auto;
  max-width: 100%;
  margin: 18px 0;
  padding: 16px;
  border-radius: 8px;
  color: #e5edf5;
  background: #172033;
  font-size: 12px;
  line-height: 1.45;
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  overflow-wrap: anywhere;
}

pre code {
  white-space: pre;
  overflow-wrap: normal;
}

article > a:not(.button) {
  font-weight: 750;
}

footer {
  display: flex;
  justify-content: center;
  gap: 20px;
  padding: 32px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  background: var(--wash);
}

@media (max-width: 980px) {
  .page-shell {
    display: block;
  }

  .side-nav {
    position: static;
    flex-direction: row;
    flex-wrap: wrap;
    max-height: none;
    padding: 16px 18px 0;
  }

  .hero,
  .split {
    grid-template-columns: 1fr;
  }

  .download-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .status-band,
  .config-grid,
  .manager-notes {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 720px) {
  .topbar {
    position: static;
    align-items: flex-start;
    flex-direction: column;
    padding: 18px;
  }

  nav {
    flex-wrap: wrap;
    gap: 12px;
    justify-content: flex-start;
  }

  .hero,
  .section {
    padding-left: 18px;
    padding-right: 18px;
  }

  .download-grid,
  .os-docs {
    grid-template-columns: minmax(0, 1fr);
  }

  .os-panel summary {
    padding: 0 16px;
    font-size: 19px;
  }

  .os-icon {
    width: 32px;
    height: 32px;
  }

  .os-panel-body {
    padding: 18px 16px;
  }

  .sub-panel-body {
    padding: 16px;
  }

  pre {
    margin-left: -4px;
    margin-right: -4px;
    padding: 14px;
    font-size: 11px;
  }

  footer {
    align-items: center;
    flex-direction: column;
  }
}
