/* ==========================================================================
   Data Cookings
   A specification sheet: hairline rules, a numbered left rail, mono for
   figures, serif for prose, sans for display. Dark by default, light on
   request. One stylesheet, no build step.
   ========================================================================== */

/* ---------- fonts -------------------------------------------------------- */
@font-face { font-family: "Display Sans"; src: url("fonts/cantarell-regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Display Sans"; src: url("fonts/cantarell-bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: "Document Serif"; src: url("fonts/libserif-regular.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Document Serif"; src: url("fonts/libserif-bold.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: swap; }

/* ---------- tokens ------------------------------------------------------- */
:root {
  color-scheme: dark;

  --font-display: "Display Sans", "Cantarell", "Trebuchet MS", system-ui, sans-serif;
  --font-body: "Document Serif", "Liberation Serif", Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, SFMono-Regular, "DejaVu Sans Mono", Menlo, Consolas, monospace;
  /* the one mark the subset faces do not carry */
  --font-symbol: "Noto Sans Thai", "Leelawadee UI", "Thonburi", "Tahoma", system-ui, sans-serif;

  --text-mega:    clamp(2.5rem, 1.75rem + 3.2vw, 3.75rem);
  --text-display: clamp(1.625rem, 1.4rem + 1vw, 2rem);
  --text-band:    clamp(1.75rem, 1.5rem + 1.2vw, 2.25rem);
  --text-title:   clamp(1.25rem, 1.15rem + 0.45vw, 1.5rem);
  --text-lead:    clamp(1.1875rem, 1.1rem + 0.4vw, 1.375rem);
  --text-body:    1.125rem;
  --text-small:   1rem;
  --text-label:   0.875rem;
  --text-micro:   0.8125rem;

  --leading-mega: 1.04;
  --leading-display: 1.14;
  --leading-title: 1.25;
  --leading-lead: 1.5;
  --leading-body: 1.65;

  --tracking-mega: -0.035em;
  --tracking-display: -0.025em;
  --tracking-title: -0.015em;

  --wrap: 77.5rem;
  --pad: clamp(1.25rem, 4vw, 3rem);
  --gutter: clamp(1rem, 2vw, 2rem);
  --space-section: clamp(3.5rem, 6.5vw, 6rem);
  --space-xs: 0.75rem;
  --space-s: 1rem;
  --space-m: 1.5rem;
  --space-l: 2rem;
  --space-xl: 3rem;
  /* the running head scrolls out of view; the bar below it stays */
  --running-head-h: 2.3125rem;

  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;

  --surface-page:   #0a0a11;
  --surface-raised: #101019;
  --surface-card:   #161622;
  --surface-inset:  #0c0c14;
  --surface-icon:   #2a1d4b;
  --surface-hover:  #292144;

  --border:        #26263a;
  --border-strong: #3a3a56;
  --rule:          #1e1e30;

  --text-primary:   #f2f0fb;
  --text-secondary: #c3c1de;
  --text-muted:     #9c9abd;

  --accent:       #7c3aed;
  --accent-text:  #b6a2fb;
  --accent-text-hover: #d2c6ff;
  --accent-soft:  rgba(139, 92, 246, 0.16);
  --accent-line:  rgba(139, 92, 246, 0.42);
  --accent-ink:   #ffffff;

  --grad-accent-a: #6d3fe0;
  --grad-accent-b: #2f6fe0;
  --grad-text-a:   #b9a6ff;
  --grad-text-b:   #7db0ff;
  --gradient-accent: linear-gradient(100deg, var(--grad-accent-a) 0%, var(--grad-accent-b) 100%);
  --gradient-text:   linear-gradient(100deg, var(--grad-text-a) 0%, var(--grad-text-b) 100%);

  --blob-1: rgba(124, 92, 255, 0.22);
  --blob-2: rgba(79, 140, 255, 0.14);

  --shadow-md: 0 1px 2px rgba(3, 3, 10, 0.45), 0 14px 30px -14px rgba(3, 3, 10, 0.85);
  --shadow-art: 0 24px 48px -28px rgba(3, 3, 10, 0.9);
}

html[data-theme="light"] {
  color-scheme: light;

  --surface-page:   #f7f5ff;
  --surface-raised: #ffffff;
  --surface-card:   #ffffff;
  --surface-inset:  #eeebfc;
  --surface-icon:   #ded8f7;
  --surface-hover:  #f0edfd;

  --border:        #dad4f0;
  --border-strong: #b4abd6;
  --rule:          #e4e0f4;

  --text-primary:   #17132a;
  --text-secondary: #3f3a56;
  --text-muted:     #5d5775;

  --accent:       #5b3ad9;
  --accent-text:  #5334c7;
  --accent-text-hover: #3b219b;
  --accent-soft:  rgba(106, 73, 240, 0.10);
  --accent-line:  rgba(106, 73, 240, 0.30);
  --accent-ink:   #ffffff;

  --grad-text-a: #5b3ad9;
  --grad-text-b: #2560d0;

  --blob-1: rgba(124, 92, 255, 0.16);
  --blob-2: rgba(79, 140, 255, 0.12);

  --shadow-md: 0 1px 2px rgba(20, 20, 43, 0.05), 0 14px 30px -16px rgba(20, 20, 43, 0.22);
  --shadow-art: 0 22px 48px -26px rgba(20, 20, 43, 0.3);
}

/* ---------- base --------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 6rem;
}

body {
  margin: 0;
  overflow-x: clip;
  background: var(--surface-page);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: var(--leading-body);
  -webkit-font-smoothing: antialiased;
  font-synthesis: none;
}

img, svg { display: block; max-width: 100%; height: auto; }
svg { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
figure { margin: 0; }
h1, h2, h3, h4 { margin: 0; font-family: var(--font-display); font-weight: 700; color: var(--text-primary); overflow-wrap: break-word; }
p, ul, ol, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }
a { color: var(--accent-text); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-text-hover); }
strong { font-weight: 700; }
::selection { background: var(--accent-soft); color: var(--text-primary); }
:focus-visible { outline: 2px solid var(--accent-text); outline-offset: 3px; border-radius: 3px; }
.baht { font-family: var(--font-symbol); }

.skip {
  position: absolute;
  left: var(--pad);
  top: 0.75rem;
  z-index: 100;
  padding: 0.625rem 1rem;
  background: var(--surface-card);
  border: 1px solid var(--accent-line);
  border-radius: var(--radius-sm);
  font-family: var(--font-display);
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-200%);
  transition: transform 0.15s;
}
.skip:focus { transform: none; }

.wrap { width: min(100% - 2 * var(--pad), var(--wrap)); margin-inline: auto; }

/* ---------- running head ------------------------------------------------- */
.running-head { background: var(--surface-inset); border-bottom: 1px solid var(--rule); white-space: nowrap; overflow: hidden; }
.running-head__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 2.25rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.running-head__doc { color: var(--text-secondary); }
.running-head__section { display: inline-flex; align-items: center; gap: 1rem; margin-right: auto; }
.running-head__section::before { content: ""; width: 1rem; height: 1px; background: var(--border-strong); }

/* ---------- header ------------------------------------------------------- */
.site-header {
  position: sticky;
  top: calc(-1 * var(--running-head-h));
  z-index: 40;
  background: color-mix(in srgb, var(--surface-page) 88%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--rule);
}
.site-header__inner { display: flex; align-items: center; gap: 1.5rem; min-height: 4.25rem; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.125rem;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  text-decoration: none;
  white-space: nowrap;
}
.brand:hover { color: var(--text-primary); }
.brand img { width: 2.25rem; height: 2.25rem; }

.nav { display: flex; align-items: center; gap: clamp(0.75rem, 1.5vw, 1.5rem); }
.nav a:not(.nav__cta) {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  font-family: var(--font-display);
  font-size: 0.9375rem;
  color: var(--text-secondary);
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s;
}
.nav a:not(.nav__cta):hover { color: var(--text-primary); }
.nav a[aria-current="page"] { color: var(--text-primary); }
.nav a[aria-current="page"]::after {
  content: "";
  position: absolute;
  inset-inline: 0;
  bottom: 0.375rem;
  height: 2px;
  border-radius: 2px;
  background: var(--gradient-accent);
}
.nav a.nav__cta { display: none; }

.header__actions { display: flex; align-items: center; gap: 0.625rem; margin-left: auto; }

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 2.5rem;
  padding: 0 0.875rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: color 0.15s, border-color 0.15s;
}
.theme-toggle:hover { color: var(--text-primary); border-color: var(--border-strong); }
.theme-toggle svg { width: 1rem; height: 1rem; }
.theme-toggle__moon { display: none; }
html[data-theme="light"] .theme-toggle__sun { display: none; }
html[data-theme="light"] .theme-toggle__moon { display: block; }

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--text-primary);
  cursor: pointer;
}
.menu-toggle svg { width: 1.25rem; height: 1.25rem; }
.menu-toggle__close { display: none; }
.menu-toggle[aria-expanded="true"] .menu-toggle__open { display: none; }
.menu-toggle[aria-expanded="true"] .menu-toggle__close { display: block; }

