﻿/*
 * FlightOps Operations Console Theme
 *
 * Purpose:
 * - Layer a dark, map-first visual system over the existing FlightOps shell.
 * - Preserve all current IDs, bindings, and realtime behavior.
 *
 * Does not:
 * - Change backend routes or data flow.
 * - Rename JavaScript-driven elements.
 * - Replace panel logic or panel ownership.
 */

:root {
  --fo-font-sans: Inter, "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;

  --fo-bg-page: #08101c;
  --fo-bg-map: #06111d;
  --fo-bg-topbar: rgba(10, 20, 33, 0.96);
  --fo-bg-overlay: rgba(8, 16, 28, 0.74);
  --fo-bg-surface: rgba(11, 23, 38, 0.94);
  --fo-bg-surface-2: rgba(15, 29, 47, 0.96);
  --fo-bg-surface-3: rgba(18, 37, 60, 0.98);
  --fo-bg-card: rgba(14, 27, 44, 0.96);
  --fo-bg-card-soft: rgba(18, 35, 56, 0.88);
  --fo-bg-input: #0b1828;

  --fo-text-primary: #edf4fb;
  --fo-text-secondary: #b6c6d8;
  --fo-text-muted: #8192a8;
  --fo-text-strong: #ffffff;

  --fo-border-subtle: rgba(255, 255, 255, 0.08);
  --fo-border-medium: rgba(126, 156, 198, 0.22);
  --fo-border-strong: rgba(70, 132, 255, 0.35);

  --fo-accent: #3a82f7;
  --fo-accent-hover: #4b92ff;
  --fo-accent-soft: rgba(58, 130, 247, 0.16);
  --fo-success: #22c55e;
  --fo-warning: #f59e0b;
  --fo-danger: #ef4444;

  --fo-shadow-1: 0 12px 30px rgba(0, 0, 0, 0.22);
  --fo-shadow-2: 0 22px 48px rgba(0, 0, 0, 0.34);

  --fo-radius-xs: 8px;
  --fo-radius-sm: 12px;
  --fo-radius-md: 16px;
  --fo-radius-lg: 20px;
  --fo-radius-pill: 999px;

  --fo-space-1: 4px;
  --fo-space-2: 8px;
  --fo-space-3: 12px;
  --fo-space-4: 16px;
  --fo-space-5: 20px;
  --fo-space-6: 24px;
  --fo-space-7: 32px;

  --fo-topbar-height: 64px;
  --fo-panel-width: 360px;
  --fo-panel-gap: 14px;
}

html,
body {
  background: var(--fo-bg-page);
  color: var(--fo-text-primary);
  font-family: var(--fo-font-sans);
}

