/*
 * SOMAT site styles.
 * Colours are tokens on :root. Dark mode follows the browser unless the visitor has picked one with the toggle,
 * which sets data-theme on <html>.
 */

:root {
  --bg: #f4f6f9;
  --bg-alt: #eaeef3;
  --surface: #ffffff;
  --text: #33506b;
  --heading: #0b2f4d;
  --muted: #5f7992;
  --line: #d8e0e8;
  --line-strong: #0b2f4d;
  --link: #0a6c8f;
  --accent: #0a6c8f;         /* eyebrows, highlights */
  --accent-soft: #e1f3fa;
  --btn-bg: #0b2f4d;
  --btn-text: #ffffff;
  --btn-hover: #174a73;
  --hero-bg: #e7edf3;
  --grid-line: rgba(48, 82, 113, .09);
  --warn: #c4621d;
  --bad: #b8392d;
  --good: #23855a;
  --shadow: 0 1px 2px rgba(11, 47, 77, .06), 0 8px 24px rgba(11, 47, 77, .07);

  /* The cube mark */
  --mark-top: #305271;
  --mark-left: #849aaf;
  --mark-right: #5a9ac6;
  --mark-edge: #83e0ff;

  --font-body: Figtree, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --radius: 10px;
  --wrap: 1140px;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d1a26;
    --bg-alt: #112131;
    --surface: #152738;
    --text: #bccada;
    --heading: #f2f8ff;
    --muted: #8aa0b5;
    --line: #26394c;
    --line-strong: #83e0ff;
    --link: #83e0ff;
    --accent: #83e0ff;
    --accent-soft: rgba(131, 224, 255, .1);
    --btn-bg: #83e0ff;
    --btn-text: #062438;
    --btn-hover: #a8ebff;
    --hero-bg: #0b2f4d;
    --grid-line: rgba(131, 224, 255, .07);
    --warn: #f0a062;
    --bad: #f0837a;
    --good: #5cc796;
    --shadow: 0 1px 2px rgba(0, 0, 0, .25), 0 10px 28px rgba(0, 0, 0, .25);
    --mark-top: #305271;
    --mark-left: #849aaf;
    --mark-right: #5a9ac6;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #0d1a26;
  --bg-alt: #112131;
  --surface: #152738;
  --text: #bccada;
  --heading: #f2f8ff;
  --muted: #8aa0b5;
  --line: #26394c;
  --line-strong: #83e0ff;
  --link: #83e0ff;
  --accent: #83e0ff;
  --accent-soft: rgba(131, 224, 255, .1);
  --btn-bg: #83e0ff;
  --btn-text: #062438;
  --btn-hover: #a8ebff;
  --hero-bg: #0b2f4d;
  --grid-line: rgba(131, 224, 255, .07);
  --warn: #f0a062;
  --bad: #f0837a;
  --good: #5cc796;
  --shadow: 0 1px 2px rgba(0, 0, 0, .25), 0 10px 28px rgba(0, 0, 0, .25);
  color-scheme: dark;
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 88px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.65 var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; }
a { color: var(--link); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }
h1, h2, h3, h4 { color: var(--heading); margin: 0; line-height: 1.18; text-wrap: balance; letter-spacing: -.01em; }
h1 { font-size: clamp(34px, 5vw, 54px); font-weight: 800; letter-spacing: -.02em; }
h2 { font-size: clamp(26px, 3.2vw, 36px); font-weight: 700; }
h3 { font-size: 20px; font-weight: 700; }
p { margin: 0; }
p + p { margin-top: 1em; }
.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: max(16px, env(safe-area-inset-left, 0px));
  padding-right: max(16px, env(safe-area-inset-right, 0px));
}
@media (min-width: 700px) { .wrap { padding-left: 28px; padding-right: 28px; } }

.eyebrow {
  display: block;
  font: 500 12.5px/1.4 var(--font-mono);
  letter-spacing: .09em;
  text-transform: uppercase;
  color: var(--accent);
}
.lede { font-size: 19px; color: var(--text); max-width: 60ch; }
.muted { color: var(--muted); }
.small { font-size: 14.5px; }

