:root { --surface:#fff; --surface-soft:#f4f7f6; --ink:#172b3a; --muted:#526579; --line:#dce5e1; --green-soft:#edf8f0; }
html[data-theme="dark"] { --surface:#142538; --surface-soft:#0d1c2c; --ink:#e8f0f6; --muted:#afc0ce; --line:#304457; --green-soft:#183c32; --background-color:#0b1725; --text-color:#e8f0f6; }
.theme-picker { display:flex; align-items:center; gap:5px; padding:7px 9px; border:1px solid var(--line); border-radius:999px; background:var(--surface); color:var(--ink); }
.theme-picker select { background:transparent; color:inherit; border:0; font-size:12px; cursor:pointer; max-width:85px; }
.theme-picker option { background:var(--surface); color:var(--ink); }
#site-navigation { background:var(--surface); border-color:var(--line); }
#site-navigation .mega-menu { background:var(--surface); border-color:var(--line); }
#site-navigation .mega-link strong { color:var(--ink); }
#site-navigation .mega-link small { color:var(--muted); font-size:12px; line-height:1.5; }
#site-navigation .mega-link:hover, #site-navigation .mega-link:focus-visible { background:var(--green-soft); border-color:#268440; }
#site-navigation button[aria-expanded="true"] { color:#268440; background:var(--green-soft); }
#mobile-navigation { max-height:calc(100dvh - 105px); overflow-y:auto; }
html[data-theme="dark"] body { background:var(--background-color); color:var(--ink); }
html[data-theme="dark"] :is(.bg-white, .bg-white\/95) { background-color:var(--surface); }
html[data-theme="dark"] :is(.bg-gray-50,.bg-gray-100,.bg-slate-50,.bg-slate-100,.bg-green-50,.bg-orange-50,.bg-blue-50,.bg-\[\#f7faf8\]) { background-color:var(--surface-soft); }
html[data-theme="dark"] :is(.text-gray-900,.text-gray-800,.text-gray-700,.text-slate-900,.text-slate-800,.text-slate-700) { color:var(--ink); }
html[data-theme="dark"] :is(.text-gray-600,.text-gray-500,.text-slate-600,.text-slate-500) { color:var(--muted); }
html[data-theme="dark"] :is(.border-gray-100,.border-gray-200,.border-gray-300,.border-slate-100,.border-slate-200) { border-color:var(--line); }
html[data-theme="dark"] :is(input,textarea,select) { color-scheme:dark; }
html[data-theme="dark"] main :is(input,textarea,select):not([type="submit"]):not([type="checkbox"]):not([type="radio"]) { background-color:var(--surface); color:var(--ink); }
html[data-theme="dark"] .nav-logo { background:#fff; padding:4px 8px; }
html[data-theme="dark"] :is(.from-white,.from-gray-50,.from-slate-50) { --tw-gradient-from:var(--surface); --tw-gradient-to:rgb(20 37 56 / 0); }
html[data-theme="dark"] :is(.to-white,.to-gray-50,.to-slate-50) { --tw-gradient-to:var(--surface-soft); }
html[data-theme="dark"] :is(.hover\:bg-gray-50,.hover\:bg-gray-100):hover { background-color:var(--surface-soft); }
@media(max-width:639px) { .theme-picker { padding:6px; } .theme-picker select { font-size:12px!important; } }

html[data-theme="dark"] #site-navigation :is(.text-\[\#268440\], button[aria-expanded="true"]) { color:#7bdd9a; }
html[data-theme="dark"] #site-navigation .mega-kicker { color:#ffb16e; }
