:root{--cal-present:linear-gradient(120deg,#e0f7ef,#bceee6);--cal-absent:linear-gradient(120deg,#f0eff1,#dbdce1);--cal-late:linear-gradient(120deg,#fff0f2,#f7d5dd);--cal-early:linear-gradient(120deg,#fff6e9,#ffe7cc);--cal-future:linear-gradient(120deg,#f3fcf8,#e2f5ed)}
html:root body:is(.admin-workspace,.staff-workspace) .ov-day.present,.legend-swatch.present{--cal-bg:var(--cal-present);--cal-ink:#12574e;--cal-edge:#159b88}
html:root body:is(.admin-workspace,.staff-workspace) .ov-day.absent,.legend-swatch.absent{--cal-bg:var(--cal-absent);--cal-ink:#292d36;--cal-edge:#777d86}
html:root body:is(.admin-workspace,.staff-workspace) .ov-day.late,.legend-swatch.late{--cal-bg:var(--cal-late);--cal-ink:#a22a45;--cal-edge:#c53b59}
html:root body:is(.admin-workspace,.staff-workspace) .ov-day.early,.legend-swatch.early{--cal-bg:var(--cal-early);--cal-ink:#9a5415;--cal-edge:#d88225}
html:root body:is(.admin-workspace,.staff-workspace) .ov-day.future,.legend-swatch.future{--cal-bg:var(--cal-future);--cal-ink:#285b4e;--cal-edge:#c3e6d7}
html:root body:is(.admin-workspace,.staff-workspace) .ov-day.off,.legend-swatch.off{--cal-bg:linear-gradient(120deg,#fff,#fff);--cal-ink:#324a42;--cal-edge:#d5e1dc}
html:root body:is(.admin-workspace,.staff-workspace) .ov-calendar .ov-day{background:var(--cal-bg)!important;border:1px solid var(--cal-edge)!important;border-left:3px solid var(--cal-edge)!important;color:var(--cal-ink)!important;box-shadow:none!important;filter:none!important;overflow:hidden!important;position:relative!important}
html:root body:is(.admin-workspace,.staff-workspace) .ov-calendar .ov-day:before,html:root body:is(.admin-workspace,.staff-workspace) .ov-calendar .ov-day:after{background:none!important;box-shadow:none!important}
html:root body:is(.admin-workspace,.staff-workspace) .ov-calendar .ov-day :is(.ov-num,.ov-mo){color:var(--cal-ink)!important}
html:root body:is(.admin-workspace,.staff-workspace) .ov-calendar .ov-dot,.legend-ot-dot{background:#2879db!important;border:1px solid white!important;box-shadow:none!important}
.attendance-legend{display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:12px 24px;padding:14px 0 4px;color:var(--ink,#344b43);font-size:12px;line-height:1.4}
.legend-item{display:inline-flex;align-items:center;gap:8px;white-space:nowrap}
.legend-swatch{width:21px;height:21px;border:1px solid var(--cal-edge);border-radius:5px;background:var(--cal-bg);flex:none;box-sizing:border-box}
.legend-overtime{flex-basis:100%;display:flex;align-items:center;justify-content:center;gap:16px;font-size:11px}
.legend-ot-dot{width:9px;height:9px;border-radius:50%;display:inline-block}
.legend-note{border-left:1px solid var(--hr-line);padding-left:16px;color:#71847c}
html:root body.admin-workspace .sw-templates .shift-new-button{width:auto!important;min-width:150px!important;height:40px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;padding:0 16px!important;flex:none!important;text-align:center!important}
html:root body.admin-workspace .sw-holiday-name{position:absolute!important;bottom:4px!important;left:4px!important;right:4px!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:3px!important;font-size:10px!important;line-height:13px!important;color:#9b3150!important;background:rgba(255,255,255,.88)!important;border-radius:3px!important;padding:1px 2px!important;z-index:3!important;max-width:calc(100% - 8px)!important}
.sw-holiday-name>span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0}
.sw-holiday-name svg{width:12px;height:12px;fill:none;stroke:currentColor;stroke-width:1.8;flex:none}
html:root body.admin-workspace .sw-holiday .sw-band-counts{bottom:20px!important;top:17px!important}
html:root body.admin-workspace .sw-holiday-detail{font-size:13px!important;color:#a12d4e!important;margin:5px 0 10px!important;font-weight:600}
html:root[data-theme=dark] .attendance-legend{color:#dbe7e1}
@media(max-width:700px){.attendance-legend{gap:7px 14px;font-size:11px;padding:8px 0 3px}.legend-swatch{width:14px;height:14px;border-radius:4px}.legend-item{gap:5px}.legend-overtime{gap:8px;font-size:10px;flex-wrap:wrap}.legend-note{padding-left:8px}html:root body.admin-workspace .sw-templates .shift-new-button{min-width:0!important;padding:0 12px!important;font-size:12px!important}html:root body:has(.admin-staff-calendar){--ov-cell-height:clamp(26px,calc((100dvh - 470px)/6),42px)}}
/* Override older state-specific solid fills as well as their white date labels. */
html:root body:is(.admin-workspace,.staff-workspace) .ov-calendar .ov-day:is(.present,.absent,.late,.early,.future,.off){background:var(--cal-bg)!important;border-color:var(--cal-edge)!important;color:var(--cal-ink)!important}
html:root body:is(.admin-workspace,.staff-workspace) .ov-calendar .ov-day:is(.present,.absent,.late,.early,.future,.off) :is(.ov-num,.ov-mo){color:var(--cal-ink)!important}
