:root {
  --bg: #0d0f12;
  --bg-secondary: #12151a;
  --panel: rgba(18, 20, 24, 0.94);
  --panel-strong: rgba(15, 17, 20, 0.96);
  --panel-border: rgba(255, 255, 255, 0.08);
  --panel-glow: rgba(255, 255, 255, 0);
  --text: #eef1f4;
  --muted: #98a1ab;
  --muted-strong: #c2c8cf;
  --accent: #d8be93;
  --accent-strong: #e4c799;
  --accent-soft: rgba(216, 190, 147, 0.12);
  --shell-shadow: rgba(0, 0, 0, 0.22);
  --surface-strong: rgba(22, 25, 30, 0.96);
  --surface-soft: rgba(255, 255, 255, 0.03);
  --surface-muted: rgba(255, 255, 255, 0.04);
  --control-bg: rgba(22, 25, 30, 0.96);
  --field-bg: rgba(14, 16, 19, 0.96);
  --button-fill: #20242a;
  --button-fill-text: #eef1f4;
  --button-fill-shadow: none;
  --low: #90de72;
  --medium: #f3cf78;
  --high: #ff9867;
  --critical: #ff625e;
}

body[data-theme="light"] {
  --bg: #f3f5f7;
  --bg-secondary: #eef1f4;
  --panel: rgba(255, 255, 255, 0.96);
  --panel-strong: rgba(255, 255, 255, 0.98);
  --panel-border: rgba(19, 24, 31, 0.08);
  --panel-glow: rgba(0, 0, 0, 0);
  --text: #161b22;
  --muted: #66717e;
  --muted-strong: #3f4a57;
  --accent: #6c7681;
  --accent-strong: #29323d;
  --accent-soft: rgba(41, 50, 61, 0.08);
  --shell-shadow: rgba(15, 23, 31, 0.08);
  --surface-strong: rgba(248, 250, 252, 0.98);
  --surface-soft: rgba(15, 23, 31, 0.03);
  --surface-muted: rgba(15, 23, 31, 0.04);
  --control-bg: rgba(248, 250, 252, 0.98);
  --field-bg: rgba(255, 255, 255, 0.98);
  --button-fill: #f6f8fa;
  --button-fill-text: #161b22;
  --button-fill-shadow: none;
}

@keyframes liveDotPulse {
  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(227, 195, 142, 0.12);
    transform: scale(1);
  }

  50% {
    box-shadow:
      0 0 0 7px rgba(227, 195, 142, 0.09),
      0 0 24px rgba(255, 184, 103, 0.16);
    transform: scale(1.08);
  }
}

@keyframes feedCardIn {
  0% {
    opacity: 0;
    transform: translateY(14px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes highlightPulse {
  0%,
  100% {
    box-shadow:
      0 0 0 0 rgba(227, 195, 142, 0),
      0 0 0 1px rgba(227, 195, 142, 0.08);
    transform: translateY(0);
  }

  50% {
    box-shadow:
      0 0 0 7px rgba(227, 195, 142, 0.08),
      0 0 28px rgba(255, 184, 103, 0.16);
    transform: translateY(-1px);
  }
}

@keyframes markerPulse {
  0%,
  100% {
    transform: scale(1);
  }

  50% {
    transform: scale(1.08);
  }
}

@keyframes toastSlideIn {
  0% {
    opacity: 0;
    transform: translateY(-10px) scale(0.98);
  }

  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes sirenSweep {
  0% {
    opacity: 0.5;
    transform: scale(0.72);
  }

  100% {
    opacity: 0;
    transform: scale(1.8);
  }
}

@keyframes sirenBlink {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.36;
    transform: scale(0.88);
  }
}

@keyframes impactThump {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
  }

  40% {
    transform: scale(1.14);
    box-shadow:
      0 0 0 1px rgba(255, 255, 255, 0.08),
      0 0 20px rgba(255, 152, 103, 0.26);
  }
}

@keyframes airstrikeDive {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }

  35% {
    transform: translate(1px, -2px) rotate(8deg);
  }

  70% {
    transform: translate(-1px, 1px) rotate(-6deg);
  }
}

@keyframes droneHover {
  0%,
  100% {
    transform: translate(0, 0);
  }

  50% {
    transform: translate(2px, -3px);
  }
}

@keyframes advisoryBreathe {
  0%,
  100% {
    opacity: 0.9;
    transform: scale(1);
  }

  50% {
    opacity: 1;
    transform: scale(1.05);
  }
}

@keyframes convoyRoll {
  0%,
  100% {
    transform: translateX(-3px);
  }

  50% {
    transform: translateX(3px);
  }
}

@keyframes diplomacyOrbit {
  0% {
    opacity: 0.42;
    transform: rotate(0deg) scale(0.9);
  }

  100% {
    opacity: 0;
    transform: rotate(360deg) scale(1.14);
  }
}

@keyframes denialGlitch {
  0%,
  100% {
    opacity: 1;
    transform: translate(0, 0);
  }

  18% {
    opacity: 0.34;
    transform: translate(-1px, 1px) scale(1.02);
  }

  19% {
    opacity: 1;
    transform: translate(2px, -1px) scale(0.96);
  }

  54% {
    transform: translate(1px, 0) rotate(-6deg);
  }
}

@keyframes airstrikeFlare {
  0%,
  100% {
    opacity: 0.16;
    transform: scale(0.86);
  }

  50% {
    opacity: 0.56;
    transform: scale(1.36);
  }
}

@keyframes toastSignal {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.46;
    transform: scale(1.12);
  }
}