/* ---------- buttons ------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 3rem;
  padding: 0 1.5rem;
  border: 1px solid transparent;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, background-color 0.15s, border-color 0.15s, color 0.15s;
}
.btn--primary {
  background: var(--gradient-accent);
  color: var(--accent-ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 10px 24px -12px rgba(109, 63, 224, 0.9);
}
.btn--primary:hover {
  color: var(--accent-ink);
  transform: translateY(-1px);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 14px 28px -12px rgba(109, 63, 224, 1);
}
.btn--ghost { background: transparent; border-color: var(--border-strong); color: var(--text-primary); }
.btn--ghost:hover { background: var(--accent-soft); border-color: var(--accent-line); color: var(--text-primary); }
.btn--sm { min-height: 2.5rem; padding: 0 1.125rem; font-size: 0.9375rem; }

.cta-row { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: var(--space-l); }
.cta-facts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin-top: var(--space-m);
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  color: var(--text-muted);
}
.cta-facts li { display: inline-flex; align-items: center; gap: 0.5rem; }
.cta-facts li::before { content: ""; width: 3px; height: 3px; border-radius: 50%; background: var(--accent-text); }

.hero-notes { display: grid; gap: 0.5rem; margin-top: var(--space-m); font-size: var(--text-small); color: var(--text-muted); }
.hero-notes li { position: relative; padding-left: 1.25rem; }
.hero-notes li::before { content: ""; position: absolute; left: 0; top: 0.7em; width: 0.5rem; height: 1px; background: var(--accent-text); }

/* ---------- masthead ----------------------------------------------------- */
.masthead {
  position: relative;
  overflow: clip;
  padding-block: clamp(3rem, 6vw, 5.5rem);
  border-bottom: 1px solid var(--rule);
}
.masthead::before {
  content: "";
  position: absolute;
  inset: -40% -15% auto -15%;
  height: 160%;
  background:
    radial-gradient(44rem 28rem at 78% 34%, var(--blob-1), transparent 62%),
    radial-gradient(32rem 22rem at 4% 8%, var(--blob-2), transparent 60%);
  pointer-events: none;
}
.masthead__inner {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gutter);
  align-items: center;
}
.masthead__copy { grid-column: 1 / span 7; }
.masthead__figure { grid-column: 8 / -1; }
.masthead--plain .masthead__copy { grid-column: 1 / span 9; }
.masthead--legal { padding-block: clamp(2.5rem, 4vw, 3.5rem); }
.masthead h1 {
  font-size: var(--text-mega);
  line-height: var(--leading-mega);
  letter-spacing: var(--tracking-mega);
  text-wrap: balance;
}
.masthead--legal h1 { font-size: var(--text-band); line-height: var(--leading-display); letter-spacing: var(--tracking-display); }
.lead {
  margin-top: var(--space-m);
  max-width: 46ch;
  font-size: var(--text-lead);
  line-height: var(--leading-lead);
  color: var(--text-secondary);
}
.grad { background: var(--gradient-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
@supports not ((-webkit-background-clip: text) or (background-clip: text)) { .grad { background: none; color: var(--accent-text); } }

/* ---------- figure panels ------------------------------------------------ */
.sheet {
  background: var(--surface-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem 1.5rem;
  box-shadow: var(--shadow-art);
}
.sheet__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding-bottom: 0.875rem;
  border-bottom: 1px solid var(--rule);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.sheet__head strong { font-weight: 400; color: var(--text-secondary); }
.sheet__rows li {
  position: relative;
  display: grid;
  grid-template-columns: 2.5rem minmax(0, 1fr);
  gap: 1rem;
  align-items: center;
  padding: 1rem 0;
  border-bottom: 1px solid var(--rule);
}
.sheet__rows li:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 1.25rem;
  top: 3.5rem;
  bottom: -1rem;
  width: 1px;
  background: var(--accent-line);
}
.sheet__icon {
  position: relative;
  z-index: 1;
  width: 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
  border-radius: 0.625rem;
  border: 1px solid var(--accent-line);
  background: var(--surface-icon);
  color: var(--accent-text);
}
.sheet__icon svg { width: 1.25rem; height: 1.25rem; }
.sheet__name { display: block; font-family: var(--font-display); font-weight: 700; font-size: 1.0625rem; line-height: 1.3; }
.sheet__note { display: block; margin-top: 0.125rem; font-size: var(--text-small); line-height: 1.4; color: var(--text-muted); }
.sheet__foot { margin-top: 1rem; font-size: var(--text-small); line-height: 1.5; color: var(--text-secondary); }
.sheet__foot strong { font-weight: 400; color: var(--text-primary); }

.meta > div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--rule);
  font-family: var(--font-mono);
  font-size: var(--text-micro);
}
.meta dt { color: var(--text-secondary); }
.meta dd { white-space: nowrap; color: var(--text-muted); }

