:root {color-scheme: light}
.theme-nav {gap:.85rem}
.theme-toggle {
  display:inline-flex;
  flex:none;
  align-items:center;
  gap:.42rem;
  padding:.42rem .7rem;
  min-height:44px;
  border:1px solid var(--line);
  border-radius:999px;
  background:var(--paper);
  color:var(--ink);
  font-size:.875rem;
  font-weight:650;
}
.theme-toggle:hover,.theme-toggle[aria-pressed="true"] {border-color:var(--accent)}
@media(max-width:680px) {
  .theme-nav {display:grid;grid-template-columns:1fr auto;align-items:center}
  .theme-nav > div {grid-row:2;grid-column:1/-1}
  .theme-toggle {grid-row:1;grid-column:2}
}

:root[data-theme="dark"] {
  color-scheme:dark;
  --cream:#191b17;
  --paper:#22251e;
  --ink:#eee9dc;
  --accent:#f0a68d;
  --line:#54564b;
  --night-card:#272a23;
  --night-raised:#32382c;
  --night-warm:#352922;
  --night-muted:#c8c0af;
  --night-green:#b8cba7;
  --night-button:#343c2e;
}
[data-theme="dark"] :is(.button,.controls button[aria-pressed="true"]) {
  background:var(--night-button);
  border-color:#758465;
  color:var(--ink);
}
[data-theme="dark"] .button:hover {background:#414d38}
[data-theme="dark"] .duel button[aria-pressed="true"] {
  background:var(--night-warm);
  border-color:var(--accent);
}
[data-theme="dark"] select {
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 16 16'%3E%3Cpath fill='none' stroke='%23eee9dc' stroke-width='1.5' d='m4 6 4 4 4-4'/%3E%3C/svg%3E");
}
[data-theme="dark"] :is(.guides .card,.style-tile,.hair-measure article,.hair-card,.hair-result,
.look-panel,.look-switch span,.pq-form,.pq-results,.pq-card,.pq-option,
.skip:focus,.hair-skip:focus,.style-skip:focus) {background:var(--night-card)}
[data-theme="dark"] :is(.look-section,.hair-table tbody tr:nth-child(even)) {background:var(--paper)}
[data-theme="dark"] :is(.look-tip,.style-tip,.hair-table thead,.filter-reset:hover,.look-switch input:checked+span) {background:var(--night-raised)}
[data-theme="dark"] :is(.look-photo,.hair-section blockquote,.pq-callout,.pq-card:first-child,
.pq-option:has(input:checked),.pq-secondary:hover) {background:var(--night-warm)}
[data-theme="dark"] :is(.brand-card-head,.brand-meta,.breadcrumbs span,.hair-breadcrumbs span,
.perf-small,.look-count,.look-note,.look-piece span,.pq-hint,.pq-concentration,.pq-match,.pq-note) {color:var(--night-muted)}
[data-theme="dark"] :is(.look-piece:has(input:checked)>div:first-child,.look-piece:has(input:checked) span) {color:var(--night-green)}
[data-theme="dark"] :is(.pq-hero em,.pq-progress strong,.pq-card a,#pq-error) {color:var(--accent)}
[data-theme="dark"] :is(.pq-callout,.pq-card,.pq-form,.pq-results,.pq-option,.pq-secondary) {border-color:var(--line)}
[data-theme="dark"] :is(.pq-option:hover,.pq-option:has(input:checked),.look-switch input:checked+span) {border-color:var(--accent)}
[data-theme="dark"] .pq-option:focus-within {outline-color:var(--accent)}
[data-theme="dark"] :is(.pq-option input,.pq-progress progress,.look-owned input) {accent-color:var(--night-green)}
[data-theme="dark"] .tone-01 {--tile:#303c34}
[data-theme="dark"] .tone-02 {--tile:#403127}
[data-theme="dark"] .tone-03 {--tile:#2c3643}
[data-theme="dark"] .tone-04 {--tile:#383e29}
[data-theme="dark"] .tone-05 {--tile:#442e2b}
[data-theme="dark"] .tone-06 {--tile:#3e3433}
[data-theme="dark"] :is(.perf-bottle-link,.perf-bottle,.perf-habit) {background:#b4ac9f}
[data-theme="dark"] :is(main img,.brand-logo-frame) {filter:brightness(.80)}