@keyframes toastDrift {
  0%,
  100% {
    transform: translateX(0);
  }

  50% {
    transform: translateX(2px);
  }
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  height: 100%;
}

body {
  --feed-column: clamp(340px, 28vw, 430px);
  --shell-padding: 20px;
  --shell-gap: 20px;
  --map-left: calc(var(--shell-padding) + var(--feed-column) + var(--shell-gap));
  --map-width: calc(100vw - (2 * var(--shell-padding)) - var(--feed-column) - var(--shell-gap));
  min-height: 100vh;
  min-height: 100dvh;
  overflow: hidden;
  position: relative;
  color: var(--text);
  font-family: "Manrope", sans-serif;
  background: var(--bg);
}

body::before,
body::after {
  content: none;
}

body[data-theme="light"] {
  background: var(--bg);
}

body[data-theme="light"][data-feed-drawer="closed"] {
  --feed-column: 0px;
}

body[data-feed-drawer="closed"] {
  --feed-column: 0px;
}

a {
  color: inherit;
}

textarea,
button,
input {
  font: inherit;
}

button {
  border: 0;
  border-radius: 12px;
  padding: 10px 12px;
  cursor: pointer;
  color: var(--button-fill-text);
  background: var(--button-fill);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: var(--button-fill-shadow);
  transition:
    transform 180ms ease,
    box-shadow 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease,
    opacity 180ms ease;
}

button:hover {
  transform: translateY(-1px);
}

button:disabled {
  cursor: default;
  opacity: 0.58;
  transform: none;
}

:focus-visible {
  outline: 2px solid rgba(227, 195, 142, 0.44);
  outline-offset: 2px;
}

h1,
h2,
.feed-item strong,
.timeline-group-copy strong,
.banner-title,
.brand-copy h2,
.dock-card-head h2,
.event-toast-copy strong {
  font-family: "Manrope", sans-serif;
}

h1,
h2 {
  margin: 0;
  font-weight: 700;
  line-height: 1.05;
}

.eyebrow,
.panel-kicker,
.search-label,
.results-summary,
.feed-item time,
.feed-item .meta,
.feed-source-name,
.severity-pill,
.feed-link,
.theme-toggle-button,
.view-mode-button,
.panel-close-button,
.desktop-drawer-toggle,
.source-status-kind,
.source-status-detail,
.source-status-footnote,
.source-countdown,
.embed-card-header,
.event-toast-copy span,
.timeline-group-copy span,
.timeline-group-caret,
.dock-kicker,
.status-pill,
.scene-pill,
.country-pill {
  font-family: "IBM Plex Mono", monospace;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.shell {
  position: relative;
  display: grid;
  grid-template-columns: var(--feed-column) minmax(0, 1fr);
  gap: var(--shell-gap);
  height: 100vh;
  height: 100dvh;
  padding: var(--shell-padding);
  transition: grid-template-columns 240ms cubic-bezier(0.22, 1, 0.36, 1);
}

.sidebar {
  width: 100%;
  min-width: 0;
  min-height: 0;
  opacity: 1;
  transition:
    transform 240ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 220ms ease;
}

body[data-feed-drawer="closed"] .sidebar {
  transform: translateX(-28px);
  opacity: 0;
  pointer-events: none;
}

.panel,
.intel-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid var(--panel-border);
  background: var(--panel);
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 24px var(--shell-shadow);
}

.panel {
  padding: 16px 16px 14px;
}

.panel-feed {
  gap: 0;
}

.panel-topbar,
.panel-actions,
.brand-lockup,
.feed-topline,
.feed-title-row,
.feed-source,
.feed-toolbar,
.intel-dock-header,
.dock-card-head,
.source-status-topline,
.source-status-copy,
.embed-card-header {
  display: flex;
  align-items: center;
}

.panel-topbar {
  justify-content: space-between;
  gap: 14px;
}

.mode-toolbar {
  display: flex;
  justify-content: flex-start;
}

.brand-lockup {
  gap: 10px;
  min-width: 0;
}

.brand-mark-shell {
  display: grid;
  place-items: center;
  flex: none;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid var(--panel-border);
  background: var(--surface-soft);
}

.brand-mark {
  width: 26px;
  height: 26px;
}

