/* Calendar mode selection: approved neutral date material for the three view controls.
   Scope is explicit because the compiled calendar is still legacy UI. */
[data-stam-calendar-mode="selected"]{position:relative;isolation:isolate;background:transparent!important;box-shadow:none!important;color:#f5f5f5!important;z-index:1}
[data-stam-calendar-mode="selected"]::before{content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;border-radius:40% / 36%;border:2px solid #999;background:linear-gradient(145deg,#656565,#444);box-shadow:inset 0 1px 0 #ffffff55,inset 0 -2px 2px #00000055,0 2px 3px #00000030}
.theme-light [data-stam-calendar-mode="selected"],html.light [data-stam-calendar-mode="selected"],html:not(.dark):not(.theme-dark) [data-stam-calendar-mode="selected"]{color:#242424!important}
.theme-light [data-stam-calendar-mode="selected"]::before,html.light [data-stam-calendar-mode="selected"]::before,html:not(.dark):not(.theme-dark) [data-stam-calendar-mode="selected"]::before{background:linear-gradient(145deg,#f0f0f0,#d9d9d9);box-shadow:inset 0 1px 0 #ffffffe6,inset 0 -2px 2px #0000001f,0 2px 3px #00000020}
[data-stam-calendar-mode]:focus-visible{outline:2px solid hsl(var(--primary));outline-offset:2px}
/* The week dates meet the toolbar in normal flow; the scrollport-relative sticky top keeps them flush after scrolling. */
.stam-calendar-week-header{margin-top:-1rem!important}

/* Give the three view labels their own row when actions cannot fit beside them. */
[data-stam-calendar-mode-controls]{flex-wrap:wrap}
[data-stam-calendar-mode-controls]>:first-child{flex:1 1 200px;min-width:200px}
[data-stam-calendar-mode-controls] [data-stam-calendar-mode]{min-width:0;white-space:nowrap}
