:root {
  color-scheme: light;
  --ink: #17201b;
  --muted: #5d665f;
  --paper: #f7f8f4;
  --surface: #ffffff;
  --surface-alt: #eef6f1;
  --surface-blue: #f0f4fb;
  --line: #d8ddd4;
  --line-strong: #aeb9ae;
  --green: #2f7d5c;
  --green-dark: #1f5f45;
  --blue: #3457a6;
  --amber: #b36a18;
  --red: #b74736;
  --code-bg: #111713;
  --code-fg: #eef7ed;
  --shadow: 0 24px 70px rgba(23, 32, 27, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
  letter-spacing: 0;
}

a {
  color: inherit;
}

.text-link,
.heading-link {
  color: var(--green-dark);
  font-weight: 800;
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 0.16em;
}

.text-link:hover,
.text-link:focus-visible,
.heading-link:hover,
.heading-link:focus-visible {
  color: var(--blue);
  outline: none;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 64px;
  padding: 0 32px;
  border-bottom: 1px solid rgba(216, 221, 212, 0.9);
  background: rgba(247, 248, 244, 0.94);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
}

.brand-mark {
  width: 22px;
  height: 22px;
  border: 5px solid var(--green);
  border-right-color: var(--amber);
  border-bottom-color: var(--blue);
  border-radius: 50%;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-links a {
  padding: 8px 10px;
  border-radius: 6px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
}

.nav-links a:hover,
.nav-links a:focus-visible {
  background: var(--surface-alt);
  color: var(--ink);
  outline: none;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 0.86fr) minmax(420px, 1.14fr);
  gap: 48px;
  align-items: center;
  min-height: calc(100vh - 64px);
  padding: 58px 56px 42px;
}

.hero-copy,
.section-copy,
.site-footer {
  max-width: 980px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--green-dark);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

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

h1 {
  margin-bottom: 22px;
  font-size: 64px;
  line-height: 0.95;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 16px;
  font-size: 36px;
  line-height: 1.08;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: 0;
}

h4 {
  margin-bottom: 10px;
  font-size: 18px;
  line-height: 1.22;
  letter-spacing: 0;
}

.lede {
  max-width: 680px;
  color: #344039;
  font-size: 22px;
  line-height: 1.45;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin: 30px 0 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 18px;
  border: 1px solid var(--green);
  border-radius: 6px;
  font-size: 15px;
  font-weight: 750;
  text-decoration: none;
}

.button.primary {
  background: var(--green);
  color: white;
}

.button.secondary {
  background: transparent;
  color: var(--green-dark);
}

.button:hover,
.button:focus-visible {
  box-shadow: 0 0 0 4px rgba(47, 125, 92, 0.16);
  outline: none;
}

.summary-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.summary-strip div {
  min-width: 0;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.summary-strip dt {
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.summary-strip dd {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: 14px;
  font-weight: 750;
}

.runtime-panel {
  position: relative;
  overflow: hidden;
  min-height: 480px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

#runtime-map {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 480px;
}

.overview-band,
.why-band,
.examples-band,
.contract-band,
.implementation-band {
  padding: 70px 56px;
}

.overview-band {
  background: var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.examples-band {
  background: var(--surface-blue);
}

.why-band {
  background: #fbfaf4;
  border-bottom: 1px solid var(--line);
}

.contract-band {
  background: var(--paper);
  border-top: 1px solid var(--line);
}

.implementation-band {
  background: var(--surface);
  border-top: 1px solid var(--line);
}

.section-copy p {
  max-width: 800px;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.55;
}

.feature-grid,
.reason-grid,
.implementation-grid {
  display: grid;
  gap: 16px;
  margin-top: 34px;
}

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

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

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

.build-stack {
  display: grid;
  gap: 22px;
  margin-top: 34px;
}

.build-section {
  min-width: 0;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfaf4;
}

.build-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 2px;
}

.build-heading h3 {
  margin-bottom: 0;
  overflow-wrap: anywhere;
}

.feature-card,
.reason-card,
.implementation-card,
.example-surface,
.result-surface,
.reference-table {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
}

.feature-card {
  min-height: 210px;
  padding: 22px;
}

.reason-card,
.implementation-card {
  min-height: 230px;
  padding: 22px;
}

.feature-kicker,
.surface-label {
  display: inline-flex;
  width: fit-content;
  margin-bottom: 14px;
  padding: 4px 8px;
  border-radius: 999px;
  background: var(--surface-alt);
  color: var(--green-dark);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.feature-card p,
.reason-card p,
.implementation-card p,
.example-surface p,
.result-surface p {
  color: var(--muted);
  font-size: 15px;
  line-height: 1.55;
}

.feature-card code,
.reason-card code,
.implementation-card code,
.example-surface p code,
.result-surface p code,
.contract-band p code,
.site-footer code {
  padding: 1px 5px;
  border-radius: 4px;
  background: #edf1eb;
  color: #26342c;
  font-size: 0.92em;
}

.example-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 34px;
}

.example-surface,
.result-surface {
  padding: 24px;
}

.surface-heading {
  margin-bottom: 10px;
}

.code-shell {
  position: relative;
  min-width: 0;
  overflow: hidden;
  margin-top: 18px;
  border-radius: 8px;
  background: var(--code-bg);
  color: var(--code-fg);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.code-shell.compact {
  margin-top: 12px;
}

.code-shell pre {
  max-width: 100%;
  min-height: 0;
  max-height: 380px;
  margin: 0;
  overflow: auto;
  padding: 20px;
  font-size: 13px;
  line-height: 1.55;
  white-space: pre;
}

.copy-button {
  position: absolute;
  top: 10px;
  right: 10px;
  min-width: 58px;
  min-height: 30px;
  border: 1px solid rgba(238, 247, 237, 0.28);
  border-radius: 6px;
  background: rgba(238, 247, 237, 0.08);
  color: var(--code-fg);
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.copy-button:hover,
.copy-button:focus-visible {
  background: rgba(238, 247, 237, 0.16);
  outline: 2px solid rgba(238, 247, 237, 0.34);
  outline-offset: 2px;
}

.result-surface {
  margin-top: 18px;
}

.contract-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(0, 0.92fr);
  gap: 18px;
  margin-top: 34px;
}

.reference-table {
  overflow: hidden;
}

.reference-table h3 {
  margin: 0;
  padding: 20px 22px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

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

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

th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

td {
  color: #344039;
  line-height: 1.45;
}

td code {
  color: var(--blue);
  font-size: 13px;
  font-weight: 700;
}

.site-footer {
  padding: 34px 56px 44px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding: 42px 28px 30px;
  }

  .runtime-panel,
  #runtime-map {
    min-height: 390px;
  }

  .overview-band,
  .why-band,
  .examples-band,
  .contract-band,
  .implementation-band {
    padding: 56px 28px;
  }

  .feature-grid,
  .reason-grid,
  .implementation-grid,
  .example-grid,
  .contract-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
    padding: 12px 18px;
  }

  .nav-links {
    width: 100%;
    justify-content: space-between;
  }

  .nav-links a {
    padding: 7px 6px;
    font-size: 13px;
  }

  .hero {
    padding: 34px 18px 26px;
  }

  h1 {
    font-size: 42px;
  }

  h2 {
    font-size: 28px;
  }

  .lede {
    font-size: 18px;
  }

  .summary-strip {
    grid-template-columns: 1fr;
  }

  .runtime-panel,
  #runtime-map {
    min-height: 330px;
  }

  .overview-band,
  .why-band,
  .examples-band,
  .contract-band,
  .implementation-band,
  .site-footer {
    padding-right: 18px;
    padding-left: 18px;
  }

  .feature-card,
  .reason-card,
  .implementation-card,
  .build-section,
  .example-surface,
  .result-surface {
    padding: 18px;
  }

  .build-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 0;
  }

  .code-shell pre {
    padding: 48px 14px 16px;
    font-size: 12px;
  }

  th,
  td {
    display: block;
    width: 100%;
    padding: 12px 16px;
  }

  th {
    border-bottom: 0;
  }

  tr {
    display: block;
    border-bottom: 1px solid var(--line);
  }

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

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