.brand-copy {
  min-width: 0;
}

.brand-copy h2 {
  font-size: 1.05rem;
  letter-spacing: 0.01em;
}

.panel-kicker,
.dock-kicker,
.eyebrow,
.search-label,
.results-summary {
  color: var(--muted);
  font-size: 0.72rem;
}

.feed-item p,
.empty-state p,
.source-status-detail,
.source-status-footnote {
  margin: 0;
  line-height: 1.55;
}

.panel-actions {
  gap: 8px;
}

.theme-toggle-button,
.panel-close-button,
.desktop-drawer-toggle {
  min-width: 0;
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: var(--control-bg);
  color: var(--text);
  box-shadow: none;
  backdrop-filter: none;
}

.sidebar-theme-toggle {
  box-shadow: none;
}

.panel-close-button {
  border-color: rgba(255, 98, 94, 0.18);
  background: transparent;
}

body[data-theme="light"] .theme-toggle-button,
body[data-theme="light"] .panel-close-button,
body[data-theme="light"] .desktop-drawer-toggle {
  border-color: var(--panel-border);
}

body[data-theme="light"] .panel-close-button {
  background: transparent;
}

.filter-stack {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 14px;
}

.search-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-field input {
  width: 100%;
  border: 1px solid var(--panel-border);
  border-radius: 12px;
  padding: 11px 12px;
  background: var(--field-bg);
  color: var(--text);
  transition:
    border-color 180ms ease,
    box-shadow 180ms ease,
    background-color 180ms ease;
}

.search-field input::placeholder {
  color: var(--muted);
}

.search-field input:focus {
  outline: none;
  border-color: rgba(227, 195, 142, 0.32);
  box-shadow: 0 0 0 4px rgba(227, 195, 142, 0.08);
}

body[data-theme="light"] .search-field input {
  border-color: var(--panel-border);
}

.severity-filter-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.severity-chip,
.clear-filters-button {
  padding: 8px 10px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: transparent;
  color: var(--muted);
  font-size: 0.71rem;
  box-shadow: none;
}

body[data-theme="light"] .severity-chip,
body[data-theme="light"] .clear-filters-button {
  border-color: var(--panel-border);
  background: transparent;
}

.severity-chip.active {
  color: var(--text);
  border-color: rgba(216, 190, 147, 0.24);
  background: var(--surface-soft);
}

.clear-filters-button:disabled {
  opacity: 0.42;
}

.feed-toolbar {
  justify-content: space-between;
  gap: 12px;
}

.results-summary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.results-summary::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: var(--accent-strong);
}

.feed {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 12px -4px 0 0;
  padding: 0 6px 0 0;
  list-style: none;
  flex: 1;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-gutter: stable;
}

.feed::-webkit-scrollbar,
.intel-panel-body::-webkit-scrollbar {
  width: 10px;
}

.feed::-webkit-scrollbar-track,
.intel-panel-body::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 999px;
}

.feed::-webkit-scrollbar-thumb,
.intel-panel-body::-webkit-scrollbar-thumb {
  background: rgba(227, 195, 142, 0.24);
  border: 2px solid transparent;
  border-radius: 999px;
  background-clip: padding-box;
}

body[data-theme="light"] .feed::-webkit-scrollbar-track,
body[data-theme="light"] .intel-panel-body::-webkit-scrollbar-track {
  background: rgba(121, 84, 45, 0.08);
}

body[data-theme="light"] .feed::-webkit-scrollbar-thumb,
body[data-theme="light"] .intel-panel-body::-webkit-scrollbar-thumb {
  background: rgba(121, 84, 45, 0.18);
  background-clip: padding-box;
}

.feed-item {
  width: 100%;
  padding: 14px;
  border-radius: 16px;
  border: 1px solid var(--panel-border);
  background: var(--surface-strong);
  color: var(--text);
  cursor: pointer;
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  box-shadow: none;
  transition:
    border-color 180ms ease,
    background-color 180ms ease;
}

.feed-item:hover {
  border-color: rgba(216, 190, 147, 0.24);
}

.feed-item.compact {
  padding: 12px;
}

.feed-item.is-latest {
  border-color: rgba(216, 190, 147, 0.28);
}

.feed-item.is-recent {
  border-color: rgba(216, 190, 147, 0.34);
  animation: feedCardIn 320ms cubic-bezier(0.22, 1, 0.36, 1);
}

body[data-theme="light"] .feed-item {
  border-color: var(--panel-border);
}

body[data-theme="light"] .feed-item.is-recent {
  border-color: rgba(162, 79, 42, 0.24);
}

.feed-item.low {
  border-left: 3px solid var(--low);
}

.feed-item.medium {
  border-left: 3px solid var(--medium);
}

.feed-item.high {
  border-left: 3px solid var(--high);
}

.feed-item.critical {
  border-left: 3px solid var(--critical);
}

