:root {
  color-scheme: light;
  --bg: #f7f8fb;
  --panel: #ffffff;
  --panel-soft: #eef4f8;
  --text: #17212f;
  --muted: #5f6b7a;
  --line: #dbe3ea;
  --accent: #0f766e;
  --accent-strong: #115e59;
  --accent-soft: #dff7f3;
  --code: #101827;
  --shadow: 0 18px 45px rgba(23, 33, 47, 0.09);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  line-height: 1.65;
}

a {
  color: inherit;
}

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

pre {
  overflow: auto;
  margin: 1rem 0 0;
  padding: 1rem;
  border-radius: 8px;
  background: var(--code);
  color: #eef6ff;
  font-size: 0.92rem;
  line-height: 1.55;
}

code {
  font-size: 0.92em;
}

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

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 20;
  border-radius: 6px;
  background: var(--text);
  color: #fff;
  padding: 0.7rem 1rem;
}

.skip-link:focus {
  top: 1rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 1px solid rgba(219, 227, 234, 0.9);
  background: rgba(247, 248, 251, 0.92);
  backdrop-filter: blur(16px);
}

.header-inner,
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.header-inner {
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
}

.brand small {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem;
}

.nav a {
  border-radius: 6px;
  color: var(--muted);
  padding: 0.45rem 0.65rem;
  text-decoration: none;
  font-size: 0.92rem;
}

.nav a:hover {
  background: var(--accent-soft);
  color: var(--accent-strong);
}

.hero {
  padding: 88px 0 72px;
}

.hero-grid,
.two-column {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 2rem;
  align-items: center;
}

.eyebrow,
.section-kicker {
  margin: 0 0 0.75rem;
  color: var(--accent-strong);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 800px;
  margin-bottom: 1rem;
  font-size: clamp(2.35rem, 5vw, 4.8rem);
  line-height: 1.04;
}

h2 {
  margin-bottom: 1rem;
  font-size: clamp(1.85rem, 3vw, 3rem);
  line-height: 1.12;
}

h3 {
  margin-bottom: 0.5rem;
  font-size: 1.05rem;
}

.lead {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.18rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.75rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  padding: 0.62rem 1rem;
  text-decoration: none;
  font-weight: 700;
}

.button.primary {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}

.system-map,
.panel,
.card-list article,
.feature-grid article,
.api-grid article,
.step {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.system-map {
  padding: 1.25rem;
}

.map-node,
.map-grid div {
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  padding: 0.85rem;
  text-align: center;
  font-weight: 800;
}

.map-node.active {
  background: var(--accent);
  color: #fff;
}

.map-line {
  width: 2px;
  height: 24px;
  margin: 0.5rem auto;
  background: var(--line);
}

.map-row,
.map-grid {
  display: grid;
  gap: 0.7rem;
}

.map-row {
  grid-template-columns: repeat(3, 1fr);
}

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

.section {
  padding: 72px 0;
}

.muted {
  background: var(--panel-soft);
}

.card-list,
.feature-grid,
.api-grid {
  display: grid;
  gap: 1rem;
}

.card-list article,
.feature-grid article,
.api-grid article,
.panel {
  padding: 1.25rem;
}

.feature-grid,
.api-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feature-grid p,
.api-grid p,
.card-list p,
.panel p,
.step p {
  color: var(--muted);
}

.steps {
  display: grid;
  gap: 1rem;
}

.step {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 1rem;
  padding: 1.25rem;
}

.step > span {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent-strong);
  font-weight: 900;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

th,
td {
  border-bottom: 1px solid var(--line);
  padding: 0.9rem 1rem;
  text-align: left;
  vertical-align: top;
}

th {
  background: #f9fbfd;
  color: var(--muted);
  font-size: 0.82rem;
  text-transform: uppercase;
}

tr:last-child td {
  border-bottom: 0;
}

.api-grid ul,
.check-list,
.panel ol {
  margin: 0;
  padding-left: 1.25rem;
}

.api-grid li,
.check-list li,
.panel li {
  margin: 0.45rem 0;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 1.5rem 0;
  color: var(--muted);
}

.site-footer a {
  color: var(--accent-strong);
  font-weight: 700;
  text-decoration: none;
}

@media (max-width: 880px) {
  .header-inner,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav {
    justify-content: flex-start;
  }

  .hero-grid,
  .two-column,
  .feature-grid,
  .api-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 56px;
  }
}

@media (max-width: 560px) {
  .map-row,
  .map-grid {
    grid-template-columns: 1fr;
  }

  .step {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 2.25rem;
  }
}