body.flightops-ops-console {
  background:
    radial-gradient(circle at top center, rgba(57, 103, 185, 0.12), transparent 30%),
    linear-gradient(180deg, #09111d 0%, #060d17 100%);
  color: var(--fo-text-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body.flightops-ops-console #map,
body.flightops-ops-console .leaflet-container {
  background:
    linear-gradient(180deg, rgba(7, 15, 26, 0.84), rgba(5, 10, 18, 0.84)),
    var(--fo-bg-map);
}

body.flightops-ops-console a {
  color: #9cc5ff;
}

body.flightops-ops-console button,
body.flightops-ops-console input,
body.flightops-ops-console select,
body.flightops-ops-console textarea {
  font-family: inherit;
}

body.flightops-ops-console button {
  border-radius: var(--fo-radius-pill);
  border: 1px solid var(--fo-border-subtle);
  background: linear-gradient(180deg, rgba(66, 138, 255, 0.18), rgba(29, 60, 103, 0.34));
  color: var(--fo-text-primary);
  box-shadow: none;
  transition:
    border-color 140ms ease,
    background-color 140ms ease,
    transform 140ms ease,
    opacity 140ms ease;
}

body.flightops-ops-console button:hover {
  background: linear-gradient(180deg, rgba(80, 151, 255, 0.28), rgba(36, 72, 118, 0.44));
  border-color: var(--fo-border-strong);
  transform: none;
}

body.flightops-ops-console button.secondary,
body.flightops-ops-console button.ghost,
body.flightops-ops-console .authUtilityBtn,
body.flightops-ops-console .topNavBtn,
body.flightops-ops-console .sectionToggle,
body.flightops-ops-console .sensorBlockToggle {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(154, 179, 214, 0.14);
  color: var(--fo-text-secondary);
}

body.flightops-ops-console button.secondary:hover,
body.flightops-ops-console button.ghost:hover,
body.flightops-ops-console .authUtilityBtn:hover,
body.flightops-ops-console .topNavBtn:hover,
body.flightops-ops-console .sectionToggle:hover,
body.flightops-ops-console .sensorBlockToggle:hover {
  color: var(--fo-text-primary);
  background: rgba(255, 255, 255, 0.08);
}

body.flightops-ops-console button:focus-visible,
body.flightops-ops-console input:focus-visible,
body.flightops-ops-console select:focus-visible,
body.flightops-ops-console textarea:focus-visible {
  outline: none;
  border-color: var(--fo-accent);
  box-shadow: 0 0 0 2px rgba(58, 130, 247, 0.25);
}

body.flightops-ops-console input[type="text"],
body.flightops-ops-console input[type="password"],
body.flightops-ops-console input[type="email"],
body.flightops-ops-console input[type="number"],
body.flightops-ops-console input[type="file"],
body.flightops-ops-console select,
body.flightops-ops-console textarea {
  background: var(--fo-bg-input);
  border: 1px solid rgba(121, 149, 187, 0.18);
  border-radius: var(--fo-radius-sm);
  color: var(--fo-text-primary);
}

body.flightops-ops-console input[type="range"] {
  accent-color: var(--fo-accent);
}

body.flightops-ops-console .phase1Check {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(121, 149, 187, 0.18);
  border-radius: var(--fo-radius-sm);
  color: var(--fo-text-secondary);
}

body.flightops-ops-console .phase1Check input {
  accent-color: var(--fo-accent);
}

body.flightops-ops-console .label {
  color: var(--fo-text-muted);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

body.flightops-ops-console .value,
body.flightops-ops-console .name {
  color: var(--fo-text-primary);
}

body.flightops-ops-console .sub,
body.flightops-ops-console .error,
body.flightops-ops-console .phase1SaveStatus,
body.flightops-ops-console .authGateHint,
body.flightops-ops-console .authGatePasswordStatus {
  color: var(--fo-text-muted);
}

body.flightops-ops-console .error,
body.flightops-ops-console .phase1SaveStatus.error,
body.flightops-ops-console .authGatePasswordStatus.error {
  color: #ff8d8d;
}

body.flightops-ops-console .badge {
  min-width: 30px;
  border-radius: var(--fo-radius-pill);
  background: rgba(58, 130, 247, 0.14);
  color: #a8ccff;
}

body.flightops-ops-console .pill {
  border-radius: var(--fo-radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 10px;
  letter-spacing: 0.08em;
}

body.flightops-ops-console .pill.ok,
body.flightops-ops-console .pill.empty {
  background: rgba(34, 197, 94, 0.14);
  color: #86efac;
}

body.flightops-ops-console .pill.stale {
  background: rgba(245, 158, 11, 0.14);
  color: #fcd34d;
}

body.flightops-ops-console .pill.disabled,
body.flightops-ops-console .pill.offline {
  background: rgba(239, 68, 68, 0.14);
  color: #fca5a5;
}

body.flightops-ops-console .pill.idle {
  background: rgba(148, 163, 184, 0.14);
  color: #cbd5e1;
}

body.flightops-ops-console #authTopbar {
  height: var(--fo-topbar-height);
  padding: 0 18px;
  gap: 18px;
  background:
    linear-gradient(180deg, rgba(16, 29, 48, 0.98), rgba(9, 18, 31, 0.98));
  border-bottom: 1px solid rgba(121, 149, 187, 0.18);
  box-shadow: var(--fo-shadow-1);
  backdrop-filter: none;
}

body.flightops-ops-console .authTopbarTitle {
  gap: 14px;
}

body.flightops-ops-console .authTopbarMenuBtn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

body.flightops-ops-console .authTopbarMenuBtn span {
  width: 18px;
  height: 2px;
}

body.flightops-ops-console .authTopbarTitleText {
  gap: 3px;
}

body.flightops-ops-console .authTopbarTitleText strong {
  color: var(--fo-text-strong);
  font-size: 15px;
  letter-spacing: 0.01em;
}

body.flightops-ops-console .authTopbarTitleText::after {
  content: "FLIGHT OPERATIONS DISPLAY";
  color: var(--fo-text-muted);
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

body.flightops-ops-console #topNav {
  justify-content: center;
  gap: 10px;
  flex-wrap: nowrap;
}

body.flightops-ops-console .topNavBtn {
  min-height: 38px;
  padding: 0 15px;
  border-radius: var(--fo-radius-pill);
  background: rgba(255, 255, 255, 0.04);
  color: var(--fo-text-secondary);
}

body.flightops-ops-console .topNavBtn.active {
  background: linear-gradient(180deg, var(--fo-accent-hover), var(--fo-accent));
  border-color: rgba(130, 176, 255, 0.58);
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

/* Keep active/open command states visually obvious even under the broader theme button rules. */
body.flightops-ops-console button.topNavBtn.active,
body.flightops-ops-console button.authUtilityBtn.active,
body.flightops-ops-console button.authAccountMenuBtn.active,
body.flightops-ops-console .authAccountMenuBtn.open {
  background: linear-gradient(180deg, var(--fo-accent-hover), var(--fo-accent));
  border-color: rgba(130, 176, 255, 0.58);
  color: #fff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 0 0 1px rgba(58, 130, 247, 0.18);
}

body.flightops-ops-console .authTopbarRight,
body.flightops-ops-console .authTopSignedIn {
  gap: 10px;
}

body.flightops-ops-console #authTopSignedIn {
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: 0;
  overflow: visible;
}

body.flightops-ops-console .authUtilityBtn {
  min-width: 40px;
  min-height: 40px;
  padding: 0 12px;
  font-size: 13px;
}

body.flightops-ops-console .authQuickLogoutBtn {
  min-height: 40px;
  padding: 0 14px;
  font-size: 12px;
}

body.flightops-ops-console .authAccountMenuBtn {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  column-gap: 10px;
  row-gap: 1px;
  align-items: center;
  min-width: 122px;
  min-height: 40px;
  padding: 7px 10px 7px 11px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
}

body.flightops-ops-console .authAccountMenuBtn::after {
  content: "";
  grid-column: 2;
  grid-row: 1 / span 2;
  justify-self: end;
  align-self: center;
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  margin-left: 10px;
  opacity: 0.78;
}

body.flightops-ops-console .authAccountName {
  grid-column: 1;
  grid-row: 1;
  max-width: 84px;
  font-size: 11px;
  line-height: 1.05;
  color: var(--fo-text-primary);
}

body.flightops-ops-console .authAccountRole {
  grid-column: 1;
  grid-row: 2;
  font-size: 9px;
  line-height: 1;
  letter-spacing: 0.1em;
  color: var(--fo-text-muted);
}

body.flightops-ops-console .authAccountMenu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 184px;
  padding: 8px;
  background: var(--fo-bg-surface-2);
  border: 1px solid rgba(121, 149, 187, 0.18);
  border-radius: var(--fo-radius-md);
  box-shadow: var(--fo-shadow-2);
  z-index: 2305;
  gap: 6px;
}

body.flightops-ops-console .authAccountMenuItem {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  width: 100%;
  min-height: 38px;
  padding: 0 11px;
  border-radius: var(--fo-radius-sm);
  background: transparent;
  border: 1px solid transparent;
  color: var(--fo-text-primary);
  font-size: 12px;
  text-align: left;
}

body.flightops-ops-console .authAccountMenuItem:hover,
body.flightops-ops-console .authAccountMenuItem:focus-visible {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(121, 149, 187, 0.18);
  color: var(--fo-text-strong);
}

body.flightops-ops-console #settingsGearBtn.authAccountMenuItem::before,
body.flightops-ops-console #authAccountProfileBtn.authAccountMenuItem::before,
body.flightops-ops-console #downloadsMenuBtn.authAccountMenuItem::before,
body.flightops-ops-console #authQuickLogoutBtn.authAccountMenuItem::before {
  font-size: 14px;
  opacity: 0.82;
}

body.flightops-ops-console #settingsGearBtn.authAccountMenuItem::before {
  content: "⚙";
}

body.flightops-ops-console #authAccountProfileBtn.authAccountMenuItem::before {
  content: "◉";
}