.feed-topline {
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.feed-source {
  gap: 8px;
  min-width: 0;
}

.feed-source-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
  font-size: 0.7rem;
}

.feed-item time,
.feed-item .meta {
  color: var(--muted);
  font-size: 0.71rem;
}

.feed-title-row {
  justify-content: flex-start;
  align-items: flex-start;
  gap: 10px;
  margin: 10px 0 8px;
}

.feed-item strong {
  display: block;
  margin: 0;
  font-size: 1rem;
  line-height: 1.25;
  letter-spacing: 0;
}

.feed-item.compact strong {
  font-size: 0.94rem;
}

.feed-item p {
  color: var(--muted-strong);
}

body[data-theme="light"] .feed-item p {
  color: #463528;
}

.feed-aux {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin: 8px 0 10px;
}

.feed-summary {
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
}

.source-logo {
  width: 32px;
  height: 20px;
  object-fit: contain;
  border-radius: 8px;
  border: 1px solid var(--panel-border);
  background: var(--surface-soft);
}

body[data-theme="light"] .source-logo {
  border-color: var(--panel-border);
  background: var(--surface-soft);
}

.feed-media {
  position: relative;
  display: block;
  margin: 4px 0 12px;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid var(--panel-border);
  background: var(--surface-soft);
  aspect-ratio: 16 / 9;
}

.feed-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(0, 0, 0, 0.22));
  pointer-events: none;
}

.feed-media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.feed-media-badge,
.feed-link,
.status-pill,
.scene-pill,
.country-pill,
.severity-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 5px 9px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: transparent;
}

.feed-media-badge {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 1;
  color: #f6ecdf;
  font-size: 0.66rem;
}

.feed-links {
  display: flex;
  margin-top: 12px;
}

.feed-link {
  color: var(--text);
  font-size: 0.69rem;
  text-decoration: none;
  transition:
    color 180ms ease,
    border-color 180ms ease,
    background-color 180ms ease;
}

.feed-link:hover {
  color: var(--accent);
  border-color: rgba(227, 195, 142, 0.22);
}

body[data-theme="light"] .feed-media,
body[data-theme="light"] .feed-media-badge,
body[data-theme="light"] .feed-link,
body[data-theme="light"] .status-pill,
body[data-theme="light"] .scene-pill,
body[data-theme="light"] .country-pill,
body[data-theme="light"] .severity-pill {
  border-color: var(--panel-border);
  background: transparent;
}

body[data-theme="light"] .feed-media-badge {
  color: #2f2117;
}

.event-icon {
  width: 24px;
  height: 24px;
  flex: none;
}

.event-icon,
.marker-icon,
.event-toast-icon {
  display: inline-block;
  background-color: var(--text);
  -webkit-mask-image: var(--icon-url);
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  mask-image: var(--icon-url);
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
}

.severity-pill {
  font-size: 0.67rem;
}

.severity-pill.low {
  color: var(--low);
}

.severity-pill.medium {
  color: var(--medium);
}

.severity-pill.high {
  color: var(--high);
}

.severity-pill.critical {
  color: var(--critical);
}

.empty-state {
  padding: 18px;
  border-radius: 16px;
  border: 1px dashed var(--panel-border);
  background: transparent;
}

body[data-theme="light"] .empty-state {
  border-color: var(--panel-border);
  background: transparent;
}

.empty-state strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.04rem;
}

.timeline-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.timeline-group + .timeline-group {
  margin-top: 8px;
}

.timeline-group-toggle {
  width: 100%;
  justify-content: space-between;
  align-items: center;
  padding: 12px 13px;
  border-radius: 14px;
  border: 1px solid var(--panel-border);
  background: transparent;
  color: var(--text);
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  box-shadow: none;
}

body[data-theme="light"] .timeline-group-toggle {
  border-color: var(--panel-border);
  background: transparent;
}

.timeline-group-copy {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.timeline-group-copy strong {
  font-size: 1.1rem;
}

.timeline-group-copy span,
.timeline-group-caret {
  color: var(--muted);
  font-size: 0.7rem;
}

.timeline-group-body {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-left: 10px;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
}

body[data-theme="light"] .timeline-group-body {
  border-left-color: rgba(121, 84, 45, 0.12);
}

.map-stage {
  position: relative;
  min-width: 0;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid var(--panel-border);
  background: #0c0f13;
  box-shadow: 0 10px 24px var(--shell-shadow);
  isolation: isolate;
}

body[data-theme="light"] .map-stage {
  background: #eef1f4;
}

.map-stage::before,
.map-stage::after,
.map-scrim,
.map-grid {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.map-stage::before {
  content: none;
  z-index: 0;
}

.map-stage::after {
  content: "";
  inset: 1px;
  border-radius: inherit;
  border: 1px solid rgba(255, 255, 255, 0.04);
  z-index: 5;
}

.map-scrim {
  z-index: 1;
  background: linear-gradient(180deg, rgba(12, 15, 19, 0.1), rgba(12, 15, 19, 0.2));
}

body[data-theme="light"] .map-scrim {
  background: linear-gradient(180deg, rgba(238, 241, 245, 0.04), rgba(238, 241, 245, 0.1));
}

.map-grid {
  z-index: 2;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.04;
  mix-blend-mode: normal;
}

body[data-theme="light"] .map-grid {
  opacity: 0.03;
}

#map {
  position: absolute;
  inset: 0;
}

.banner,
.toast-layer,
.intel-dock,
.desktop-drawer-toggle {
  z-index: 4;
}

.view-mode-floating {
  display: inline-flex;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--panel-border);
  background: transparent;
  backdrop-filter: none;
  box-shadow: none;
}

