/* Kakanj-X V2.4.51: page-scoped night mode, icon rail, mobile nav and personal theme. */
body.kx-theme-dark{color-scheme:dark;--kx51-bg:#0d1318;--kx51-panel:#172029;--kx51-soft:#111b23;--kx51-raised:#202d39;--kx51-stroke:#344554;--kx51-text:#edf3f7;--kx51-muted:#b4c4ce}
/* Public navigation: do not alter AQI status colours, logos or media. */
body.kx-theme-dark .kx-global-nav,body.kx-theme-dark .kx-nav-row{background:#111c24!important;border-color:#354553!important;color:var(--kx51-text)!important}
body.kx-theme-dark .kx-nav-tools,body.kx-theme-dark .kx-primary,body.kx-theme-dark .kx-main-nav-186{background:transparent;color:var(--kx51-text)}
body.kx-theme-dark .kx-nav-tools :is(.kxc-nav-reader,.kx-weather-indicator,.kx-air-nav,.kx-nav-action-171,.kx-icon-btn),body.kx-theme-dark .kx-nav-tools :is(.kx-nav-action-caption-171,.kx-nav-symbol-171,#kxAirMini,#kxMiniTemp,.kxwx-nav-glyph){color:var(--kx51-text)!important;border-color:var(--kx51-stroke)}
body.kx-theme-dark .kx-nav-tools :is(a,button):hover{background-color:var(--kx51-raised)!important}
body.kx-theme-dark .kx-nav-tools :is(svg){color:inherit}
body.kx-theme-dark .kx-nav-tools .kxair-nav-icon{background:transparent!important;box-shadow:none!important} /* original category colour remains on SVG icon */
/* Theme choice lives beside weather/air icons in both layouts. */
.kx-theme-switch-2451{appearance:none;border:1px solid rgba(108,131,147,.44);border-radius:999px;display:inline-flex;gap:6px;align-items:center;justify-content:center;flex:none;padding:7px 10px;min-height:35px;white-space:nowrap;background:rgba(120,130,140,.10);color:inherit;cursor:pointer;font:600 12px/1.15 system-ui,-apple-system,sans-serif;transition:background .2s,border-color .2s}
.kx-theme-switch-2451:hover{background:rgba(30,133,87,.14)}.kx-theme-switch-2451:focus-visible{outline:2px solid #63d49e;outline-offset:3px}
body.kx-theme-dark .kx-theme-switch-2451{background:#20313c;color:#f1f6fa;border-color:#496170}
body.kx-theme-dark .kx-theme-switch-2451:hover{background:#2c4050}
/* AIR: self-contained module had its own white cards; recolour surfaces only. */
body.kx-theme-dark .kx-air-theme-2451{background:transparent!important;color:var(--kx51-text)}
body.kx-theme-dark .kx-air-theme-2451 :is(section,article,aside,header,footer,main,.card,.panel,.box,.tile,.widget,.surface,.summary,.detail,.chart-wrap,.table-wrap){border-color:var(--kx51-stroke)}
body.kx-theme-dark .kx-air-theme-2451 :is(.card,.panel,.box,.tile,.widget,.surface,.summary,.detail,.chart-wrap,.table-wrap,.kx-air-panel,.kx-air-card,.kx-air-summary,[class*="card"],[class*="panel"],[class*="table"],[class*="stat"],[class*="station"],[class*="summary"],[class*="chart"]):not([class*="aqi"]):not([class*="AQI"]):not([class*="level"]):not([class*="status"]):not([class*="legend"]){background-color:var(--kx51-panel)!important;color:var(--kx51-text);border-color:var(--kx51-stroke)!important}
body.kx-theme-dark .kx-air-theme-2451 :is(h1,h2,h3,h4,h5,h6,p,li,td,th,label,small){color:inherit}
body.kx-theme-dark .kx-air-theme-2451 :is([style*="background: white"],[style*="background:#fff"],[style*="background: #fff"],[style*="background:#ffffff"],[style*="background-color: white"],[style*="background-color:#fff"]):not([class*="aqi"]):not([class*="status"]):not([class*="level"]){background-color:var(--kx51-panel)!important;color:var(--kx51-text)!important}
body.kx-theme-dark .kx-air-theme-2451 :is(input,select,textarea){color:var(--kx51-text)!important;background:var(--kx51-soft)!important;border-color:var(--kx51-stroke)!important}
body.kx-theme-dark .kx-air-theme-2451 :is(table,thead,tbody,tr,td,th){border-color:var(--kx51-stroke)!important}body.kx-theme-dark .kx-air-theme-2451 :is(table,td,th){color:var(--kx51-text)}
body.kx-theme-dark .kx-air-theme-2451 th{background:var(--kx51-raised)!important}
/* Do not recolour AQI category chips, station graphs, icons, air indicators, or photography. */
body.kx-theme-dark .kx-air-theme-2451 :is([class*="aqi"],[class*="AQI"],[class*="level"],[class*="status"],[class*="legend"],[class*="badge"],[class*="chip"],canvas,svg,img){filter:none}
/* Mobile menus: complete dark surfaces incl. expanded submenu and off-canvas nav. */
@media(max-width:900px){
 body.kx-theme-dark :is(.kx-global-nav,.kx-nav-row,.kx-primary,.kx-main-nav-186,.kx-news-item-186,.kx-magazine-item-2432,.kx-news-submenu-186,.kx-magazine-submenu-2432,.kx-nav-search){background-color:#111c24!important;color:#edf3f7!important;border-color:#354553!important}
 body.kx-theme-dark :is(.kx-main-nav-186,.kx-news-submenu-186,.kx-magazine-submenu-2432) :is(a,button){color:#edf3f7!important;background:transparent!important;border-color:#354553!important}
 body.kx-theme-dark :is(.kx-main-nav-186,.kx-news-submenu-186,.kx-magazine-submenu-2432) :is(a,button):hover{background:#243644!important}
 body.kx-theme-dark :is(.kx-menu-toggle,.kx-news-toggle-186,.kx-magazine-toggle-2432){color:#edf3f7!important;background:#1e303e!important;border-color:#354553!important}
 body.kx-theme-dark .kx-nav-tools{background:#111c24!important;color:#edf3f7!important;border-color:#354553!important}
 .kx-theme-switch-2451{min-width:35px;min-height:35px;padding:6px;gap:0}
 .kx-theme-switch-2451 span{display:none}
}
@media(prefers-reduced-motion:reduce){.kx-theme-switch-2451{transition:none}}