body.flightops-ops-console #downloadsMenuBtn.authAccountMenuItem::before {
  content: "⤓";
}

body.flightops-ops-console #authQuickLogoutBtn.authAccountMenuItem::before {
  content: "↗";
}

body.flightops-ops-console #authGate {
  top: 0;
  z-index: 2300;
  background: #03080f;
}

body.flightops-ops-console .authGateCard {
  background: linear-gradient(180deg, rgba(15, 29, 47, 0.96), rgba(10, 20, 33, 0.98));
  border: 1px solid rgba(121, 149, 187, 0.18);
  border-radius: var(--fo-radius-lg);
  box-shadow: var(--fo-shadow-2);
}

body.flightops-ops-console .authGateCard h2,
body.flightops-ops-console .authGateCard p {
  color: var(--fo-text-primary);
}

body.flightops-ops-console.authLocked #authTopbar,
body.flightops-ops-console.authLocked #sidebar,
body.flightops-ops-console.authLocked #map {
  opacity: 0;
  pointer-events: none;
  filter: none;
}

body.flightops-ops-console #sidebar {
  background: transparent;
}

body.flightops-ops-console .shell,
body.flightops-ops-console .body {
  background: transparent;
  pointer-events: none;
}

body.flightops-ops-console .panelSection {
  top: 88px;
  left: 16px;
  width: min(360px, calc(100vw - 32px));
  max-height: calc(100vh - 108px);
  overflow: auto;
  border-radius: var(--fo-radius-lg);
}

body.flightops-ops-console .card {
  background: linear-gradient(180deg, rgba(18, 35, 56, 0.95), rgba(11, 22, 37, 0.95));
  border: 1px solid rgba(121, 149, 187, 0.16);
  border-radius: var(--fo-radius-lg);
  box-shadow: var(--fo-shadow-1);
}

body.flightops-ops-console .head {
  padding: 14px 16px 12px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent),
    rgba(255, 255, 255, 0.02);
  border-top: 0;
  border-bottom: 1px solid rgba(121, 149, 187, 0.12);
}

body.flightops-ops-console .head h2 {
  color: var(--fo-text-strong);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

body.flightops-ops-console .headActions {
  gap: 8px;
}

body.flightops-ops-console .sectionBody {
  display: grid;
  gap: 12px;
  padding: 14px 16px 16px;
}

body.flightops-ops-console .grid,
body.flightops-ops-console .controls,
body.flightops-ops-console .stats,
body.flightops-ops-console .details,
body.flightops-ops-console .list {
  gap: 10px;
}

body.flightops-ops-console .stats,
body.flightops-ops-console .details {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.flightops-ops-console .row,
body.flightops-ops-console .item,
body.flightops-ops-console .sensorBlock,
body.flightops-ops-console .alertClosestCard,
body.flightops-ops-console .alertCountCard,
body.flightops-ops-console .monitorCard,
body.flightops-ops-console .monitorMini,
body.flightops-ops-console .phase1Check,
body.flightops-ops-console #accountSettingsCard,
body.flightops-ops-console #smtpSettingsCard,
body.flightops-ops-console #mpu5SettingsCard,
body.flightops-ops-console #downloadsAdminCard,
body.flightops-ops-console #videoPlayerCard {
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(121, 149, 187, 0.14);
  box-shadow: none;
}

body.flightops-ops-console .row {
  padding: 10px 12px;
  border-radius: var(--fo-radius-sm);
}

body.flightops-ops-console .value {
  margin-top: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--fo-text-primary);
}

body.flightops-ops-console .value.muted,
body.flightops-ops-console .empty {
  color: var(--fo-text-muted);
}

body.flightops-ops-console .empty {
  padding: 10px 0 2px;
}

body.flightops-ops-console .sensorBlock {
  padding: 12px;
  border-radius: var(--fo-radius-md);
}

body.flightops-ops-console .sensorBlockHead {
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(121, 149, 187, 0.12);
}

body.flightops-ops-console .sensorBlockBody {
  display: grid;
  gap: 10px;
  padding-top: 10px;
}

body.flightops-ops-console .sensorBlockTitleText {
  color: var(--fo-text-primary);
  font-size: 12px;
  letter-spacing: 0.08em;
}

body.flightops-ops-console .phase1Toolbar {
  padding: 4px 0 0;
}

body.flightops-ops-console .phase1Config {
  gap: 10px;
}

body.flightops-ops-console .trail,
body.flightops-ops-console .upload {
  gap: 10px;
}

body.flightops-ops-console .controls.settingsControls {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.flightops-ops-console .mergeControl,
body.flightops-ops-console #accountSettingsCard,
body.flightops-ops-console #smtpSettingsCard,
body.flightops-ops-console #mpu5SettingsCard,
body.flightops-ops-console #videoIngestSettingsCard,
body.flightops-ops-console #viewAccessCard {
  padding: 12px;
  border-radius: var(--fo-radius-md);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(121, 149, 187, 0.14);
}

body.flightops-ops-console .alertCardOptionB,
body.flightops-ops-console .alertHeroPanel,
body.flightops-ops-console .alertClosestCard,
body.flightops-ops-console .alertCountCard {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(121, 149, 187, 0.14);
  color: var(--fo-text-primary);
}

body.flightops-ops-console .alertHeroPanel {
  border-bottom: 1px solid rgba(121, 149, 187, 0.12);
}

body.flightops-ops-console .alertHeroLabel,
body.flightops-ops-console .alertClosestLabel,
body.flightops-ops-console .alertWindowMeta,
body.flightops-ops-console .alertTrafficMeta {
  color: var(--fo-text-muted);
}

