/* Complete semantic palettes. Layout and typography remain in styles.css. */
:root{--bg:#0b1015;--card:#101923;--inset:#1b2630;--hover:#1c2b37;--text:#f0f4f8;--muted:#a4b5c8;--border:#3c4e60;--accent:rgb(20 184 166 / var(--tw-bg-opacity, 1));--on-accent:#fff;--link:#65e5d3;--positive:#62deb0;--negative:#ff9299;--success-bg:#133d30;--danger-bg:#46232c;--warning-bg:#362c17;--warning-text:#f7df9a;--warning-border:#8b7136;--chart-grid:#364859;--chart-up:#62deb0;--chart-down:#ff9299;--shadow:0 12px 30px #0005;--header:rgba(10,15,20,.96);color-scheme:dark}
html[data-theme=light]{--bg:#f7fafb;--card:#fff;--inset:#edf3f6;--hover:#e4edf2;--text:#1f2b39;--muted:#506075;--border:#8799aa;--accent:rgb(20 184 166 / var(--tw-bg-opacity, 1));--on-accent:#fff;--link:var(--accent);--positive:#087344;--negative:#b32739;--success-bg:#e1f2e8;--danger-bg:#fae8ec;--warning-bg:#fff8df;--warning-text:#725300;--warning-border:#a68b39;--chart-grid:#b5c2cd;--chart-up:#087344;--chart-down:#b32739;--shadow:0 12px 30px #26374622;--header:rgba(247,250,251,.97);color-scheme:light}
html[data-theme] body{background:var(--bg);color:var(--text)}
html[data-theme=dark] body.admin{--bg:#0e1715;--card:#15221d;--inset:#1c2e26;--hover:#233d30;--text:#edf5f0;--muted:#b0c4b8;--border:#557363;--accent:rgb(20 184 166 / var(--tw-bg-opacity, 1));--link:#77e2ae;--positive:#77e2ae;--negative:#ff9299;--success-bg:#153b2a;--danger-bg:#46232c;--warning-bg:#362c17;--warning-text:#f7df9a;--warning-border:#8b7136;color-scheme:dark}
html[data-theme=light] body.admin{--bg:#f4f6f5;--card:#fff;--inset:#edf3ef;--hover:#e2ede6;--text:#222c27;--muted:#52645a;--border:#869b8f;--accent:rgb(20 184 166 / var(--tw-bg-opacity, 1));--link:#086b43;--positive:#0c6a30;--negative:#ae2838;--success-bg:#e5f3e9;--danger-bg:#fdebec;--warning-bg:#fff6db;--warning-text:#725300;--warning-border:#a68b39;color-scheme:light}
html[data-theme] .header{background:var(--header);border-color:var(--border)}
html[data-theme] .header nav a,html[data-theme] .header nav summary,html[data-theme] .header-actions button{color:var(--muted)}
html[data-theme] .header nav a.selected{color:var(--link)}
html[data-theme] button,html[data-theme] .button{color:var(--text);border-color:var(--border)}
html[data-theme] button:hover,html[data-theme] .button:hover{background:var(--hover)}
html[data-theme] .primary,html[data-theme] .header-actions .primary,html[data-theme] .avatar{background:var(--accent);border-color:var(--accent);color:var(--on-accent)}
html[data-theme] .primary:hover{filter:brightness(.92);background:var(--accent)}
html[data-theme] .panel,html[data-theme] .modal,html[data-theme] .support-panel,html[data-theme] .dropdown-menu{background:var(--card);border-color:var(--border);color:var(--text)}
html[data-theme] .why .panel{background:var(--card);border:1px solid var(--border)}
html[data-theme] .muted,html[data-theme] .stat p,html[data-theme] .page-top p,html[data-theme] .field small,html[data-theme] .check-label,html[data-theme] .empty,html[data-theme] .pagination{color:var(--muted)}
html[data-theme] .positive{color:var(--positive)}html[data-theme] .negative,html[data-theme] .danger{color:var(--negative)}
html[data-theme] input,html[data-theme] select,html[data-theme] textarea{background:var(--inset);color:var(--text);border-color:var(--border)}
html[data-theme] input::placeholder,html[data-theme] textarea::placeholder{color:var(--muted);opacity:1}
html[data-theme] :focus-visible{outline:3px solid var(--link);outline-offset:3px}
html[data-theme] input:focus,html[data-theme] select:focus,html[data-theme] textarea:focus{border-color:var(--link)}
html[data-theme] .tabs button{background:var(--inset);border-color:var(--border);color:var(--muted)}
html[data-theme] .tabs button.active{background:var(--accent);color:var(--on-accent);border-color:var(--accent)}
html[data-theme] .tabs.outline button.active{background:var(--success-bg);color:var(--link);border-color:var(--link)}
html[data-theme] .tabs.outline button.active .muted{color:inherit}
html[data-theme] .link-button,html[data-theme] .teal-outline,html[data-theme] .icon-box{color:var(--link)}
html[data-theme] .link-button{border-color:transparent}
html[data-theme] .teal-outline{border-color:var(--link)}
html[data-theme] .icon-box{background:var(--success-bg)}
html[data-theme] .table-wrap,html[data-theme] .account-link,html[data-theme] .book .mid,html[data-theme] .footer-bottom{border-color:var(--border)}
html[data-theme] th{background:var(--inset);color:var(--muted);border-color:var(--border)}
html[data-theme] td{border-color:var(--border)}html[data-theme] tbody tr:hover{background:var(--hover)}
html[data-theme] .pill{background:var(--inset);border-color:var(--border);color:var(--muted)}
html[data-theme] .badge{background:var(--success-bg);color:var(--positive)}
html[data-theme] .badge.red{background:var(--danger-bg);color:var(--negative)}
html[data-theme] .badge.amber,html[data-theme] .notice{background:var(--warning-bg);color:var(--warning-text);border-color:var(--warning-border)}
html[data-theme] .fund-info,html[data-theme] .inline-summary,html[data-theme] .bubble{background:var(--inset);color:var(--text)}
html[data-theme] .fund-info p{color:var(--muted)}html[data-theme] .fund-info .positive{color:var(--positive)}
html[data-theme] .bubble.self{background:var(--success-bg);color:var(--text)}
html[data-theme] .score-number{color:var(--positive)}html[data-theme] .score-bar{background:var(--inset)}
html[data-theme] .score-bar span{background:var(--positive)}html[data-theme] .score-panel h4{color:var(--muted);border-color:var(--border)}
html[data-theme] .upload-box{border-color:var(--border);color:var(--muted)}
html[data-theme] .ticker{background:var(--inset);border-color:var(--border);position:relative}
html[data-theme] .ticker-card{background:var(--card);color:var(--text);border-color:var(--border)}
html[data-theme] .ticker-name,html[data-theme] .ticker-code{color:var(--muted)}
html[data-theme] .quant-intro{background:var(--inset);color:var(--text)}
html[data-theme] .quant-content .panel{background:var(--card);border-color:var(--border)}
html[data-theme] .quant-network{color:var(--positive)}
html[data-theme] .footer{background:var(--inset);color:var(--muted)}
html[data-theme] .auth .demo-help{background:var(--success-bg);color:var(--text);border-color:var(--border)}
html[data-theme] .fav{color:var(--muted);border:0;min-width:32px;min-height:32px}
html[data-theme] .fav.on{color:var(--link)}.fav.on .icon{fill:currentColor}
html[data-theme] .support-fab{background:var(--accent);color:var(--on-accent)}
html[data-theme] .support-fab .icon{color:inherit}
html[data-theme] .admin-header{background:var(--card);border-color:var(--border)}
html[data-theme] .admin-header button{background:var(--card);color:var(--text)}
html[data-theme] .admin h1,html[data-theme] .admin .stat strong{color:var(--positive)}
html[data-theme] .admin .table-wrap{background:var(--card)}
html[data-theme] .admin .customers-table td:last-child{background:var(--card)}
html[data-theme] .admin .customers-table th:last-child{background:var(--inset)}
html[data-theme] .admin .dashboard-help{color:var(--muted)}
.icon{display:inline-block;flex:none;vertical-align:middle;pointer-events:none}.icon-box .icon{width:24px;height:24px}
.sidebar-icon{color:inherit}.sidebar details summary>.icon:first-child{margin-right:0}.sidebar details summary>.icon:last-child{margin-left:auto}
.header-actions>.dropdown{flex:none}.header-actions button:has(>.icon:only-child),.mobile-menu{min-width:40px;min-height:40px}
.theme-picker summary{display:flex;align-items:center;justify-content:center;min-width:40px;min-height:40px;cursor:pointer;list-style:none;border-radius:8px;color:var(--muted)}
.theme-picker summary::-webkit-details-marker{display:none}.theme-picker .dropdown-menu{left:auto;right:0;min-width:170px;padding:8px}
.theme-picker button{display:flex;width:100%;gap:10px;justify-content:flex-start;border:0;min-height:42px}
.theme-picker button[aria-pressed=true]{background:var(--success-bg);color:var(--link)}
.motion-control{position:absolute;right:12px;bottom:10px;z-index:3;background:var(--card)!important;color:var(--text)!important;min-width:36px;min-height:36px;padding:7px;border:1px solid var(--border)!important;box-shadow:0 2px 10px #0003}
.hero-motion-control{bottom:18px;right:18px;background:#0b2029!important;color:#fff!important;border-color:#72919d!important}
.hero .demo-tag{position:absolute;right:18px;top:18px;z-index:3;background:#0b2029e6;color:#e9f7f4;border:1px solid #72919d;border-radius:6px;padding:5px 9px;font-size:11px}
.ticker .motion-control{bottom:7px}.ticker-track{padding-right:0}.ticker-group{padding-right:12px}
html[data-motion-paused=true] body:not(.market-page) .ticker-track{animation-play-state:paused}
.chart-grid{stroke:var(--chart-grid)}.chart-label{fill:var(--muted)}.chart-up{stroke:var(--chart-up);fill:var(--chart-up)}.chart-down{stroke:var(--chart-down);fill:var(--chart-down)}
.book td:last-child{background:none!important}.book .positive{background:color-mix(in srgb,var(--positive) 9%,transparent)!important}.book .negative{background:color-mix(in srgb,var(--negative) 9%,transparent)!important}
.hero-copy{pointer-events:none}.hero-copy a,.hero-copy button{pointer-events:auto}
@media(max-width:760px){.header-actions button:has(>.icon:only-child),.theme-picker summary,.mobile-menu{min-width:36px;min-height:40px;padding:7px}.theme-picker{position:static}.theme-picker .dropdown-menu{position:absolute;right:10px;top:60px}.theme-picker .dropdown-menu button{min-height:44px}.header .dropdown-menu button{font-size:14px}.sidebar details summary{min-height:44px}.support-fab{min-width:56px;min-height:56px}.admin-header .theme-picker{position:relative}.admin-header .theme-picker .dropdown-menu{top:40px;right:0}.motion-control{right:8px}.hero .demo-tag{top:12px;right:12px;font-size:10px}}
@media(prefers-reduced-motion:reduce){.ticker-track{animation:none!important}html{scroll-behavior:auto}*{scroll-behavior:auto!important}}

html[data-theme] .prototype-label{background:var(--card);color:var(--muted);border:1px solid var(--border)}
html[data-theme] .header nav summary{display:flex;align-items:center;gap:4px}
@media(prefers-reduced-motion:reduce){html[data-motion-paused=false] body:not(.market-page) .ticker-track{animation:ticker-scroll 45s linear infinite!important}}

.ticker-source{position:absolute;bottom:0;left:8px;font-size:9px;line-height:12px;color:var(--muted);background:var(--card);padding:0 4px;border-radius:3px}.quote-source{margin-top:5px}

.google-button:before{content:none}
@media(max-width:1050px){.quote-row{flex-wrap:wrap;gap:16px}.quote-stats{display:flex;overflow:auto;max-width:100%;width:100%;gap:20px;padding:6px 0}.quote-stats>div{flex:none;min-width:85px}.quote-stats p{white-space:nowrap}}