body[data-theme="light"] .view-mode-floating {
  border-color: var(--panel-border);
  background: transparent;
}

.view-mode-button {
  min-width: 78px;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid transparent;
  color: var(--muted);
  background: transparent;
  font-size: 0.72rem;
  box-shadow: none;
}

.view-mode-button.active {
  color: var(--text);
  background: var(--surface-soft);
  border-color: var(--panel-border);
}

.banner {
  position: fixed;
  top: 10px;
  left: calc(var(--map-left) + (var(--map-width) / 2));
  transform: translateX(-50%);
  width: min(500px, calc(var(--map-width) - 28px));
  padding: 12px 14px;
  border-radius: 14px;
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.2);
  transition:
    opacity 220ms ease,
    transform 220ms ease;
}

.banner.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateX(-50%) translateY(-10px);
}

.banner.low {
  background: rgba(144, 222, 114, 0.14);
  border: 1px solid rgba(144, 222, 114, 0.3);
}

.banner.medium {
  background: rgba(243, 207, 120, 0.14);
  border: 1px solid rgba(243, 207, 120, 0.3);
}

.banner.high {
  background: rgba(255, 152, 103, 0.14);
  border: 1px solid rgba(255, 152, 103, 0.3);
}

.banner.critical {
  background: rgba(255, 98, 94, 0.16);
  border: 1px solid rgba(255, 98, 94, 0.32);
}

.banner-title {
  display: block;
  margin-bottom: 6px;
  font-size: 1.18rem;
  line-height: 0.95;
}

.toast-layer {
  position: fixed;
  top: 76px;
  left: calc(var(--map-left) + (var(--map-width) / 2));
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: min(380px, calc(var(--map-width) - 28px));
  pointer-events: none;
}

.event-toast {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--panel-border);
  background: var(--panel);
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
  opacity: 0;
  transform: translateY(-8px);
  transition:
    opacity 180ms ease,
    transform 180ms ease;
}

body[data-theme="light"] .event-toast {
  border-color: var(--panel-border);
  background: var(--panel);
  box-shadow: 0 8px 18px rgba(15, 23, 31, 0.08);
}

.event-toast.visible {
  opacity: 1;
  transform: translateY(0);
  animation: toastSlideIn 220ms ease;
}

.event-toast.leaving {
  opacity: 0;
  transform: translateY(-6px) scale(0.98);
}

.event-toast.low {
  border-color: rgba(144, 222, 114, 0.24);
}

.event-toast.medium {
  border-color: rgba(243, 207, 120, 0.24);
}

.event-toast.high {
  border-color: rgba(255, 152, 103, 0.24);
}

.event-toast.critical {
  border-color: rgba(255, 98, 94, 0.26);
}

.event-toast-icon {
  width: 22px;
  height: 22px;
  flex: none;
}

.event-toast-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.event-toast-copy strong {
  font-size: 0.94rem;
  line-height: 0.96;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.event-toast-copy span {
  color: var(--muted);
  font-size: 0.7rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.event-toast[data-event-type="siren"] .event-toast-icon,
.event-toast[data-scene-type="air-defense"] .event-toast-icon,
.event-toast[data-status="intercepted"] .event-toast-icon {
  background-color: #7edcff;
}

.event-toast[data-event-type="airstrike"] .event-toast-icon,
.event-toast[data-scene-type="airstrike"] .event-toast-icon {
  background-color: #ffc277;
}

.event-toast[data-scene-type="denial"] .event-toast-icon {
  background-color: #ff9a8e;
}

.intel-dock {
  position: absolute;
  top: 24px;
  right: 24px;
  bottom: 24px;
  width: min(360px, calc(100% - 48px));
  transition:
    transform 240ms cubic-bezier(0.22, 1, 0.36, 1),
    opacity 220ms ease;
}

body[data-intel-drawer="closed"] .intel-dock {
  transform: translateX(calc(100% + 24px));
  opacity: 0;
  pointer-events: none;
}

.intel-panel {
  padding: 16px;
}

.intel-dock-header {
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  padding-bottom: 16px;
}

.intel-heading {
  min-width: 0;
}

.intel-heading h2 {
  font-size: 1.05rem;
}

.intel-panel-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
  min-height: 0;
  padding-right: 6px;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.intel-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

body[data-theme="light"] .intel-section {
  border-bottom-color: rgba(121, 84, 45, 0.12);
}

.intel-section:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.dock-card-head {
  justify-content: space-between;
  gap: 12px;
}

.dock-card-head h2 {
  font-size: 0.96rem;
}

.source-status-list,
.market-widgets,
.x-embed-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.source-status-card,
.market-widget-card,
.x-embed-card,
.embed-fallback {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--panel-border);
  background: transparent;
}

body[data-theme="light"] .source-status-card,
body[data-theme="light"] .market-widget-card,
body[data-theme="light"] .x-embed-card,
body[data-theme="light"] .embed-fallback {
  border-color: var(--panel-border);
  background: transparent;
}

.source-status-card.empty,
.embed-fallback {
  justify-content: center;
  min-height: 88px;
}

.source-status-copy {
  gap: 8px;
  min-width: 0;
}

.source-status-copy strong,
.embed-card-header strong,
.embed-fallback strong {
  font-size: 0.92rem;
  line-height: 1;
}

.source-status-kind {
  padding: 4px 8px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted);
  font-size: 0.62rem;
}

