/* Clean Light Mode UI Styling - Venezuela Earthquake OSINT Simulator */

:root {
  /* Colors */
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --text-main: #334155;
  --text-muted: #64748b;
  --text-inverse: #ffffff;
  
  --border-color: #e2e8f0;
  --border-focus: #cbd5e1;
  
  --primary: #475569;
  --primary-hover: #334155;
  --primary-light: #f1f5f9;
  
  --accent-blue: #2563eb;
  --accent-blue-light: #eff6ff;
  --accent-red: #dc2626;
  --accent-red-light: #fef2f2;
  --accent-orange: #d97706;
  --accent-orange-light: #fffbeb;
  --accent-green: #16a34a;
  --accent-green-light: #f0fdf4;
  
  /* Fonts */
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-title: 'Outfit', sans-serif;
  
  /* Box Shadow */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -4px rgba(0, 0, 0, 0.05);
  --shadow-glow: 0 0 12px rgba(37, 99, 235, 0.15);
  
  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-main);
  color: var(--text-main);
  overflow: hidden;
  height: 100vh;
  width: 100vw;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.app-container {
  display: flex;
  height: 100%;
  width: 100%;
  position: relative;
}

/* ==========================================
   LEFT PANEL (Control & Information Panel)
   ========================================== */
.control-panel {
  width: 400px;
  min-width: 400px;
  max-width: 400px;
  background-color: var(--bg-card);
  border-right: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
  z-index: 10;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  transition: margin-left var(--transition-normal);
}

.control-panel.collapsed {
  margin-left: -400px;
}

.panel-header {
  padding: 24px;
  border-bottom: 1px solid var(--border-color);
  background-color: #ffffff;
}

.header-badges {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: var(--accent-blue-light);
  color: var(--accent-blue);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 4px 8px;
  border-radius: 4px;
}

.system-clock-badge {
  display: inline-flex;
  align-items: center;
  gap: 6.5px;
  background-color: var(--primary-light);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.05em;
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
}

.clock-icon {
  width: 12px;
  height: 12px;
}

.pulse-dot {
  width: 6px;
  height: 6px;
  background-color: var(--accent-blue);
  border-radius: 50%;
  animation: pulse 1.8s infinite alternate;
}

@keyframes pulse {
  0% { transform: scale(0.9); opacity: 0.6; }
  100% { transform: scale(1.3); opacity: 1; }
}

.panel-header h1 {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 700;
  color: #1e293b;
  line-height: 1.3;
}

.timestamp-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.panel-content {
  flex: 1;
  overflow-y: auto;
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Scrollbar styling */
.panel-content::-webkit-scrollbar {
  width: 6px;
}
.panel-content::-webkit-scrollbar-track {
  background: transparent;
}
.panel-content::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 3px;
}
.panel-content::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Info Cards */
.info-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.info-card:hover {
  box-shadow: var(--shadow-md);
}

.card-title {
  font-family: var(--font-title);
  font-size: 15px;
  font-weight: 600;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  border-bottom: 1px solid var(--primary-light);
  padding-bottom: 8px;
}

.card-icon {
  width: 16px;
  height: 16px;
}

.info-accent { color: var(--accent-blue); }
.alert-accent { color: var(--accent-red); }
.primary-accent { color: var(--primary); }

.summary-card p {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--text-main);
  margin-bottom: 10px;
}

.summary-card p:last-child {
  margin-bottom: 0;
}

/* Casualty KPI Widget */
.kpi-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 14px;
}

.kpi-stat {
  background-color: var(--primary-light);
  border-radius: 8px;
  padding: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  border: 1px solid rgba(0, 0, 0, 0.02);
}

.kpi-value {
  font-family: var(--font-title);
  font-size: 24px;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 4px;
}

.kpi-value.highlight-red {
  color: var(--accent-red);
}

.kpi-value.highlight-orange {
  color: var(--accent-orange);
}

.kpi-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  line-height: 1.2;
}

