:root{color-scheme:light}
:root[data-theme=dark]{color-scheme:dark;--bg:#071322;--panel:#10243a;--ink:#edf5ff;--navy:#edf5ff;--muted:#a6bad1;--line:#29415c;--accent:#80b3ff;--teal:#49ded0}
.site-header nav,.member-header nav{flex-wrap:wrap}
.theme-toggle,.member-header .theme-toggle{display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;min-height:40px;padding:9px 13px;border:1px solid var(--line);border-radius:24px;background:var(--panel);color:var(--ink);font:600 13px var(--sans, sans-serif);cursor:pointer;white-space:nowrap}
.theme-toggle:hover{border-color:var(--accent)}
.theme-toggle:focus-visible{outline:3px solid var(--accent);outline-offset:4px}
html[data-theme=dark] body{background:radial-gradient(ellipse at 95% 0,#10354460,transparent 42%),var(--bg);color:var(--ink)}
html[data-theme=dark] :is(.site-header,.member-header,footer,.interest-row,.admin-card-action){border-color:var(--line)}
html[data-theme=dark] :is(.path-card,.path-card:nth-child(n),.project-card,.contact-form,.member-card,.admin-section-card,.checker-console,.checker-result-card,.tool-feature,dialog,.admin-dialog,.sandbox-session:fullscreen){background:#0e2035;color:var(--ink);border-color:var(--line);box-shadow:0 18px 55px #0002}
html[data-theme=dark] :is(.page-intro>p,.path-card p,.interest-row p,.contact-aside>p,.contact-note p,.field-hint,.form-privacy,#project-count,#dialog-description,.tool-feature-copy p,.tools-footnote,.checker-about p,.checker-result-card p,.checker-results-heading p,.checker-result-card dt,.checker-modes small,.checker-actions [role=status],#sandbox-results figcaption,#sandbox-view-status,#sandbox-protection-status,.admin-home-note,.person-identity>span,.member-usage-strip>div,.admin-empty,.log-record time){color:var(--muted)}
html[data-theme=dark] :is(.path-action,.path-number,.eyebrow,.page-intro>.eyebrow,.member-main .eyebrow,.member-main summary,.member-main .quiet,.admin-breadcrumb a,.admin-card-action,.admin-home-footer a,.admin-footnote a,.checker-back,#dialog-category,nav a[aria-current=page],.contact-aside h2 em){color:#81c6ff}
html[data-theme=dark] :is(.page-intro h1 em,.section-heading h2 span){background-image:linear-gradient(95deg,#8ab5ff,#49ded0)}
html[data-theme=dark] :is(.field input,.field select,.field textarea,.member-main input,.member-main select){background:#071727;color:var(--ink);border-color:#3c5875}
html[data-theme=dark] :is(input,textarea)::placeholder{color:#91a6bf}
html[data-theme=dark] :is(.stat,.result-grid>div,.secret,.checker-note,.sandbox-verdict,#sandbox-results blockquote,.admin-owner-note,.feature-limits,.admin-section-nav,.log-tabs,.log-label,.tool-tags span,.checker-badge,.admin-section-icon,.admin-section-card:nth-child(2n) .admin-section-icon,.person-avatar){background:#173049;color:#c7dfef;border-color:var(--line)}
html[data-theme=dark] :is(.project-details,.project-filters button,.checker-secondary,.member-main button,.member-main .action-link,.member-header button,.dialog-close,.nav-login,.motion-toggle){background:#173049;color:#d0e5ff;border-color:#3c5875}
html[data-theme=dark] :is(.button-primary,.member-main .primary){background:linear-gradient(115deg,#205ce5,#087c98);color:#fff}
html[data-theme=dark] :is(.project-filters button[aria-pressed=true],.admin-section-nav a[aria-current],.member-main .log-tabs button[aria-pressed=true],.checker-modes label:has(input:checked)){background:#254b70;color:#fff;border-color:#80b3ff}
html[data-theme=dark] :is(.admin-section-nav a,.admin-nav #admin-dropdown a,.member-main legend,.member-usage-strip strong){color:#c7dff7}
html[data-theme=dark] .admin-nav #admin-dropdown{background:#10243a;border-color:var(--line)}
html[data-theme=dark] :is(.external-links a:hover,.admin-nav #admin-dropdown a:hover,.admin-nav #admin-dropdown a[aria-current],.member-main button.person-row[aria-current]){background:#203c58;color:#fff}
html[data-theme=dark] :is(.badge,.person-state.active,#notice:not(:empty)){background:#113c3b;color:#92f1d6;border-color:#36736b}
html[data-theme=dark] :is(#notice.error,.member-main .danger,.sandbox-verdict[data-level=high]){background:#3c202d;color:#ffb6c3;border-color:#875163}
html[data-theme=dark] :is(.log-error,.badge-paused,.sandbox-verdict[data-level=suspicious]){background:#3c3020;color:#f4d295;border-color:#846b42}
html[data-theme=dark] :is(#contact-status[data-state=error],.checker-actions [data-state=error],#sandbox-form [data-state=error],.admin-dialog #invite-status){color:#ffb6c3}
html[data-theme=dark] #contact-status[data-state=success]{color:#92f1d6}
/* Keep original logo artwork and QR codes on their intended light surfaces. */
html[data-theme=dark] .mfa-qr canvas{background:#fff;border-radius:8px}
html[data-theme=dark] .brand-symbol{background:#f8faff;border-radius:7px}
html[data-theme=dark] .brand-symbol img{mix-blend-mode:normal}
html[data-theme=dark] .nav-github{background:#173049;color:#edf5ff;border-color:#3c5875}
html[data-theme=dark] :is(.coding-workspace,.chat-composer textarea,.chat-attachment-info strong){color:var(--ink)}
html[data-theme=dark] :is(.chat-shell,.chat-toolbar,.chat-settings>div,.chat-drawer,.chat-chat-item,.studio-page .chat-composer){background:#0e2035;border-color:var(--line)}
html[data-theme=dark] :is(.studio-page .coding-workspace button,.studio-page .coding-workspace .action-link,.chat-settings summary,.studio-page .chat-attach-button,.chat-message.user,.chat-attachment,.chat-inline-code,.chat-text code){background:#173049;color:#d0e5ff;border-color:var(--line)}
html[data-theme=dark] .studio-page .coding-workspace .primary{background:#205ce5;color:white}
html[data-theme=dark] :is(.chat-eyebrow,#studio-state,.chat-chat-empty,.chat-chat-meta,.chat-search-results,.chat-starters span,.chat-perf-note,.chat-working,.chat-attachment-info span,#studio-context,.chat-footer){color:var(--muted)}
html[data-theme=dark] .chat-chat-select{color:var(--ink)!important}
html[data-theme=dark] :is(.chat-warning,#studio-feedback){color:#f4d295!important}
html[data-theme=dark] :is(.chat-message-heading,.chat-text a,.chat-heading h1 span){color:#66dfd4}
@media(max-width:700px){.site-header nav,.member-header nav{gap:12px}.site-header,.member-header{height:auto;min-height:100px;gap:18px;padding-top:20px;padding-bottom:20px}.theme-toggle{min-height:40px}}