body[data-theme="light"] .source-status-kind {
  border-color: rgba(121, 84, 45, 0.12);
}

.source-status-topline {
  justify-content: space-between;
  gap: 12px;
}

.source-countdown {
  color: var(--accent-strong);
  font-size: 0.86rem;
}

.source-status-detail,
.source-status-footnote,
.embed-card-header,
.embed-fallback {
  color: var(--muted);
  font-size: 0.69rem;
}

.source-status-card.running {
  border-color: rgba(227, 195, 142, 0.24);
}

.source-status-card.healthy {
  border-color: rgba(227, 195, 142, 0.16);
}

.source-status-card.critical {
  border-color: rgba(255, 98, 94, 0.24);
}

.source-status-card.muted {
  opacity: 0.72;
}

.market-widget-frame,
.tradingview-widget-container,
.tradingview-widget-container__widget {
  min-height: 220px;
}

.x-embed-card .twitter-timeline {
  border-radius: 18px;
}

.desktop-drawer-toggle {
  position: absolute;
  top: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  transform: translateY(-50%);
  font-size: 0.72rem;
}

.desktop-drawer-toggle-left {
  left: 18px;
}

.desktop-drawer-toggle-right {
  right: 18px;
}

body[data-feed-drawer="open"] .desktop-drawer-toggle-left,
body[data-intel-drawer="open"] .desktop-drawer-toggle-right {
  opacity: 0;
  pointer-events: none;
}

.mobile-sheet-backdrop,
.mobile-nav {
  display: none;
}

.marker {
  position: relative;
  isolation: isolate;
  display: grid;
  place-items: center;
  border-radius: 999px;
  transition: none;
}

.marker::before {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: inherit;
  pointer-events: none;
  opacity: 0;
}

.marker-shell {
  display: grid;
  place-items: center;
  width: 100%;
  height: 100%;
  border-radius: inherit;
  border: 1.5px solid rgba(255, 245, 229, 0.88);
  background: rgba(16, 12, 10, 0.84);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.marker-icon {
  width: 62%;
  height: 62%;
}

.marker-incident {
  width: 34px;
  height: 34px;
}

.marker-track {
  width: 24px;
  height: 24px;
}

.marker-track[data-motion="missile"] .marker-shell {
  background:
    radial-gradient(circle at 68% 34%, rgba(255, 241, 156, 0.82), rgba(255, 152, 103, 0.22) 58%, rgba(16, 12, 10, 0.94) 74%),
    rgba(16, 12, 10, 0.84);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.1),
    0 0 18px rgba(255, 152, 103, 0.28),
    0 0 34px rgba(255, 98, 94, 0.18);
}

body[data-view-mode="live"] .marker-incident[data-event-type="siren"] .marker-icon {
  background-color: #7edcff;
}

body[data-view-mode="live"] .marker-incident[data-event-type="airstrike"] .marker-icon,
body[data-view-mode="live"] .marker-track[data-motion="airstrike"] .marker-icon {
  background-color: #ffc277;
}

body[data-view-mode="live"] .marker-incident[data-event-type="drone"] .marker-icon,
body[data-view-mode="live"] .marker-track[data-motion="movement"] .marker-icon {
  background-color: #e9f5ff;
}

body[data-view-mode="live"] .marker-track[data-motion="movement"] .marker-shell {
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.08),
    0 0 18px rgba(126, 220, 255, 0.18);
}

body[data-view-mode="live"] .marker-spotlight[data-mode="diplomacy"] .marker-shell {
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.08),
    0 0 18px rgba(227, 195, 142, 0.2);
}

body[data-view-mode="live"] .marker-spotlight[data-mode="denial"] .marker-icon {
  background-color: #ff9a8e;
}

