/* Three intentional looks: Crystal Light, Aurora Dark and Clear Minimal. */
.theme-switcher{position:fixed;right:22px;bottom:20px;z-index:500;display:flex;align-items:center;gap:4px;padding:7px;border:1px solid rgba(170,191,231,.65);border-radius:18px;background:rgba(255,255,255,.93);color:#304967;box-shadow:0 14px 46px rgba(30,51,92,.22),inset 0 1px #fff;backdrop-filter:blur(22px);font:600 12px/1.2 Inter,'DM Sans',system-ui,sans-serif;max-width:calc(100vw - 24px)}
.theme-switcher__label{font-size:9px;font-weight:850;letter-spacing:1px;color:#617797;padding:0 7px}
.theme-switcher [data-theme-choice]{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:35px;padding:7px 10px;border:0;background:transparent;color:#486183;border-radius:11px;box-shadow:none;transform:none;text-decoration:none;font:inherit;cursor:pointer;white-space:nowrap;transition:background .2s,color .2s,box-shadow .2s}
.theme-switcher [data-theme-choice]:hover{background:#e7edff;color:#223c73}
.theme-switcher [data-theme-choice][aria-pressed="true"]{background:linear-gradient(110deg,#5369e9,#9275ea);color:white;box-shadow:0 6px 17px rgba(83,103,236,.28)}
.theme-switcher [data-theme-choice]:focus-visible{outline:3px solid #26bcd3;outline-offset:3px}
.theme-switcher .theme-icon{font-size:14px;line-height:1}
html[data-theme="dark"]{background:#090f23;color:#ecf3ff;color-scheme:dark;--ink:#f0f5ff;--deep:#edf3ff;--mute:#afc0da;--outline:#304365;--glass:rgba(18,30,65,.85);--shadow:0 20px 65px rgba(0,0,0,.32)}
html[data-theme="dark"] body{background:radial-gradient(ellipse at 10% 5%,#1c2150 0,transparent 40%),radial-gradient(ellipse at 90% 20%,#102f47 0,transparent 44%),#0a1024;color:#eef4ff}
html[data-theme="dark"] .theme-switcher{background:rgba(17,26,54,.96);color:#f2f5ff;border-color:#5977ae}
html[data-theme="dark"] .theme-switcher__label{color:#d1deff}
html[data-theme="dark"] .theme-switcher [data-theme-choice]{color:#d2dffa}
html[data-theme="dark"] .theme-switcher [data-theme-choice]:hover{background:#293963;color:#fff}
/* Public landing: deep aurora glass, not an inverted screenshot. */
html[data-theme="dark"] .site-header{background:rgba(10,17,39,.84);border-color:#34476e}
html[data-theme="dark"] .brand-word,html[data-theme="dark"] .hero h1,html[data-theme="dark"] h2,html[data-theme="dark"] h3,html[data-theme="dark"] .capability h3,html[data-theme="dark"] .price-card h3{color:#f5f8ff}
html[data-theme="dark"] .nav-links>a,html[data-theme="dark"] .nav-signin{color:#d5e2ff}
html[data-theme="dark"] .hero-lead,html[data-theme="dark"] .section-intro p,html[data-theme="dark"] .split-intro p,html[data-theme="dark"] .capability p,html[data-theme="dark"] .journey-copy p,html[data-theme="dark"] .faq-section p{color:#bbcae3}
html[data-theme="dark"] .aura-a{background:radial-gradient(ellipse,#40377e 5%,#1c436b 52%,transparent 75%)}
html[data-theme="dark"] .aura-b{background:radial-gradient(ellipse,#15505c 6%,#222858 45%,transparent 77%)}
html[data-theme="dark"] .aura-c{background:radial-gradient(ellipse,#5e2e68,#263964 52%,transparent 74%)}
html[data-theme="dark"] .universe-glow{background:radial-gradient(circle,#283c74 1%,#182a55cd 35%,#35255f77 54%,transparent 75%)}
html[data-theme="dark"] .hero-core{background:linear-gradient(130deg,#172d55e8,#252347e8);border-color:#6b7ba877;box-shadow:0 30px 90px #0005,inset 0 1px #ffffff33}
html[data-theme="dark"] .hero-core strong,html[data-theme="dark"] .core-kicker{color:#e5eeff}
html[data-theme="dark"] .hero-core-bottom,html[data-theme="dark"] .float-tag,html[data-theme="dark"] .capability,html[data-theme="dark"] .price-card,html[data-theme="dark"] .diagram-inspector,html[data-theme="dark"] .journey-copy,html[data-theme="dark"] .showcase-frame{background:linear-gradient(135deg,rgba(24,38,75,.96),rgba(17,26,52,.95));border-color:#3c5182;color:#edf3ff}
html[data-theme="dark"] .float-tag b,html[data-theme="dark"] .layer-chip b,html[data-theme="dark"] .hero-credibility strong,html[data-theme="dark"] .mini-col,html[data-theme="dark"] .diagram-inspector b{color:#e5eeff}
html[data-theme="dark"] .hero-credibility small,html[data-theme="dark"] .float-tag,html[data-theme="dark"] .core-description{color:#b7c8ea}
html[data-theme="dark"] .btn-glass,html[data-theme="dark"] .btn-outline{background:#202f56;color:#ebf4ff;border-color:#49659e}
html[data-theme="dark"] .nav-links.open{background:#141f3de8;border-color:#3e5c91}
html[data-theme="dark"] .rail,html[data-theme="dark"] .footer,html[data-theme="dark"] .footer-group a,html[data-theme="dark"] .footer-identity p{color:#b7c8e6}
html[data-theme="dark"] .showcase-main,html[data-theme="dark"] .showcase-sidebar,html[data-theme="dark"] .mock-panel,html[data-theme="dark"] .mock-metric,html[data-theme="dark"] .system-node,html[data-theme="dark"] .test-visual,html[data-theme="dark"] .faq-item,html[data-theme="dark"] .plan-toggle,html[data-theme="dark"] .diagram-toolbar{background:#1a2b50;color:#edf4ff;border-color:#435a85}
html[data-theme="dark"] .mock-panel b,html[data-theme="dark"] .mock-metric b,html[data-theme="dark"] .system-node b,html[data-theme="dark"] .price-card strong{color:#eef5ff}
html[data-theme="dark"] .faq-question,html[data-theme="dark"] .faq-answer,html[data-theme="dark"] .price-card p{color:#c6d5eb}
/* Legal and trust pages: readable contrast and subdued surfaces. */
html[data-theme="dark"] .sitehead{background:#121e39ee;border-bottom-color:#3b5077}
html[data-theme="dark"] .identity,html[data-theme="dark"] .hero h1,html[data-theme="dark"] .paper h2,html[data-theme="dark"] .trustcard h2,html[data-theme="dark"] .trustcard h3{color:#f0f5ff}
html[data-theme="dark"] .hero p,html[data-theme="dark"] .paper p,html[data-theme="dark"] .paper li,html[data-theme="dark"] .trustcard p{color:#cbd7ed}
html[data-theme="dark"] .paper,html[data-theme="dark"] .sidenav,html[data-theme="dark"] .trustcard{background:#152543f5;border-color:#3b537e;box-shadow:0 15px 45px #0003;color:#f0f5ff}
html[data-theme="dark"] .paper section{border-color:#344769}
html[data-theme="dark"] .sidenav a{color:#d4e0f7}
html[data-theme="dark"] .sidenav a.active,html[data-theme="dark"] .sidenav a:hover,html[data-theme="dark"] .docnav a,html[data-theme="dark"] .pill{background:#273d67;color:#e7eeff;border-color:#506998}
html[data-theme="dark"] .disclaimer,html[data-theme="dark"] .status{background:#443521;color:#ffe8bd;border-color:#81623c}
html[data-theme="dark"] .toplinks a,html[data-theme="dark"] .foot a{color:#b9d3ff}
/* Clear Minimal: high-contrast text, stripped-back backgrounds and no decorative animation. */
html[data-theme="clear"]{background:#fff;color:#15243c;--ink:#15243c;--deep:#15243c;--mute:#455774;--shadow:none;--outline:#cbd6e3}
html[data-theme="clear"] body{background:#fff;color:#15243c}
html[data-theme="clear"] .ambient,html[data-theme="clear"] .aura,html[data-theme="clear"] .universe-glow,html[data-theme="clear"] .cta-orbits,html[data-theme="clear"] .cta-shimmer{display:none!important}
html[data-theme="clear"] .site-header,html[data-theme="clear"] .sitehead{background:#fff;border-bottom:1px solid #d9e0e9;backdrop-filter:none}
html[data-theme="clear"] .capability,html[data-theme="clear"] .price-card,html[data-theme="clear"] .diagram-inspector,html[data-theme="clear"] .journey-copy,html[data-theme="clear"] .showcase-frame,html[data-theme="clear"] .hero-core,html[data-theme="clear"] .float-tag,html[data-theme="clear"] .paper,html[data-theme="clear"] .sidenav,html[data-theme="clear"] .trustcard{background:#fff;box-shadow:none;border-color:#cbd6e3;backdrop-filter:none;color:#15243c}
html[data-theme="clear"] .theme-switcher{background:white;border-color:#bdcbdb;box-shadow:0 5px 20px #273a5c21;backdrop-filter:none}
html[data-theme="clear"] .hero-lead,html[data-theme="clear"] .paper p,html[data-theme="clear"] .paper li,html[data-theme="clear"] .hero p{color:#344660}
html[data-theme="clear"] .gradient-type{-webkit-text-fill-color:initial;background:none;color:#204cb7}
html[data-theme="clear"] .nav-links a,html[data-theme="clear"] .nav-signin{color:#243d64}
html[data-theme="clear"] .nav-links.open{background:white;border-color:#bdcbdb}
html[data-theme="clear"] .pill,html[data-theme="clear"] .docnav a{background:#edf3fb;border-color:#cbd6e3;color:#193b74}
html[data-theme="clear"]:not([data-app="studio"]) *,html[data-theme="clear"]:not([data-app="studio"]) *::before,html[data-theme="clear"]:not([data-app="studio"]) *::after{animation:none!important;transition-duration:0s!important}
@media(max-width:690px){.theme-switcher{left:12px;right:12px;bottom:max(12px, env(safe-area-inset-bottom));justify-content:center;padding:6px;gap:2px}.theme-switcher__label{font-size:9px;padding:0 5px}.theme-switcher [data-theme-choice]{padding:8px 7px;flex:1;font-size:11px}body{padding-bottom:62px}}
@media(max-width:360px){.theme-switcher__label{display:none}.theme-switcher [data-theme-choice]{padding:7px 6px}}
@media(prefers-reduced-motion:reduce){.theme-switcher *{transition:none!important}}
/* Authenticated workspace themes reuse the same preference. */
html[data-theme="dark"]{--navy:#f3f6ff;--text:#e5eaf6;--muted:#b4c5e1;--line:#364c73;--white:rgba(20,34,66,.89);--border:#50668a;--shadow:0 20px 70px #0005}
html[data-theme="dark"] body:before{background:radial-gradient(circle at 10% 12%,#233d6d,transparent 33%),radial-gradient(circle at 89% 12%,#38255f,transparent 26%),#0a1127}
html[data-theme="dark"] .sidebar{background:rgba(15,25,49,.96);border-color:#435b84}
html[data-theme="dark"] .sidebar-foot,html[data-theme="dark"] .nav-item.selected,html[data-theme="dark"] .glass{background:#1b2d51;border-color:#4b648c;color:#e6f2ff}
html[data-theme="dark"] .nav-item,html[data-theme="dark"] .muted-sm,html[data-theme="dark"] .top-left{color:#c1d0ea}
html[data-theme="dark"] .nav-item:hover{background:#273f6b}
html[data-theme="dark"] .btn:not(.primary),html[data-theme="dark"] .pill{background:#243b64;color:#edf5ff;border-color:#405b88}
html[data-theme="dark"] .main h1,html[data-theme="dark"] .main h2,html[data-theme="dark"] .main h3{color:#edf3ff}
html[data-theme="clear"]{--navy:#132849;--text:#253750;--muted:#4c5d74;--white:#fff;--border:#cbd6e3;--shadow:none;--line:#cdd8e4}
html[data-theme="clear"] body:before,html[data-theme="clear"] .aurora{display:none}
html[data-theme="clear"] .sidebar,html[data-theme="clear"] .glass,html[data-theme="clear"] .nav-item.selected,html[data-theme="clear"] .sidebar-foot{background:#fff;border-color:#d8e1eb;backdrop-filter:none;box-shadow:none}
/* Narrow phones: keep header controls and decorative overflow within the viewport. */
html{overflow-x:clip}
@media(max-width:390px){
  .topnav{gap:7px}
  .topnav .brand{gap:6px;min-width:0}
  .topnav .brand-mark{width:34px;height:34px;flex:none}
  .topnav .brand-word{font-size:16px;max-width:178px;letter-spacing:-.5px}
  .topnav .brand-word small{letter-spacing:1.15px;font-size:7px}
  .topnav .nav-actions{display:none}
  .topnav .menu-toggle{flex:none;order:2;margin-left:auto}
  .sitehead .top{gap:8px}
  .sitehead .identity{font-size:18px;gap:5px;flex-shrink:1;min-width:0}
  .sitehead .identity img{width:35px;height:35px}
  .sitehead .toplinks{margin-left:auto;gap:5px;flex-shrink:0}
  .sitehead .toplinks .pill{font-size:11px;padding:6px 9px}
}

/* Reserve room for the floating control so it never covers the final row of content. */
body:has(> .theme-switcher:not(.theme-switcher--inline)){padding-bottom:78px}
@media (max-width:640px){.theme-switcher:not(.theme-switcher--inline) .theme-switcher__label{display:none}.theme-switcher:not(.theme-switcher--inline) [data-theme-choice]{padding:7px 8px}}