body.flightops-ops-console .alertClosestName,
body.flightops-ops-console .alertCountValue,
body.flightops-ops-console .alertListTitle {
  color: var(--fo-text-strong);
}

body.flightops-ops-console .alertTrafficChip.advisory {
  background: rgba(245, 158, 11, 0.16);
  color: #fcd34d;
}

body.flightops-ops-console .alertTrafficChip.warning {
  background: rgba(251, 146, 60, 0.16);
  color: #fdba74;
}

body.flightops-ops-console .alertTrafficChip.critical {
  background: rgba(239, 68, 68, 0.16);
  color: #fca5a5;
}

body.flightops-ops-console .alertTrafficChip.clear {
  background: rgba(34, 197, 94, 0.16);
  color: #86efac;
}

body.flightops-ops-console .panelSection[data-panel="settings"] {
  top: 80px !important;
  left: 16px !important;
  width: min(390px, calc(100vw - 32px)) !important;
  max-height: calc(100vh - 100px) !important;
  border-radius: var(--fo-radius-lg) !important;
  background: linear-gradient(180deg, rgba(18, 35, 56, 0.96), rgba(11, 22, 37, 0.98)) !important;
  border: 1px solid rgba(121, 149, 187, 0.18) !important;
  box-shadow: var(--fo-shadow-2) !important;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .head {
  padding: 14px 16px 12px !important;
  background: rgba(255, 255, 255, 0.02) !important;
  border-bottom: 1px solid rgba(121, 149, 187, 0.12) !important;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .sectionBody {
  display: grid !important;
  gap: 12px !important;
  padding: 14px 16px 18px !important;
}

/* Settings is dense operational text, so it needs stronger contrast than the general muted card treatment. */
body.flightops-ops-console .panelSection[data-panel="settings"] .label,
body.flightops-ops-console .panelSection[data-panel="settings"] .field .label {
  color: #dbe8f7 !important;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .sub,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1SaveStatus,
body.flightops-ops-console .panelSection[data-panel="settings"] .authHint,
body.flightops-ops-console .panelSection[data-panel="settings"] .authGateHint {
  color: #b7cae0 !important;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .name,
body.flightops-ops-console .panelSection[data-panel="settings"] .value,
body.flightops-ops-console .panelSection[data-panel="settings"] .sensorBlockTitleText,
body.flightops-ops-console .panelSection[data-panel="settings"] h2 {
  color: #ffffff !important;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .row,
body.flightops-ops-console .panelSection[data-panel="settings"] .item,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Check,
body.flightops-ops-console .panelSection[data-panel="settings"] #accountSettingsCard,
body.flightops-ops-console .panelSection[data-panel="settings"] #smtpSettingsCard,
body.flightops-ops-console .panelSection[data-panel="settings"] #mpu5SettingsCard,
body.flightops-ops-console .panelSection[data-panel="settings"] #videoIngestSettingsCard,
body.flightops-ops-console .panelSection[data-panel="settings"] #viewAccessCard {
  background: rgba(255, 255, 255, 0.055);
  border-color: rgba(147, 178, 220, 0.24);
}

body.flightops-ops-console .panelSection[data-panel="settings"] input[type="text"],
body.flightops-ops-console .panelSection[data-panel="settings"] input[type="password"],
body.flightops-ops-console .panelSection[data-panel="settings"] input[type="email"],
body.flightops-ops-console .panelSection[data-panel="settings"] input[type="number"],
body.flightops-ops-console .panelSection[data-panel="settings"] input[type="file"],
body.flightops-ops-console .panelSection[data-panel="settings"] select,
body.flightops-ops-console .panelSection[data-panel="settings"] textarea {
  background: rgba(8, 20, 34, 0.98);
  border-color: rgba(147, 178, 220, 0.22);
  color: #f8fbff;
}

body.flightops-ops-console .panelSection[data-panel="video"] {
  min-width: 420px;
  min-height: 180px;
}

body.flightops-ops-console .panelSection[data-panel="video"] #videoPlayerCard {
  border-radius: var(--fo-radius-md);
  overflow: hidden;
}

body.flightops-ops-console .panelSection[data-panel="video"] .videoInlineShell {
  background: rgba(3, 8, 15, 0.82);
}

body.flightops-ops-console .panelSection[data-panel="video"] .videoInlineBar {
  padding: 12px 14px;
  background: rgba(16, 29, 48, 0.96);
  border-bottom: 1px solid rgba(121, 149, 187, 0.14);
}

body.flightops-ops-console .panelSection[data-panel="video"] .videoInlineLabel {
  color: var(--fo-text-muted);
}

body.flightops-ops-console .panelSection[data-panel="video"] .videoInlineSource {
  color: var(--fo-text-strong);
  font-size: 15px;
}

body.flightops-ops-console .panelSection[data-panel="video"] .videoPlayerHint {
  background: rgba(239, 68, 68, 0.1);
  border-bottom: 1px solid rgba(239, 68, 68, 0.16);
  color: #fca5a5;
}

body.flightops-ops-console .panelSection[data-panel="video"] #videoInlinePlayer {
  background: #000;
}

body.flightops-ops-console .videoInlineSelectWrap {
  color: var(--fo-text-secondary);
}

body.flightops-ops-console #videoInlineSelect {
  background: var(--fo-bg-input);
  color: var(--fo-text-primary);
  border: 1px solid rgba(121, 149, 187, 0.18);
  border-radius: var(--fo-radius-pill);
  min-height: 38px;
  padding: 0 12px;
}

body.flightops-ops-console #monitoringDock {
  top: 88px;
  transform: translateX(calc(100% - 38px));
}

/* The JS toggles .open; the theme must preserve that state with matching specificity. */
body.flightops-ops-console #monitoringDock.open {
  transform: translateX(0);
}

body.flightops-ops-console #monitoringDockToggle {
  width: 38px;
  min-width: 38px;
  height: 42px;
  border-radius: var(--fo-radius-sm) 0 0 var(--fo-radius-sm);
  border: 1px solid rgba(121, 149, 187, 0.18);
  border-right: 0;
  background: rgba(10, 20, 33, 0.96);
  color: var(--fo-text-primary);
  box-shadow: var(--fo-shadow-1);
}

