/* Shared surfaces and foregrounds keep every language in the same palette. */
:root {
  color-scheme: dark;
  --paper: #23262c;
  --ink: #e3e4e7;
  --muted: #b5bac3;
  --line: #4c525d;
  --surface: #2c3037;
  --surface-alt: #353a43;
  --section: #202329;
  --tint: #41362f;
  --accent: #d79766;
  --highlight: #594331;
  --lime: var(--highlight);
  --white: var(--surface);
  --cta-bg: #d79766;
  --cta-hover: #dfa87e;
  --cta-text: #211912;
  --strong-bg: #1b2028;
  --strong-text: #e3e4e7;
  --orange-bg: #41362f;
  --orange-text: #eab98f;
  --orange-solid: #d79766;
  --orange-ink: #211912;
  --shadow: none;
}

:root[data-theme="light"] {
  color-scheme: light;
  --paper: #e5e4df;
  --ink: #242a32;
  --muted: #525b68;
  --line: #a5abb2;
  --surface: #f0efeb;
  --surface-alt: #dcddd8;
  --section: #dbdcd8;
  --tint: #e5d9ce;
  --accent: #8b4b23;
  --highlight: #dbc0a8;
  --cta-bg: #8b4b23;
  --cta-hover: #74401f;
  --cta-text: #fff6eb;
  --strong-bg: #2d333c;
  --strong-text: #e3e4e7;
  --orange-bg: #e5d9ce;
  --orange-text: #81431e;
  --orange-solid: #8b4b23;
  --orange-ink: #fff6eb;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #11151c;
  --ink: #dbdee5;
  --muted: #adb6c4;
  --line: #3c4655;
  --surface: #1a2029;
  --surface-alt: #252d39;
  --section: #151a22;
  --tint: #352d28;
  --accent: #d89a6a;
  --highlight: #503d2e;
  --cta-bg: #d89a6a;
  --cta-hover: #e0ab81;
  --cta-text: #211912;
  --strong-bg: #0e1219;
  --strong-text: #dbdee5;
  --orange-bg: #352d28;
  --orange-text: #e7b68e;
  --orange-solid: #d89a6a;
  --orange-ink: #211912;
}

html, body { background: var(--paper); color: var(--ink); }
body { transition: none; }
.theme-control { display: flex; flex-shrink: 0; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 30px; background: var(--surface); }
.theme-choice { display: grid; place-items: center; width: 40px; height: 40px; padding: 0; border: 0; border-radius: 50%; background: transparent; color: var(--muted); font-size: 19px; line-height: 1; }
.theme-choice:hover { background: var(--surface-alt); color: var(--ink); }
.theme-choice[aria-pressed="true"] { background: var(--cta-bg); color: var(--cta-text); }
.theme-choice:focus-visible, button:focus-visible, a:focus-visible, [tabindex]:focus-visible,
.module summary:focus-visible, .language-menu summary:focus-visible { outline-color: var(--accent); }
.header nav a:hover, .text-link:hover, .module-plus { color: var(--accent); }
.status-dot, .tiny-line { background: var(--accent); }
.track-line { background: var(--line); }
.skip { background: var(--cta-bg); color: var(--cta-text); }

.hero-intro, .hero-footnote, .hero-bottom, .stage-top, .signal-track,
.insight-card small, .card-index, .demo-label, .section-index, .muted,
.opening-bottom p, .cap p, .pilot-grid p, .section-lead,
.cap-number, .cap-tag, .mini-brand span, .sidebar-caption,
.scenario-tabs button, .sidebar-bottom, .sidebar-bottom div,
.demo-overline, .demo-pill, .customer-quote > span, .small-label,
.demo-columns p, .demo-footer, .founder div > span, .research-note,
.pilot-grid article > span, .final-cta p, .footer > span, dialog > p,
.module-number, .module summary small, .module-body p, .module-type,
.modules-note, .voice-card-index, .voice-card p, .voice-note, .contact-address {
  color: var(--muted);
}
.hero-bottom div span::before { color: var(--accent); }
.signal-stage, .research-visual { background: var(--surface-alt); border-color: var(--line); }
.signal-stage::before { display: none; }
.wave i { background: var(--accent); }
.insight-card, .cap, .demo-shell, .module, .voice-card, .language-options {
  background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: var(--shadow);
}
.insight-icon, .cap-tag, .demo-pill, .module-type, .research-place,
.pilot-grid article, .final-cta, .text-link { border-color: var(--line); }
.capabilities, .voice-section, .next-section { background: var(--section); }
.demo-sidebar, .customer-quote, .founder-avatar { background: var(--surface-alt); color: var(--ink); border-color: var(--line); }
.mini-brand { color: var(--ink); }
.module[open], .language-options a:hover, .language-options a[aria-current="page"] { background: var(--tint); }