.warning-banner {
  display: flex;
  gap: 10px;
  background-color: var(--accent-orange-light);
  border-left: 3px solid var(--accent-orange);
  padding: 10px 12px;
  border-radius: 0 6px 6px 0;
}

.warning-icon {
  color: var(--accent-orange);
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  margin-top: 2px;
}

.warning-text {
  font-size: 12px;
  line-height: 1.45;
  color: #78350f;
}

/* Layer Control Group Toggles */
.control-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.toggle-control {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 8px 4px;
  border-radius: 6px;
  transition: background-color var(--transition-fast);
}

.toggle-control:hover {
  background-color: var(--primary-light);
}

.toggle-label {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-main);
}

.toggle-icon {
  width: 15px;
  height: 15px;
  color: var(--text-muted);
}

/* Switch UI Component */
.toggle-control input {
  display: none;
}

.toggle-switch {
  position: relative;
  width: 36px;
  height: 20px;
  background-color: #cbd5e1;
  border-radius: 20px;
  transition: background-color var(--transition-fast);
}

.toggle-switch::after {
  content: "";
  position: absolute;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background-color: #ffffff;
  top: 3px;
  left: 3px;
  transition: transform var(--transition-fast);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.toggle-control input:checked + .toggle-switch {
  background-color: var(--accent-blue);
}

.toggle-control input:checked + .toggle-switch::after {
  transform: translateX(16px);
}

/* News Feed Container */
.news-feed-container {
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: opacity var(--transition-normal), max-height var(--transition-normal);
  max-height: 2000px;
}

.news-feed-container.collapsed {
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  margin: 0;
  padding: 0;
  pointer-events: none;
}

.section-title {
  font-family: var(--font-title);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
}

.title-icon {
  width: 14px;
  height: 14px;
  color: var(--accent-red);
}

.news-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.news-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 12px 14px;
  box-shadow: var(--shadow-sm);
  position: relative;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
  animation: slideIn 0.3s ease-out forwards;
}

@keyframes slideIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.news-card:hover {
  border-color: var(--border-focus);
}

.news-time {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--accent-red);
  margin-bottom: 4px;
  display: inline-block;
  background-color: var(--accent-red-light);
  padding: 2px 6px;
  border-radius: 4px;
}

.news-text {
  font-size: 12.5px;
  line-height: 1.4;
  color: var(--text-main);
}

/* ==========================================
   RIGHT PANEL (Map Canvas & Controls)
   ========================================== */
.map-wrapper {
  flex: 1;
  position: relative;
  height: 100vh;
  background-color: #eaeaea;
}

#map {
  width: 100%;
  height: 100%;
}

/* Floating Legend (Top-Right) */
.map-legend {
  position: absolute;
  top: 20px;
  right: 20px;
  background-color: rgba(255, 255, 255, 0.95);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 12px 16px;
  box-shadow: var(--shadow-lg);
  z-index: 5;
  width: 190px;
  font-size: 12px;
  pointer-events: none;
  backdrop-filter: blur(4px);
}

.map-legend h4 {
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  margin-bottom: 8px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 4px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  color: var(--text-main);
  font-weight: 500;
}

.legend-item:last-child {
  margin-bottom: 0;
}

.legend-color {
  width: 12px;
  height: 12px;
  border-radius: 3px;
  flex-shrink: 0;
}

.wave-epicenter-1 {
  background-color: var(--accent-red);
  border: 2px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 4px rgba(220, 38, 38, 0.5);
}

.wave-epicenter-2 {
  background-color: var(--accent-blue);
  border: 2px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 4px rgba(37, 99, 235, 0.5);
}

.wave-ring-1 {
  background: radial-gradient(circle, rgba(239, 68, 68, 0.2) 0%, rgba(239, 68, 68, 0) 100%);
  border: 1px solid rgba(239, 68, 68, 0.7);
}