body.flightops-ops-console #monitoringDockRail {
  width: 300px;
  gap: 10px;
  padding-left: 10px;
}

body.flightops-ops-console #monitoringDock .monitorCard {
  gap: 8px;
  padding: 12px 14px;
  border-radius: var(--fo-radius-md);
  background: linear-gradient(180deg, rgba(18, 35, 56, 0.98), rgba(10, 20, 33, 0.98));
  border: 1px solid rgba(121, 149, 187, 0.18);
  box-shadow: var(--fo-shadow-1);
}

body.flightops-ops-console #monitoringDock .monitorTitle,
body.flightops-ops-console .monitorTitle {
  color: var(--fo-text-strong);
}

body.flightops-ops-console #monitoringDock .monitorStatus,
body.flightops-ops-console .monitorStatus,
body.flightops-ops-console .monitorMeta .sub,
body.flightops-ops-console .monitorMiniMeta,
body.flightops-ops-console .monitorMiniLabel {
  color: var(--fo-text-secondary);
}

body.flightops-ops-console .monitorMini,
body.flightops-ops-console .monitorSubgrid .monitorMini {
  border-radius: var(--fo-radius-sm);
}

body.flightops-ops-console .monitorLamp.ok,
body.flightops-ops-console .monitorLamp.up,
body.flightops-ops-console .monitorMiniLamp.up,
body.flightops-ops-console .monitorFortemPanelLamp.up {
  background: var(--fo-success);
}

body.flightops-ops-console .monitorLamp.down,
body.flightops-ops-console .monitorMiniLamp.down,
body.flightops-ops-console .monitorFortemPanelLamp.down {
  background: var(--fo-danger);
}

body.flightops-ops-console #mapUtilityDrawer {
  top: 138px;
  transform: translateX(calc(100% - 40px));
}

/* The drawer still uses the legacy .open state, so keep the theme in sync with that contract. */
body.flightops-ops-console #mapUtilityDrawer.open {
  transform: translateX(0);
}

body.flightops-ops-console #mapUtilityDrawerToggle {
  width: 40px;
  min-width: 40px;
  height: 42px;
  border-radius: var(--fo-radius-sm) 0 0 var(--fo-radius-sm);
  border: 1px solid rgba(121, 149, 187, 0.18);
  border-right: 0;
  background: rgba(10, 20, 33, 0.96);
  color: var(--fo-text-primary);
  box-shadow: var(--fo-shadow-1);
}

body.flightops-ops-console #mapUtilityDrawerPanel,
body.flightops-ops-console .mapUtilityDrawerPanel {
  width: 172px;
  padding: 12px;
  background: linear-gradient(180deg, rgba(18, 35, 56, 0.98), rgba(10, 20, 33, 0.98));
  border: 1px solid rgba(121, 149, 187, 0.18);
  box-shadow: var(--fo-shadow-1);
  color: var(--fo-text-primary);
}

body.flightops-ops-console .mapUtilityDrawerHeader {
  padding: 10px 8px;
  border-radius: var(--fo-radius-sm);
  border: 1px solid rgba(121, 149, 187, 0.14);
  background: rgba(255, 255, 255, 0.03);
}

body.flightops-ops-console .mapUtilityDrawerTitle {
  color: var(--fo-text-strong);
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body.flightops-ops-console .mapUtilityDrawerSection {
  gap: 8px;
}

body.flightops-ops-console #mapUtilityLayersButtons,
body.flightops-ops-console #mapUtilityOverlayControls,
body.flightops-ops-console #mapUtilityAttachmentMount,
body.flightops-ops-console #mapUtilityReloadMount {
  gap: 8px;
}

body.flightops-ops-console #mapUtilityDrawer .item,
body.flightops-ops-console #mapUtilityDrawer .field,
body.flightops-ops-console #mapUtilityDrawer .upload {
  border-radius: var(--fo-radius-sm);
}

body.flightops-ops-console .leaflet-control-zoom a,
body.flightops-ops-console .basemapBtn,
body.flightops-ops-console .clearPinsBtn {
  background: rgba(10, 20, 33, 0.96);
  border: 1px solid rgba(121, 149, 187, 0.18);
  color: var(--fo-text-primary);
  box-shadow: var(--fo-shadow-1);
}

/*
 * Map utility controls need stable hit targets. Avoid hover motion here and
 * explicitly keep pointer events enabled so the first interaction acts on the
 * control rather than just establishing focus.
 */
body.flightops-ops-console .measureControl,
body.flightops-ops-console .measureControl *,
body.flightops-ops-console .basemapControl,
body.flightops-ops-console .basemapControl *,
body.flightops-ops-console .clearPinsControl,
body.flightops-ops-console .clearPinsControl * {
  pointer-events: auto;
}

body.flightops-ops-console .measureControl,
body.flightops-ops-console .basemapBtn,
body.flightops-ops-console .clearPinsBtn {
  background: rgba(10, 20, 33, 0.96);
  border: 1px solid rgba(121, 149, 187, 0.18);
  color: var(--fo-text-primary);
  box-shadow: var(--fo-shadow-1);
}

body.flightops-ops-console .measureControl button:hover,
body.flightops-ops-console .basemapBtn:hover,
body.flightops-ops-console .clearPinsBtn:hover,
body.flightops-ops-console .leaflet-control-zoom a:hover {
  transform: none;
}

body.flightops-ops-console .leaflet-tooltip.tip::before {
  border-top-color: rgba(121, 149, 187, 0.18);
}

body.flightops-ops-console .leaflet-tooltip.tip,
body.flightops-ops-console .leaflet-popup.tip .leaflet-popup-content-wrapper,
body.flightops-ops-console .leaflet-popup.tip .leaflet-popup-tip {
  background: rgba(10, 20, 33, 0.96);
  border: 1px solid rgba(121, 149, 187, 0.18);
  color: var(--fo-text-primary);
  box-shadow: var(--fo-shadow-1);
}