.marker-spotlight {
  width: 30px;
  height: 30px;
}

.marker.low.highlighted .marker-shell {
  box-shadow:
    0 0 0 8px rgba(144, 222, 114, 0.08),
    0 0 26px rgba(144, 222, 114, 0.22);
}

.marker.medium.highlighted .marker-shell {
  box-shadow:
    0 0 0 8px rgba(243, 207, 120, 0.08),
    0 0 26px rgba(243, 207, 120, 0.22);
}

.marker.high.highlighted .marker-shell {
  box-shadow:
    0 0 0 8px rgba(255, 152, 103, 0.08),
    0 0 26px rgba(255, 152, 103, 0.24);
}

.marker.critical.highlighted .marker-shell {
  box-shadow:
    0 0 0 8px rgba(255, 98, 94, 0.08),
    0 0 28px rgba(255, 98, 94, 0.28);
}

body[data-view-mode="live"] .marker-incident[data-event-type="siren"]::before,
body[data-view-mode="live"] .marker-spotlight[data-mode="air-defense"]::before {
  opacity: 1;
  border: 1px solid rgba(126, 220, 255, 0.24);
  animation: sirenSweep 1.1s ease-out infinite;
}

body[data-view-mode="live"] .marker-incident[data-event-type="siren"] .marker-shell {
  animation: sirenBlink 1s ease-in-out infinite;
}

body[data-view-mode="live"] .marker-incident[data-event-type="impact"] .marker-shell,
body[data-view-mode="live"] .marker-track[data-motion="missile"] .marker-shell {
  animation: impactThump 0.9s ease-in-out infinite;
}

body[data-view-mode="live"] .marker-incident[data-event-type="airstrike"] .marker-icon,
body[data-view-mode="live"] .marker-track[data-motion="airstrike"] .marker-icon {
  animation: airstrikeDive 1.4s ease-in-out infinite;
}

body[data-view-mode="live"] .marker-incident[data-event-type="airstrike"]::before,
body[data-view-mode="live"] .marker-track[data-motion="airstrike"]::before {
  opacity: 1;
  background: radial-gradient(circle, rgba(255, 194, 119, 0.36), transparent 66%);
  animation: airstrikeFlare 1.4s ease-in-out infinite;
}

body[data-view-mode="live"] .marker-incident[data-event-type="drone"] .marker-shell,
body[data-view-mode="live"] .marker-track[data-motion="movement"] .marker-shell {
  animation: droneHover 1.9s ease-in-out infinite;
}

body[data-view-mode="live"] .marker-incident[data-event-type="advisory"] .marker-shell,
body[data-view-mode="live"] .marker-incident[data-event-type="unknown"] .marker-shell,
body[data-view-mode="live"] .marker-spotlight[data-mode="advisory"] .marker-shell {
  animation: advisoryBreathe 2.1s ease-in-out infinite;
}

body[data-view-mode="live"] .marker-incident[data-event-type="convoy"] .marker-shell,
body[data-view-mode="live"] .marker-track[data-motion="movement"] .marker-icon {
  animation: convoyRoll 1.6s ease-in-out infinite;
}

body[data-view-mode="live"] .marker-spotlight[data-mode="diplomacy"]::before {
  opacity: 1;
  border: 1px solid rgba(227, 195, 142, 0.26);
  animation: diplomacyOrbit 2.3s linear infinite;
}

body[data-view-mode="live"] .marker-spotlight[data-mode="denial"] .marker-shell {
  animation: denialGlitch 1.3s steps(2, jump-none) infinite;
}

.marker.highlighted,
body[data-view-mode="timeline"] .marker.highlighted {
  animation: none;
}

.mapboxgl-popup-content {
  border-radius: 18px;
  padding: 14px 16px;
  background: rgba(22, 17, 13, 0.92);
  color: var(--text);
  font-family: "IBM Plex Mono", monospace;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.24);
}

body[data-theme="light"] .mapboxgl-popup-content {
  background: rgba(255, 249, 241, 0.96);
  border-color: rgba(121, 84, 45, 0.12);
  box-shadow: 0 18px 32px rgba(96, 69, 41, 0.12);
}

.mapboxgl-popup-close-button {
  color: var(--text);
}

body[data-theme="light"] .mapboxgl-popup-close-button {
  color: var(--text);
}