.wave-ring-2 {
  background: radial-gradient(circle, rgba(37, 99, 235, 0.2) 0%, rgba(37, 99, 235, 0) 100%);
  border: 1px solid rgba(37, 99, 235, 0.7);
}

.density-high {
  background: linear-gradient(to right, rgba(254, 240, 138, 0.6), rgba(239, 68, 68, 0.8));
  border: 1px solid var(--border-color);
}

.heli-track {
  background-color: var(--accent-blue);
  clip-path: polygon(50% 0%, 100% 100%, 50% 75%, 0% 100%);
}

.international-track {
  background-color: #d946ef;
  clip-path: polygon(50% 0%, 100% 100%, 50% 75%, 0% 100%);
}

.plane-track {
  background-color: var(--accent-green);
  clip-path: polygon(50% 0%, 100% 100%, 50% 75%, 0% 100%); /* triangle shape */
}

.commercial-track {
  background-color: var(--accent-orange);
  clip-path: polygon(50% 0%, 100% 100%, 50% 75%, 0% 100%); /* triangle shape */
}

.ship-track-legend {
  background-color: #06b6d4;
  border-radius: 2px;
}

.commercial-ship-legend {
  background-color: #a21caf;
  border-radius: 2px;
}

.fishing-ship-legend {
  background-color: #eab308;
  border-radius: 2px;
}

.fir-boundary-legend {
  border: 1px dashed #6b21a8;
  background-color: rgba(107, 33, 168, 0.1);
  border-radius: 2px;
}

.radar-cone-legend {
  border: 1px dashed #0284c7;
  background-color: rgba(2, 132, 199, 0.05);
  border-radius: 2px;
}

.landslide-zone-legend {
  border: 1px dashed #f43f5e;
  background-color: rgba(244, 63, 94, 0.05);
  border-radius: 2px;
}

/* Glassmorphic Video-Editor Timeline Bar (Bottom-Center) */
.timeline-container {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  width: calc(100% - 40px);
  max-width: 1100px;
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: var(--shadow-lg);
  border-radius: 16px;
  padding: 12px 18px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.timeline-container.dragging {
  cursor: grabbing !important;
  user-select: none;
  transition: none !important;
}

.timeline-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  cursor: grab;
}

.timeline-toolbar .speed-controls-wrapper,
.timeline-toolbar .zoom-controls-wrapper,
.timeline-toolbar .time-badge {
  cursor: default;
}


.action-buttons-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.speed-controls-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
  background-color: var(--primary-light);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 4px 8px;
  height: 32px;
}

.speed-btn {
  background: none;
  border: none;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 4px;
  transition: background-color var(--transition-fast);
}

.speed-btn:hover {
  background-color: var(--border-color);
}

.speed-btn svg {
  width: 14px;
  height: 14px;
}

#speed-text {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-main);
  min-width: 38px;
  text-align: center;
  font-family: 'Roboto Mono', 'SFMono-Regular', Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

/* Timeline Board: Left Track Headers, Right Scrollable tracks */
.timeline-board {
  display: flex;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  overflow: hidden;
  background-color: rgba(0, 0, 0, 0.015);
  height: 292px; /* Ruler (35px) + 8 tracks * 30px + scrollbar padding (17px) */
  position: relative;
}

.track-headers {
  width: 130px;
  min-width: 130px;
  flex-shrink: 0;
  border-right: 1px solid var(--border-color);
  background-color: #f1f5f9;
  display: flex;
  flex-direction: column;
  z-index: 3;
}

.track-header-cell {
  height: 30px;
  min-height: 30px;
  display: flex;
  align-items: center;
  padding: 0 10px;
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.track-header-cell.ruler-header {
  height: 35px;
  min-height: 35px;
  font-weight: 700;
  color: var(--text-main);
  background-color: #cbd5e1;
  border-bottom: 1px solid var(--border-color);
}

.track-header-cell:last-child {
  border-bottom: none;
}

.timeline-scroll-container {
  flex: 1;
  overflow-x: hidden;
  overflow-y: hidden;
  position: relative;
  height: 100%;
}

.timeline-scroll-container::-webkit-scrollbar {
  height: 6px;
}
.timeline-scroll-container::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.02);
}
.timeline-scroll-container::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.15);
  border-radius: 3px;
}
.timeline-scroll-container::-webkit-scrollbar-thumb:hover {
  background: rgba(0, 0, 0, 0.25);
}