body.flightops-ops-console .leaflet-popup.tip .leaflet-popup-content {
  color: var(--fo-text-primary);
}

body.flightops-ops-console .panelSection::-webkit-scrollbar,
body.flightops-ops-console #monitoringDockRail::-webkit-scrollbar,
body.flightops-ops-console #mapUtilityDrawerPanel::-webkit-scrollbar,
body.flightops-ops-console .mapUtilityDrawerPanel::-webkit-scrollbar {
  width: 10px;
}

body.flightops-ops-console .panelSection::-webkit-scrollbar-thumb,
body.flightops-ops-console #monitoringDockRail::-webkit-scrollbar-thumb,
body.flightops-ops-console #mapUtilityDrawerPanel::-webkit-scrollbar-thumb,
body.flightops-ops-console .mapUtilityDrawerPanel::-webkit-scrollbar-thumb {
  background: rgba(121, 149, 187, 0.28);
  border-radius: 999px;
}

@media (max-width: 1100px) {
  body.flightops-ops-console #topNav {
    flex-wrap: wrap;
    justify-content: flex-start;
  }

  body.flightops-ops-console #authTopbar {
    height: auto;
    align-items: flex-start;
    padding: 10px 14px 12px;
  }

  body.flightops-ops-console #authTopSignedIn {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  body.flightops-ops-console .panelSection,
  body.flightops-ops-console .panelSection[data-panel="settings"] {
    left: 12px !important;
    width: min(360px, calc(100vw - 24px)) !important;
  }
}

@media (max-width: 720px) {
  body.flightops-ops-console .stats,
  body.flightops-ops-console .details,
  body.flightops-ops-console .controls.settingsControls,
  body.flightops-ops-console .phase1Config {
    grid-template-columns: 1fr;
  }

  body.flightops-ops-console #monitoringDockRail {
    width: min(76vw, 300px);
  }

  body.flightops-ops-console #mapUtilityDrawerPanel,
  body.flightops-ops-console .mapUtilityDrawerPanel {
    width: min(60vw, 190px);
  }
}

/* -----------------------------------------------------------------------------
 * Panel readability and density refinement
 * -----------------------------------------------------------------------------
 * Keep this pass CSS-only so the existing panel DOM, IDs, and JS bindings stay
 * intact. The goal is to make the left rail and support cards easier to scan
 * under load without changing panel ownership or behavior.
 */
body.flightops-ops-console .panelSection .head,
body.flightops-ops-console .panelSection[data-panel="settings"] .head {
  gap: 10px;
  padding: 12px 14px 10px;
}

body.flightops-ops-console .panelSection .head h2,
body.flightops-ops-console .panelSection[data-panel="settings"] h2,
body.flightops-ops-console .monitorTitle {
  font-size: 14px;
  line-height: 1.15;
  letter-spacing: 0.02em;
}

body.flightops-ops-console .panelSection .sectionBody,
body.flightops-ops-console .panelSection[data-panel="settings"] .sectionBody {
  gap: 10px !important;
  padding: 12px 14px 14px !important;
}

body.flightops-ops-console .panelSection .grid,
body.flightops-ops-console .panelSection .controls,
body.flightops-ops-console .panelSection .stats,
body.flightops-ops-console .panelSection .details,
body.flightops-ops-console .panelSection .list,
body.flightops-ops-console .panelSection .trail,
body.flightops-ops-console .panelSection .upload,
body.flightops-ops-console .panelSection .phase1Config,
body.flightops-ops-console .panelSection .contextCheckGroup {
  gap: 8px;
}

body.flightops-ops-console .panelSection .row,
body.flightops-ops-console .panelSection .item,
body.flightops-ops-console .panelSection .sensorBlock,
body.flightops-ops-console .panelSection .phase1Check,
body.flightops-ops-console .panelSection #accountSettingsCard,
body.flightops-ops-console .panelSection #smtpSettingsCard,
body.flightops-ops-console .panelSection #mpu5SettingsCard,
body.flightops-ops-console .panelSection #videoIngestSettingsCard,
body.flightops-ops-console .panelSection #viewAccessCard,
body.flightops-ops-console .panelSection #downloadsAdminCard {
  padding: 11px 12px;
  border-radius: var(--fo-radius-sm);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.025));
  border-color: rgba(132, 161, 202, 0.18);
}

body.flightops-ops-console .panelSection .itemMain,
body.flightops-ops-console .panelSection .sensorBlockBody,
body.flightops-ops-console .panelSection .phase1Toolbar,
body.flightops-ops-console .panelSection .headActions {
  gap: 6px;
}

body.flightops-ops-console .panelSection .sensorBlockHead {
  padding-bottom: 8px;
}

body.flightops-ops-console .panelSection .sensorBlockBody {
  padding-top: 8px;
}

body.flightops-ops-console .panelSection .label,
body.flightops-ops-console .panelSection .phase1Field > span,
body.flightops-ops-console .panelSection .field .label,
body.flightops-ops-console .panelSection .colorField span,
body.flightops-ops-console .panelSection .sensorBlockTitleText,
body.flightops-ops-console .panelSection .monitorMiniLabel {
  color: #cfdced;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body.flightops-ops-console .panelSection .value,
body.flightops-ops-console .panelSection .name,
body.flightops-ops-console .panelSection .monitorTitle,
body.flightops-ops-console .panelSection .alertListTitle {
  margin-top: 4px;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
}

body.flightops-ops-console .panelSection .sub,
body.flightops-ops-console .panelSection .error,
body.flightops-ops-console .panelSection .phase1SaveStatus,
body.flightops-ops-console .panelSection .monitorMiniMeta,
body.flightops-ops-console .panelSection .monitorStatus,
body.flightops-ops-console .panelSection .monitorMeta .sub {
  font-size: 11px;
  line-height: 1.35;
}

body.flightops-ops-console .panelSection .phase1Field,
body.flightops-ops-console .panelSection .field,
body.flightops-ops-console .panelSection .colorField {
  display: grid;
  gap: 5px;
}

body.flightops-ops-console .panelSection input[type="text"],
body.flightops-ops-console .panelSection input[type="password"],
body.flightops-ops-console .panelSection input[type="email"],
body.flightops-ops-console .panelSection input[type="number"],
body.flightops-ops-console .panelSection input[type="file"],
body.flightops-ops-console .panelSection select,
body.flightops-ops-console .panelSection textarea {
  min-height: 38px;
  padding-left: 11px;
  padding-right: 11px;
}

body.flightops-ops-console .panelSection textarea {
  min-height: 88px;
  padding-top: 10px;
}

body.flightops-ops-console .panelSection .controls.settingsControls {
  align-items: start;
}

body.flightops-ops-console .panelSection .contextCheckGroup {
  display: grid;
}

body.flightops-ops-console .panelSection .contextCheckGroup .phase1Check {
  min-height: 38px;
}

body.flightops-ops-console #monitoringDockRail {
  gap: 8px;
}