.status { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1.5rem; align-items: center; padding: 1.5rem 0 0.25rem; }
.status img { width: 5.5rem; height: 5.5rem; }
.status__figure { font-family: var(--font-display); font-weight: 700; font-size: 3.5rem; line-height: 1; letter-spacing: -0.04em; }
.status__label { margin-top: 0.375rem; font-family: var(--font-mono); font-size: var(--text-micro); letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); }

.route { display: grid; gap: 0.5rem; padding-top: 1rem; }
.route__box {
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-inset);
  text-align: center;
}
.route__name { display: block; font-family: var(--font-display); font-weight: 700; line-height: 1.3; }
.route__note { display: block; margin-top: 0.125rem; font-size: var(--text-micro); line-height: 1.4; color: var(--text-muted); }
.route__arrow { display: grid; place-items: center; height: 1.25rem; color: var(--accent-text); }
.route__arrow svg { width: 1rem; height: 1rem; }
.route__tiers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.5rem; }
.route__tier {
  padding: 0.5rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-inset);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-small);
  text-align: center;
  color: var(--text-muted);
}
.route__tier--on { border-color: var(--accent-line); background: var(--surface-icon); color: var(--text-primary); }
.route__legend { font-family: var(--font-mono); font-size: var(--text-micro); line-height: 1.5; text-align: center; color: var(--text-muted); }