.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--surface); padding: 8px 14px; border-radius: 6px; }
.skip:focus { left: 16px; }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 10px 20px;
  border-radius: 8px; border: 1px solid transparent;
  font: 600 15.5px/1.1 var(--font-body);
  text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s, border-color .15s, color .15s;
}
.btn-primary { background: var(--btn-bg); color: var(--btn-text); }
.btn-primary:hover { background: var(--btn-hover); }
.btn-secondary { background: transparent; color: var(--heading); border-color: var(--line); }
.btn-secondary:hover { border-color: var(--accent); }
.text-link { font-weight: 600; text-decoration: none; color: var(--heading); }
.text-link::after { content: " \2192"; color: var(--accent); }
.text-link:hover { color: var(--link); }

/* ---------- Header ---------- */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
.bar { display: flex; align-items: center; gap: 24px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--heading); flex: none; }
.mark { width: 34px; height: 34px; display: block; }
.mark-top { fill: var(--mark-top); stroke: var(--mark-edge); stroke-width: 4; stroke-linejoin: round; }
.mark-left { fill: var(--mark-left); }
.mark-right { fill: var(--mark-right); }
.wordmark { font-weight: 800; font-size: 20px; letter-spacing: .14em; line-height: 1; }

.site-nav { margin-left: auto; }
.site-nav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.site-nav a {
  display: block; padding: 8px 12px; border-radius: 6px;
  color: var(--text); text-decoration: none; font-size: 15.5px; font-weight: 500;
}
.site-nav a:hover { color: var(--heading); background: var(--bg-alt); }
.site-nav a[aria-current="page"] { color: var(--heading); font-weight: 700; box-shadow: inset 0 -2px 0 var(--accent); border-radius: 0; }

.bar-actions { display: flex; align-items: center; gap: 10px; }
.theme-toggle, .nav-toggle {
  width: 44px; height: 44px; display: inline-grid; place-items: center;
  border: 1px solid var(--line); border-radius: 8px; background: transparent; color: var(--heading); cursor: pointer;
}
.theme-toggle:hover, .nav-toggle:hover { border-color: var(--accent); }
.theme-toggle svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; }
.theme-toggle .icon-moon { display: none; }
/* The icon shows the mode you would switch to. */
:root[data-theme-resolved="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme-resolved="dark"] .theme-toggle .icon-moon { display: none; }
:root[data-theme-resolved="light"] .theme-toggle .icon-sun { display: none; }
:root[data-theme-resolved="light"] .theme-toggle .icon-moon { display: block; }

.nav-toggle { display: none; gap: 4px; align-content: center; }
.nav-toggle span { display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px; transition: transform .2s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 960px) {
  .bar { gap: 12px; }
  .bar-actions { margin-left: auto; }
  .nav-toggle { display: inline-grid; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--bg); border-bottom: 1px solid var(--line); box-shadow: var(--shadow);
    display: none;
  }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; padding: 8px max(16px, env(safe-area-inset-left, 0px)) 16px; }
  .site-nav a { padding: 12px 4px; font-size: 17px; border-bottom: 1px solid var(--line); border-radius: 0; }
  .site-nav a[aria-current="page"] { box-shadow: inset 3px 0 0 var(--accent); padding-left: 12px; }
}
@media (max-width: 560px) {
  .bar-cta { display: none; }
}

/* ---------- Sections ---------- */

.section { padding-block: clamp(56px, 8vw, 96px); }
.section + .section { border-top: 1px solid var(--line); }
.section.alt { background: var(--bg-alt); }
.sec-head { display: grid; gap: 12px; max-width: 66ch; margin-bottom: clamp(28px, 4vw, 44px); }
.sec-head p { font-size: 18px; }