body.flightops-ops-console #monitoringDock .monitorCard {
  gap: 7px;
  padding: 11px 12px;
}

body.flightops-ops-console .monitorMini,
body.flightops-ops-console .monitorSubgrid .monitorMini {
  gap: 7px;
  padding: 6px 8px;
  min-height: 34px;
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(132, 161, 202, 0.18);
}

body.flightops-ops-console #mapUtilityDrawerPanel,
body.flightops-ops-console .mapUtilityDrawerPanel {
  width: 186px;
  gap: 8px;
  padding: 10px;
}

body.flightops-ops-console .mapUtilityDrawerHeader {
  padding: 9px 8px;
}

body.flightops-ops-console .mapUtilityDrawerTitle {
  font-size: 13px;
  letter-spacing: 0.06em;
}

body.flightops-ops-console #mapUtilityDrawer .controls button,
body.flightops-ops-console #mapUtilityDrawer #mapUtilityOverlayControls button,
body.flightops-ops-console #mapUtilityDrawer .mapUtilitySectionToggle,
body.flightops-ops-console #mapUtilityReloadMount button,
body.flightops-ops-console #mapUtilityDrawer #uploadOverlayBtn {
  min-height: 34px;
  padding: 7px 8px;
  font-size: 11px;
}

body.flightops-ops-console #mapUtilityDrawer .item,
body.flightops-ops-console #mapUtilityDrawer .field,
body.flightops-ops-console #mapUtilityDrawer .upload {
  padding: 8px 9px;
  background: rgba(255, 255, 255, 0.045);
  border-color: rgba(132, 161, 202, 0.18);
}

body.flightops-ops-console #mapUtilityDrawer .label,
body.flightops-ops-console #mapUtilityDrawer .field .label,
body.flightops-ops-console #mapUtilityDrawer .colorField span {
  color: #d1deee;
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

body.flightops-ops-console #mapUtilityDrawer .name,
body.flightops-ops-console #mapUtilityDrawer .value {
  font-size: 13px;
  line-height: 1.25;
}

body.flightops-ops-console #mapUtilityDrawer .sub,
body.flightops-ops-console #mapUtilityDrawer .phase1SaveStatus {
  font-size: 10px;
  line-height: 1.3;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .label,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Field > span,
body.flightops-ops-console .panelSection[data-panel="settings"] .field .label,
body.flightops-ops-console .panelSection[data-panel="settings"] .colorField span {
  color: #e3eefb !important;
}

@media (max-width: 720px) {
  body.flightops-ops-console #mapUtilityDrawerPanel,
  body.flightops-ops-console .mapUtilityDrawerPanel {
    width: min(62vw, 196px);
  }
}

/* -----------------------------------------------------------------------------
 * Settings panel docked-layout pass
 * -----------------------------------------------------------------------------
 * Make Settings read like a true operations sidebar: docked to the map edge,
 * full-height under the top bar, and wide enough that admin text fields do not
 * collapse into narrow columns.
 */