/* ---------- principles strip --------------------------------------------- */
.principles { background: var(--surface-raised); border-bottom: 1px solid var(--rule); }
.principles__row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); }
.principles__row li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 1rem; align-items: baseline; padding: 1.75rem 0; }
.principles__row li:not(:last-child) { padding-right: var(--gutter); }
.principles__row li + li { padding-left: var(--gutter); border-left: 1px solid var(--rule); }
.principles__num { font-family: var(--font-mono); font-size: var(--text-micro); letter-spacing: 0.12em; color: var(--accent-text); }
.principles__row p { font-size: var(--text-body); line-height: 1.5; color: var(--text-secondary); }

/* ---------- sections ----------------------------------------------------- */
.section { padding-block: var(--space-section); border-bottom: 1px solid var(--rule); }
.section__inner {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gutter);
  align-items: start;
}
.section__rail { grid-column: 1 / span 3; position: sticky; top: 6rem; }
.section__index {
  display: block;
  margin-bottom: 0.75rem;
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-text);
}
.section__title {
  font-size: var(--text-display);
  line-height: var(--leading-display);
  letter-spacing: var(--tracking-display);
  text-wrap: balance;
}
.section__body { grid-column: 4 / -1; min-width: 0; display: grid; gap: var(--space-l); }
.section__body > *, .split > *, .product > *, .claim > *, .cards > *, .steps > *, .masthead__inner > *, .band__inner > * { min-width: 0; }
.section__intro { max-width: 62ch; font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--text-secondary); }

