/* Optional evening palette. Original game artwork keeps its authored colors. */
.header nav{align-items:center;gap:20px}
.theme-toggle{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:40px;padding:9px 13px;border:1px solid #b6a4c4;border-radius:24px;background:transparent;color:#513b60;font-size:11px;white-space:nowrap}
.theme-toggle:hover{background:#e9def0}
.theme-icon{font:20px/1 Arial,sans-serif;display:inline-block;width:20px;text-align:center}
.menu-appearance{display:flex;align-items:center;justify-content:space-between;gap:16px;margin-top:26px;padding:17px 0;border-block:1px solid #9a7cb44d;font-size:14px}
.menu-appearance .theme-toggle{font-size:13px;padding-inline:17px}
#section-menu{max-height:90svh;overflow:auto}
@media(min-width:761px) and (max-width:1200px){.header-caption{display:none}.header{gap:20px}.header nav{gap:15px}.theme-toggle{padding-inline:10px}}
@media(max-width:760px){.header nav{display:none}.menu-appearance{margin-top:20px}.menu-body{padding-top:24px}}

html[data-theme=dark]{--black:#e9dff0;--paper:#211d27;--ink:#f4edf6;--purple:#c7aae6;--muted:#bcafc6;--line:#c7aae630;background:#1b1820;color:#f4edf6;color-scheme:dark}
[data-theme=dark] .header{border-color:#dac3ed24}
[data-theme=dark] .header-caption{color:#bcadca}
[data-theme=dark] .theme-toggle{color:#f0e4f9;border-color:#a88cba75;background:#c7aae60c}
[data-theme=dark] .theme-toggle:hover{background:#c7aae625}
[data-theme=dark] .menu-trigger{background:#dcc4ef;color:#2b1d36}
[data-theme=dark] .hero{background:#1b1820}
[data-theme=dark] .hero h1 em{color:#e0c2f4}
[data-theme=dark] .hero .label,[data-theme=dark] .hero-intro p{color:#c9bbd1}
[data-theme=dark] .hero-art>img{mix-blend-mode:normal;mask-image:radial-gradient(ellipse,#000 30%,#000e 48%,transparent 76%)}
[data-theme=dark] .hero-art:after{content:'';position:absolute;inset:0;background:linear-gradient(180deg,#1b182010,#1b18202e 35%,transparent 70%),linear-gradient(90deg,#1b182040,transparent 60%);pointer-events:none}
[data-theme=dark] .hero-film{background:#302735d9;border-color:#9e82af66;color:#f4eaf9;box-shadow:0 8px 30px #0002}
[data-theme=dark] .hero-film small{color:#c8b7d5}
[data-theme=dark] .scroll-cue,[data-theme=dark] .art-caption{color:#b5a3c1}
[data-theme=dark] .scroll-line{background:#7d688c}
[data-theme=dark] .lavender{background:#c7aae6;color:#271a32}
[data-theme=dark] .lavender:hover{background:#d8c0f1}
[data-theme=dark] .paper{background:#211d27;color:#f4edf6;color-scheme:dark}
[data-theme=dark] .start{border-color:#b79acb33}
[data-theme=dark] .section-top{border-color:#b79acb40}
[data-theme=dark] .paper .section-top>.label:last-child{color:#baabc5}
[data-theme=dark] .start-heading p{color:#c4b6ce}
[data-theme=dark] em,[data-theme=dark] .start-heading h2 em{color:#c7aae6}
[data-theme=dark] .path-card{background:#2e2933;border-color:#5c4d67;color:#f4edf6}
[data-theme=dark] .path-card:nth-child(2){background:#382c42;border-color:#6b507d}
[data-theme=dark] .path-card:nth-child(3){background:#2c342b;border-color:#56674b}
[data-theme=dark] .path-card:hover{background:#45334f;border-color:#c7aae6}
[data-theme=dark] .path-card:nth-child(3):hover{background:#394631;border-color:#b1c68e}
[data-theme=dark] .path-card p,[data-theme=dark] .path-foot>span{color:#c5bacd}
[data-theme=dark] .path-foot{border-color:#d3b8e333}
[data-theme=dark] .round-arrow{border-color:#d3b8e35c}
[data-theme=dark] .path-card:hover .round-arrow{background:#d5bbed22}
[data-theme=dark] .symbol-world,[data-theme=dark] .symbol-world i,[data-theme=dark] .symbol-film i,[data-theme=dark] .symbol-grid i{border-color:#d5c6df}
[data-theme=dark] .symbol-film i:nth-child(2){background:#382c42}
[data-theme=dark] .symbol-grid i:nth-child(5){background:#adc58c;border-color:#adc58c}
[data-theme=dark] .game-section{background:#2d2435;color:#f4edf6}
[data-theme=dark] .game-section .section-top,[data-theme=dark] .game-heading>p{color:#c7b3d6;border-color:#a888bc55}
[data-theme=dark] .pill{color:#d5c3e2;border-color:#ad8fc260}
[data-theme=dark] .pill .status-dot,[data-theme=dark] .reading-progress{background:#c7aae6}
[data-theme=dark] .title-star{color:#c7aae6}
[data-theme=dark] .game-stage{background:#392e42;border-color:#6f567f}
[data-theme=dark] .game-panel>.label,[data-theme=dark] .guide-copy>.label,[data-theme=dark] .sample-copy>.label{color:#cab1db}
[data-theme=dark] .game-panel h3 em{color:#d2b2ec}
[data-theme=dark] .game-panel>p,[data-theme=dark] .game-panel .fine{color:#cbbbd5}
[data-theme=dark] .game-tags span{border-color:#b69bc34d;color:#d7c8df}
[data-theme=dark] .game-panel .button{background:#d3b7e9;color:#2b1e36}
[data-theme=dark] .full-demo-link{color:#e0c3f6}
[data-theme=dark] .film-library{background:#292222}
[data-theme=dark] .library-heading h2 em{color:#dfb99c}
[data-theme=dark] .library-heading p,[data-theme=dark] .film-card-caption>span{color:#ccb5a5}
[data-theme=dark] .tabs{border-color:#8b749c66}
[data-theme=dark] .tabs button{color:#c8b9d3}
[data-theme=dark] .tabs [aria-selected=true]{background:#c7aae6;color:#251a30}
[data-theme=dark] .guide-visual{background:#342d3d}
[data-theme=dark] .guide-sticker{color:#283021}
[data-theme=dark] .guide-copy>p,[data-theme=dark] .sample-copy>p,[data-theme=dark] .steps p{color:#c5b8ce}
[data-theme=dark] .steps li,[data-theme=dark] .tutorial-choices>button{border-color:#a88fba44}
[data-theme=dark] .steps li>span,[data-theme=dark] .tutorial-choices small{color:#bda8ce}
[data-theme=dark] .text-button,[data-theme=dark] .contact-link{border-color:#ae90c4}
[data-theme=dark] .puzzle-shell{background:#302737;border-color:#70577f;box-shadow:0 15px 45px #0002;color:#f4edf6}
[data-theme=dark] .puzzle-top .label,[data-theme=dark] .level-size,[data-theme=dark] .vault-progress #puzzle-count{color:#cdbbd9}
[data-theme=dark] #puzzle-hearts{color:#ef9cb8}
[data-theme=dark] .puzzle-instructions{background:#241e2b;border-color:#70577f;color:#f5eafc}
[data-theme=dark] .puzzle-instructions>div+div{border-color:#70577f66}
[data-theme=dark] .control-symbol{color:#d8b5f0}
[data-theme=dark] .puzzle-instructions p>span,[data-theme=dark] .puzzle-shell .keyboard-help{color:#c6b6d2}
[data-theme=dark] .puzzle-shell #puzzle-response{color:#d4c2df}
[data-theme=dark] .puzzle-shell #puzzle-response.success{color:#d4e8b8}
[data-theme=dark] .dark,[data-theme=dark] .ivory{background:#d2b7e7;color:#281b33}
[data-theme=dark] .puzzle-shell.vault-won{background:#2a342a;border-color:#829a67}
[data-theme=dark] .vault-won h4{color:#d4e8b8}
[data-theme=dark] .studio{background:#3b2c47;color:#f2e8f8}
[data-theme=dark] .studio-left h2 em{color:#cda9e8}
[data-theme=dark] .studio-marquee,[data-theme=dark] .studio-values,[data-theme=dark] .studio-right{border-color:#b595cd44}
[data-theme=dark] .studio-right>p.subtle{color:#c9b5d8}
[data-theme=dark] .help-copy>p,[data-theme=dark] .faqs p{color:#c6b5d1}
[data-theme=dark] .faqs p a{color:#d7b4ef}
[data-theme=dark] .faqs details{border-color:#a88bbb55}
[data-theme=dark] .faqs summary span{color:#c7aae6}
[data-theme=dark] .fine{color:#c0accd}
[data-theme=dark] .footer{background:#251e2c;color:#e7d6f3}
[data-theme=dark] .footer-top p,[data-theme=dark] .footer-bottom,[data-theme=dark] .legal-links{color:#c3accf}
[data-theme=dark] .footer-logo{color:#ae8ac5}
[data-theme=dark] .footer-bottom,[data-theme=dark] .back-top>span{border-color:#b08ac344}
[data-theme=dark] .footer-bottom button,[data-theme=dark] .footer-bottom button>span{color:#d5b5ed}
[data-theme=dark] .section-dock{background:#2b2333ed;border-color:#a17eb257;box-shadow:0 8px 30px #0004}
[data-theme=dark] .section-dock a{color:#c6afd4}
[data-theme=dark] .section-dock a:hover{color:#fff1ff}
[data-theme=dark] .section-dock a.active{background:#c7aae6;color:#2d1e39}
[data-theme=dark] #section-menu{background:#302538;color:#f3e7fa;border-color:#876298}
[data-theme=dark] #section-menu .close-button{color:#f3e7fa;background:#ffffff0d;border-color:#b59ac855}
[data-theme=dark] .menu-appearance,[data-theme=dark] .menu-body>a{border-color:#b59ac844}
[data-theme=dark] .menu-body>.label,[data-theme=dark] .menu-body>a>small,[data-theme=dark] .menu-note{color:#c5acd5}
[data-theme=dark] .menu-body>a:hover{color:#d6b5f0}
[data-theme=dark] ::selection{background:#c7aae6;color:#22162d}

[data-theme=dark] .skip{color:#251a30}

[data-theme=dark] .tutorial-choices>button{background:#302638;border-color:#5a456a;color:#f2e8f8;box-shadow:0 4px 16px #00000012}
[data-theme=dark] .tutorial-choices>button:hover{background:#3d2f47;border-color:#a780c1}
[data-theme=dark] .tutorial-choices small{color:#c6b2d4}
[data-theme=dark] .tutorial-choices b{background:#4a3659;color:#ddc2f0}

/* A tactile day/night switch; the next palette opens from this control. */
.theme-toggle,.menu-appearance .theme-toggle{padding:0;gap:10px;min-height:44px;border:0;background:transparent;font-size:11px}
.theme-toggle:hover,[data-theme=dark] .theme-toggle,[data-theme=dark] .theme-toggle:hover{background:transparent;border:0}
.theme-track{position:relative;display:inline-flex;align-items:center;justify-content:space-between;direction:ltr;flex:none;width:68px;height:36px;padding:0 9px;border:1px solid #cfc0da;border-radius:30px;background:#e8dfef;box-shadow:inset 0 1px 3px #5437670a;isolation:isolate;transition:background .4s,border-color .4s,box-shadow .3s}
.theme-thumb{position:absolute;z-index:-1;left:3px;top:3px;width:28px;height:28px;border-radius:50%;background:#fffaf0;box-shadow:0 2px 7px #56416424;transition:transform .5s cubic-bezier(.22,1,.36,1),background .4s}
.theme-track svg{display:block;width:18px;height:18px;transition:transform .5s cubic-bezier(.22,1,.36,1),color .3s}
.theme-sun{color:#886528}.theme-moon{color:#877492}
[data-theme=dark] .theme-track{background:#302638;border-color:#6b527c}
[data-theme=dark] .theme-thumb{transform:translateX(32px);background:#d8bced;box-shadow:0 2px 10px #0003}
[data-theme=dark] .theme-sun{color:#ae91ba}
[data-theme=dark] .theme-moon{color:#4b315d;transform:rotate(-12deg)}
.theme-toggle:focus-visible{outline:2px solid #9672af;outline-offset:5px;border-radius:24px}
.theme-toggle [data-theme-label]{min-width:62px;text-align:start}
@media(hover:hover){
  .theme-toggle:hover .theme-track{border-color:#a381b8;box-shadow:0 0 0 4px #b993d212}
  .theme-toggle:hover .theme-thumb{transform:translateX(4px)}
  .theme-toggle:hover .theme-moon{transform:rotate(-20deg)}
  [data-theme=dark] .theme-toggle:hover .theme-thumb{transform:translateX(28px)}
  [data-theme=dark] .theme-toggle:hover .theme-sun{transform:rotate(60deg);color:#f4d89f}
}
html.theme-reveal::view-transition-old(root),html.theme-reveal::view-transition-new(root){animation:none;mix-blend-mode:normal}
html.theme-reveal::view-transition-new(root){z-index:1}
html.theme-reveal::view-transition-old(root){z-index:0}
html.theme-reveal::view-transition-group(root){animation:none}
.theme-fade body,.theme-fade section,.theme-fade header,.theme-fade footer,.theme-fade dialog,.theme-fade .path-card,.theme-fade .puzzle-shell,.theme-fade .tutorial-choices>button{transition:background-color .6s ease,color .6s ease,border-color .6s ease}
@media(prefers-reduced-motion:reduce){.theme-track,.theme-thumb,.theme-track svg{transition:none!important}}
.paused .theme-track,.paused .theme-thumb,.paused .theme-track svg{transition:none!important}
