/* SLFD's operational palette, in paired light and charcoal appearances. */
html[data-theme]{--surface:#fff;--surface-soft:#f5f7f8;--surface-raised:#fff;--page:#eef2f3;--text:#20333f;--text-muted:#576e7b;--stroke:#d6e0e4;--accent:#167b83;--accent-soft:#e4f0f1;--accent-text:#155e66;--brand:#a43145;--good-bg:#e4f4ed;--good-text:#146448;--warn-bg:#fff2d9;--warn-text:#77500d;--bad-bg:#fce7ec;--bad-text:#9c2b42;--info-bg:#e5eff8;--info-text:#245c83;--map-filter:grayscale(.85) saturate(.35) contrast(.88) brightness(1.08);--surface-shadow:0 4px 18px #18384306;--nav-shadow:0 6px 24px #18384309}
html[data-theme=dark]{--surface:#1a2229;--surface-soft:#202b33;--surface-raised:#25313a;--page:#10171c;--text:#e3edf2;--text-muted:#a8bbc7;--stroke:#34444e;--accent:#66c1c6;--accent-soft:#263d43;--accent-text:#ade4e7;--brand:#b43e53;--good-bg:#1b3c31;--good-text:#a1e6c8;--warn-bg:#443826;--warn-text:#f4d295;--bad-bg:#4a2b36;--bad-text:#ffc1cf;--info-bg:#263d50;--info-text:#b6dcf7;--map-filter:grayscale(1) invert(1) brightness(.72) contrast(.85);--surface-shadow:0 5px 20px #00000012;--nav-shadow:0 10px 30px #00000020}
html[data-theme]{--nav:var(--surface);--paper:var(--surface);--ink:var(--text);--muted:var(--text-muted);--line:var(--stroke);--blue:var(--brand);--blue-dark:#882d3f;--blue-soft:var(--accent-soft);--app-card:var(--surface);--app-ink:var(--text);--app-line:var(--stroke);--app-soft:var(--surface-soft);--app-bluewash:var(--accent-soft);--slfd-ink:var(--text);--slfd-muted:var(--text-muted);--slfd-line:var(--stroke);--slfd-surface:var(--surface);--slfd-accent:var(--brand);--slfd-navy:var(--text);--slfd-teal:var(--accent);--slfd-shadow:var(--surface-shadow);background:var(--page);color:var(--text)}
html[data-theme] body,html[data-theme] body.live-viewer{background:var(--page);color:var(--text);--app-card:var(--surface);--app-ink:var(--text);--app-line:var(--stroke);--app-soft:var(--surface-soft);--app-bluewash:var(--accent-soft)}
html[data-theme] body :is(h1,h2,h3,h4,h5){color:var(--text)}html[data-theme] body :is(small,.muted,.breadcrumb,.weather-source-note,.weather-heading>span,.source-chooser-prompt,.readiness-note,.pilot p,.table-footer,.maintenance-result-note){color:var(--text-muted)}
html[data-theme] body :is(.eyebrow,.nav-label,.planning-group-label,.planning-laanc>span){color:var(--text-muted)}html[data-theme] body a{color:var(--accent-text)}html[data-theme=dark] body a{color:var(--accent)}
html[data-theme] body :is(.card,.metric,.map-card,.overview-flight-card,.login-card,.aircraft-record-card,.maintenance-work-card,.overview-readiness,.session-bar,.forecast-card,.hour-card,.pilot-card,.room-card,.board-card,.photo-upload,.feature-role-card){background:var(--surface);color:var(--text);border-color:var(--stroke);box-shadow:var(--surface-shadow);border-radius:14px}
html[data-theme] body :is(.section-title,.weather-heading){border-color:var(--stroke)}html[data-theme] body .overview-flight-card{border-left:3px solid var(--accent);background:var(--surface)}html[data-theme] body .card{border-width:1px;border-style:solid}
html[data-theme] body :is(input:not([type=checkbox]):not([type=radio]):not([type=range]),select,textarea){background:var(--surface-soft)!important;color:var(--text)!important;border-color:var(--stroke)!important;box-shadow:none}html[data-theme] body :is(input,textarea)::placeholder{color:var(--text-muted);opacity:.85}html[data-theme] body :is(input[type=checkbox],input[type=radio]){accent-color:var(--accent)}
html[data-theme] body :is(label,legend){color:var(--text)!important}html[data-theme] body #ops-form>.record-actions{box-shadow:0 -7px 14px var(--surface)!important}
html[data-theme] body button:not(.primary):not(.sensitive-action):not(.uas-source-card),html[data-theme] body .button:not(.primary){background:var(--surface)!important;color:var(--text)!important;border-color:var(--stroke)!important;box-shadow:none}
html[data-theme] body button:not(.primary):not(.sensitive-action):not(.uas-source-card):hover,html[data-theme] body .button:not(.primary):hover{background:var(--surface-soft)!important;border-color:var(--accent)!important}
html[data-theme] body :is(button.primary,.button.primary){background:var(--brand)!important;color:#fff!important;border-color:var(--brand)!important;box-shadow:0 2px 6px #0000000a}
html[data-theme] body :is(button.primary,.button.primary):hover{filter:brightness(1.08)}html[data-theme] body :focus-visible{outline:3px solid var(--accent);outline-offset:3px}
html[data-theme] body .sidebar{background:var(--surface);color:var(--text);border-color:var(--stroke);border-radius:16px;box-shadow:var(--nav-shadow)}html[data-theme] body .sidebar :is(.program-brand,.program-brand small,.program-brand strong,.video-link,.sidebar-bottom p,.nav-group>summary,.nav-group-links a){color:var(--text)}
html[data-theme] body .sidebar .nav-group>summary{font-size:12px;font-weight:650}html[data-theme] body .sidebar .nav-group>summary .ui-icon{color:var(--text-muted)}html[data-theme] body .sidebar :is(.nav-group-links a,.nav-group>summary):hover{background:var(--surface-soft);color:var(--text)}html[data-theme] body .sidebar .nav-group-links a[aria-current=page]{background:var(--accent-soft);color:var(--accent-text);border:1px solid var(--stroke);border-left:3px solid var(--accent)}
html[data-theme] body .sidebar :is(.sidebar-bottom,.nav-group-links){border-color:var(--stroke)}html[data-theme] body .sidebar-bottom .video-link{background:var(--surface-soft);border-color:var(--stroke)}
html[data-theme] body .workspace-header,html[data-theme] body.live-viewer .topbar{background:var(--surface);color:var(--text);border-color:var(--stroke);box-shadow:none;backdrop-filter:none}
html[data-theme] body.live-viewer .topbar :is(.brand,.brand strong,.brand small,#username),html[data-theme] body .account #identity{color:var(--text)}html[data-theme] body .account-dot{background:var(--accent-soft);border-color:var(--surface-soft)}
html[data-theme] body :is(#workspace-find,.finder-shortcut){color:var(--text-muted)}html[data-theme] body .workspace-header{gap:12px;min-height:78px}html[data-theme] body .workspace-heading h1{font-size:24px;font-weight:680;letter-spacing:-.04em}
html[data-theme] body :is(.viewer-menu-body,.viewer-options-body,.overview-more-body,.record-export-menu[open]>div,.column-picker[open],.feature-checkbox-dropdown[open],.uas-wall-picker-body,.uas-feed-controls-body,.contact-sharing-dialog,.contact-sharing-panel){background:var(--surface-raised)!important;color:var(--text)!important;border-color:var(--stroke)!important;box-shadow:0 10px 30px #00000020}
html[data-theme] body :is(dialog,#ops-editor){background:var(--surface);color:var(--text);border-color:var(--stroke)}html[data-theme] body :is(dialog .section-title,#ops-editor>.section-title){background:var(--surface);border-color:var(--stroke)}html[data-theme] body :is(.record-actions,.flight-check-actions,.contact-sharing-actions){background:var(--surface)!important;border-color:var(--stroke)!important;backdrop-filter:none}
html[data-theme] body :is(.form-section,.maintenance-checks,.maintenance-extra,.optional-record-fields,.record-context,.procedure-item,.flight-flow-cards li,.flight-guide-step,.flight-guide-summary,.check-section){background:var(--surface-soft);border-color:var(--stroke);color:var(--text)}html[data-theme] body :is(.form-section legend,.maintenance-checks legend,.maintenance-editor label small){color:var(--text-muted)}
html[data-theme] body :is(.maintenance-overview,.maintenance-form-intro){background:linear-gradient(110deg,var(--surface-soft),var(--surface));border-color:var(--stroke);box-shadow:none}html[data-theme] body :is(.maintenance-overview p,.maintenance-form-intro p,.maintenance-stats span,.maintenance-work-card>small,.maintenance-excerpt,.maintenance-work-top>small,.maintenance-steps li){color:var(--text-muted)}html[data-theme] body .maintenance-stats strong{color:var(--text)}html[data-theme] body .maintenance-steps li{border-color:var(--stroke)}html[data-theme] body .maintenance-steps li:before{background:var(--accent-soft);color:var(--accent-text)}html[data-theme] body .maintenance-check-row{border-color:var(--stroke)}
html[data-theme] body :is(.segmented-control,.table-tools,.aircraft-view-toolbar,.metar,.forecast-card.night,.wx-radio-card,.wx-fact,.wx-source-card,.wx-brief-controls,.wx-tabs){background:var(--surface-soft);color:var(--text);border-color:var(--stroke)}
html[data-theme] body :is(.segmented-control button[aria-pressed=true],button[role=tab][aria-selected=true]){background:var(--accent-soft)!important;color:var(--accent-text)!important;border-color:var(--accent)!important}
html[data-theme] body :is(.records-table,.records-table td,.records-table th,.user-row,.pilot,.attachment-row){border-color:var(--stroke);color:var(--text)}html[data-theme] body :is(.records-table th,.records-table thead,.records-table th button){background:var(--surface-soft)!important;color:var(--text)!important}html[data-theme] body .records-table tr:hover td{background:var(--surface-soft)}html[data-theme] body .records-empty{background:var(--surface-soft);border-color:var(--stroke);color:var(--text-muted)}
html[data-theme] body .records-empty h3{color:var(--text)}html[data-theme] body .records-empty p{color:var(--text-muted)}html[data-theme] body :is(.aircraft-record-card small,.aircraft-record-card dt,.aircraft-card-top small){color:var(--text-muted)}html[data-theme] body :is(.aircraft-record-card dd,.aircraft-record-card h3){color:var(--text)}
html[data-theme] body :is(.record-status-badge,.status-tag,.badge,.station-tag,.pill){background:var(--surface-soft);color:var(--text-muted);border-color:var(--stroke)}
html[data-theme] body :is(.record-status-badge[data-tone=good],.status-tag.active,.overview-condition.safe){background:var(--good-bg);color:var(--good-text);border-color:var(--good-text)}
html[data-theme] body :is(.record-status-badge[data-tone=attention],.overview-condition.caution,.weather-alert,.alert-summary.has-alerts){background:var(--warn-bg);color:var(--warn-text);border-color:var(--warn-text)}
html[data-theme] body :is(.record-status-badge[data-tone=critical],.overview-condition.unsafe){background:var(--bad-bg);color:var(--bad-text);border-color:var(--bad-text)}html[data-theme] body .record-status-badge[data-tone=info]{background:var(--info-bg);color:var(--info-text);border-color:var(--stroke)}
html[data-theme] body .overview-condition{background:var(--surface-soft);color:var(--text);border-color:var(--text-muted)}html[data-theme] body .overview-condition :is(strong,span){color:inherit}
html[data-theme] body :is(.inline-note,.alert-summary,#ops-message:not(:empty),#ops-editor-message:not(:empty),#status:not(:empty),.flight-guide-note){background:var(--accent-soft);color:var(--accent-text);border-color:var(--stroke)}
html[data-theme] body :is(#flight-check-status:not(:empty),.contact-sharing [role=status]:not(:empty)){background:var(--accent-soft)!important;color:var(--accent-text)!important;border-color:var(--stroke)!important}html[data-theme] body #notice:not(:empty){background:var(--warn-bg);color:var(--warn-text);border-color:var(--warn-text)}
html[data-theme] body :is(#preflight-map,#mission-brief-map){background:var(--surface-soft);border-color:var(--stroke)}:is(#preflight-map,#mission-brief-map) .leaflet-tile-pane{filter:var(--map-filter)}
html[data-theme] body .weather-hero{background:linear-gradient(130deg,#16424c,#20636d);box-shadow:var(--surface-shadow);border:1px solid #477983}html[data-theme=dark] body .weather-hero{background:linear-gradient(130deg,#20353e,#23464d);border-color:#38616a}
html[data-theme] body .weather-hero :is(h3,strong,p,a){color:#f3fbfc}html[data-theme] body .weather-hero :is(.eyebrow,small,.weather-facts span,.weather-timestamp){color:#c1e0e5}html[data-theme] body .weather-hero :is(.is-stale,.is-unavailable){color:#ffe1a6!important}html[data-theme] body :is(.hour-card small,.forecast-card p,.forecast-card small){color:var(--text-muted)}
html[data-theme] body .is-stale{color:var(--warn-text)!important}html[data-theme] body .is-unavailable{color:var(--bad-text)!important}
html[data-theme] body .uas-panel .uas-wall.is-wall.adaptive-wall{background:var(--surface-soft);border-color:var(--stroke);box-shadow:var(--surface-shadow)}html[data-theme] body .uas-panel .uas-wall.is-wall.adaptive-wall .uas-card{background:var(--surface);color:var(--text);border-color:var(--stroke);box-shadow:none}html[data-theme] body .uas-panel .uas-wall.is-wall.adaptive-wall .uas-card h3{color:var(--text)}
html[data-theme] body .uas-source-card{background:var(--surface);color:var(--text);border-color:var(--stroke);box-shadow:var(--surface-shadow)}html[data-theme] body .uas-source-card :is(strong,h3){color:var(--text)}html[data-theme] body .uas-source-card :is(small,.uas-source-kind){color:var(--text-muted)}
html[data-theme] body .uas-source-card[data-source-status=online]{border-color:var(--good-text)}html[data-theme] body .uas-source-card[data-source-status=offline]{border-color:var(--stroke)}
html[data-theme] body :is([data-uas-feed-status],.uas-source-status){color:var(--text);background:var(--surface-soft);border-color:var(--stroke)}
html[data-theme] body :is([data-uas-feed-status].online,.uas-source-card[data-source-status=online] .uas-source-status){background:var(--good-bg)!important;color:var(--good-text)!important}
html[data-theme] body :is([data-uas-feed-status].offline,.uas-source-card[data-source-status=offline] .uas-source-status){background:var(--bad-bg)!important;color:var(--bad-text)!important}
html[data-theme] body .uas-video{background:#0b1117}html[data-theme] body .uas-panel .uas-feed-controls-body{background:var(--surface-raised)!important;color:var(--text)!important;border-color:var(--stroke)!important}
html[data-theme] body :is(.feature-checkbox-dropdown,.feature-checkbox-list,.feature-role-presets,.contact-sharing-people,.contact-sharing-preview,.contact-sharing-feed,.contact-sharing-tabs,#mfa-key,.telemetry-source,.room-item,.board-task){background:var(--surface-soft);color:var(--text);border-color:var(--stroke)}
html[data-theme] body :is(#workspace-find-results a,#workspace-find-status,.workspace-finder-heading){color:var(--text)}html[data-theme] body :is(#workspace-find-results a:hover,#workspace-find-results a[aria-current=page]){background:var(--accent-soft)}html[data-theme] body .workspace-finder-heading{background:var(--surface);border-color:var(--stroke)}
html[data-theme] body #publisher-list button{background:var(--surface-soft)!important}html[data-theme] body footer{color:var(--text-muted);border-color:var(--stroke)}
.appearance-control{display:inline-flex!important;align-items:center;gap:7px;margin:0!important;padding:3px 7px;border:1px solid var(--stroke);border-radius:9px;background:var(--surface);color:var(--text);flex:0 0 auto;max-width:125px}.appearance-icon{font-size:18px;line-height:1;color:var(--accent)}
html[data-theme] body.live-viewer :is(.viewer-menu>summary,.viewer-options>summary){background:var(--surface-soft)!important;color:var(--text)!important;border-color:var(--stroke)!important}html[data-theme] body.live-viewer .viewer-menu-body :is(a,.header-link){color:var(--text);border-color:var(--stroke)}html[data-theme] body.live-viewer .viewer-menu-body a:hover{background:var(--surface-soft)}html[data-theme] body .viewer-tools{background:var(--surface-raised);color:var(--text);border-color:var(--stroke)}
html[data-theme] body.live-viewer .topbar .viewer-menu-body .header-link{background:var(--surface-soft)!important;color:var(--text)!important;border-color:var(--stroke)!important}
html[data-theme] body :is(.streaming-card,#streaming-status,.upload-preview,.photo-preview>article,.reference-panel){background:var(--surface);color:var(--text);border-color:var(--stroke)}html[data-theme] body .streaming-card p{color:var(--text-muted)}html[data-theme] body>header:not(.mobile-brand):not(.topbar){background:var(--surface);color:var(--text);border-color:var(--stroke)}html[data-theme] body>header:not(.mobile-brand):not(.topbar) :is(.brand,.brand strong,.brand small,nav a){color:var(--text)}
html[data-theme] .appearance-control select{width:83px;min-height:31px!important;height:31px;margin:0!important;padding:3px 16px 3px 3px!important;border:0!important;background:transparent!important;font-size:12px!important;cursor:pointer}.viewer-header-tools{display:flex;align-items:center;justify-content:flex-end;gap:12px;flex-wrap:wrap}#login>.appearance-control{float:right;margin:0 0 12px 12px!important}body>main>header>.appearance-control{margin-bottom:14px!important}
.sr-only{position:absolute!important;width:1px!important;height:1px!important;padding:0!important;margin:-1px!important;overflow:hidden!important;clip:rect(0,0,0,0)!important;white-space:nowrap!important;border:0!important}
html[data-theme] body :is(.wx-assessment,.wx-table,.wx-chart,.wx-data-note,.preflight-site,.preflight-brief,.preflight-facts>div,.guide-confirm,#guide-dependencies,#guide-risk:not(:empty),#guide-approval:not(:empty),#flight-check-context,.admin-stream-sharing,.contact-picker,.contact-result,.contact-link-row){background:var(--surface-soft)!important;color:var(--text)!important;border-color:var(--stroke)!important}
html[data-theme] body :is(.wx-table th,.wx-table td,.wx-table th:first-child,.wx-table td:first-child){background:var(--surface);color:var(--text);border-color:var(--stroke)}html[data-theme] body .wx-table thead th{background:var(--surface-raised);color:var(--text)}html[data-theme] body .wx-chart text{fill:var(--text-muted)}
html[data-theme] body .wx-assessment.within{border-left-color:var(--good-text)!important}html[data-theme] body .wx-assessment.exceeded{border-left-color:var(--bad-text)!important}html[data-theme] body :is(.wx-assessment.incomplete,.wx-assessment.advisory){border-left-color:var(--warn-text)!important}html[data-theme] body .wx-table tr.wx-exceeded td{border-bottom-color:var(--bad-text)}
html[data-theme] body :is(.wx-sources,.wx-data-note,#guide-help,#flight-check-log-state,#flight-check-progress,.contact-quick-help,.preflight-facts strong){color:var(--text-muted)}html[data-theme] body .wx-tabs button[aria-pressed=true]{background:var(--accent-soft)!important;color:var(--accent-text)!important;border-color:var(--accent)!important}
html[data-theme] body :is(.flight-check-header,.flight-check-footer,.guide-footer,.contact-sharing-heading,.mobile-share-dock){background:var(--surface)!important;color:var(--text);border-color:var(--stroke);box-shadow:none}html[data-theme] #guide-steps button[aria-current=step]{background:var(--accent-soft)!important;color:var(--accent-text)!important;border-color:var(--accent)!important}
html[data-theme] body .flight-weather-banner.safe{background:var(--good-bg);color:var(--good-text);border-color:var(--good-text)}html[data-theme] body .flight-weather-banner.unsafe{background:var(--bad-bg);color:var(--bad-text);border-color:var(--bad-text)}html[data-theme] body .flight-weather-banner.caution{background:var(--warn-bg);color:var(--warn-text);border-color:var(--warn-text)}html[data-theme] body .flight-weather-banner.unknown{background:var(--surface-soft);color:var(--text);border-color:var(--text-muted)}html[data-theme] body .flight-weather-banner small{color:inherit}
html[data-theme] body [data-uas-source]{background:var(--surface)!important;color:var(--text)!important;border-color:var(--stroke)!important;box-shadow:var(--surface-shadow)}html[data-theme] body [data-uas-source] :is(strong,small){color:var(--text)!important}html[data-theme] body [data-uas-source][data-source-status=online]>span,html[data-theme] body [data-uas-feed-status][data-source-status=online]{background:var(--good-bg)!important;color:var(--good-text)!important}html[data-theme] body [data-uas-source][data-source-status=offline]>span{background:var(--bad-bg)!important;color:var(--bad-text)!important}html[data-theme] body [data-uas-source][data-source-status=unknown]>span{background:var(--surface-soft)!important;color:var(--text-muted)!important}
html[data-theme] body .uas-panel :is(.uas-feed-controls>summary,.uas-wall-picker>summary){background:var(--surface-raised);color:var(--text)!important;border-color:var(--stroke)}html[data-theme] body .uas-panel .uas-card[data-source-status=offline] [data-uas-feed-status]{background:var(--bad-bg)!important;color:var(--bad-text)!important}html[data-theme] body .uas-panel .uas-card[data-source-status=online] [data-uas-feed-status]{background:var(--good-bg)!important;color:var(--good-text)!important}html[data-theme] body .uas-panel .uas-card[data-source-status=offline] [data-uas-player-status]{color:var(--warn-text)!important}html[data-theme] body .uas-panel .source-chooser-prompt{background:var(--surface-soft);color:var(--text-muted);border-color:var(--stroke)}html[data-theme] body [data-uas-source][aria-pressed=true]{border-color:var(--accent)!important;box-shadow:0 0 0 1px var(--accent)}
@media(max-width:1100px){html[data-theme] .workspace-header .account #identity{display:none}html[data-theme] .workspace-header .account-dot{display:none}}
@media(max-width:600px){html[data-theme] body .workspace-header{gap:8px;flex-wrap:wrap}.workspace-header .appearance-control{margin-left:auto!important}.workspace-header .workspace-heading{flex-basis:calc(100% - 60px)}html[data-theme] .appearance-control select{width:75px}.appearance-control{gap:4px;max-width:112px}.viewer-header-tools{gap:7px}html[data-theme] body.live-viewer .topbar{padding:13px;gap:9px;align-items:flex-start;flex-wrap:wrap}.live-viewer .brand{flex:1 1 200px}.live-viewer .viewer-header-tools{flex:1 1 auto}.live-viewer #account{flex:0 0 auto}.live-viewer .brand small{font-size:10px}}
@media(max-width:850px){html[data-theme] body .workspace-header{display:grid;grid-template-columns:44px minmax(0,1fr) auto;align-items:center;gap:8px;padding:12px 16px}html[data-theme] .workspace-header #workspace-menu{grid-column:1;grid-row:1;padding:8px}html[data-theme] .workspace-header .workspace-heading{grid-column:2;grid-row:1}html[data-theme] .workspace-header .account{grid-column:3;grid-row:1;padding:0;border:0;flex-basis:auto;justify-content:flex-end}html[data-theme] .workspace-header #workspace-find{grid-column:1/3;grid-row:2;justify-self:start;min-height:38px}html[data-theme] .workspace-header .appearance-control{grid-column:3;grid-row:2;margin:0!important}html[data-theme] .workspace-header .account button{min-height:38px}}
@media(prefers-reduced-motion:no-preference){html[data-theme] :is(.card,.metric,.maintenance-work-card,.aircraft-record-card,.uas-source-card){transition:border-color .18s ease,box-shadow .18s ease,transform .18s ease}}

html[data-theme] body.field-utility section{background:var(--surface);color:var(--text);border-color:var(--stroke)}html[data-theme] body.field-utility :is(header,section,article,figure){border-color:var(--stroke)}

/* Operational dashboard: compact metrics and purposeful movement. */
html[data-theme] [data-panel="overview"]{display:grid;grid-template-columns:minmax(0,1.02fr) minmax(0,.98fr);gap:14px;align-items:stretch}
html[data-theme] [data-panel="overview"]>.welcome{grid-column:1/-1;order:1;padding:0 0 2px;margin:0;min-width:0}
html[data-theme] [data-panel="overview"]>.welcome h2{font-size:clamp(24px,2.2vw,31px);margin-bottom:3px}
html[data-theme] [data-panel="overview"]>.streamlined-overview{grid-column:1/-1;order:2;margin:0;display:block}
html[data-theme] [data-panel="overview"] .program-summary{display:grid;grid-template-columns:minmax(135px,.8fr) minmax(0,3.2fr) auto;align-items:center;gap:14px;padding:15px 18px;border-radius:16px}
html[data-theme] [data-panel="overview"] .program-summary>.eyebrow{display:none}
html[data-theme] [data-panel="overview"] .program-summary>h3{margin:0;font-size:15px}
html[data-theme] [data-panel="overview"] .program-summary>.muted{display:none}
html[data-theme] [data-panel="overview"] .program-summary>a{white-space:nowrap;font-size:12px}
html[data-theme] [data-panel="overview"] .summary-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:0;margin:0}
html[data-theme] [data-panel="overview"] .summary-stats>div{padding:0 14px;border-left:1px solid var(--stroke);min-width:0}
html[data-theme] [data-panel="overview"] .summary-stats strong{font-size:22px;line-height:1.15;overflow-wrap:anywhere}
html[data-theme] [data-panel="overview"] .summary-stats span{display:block;font-size:11px;margin-top:4px;color:var(--text-muted)}
html[data-theme] [data-panel="overview"]>.overview-flight-card{grid-column:1;order:3;margin:0;padding:22px;display:flex;flex-direction:column;justify-content:space-between;gap:22px;border-radius:18px;position:relative;overflow:hidden;background:linear-gradient(145deg,var(--surface),var(--surface-soft))}
html[data-theme] [data-panel="overview"] .overview-flight-card h3{font-size:24px;letter-spacing:-.035em;margin:0 0 14px}
html[data-theme] [data-panel="overview"] .command-steps{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px;padding:0;margin:20px 0 14px;list-style:none}
html[data-theme] [data-panel="overview"] .command-steps li{font-size:12px;color:var(--text);font-weight:650;min-width:0}
html[data-theme] [data-panel="overview"] .command-steps li span{display:block;color:var(--accent-text);background:var(--accent-soft);border:1px solid var(--stroke);border-radius:10px;padding:9px 10px;margin-bottom:6px;font-size:13px}
html[data-theme] [data-panel="overview"] .command-subtext{font-size:12px;color:var(--text-muted);margin:0}
html[data-theme] [data-panel="overview"] .overview-flight-actions{display:flex;flex-wrap:wrap;gap:8px}
html[data-theme] [data-panel="overview"]>.overview-weather-grid{grid-column:2;order:4;margin:0;display:grid;grid-template-columns:minmax(0,1fr);gap:12px}
html[data-theme] [data-panel="overview"] .weather-hero,html[data-theme] [data-panel="overview"] .overview-readiness{margin:0;padding:18px 20px;border-radius:18px}
html[data-theme] [data-panel="overview"] .weather-hero{min-height:0}
html[data-theme] [data-panel="overview"] .weather-temp{font-size:36px;line-height:1}
html[data-theme] [data-panel="overview"] .weather-facts{margin-top:10px;padding-top:10px}
html[data-theme] [data-panel="overview"] .overview-readiness h3{margin:0 0 4px}
html[data-theme] [data-panel="overview"] .overview-readiness label{margin:6px 0 4px}
html[data-theme] [data-panel="overview"] .readiness-note{margin:8px 0 2px}
html[data-theme] [data-panel="overview"]>#flight-guide-resume{grid-column:1/-1;order:5}
html[data-theme] [data-panel="overview"]>.overview-utility-grid{grid-column:1/-1;order:6;margin:0}
html[data-theme] [data-panel="overview"]>.overview-metar{grid-column:1/-1;order:7;margin:0}
html[data-theme] [data-panel="overview"]>.alert-summary{grid-column:1/-1;order:8;margin:0}
html[data-theme] .sidebar .nav-group-links a[aria-current=page]{box-shadow:inset 0 0 0 1px var(--accent-soft)}
html[data-theme] body.live-viewer .uas-panel .uas-heading{border-bottom:1px solid var(--stroke);padding-bottom:15px;margin-bottom:16px}
html[data-theme] body.live-viewer .uas-panel .uas-source-buttons{gap:12px}
html[data-theme] body.live-viewer .uas-panel .uas-source{border-radius:16px;min-height:94px;padding:15px 18px;position:relative;overflow:hidden}
html[data-theme] body.live-viewer .uas-panel .uas-source[aria-pressed="true"]{box-shadow:inset 0 0 0 2px var(--accent);border-color:var(--accent)!important}
html[data-theme] body.live-viewer .uas-panel .uas-source strong{font-size:16px;letter-spacing:-.02em}
html[data-theme] body.live-viewer .uas-panel .uas-source small{color:var(--text-muted)}
@media (prefers-reduced-motion:no-preference){
 html[data-theme] [data-panel="overview"]>.streamlined-overview,html[data-theme] [data-panel="overview"]>.overview-flight-card,html[data-theme] [data-panel="overview"]>.overview-weather-grid{animation:command-reveal .48s cubic-bezier(.2,.7,.2,1) both}
 html[data-theme] [data-panel="overview"]>.overview-flight-card{animation-delay:.08s}html[data-theme] [data-panel="overview"]>.overview-weather-grid{animation-delay:.16s}
 html[data-theme] [data-panel="overview"] .weather-hero-top svg{animation:weather-drift 5s ease-in-out infinite}
 html[data-theme] body.live-viewer .uas-panel .uas-source[data-source-status="online"] span:before{animation:live-breathe 2s ease-in-out infinite}
 html[data-theme] body.live-viewer .uas-panel .uas-source:hover{transform:translateY(-3px);box-shadow:0 10px 26px #0002}
 html[data-theme] [data-panel="overview"] .command-steps li span{transition:transform .2s ease,background .2s ease}html[data-theme] [data-panel="overview"] .command-steps li:hover span{transform:translateY(-3px)}
}
@keyframes command-reveal{from{opacity:0;transform:translateY(12px)}to{opacity:1;transform:translateY(0)}}
@keyframes weather-drift{0%,100%{transform:translateY(0)}50%{transform:translateY(-5px)}}
@keyframes live-breathe{0%,100%{opacity:1}50%{opacity:.35}}
@media(max-width:900px){html[data-theme] [data-panel="overview"] .program-summary{grid-template-columns:1fr auto}html[data-theme] [data-panel="overview"] .program-summary .summary-stats{grid-column:1/-1;grid-row:2}html[data-theme] [data-panel="overview"] .program-summary .summary-stats>div:first-child{border-left:0;padding-left:0}}
@media(max-width:700px){html[data-theme] [data-panel="overview"]{grid-template-columns:minmax(0,1fr)}html[data-theme] [data-panel="overview"]>.overview-flight-card,html[data-theme] [data-panel="overview"]>.overview-weather-grid{grid-column:1}html[data-theme] [data-panel="overview"] .program-summary .summary-stats{grid-template-columns:repeat(2,minmax(0,1fr));row-gap:14px}html[data-theme] [data-panel="overview"] .summary-stats>div:nth-child(3){border-left:0;padding-left:0}html[data-theme] [data-panel="overview"] .command-steps{grid-template-columns:repeat(4,minmax(0,1fr));gap:5px}html[data-theme] [data-panel="overview"] .command-steps li{font-size:10px}html[data-theme] [data-panel="overview"] .command-steps li span{padding:7px}html[data-theme] [data-panel="overview"]>.overview-flight-card{padding:18px}}
@media(max-width:700px){html[data-theme] [data-panel="overview"] .overview-flight-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}html[data-theme] [data-panel="overview"] .overview-flight-actions>button,html[data-theme] [data-panel="overview"] .overview-flight-actions>details{width:100%;min-width:0;margin:0}html[data-theme] [data-panel="overview"] .overview-flight-actions>button{font-size:12px;line-height:1.25;padding:8px}html[data-theme] [data-panel="overview"] .overview-flight-actions>details>summary{height:100%;display:flex;align-items:center;justify-content:center;font-size:12px}}
@media(min-width:901px){html[data-theme] [data-panel="overview"]>.overview-weather-grid{display:contents}html[data-theme] [data-panel="overview"] .overview-weather-grid>.weather-hero{grid-column:2;order:4}html[data-theme] [data-panel="overview"] .overview-weather-grid>.overview-readiness{grid-column:1/-1;order:5;display:grid;grid-template-columns:minmax(160px,1fr) minmax(190px,1fr) minmax(250px,1.2fr);column-gap:18px;align-items:center}html[data-theme] [data-panel="overview"] .overview-readiness>div:first-child{grid-column:1;grid-row:1}html[data-theme] [data-panel="overview"] .overview-readiness>label{grid-column:2;grid-row:1}html[data-theme] [data-panel="overview"] .overview-readiness>select{grid-column:2;grid-row:2}html[data-theme] [data-panel="overview"] .overview-readiness>.overview-condition{grid-column:3;grid-row:1/3}html[data-theme] [data-panel="overview"] .overview-readiness>.readiness-note{grid-column:1/3;grid-row:3}html[data-theme] [data-panel="overview"] .overview-readiness>a{grid-column:3;grid-row:3}}
html[data-theme] [data-panel="overview"]>.overview-flight-card{align-items:stretch;justify-content:flex-start;gap:14px}

/* Navy and fire red operational accents. Status colors remain semantic. */
html[data-theme]{--accent:#2c6292;--accent-soft:#e6edf6;--accent-text:#244e78;--brand:#a43145;--map-filter:grayscale(.85) saturate(.35) contrast(.88) brightness(1.08)}
html[data-theme=dark]{--accent:#98bfe8;--accent-soft:#29384a;--accent-text:#c3dcf5;--brand:#b43e53}
html[data-theme] [data-panel="overview"]>.overview-flight-card{overflow:visible;z-index:4}
html[data-theme] [data-panel="overview"] .overview-more-actions[open]{position:relative;z-index:50}
html[data-theme] body .records-table th button{display:inline-flex!important;width:auto!important;min-width:0!important;min-height:0!important;padding:4px 2px!important;margin:0!important;border:0!important;border-radius:0!important;background:transparent!important;line-height:1.3;box-shadow:none!important;text-align:left}
html[data-theme] body .records-table th{padding:10px 14px;white-space:normal}
html[data-theme] body .weather-hero{background:linear-gradient(140deg,#e4edf8,#f4f7fb)!important;color:#213b57!important;border-color:#c5d5e7!important}
html[data-theme=dark] body .weather-hero{background:linear-gradient(140deg,#26384a,#202d3a)!important;color:#e8f0f8!important;border-color:#435970!important}

.overview-extra-weather{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px;margin-top:12px}.overview-extra-weather span,.overview-extra-weather strong{display:block;font-size:11px}.overview-next-hours{margin-top:14px;border-top:1px solid var(--stroke);padding-top:12px}.overview-next-hours>strong{font-size:12px}#overview-four-hours{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;margin-top:7px}#overview-four-hours>div{background:var(--surface-soft);border:1px solid var(--stroke);border-radius:9px;padding:7px;min-width:0}#overview-four-hours :is(small,strong,span){display:block;overflow-wrap:anywhere}#overview-four-hours span{font-size:10px;color:var(--text-muted)}@media(max-width:380px){#overview-four-hours{grid-template-columns:repeat(2,minmax(0,1fr))}}
html[data-theme=light] body .weather-hero :is(h3,h3 span,p,span,strong,small,a,.eyebrow,.weather-temp,.weather-timestamp){color:#213b57!important}
html[data-theme=light] body .weather-hero svg{color:#315a86!important}

.maintenance-simple-toggle{margin:4px 0 10px}.maintenance-simple-buttons{display:flex;flex-wrap:wrap;gap:6px}.maintenance-simple-buttons[hidden]{display:none!important}.maintenance-simple-buttons button{min-height:44px;padding:8px 12px;font-size:12px}.maintenance-simple-buttons button[aria-pressed=true]{background:var(--accent-soft)!important;color:var(--accent-text)!important;border-color:var(--accent)!important;box-shadow:inset 0 0 0 1px var(--accent)!important}@media(max-width:600px){.maintenance-simple-buttons button{flex:1 1 0;min-width:0}.maintenance-simple-buttons button:nth-child(2){flex:1.6 1 0}.maintenance-check-row{margin-bottom:12px}}
/* Contrast repairs for headings, record controls, weather, and status text. */
html[data-theme] body .skip-link{background:var(--surface);color:var(--text)!important;border:1px solid var(--stroke)}
html[data-theme] body .section-title p:not(.eyebrow),html[data-theme] body :is(#telemetry-status,#telemetry-tracks p,#plan-traffic-status){color:var(--text-muted)}
html[data-theme] body .metric span,html[data-theme] body .map-footer span{color:var(--text-muted)}
html[data-theme] body #map-status:not(:empty){color:var(--warn-text)}
html[data-theme] body .record-export-menu>summary{background:var(--surface-soft);border-color:var(--stroke);color:var(--text)}
html[data-theme] body .observation-hero>span{background:var(--surface-soft);color:var(--text);border:1px solid var(--stroke)}
html[data-theme] body.live-viewer .viewer-options>.viewer-tools{background:var(--surface-raised);color:var(--text);border-color:var(--stroke)}

/* Compact, aligned workflow and weather controls. */
html[data-theme] [data-panel="overview"] .command-steps li span{display:inline;color:var(--accent-text);background:none;border:0;padding:0;margin:0 5px 0 0;border-radius:0}
html[data-theme] [data-panel="overview"] .command-steps li:hover span{transform:none}
html[data-theme] [data-panel="overview"] .overview-flight-actions{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px;align-items:stretch}
html[data-theme] [data-panel="overview"] .overview-flight-actions>button,html[data-theme] [data-panel="overview"] .overview-flight-actions>details{width:100%;min-width:0;margin:0}
html[data-theme] [data-panel="overview"] .overview-flight-actions>details>summary{min-height:48px;height:100%;display:flex;align-items:center;justify-content:center}
@media(min-width:901px){html[data-theme] [data-panel="overview"] .overview-weather-grid>.overview-readiness{grid-template-columns:minmax(200px,1fr) minmax(200px,1fr) minmax(240px,1.1fr);align-items:start;row-gap:8px}html[data-theme] [data-panel="overview"] .overview-readiness>label{grid-column:2;grid-row:1}html[data-theme] [data-panel="overview"] .overview-readiness>select{grid-column:2;grid-row:2}html[data-theme] [data-panel="overview"] .overview-readiness>.overview-condition{grid-column:3;grid-row:1/3}html[data-theme] [data-panel="overview"] .overview-readiness>.readiness-note{grid-row:3}html[data-theme] [data-panel="overview"] .overview-readiness>a{grid-row:3}}
.wx-workspace #wx-location{align-items:end}.wx-workspace #wx-location label{display:flex;flex-direction:column;gap:6px;margin:0}.wx-workspace #wx-location input,.wx-workspace #wx-location button{min-height:48px;margin:0}.readiness-maintenance{margin-top:24px}.readiness-maintenance h4{margin-bottom:10px}

@media(min-width:901px){html[data-theme] [data-panel="overview"] .overview-readiness>.overview-weather-criteria{grid-column:2;grid-row:1/3;margin:0;align-self:center}}

/* Responsive workspace header: the menu needs room for both its icon and text. */
@media(max-width:850px){html[data-theme] body .workspace-header{grid-template-columns:max-content minmax(0,1fr) max-content;column-gap:12px}html[data-theme] .workspace-header #workspace-menu{width:auto;min-width:0;white-space:nowrap}html[data-theme] .workspace-header .workspace-heading{min-width:0}html[data-theme] .workspace-header .workspace-heading h1{font-size:clamp(18px,3.1vw,24px);line-height:1.15;overflow-wrap:anywhere}html[data-theme] .workspace-header .breadcrumb{overflow-wrap:anywhere}html[data-theme] .workspace-header .account{min-width:0}}
@media(max-width:420px){html[data-theme] .workspace-header #workspace-menu{width:44px;min-width:44px;justify-content:center}}
/* Month calendar: readable week grid with a compact day detail on phones. */
.calendar-section-header,.month-calendar-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap}.calendar-section-header h3,.month-calendar-heading h4{margin:0}.calendar-section-header p,.month-calendar>p{color:var(--text-muted);margin:4px 0 12px}.calendar-section-actions,.month-calendar-controls{display:flex;gap:8px;flex-wrap:wrap}.month-calendar{margin-top:18px}.month-calendar-controls button{min-width:42px;min-height:42px;margin:0}.month-calendar-grid{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:5px}.calendar-weekday{font-size:12px;font-weight:700;color:var(--text-muted);text-align:center;padding:6px}.calendar-day{position:relative;display:flex;flex-direction:column;align-items:stretch;justify-content:flex-start;gap:6px;min-width:0;min-height:112px;padding:9px;text-align:left;background:var(--surface-soft);border:1px solid var(--stroke);color:var(--text);border-radius:9px}.calendar-day-number{align-self:flex-start}.calendar-day[aria-current=date] .calendar-day-number{color:var(--accent-text);text-decoration:underline;text-underline-offset:3px}.calendar-day[aria-pressed=true]{border-color:var(--accent);box-shadow:inset 0 0 0 1px var(--accent)}.calendar-day-events{display:grid;gap:3px;min-width:0}.calendar-day-events>span{font-size:11px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.calendar-event{padding:3px 5px;border-left:3px solid var(--accent);background:var(--accent-soft);color:var(--accent-text);border-radius:4px}.calendar-event[data-kind=training]{border-left-color:#a43145}.calendar-event[data-kind=maintenance]{border-left-color:#ad7430}.calendar-event[data-status=cancelled]{text-decoration:line-through;opacity:.7}.calendar-event-count{display:none}.calendar-day-detail{margin-top:12px;padding:14px;border:1px solid var(--stroke);border-radius:10px;background:var(--surface-soft)}.calendar-day-detail h4,.calendar-day-detail p{margin:0}.calendar-detail-row{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:10px 0;border-top:1px solid var(--stroke)}.calendar-detail-row:first-of-type{margin-top:8px}.calendar-detail-row div{min-width:0}.calendar-detail-row strong,.calendar-detail-row span{display:block;overflow-wrap:anywhere}.calendar-detail-row span{color:var(--text-muted);font-size:12px}.calendar-list{margin-top:18px}.calendar-list summary{cursor:pointer;font-weight:700}.calendar-list .table-scroll{margin-top:10px}
@media(max-width:700px){.calendar-day{min-height:65px;padding:6px;align-items:center;gap:3px}.calendar-day-number{align-self:center}.calendar-day-events{display:none}.calendar-event-count{display:block;font-size:10px;font-weight:700;color:var(--accent-text);background:var(--accent-soft);border-radius:99px;padding:1px 5px}.calendar-weekday{font-size:10px;padding:4px 0}.month-calendar-grid{gap:3px}.calendar-section-actions>button{flex:1 1 auto}.calendar-detail-row{align-items:flex-start}}
@media(prefers-reduced-motion:no-preference){.calendar-day{transition:border-color .18s,transform .18s,box-shadow .18s}.calendar-day:hover{transform:translateY(-2px);border-color:var(--accent)}}
/* Consistent navy/blue status and clearer workspace hierarchy. */
html[data-theme=light] body :is(.flight-weather-banner.safe,.overview-condition.safe){background:#e5eef9;color:#163c68;border-color:#416e9c}
html[data-theme=dark] body :is(.flight-weather-banner.safe,.overview-condition.safe){background:#203b58;color:#d5eaff;border-color:#8bbce9}
html[data-theme] body .wx-assessment.within{border-left-color:var(--accent)!important}
html[data-theme] body #content :is(.card,.map-card){min-width:0}
html[data-theme] body #content :is(.section-title,.weather-heading){gap:14px;flex-wrap:wrap;align-items:center}
html[data-theme] body #content :is(h1,h2,h3,h4){overflow-wrap:anywhere}
html[data-theme] body #content :is(button,a,summary):focus-visible{outline:3px solid var(--accent);outline-offset:3px}
html[data-theme] body .calendar-section{padding:clamp(16px,2.4vw,28px)}
html[data-theme] body .calendar-section-header{padding-bottom:14px;border-bottom:1px solid var(--stroke)}
html[data-theme] body .calendar-section-header h3{font-size:clamp(20px,2vw,25px);letter-spacing:-.025em}
@media(prefers-reduced-motion:no-preference){html[data-theme] body .calendar-section{animation:command-reveal .35s ease both}}
/* Keep the full theme name visible, including in narrow windows. */
html[data-theme] body .appearance-control{max-width:none}
html[data-theme] body .appearance-control select{width:94px;min-width:94px}
/* Data-bound wind bars and compact metric surfaces. */
html[data-theme] [data-panel="overview"] .program-summary .summary-stats>div{min-width:0;border:1px solid var(--stroke);border-radius:10px;background:var(--surface-soft);padding:11px 12px}
html[data-theme] [data-panel="overview"] .program-summary .summary-stats{gap:8px}
.forecast-wind-meter{display:block;height:4px;margin-top:6px;border-radius:9px;background:var(--stroke);overflow:hidden}.forecast-wind-meter>i{display:block;height:100%;background:var(--accent);border-radius:inherit;transform-origin:left}
@media(prefers-reduced-motion:no-preference){.forecast-wind-meter>i{animation:wind-reveal .55s ease both}@keyframes wind-reveal{from{transform:scaleX(0)}to{transform:scaleX(1)}}}