.subblock { scroll-margin-top: 6rem; }
.subblock h3 { margin-bottom: 1rem; font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
.note { font-family: var(--font-mono); font-size: var(--text-micro); line-height: 1.6; color: var(--text-muted); max-width: 74ch; }
.note + .note { margin-top: 0.5rem; }
.subblock .note { margin-top: 1rem; }

.text-link { display: inline-flex; align-items: center; gap: 0.375rem; margin-top: 1.25rem; font-family: var(--font-display); font-weight: 700; font-size: var(--text-small); }
.text-link svg, .claim__link svg, .card__more svg { width: 1rem; height: 1rem; transition: transform 0.2s; }
.text-link:hover svg, .claim__link:hover svg, .card:hover .card__more svg { transform: translateX(3px); }

/* ---------- cards -------------------------------------------------------- */
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); }
.cards--two { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 46rem; }
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.5rem;
  background: var(--surface-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.card:hover { border-color: var(--accent-line); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.card:has(.card__title a:focus-visible) { outline: 2px solid var(--accent-text); outline-offset: 3px; }
.card__label { font-family: var(--font-mono); font-size: 0.75rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.card__title { font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
.card__title a { color: inherit; text-decoration: none; }
.card__title a:focus-visible { outline: none; }
.card__title a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.card__text { font-size: var(--text-small); color: var(--text-secondary); }
.card__meta { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--rule); font-family: var(--font-mono); font-size: var(--text-micro); color: var(--text-muted); }
.card__meta strong { font-family: var(--font-display); font-size: 1.25rem; letter-spacing: -0.02em; color: var(--text-primary); }
.card__more { display: inline-flex; align-items: center; gap: 0.375rem; font-family: var(--font-display); font-weight: 700; font-size: var(--text-small); color: var(--accent-text); }
.card:hover .card__more { color: var(--accent-text-hover); }
@media (min-width: 48rem) { .cards:not(.cards--two) .card__title { min-height: 2.5em; } }

.contact-card {
  display: grid;
  gap: 0.375rem;
  padding: 1.5rem;
  background: var(--surface-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
}
.contact-card:hover { border-color: var(--accent-line); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.contact-card__icon {
  width: 2.5rem;
  height: 2.5rem;
  display: grid;
  place-items: center;
  margin-bottom: 0.625rem;
  border-radius: 0.625rem;
  border: 1px solid var(--accent-line);
  background: var(--surface-icon);
  color: var(--accent-text);
}
.contact-card__icon svg { width: 1.25rem; height: 1.25rem; }
.contact-card__value { font-family: var(--font-display); font-weight: 700; font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); color: var(--text-primary); overflow-wrap: anywhere; }

/* ---------- steps and timeline ------------------------------------------- */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); counter-reset: step; }
.steps li { counter-increment: step; position: relative; padding-top: 1.25rem; border-top: 1px solid var(--border-strong); }
.steps li::before {
  content: "0" counter(step);
  display: block;
  margin-bottom: 0.875rem;
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  letter-spacing: 0.12em;
  color: var(--accent-text);
}
.steps li::after { content: ""; position: absolute; top: -1px; left: 0; width: 2.75rem; height: 1px; background: var(--accent-text); }
.steps h3, .timeline h3 { margin-bottom: 0.5rem; font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
.steps p, .timeline p { font-size: var(--text-small); color: var(--text-secondary); }

.timeline { counter-reset: step; max-width: 52rem; }
.timeline li {
  counter-increment: step;
  position: relative;
  display: grid;
  grid-template-columns: 3.5rem minmax(0, 1fr);
  gap: 1.5rem;
  padding-bottom: 2rem;
}
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: "0" counter(step);
  padding-top: 0.3rem;
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  letter-spacing: 0.12em;
  color: var(--accent-text);
}
.timeline li::after { content: ""; position: absolute; left: 0.6875rem; top: 2rem; bottom: 0; width: 1px; background: var(--rule); }
.timeline li:last-child::after { display: none; }

/* ---------- prose, lists, asides ----------------------------------------- */
.split { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--space-xl); align-items: start; }
.prose p { max-width: 62ch; color: var(--text-secondary); }
.prose p + p { margin-top: 1rem; }
.list { display: grid; gap: 0.75rem; }
.prose .list { margin-top: var(--space-m); }
.list li { position: relative; padding-left: 1.75rem; color: var(--text-secondary); }
.list li::before {
  content: "";
  position: absolute;
  left: 0.25rem;
  top: 0.55em;
  width: 0.5rem;
  height: 0.5rem;
  border-radius: 50%;
  border: 1.5px solid var(--accent-text);
}
.aside { padding: 1.5rem; background: var(--surface-inset); border: 1px solid var(--border); border-radius: var(--radius-md); }
.aside__title { margin-bottom: 1rem; font-family: var(--font-mono); font-size: 0.75rem; font-weight: 400; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.aside ul { display: grid; gap: 0.625rem; }
.aside li { display: grid; grid-template-columns: 1.25rem minmax(0, 1fr); gap: 0.625rem; align-items: baseline; font-size: var(--text-small); color: var(--text-secondary); }
.aside li svg { width: 1rem; height: 1rem; color: var(--accent-text); transform: translateY(0.15em); }
.aside p { font-size: var(--text-small); color: var(--text-secondary); }
.rule {
  padding: 1.25rem 1.5rem;
  border-left: 2px solid var(--accent-text);
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  background: var(--accent-soft);
  font-size: var(--text-lead);
  line-height: var(--leading-lead);
  color: var(--text-primary);
}
.illustration { border: 1px solid var(--border); border-radius: var(--radius-md); overflow: hidden; background: #fff; }
.illustration img { width: 100%; height: auto; }

/* ---------- products and prices ------------------------------------------ */
.product {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: var(--space-xl);
  padding: clamp(1.5rem, 3vw, 2.5rem);
  background: var(--surface-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.product__label, .price__unit { font-family: var(--font-mono); font-size: var(--text-micro); letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-muted); }
.product__title { margin-top: 0.5rem; font-size: var(--text-display); line-height: var(--leading-display); letter-spacing: var(--tracking-display); }
.product__desc { margin-top: 0.75rem; max-width: 58ch; color: var(--text-secondary); }
.product__list { display: grid; gap: 0.625rem; margin-top: 1.25rem; }
.product__list li { position: relative; padding-left: 1.5rem; font-size: var(--text-small); color: var(--text-secondary); }
.product__list li::before { content: ""; position: absolute; left: 0.25rem; top: 0.6em; width: 0.375rem; height: 0.375rem; border-radius: 50%; background: var(--accent-text); }
.product__aside { display: flex; flex-direction: column; gap: 1.25rem; padding-left: var(--space-xl); border-left: 1px solid var(--rule); }
.price__amount {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.25rem, 1.8rem + 1.8vw, 3rem);
  line-height: 1;
  letter-spacing: -0.035em;
  font-variant-numeric: tabular-nums;
}
.price__unit { margin-top: 0.5rem; }
.price__alt { margin-top: 0.75rem; font-family: var(--font-mono); font-size: var(--text-micro); color: var(--text-muted); }
.price__more { padding-top: 1.25rem; border-top: 1px solid var(--rule); font-size: var(--text-small); color: var(--text-muted); }
.price__more strong { display: block; margin: 0.25rem 0; font-family: var(--font-display); font-size: 1.25rem; letter-spacing: -0.02em; color: var(--text-primary); }
.product__aside .btn { align-self: flex-start; margin-top: auto; }

/* ---------- tables ------------------------------------------------------- */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-md); background: var(--surface-card); }
.table { width: 100%; min-width: 36rem; border-collapse: separate; border-spacing: 0; font-size: var(--text-small); }
.table caption {
  padding: 1rem 1.25rem;
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  text-align: left;
  color: var(--text-muted);
}
.table th, .table td { padding: 0.875rem 1.25rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--rule); }
.table thead th {
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  font-weight: 400;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--text-muted);
}
.table tbody th { position: sticky; left: 0; background: var(--surface-card); font-family: var(--font-display); font-weight: 700; }
.table tbody td { color: var(--text-secondary); }
.table tbody tr:last-child th, .table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover > * { background: var(--surface-hover); }
.table .num { font-family: var(--font-mono); text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }

.rate { display: grid; grid-template-columns: 5.5rem minmax(4rem, 1fr); gap: 0.875rem; align-items: center; }
.rate__pct { text-align: right; }
.rate__track { position: relative; height: 0.375rem; border-radius: 999px; background: var(--surface-inset); box-shadow: inset 0 0 0 1px var(--rule); }
.rate__fill {
  position: absolute;
  inset-block: 0;
  left: calc(var(--min) * 1%);
  width: calc((var(--max) - var(--min)) * 1%);
  border-radius: 999px;
  background: var(--gradient-accent);
}

/* ---------- questions ---------------------------------------------------- */
.faq { border-top: 1px solid var(--border); max-width: 56rem; }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1.5rem;
  padding: 1.25rem 0;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: var(--text-title);
  line-height: var(--leading-title);
  letter-spacing: var(--tracking-title);
  cursor: pointer;
  list-style: none;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; flex: none; font-family: var(--font-mono); font-weight: 400; font-size: 1.25rem; line-height: 1; color: var(--accent-text); }
.faq details[open] summary::after { content: "–"; }
.faq details p { max-width: 62ch; padding-bottom: 1.25rem; color: var(--text-secondary); }

/* ---------- the cost claim ----------------------------------------------- */
.claim {
  position: relative;
  overflow: clip;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--space-xl);
  align-items: center;
  padding: clamp(1.75rem, 4vw, 3rem);
  background: var(--surface-raised);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
}
.claim::before {
  content: "";
  position: absolute;
  right: -10%;
  bottom: -70%;
  width: 60%;
  aspect-ratio: 1;
  background: radial-gradient(closest-side, var(--blob-1), transparent);
  pointer-events: none;
}
.claim > * { position: relative; }
.claim__figure {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(3rem, 2rem + 5vw, 5.5rem);
  line-height: 0.95;
  letter-spacing: -0.045em;
  background: var(--gradient-text);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.claim__x { font-size: 0.62em; }
.claim--plain .claim__figure { font-size: clamp(2.25rem, 1.6rem + 3vw, 3.75rem); }
.claim__text { font-size: var(--text-lead); line-height: var(--leading-lead); color: var(--text-primary); }
.claim__source { margin-top: 1rem; font-family: var(--font-mono); font-size: var(--text-micro); line-height: 1.6; color: var(--text-muted); }
.claim__link { display: inline-flex; align-items: center; gap: 0.375rem; margin-top: 1rem; font-family: var(--font-display); font-weight: 700; font-size: var(--text-small); }

/* ---------- empty state -------------------------------------------------- */
.empty {
  display: grid;
  justify-items: start;
  gap: 1rem;
  padding: clamp(2rem, 4vw, 3rem);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-lg);
  background: var(--surface-inset);
}
.empty h3 { font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); }
.empty p { max-width: 56ch; color: var(--text-secondary); }