/* Isometric lattice drawn at the angles of the cube mark */
.lattice { position: relative; isolation: isolate; }
.lattice::before {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    repeating-linear-gradient(42deg, var(--grid-line) 0 1px, transparent 1px 46px),
    repeating-linear-gradient(-42deg, var(--grid-line) 0 1px, transparent 1px 46px);
  -webkit-mask-image: linear-gradient(105deg, transparent 15%, #000 70%);
  mask-image: linear-gradient(105deg, transparent 15%, #000 70%);
}

/* ---------- Hero ---------- */

.hero { background: var(--hero-bg); border-bottom: 1px solid var(--line); }
.hero-grid {
  display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  gap: clamp(32px, 5vw, 64px); align-items: center;
  padding-block: clamp(48px, 7vw, 96px);
}
.hero h1 { max-width: 16ch; }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lede { margin-top: 22px; }
.actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }
:root[data-theme-resolved="dark"] .hero { border-bottom-color: transparent; }
:root[data-theme-resolved="dark"] .hero .lede { color: #c9d8e6; }

/* The observation sequence: the site's signature object */
.seq {
  margin: 0; min-width: 0;
  background: var(--surface); border: 1px solid var(--line); border-radius: 14px;
  padding: clamp(18px, 3vw, 26px); box-shadow: var(--shadow);
}
:root[data-theme-resolved="dark"] .hero .seq { background: #123d61; border-color: rgba(131, 224, 255, .22); }
.seq-head { display: flex; justify-content: space-between; align-items: baseline; gap: 6px 14px; flex-wrap: wrap; }
.seq-head strong { color: var(--heading); font-size: 15.5px; }
.seq-head small { font: 12px var(--font-mono); color: var(--muted); }
.seq ol { list-style: none; margin: 18px 0 0; padding: 0; position: relative; }
.seq ol::before { content: ""; position: absolute; left: 63px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.seq li { display: grid; grid-template-columns: 52px 22px minmax(0, 1fr); gap: 0 8px; padding-block: 8px; }
.seq time { font: 13px/1.5 var(--font-mono); color: var(--muted); text-align: right; padding-top: 1px; white-space: nowrap; }
.dot { width: 14px; height: 14px; border-radius: 50%; margin: 4px 0 0 4px; position: relative; z-index: 1; box-shadow: 0 0 0 3px var(--surface); }
:root[data-theme-resolved="dark"] .hero .dot { box-shadow: 0 0 0 3px #123d61; }
.dot.cue { background: var(--accent); }
.dot.err { background: var(--warn); }
.dot.bad { background: var(--bad); }
.dot.out { background: var(--heading); }
.kind { font: 500 12px/1.5 var(--font-mono); letter-spacing: .05em; text-transform: uppercase; }
.kind.cue { color: var(--accent); }
.kind.err { color: var(--warn); }
.kind.bad { color: var(--bad); }
.kind.out { color: var(--heading); }
.seq li p { font-size: 15px; line-height: 1.5; }
.seq .note { margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 14.5px; }
.seq .note b { color: var(--heading); }

/* Rotation between examples */
.seq { position: relative; overflow: hidden; }
.seq-body { transition: opacity .35s ease, transform .35s ease; }
.seq-body.leaving { opacity: 0; transform: translateY(-6px); }
.seq-body.entering { opacity: 0; transform: translateY(6px); }
.seq.sizing { transition: height .4s ease; }
.seq-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; min-height: 32px; }
.seq-sector { font: 500 12px/1.4 var(--font-mono); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); transition: opacity .35s ease; }
.seq-body.leaving ~ .seq-foot .seq-sector, .seq-body.entering ~ .seq-foot .seq-sector { opacity: 0; }
.seq-next {
  font: 600 13.5px/1 var(--font-body); color: var(--heading); background: transparent;
  border: 1px solid var(--line); border-radius: 999px; padding: 8px 14px; min-height: 32px; cursor: pointer;
}
.seq-next::after { content: " \2192"; color: var(--accent); }
.seq-next:hover { border-color: var(--accent); }
.seq-progress { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: transparent; }
.seq-progress span { display: block; height: 100%; width: 100%; background: var(--accent); opacity: .55; transform-origin: left; transform: scaleX(0); }
.seq.running .seq-progress span { animation: seq-timer var(--seq-delay, 12s) linear forwards; }
.seq.paused .seq-progress span { animation-play-state: paused; }
@keyframes seq-timer { from { transform: scaleX(0); } to { transform: scaleX(1); } }
@media (prefers-reduced-motion: reduce) {
  .seq-body, .seq.sizing, .seq-sector { transition: none; }
  .seq-progress { display: none; }
}
@media (prefers-reduced-motion: no-preference) {
  .seq li { animation: rise .55s ease both; }
  .seq li:nth-child(2) { animation-delay: .15s; }
  .seq li:nth-child(3) { animation-delay: .3s; }
  .seq li:nth-child(4) { animation-delay: .45s; }
  @keyframes rise { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
}

/* ---------- Platform: four functions ---------- */

.functions { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 2px solid var(--line-strong); }
.functions > div { padding: 22px 22px 0 0; display: grid; gap: 8px; align-content: start; }
.functions > div + div { padding-left: 22px; border-left: 1px solid var(--line); }
.functions p { font-size: 16px; }
@media (max-width: 900px) {
  .functions { grid-template-columns: 1fr 1fr; }
  .functions > div:nth-child(3) { padding-left: 0; border-left: 0; }
  .functions > div:nth-child(n+3) { padding-top: 28px; }
}
@media (max-width: 540px) {
  .functions { grid-template-columns: 1fr; }
  .functions > div, .functions > div + div { padding: 20px 0; border-left: 0; }
  .functions > div + div { border-top: 1px solid var(--line); }
}

/* ---------- Two-column blocks ---------- */

.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(32px, 5vw, 64px); align-items: start; }
.split .copy { display: grid; gap: 16px; max-width: 60ch; }
.split .copy p + p { margin-top: 0; }
@media (max-width: 860px) { .split { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Cards ---------- */

.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: clamp(18px, 3vw, 26px); min-width: 0;
}
.card .src { font: 12px/1.5 var(--font-mono); color: var(--muted); }
.card h3 { font-size: 19px; margin-top: 8px; }
.bars { display: grid; gap: 14px; margin-top: 22px; }
.bar-row { display: grid; grid-template-columns: 120px minmax(0, 1fr) 100px; gap: 12px; align-items: center; font-size: 14.5px; }
.track { height: 14px; background: var(--bg-alt); border-radius: 3px; overflow: hidden; }
.fill { display: block; height: 100%; background: var(--accent); }
.bar-row.worse .fill { background: var(--warn); }
.val { font: 13px var(--font-mono); font-variant-numeric: tabular-nums; text-align: right; color: var(--heading); }
.caveat { margin-top: 20px; font-size: 14.5px; color: var(--muted); border-left: 3px solid var(--line); padding-left: 12px; }
.analyst { margin-top: 12px; font-size: 14.5px; }
.analyst b { color: var(--heading); }
@media (max-width: 480px) { .bar-row { grid-template-columns: 92px minmax(0, 1fr) 84px; gap: 8px; font-size: 13.5px; } }

/* ---------- Sectors ---------- */

.notice {
  display: flex; gap: 12px; align-items: flex-start;
  background: var(--accent-soft); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 16px; font-size: 15px; margin-bottom: 24px; max-width: 80ch;
}
.notice::before { content: "i"; flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font: 600 13px var(--font-mono); background: var(--accent); color: var(--bg); margin-top: 1px; }
.sectors { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 16px; }
.sector {
  display: grid; gap: 12px; align-content: start;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; text-decoration: none; color: var(--text);
  transition: border-color .15s, transform .15s, box-shadow .15s;
}
.sector:hover { border-color: var(--accent); box-shadow: var(--shadow); }
@media (prefers-reduced-motion: no-preference) { .sector:hover { transform: translateY(-2px); } }
.sector .why { font: 12px/1.45 var(--font-mono); color: var(--accent); letter-spacing: .02em; }
.sector h3 { font-size: 19px; }
.sector ul { margin: 0; padding-left: 18px; font-size: 15px; display: grid; gap: 4px; }
.sector .go { margin-top: 4px; font-weight: 600; font-size: 15px; color: var(--heading); }
.sector .go::after { content: " \2192"; color: var(--accent); }

/* ---------- Mapping table ---------- */

.map { width: 100%; border-collapse: collapse; font-size: 15.5px; border-top: 2px solid var(--line-strong); }
.map th, .map td { text-align: left; padding: 11px 12px 11px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.map thead th { font: 500 12px var(--font-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.map tbody th { font: 500 13px var(--font-mono); color: var(--accent); white-space: nowrap; }
.map td { color: var(--heading); }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ---------- Articles ---------- */

.article-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.article-card {
  display: grid; gap: 10px; align-content: start;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; text-decoration: none; color: var(--text);
  transition: border-color .15s, box-shadow .15s;
}
.article-card:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.article-card h3 { font-size: 20px; }
.article-card p { font-size: 15.5px; }
.meta { font: 12.5px/1.5 var(--font-mono); color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 12px; }
.meta .tag { color: var(--accent); text-transform: uppercase; letter-spacing: .06em; }

.page-head { padding-block: clamp(48px, 7vw, 88px) clamp(32px, 4vw, 48px); background: var(--hero-bg); border-bottom: 1px solid var(--line); }
.page-head .lede { margin-top: 18px; }
.page-head h1 { font-size: clamp(32px, 4.4vw, 48px); max-width: 22ch; }
:root[data-theme-resolved="dark"] .page-head { border-bottom-color: transparent; }

.prose { max-width: 68ch; font-size: 18px; line-height: 1.72; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { font-size: clamp(23px, 2.6vw, 28px); margin-top: 1.9em; }
.prose h3 { font-size: 20px; margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: .4em; }
.prose blockquote { margin-left: 0; padding-left: 18px; border-left: 3px solid var(--accent); color: var(--heading); }
.prose figure { margin-inline: 0; }
.prose figcaption { font-size: 14.5px; color: var(--muted); margin-top: 10px; }
.prose code { font: .88em var(--font-mono); background: var(--bg-alt); padding: .1em .35em; border-radius: 4px; }
.prose .table-scroll { margin-top: 1.4em; }
.article-foot { margin-top: 48px; padding-top: 24px; border-top: 1px solid var(--line); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: center; }

/* ---------- Background page ---------- */

.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 16px; }
.split .facts { grid-template-columns: minmax(0, 1fr); }
.facts .card h3 { font-size: 18px; margin: 0 0 6px; }
.facts .card p { font-size: 15.5px; }
.partners { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 16px; }
.partners .card { display: grid; gap: 10px; align-content: start; }

/* ---------- Pilots ---------- */

.steps { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--line-strong); }
.steps li { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 16px; padding-block: 16px; border-bottom: 1px solid var(--line); }
.steps .when { font: 500 13px/1.6 var(--font-mono); color: var(--accent); }
.steps b { display: block; color: var(--heading); font-size: 17px; }
.steps span { font-size: 16px; }
@media (max-width: 420px) { .steps li { grid-template-columns: 1fr; gap: 2px; } }

.cta-band { background: var(--hero-bg); }
.cta-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px 48px; align-items: center; }
.cta-inner .copy { display: grid; gap: 12px; max-width: 64ch; }
@media (max-width: 760px) { .cta-inner { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Form ---------- */

.form { display: grid; gap: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: clamp(20px, 3vw, 30px); min-width: 0; box-shadow: var(--shadow); }
.form h2 { font-size: 24px; }
.form label { display: grid; gap: 6px; font-size: 14.5px; font-weight: 600; color: var(--heading); }
.form .opt { font-weight: 400; color: var(--muted); }
.form input, .form select, .form textarea {
  font: 16px var(--font-body); width: 100%; min-height: 46px; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: 8px; background: var(--bg); color: var(--heading);
}
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--accent); outline: 2px solid color-mix(in srgb, var(--accent) 35%, transparent); outline-offset: 0; }
.form textarea { min-height: 120px; resize: vertical; }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .row2 { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { border-radius: 8px; padding: 12px 14px; font-size: 15px; border: 1px solid; }
.alert.ok { border-color: var(--good); color: var(--good); background: color-mix(in srgb, var(--good) 10%, transparent); }
.alert.err { border-color: var(--bad); color: var(--bad); background: color-mix(in srgb, var(--bad) 10%, transparent); }
.field-error { color: var(--bad); font-size: 13.5px; font-weight: 500; }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--line); padding-block: 44px 36px; font-size: 15px; background: var(--bg); }
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 24px 48px; }
.footer-brand { display: grid; gap: 14px; max-width: 46ch; }
.site-footer nav ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 24px; }
.site-footer nav a { color: var(--text); text-decoration: none; }
.site-footer nav a:hover { color: var(--heading); text-decoration: underline; }
.footer-small { grid-column: 1 / -1; font-size: 13.5px; color: var(--muted); padding-top: 18px; border-top: 1px solid var(--line); }
@media (max-width: 700px) { .footer-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Hero responsive ---------- */

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); }
  .hero h1 { max-width: 20ch; }
}
@media (max-width: 400px) {
  .seq li { grid-template-columns: 44px 22px minmax(0, 1fr); gap: 0 6px; }
  .seq ol::before { left: 53px; }
  .actions .btn { width: 100%; }
}