@media (max-width: 980px) {
  body {
    --feed-column: auto;
    --shell-padding: 0px;
    --shell-gap: 0px;
    --map-left: 0px;
    --map-width: 100vw;
  }

  .shell {
    display: block;
    padding: 0;
  }

  .sidebar,
  .intel-dock {
    position: fixed;
    inset: 0;
    z-index: 8;
    width: auto;
    max-width: none;
    min-height: 100dvh;
    padding: 14px;
    overflow-y: auto;
    transform: translateY(calc(100% + 24px));
    opacity: 0;
    pointer-events: none;
    transition:
      transform 260ms cubic-bezier(0.22, 1, 0.36, 1),
      opacity 220ms ease;
  }

  body[data-mobile-sheet="feed"] .sidebar,
  body[data-mobile-sheet="intel"] .intel-dock {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .panel,
  .intel-panel {
    min-height: calc(100dvh - 28px);
    border-radius: 18px;
  }

  .panel {
    padding: 16px 14px 96px;
  }

  .map-stage {
    height: 100vh;
    height: 100dvh;
    border-radius: 0;
    border: 0;
    box-shadow: none;
  }

  .map-stage::after {
    display: none;
  }

  .view-mode-floating {
    width: max-content;
    max-width: 100%;
  }

  .view-mode-button {
    min-width: 78px;
    padding: 8px 12px;
  }

  .banner {
    top: 14px;
    left: 14px;
    right: 14px;
    width: auto;
    transform: none;
  }

  .banner.hidden {
    transform: translateY(-10px);
  }

  .toast-layer {
    top: 84px;
    left: 14px;
    right: 14px;
    width: auto;
    transform: none;
  }

  .intel-dock {
    right: auto;
    bottom: auto;
  }

  .intel-panel {
    padding: 14px;
  }

  .intel-dock-header {
    flex-wrap: wrap;
  }

  .desktop-drawer-toggle {
    display: none;
  }

  .mobile-sheet-backdrop {
    position: fixed;
    inset: 0;
    z-index: 7;
    display: block;
    border: 0;
    background: rgba(7, 5, 4, 0.5);
    opacity: 0;
    pointer-events: none;
    transition: opacity 220ms ease;
  }

  body[data-theme="light"] .mobile-sheet-backdrop {
    background: rgba(65, 49, 35, 0.18);
  }

  body[data-mobile-sheet="feed"] .mobile-sheet-backdrop,
  body[data-mobile-sheet="intel"] .mobile-sheet-backdrop {
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-nav {
    position: fixed;
    left: 12px;
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    z-index: 9;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 8px;
    border-radius: 16px;
    border: 1px solid var(--panel-border);
    background: var(--panel);
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.18);
    transition:
      opacity 220ms ease,
      transform 220ms ease;
  }

  body[data-theme="light"] .mobile-nav {
    border-color: var(--panel-border);
    background: var(--panel);
    box-shadow: 0 8px 18px rgba(15, 23, 31, 0.08);
  }

  body[data-mobile-sheet="feed"] .mobile-nav,
  body[data-mobile-sheet="intel"] .mobile-nav {
    opacity: 0;
    transform: translateY(24px);
    pointer-events: none;
  }

  .mobile-nav-button {
    justify-content: center;
    padding: 12px 14px;
    border-radius: 16px;
    color: var(--muted);
    background: transparent;
    box-shadow: none;
  }

  .mobile-nav-button.active {
    color: var(--button-fill-text);
    background: var(--button-fill);
    box-shadow: var(--button-fill-shadow);
  }

  body[data-mobile-sheet="feed"] .banner,
  body[data-mobile-sheet="feed"] .toast-layer,
  body[data-mobile-sheet="intel"] .banner,
  body[data-mobile-sheet="intel"] .toast-layer {
    opacity: 0;
    pointer-events: none;
  }

  .panel-topbar,
  .panel-actions {
    flex-wrap: wrap;
  }

  .feed {
    padding-bottom: 8px;
  }
}

@media (max-width: 640px) {
  .panel,
  .intel-panel {
    border-radius: 24px;
  }

  .panel {
    padding: 14px 14px 92px;
  }

  .brand-mark-shell {
    width: 36px;
    height: 36px;
    border-radius: 10px;
  }

  .brand-mark {
    width: 22px;
    height: 22px;
  }

  .brand-copy h2,
  .intel-heading h2 {
    font-size: 0.96rem;
  }

  .banner {
    top: 12px;
    padding: 14px 15px;
  }

  .banner-title {
    font-size: 1.06rem;
  }

  .toast-layer {
    top: 76px;
  }

  .event-toast {
    padding: 11px 12px;
    gap: 10px;
  }

  .event-toast-copy strong {
    font-size: 0.88rem;
  }

  .feed-item {
    padding: 12px;
    border-radius: 14px;
  }

  .feed-item strong {
    font-size: 0.95rem;
  }

  .feed-item time,
  .feed-item .meta,
  .feed-source-name {
    font-size: 0.66rem;
  }

  .source-logo {
    width: 30px;
    height: 18px;
  }

  .event-icon {
    width: 20px;
    height: 20px;
  }

  .source-status-topline {
    align-items: flex-start;
    flex-direction: column;
  }

  .mobile-nav {
    left: 10px;
    right: 10px;
    bottom: max(10px, env(safe-area-inset-bottom));
    gap: 8px;
  }

  .mobile-nav-button {
    padding: 11px 12px;
    font-size: 0.72rem;
  }
}