/* ---------- closing band ------------------------------------------------- */
.band {
  position: relative;
  overflow: clip;
  padding-block: clamp(3.5rem, 6vw, 5.5rem);
  background: var(--surface-raised);
  border-bottom: 1px solid var(--rule);
}
.band::before {
  content: "";
  position: absolute;
  right: -10%;
  bottom: -90%;
  width: 70%;
  aspect-ratio: 1;
  background: radial-gradient(closest-side, var(--blob-1), transparent);
  pointer-events: none;
}
.band__inner {
  position: relative;
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: var(--gutter);
  align-items: center;
}
.band__copy { grid-column: 1 / span 7; }
.band__action { grid-column: 8 / -1; justify-items: end; }
.band h2 { font-size: var(--text-band); line-height: var(--leading-display); letter-spacing: var(--tracking-display); text-wrap: balance; }
.band p { margin-top: 1rem; max-width: 52ch; color: var(--text-secondary); }
.band .cta-row { justify-content: flex-end; margin-top: 0; }
.band .cta-facts { justify-content: flex-end; margin-top: 1rem; }

/* ---------- legal pages -------------------------------------------------- */
.toc { margin-top: 1.5rem; }
.toc__label { display: block; margin-bottom: 0.875rem; font-family: var(--font-mono); font-size: var(--text-micro); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.toc ul { display: grid; gap: 0.625rem; }
.toc a { font-family: var(--font-display); font-size: var(--text-small); color: var(--text-secondary); text-decoration: none; }
.toc a:hover { color: var(--text-primary); }
.legal-prose { max-width: 66ch; }
.legal-prose h2 { margin: 2.5rem 0 0.75rem; font-size: var(--text-title); line-height: var(--leading-title); letter-spacing: var(--tracking-title); scroll-margin-top: 6rem; }
.legal-prose h2:first-child { margin-top: 0; }
.legal-prose p { color: var(--text-secondary); }
.legal-prose p + p { margin-top: 1rem; }
.legal-prose strong { color: var(--text-primary); }

.defs { border-top: 1px solid var(--border); }
.defs > div { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.2fr); gap: var(--gutter); padding: 1.5rem 0; border-bottom: 1px solid var(--rule); }
.defs dt { font-family: var(--font-display); font-weight: 700; }
.defs dd { color: var(--text-secondary); }
.defs .list { gap: 0.5rem; }

