/* The choice is local to this browser; System follows the device live. */
:root { color-scheme: light; }
:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #e6edf2;
  --ink-soft: #bdcbd4;
  --muted: #a5b5c1;
  --surface: #17232d;
  --surface-soft: #0e1720;
  --surface-blue: #173444;
  --line: #344653;
  --line-strong: #526876;
  --brand-blue-dark: #79cbe9;
  --danger: #ffaaa3;
  --shadow-sm: 0 8px 24px #0003;
  --shadow-md: 0 18px 50px #0005;
  --dash-blue: #79cbe9;
  --dash-bright: #79cbe9;
  --dash-ink: var(--ink);
  --dash-muted: var(--muted);
  --dash-line: var(--line);
  --dash-paper: var(--surface-soft);
  --dash-good: #92d8ad;
}
.site-header .theme-picker {
  display: flex;
  align-items: center;
  gap: 9px;
  margin: 0 0 0 8px;
  color: var(--ink-soft);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.site-header .theme-picker select {
  width: auto;
  min-width: 92px;
  min-height: 44px;
  margin: 0;
  padding: 8px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  color: var(--ink);
  cursor: pointer;
  font: inherit;
}
.theme-picker[hidden] { display: none !important; }
@media (max-width:1540px) {
  .site-header .theme-picker { grid-column: 1 / -1; justify-content: space-between; margin: 8px 0 0; padding: 10px 13px 0; border-top: 1px solid var(--line); }
  .site-header .theme-picker select { font-size: 16px; min-width: 118px; }
}

/* Shared surfaces and form controls. Product photos retain their original colors. */
:root[data-theme="dark"] .site-header { background: #17232df2; border-color: var(--line); }
:root[data-theme="dark"] :is(.primary-nav,.nav-guides-list,.nav-toggle,.button--secondary,.hero-card--main,
  .notification-options label,.notification-panel>input,.notification-setup-grid article,.alert-action-page,
  .input-prefix,.telegram-input,.deal-card,.feature-strip article,.telegram-post,.standalone-empty,
  .seo-explainer,.faq-section,.faq-list details,.feed-source-bar,.feed-refresh,.telegram-widget-card,
  .native-feed-status,.native-feed-card,.platform-guide,.browser-alert-card,.alerts-overview-card,
  .curated-channel-card,.community-platform-card,.custom-alert-callout,.category-directory,
  .deal-discovery-strip,.category-checklist,.public-guide-card,.public-guide-controls input,
  .public-guide-controls select,.dashboard-shell .panel,.watch-row,.watch-detail,.dash-button.secondary,
  .chart-ranges button[aria-pressed=true],#dealagram-contact-form) { background: var(--surface); border-color: var(--line); }
:root[data-theme="dark"] :is(input[type="text"],input[type="number"],input[type="email"],input[type="search"],input[type="url"],textarea,select,
  .dashboard-shell input:not([type=checkbox]):not([type=hidden]),.dashboard-shell select) { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
:root[data-theme="dark"] :is(input,textarea)::placeholder { color: var(--muted); }
:root[data-theme="dark"] :is(.hero,.page-hero,.story-card--lead,.contact-aside,.alert-option) { background: linear-gradient(150deg,var(--surface),var(--surface-soft)); }
:root[data-theme="dark"] :is(.bot-setup-split>div,.follow-deal-panel,.chart-ranges,.watch-loading-note,.notification-return,.dashboard-tabs span) { background: var(--surface-blue); color: var(--ink-soft); border-color: var(--line); }
:root[data-theme="dark"] :is(.category-checklist label:has(input:checked),.site-header .primary-nav>a.nav-account:hover,.site-header .primary-nav>a.nav-account.active,.collection-buttons .button:hover,.watch-row:hover,.watch-item[open]>.watch-row) { background: var(--surface-blue); color: var(--ink); }
:root[data-theme="dark"] :is(.site-header .primary-nav>a.nav-cta,.button--primary,.dash-button.primary) { background: #137ca4; color: #fff; }
:root[data-theme="dark"] :is(.site-header .primary-nav>a.nav-cta:hover,.button--primary:hover,.dash-button.primary:hover) { background: #106587; color: #fff; }
:root[data-theme="dark"] :is(.current-price,.native-feed-current) { color: #ffaaa3; }
:root[data-theme="dark"] :is(.discount-badge,.native-feed-card:not(.native-feed-card--expired) .native-feed-discount) { background: #173444; color: #fff; }
:root[data-theme="dark"] :is(.save-line,.native-feed-facts span:first-child,.deal-share-status) { color: #92d8ad; }
:root[data-theme="dark"] :is(.free-badge,.card-badge,.saved-alert-notice,.feed-update-message,.native-feed-msrp-discount,.buy-insight,.account-message,.connection-chip,.subscription-state.on) { background: #19392e; color: #a4e4bc; border-color: #3c6552; }
:root[data-theme="dark"] :is(.saved-alert-notice--error,.alert-setup-status--error,.account-message.error,.dash-button.danger) { background: #402725; color: #ffb8af; border-color: #82524d; }
:root[data-theme="dark"] :is(.account-settings>details summary,.subscription-delete>summary) { color: #ffb8af; }
:root[data-theme="dark"] .dashboard-shell .danger { color: #ffb8af !important; }
:root[data-theme="dark"] :is(.subscription-state,.connection-chip.muted,.product-state--pending) { background: #293b47; color: var(--ink-soft); }
:root[data-theme="dark"] :is(.product-state,.custom-alert-examples span,.alert-product-number,.deal-return-note,.price-reduced-note) { color: #91d8ef; background: var(--surface-blue); }
:root[data-theme="dark"] :is(.product-state--expired,.telegram-feed--fallback::before) { background: #3f3423; color: #f1cf93; }
:root[data-theme="dark"] .product-history-expired { color: #f1cf93; }
:root[data-theme="dark"] :is(.native-share-link,.native-follow-link,.shared-deal-intro a) { color: var(--brand-blue-dark); }
:root[data-theme="dark"] :is(.footer-disclosures,.search-price-verification,.shared-deal-note,.follow-deal-panel p,.native-feed-asin) { color: var(--muted); }
:root[data-theme="dark"] .watch-row { --dash-summary-blue: #79cbe9; }
:root[data-theme="dark"] .skip-link { background: var(--surface); color: var(--ink); }
:root[data-theme="dark"] .cta-panel { background: #173444; }
:root[data-theme="dark"] .empty-glyph { background: var(--surface-blue); border-color: var(--line); }

/* Member buying guides use a shared editorial palette and their own dialogs. */
:root[data-theme="dark"] :is(.robot-guide,.monitor-guide,.tv-guide,.headset-guide,.collection-guide) {
  color-scheme: dark;
  --ink: #e6edf2; --muted: #acbfc5; --teal: #7bd2ce; --dark: #173e42;
  --lime: #bbd18a; --paper: #101c23; --line: #3a4f56; --white: #192a31;
  --shadow: 0 16px 40px #0003;
}
:root[data-theme="dark"] :is(.robot-guide,.tv-guide,.headset-guide,.collection-guide) :is(
  .site-header,.pick-card,.history-layout,.history-sidebar select,.range-tabs button.active,.table-scroll,
  form select,.category-watch>.button,#budget-filter,.no-picks,.watch-mode button.active,#watch-destination,
  .guide-category-card,.nav-menu,.filter-controls select,.filter-extra select,.comparison .model-cell,
  .panel-card,.console-pick,.console-specs,.platform-card,.quick-card,.collection-filters,.collection-table,.advice-card) { background: var(--white); color: var(--ink); border-color: var(--line); }
:root[data-theme="dark"] :is(.robot-guide,.tv-guide,.headset-guide,.collection-guide) :is(
  .byline-mark,.hero-art,.hero-circle,.hero-float,.float-icon,.hero-bottom,.section-nav,.price-section,
  .history-sidebar,.range-tabs,.history-insight,.review-visual,.test-result,.price-take,thead th,.table-watch,
  .method-section,.modal-heading-icon,.price-input,.target-presets button,.channel-options input:checked+span,
  .preview-message,.category-watch,.category-icon,.watch-mode,.category-scope,.table-scroll th:first-child,
  #guide-signup-status,.finder,.spec-badges span,.console-specs thead,.tv-console-note,.size-jumps a,
  .editorial-ratings,.platform-caution,.platform-explainer,.headset-compare tbody th,.review-evidence,.empty-state,
  .watch-suggestion,#watch-target:disabled) { background: #223a41; color: var(--ink); border-color: var(--line); }
:root[data-theme="dark"] :is(.robot-guide,.tv-guide,.headset-guide,.collection-guide) :is(
  .hero-caption,.history-insight p,.evidence p,.test-result span,.tradeoffs ul,.price-take p,.product-note summary,
  .review-sources,thead th:first-child,tbody th,.method-grid p,.source-list,.category-watch p,.shipping-note,
  .filter-controls label,.preview-message span,.size-verdict,.fit-ratings dt,.fit-good,.watch-suggestion>span,
  .watch-suggestion>p) { color: var(--muted); }
:root[data-theme="dark"] :is(.robot-guide,.tv-guide,.headset-guide,.collection-guide) :is(.signal-low,.plus,.stock-label,.stock-label span,.availability-note>strong,.fit-strong,.watch-suggestion>strong) { color: #a4e4bc; }
:root[data-theme="dark"] :is(.robot-guide,.tv-guide,.headset-guide,.collection-guide) :is(.card-signal,.minus,.stock-stale,.stock-stale strong,.fit-basic,.saved-item button) { color: #f1cf93; }
:root[data-theme="dark"] :is(.robot-guide,.tv-guide,.headset-guide,.collection-guide) :is(.primary,.filter.active) { background: #167c80; color: #fff; }
:root[data-theme="dark"] .dashboard-track-link { color: #79cbe9 !important; }