.button.dark { background: var(--cta-bg); color: var(--cta-text); }
.button.dark:hover { background: var(--cta-hover); }
.card-three, .value-strip { background: var(--strong-bg); color: var(--strong-text); border-color: var(--line); }
.card-three small, .value-inner .section-index { color: var(--strong-text); }
.card-three .insight-icon { color: var(--strong-text); border-color: var(--line); }
.card-three .card-index { color: var(--strong-text); }
.value-inner p span, .large-arrow { color: var(--strong-text); }
.highlight::after { background: var(--highlight); }
:lang(en) .highlight, :lang(de) .highlight, :lang(fr) .highlight, :lang(es) .highlight {
  background: linear-gradient(transparent 77%, var(--highlight) 77%);
}
.scenario-tabs button[aria-selected="true"], .next-action { background: var(--orange-bg); color: var(--orange-text); border-color: var(--line); }
.next-action .small-label { color: var(--orange-text); }
.action-icon { background: var(--orange-solid); color: var(--orange-ink); }
.orbit > div { border-color: var(--muted); opacity: .45; }
.orbit-dot { background: var(--accent); box-shadow: none; }

dialog { background: var(--surface); color: var(--ink); border-color: var(--line); box-shadow: 0 24px 80px #0005; }
dialog::backdrop { background: #0e1513c9; }
dialog .secondary { color: var(--ink); border-color: var(--line); background: transparent; }
dialog .secondary:hover { background: var(--surface-alt); }
.language-options { box-shadow: 0 12px 36px #0003; }
.stage-top, .signal-track, .insight-card small, .card-index, .demo-label,
.cap-tag, .mini-brand span, .sidebar-caption, .sidebar-bottom, .sidebar-bottom div,
.demo-overline, .demo-pill, .customer-quote > span, .small-label, .demo-footer,
.value-inner .section-index, .research-top, .research-place, .founder div > span,
.pilot-grid article > span, .footer > span, .footer > span:last-child,
dialog .section-index, .module-number, .module summary small, .module-type { font-size: 10px; }
.research-note, .modules-note, .voice-note, .contact-address { font-size: 12px; }

@media (max-width: 1120px) { .header nav { display: none; } }
@media (max-width: 600px) {
  .header { gap: 10px; height: auto; min-height: 90px; padding-top: 20px; padding-bottom: 20px; flex-wrap: wrap; }
  .header-actions { gap: 8px; }
  .language-menu summary { padding: 10px; }
}
@media (max-width: 380px) {
  .header { padding-left: 16px; padding-right: 16px; gap: 6px; }
  .header .brand { font-size: 22px; }
  .brand-mark { margin-right: 6px; gap: 2px; }
  .header-actions { gap: 6px; }
  .language-menu summary { padding: 9px 8px; }
  .language-menu summary span { margin-left: 4px; }
}
@media print {
  :root[data-theme] { color-scheme: light; --paper: #fff; --ink: #242a32; --muted: #525b68; --surface: #fff; --surface-alt: #ebeced; --section: #f3f3f2; --line: #a5abb2; --tint: #e5d9ce; --accent: #8b4b23; --highlight: #dbc0a8; --strong-bg: #ebeced; --strong-text: #242a32; --orange-bg: #e5d9ce; --orange-text: #81431e; }
  .theme-control { display: none; }
}