/* ---------- footer ------------------------------------------------------- */
.site-footer { padding-block: clamp(3rem, 6vw, 5rem) 2.5rem; }
.site-footer__mast { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: var(--gutter); }
.site-footer__name { grid-column: 1 / span 5; }
.site-footer__name img { width: 3.5rem; height: 3.5rem; margin-bottom: 1rem; }
.site-footer__name h2 { font-size: clamp(1.75rem, 1.4rem + 1.4vw, 2.5rem); line-height: 1.1; letter-spacing: -0.03em; }
.site-footer__tagline { margin-top: 1rem; max-width: 40ch; color: var(--text-secondary); }
.site-footer__cols { grid-column: 6 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); }
.site-footer__label { display: block; margin-bottom: 1rem; font-family: var(--font-mono); font-size: var(--text-micro); letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-muted); }
.site-footer ul { display: grid; gap: 0.625rem; }
.site-footer a { color: var(--text-secondary); text-decoration: none; }
.site-footer a:hover { color: var(--text-primary); text-decoration: underline; }
.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
  margin-top: clamp(2.5rem, 5vw, 4rem);
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  font-family: var(--font-mono);
  font-size: var(--text-micro);
  color: var(--text-muted);
}

/* ---------- responsive --------------------------------------------------- */
@media (max-width: 68.75rem) {
  .header__cta { display: none; }
  .menu-toggle { display: inline-flex; }

  .js .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: 0.5rem var(--pad) 1.5rem;
    background: var(--surface-page);
    border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
  }
  .js .nav.is-open { display: flex; }
  .js .nav a:not(.nav__cta) {
    min-height: 3rem;
    font-size: 1.0625rem;
    border-bottom: 1px solid var(--rule);
  }
  .js .nav a[aria-current="page"] { color: var(--accent-text); }
  .js .nav a[aria-current="page"]::after { display: none; }
  .js .nav a.nav__cta { display: inline-flex; align-self: flex-start; margin-top: 1.25rem; }

  /* without JavaScript the navigation stays on the page, wrapped */
  html:not(.js) .site-header__inner { flex-wrap: wrap; padding-block: 0.5rem; }
  html:not(.js) .nav { order: 3; flex: 1 0 100%; flex-wrap: wrap; gap: 0 1.25rem; margin-left: 0; }
  html:not(.js) .nav a.nav__cta, html:not(.js) .menu-toggle { display: none; }
}

@media (max-width: 64rem) {
  .masthead__copy, .masthead__figure, .masthead--plain .masthead__copy { grid-column: 1 / -1; }
  .masthead__figure { max-width: 30rem; margin-top: var(--space-l); }
  .section__rail, .section__body { grid-column: 1 / -1; }
  .section__rail { position: static; }
  .section__body { margin-top: var(--space-l); }
  .site-footer__name, .site-footer__cols { grid-column: 1 / -1; }
  .site-footer__cols { margin-top: var(--space-l); }
}

@media (max-width: 48rem) {
  .cards, .cards--two, .steps, .split, .product, .claim { grid-template-columns: minmax(0, 1fr); }
  .cards > :last-child:nth-child(3) { grid-column: 1 / -1; }
  .steps { gap: var(--space-m); }
  .product__aside { padding-left: 0; padding-top: var(--space-l); border-left: 0; border-top: 1px solid var(--rule); }
  .product__aside .btn { align-self: stretch; }
  .band__copy, .band__action { grid-column: 1 / -1; }
  .band__action { justify-items: start; margin-top: var(--space-m); }
  .band .cta-row, .band .cta-facts { justify-content: flex-start; }
  .principles__row { grid-template-columns: minmax(0, 1fr); }
  .principles__row li { padding: 1.25rem 0; }
  .principles__row li + li { padding-left: 0; border-left: 0; border-top: 1px solid var(--rule); }
  .principles__row li:not(:last-child) { padding-right: 0; }
}

@media (max-width: 40rem) {
  .running-head__doc, .running-head__section::before { display: none; }
  .running-head__prefix { display: none; }
  .theme-toggle__text { display: none; }
  .theme-toggle { width: 2.75rem; padding: 0; justify-content: center; }
  .defs > div { grid-template-columns: minmax(0, 1fr); gap: 0.5rem; }
  .site-footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .site-footer__cols > div { grid-column: 1 / -1; }
  .timeline li { grid-template-columns: 2.75rem minmax(0, 1fr); gap: 1rem; }
  .table tbody th { max-width: 9.5rem; box-shadow: inset -1px 0 0 var(--rule); }
  .table th, .table td { padding: 0.75rem 0.875rem; }
}

/* ---------- motion and print --------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}

@media print {
  .running-head, .site-header, .band, .site-footer__cols, .skip { display: none; }
  body { background: #fff; color: #000; }
  .section__rail { position: static; }
  a { color: #000; }
}
