/* Shared theme control and deliberate light surfaces. Purple remains the brand color. */
.theme-switch{display:inline-flex;align-items:center;justify-content:center;gap:6px;flex:none;min-height:32px;padding:7px 9px;border:1px solid #b498ef30;border-radius:7px;background:#b499fb08;color:#d7cbf0;font:500 11px/1.2 'Segoe UI','Microsoft YaHei',sans-serif;cursor:pointer;white-space:nowrap}
.theme-switch svg{display:block;width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.theme-switch:hover{background:#9b7ada24}.theme-switch:focus-visible{outline:2px solid #9b73e9;outline-offset:3px}
html:root[data-theme=light]{color-scheme:light;--bg:#faf9fd;--panel:#fff;--panel2:#f3f0fa;--surface:#fff;--border:#e9e4f1;--line:#e9e4f1;--text:#241c37;--muted:#71677f;--purple:#7042c1;--green:#14765b;--red:#b53a56;--gold:#856020}
html:root[data-theme=light] body{background:var(--bg);color:var(--text)}
html:root[data-theme=light] :is(.hub,.mobile-app){--hub-accent:#7042c1;--hub-border:#e5deef;color:var(--text)}
html:root[data-theme=light] :is(.theme-switch,.language-switch){background:#ffffffb3;color:#625073;border-color:#ded5eb}
html:root[data-theme=light] :is(.theme-switch,.language-switch):hover{background:#eee7fa;color:#492183}
html:root[data-theme=light] :is(.header,.header.scrolled,.topbar,.mobile-topbar){background:#ffffffeb;backdrop-filter:blur(20px);border-color:var(--border);box-shadow:0 1px 0 #43305709}
html:root[data-theme=light] .sidebar{background:#fdfcfe;border-color:var(--border)}
html:root[data-theme=light] :is(.brand-wordmark,.brand-home,.mobile-wordmark,.brand-home b,.footer-brand){color:#2e2043}
html:root[data-theme=light] :is(.wordmark-ultra,.mobile-wordmark>span:last-child){color:#6c5785}
html:root[data-theme=light] :is(.header nav a,.brand-auth-link,.admin-entry){color:#60536e}
html:root[data-theme=light] :is(.header nav a:hover,.brand-auth-link:hover,.admin-entry:hover){color:#7042c1}
html:root[data-theme=light] :is(.button.primary,.nav-cta,.hero .button.primary,.brand-register){background:linear-gradient(115deg,#6740ba,#8858d6);color:#fff;border-color:#7547c0;box-shadow:0 6px 20px #7042c11c}
html:root[data-theme=light] :is(.button.primary:hover,.nav-cta:hover){background:linear-gradient(115deg,#5932a9,#7d4bc9);color:#fff}
html:root[data-theme=light] :is(.button.secondary,.button.ghost,.watch-button){background:#ffffffa8;color:#624780;border-color:#ded5e9}
html:root[data-theme=light] :is(.button.danger,.negative,.form-error){color:#b53a56}
html:root[data-theme=light] .positive{color:#14765b}
html:root[data-theme=light] :is(input,select,textarea){background:#fff;color:#2c213d;border-color:#dcd5e7;accent-color:#7648c7}
html:root[data-theme=light] :is(input,textarea)::placeholder{color:#82768e}
html:root[data-theme=light] :is(.panel,dialog,.strategy-card,.composer){background:#fff;border-color:var(--border);color:var(--text);box-shadow:0 6px 22px #3e255306}
html:root[data-theme=light] :is(dialog,#film-dialog,#plan-dialog){box-shadow:0 22px 90px #34244828}
html:root[data-theme=light] dialog::backdrop{background:#21173145}
html:root[data-theme=light] #toast{background:#fff;color:#3d2954;border-color:#d5c4ec;box-shadow:0 10px 40px #44305520}
html:root[data-theme=light] :is(.status.active,.status.approved,.status.success,.status.visible,.status.resolved,.hub-badge.ready){color:#166c51;background:#eaf7f0;border-color:#c8e8d8}
html:root[data-theme=light] :is(.status.paused,.status.pending,.status.open,.hub-badge.preview){color:#855c16;background:#fcf4df;border-color:#f0dfb5}
html:root[data-theme=light] :is(.status.failed,.status.rejected,.status.suspended,.status.hidden,.status.blocked){color:#a6304a;background:#ffedf0;border-color:#efcad2}
html:root[data-theme=light] :is(.tabs button.active,.segmented button.active,.feed-tabs button.active,.market-filter button.active,.range-filter button.active){color:#6635aa}
html:root[data-theme=light] :is(nav a.active,.mobile-bottom-nav a.active){color:#6d3fb9;background:#7544bb0c;box-shadow:none}
html:root[data-theme=light] :is(.data-table th,.hub-map-toolbar){background:#f5f1fa;color:#6e5c7f}
html:root[data-theme=light] .data-table td{color:#51435f}
html:root[data-theme=light] :is(.hub-welcome,.hub-map-intro,.studio-policy,.mascot-panel){background:radial-gradient(ellipse at 90% 60%,#dfd0f950,transparent 65%),#f7f4fc;border-color:#e5dced}
html:root[data-theme=light] :is(.hub-launch,.hub-feature,.hub-stats>div){background:#fff;border-color:var(--border)}
html:root[data-theme=light] :is(.hub-launch:hover,.hub-feature:hover){background:#f6f1fc;border-color:#c9b4e6}
html:root[data-theme=light] .hub-savebar{background:#ffffffed;border-color:#dacbea;box-shadow:0 8px 35px #37214d10}
html:root[data-theme=light] .hub-orbit>div{background:linear-gradient(140deg,#4f287e,#8857c9 55%,#5a3a93);background-clip:text;color:transparent}
html:root[data-theme=light] :is(.mascot-panel img,.mascot-wrap img){filter:none;mix-blend-mode:multiply;opacity:.9}
html:root[data-theme=light] :is(.sparkline path[stroke],.chart path[stroke]){stroke:#8659cc}
/* Homepage: a continuous pearl-and-lavender space, with the approved 3D UP. */
html:root[data-theme=light][data-surface=brand] body::before{background:radial-gradient(ellipse at 70% 12%,#ded0f440,transparent 42%),linear-gradient(180deg,#fff,#faf8fd 60%,#fff)}
html:root[data-theme=light][data-surface=brand] :is(.hero,.nebula-scene){background:transparent;background-image:none}
html:root[data-theme=light][data-surface=brand] .hero-shade{background:radial-gradient(ellipse at 50% 72%,#ad86e72b,transparent 36%),linear-gradient(180deg,#fff0 60%,#faf9fd)}
html:root[data-theme=light][data-surface=brand] #aurora{opacity:.07;mix-blend-mode:multiply}
html:root[data-theme=light][data-surface=brand] .hero h1{color:#2c203e}
html:root[data-theme=light][data-surface=brand] .hero h1 span{background-image:linear-gradient(110deg,#604193,#8c59c8 60%,#6847c3);background-clip:text;color:transparent}
html:root[data-theme=light][data-surface=brand] :is(.hero-copy,.hero-coordinate,.hero-coordinate b,.logo-stage-caption,.free-brand-note,.scroll-cue){color:#78648d}
html:root[data-theme=light][data-surface=brand] .free-brand-note a{color:#7244b6}
html:root[data-theme=light][data-surface=brand] :is(.portal-card,.workspace,.workspace-top,.step,.step:first-child,.community-feed,.community-band,.market-ribbon,footer){background:transparent;border:0;box-shadow:none}
html:root[data-theme=light][data-surface=brand] :is(.portal-card:hover,.workspace:hover){background:transparent;border:0;box-shadow:none}
html:root[data-theme=light][data-surface=brand] :is(.platform-proof-grid strong,.portal-go,.manifesto h2,.closing h2){color:#402956}
html:root[data-theme=light][data-surface=brand] .manifesto h2 span{color:#8a759d}
html:root[data-theme=light][data-surface=brand] .closing h2 span{color:#7a4abc}
html:root[data-theme=light][data-surface=brand] :is(.platform-proof small,.portal-note,.data-notice,.portal-tags){color:#796b88}
html:root[data-theme=light][data-surface=brand] .strategy-card{background:transparent;box-shadow:none}
html:root[data-theme=light][data-surface=brand] .strategy-card.selected{background:#eee6f8;color:#5f329d}
html:root[data-theme=light][data-surface=brand] .chart-grid path{stroke:#4c336217}
html:root[data-theme=light][data-surface=brand] #chart-path{stroke:#8151c5}
html:root[data-theme=light][data-surface=brand] .closing-word{color:#7144ab08;text-shadow:none}
html:root[data-theme=light][data-surface=brand] .closing{background:radial-gradient(ellipse at 50% 100%,#bba0dc24,transparent 70%)}
/* Mobile keeps the existing open, unboxed layout. */
html:root[data-theme=light][data-surface=mobile] .mobile-cosmos{background:radial-gradient(ellipse at 75% 16%,#e4d6fa70,transparent 48%),linear-gradient(180deg,#fff,#faf8fd)}
html:root[data-theme=light][data-surface=mobile] :is(.mobile-device,.mobile-device::before,.m-feature-banner){background:transparent;border:0;box-shadow:none}
html:root[data-theme=light][data-surface=mobile] .mobile-environment{background:#eee8f680;color:#7a668d}
html:root[data-theme=light][data-surface=mobile] .mobile-bottom-nav{background:#fffefdf0;border-top:1px solid #e9e2f1}
html:root[data-theme=light][data-surface=mobile] :is(.panel,.m-account-glance,.m-market-strip>a,.m-signal-card,.post,.m-profile-promo,.m-menu,.m-notice-card,.m-follow-gate,.hub-map-intro,.hub-feature,.studio-policy,.fee-note,.hub-notice,.m-shortcuts a>span,.account){background:transparent;border:0;box-shadow:none}
html:root[data-theme=light][data-surface=mobile] :is(.m-platform-proof-grid strong,.m-home-intro h1,.m-feature-banner h2){color:#392448}
html:root[data-theme=light][data-surface=mobile] :is(.m-mini-label,.m-feature-banner a,.m-shortcuts a>span){color:#8055ad}
html:root[data-theme=light][data-surface=mobile] :is(.m-platform-proof-grid span,.m-platform-proof>p,.mobile-footer){color:#7c6b8b}
html:root[data-theme=light][data-surface=mobile] .m-compose-prompt{background:#f0eaf8;color:#796789;border-color:#e4d9ee}
@media(max-width:1100px){.header-actions{gap:9px}.header nav{gap:17px}}
@media(max-width:700px){.theme-switch{padding:7px;width:31px;min-height:31px}.theme-switch span{display:none}.header .header-actions{gap:6px}.header .brand .brand-wordmark{font-size:16px}.header .brand .brand-emblem{width:30px;height:30px;flex-basis:30px}.mobile-top-actions{gap:4px}.mobile-app .theme-switch{border:0;background:transparent}.top-actions{gap:8px}}
@media(max-width:380px){.header .brand .brand-wordmark{font-size:14px}.header .brand .brand-emblem{width:26px;height:26px;flex-basis:26px}.header .brand-register{padding:7px;font-size:10px}.header .language-switch{padding:6px}.header .brand-auth-link{font-size:10px}.header .header-actions{gap:4px}.mobile-wordmark>span:last-child{font-size:12px}.mobile-topbar{gap:8px}.mobile-top-actions{gap:2px}}
