/* Shared application chrome. Map textures, entity/team colours and transparent
   fusion output keep their original meaning; only interface surfaces change. */
:root,body.radar-dark{--x-bg:#f7f9fc;--x-surface:#fff;--x-surface-2:#f0f4fa;--x-border:#d7e0ec;--x-border-soft:#e1e7ef;--x-text:#223248;--x-text-2:#63758d;--x-text-3:#8796aa;--x-accent:#2467e9;--x-success:#159a71;--x-warning:#a77c05;--x-danger:#d94350;--panel2:#f0f4fa;--card:#fff;--line:#e1e7ef;--text:#223248;--muted:#63758d;--tx:#223248;--dim:#8796aa;--acc:#2467e9;--ok:#159a71;--warn:#a77c05;--bad:#d94350}
:root,body.radar-dark{color-scheme:light;--bg:#f7f9fc;--panel:rgba(255,255,255,.97);--border:#dfe6ef;--accent:#2467e9;--green:#159a71;--red:#db4350;--t1:#223248;--t2:#697b90;--t3:#96a2b3;--shadow:0 8px 32px #263f641a;--ref-bg:#f7f9fc;--ref-map:#eef2f6;--ref-panel:#fff;--ref-panel-2:#f5f8fc;--ref-line:#dfe6ef;--ref-line-hot:#b7c9e3;--ref-text:#223248;--ref-muted:#697b90;--ref-dim:#8c9bb0;--ref-blue:#2467e9;--ref-green:#159a71;--ref-yellow:#a77c05;--ref-red:#db4350;--ref-purple:#8056c7;--ref-orange:#bc7625;--command-bg:rgba(255,255,255,.97);--command-line:#dfe6ef;--command-accent:#2467e9;--hud:#fff;--hud2:#f5f8fc;--line:#dfe6ef;--cyan:#2467e9;--amber:#a77c05}
html,body{background:#f7f9fc!important;color:#223248!important}body:before,#map:after{background:transparent!important;box-shadow:none!important}#map,.leaflet-container{background:#eef2f6!important}
.sidebar,.item-filter-panel,.operator-panel,.player-counter,.map-tabs,.radar-dock,.spectate-bar,.team-card,.team-float,.float-stats,.float-settings,.box-cfg-pop,.command-panel,.command-dock,.command-panel>header,.command-card,.rr3d-panel,.rr3d-toolbar,.rr3d-settings,.rr3d-settings-panel,.rr3d-touch-buttons,.rr3d-minibox,.fusion-panel,.fusion-settings,.modal-content,.dialog,.rr-wait-card,#toast{background:#fff!important;color:#223248!important;border-color:#dfe6ef!important;box-shadow:0 8px 32px #263f641a!important}
.sidebar:before,.sidebar:after,.panel-title,.section-title,.command-panel h2,.command-panel h3,.command-panel header small,.command-card strong,.pc-val,.map-tab,.radar-dock button,.spectate-bar button,.operator-card,.operator-card b,.operator-card strong,.operator-card small,.rr3d-panel,.rr3d-panel label,.rr3d-panel strong,.rr3d-panel h3,.rr3d-field-label,.rr3d-check,.rr3d-field-help{color:#223248!important}
.map-tab,.topbar-pill,.radar-dock button,.command-dock button,.command-card button,.rr3d-touch-buttons button,.rr3d-panel button,.rr3d-panel select,.rr3d-panel input:not([type=range]):not([type=checkbox]),.sidebar input:not([type=range]):not([type=checkbox]),.sidebar select,.btn,.operator-card{background:#f8fafd!important;border-color:#dfe6ef!important;color:#52677f!important}
.map-tab.active,.topbar-pill.active,.radar-dock button.active,.radar-dock button[aria-pressed=true],#commandRoot button[aria-pressed=true],#commandFloors button[aria-pressed=true],.operator-card.self,.operator-card.ally{background:#edf3ff!important;border-color:#c3d7fc!important;color:#2467e9!important}
#commandRoot{color:#223248}#commandRoot button,#commandFloors button{background:#f8fafd;color:#52677f;border-color:#dfe6ef}#commandRoot input:not([type=checkbox]):not([type=range]),#commandRoot select,#commandRoot textarea{background:#fff;color:#223248;border-color:#dfe6ef}#commandRoot input[type=checkbox],#commandRoot input[type=range]{accent-color:#2467e9}.command-note,.command-empty,.command-card small,.command-label,.command-filter-grid label,.pc-lbl,.cfg-lbl,.hint,.stat-label,.operator-panel label,.rr3d-status{color:#7a8ca1!important}.command-price{color:#a77c05}.command-grade{background:#fafbfd}.command-avatar{background:#e8eef7}.command-panel h3{border-color:#dfe6ef}.team-card{border-color:#dfe6ef!important}.team-card.active{background:#edf3ff!important}.rr3d-loading,.rr3d-error,.rr3d-character-notice,.rr3d-touch-controls #rr3dGestureHint{background:#fffffff2!important;color:#52677f!important;border-color:#dfe6ef!important}#rrGuard{background:rgba(246,249,253,.97)!important}.rr-wait-card h2,.rr-wait-card .rr-wait-brand{color:#223248!important}.rr-wait-card p,.rr-wait-status,.rr-wait-footer{color:#7a8ca1!important}.rr-wait-actions a{background:#edf3ff!important;color:#2467e9!important;border-color:#d3e1fa!important}.rr-wait-orbit{border-color:#dfe8f8!important}.rr-wait-orbit:before,.rr-wait-orbit:after{border-color:#dfe8f8!important}.rr3d-panel input,.rr3d-panel select,.rr3d-panel button{color-scheme:light}input[type=range]{accent-color:#2467e9}button:focus-visible,a:focus-visible,input:focus-visible,select:focus-visible{outline:2px solid #6a9cf6!important;outline-offset:3px}
/* Existing center, portal and admin controls: colour only, no geometry. */
.capability-login input,.date-filter input[type=date],.share-create select,.router-command-row input,.replay-side,.replay-stage,.online-chart,.status-callout,.center-nav,.online-event,.code-box,pre,textarea,input:not([type=range]):not([type=checkbox]),select{background:#fff!important;color:#223248!important;border-color:#dfe6ef!important}
.center-nav button.active,.online-heading button[aria-pressed=true]{background:#edf3ff!important;color:#2467e9!important;border-color:#c3d7fc!important}button.primary,.btn-accent{background:#2467e9!important;border-color:#2467e9!important;color:#fff!important}button.primary:hover:not(:disabled){background:#1857cf!important;border-color:#1857cf!important}button:hover:not(:disabled){border-color:#b7c9e3}button.model-dl{background:#eef4ff;border-color:#c3d7fc;color:#2467e9}.boot-screen{background-image:none}#login,.capability-login{box-shadow:0 12px 40px #263f6414}.online-chart text{fill:#73849b}#toast.bad{color:#bf3946!important;border-color:#edcbd0!important}

/* Match the specificity of the original dark theme without changing layout. */
body.radar-dark :is(button,select,input),
body.radar-dark :is(.operator-card,.operator-avatar,.operator-summary),
body.radar-dark .radar-settings-content :is(.layer-row,.scale-val),
body.radar-dark :is(.spectate-bar select,.spectate-btn),
body.radar-dark #rr3dPanel :is(.rr3d-panel-tabs,.rr3d-view-lock,.rr3d-setting-switch,.rr3d-map,.rr3d-status,.rr3d-hint),
body.radar-dark #rr3dPanel .rr3d-panel-tabs button,
body.radar-dark #replayTimeInput {
  background:#f5f8fc!important;color:#223248!important;border-color:#dfe6ef!important;
}
body.radar-dark button:hover {background:#eaf0f9!important;color:#223248!important;border-color:#b7c9e3!important}
body.radar-dark :is(button.on,button.active,button.panel-open,button[aria-selected=true]),
body.radar-dark .map-tab.active,body.radar-dark .radar-view-switch button.on,
body.radar-dark .item-value-form button,
body.radar-dark #rr3dPanel :is(button.on,button[aria-selected=true],.rr3d-map button) {
  background:#edf3ff!important;color:#2467e9!important;border-color:#c3d7fc!important;
}
body.radar-dark :is(.sidebar,.operator-panel,.item-filter-panel,.team-float,.float-stats,.radar-dock) {box-shadow:0 8px 32px #263f641a!important}
body.radar-dark .radar-settings-content .panel-title {color:#2467e9!important}
body.radar-dark .radar-settings-content .ltog {background:#bdc9d8!important}
body.radar-dark .radar-settings-content .ltog.on {background:#2467e9!important}
body.radar-dark .radar-settings-content .scale-slider::-webkit-slider-runnable-track {background:#dfe6ef}
body.radar-dark .radar-settings-content .scale-slider::-moz-range-track {background:#dfe6ef}
body.radar-dark .operator-health {background:#e1e7ef}
body.radar-dark ::-webkit-scrollbar-thumb {background:#bdc9d8}
body.radar-dark ::-webkit-scrollbar-track {background:#f5f8fc}
.topbar,#commandFloors,.command-alert,.xxx-tactical-panel,.xxx-tactical-fab,.xxx-tactical-alert {background:#fffffff5!important;color:#223248!important;border-color:#dfe6ef!important;box-shadow:0 8px 32px #263f641a!important}
.xxx-tactical-header,.xxx-tactical-tabs,.xxx-tactical-event,.xxx-tactical-loot-group,.xxx-tactical-panel footer {background:#f5f8fc!important;border-color:#dfe6ef!important}
.xxx-tactical-header strong,.xxx-tactical-line,.xxx-tactical-line b,.xxx-tactical-loot-head strong,.xxx-tactical-loot-row,.xxx-tactical-alert strong {color:#223248!important}
.xxx-tactical-time,.xxx-tactical-empty,.xxx-tactical-meta,.xxx-tactical-loot-head span,.xxx-tactical-panel footer {color:#697b90!important}
.xxx-tactical-header button,.xxx-tactical-tabs button {background:#fff!important;color:#52677f!important;border-color:#dfe6ef!important}
.xxx-tactical-tabs button.active {background:#edf3ff!important;color:#2467e9!important;border-color:#c3d7fc!important}
.xxx-tactical-line .killer {color:#bf3946!important}.xxx-tactical-line .loot,.xxx-tactical-loot-total,.xxx-tactical-loot-row em {color:#a77c05!important}.xxx-tactical-line .picker {color:#159a71!important}
#commandPlayers .team-section-heading,#commandPlayers .player-account-row .player-name,#commandPlayers .player-weapon,#commandPlayers .player-weapon.is-unarmed .weapon-name {color:#697b90!important}
#commandPlayers .team-section-heading small,#commandPlayers .player-weapon.is-pending .weapon-name {color:#8796aa!important}
#commandPlayers .player-role-row .hero-name {color:#223248!important}
#commandPlayers .team-section-heading::after {background:linear-gradient(90deg,#dfe6ef,transparent)}
#commandPlayers .player-item {background:#f5f8fc!important;border-color:#dfe6ef!important}
#commandPlayers .player-item.is-downed {background:#fff2f3!important;border-color:#edcbd0!important}
#commandPlayers .player-item.is-dead {background:#f0f2f6!important}
#commandPlayers .player-card-meta {border-color:#dfe6ef!important}
#commandLootRail .loot-rail-heading,#commandLootRail .loot-rail-image {background:#f0f4fa!important}
#commandLootRail .loot-rail-title,#commandLootRail .loot-rail-chevron {color:#52677f!important}
#commandLootRail .loot-rail-row {border-color:#dfe6ef!important}
#commandLootRail .loot-rail-row:hover {background:#edf3ff!important}
#commandLootRail .loot-rail-row[aria-pressed=true] {background:#fff9e9!important}
#commandLootRail .loot-rail-image small {background:#fffffff2!important}
#commandLootRail .loot-rail-copy small,#commandLootRail .loot-rail-empty {color:#697b90!important}
body #replayToolbar,body #replayToolbar[data-notice=true] #replaySeekHint {background:#fff!important;color:#223248!important;border-color:#dfe6ef!important;box-shadow:0 8px 32px #263f641a!important}
body #replayToolbar .rr-replay-row>label,body #replayClock,body #replayJumpForm {color:#697b90!important}
body #replayJump {background:#edf3ff!important;color:#2467e9!important;border-color:#c3d7fc!important}
input,select,textarea {color-scheme:light!important}
.primary-btn,.login-box button {background:#2467e9!important;color:#fff!important;border-color:#2467e9!important}
.primary-btn:hover:not(:disabled),.login-box button:hover:not(:disabled) {background:#1857cf!important}
#rrGuard,#commandFloors>span {color:#697b90!important}
#commandPlayers .equip-item.is-empty,#commandPlayers .equip-item.is-empty .equip-level,#commandPlayers .equip-item.is-durability-only .equip-level {color:#697b90!important}
#commandPlayers .player-health {background:#e1e7ef}
#commandPlayers .player-health span {color:#223248}
.panel,.stat-card,.package-format-card,.router-package-meta>div,.share-code {background:#fff!important;color:#223248!important;border-color:#dfe6ef!important}
.badge-dim {background:#edf1f6!important;color:#63758d!important}
.badge-green {background:#e7f6ef!important;color:#117c5b!important}
button:not(.primary):not(.primary-btn):not(.cbtn-ok):hover:not(:disabled) {background:#edf3ff!important;color:#2467e9!important}
#rr3dCameraQuick,#rrSplitResize,#rr3dMiniResize {background:#fffffff5!important;color:#52677f!important;border-color:#dfe6ef!important;box-shadow:0 4px 18px #263f641a!important}
#rr3dMiniBox {background:#fff!important;border-color:#d7e0ec!important;box-shadow:0 0 0 4px #ffffffaa,0 6px 24px #263f641a!important}
.radar-tooltip,.leaflet-popup-content-wrapper,.leaflet-popup-tip {background:#fff!important;color:#223248!important;border-color:#dfe6ef!important;box-shadow:0 4px 18px #263f641a!important}
