/* Shared presentation only: prices keep the same HA colour thresholds in both modes. */
:root { color-scheme:light; --panel:#fff; --chart-ink:#364336; --chart-grid:#e9e9eb; --grid-series:#000000; --battery-series:#7b8b99; --sales-series:#368f39; --charge-series:#de425b; --house-series:#6d4c91; --pv-series:#368f39; --pv-charge-series:#d4a600; --car-series:#087f8c; }
.theme-picker { display:flex; margin:0; align-items:center; gap:1rem; color:var(--ink); font-size:1rem; }
.appearance-settings .theme-picker { justify-content:space-between; flex-wrap:wrap; }
.theme-picker select { width:auto; max-width:none; min-height:44px; margin:0; padding:.45rem .55rem; font:inherit; font-size:.85rem;
  border:1px solid var(--line); border-radius:6px; background:var(--panel); color:var(--ink); cursor:pointer; }
.theme-picker select:focus-visible { outline:3px solid var(--green); outline-offset:2px; }
html[data-theme="dark"] { color-scheme:dark; --ink:#e6efe9; --muted:#a8baae; --line:#35473d;
  --paper:#101b17; --panel:#192820; --green:#91dab0; --lime:#d5eca9; --chart-ink:#c0d1c5;
  --chart-grid:#35473d; --grid-series:#000000; --battery-series:#f5d547; --sales-series:#368f39; --charge-series:#de425b; --house-series:#e585d9; --pv-series:#64df7b; --pv-charge-series:#a990ff; --car-series:#39dce3; }
html[data-theme="dark"] a { color:var(--green); }
html[data-theme="dark"] :is(header,section,.panel,.save-bar,.terms,.today-overview,.customer-overview-card,.car-timing-dialog,.cookie-information) {
  background:var(--panel); border-color:var(--line); color:var(--ink); }
html[data-theme="dark"] :is(input,select,textarea) { background:var(--paper); color:var(--ink); border-color:#556b5d; accent-color:#91dab0; }
html[data-theme="dark"] :is(input,textarea)::placeholder { color:var(--muted); }
html[data-theme="dark"] :is(button,.button,.customer-action) { background:#256748; border-color:#387c58; color:#f0fff5; }
html[data-theme="dark"] :is(button.secondary,a.button.secondary,.customer-action.secondary,header nav a,header nav button.secondary) {
  background:var(--panel); color:var(--green); border-color:var(--line); }
@media (hover: hover) and (pointer: fine) { html[data-theme="dark"] :is(button,.button,.customer-action):hover { background:#327b57; } }
@media (hover: hover) and (pointer: fine) { html[data-theme="dark"] :is(button.secondary,a.button.secondary,header nav a,header nav button.secondary):hover { background:#263e30; } }
html[data-theme="dark"] .chart-days button[aria-pressed="true"] { background:#327b57; border-color:#91dab0; color:#fff; }
html[data-theme="dark"] :is(.dialog-close,.cookie-footer .cookie-link) { background:transparent; color:var(--muted); }
@media (hover: hover) and (pointer: fine) { html[data-theme="dark"] .cookie-footer .cookie-link:hover { background:transparent; color:var(--ink); } }
html[data-theme="dark"] .feature-icon { background:#263e30; color:#a7d893; }
html[data-theme="dark"] :is(.message,.contact-form .form-done,.contact-info,.switch-state.on,.demo-badge,.demo-saving) { background:#233e2d; color:#c0ebd0; }
html[data-theme="dark"] :is(.error,.contact-form .form-error,.switch-state.off) { background:#472c27; color:#ffb9a5; }
html[data-theme="dark"] :is(.demo-saving strong,.serif-accent,.eyebrow) { color:#a7d893; }
html[data-theme="dark"] :is(nav,.visual-top,.chart-times,.soc-label,.chart-legend,.contact-form label,.contact-form .form-note,.footer-links,.footer-bottom) { color:var(--muted); }
html[data-theme="dark"] :is(footer,code,.pv-progress) { background:#15231c; }
html[data-theme="dark"] :is(.hero-visual,.price-card,.illustration-tag,.licence-card,.feature-card,.steps li) { background:var(--panel); border-color:var(--line); }
html[data-theme="dark"] .licence-card-loan { background:#243a2b; }
html[data-theme="dark"] :is(.licence-card-share,.callout) { background:#203e2f; }
html[data-theme="dark"] :is(.button.light,.licence-card-share .button) { background:var(--lime); color:#193b31; border-color:var(--lime); }
html[data-theme="dark"] :is(.price-bars,.plan-strip) { background:none; border-color:var(--line); }
header .brand-logo { height:32px; }
@media(max-width:600px){header .brand-logo{content:url('/wattr-mark.svg?v=compact-smile-1');width:46px;height:32px;object-fit:contain;}}
html[data-theme="dark"] .brand-logo { content:url('/wattr-wordmark-dark.svg?v=compact-smile-1'); }
html[data-theme="dark"] .admin-table tbody tr.estimated { color:var(--muted); }
/* Apex labels include explicit SVG colours; CSS also updates them on a live theme change. */
html[data-theme="dark"] .apexcharts-text { fill:var(--chart-ink); }
html[data-theme="dark"] .apexcharts-legend-text { color:var(--chart-ink) !important; }
html[data-theme="dark"] :is(.apexcharts-tooltip,.apexcharts-tooltip-title,.apexcharts-xaxistooltip,.apexcharts-yaxistooltip) {
  background:var(--panel) !important; color:var(--ink) !important; border-color:var(--line) !important; }
.price-extremum-label { fill:var(--chart-ink) !important; }
.price-extremum-label + rect { fill:var(--panel); stroke:var(--line); }
@media (max-width:600px) {
  .theme-picker select { font-size:16px; max-width:8.5rem; }
  html[data-theme="dark"] header .brand-logo { content:url('/wattr-mark-dark.svg?v=compact-smile-1'); }
}
@media print {
  html[data-theme="dark"] { --paper:#fff; --panel:#fff; --ink:#17232a; --muted:#63705f; --line:#d7ddd0; --chart-ink:#364336; }
  .theme-picker { display:none; }
}

/* Touch controls activate directly; hover feedback belongs to mouse pointers. */
:where(a, button, input, select, summary) { touch-action: manipulation; }
