:root {
  color-scheme: light;
  --sand: #f7efdf;
  --sand-deep: #ead9bd;
  --paper: #fffaf0;
  --ink: #12304a;
  --ink-soft: #46657d;
  --coral: #e8734a;
  --coral-dark: #b84f30;
  --line: #d9c7a9;
}

* {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  min-width: 0;
  background: var(--sand);
  color: var(--ink);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

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

a {
  color: var(--coral-dark);
  text-underline-offset: 0.2em;
}

a:hover,
a:focus-visible {
  color: var(--coral);
}

:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
}

.wrap {
  width: min(100% - 40px, 1080px);
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 5;
  background: rgba(255, 250, 240, 0.94);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 24px;
  min-height: 76px;
  padding: 12px 0;
}

.brand img {
  display: block;
  width: 172px;
  height: auto;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-block;
  padding: 6px 0;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 650;
  text-decoration: none;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover,
.site-nav a:focus-visible {
  color: var(--coral-dark);
  border-bottom-color: var(--coral);
}

.site-nav a[aria-current="page"] {
  color: var(--coral-dark);
  border-bottom-color: var(--coral);
}

main {
  display: block;
}

.hero {
  padding: 64px 0 48px;
}

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

h1,
h2,
h3 {
  margin: 0 0 14px;
  line-height: 1.18;
  letter-spacing: -0.02em;
}

h1 {
  max-width: 13ch;
  font-size: clamp(2.25rem, 5vw, 3.8rem);
}

h2 {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
}

h3 {
  font-size: 1.15rem;
}

p {
  margin: 0 0 16px;
}

.lede {
  max-width: 58ch;
  color: var(--ink-soft);
  font-size: 1.1rem;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--coral-dark);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.section {
  padding: 44px 0;
  border-top: 1px solid var(--line);
}

.section-tight {
  padding: 30px 0 44px;
}

.section-head {
  max-width: 68ch;
  margin-bottom: 26px;
}

.link-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 22px;
  margin-top: 24px;
}

.pill-link {
  display: inline-block;
  padding: 10px 18px;
  border: 2px solid var(--coral);
  border-radius: 999px;
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  background: var(--paper);
}

.pill-link:hover,
.pill-link:focus-visible {
  color: var(--paper);
  background: var(--coral-dark);
  border-color: var(--coral-dark);
}

.quiet-link {
  align-self: center;
  font-weight: 700;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

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

.card {
  min-width: 0;
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
  box-shadow: 0 10px 24px rgba(18, 48, 74, 0.06);
}

.card p:last-child,
.card ul:last-child {
  margin-bottom: 0;
}

.card .mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin-bottom: 14px;
  border-radius: 12px;
  background: var(--sand-deep);
  color: var(--coral-dark);
  font-weight: 900;
}

.list-check {
  margin: 0;
  padding-left: 1.2em;
}

.list-check li {
  margin-bottom: 8px;
}

.panel {
  min-width: 0;
  padding: 24px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: 0 12px 30px rgba(18, 48, 74, 0.07);
}

.panel-accent {
  border-top: 5px solid var(--coral);
}

.survey-card {
  transform: rotate(0.6deg);
}

.card-caption {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--ink-soft);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.table-scope {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}

.table-scope caption {
  margin-bottom: 12px;
  color: var(--ink-soft);
  font-size: 0.88rem;
  text-align: left;
}

.table-scope th,
.table-scope td {
  padding: 12px 10px;
  text-align: left;
  vertical-align: middle;
  border-bottom: 1px solid var(--line);
}

.table-scope th {
  color: var(--ink-soft);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

.table-scope td[data-label]::before {
  display: none;
}

.coverage-cell {
  display: flex;
  align-items: center;
  gap: 9px;
  white-space: nowrap;
}

.bar {
  display: block;
  flex: 0 1 86px;
  height: 8px;
  min-width: 42px;
  background: var(--sand-deep);
  border-radius: 999px;
  overflow: hidden;
}

.fill {
  display: block;
  height: 100%;
  background: var(--coral);
  border-radius: inherit;
}

.w72 { width: 72%; }
.w48 { width: 48%; }
.w65 { width: 65%; }
.w31 { width: 31%; }
.w80 { width: 80%; }
.w57 { width: 57%; }

.steps {
  margin: 0;
  padding-left: 1.4em;
}

.steps li {
  margin-bottom: 18px;
  padding-left: 6px;
}

.steps li::marker {
  color: var(--coral-dark);
  font-weight: 800;
}

.note {
  padding: 18px 20px;
  background: var(--sand-deep);
  border-left: 4px solid var(--coral);
  border-radius: 0 14px 14px 0;
}

.note p:last-child {
  margin-bottom: 0;
}

.doc-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.32fr) minmax(0, 0.68fr);
  gap: 34px;
  align-items: start;
}

.toc {
  padding: 20px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
}

.toc p {
  margin-bottom: 8px;
  color: var(--ink-soft);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.toc ul {
  margin: 0;
  padding-left: 1.1em;
}

.toc li {
  margin-bottom: 7px;
}

.doc-body {
  min-width: 0;
}

.doc-body h2 {
  margin-top: 8px;
}

.doc-body h3 {
  margin-top: 28px;
}

code {
  padding: 2px 6px;
  background: var(--sand-deep);
  border-radius: 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9em;
}

.example-block {
  margin: 18px 0;
  padding: 18px;
  background: var(--paper);
  border: 1px dashed var(--coral);
  border-radius: 16px;
}

.example-block p:last-child {
  margin-bottom: 0;
}

.site-footer {
  margin-top: 26px;
  padding: 30px 0 38px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 0.9rem;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px 26px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
}

.not-found {
  padding: 86px 0;
  text-align: center;
}

.not-found .code {
  color: var(--coral);
  font-size: clamp(4rem, 14vw, 7rem);
  font-weight: 900;
  line-height: 1;
}

@media (max-width: 820px) {
  .hero-grid,
  .doc-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .hero {
    padding-top: 46px;
  }

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

  .survey-card {
    transform: none;
  }
}

@media (max-width: 620px) {
  .wrap {
    width: min(100% - 28px, 1080px);
  }

  .header-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .brand img {
    width: 150px;
  }

  .site-nav ul {
    gap: 4px 14px;
  }

  .site-nav a {
    font-size: 0.9rem;
  }

  .hero {
    padding: 34px 0 32px;
  }

  .section {
    padding: 34px 0;
  }

  .panel,
  .card,
  .toc,
  .example-block {
    padding: 18px;
  }

  .table-scope,
  .table-scope tbody,
  .table-scope tr,
  .table-scope td {
    display: block;
    width: 100%;
  }

  .table-scope thead {
    display: none;
  }

  .table-scope tr {
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
  }

  .table-scope tr:last-child {
    border-bottom: 0;
  }

  .table-scope td,
  .table-scope tbody tr:last-child td {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    padding: 6px 0;
    border-bottom: 0;
    text-align: right;
  }

  .table-scope td[data-label]::before {
    display: block;
    flex: 0 0 auto;
    color: var(--ink-soft);
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-align: left;
    text-transform: uppercase;
    content: attr(data-label);
  }

  .coverage-cell {
    justify-content: flex-end;
  }

  .bar {
    width: 74px;
  }
}
