/* Unplug Mobile — light / dark theme.
   theme.js sets <html data-theme="light|dark"> before the page paints:
   the visitor's saved choice wins, otherwise it follows the phone/computer setting. */

html[data-theme=light]{color-scheme:light}
html[data-theme=dark]{
  color-scheme:dark;
  --paper:#131b16;--ink:#ece8da;--muted:#a8b2a3;--orange:#e2845d;
  --line:#2f3d34;--white:#1b251f;--sage:#25332a
}
body{transition:background-color .25s,color .25s}
@media (prefers-reduced-motion:reduce){body{transition:none}}

/* Toggle button (added to the nav by theme.js) */
.theme-toggle{display:inline-grid;place-items:center;width:40px;height:40px;padding:0;border:1px solid var(--line);border-radius:50%;background:transparent;color:var(--ink);cursor:pointer;flex:none}
.theme-toggle:hover{border-color:var(--ink)}
.theme-toggle svg{width:18px;height:18px;display:block}
.theme-toggle .tt-sun{display:none}
html[data-theme=dark] .theme-toggle .tt-sun{display:block}
html[data-theme=dark] .theme-toggle .tt-moon{display:none}

/* Buttons */
html[data-theme=dark] .button:hover,html[data-theme=dark] .btn:hover{background:#d3cebd}
html[data-theme=dark] .button.orange:hover,html[data-theme=dark] .btn.orange:hover{background:#ea9877}
html[data-theme=dark] .button.light:hover,html[data-theme=dark] .btn.ghost:hover{background:var(--sage)}
html[data-theme=dark] .skip{color:var(--paper)}

/* Home page: hero turns into a night scene */
html[data-theme=dark] .scene{background:#1e2a23}
html[data-theme=dark] .sun{background:#e6d6a8;box-shadow:0 0 70px #e6d6a840}
html[data-theme=dark] .hill{background:#2b3a30}
html[data-theme=dark] .hill.two{background:#34463a}
html[data-theme=dark] .phone{background:#18211c;border-color:#0a0f0c;box-shadow:18px 25px 0 #00000040}
html[data-theme=dark] .speaker{background:#0a0f0c}
html[data-theme=dark] .float-note{border-color:var(--line);box-shadow:0 5px 20px #00000060}
html[data-theme=dark] .kit{background:#0d1310;color:var(--ink)}
html[data-theme=dark] .app{background:var(--white)}
html[data-theme=dark] .app-icon{background:#26362c}
html[data-theme=dark] .app:nth-child(2) .app-icon{background:#3a2e24}
html[data-theme=dark] .app:nth-child(3) .app-icon{background:#2a302a}
html[data-theme=dark] .checklist-section{background:#18221c}
html[data-theme=dark] .checklist{border-color:var(--line);box-shadow:7px 7px 0 #0d1310}
html[data-theme=dark] .checklist label{border-bottom-color:var(--line)}
html[data-theme=dark] .checklist input:checked+span{color:#7f8a7b}
html[data-theme=dark] .signup-form input[type=email]{border-color:#4a5a4f}

/* Landing pages */
html[data-theme=dark] .exit{background:#0d1310;color:var(--ink);border:1px solid var(--line)}
html[data-theme=dark] .exit h2{color:var(--ink)}
html[data-theme=dark] .exit p{color:var(--muted)}
html[data-theme=dark] .exit .btn{background:var(--ink);color:var(--paper)!important}
html[data-theme=dark] .exit .btn:hover{background:#d3cebd}
html[data-theme=dark] .exit .btn.ghost{background:transparent;color:var(--ink)!important;border-color:#5d6d61}
html[data-theme=dark] .exit .btn.ghost:hover{background:var(--sage)}
html[data-theme=dark] form.builder input,html[data-theme=dark] form.builder select,html[data-theme=dark] form.builder textarea{background:var(--paper)}
html[data-theme=dark] .qopts button{background:var(--paper)}

/* Always print in light */
@media print{
  html[data-theme=dark]{color-scheme:light;--paper:#eeeadd;--ink:#23392c;--muted:#536052;--orange:#ae431f;--line:#c9ccba;--white:#faf8f0;--sage:#d9dcc8}
  .theme-toggle{display:none!important}
}

/* Keep the home-page logo on one line on phones now that the nav has a toggle */
.brand{white-space:nowrap}
@media (max-width:800px){.navlinks{gap:8px}.theme-toggle{width:36px;height:36px}nav .wrap{gap:10px}}
