/* Appearance tokens also color the existing animation without restarting it. */
:root{
  color-scheme:dark;
  --page-bg:#101113;--text:#fff;--soft-text:#b6bbc0;
  --panel:#17191c;--theme-border:#ffffff26;--theme-hover:#ffffff10;
  --theme-focus:#c8e1f0;--particle-filter:none;--particle-blend:normal;--particle-opacity:1;
}
:root[data-theme="light"]{
  color-scheme:light;
  --page-bg:#f3f0e7;--text:#20211f;--muted:#353630;--soft-text:#606159;
  --line:#25262026;--panel:#eae6db;--theme-border:#25262038;--theme-hover:#2526200c;
  --theme-focus:#665e43;--particle-filter:invert(1) grayscale(1);--particle-blend:multiply;--particle-opacity:.34;
}
:root{background:var(--page-bg);color:var(--text)}
.brain-scene{background-color:var(--page-bg)}
.brain-scene canvas{filter:var(--particle-filter);mix-blend-mode:var(--particle-blend);opacity:var(--particle-opacity)}
.theme-toggle{display:flex;align-items:center;justify-content:center;flex-shrink:0;width:36px;height:44px;padding:0;border:0;border-radius:6px;background:transparent;color:var(--text);cursor:pointer}
.theme-toggle:hover{background:var(--theme-hover)}
.theme-toggle:focus-visible{outline:2px solid var(--theme-focus);outline-offset:3px}
.theme-toggle svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.theme-toggle .theme-moon{display:none}
[data-theme="light"] .theme-toggle .theme-moon{display:block}
[data-theme="light"] .theme-toggle .theme-sun{display:none}
/* Existing dark colors stay intact; the light palette covers all page and form surfaces. */
[data-theme="light"] :is(.site-header nav,.site-header nav a:hover,.text-link:hover,.muted,.hero .eyebrow,.tags span,.question-list span,.fine-note,.ongoing h3 span,.story-copy p,.story-copy .story-signoff,.contact-bottom p,footer,footer .brand){color:var(--text)}
[data-theme="light"] :is(.header-contact,.text-link){border-color:#79766b}
[data-theme="light"] .mobile-menu{background:var(--panel)}
[data-theme="light"] .language-switch>a{color:var(--soft-text)}
[data-theme="light"] .language-switch>a:hover{color:var(--text);background:var(--theme-hover)}
[data-theme="light"] .language-switch>a[aria-current="page"]{color:var(--text)}
[data-theme="light"] .language-switch>span{color:#77766d}
[data-theme="light"] .button{background:#252621;color:#f7f4ec}
[data-theme="light"] .button:hover{background:#43443b}
[data-theme="light"] :is(a,button):focus-visible{outline-color:var(--theme-focus)}
[data-theme="light"] .skip{background:#252621;color:#f7f4ec}
[data-theme="light"] .intake-dialog{background:var(--page-bg);color:var(--text);border-color:var(--theme-border);color-scheme:light;box-shadow:0 24px 80px #25262026}
[data-theme="light"] .intake-dialog::backdrop{background:#29282066}
[data-theme="light"] :is(.intake-close,.intake-intro,.intake-hint,.intake-privacy,.field-help,.intake-brand span,.intake-back){color:var(--soft-text)}
[data-theme="light"] .intake-close:hover{color:var(--text)}
[data-theme="light"] :is(.intake-brand span,.intake-actions){border-color:var(--theme-border)}
[data-theme="light"] .intake-track span{background:#25262026}
[data-theme="light"] .intake-track .active{background:#575846;box-shadow:none}
[data-theme="light"] .intake-dialog :is(input,textarea,select){background:#faf7ef;color:var(--text);border-color:#8f8d81}
[data-theme="light"] .intake-dialog :is(input,textarea,select):hover{border-color:#5f6056}
[data-theme="light"] .intake-dialog :is(input,textarea,select):focus{background:#faf7ef;outline-color:var(--theme-focus);border-color:var(--theme-focus);box-shadow:0 0 0 3px #665e431a}
[data-theme="light"] .intake-dialog input::placeholder{color:#717268}
[data-theme="light"] .intake-setup{background:var(--panel);color:var(--soft-text);border-color:var(--theme-border)}
/* The same static pattern adapts to the light palette. */
[data-theme="light"]:is(.brain-unavailable,.brain-reduced,.brain-static) .brain-scene{background:radial-gradient(ellipse 70% 75% at 78% 48%,#e3ded2 0%,var(--page-bg) 100%)}
[data-theme="light"]:is(.brain-unavailable,.brain-reduced,.brain-static) .brain-scene::after{filter:brightness(0);opacity:.12}
@media(max-width:700px){
  .header-actions{gap:8px}
}
@media(max-width:380px){
  .header-actions{gap:4px}
  .site-header .menu-toggle{font-size:0;width:32px;height:44px;gap:0;align-items:center;justify-content:center}
  .site-header .menu-toggle span{font-size:1.25rem}
}
