/* Unified dark care palette; light mode is unaffected. */
@media screen {
html[data-theme=dark]{--mc-primary:#73d7c0;--mc-hover:#9ae8d5;--mc-soft:#193d40;--mc-soft-text:#b0eadb;--mc-gradient:linear-gradient(120deg,#73d7c0,#50bdb3);--mc-bg:#0d1b22;--mc-surface:#13262f;--mc-card:#172e37;--mc-alt:#1b343e;--mc-border:#2b4650;--mc-strong:#42616c;--mc-text:#edf5f5;--mc-secondary:#b8cbd0;--mc-muted:#91aab2;--mc-on-primary:#082a29;--mc-success:#81d8ae;--mc-success-bg:#173d32;--mc-warning:#efc078;--mc-warning-bg:#403521;--mc-danger:#f3a8a3;--mc-danger-bg:#432c32}
html[data-theme=dark] body.hms-ui .sidebar{background:#102731;border-color:var(--mc-border)}
html[data-theme=dark] body.hms-ui .sidebar .sidebar-logo{background:linear-gradient(115deg,#17414a,#102b36);border-color:var(--mc-border)}
html[data-theme=dark] body.hms-ui .sidebar .sidebar-footer{background:#102731;border-color:var(--mc-border)}
html[data-theme=dark] body.hms-ui .sidebar .nav-item{color:#bed3d8}
html[data-theme=dark] body.hms-ui .sidebar .nav-item.active{background:#204b4e;border-color:#548e88;color:#b8f0de;box-shadow:none}
html[data-theme=dark] body.hms-ui .sidebar .nav-item.active .icon{background:#2c5a59;color:#b8f0de;border-color:transparent}
html[data-theme=dark] body.hms-ui .sidebar.collapsed .nav-item.active{background:#73d7c0;color:#082a29}
html[data-theme=dark] body.hms-ui .sidebar.collapsed .nav-item.active .icon{background:transparent;color:#082a29}
html[data-theme=dark] body.hms-ui .header{background:var(--mc-surface);border-color:var(--mc-border);backdrop-filter:none}
html[data-theme=dark] body.hms-ui .header .shell-search{background:#1b343e;border-color:var(--mc-border)}
html[data-theme=dark] body.hms-ui .header .shell-search input{color:var(--mc-text)}
html[data-theme=dark] body.hms-ui :is(input,textarea)::placeholder{color:#91aab2;opacity:1}
html[data-theme=dark] body.hms-ui .page :is(.dx-ph .ey,.dx-eyebrow,.dx-kpi .cap,.dx-act small,.form-hint,.text-muted){color:var(--mc-muted)}
html[data-theme=dark] body.hms-ui .page :is(.badge-teal,.badge-green){background:var(--mc-soft);color:var(--mc-soft-text)}
html[data-theme=dark] body.hms-ui .page .badge-gray{background:var(--mc-alt);color:var(--mc-secondary);border-color:var(--mc-border)}
html[data-theme=dark] body.hms-ui .page .badge-red{background:var(--mc-danger-bg);color:var(--mc-danger)}
html[data-theme=dark] body.hms-ui .page .badge-amber{background:var(--mc-warning-bg);color:var(--mc-warning)}
html[data-theme=dark] body.hms-ui .page :is(.kv dd,.pname,.sec-title,.profile-section-title){color:var(--mc-text)}
html[data-theme=dark] body.hms-ui .page :is(.kv dt,.ipd-filter label,.ipd-table .sub){color:var(--mc-secondary)}
html[data-theme=dark] body.hms-ui .page :is(.ward-tile,.bed-chip,.notes li,.bed-chips .bed-chip){background:var(--mc-card);border-color:var(--mc-border);color:var(--mc-text)}
html[data-theme=dark] body.hms-ui .page .bed-chip.occ{border-color:#a5854d}
html[data-theme=dark] body.hms-ui .page .bed-chip.free{border-color:#488e80}
html[data-theme=dark] body.hms-ui .page .notes .body{color:var(--mc-text)}
html[data-theme=dark] body.hms-ui .page .dx-empty{background:var(--mc-card);color:var(--mc-secondary)}
html[data-theme=dark] body.hms-ui .page .flash.ok{background:var(--mc-success-bg);color:var(--mc-success);border-color:#2e6650}
html[data-theme=dark] body.hms-ui .page .flash.bad{background:var(--mc-danger-bg);color:var(--mc-danger);border-color:#795052}
html[data-theme=dark] body.hms-ui :is(.form-control,.btn,.dx-btn,.hd-item,.nav-item):focus-visible{outline:2px solid #9ae8d5;outline-offset:3px}
html[data-theme=dark] body.hms-ui .modal-box-header{background:linear-gradient(115deg,#17414a,#102b36);border-color:var(--mc-border)}
html[data-theme=dark] body.hms-home .care-marker{background:var(--mc-card);border-color:var(--mc-border)}
html[data-theme=dark] body.public-care .login-intro{background:#102b36}
}
/* Icon containers must use surface colors, not the theme's text/navy token. */
@media screen {
html[data-theme=dark] body.hms-ui :is(.dept-icon,.dept-icon.admin,.dept-role-tag,.step-num,.reg-step-num,.sec-num){background:var(--mc-soft);color:var(--mc-soft-text);border:1px solid var(--mc-border)}
html[data-theme=dark] body.hms-ui .dept-icon.admin{background:var(--mc-soft);color:var(--mc-soft-text);border-color:var(--mc-border)}
html[data-theme=dark] body.hms-ui .dept-icon svg{color:inherit;stroke:currentColor}
html[data-theme=dark] body.hms-ui .dept-card :is(.dept-name,.dept-desc,.dept-meta){border-color:var(--mc-border)}
html[data-theme=dark] body.hms-ui .dept-card .dept-name{color:var(--mc-text)}
html[data-theme=dark] body.hms-ui .dept-card :is(.dept-desc,.dept-meta){color:var(--mc-secondary)}
}