.timeline-track-content {
  position: relative;
  height: 100%;
  min-width: 100%;
  display: flex;
  flex-direction: column;
  user-select: none;
}

.timeline-ruler {
  height: 35px;
  min-height: 35px;
  position: relative;
  background-color: #f8fafc;
  border-bottom: 1px solid var(--border-color);
  width: 100%;
}

.track-rows-container {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.track-row {
  height: 30px;
  min-height: 30px;
  position: relative;
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
  width: 100%;
  background-color: rgba(255, 255, 255, 0.35);
}

.track-row:last-child {
  border-bottom: none;
}

.track-row:hover {
  background-color: rgba(255, 255, 255, 0.7);
}

/* Ruler Ticks */
.ruler-tick {
  position: absolute;
  bottom: 0;
  width: 1px;
  background-color: #cbd5e1;
  height: 6px;
  transform: translateX(-50%);
}

.ruler-tick.major {
  height: 12px;
  background-color: #94a3b8;
}

.ruler-tick-label {
  position: absolute;
  bottom: 14px;
  transform: translateX(-50%);
  font-size: 9px;
  font-weight: 600;
  color: var(--text-muted);
  white-space: nowrap;
}

/* Play/Pause Button */
.control-btn {
  background-color: var(--accent-blue);
  color: var(--text-inverse);
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 8px rgba(37, 99, 235, 0.25);
  transition: background-color var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
  flex-shrink: 0;
}

.control-btn:hover {
  background-color: #1d4ed8;
  transform: scale(1.05);
  box-shadow: 0 6px 12px rgba(37, 99, 235, 0.35);
}

.control-btn svg {
  width: 16px;
  height: 16px;
}

.hidden {
  display: none !important;
}

/* Custom Playhead */
.timeline-playhead {
  position: absolute;
  top: 0;
  bottom: 6px; /* leave space for scrollbar */
  width: 0;
  pointer-events: none;
  z-index: 5;
  transform: translateX(-50%);
}

.playhead-handle {
  width: 14px;
  height: 18px;
  background-color: var(--accent-blue);
  clip-path: polygon(0% 0%, 100% 0%, 100% 60%, 50% 100%, 0% 60%);
  cursor: grab;
  pointer-events: auto;
  box-shadow: 0 1px 3px rgba(0,0,0,0.3);
  position: absolute;
  top: 0;
  left: -7px;
}

.playhead-handle:active {
  cursor: grabbing;
}

.playhead-line {
  width: 2px;
  height: 100%;
  background-color: var(--accent-blue);
  box-shadow: 0 0 4px rgba(37, 99, 235, 0.4);
}

/* Timeline Track Blocks */
.timeline-block {
  position: absolute;
  top: 4px;
  bottom: 4px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 9px;
  font-weight: 700;
  color: var(--text-inverse);
  padding: 0 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(255, 255, 255, 0.25);
  cursor: pointer;
  transition: transform var(--transition-fast), filter var(--transition-fast);
}

.timeline-block:hover {
  transform: scaleY(1.05);
  filter: brightness(1.1);
  z-index: 4;
}

.block-seismic-1 {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  box-shadow: 0 0 4px rgba(239, 68, 68, 0.3);
}

.block-seismic-2 {
  background: linear-gradient(135deg, #b91c1c, #991b1b);
  box-shadow: 0 0 4px rgba(185, 28, 28, 0.4);
}

.block-heli {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  box-shadow: 0 0 4px rgba(37, 99, 235, 0.2);
}

.block-plane {
  background: linear-gradient(135deg, #22c55e, #16a34a);
  box-shadow: 0 0 4px rgba(22, 163, 74, 0.2);
}

.block-commercial {
  background: linear-gradient(135deg, #f97316, #ea580c);
  box-shadow: 0 0 4px rgba(234, 88, 12, 0.2);
}

.block-marine {
  background: linear-gradient(135deg, #06b6d4, #0891b2);
  box-shadow: 0 0 4px rgba(6, 182, 212, 0.2);
}

.block-fishing {
  background: linear-gradient(135deg, #eab308, #ca8a04);
  box-shadow: 0 0 4px rgba(234, 179, 8, 0.2);
}

.block-international {
  background: linear-gradient(135deg, #f0abfc, #d946ef);
  box-shadow: 0 0 4px rgba(217, 70, 239, 0.2);
}

/* Floating Timeline Tooltip */
.timeline-tooltip {
  position: fixed;
  background-color: rgba(15, 23, 42, 0.95);
  color: #ffffff;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 11px;
  line-height: 1.4;
  pointer-events: none;
  z-index: 1000;
  box-shadow: var(--shadow-lg);
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(4px);
  transform: translate(-50%, -110%);
  transition: opacity 0.12s ease;
  opacity: 0;
  font-family: var(--font-body);
}

.timeline-tooltip.visible {
  opacity: 1;
}

.tooltip-title {
  font-weight: 700;
  color: var(--accent-blue-light);
  margin-bottom: 2px;
}

.tooltip-details {
  font-size: 10px;
  color: #cbd5e1;
}

/* Zoom & Clock Groups styling */
.zoom-clocks-group {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.zoom-controls-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background-color: var(--primary-light);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 4px 8px;
  height: 32px;
  width: 120px;
  flex-shrink: 0;
  box-sizing: border-box;
}

.zoom-btn {
  background: none;
  border: none;
  color: var(--text-main);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4px;
  border-radius: 4px;
  transition: background-color var(--transition-fast);
}

.zoom-btn:hover {
  background-color: var(--border-color);
}

.zoom-btn svg {
  width: 14px;
  height: 14px;
}

#zoom-text {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-main);
  min-width: 32px;
  text-align: center;
  font-family: 'Roboto Mono', 'SFMono-Regular', Consolas, monospace;
  font-variant-numeric: tabular-nums;
}

.time-badge {
  background-color: var(--primary-light);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 4px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 150px;
  flex-shrink: 0;
  height: 32px;
  justify-content: center;
  box-sizing: border-box;
}

.event-time-badge {
  width: 180px;
}

.badge-prefix {
  font-size: 7.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 1px;
  line-height: 1;
  text-align: center;
}

.badge-value {
  font-family: 'Roboto Mono', 'SFMono-Regular', Consolas, monospace;
  font-variant-numeric: tabular-nums;
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  line-height: 1.1;
  text-align: center;
}

.badge-prefix {
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.badge-value {
  font-family: var(--font-title);
  font-size: 15px;
  font-weight: 700;
  color: #1e293b;
}

/* Custom Marker Styling (Maplibre) */
.custom-marker {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.custom-marker.grounded {
  opacity: 0.45 !important;
  transform: scale(0.8) !important;
}

.heli-marker {
  background-color: var(--accent-blue);
  width: 14px;
  height: 14px;
  clip-path: polygon(50% 0%, 100% 100%, 50% 75%, 0% 100%);
  filter: drop-shadow(0 2px 3px rgba(0,0,0,0.25));
}

.plane-marker {
  background-color: var(--accent-green);
  width: 14px;
  height: 14px;
  clip-path: polygon(50% 0%, 100% 100%, 50% 75%, 0% 100%);
  filter: drop-shadow(0 2px 3px rgba(0,0,0,0.25));
}

.plane-marker.commercial-marker {
  background-color: var(--accent-orange);
}

.ship-marker {
  width: 13px;
  height: 13px;
  clip-path: polygon(50% 0%, 90% 100%, 50% 75%, 10% 100%);
  background-color: #06b6d4;
  filter: drop-shadow(0 2px 3px rgba(0,0,0,0.25));
}

.ship-marker.commercial-marker {
  background-color: #a21caf;
}

.ship-marker.fishing-marker {
  background-color: #eab308;
}

/* Epicenter Marker 1 (Red) */
.epicenter-marker-1 {
  width: 14px;
  height: 14px;
  background-color: var(--accent-red);
  border: 2px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 0 2px var(--accent-red), 0 2px 5px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  position: relative;
}

.epicenter-marker-1::after {
  content: '';
  position: absolute;
  top: -6px;
  left: -6px;
  right: -6px;
  bottom: -6px;
  border: 1.5px solid var(--accent-red);
  border-radius: 50%;
  animation: epicenterRingPulse 1.8s infinite ease-out;
  pointer-events: none;
}

/* Epicenter Marker 2 (Blue) */
.epicenter-marker-2 {
  width: 14px;
  height: 14px;
  background-color: var(--accent-blue);
  border: 2px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 0 2px var(--accent-blue), 0 2px 5px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  position: relative;
}

.epicenter-marker-2::after {
  content: '';
  position: absolute;
  top: -6px;
  left: -6px;
  right: -6px;
  bottom: -6px;
  border: 1.5px solid var(--accent-blue);
  border-radius: 50%;
  animation: epicenterRingPulse 1.8s infinite ease-out;
  pointer-events: none;
}

@keyframes epicenterRingPulse {
  0% { transform: scale(0.8); opacity: 0.8; }
  100% { transform: scale(1.6); opacity: 0; }
}

/* Map popup override styling */
.maplibregl-popup-content {
  border-radius: 10px;
  padding: 10px 14px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
  font-family: var(--font-body);
}

.maplibregl-popup-content h3 {
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 4px;
}

.maplibregl-popup-content p {
  font-size: 11.5px;
  line-height: 1.4;
  color: var(--text-main);
}

/* Aircraft Telemetry HUD Style (Floating Top-Left) */
.telemetry-hud {
  position: absolute;
  top: 20px;
  left: 20px;
  width: 260px;
  background-color: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  font-family: var(--font-body);
  z-index: 10;
  transition: opacity var(--transition-normal), transform var(--transition-normal);
  overflow: hidden;
  border-left: 5px solid var(--accent-blue);
}

.telemetry-hud.hud-plane {
  border-left-color: var(--accent-green);
}

.telemetry-hud.hud-ship {
  border-left-color: #06b6d4;
}

.hud-badge.ship {
  background-color: #ecfeff;
  color: #0891b2;
}

.telemetry-hud.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translateY(-10px);
}

.hud-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-color);
  background-color: rgba(255, 255, 255, 0.4);
  cursor: grab;
  user-select: none;
}

.hud-title-group {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.hud-badge {
  font-size: 8px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  background-color: var(--accent-blue-light);
  color: var(--accent-blue);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  align-self: flex-start;
}

.hud-badge.plane {
  background-color: var(--accent-green-light);
  color: var(--accent-green);
}

.hud-header h3 {
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  margin: 0;
}

.hud-close-btn {
  background: none;
  border: none;
  font-size: 20px;
  font-weight: 300;
  cursor: pointer;
  color: var(--text-muted);
  transition: color var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
}

.hud-close-btn:hover {
  color: var(--accent-red);
}

.hud-body {
  padding: 12px 14px;
}

.hud-status {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 12px;
  padding: 5px 8px;
  background-color: var(--primary-light);
  border-radius: 6px;
  border: 1px solid rgba(0, 0, 0, 0.03);
}

.hud-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}

.hud-stat {
  display: flex;
  flex-direction: column;
  padding: 6px 8px;
  background-color: rgba(0,0,0,0.01);
  border: 1px solid rgba(0,0,0,0.02);
  border-radius: 6px;
}

.hud-label {
  font-size: 7.5px;
  font-weight: 700;
  color: var(--text-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hud-value {
  font-family: 'Roboto Mono', 'SFMono-Regular', Consolas, monospace;
  font-variant-numeric: tabular-nums;
  font-size: 11px;
  font-weight: 700;
  color: #1e293b;
  margin-top: 1px;
}

.hud-sparkline-title {
  font-size: 7.5px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.hud-sparkline-wrapper {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  background-color: rgba(0, 0, 0, 0.02);
  padding: 4px;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 60px;
}

#hud-sparkline {
  display: block;
  width: 100%;
  height: 100%;
}

/* Disclaimer Card Styles */
.disclaimer-card {
  margin-top: 10px;
}

.sources-list {
  font-size: 11.5px;
  line-height: 1.45;
  color: var(--text-main);
}

.sources-list ul {
  margin-left: 16px;
  margin-top: 4px;
  margin-bottom: 8px;
}

.sources-list li {
  margin-top: 2px;
}

.disclaimer-text {
  font-size: 10.5px;
  line-height: 1.4;
  color: var(--text-muted);
  border-top: 1px solid var(--border-color);
  padding-top: 8px;
  margin-top: 8px;
  font-style: italic;
}

/* Sidebar Toggle Collapse Button Styles */
.sidebar-toggle-btn {
  position: absolute;
  top: 100px;
  left: 0;
  width: 24px;
  height: 48px;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: 1px solid var(--border-color);
  border-left: none;
  border-radius: 0 8px 8px 0;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.08);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  padding: 0;
  margin: 0;
  outline: none;
  transition: background-color var(--transition-fast), width var(--transition-fast), box-shadow var(--transition-fast);
}

.sidebar-toggle-btn:hover {
  background-color: #ffffff;
  width: 28px;
  box-shadow: 2px 0 14px rgba(0, 0, 0, 0.15);
}

.sidebar-toggle-btn svg {
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  transition: transform var(--transition-normal);
}

.sidebar-toggle-btn:hover svg {
  color: #d946ef;
}

/* Video-Editor Style Custom Zoom Scroller */
.timeline-scroller-wrapper {
  width: 100%;
  padding: 8px 16px;
  background-color: rgba(255, 255, 255, 0.4);
  border-top: 1px solid var(--border-color);
  border-radius: 0 0 12px 12px;
  display: flex;
  justify-content: center;
  align-items: center;
  margin-top: 2px;
}

.zoom-scroller-track {
  position: relative;
  width: 100%;
  height: 8px;
  background-color: #e2e8f0;
  border-radius: 4px;
  user-select: none;
}

.zoom-scroller-bar {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0%;
  width: 100%;
  background-color: #94a3b8;
  border-radius: 4px;
  cursor: grab;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.2);
}

.zoom-scroller-bar:active {
  cursor: grabbing;
}

.zoom-handle {
  width: 12px;
  height: 12px;
  background-color: #ffffff;
  border: 2px solid #475569;
  border-radius: 50%;
  cursor: ew-resize;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
  z-index: 5;
  transition: background-color var(--transition-fast), border-color var(--transition-fast);
}

.zoom-handle-left {
  left: -6px;
}

.zoom-handle-right {
  right: -6px;
}

.zoom-handle:hover {
  background-color: #d946ef;
  border-color: #ffffff;
}

/* Transparent Introductory Overlay Modal (OSINT Info & Disclaimers) */
.intro-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: rgba(15, 23, 42, 0.2); /* lighter translucent overlay */
  backdrop-filter: blur(5px); /* reduced blur to keep background map visible */
  -webkit-backdrop-filter: blur(5px);
  z-index: 10000; /* overlay above everything */
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  visibility: visible;
  transition: opacity var(--transition-normal), visibility var(--transition-normal);
}

.intro-modal-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.intro-modal-content {
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid rgba(255, 255, 255, 0.6);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-radius: 24px;
  padding: 28px 36px;
  width: calc(100% - 40px);
  max-width: 900px; /* wider content container to fit on page without scrolling */
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-height: 95vh;
  overflow-y: auto;
  animation: modal-appear 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modal-appear {
  from {
    transform: translateY(20px) scale(0.96);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.intro-modal-header {
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  padding-bottom: 16px;
}

.intro-title-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.intro-badge {
  background-color: var(--accent-blue-light);
  color: var(--accent-blue);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 3px 8px;
  border-radius: 6px;
  width: fit-content;
}

.intro-modal-header h2 {
  font-family: var(--font-title);
  font-size: 24px;
  font-weight: 700;
  color: var(--text-main);
  margin: 0;
}

.intro-modal-body {
  font-family: var(--font-body);
  font-size: 14.5px;
  line-height: 1.6;
  color: var(--text-main);
  display: grid;
  grid-template-columns: 1.1fr 0.9fr; /* 2-column grid to fit all elements without scrolling */
  gap: 24px;
  align-items: start;
}

.intro-col-left,
.intro-col-right {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

@media (max-width: 768px) {
  .intro-modal-body {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .intro-modal-content {
    padding: 24px;
    max-height: 90vh;
  }
}

.intro-modal-body p {
  margin: 0;
}

.intro-section-box {
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 12px;
  padding: 14px 18px;
}

.intro-section-box h4 {
  font-family: var(--font-title);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  margin: 0 0 8px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.intro-section-icon {
  width: 16px;
  height: 16px;
  color: var(--accent-blue);
}

.intro-section-box ul {
  margin: 0;
  padding-left: 20px;
}

.intro-section-box li {
  margin-bottom: 6px;
  font-size: 13.5px;
}

.intro-section-box li:last-child {
  margin-bottom: 0;
}

.intro-warning-banner {
  background-color: var(--accent-red-light);
  border-left: 4px solid var(--accent-red);
  border-radius: 8px;
  padding: 12px 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.intro-warning-icon {
  width: 18px;
  height: 18px;
  color: var(--accent-red);
  flex-shrink: 0;
  margin-top: 2px;
}

.intro-warning-text {
  font-size: 13px;
  line-height: 1.5;
  color: #991b1b;
  margin: 0;
}

.intro-enter-btn {
  background-color: var(--accent-blue);
  color: white;
  border: none;
  border-radius: 12px;
  padding: 12px 28px;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: center;
  align-self: center;
  transition: background-color var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.25);
  margin-top: 8px;
}

.intro-enter-btn:hover {
  background-color: #1d4ed8;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.35);
}

.intro-enter-btn:active {
  transform: translateY(1px);
}

.intro-enter-btn svg {
  width: 16px;
  height: 16px;
}

/* Timeframe, compile, and version metadata styling */
.intro-timeframe-box {
  background-color: var(--accent-blue-light);
  border: 1px solid rgba(37, 99, 235, 0.12);
  border-radius: 12px;
  padding: 12px 16px;
  font-size: 13.5px;
  color: var(--accent-blue);
  display: flex;
  align-items: center;
  gap: 10px;
  line-height: 1.5;
}

.intro-timeframe-icon {
  width: 18px;
  height: 18px;
  color: var(--accent-blue);
  flex-shrink: 0;
}

.intro-modal-footer {
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  padding-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 4px;
}

.intro-footer-meta {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 12px;
  color: var(--text-main);
  font-weight: 500;
}

.intro-footer-source {
  font-size: 11.5px;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Sidebar header metadata styling */
.panel-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 6px;
  width: 100%;
}

.version-badge {
  background-color: var(--primary-light);
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
  border: 1px solid var(--border-color);
  line-height: 1;
}

/* Sidebar disclaimer card metadata styling */
.disclaimer-metadata {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px dashed var(--border-color);
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 11.5px;
  color: var(--text-main);
  font-weight: 500;
}

.disclaimer-source-note {
  margin-top: 6px;
  font-size: 11px;
  color: var(--text-muted);
  line-height: 1.4;
}