body.flightops-ops-console .panelSection[data-panel="settings"] {
  position: fixed !important;
  top: var(--fo-topbar-height) !important;
  left: 0 !important;
  right: auto !important;
  bottom: 0 !important;
  margin: 0 !important;
  width: clamp(540px, 46vw, 680px) !important;
  height: calc(100vh - var(--fo-topbar-height)) !important;
  max-height: calc(100vh - var(--fo-topbar-height)) !important;
  max-width: calc(100vw - 24px) !important;
  border-radius: 0 !important;
  box-shadow: 18px 0 42px rgba(0, 0, 0, 0.34) !important;
  overflow-x: hidden !important;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .sectionBody {
  align-content: start;
}

body.flightops-ops-console .panelSection[data-panel="settings"],
body.flightops-ops-console .panelSection[data-panel="settings"] *,
body.flightops-ops-console .panelSection[data-panel="settings"] *::before,
body.flightops-ops-console .panelSection[data-panel="settings"] *::after {
  box-sizing: border-box;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Config {
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Config .full {
  grid-column: 1 / -1;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Field,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Field input,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Field select,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Field textarea,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar.full,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar > div,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar > button,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar > .sub,
body.flightops-ops-console .panelSection[data-panel="settings"] .controls.settingsControls > *,
body.flightops-ops-console .panelSection[data-panel="settings"] .grid > *,
body.flightops-ops-console .panelSection[data-panel="settings"] .stats > *,
body.flightops-ops-console .panelSection[data-panel="settings"] .details > * {
  min-width: 0;
  max-width: 100%;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .trail {
  grid-template-columns: minmax(0, 1fr) 112px;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar.full {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar.full > :last-child,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar > div:last-child {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar.full button,
body.flightops-ops-console .panelSection[data-panel="settings"] .phase1Toolbar button {
  max-width: 100%;
}

@media (max-width: 1100px) {
  body.flightops-ops-console .panelSection[data-panel="settings"] {
    width: min(520px, calc(100vw - 12px)) !important;
  }
}

@media (max-width: 720px) {
  body.flightops-ops-console .panelSection[data-panel="settings"] {
    width: 100vw !important;
    max-width: 100vw !important;
    border-radius: 0 !important;
  }
}

/* -----------------------------------------------------------------------------
 * Fixed sidebar panel theme ownership pass
 * -----------------------------------------------------------------------------
 * Keep Settings and Display Controls visually owned by the main stylesheet so
 * runtime panel JS only has to manage geometry/open state.
 */
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"],
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] {
  left: 0 !important;
  top: var(--fo-topbar-height) !important;
  width: 360px !important;
  max-height: calc(100vh - var(--fo-topbar-height)) !important;
  resize: none !important;
  border-radius: 0 !important;
  overflow: auto !important;
  box-shadow: 0 24px 46px rgba(2, 6, 23, 0.38) !important;
  background: linear-gradient(180deg, rgba(18, 29, 44, 0.985), rgba(10, 18, 30, 0.992)) !important;
  border: 1px solid rgba(89, 118, 151, 0.42) !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] {
  border-left: 0 !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .head,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .head {
  cursor: default;
  align-items: center;
  padding: 12px 14px !important;
  border-top: 0 !important;
  background: linear-gradient(180deg, rgba(35, 50, 74, 0.99), rgba(25, 39, 58, 0.99)) !important;
  border-bottom: 1px solid rgba(82, 110, 142, 0.34) !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .head h2,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .head h2 {
  font-size: 16px !important;
  font-weight: 800 !important;
  letter-spacing: 0.01em !important;
  color: #f8feff !important;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .sectionBody,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .sectionBody {
  display: grid !important;
  gap: 12px !important;
  padding: 12px !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .grid,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .list,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .grid,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .list {
  gap: 8px !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .controls button,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] button.secondary,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] button:not(.authUtilityBtn),
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] button,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] button.secondary {
  border-radius: 12px !important;
  border-color: rgba(148, 163, 184, 0.18) !important;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.09), rgba(255, 255, 255, 0.04)) !important;
  color: #eef8fb !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04) !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .controls button:hover,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] button.secondary:hover,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] button:not(.authUtilityBtn):hover,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] button:hover,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] button.secondary:hover {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.06)) !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .item,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .row,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .phase1Check,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .item,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .row {
  background: rgba(236, 244, 250, 0.08) !important;
  border-color: rgba(120, 151, 186, 0.18) !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .label,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .value,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .name,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .label,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .value,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .name,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .phase1SaveStatus {
  color: #e7f3ff !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .sub,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .phase1SaveStatus,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .sub,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .phase1SaveStatus {
  font-size: 11px !important;
  color: #9fb7d0 !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .phase1Field span,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .phase1Field span,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerBlockTitle {
  color: #9fc0de !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] select,
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] input[type="number"],
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] input[type="text"],
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] input[type="password"],
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] input[type="email"],
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] input[type="file"],
body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] textarea {
  border-radius: 10px !important;
  border-color: rgba(125, 155, 192, 0.26) !important;
  background: rgba(8, 20, 34, 0.98) !important;
  color: #f8fbff !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] select,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] input[type="number"],
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] input[type="text"],
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] input[type="password"],
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] input[type="file"] {
  border-radius: 10px !important;
  border-color: rgba(125, 155, 192, 0.26) !important;
  background: rgba(248, 250, 252, 0.98) !important;
  color: #0f172a !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] .phase1Toolbar button,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .phase1Toolbar button {
  white-space: nowrap !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] #settingsPanelCloseBtn,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #opsDrawerCloseBtn {
  min-width: 34px !important;
  padding: 7px 9px !important;
  font-size: 16px !important;
  line-height: 1 !important;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerBlock {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(28, 41, 61, 0.98), rgba(18, 28, 43, 0.995));
  border: 1px solid rgba(97, 126, 160, 0.24);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerBlock.opsDrawerUtilityBlock {
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerBlockTitle {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerBlock.opsDrawerUtilityBlock .opsDrawerBlockTitle {
  padding: 0 2px;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerMount {
  display: grid;
  gap: 10px;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerActionRow {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .trail {
  grid-template-columns: minmax(0, 1fr) 88px;
  gap: 10px;
  align-items: center;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .mapUtilityDrawerSection {
  display: grid;
  gap: 8px;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .mapUtilitySectionToggle,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityOverlayControls button,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityReloadMount button {
  width: 100%;
  min-height: 44px;
  padding: 11px 14px;
  font-size: 12px;
  color: #eef8fb;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.03));
  border: 1px solid rgba(148, 163, 184, 0.18);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .mapUtilitySectionToggle:hover,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityOverlayControls button:hover,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityReloadMount button:hover {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
  border-color: rgba(148, 163, 184, 0.26);
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .mapUtilitySectionToggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #uploadOverlayBtn {
  width: 100%;
  min-height: 46px;
  padding: 12px 16px;
  font-size: 12px;
  color: #f3fffd;
  background: linear-gradient(180deg, #1aa39a, #0e6f69);
  border: 1px solid rgba(78, 205, 196, 0.34);
  border-radius: 14px;
  box-shadow: 0 14px 28px rgba(9, 68, 63, 0.28);
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #uploadOverlayBtn:hover {
  background: linear-gradient(180deg, #22b5ab, #107d76);
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityTopoBody,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityAttachmentsBody {
  display: grid;
  gap: 10px;
  min-height: 0;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityOverlayControls,
body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityAttachmentsBody {
  padding: 14px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(29, 41, 58, 0.98), rgba(21, 31, 44, 0.995));
  border: 1px solid rgba(111, 145, 184, 0.18);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04), 0 14px 30px rgba(2, 6, 23, 0.24);
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .mapUtilityAttachmentsHeader {
  margin-bottom: 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 96px;
  gap: 10px;
  align-items: start;
}

body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityReloadMount {
  display: grid;
  width: 96px;
}

@media (max-width: 900px) {
  body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"],
  body.flightops-ops-console #sidebar .panelSection[data-panel="settings"] {
    width: min(88vw, 360px);
  }

  body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .opsDrawerActionRow {
    grid-template-columns: 1fr;
  }

  body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] .mapUtilityAttachmentsHeader {
    grid-template-columns: 1fr;
  }

  body.flightops-ops-console #sidebar .panelSection[data-panel="opsdrawer"] #mapUtilityReloadMount {
    width: 100%;
  }
}
