/* RAMJI WEATHER CHANNEL — High-Definition Marine & Emerald-Blue Theme */
:root {
  --bg-deep-ocean: #020712;
  --bg-card: rgba(4, 16, 38, 0.82);
  --bg-card-hover: rgba(7, 24, 56, 0.92);
  --border-cyan: rgba(0, 242, 254, 0.28);
  --border-emerald: rgba(16, 185, 129, 0.28);
  --glow-cyan: rgba(0, 242, 254, 0.4);
  --glow-emerald: rgba(16, 185, 129, 0.4);
  --neon-cyan: #00f2fe;
  --neon-blue: #38bdf8;
  --neon-emerald: #10b981;
  --neon-teal: #14b8a6;
}

body {
  background-color: var(--bg-deep-ocean);
  background-image: 
    radial-gradient(circle at 50% -12%, rgba(0, 242, 254, 0.22) 0px, transparent 55%),
    radial-gradient(circle at 12% 12%, rgba(0, 242, 254, 0.16) 0px, transparent 38%),
    radial-gradient(circle at 88% 15%, rgba(16, 185, 129, 0.16) 0px, transparent 40%),
    radial-gradient(circle at 50% 50%, rgba(3, 105, 161, 0.12) 0px, transparent 65%),
    radial-gradient(circle at 18% 85%, rgba(5, 150, 105, 0.14) 0px, transparent 50%),
    radial-gradient(circle at 85% 85%, rgba(14, 165, 233, 0.16) 0px, transparent 55%);
  background-attachment: fixed;
  color: #f1f5f9;
  font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  overflow-x: hidden;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

/* Subtle Cybernetic Grid Pattern Overlay */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-size: 40px 40px;
  background-image: 
    linear-gradient(to right, rgba(0, 242, 254, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(16, 185, 129, 0.03) 1px, transparent 1px);
  pointer-events: none;
  z-index: 0;
}

/* Cinematic Viewport Vignette */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  box-shadow: inset 0 0 140px rgba(0, 0, 0, 0.7);
  pointer-events: none;
  z-index: 1;
}

main, header, footer, div, section {
  position: relative;
  z-index: 2;
}

/* High-Definition Glassmorphic Panels */
.glass-panel {
  background: var(--bg-card);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--border-cyan);
  box-shadow: 
    0 12px 35px -5px rgba(0, 0, 0, 0.75),
    0 0 20px 0 rgba(0, 242, 254, 0.08),
    inset 0 1px 1px 0 rgba(255, 255, 255, 0.14);
  transition: all 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

.glass-panel:hover {
  background: var(--bg-card-hover);
  border-color: rgba(16, 185, 129, 0.55);
  box-shadow: 
    0 18px 45px -5px rgba(0, 0, 0, 0.85),
    0 0 30px 2px rgba(16, 185, 129, 0.24),
    inset 0 1px 1px 0 rgba(255, 255, 255, 0.22);
  transform: translateY(-2px);
}

/* Special High-Definition Glowing Card */
.glass-panel-hd {
  background: linear-gradient(145deg, rgba(5, 22, 52, 0.88) 0%, rgba(3, 34, 48, 0.9) 100%);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  border: 1px solid rgba(56, 189, 248, 0.35);
  box-shadow: 
    0 14px 45px 0 rgba(0, 0, 0, 0.75),
    0 0 25px 0 rgba(16, 185, 129, 0.18),
    inset 0 0 25px 0 rgba(0, 242, 254, 0.1);
  transition: all 0.3s ease;
}

.glass-panel-hd:hover {
  border-color: rgba(0, 242, 254, 0.6);
  box-shadow: 
    0 18px 50px 0 rgba(0, 0, 0, 0.82),
    0 0 35px 0 rgba(0, 242, 254, 0.28),
    inset 0 0 30px 0 rgba(16, 185, 129, 0.15);
}

/* Custom High-Definition Scrollbar */
::-webkit-scrollbar {
  width: 7px;
  height: 7px;
}
::-webkit-scrollbar-track {
  background: #020712;
}
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #00f2fe 0%, #10b981 100%);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, #38bdf8 0%, #34d399 100%);
}

/* Radiant High-Def Neon Pulses */
@keyframes neon-pulse-emerald {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.8);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

.live-badge-pulse {
  animation: neon-pulse-emerald 2s infinite;
}

@keyframes neon-pulse-cyan {
  0% {
    box-shadow: 0 0 5px rgba(0, 242, 254, 0.5), inset 0 0 5px rgba(0, 242, 254, 0.3);
  }
  50% {
    box-shadow: 0 0 20px rgba(0, 242, 254, 0.95), inset 0 0 12px rgba(0, 242, 254, 0.7);
  }
  100% {
    box-shadow: 0 0 5px rgba(0, 242, 254, 0.5), inset 0 0 5px rgba(0, 242, 254, 0.3);
  }
}

.glow-cyan-pulse {
  animation: neon-pulse-cyan 2.5s infinite ease-in-out;
}

/* Seismic pulse */
@keyframes seismic-danger {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(244, 63, 94, 0.85);
  }
  70% {
    transform: scale(1);
    box-shadow: 0 0 0 14px rgba(244, 63, 94, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(244, 63, 94, 0);
  }
}

.seismic-pulse {
  animation: seismic-danger 1.8s infinite;
}

/* Tab active state: High-Definition Cyan-to-Emerald glow */
.nav-tab-active {
  background: linear-gradient(135deg, rgba(0, 242, 254, 0.32) 0%, rgba(16, 185, 129, 0.32) 100%) !important;
  border-color: #10b981 !important;
  color: #ffffff !important;
  box-shadow: 
    0 0 22px rgba(0, 242, 254, 0.45),
    inset 0 0 12px rgba(16, 185, 129, 0.25) !important;
}

/* High-Definition Buttons */
.btn-hd-gradient {
  background: linear-gradient(135deg, #0284c7 0%, #00f2fe 50%, #10b981 100%);
  color: #ffffff;
  box-shadow: 0 4px 20px rgba(0, 242, 254, 0.38);
  transition: all 0.25s ease-in-out;
}

.btn-hd-gradient:hover {
  background: linear-gradient(135deg, #0369a1 0%, #0891b2 50%, #059669 100%);
  box-shadow: 0 6px 28px rgba(16, 185, 129, 0.55);
  transform: translateY(-1px);
}

/* Interactive Direct Chart Expand Badge */
.btn-direct-chart {
  background: rgba(4, 25, 58, 0.85);
  border: 1px solid rgba(0, 242, 254, 0.45);
  color: #00f2fe;
  font-weight: 700;
  transition: all 0.22s ease;
}

.btn-direct-chart:hover {
  background: linear-gradient(135deg, rgba(0, 242, 254, 0.25) 0%, rgba(16, 185, 129, 0.3) 100%);
  border-color: #10b981;
  color: #ffffff;
  box-shadow: 0 0 15px rgba(0, 242, 254, 0.4);
  transform: scale(1.03);
}

/* Direct Chart Quick-Access Dock Pill */
.dock-chart-btn {
  background: rgba(3, 14, 34, 0.9);
  border: 1px solid rgba(0, 242, 254, 0.25);
  transition: all 0.22s ease;
}

.dock-chart-btn:hover {
  background: linear-gradient(135deg, rgba(0, 242, 254, 0.2) 0%, rgba(16, 185, 129, 0.25) 100%);
  border-color: #00f2fe;
  box-shadow: 0 0 18px rgba(0, 242, 254, 0.35);
  transform: translateY(-1.5px);
}

/* Direct Chart Studio Modal Styles */
#direct-chart-modal {
  animation: fadeInModal 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes fadeInModal {
  from {
    opacity: 0;
    transform: scale(0.97);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Chart Canvas Clickable Indicator */
.chart-clickable {
  cursor: zoom-in;
  transition: opacity 0.2s;
}

.chart-clickable:hover {
  opacity: 0.95;
}

/* Live Intelligence Ticker with Hardware-Accelerated Edge Fade */
.ticker-wrap {
  overflow: hidden;
  white-space: nowrap;
  mask-image: linear-gradient(to right, transparent 0%, black 4%, black 96%, transparent 100%);
  -webkit-mask-image: linear-gradient(to right, transparent 0%, black 4%, black 96%, transparent 100%);
}

.ticker-content {
  display: inline-flex;
  gap: 2.5rem;
  animation: ticker-slide 38s linear infinite;
}

.ticker-content:hover {
  animation-play-state: paused;
}

@keyframes ticker-slide {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Tab Panel Fluid Entrance Animation */
@keyframes tabFadeIn {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.tab-content:not(.hidden) {
  animation: tabFadeIn 0.28s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Leaflet Map overrides for dark deep-ocean theme */
.leaflet-container {
  background: #020712 !important;
  font-family: inherit !important;
}

.leaflet-popup-content-wrapper {
  background: rgba(4, 16, 38, 0.96) !important;
  color: #f1f5f9 !important;
  border: 1px solid rgba(0, 242, 254, 0.45) !important;
  border-radius: 12px !important;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.75), 0 0 20px rgba(16, 185, 129, 0.25) !important;
}

.leaflet-popup-tip {
  background: rgba(4, 16, 38, 0.96) !important;
}

/* OpenStreetMap Cybernetic Dark Mode Filters (100% Free, Zero API Keys, Unmetered) */
#seismicMap .leaflet-tile-pane {
  filter: invert(100%) hue-rotate(180deg) brightness(75%) contrast(140%) !important;
}

#seismicMap .leaflet-control-attribution {
  background: rgba(2, 7, 18, 0.85) !important;
  color: #64748b !important;
  font-size: 10px !important;
  border-top-left-radius: 8px;
  border: 1px solid rgba(0, 242, 254, 0.2);
}

#seismicMap .leaflet-control-attribution a {
  color: #38bdf8 !important;
}

#seismicMap .leaflet-control-zoom a {
  background: rgba(4, 16, 38, 0.9) !important;
  color: #00f2fe !important;
  border: 1px solid rgba(0, 242, 254, 0.3) !important;
}

#seismicMap .leaflet-control-zoom a:hover {
  background: rgba(0, 242, 254, 0.25) !important;
  color: #ffffff !important;
}

/* Prestigious Commercial Showcase Banner */
.ad-slot-leaderboard {
  min-height: 88px;
  background: linear-gradient(135deg, rgba(3, 18, 42, 0.9) 0%, rgba(2, 28, 38, 0.92) 100%);
  border: 1px solid rgba(0, 242, 254, 0.35);
  border-radius: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 10px 30px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  position: relative;
  overflow: hidden;
}

.ad-slot-leaderboard::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(0, 242, 254, 0.12), transparent);
  transform: skewX(-25deg);
  transition: left 0.8s ease;
}

.ad-slot-leaderboard:hover::before {
  left: 160%;
}

.ad-slot-leaderboard:hover {
  border-color: rgba(16, 185, 129, 0.75);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.18), 0 14px 40px rgba(16, 185, 129, 0.22);
  transform: translateY(-2px);
}

/* Polished Form Inputs & Tactile Micro-Interactions */
select, input[type="text"], input[type="password"], textarea {
  background: rgba(2, 7, 18, 0.85) !important;
  color: #e2e8f0 !important;
  border: 1px solid rgba(0, 242, 254, 0.35) !important;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.5), 0 0 10px rgba(0, 242, 254, 0.05) !important;
  transition: all 0.2s ease !important;
}

select:focus, input[type="text"]:focus, input[type="password"]:focus, textarea:focus {
  border-color: #00f2fe !important;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.5), 0 0 16px rgba(0, 242, 254, 0.35) !important;
  outline: none !important;
}

select option {
  background: #020712;
  color: #f1f5f9;
}

button:active {
  transform: scale(0.98);
}

.city-pill-btn {
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.city-pill-btn:hover {
  transform: translateY(-1px);
}

/* ================= MASTER PROFESSIONAL STYLING SUITE ================= */

/* Accessibility & Focus-Visible Rings */
:focus-visible {
  outline: 2px solid #00f2fe !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 14px rgba(0, 242, 254, 0.6) !important;
}

/* Specular Card & Glow Classes */
.glass-card-specular {
  position: relative;
  background: rgba(4, 16, 38, 0.85);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  border: 1px solid rgba(0, 242, 254, 0.28);
  box-shadow: 
    0 16px 40px -8px rgba(0, 0, 0, 0.75),
    inset 0 1px 0 rgba(255, 255, 255, 0.15),
    0 0 25px rgba(0, 242, 254, 0.1);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.glass-card-specular:hover {
  border-color: rgba(0, 242, 254, 0.6);
  box-shadow: 
    0 20px 50px -8px rgba(0, 0, 0, 0.85),
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 0 35px rgba(0, 242, 254, 0.25);
  transform: translateY(-2px);
}

/* Dynamic Atmospheric Condition Ambient Glows for Weather Hero Card */
.weather-glow-clear {
  border-color: rgba(245, 158, 11, 0.5) !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.75), 0 0 35px rgba(245, 158, 11, 0.22), inset 0 0 20px rgba(245, 158, 11, 0.1) !important;
  background: linear-gradient(145deg, rgba(28, 20, 4, 0.9) 0%, rgba(4, 16, 38, 0.92) 100%) !important;
}

.weather-glow-rain {
  border-color: rgba(0, 242, 254, 0.55) !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.75), 0 0 35px rgba(0, 242, 254, 0.25), inset 0 0 20px rgba(0, 242, 254, 0.12) !important;
  background: linear-gradient(145deg, rgba(3, 24, 48, 0.9) 0%, rgba(4, 16, 38, 0.92) 100%) !important;
}

.weather-glow-cloudy {
  border-color: rgba(148, 163, 184, 0.45) !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.75), 0 0 30px rgba(148, 163, 184, 0.15), inset 0 0 20px rgba(148, 163, 184, 0.08) !important;
  background: linear-gradient(145deg, rgba(15, 23, 42, 0.9) 0%, rgba(4, 16, 38, 0.92) 100%) !important;
}

.weather-glow-storm {
  border-color: rgba(168, 85, 247, 0.55) !important;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.75), 0 0 40px rgba(168, 85, 247, 0.3), inset 0 0 25px rgba(168, 85, 247, 0.15) !important;
  background: linear-gradient(145deg, rgba(26, 12, 48, 0.92) 0%, rgba(4, 16, 38, 0.95) 100%) !important;
}

/* 12-Segment Visual Beaufort Wind Gauge Bar */
.beaufort-gauge-container {
  display: flex;
  gap: 3px;
  width: 100%;
  height: 8px;
  background: rgba(2, 7, 18, 0.8);
  border-radius: 9999px;
  padding: 2px;
  border: 1px solid rgba(0, 242, 254, 0.2);
}

.beaufort-segment {
  flex: 1;
  border-radius: 2px;
  background: rgba(148, 163, 184, 0.15);
  transition: all 0.3s ease;
}

.beaufort-segment.active-calm { background: #10b981; box-shadow: 0 0 6px #10b981; }
.beaufort-segment.active-breeze { background: #14b8a6; box-shadow: 0 0 6px #14b8a6; }
.beaufort-segment.active-moderate { background: #06b6d4; box-shadow: 0 0 6px #06b6d4; }
.beaufort-segment.active-fresh { background: #0284c7; box-shadow: 0 0 6px #0284c7; }
.beaufort-segment.active-gale { background: #f59e0b; box-shadow: 0 0 8px #f59e0b; }
.beaufort-segment.active-storm { background: #f43f5e; box-shadow: 0 0 10px #f43f5e; }
.beaufort-segment.active-hurricane { background: #ef4444; box-shadow: 0 0 12px #ef4444; }

/* 7-Day Temperature Range Gradient Pill Bar */
.temp-range-track {
  width: 100%;
  height: 5px;
  background: rgba(6, 22, 50, 0.8);
  border-radius: 9999px;
  overflow: hidden;
  position: relative;
}

.temp-range-fill {
  height: 100%;
  background: linear-gradient(90deg, #00f2fe 0%, #10b981 50%, #f59e0b 100%);
  border-radius: 9999px;
  transition: width 0.4s ease;
}

/* Nautical Vector Compass Indicator */
.compass-ring {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1.5px solid rgba(0, 242, 254, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(2, 7, 18, 0.7);
  box-shadow: 0 0 10px rgba(0, 242, 254, 0.2);
}

.compass-needle {
  transition: transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
  transform-origin: center center;
}

/* Skeleton Loading Shimmer for Zero Layout Shift */
.skeleton-shimmer {
  background: linear-gradient(90deg, rgba(6, 22, 50, 0.4) 25%, rgba(0, 242, 254, 0.12) 50%, rgba(6, 22, 50, 0.4) 75%);
  background-size: 200% 100%;
  animation: shimmerAnimation 1.8s infinite;
  border-radius: 8px;
}

@keyframes shimmerAnimation {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ================= CYBERNETIC NEON AURORA & ISOBAR SUITE ================= */
.cyber-neon-bg-container {
  position: fixed;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
}

/* Cinematic Atmospheric Thunderstorm Photo Backdrop (Mobile First WebP) */
.weather-photo-backdrop {
  position: absolute;
  inset: -15px;
  background-image: url('thunderstorm_bg_mobile.webp');
  background-size: cover;
  background-position: center 32%;
  background-repeat: no-repeat;
  opacity: 0.40;
  filter: contrast(1.18) saturate(1.22) brightness(0.88);
  -webkit-filter: contrast(1.18) saturate(1.22) brightness(0.88);
  transform: scale(1.02);
  will-change: transform, opacity;
  animation: atmosphericBreathe 42s ease-in-out infinite alternate;
}

@media (min-width: 640px) {
  .weather-photo-backdrop {
    background-image: url('thunderstorm_bg.webp');
  }
}

@keyframes atmosphericBreathe {
  0% { transform: scale(1.02) translate3d(0, 0, 0); opacity: 0.36; }
  50% { transform: scale(1.04) translate3d(-6px, -4px, 0); opacity: 0.43; }
  100% { transform: scale(1.02) translate3d(5px, -8px, 0); opacity: 0.38; }
}

/* Atmospheric Ambient Distant Lightning Flash Pulse */
.weather-lightning-flash {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 53% 36%, rgba(0, 242, 254, 0.45) 0%, rgba(16, 185, 129, 0.22) 42%, transparent 70%);
  opacity: 0;
  mix-blend-mode: screen;
  pointer-events: none;
  animation: lightningFlashAmbient 15s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

@keyframes lightningFlashAmbient {
  0%, 88%, 90.5%, 93%, 95.5%, 100% {
    opacity: 0;
  }
  89.5% {
    opacity: 0.18;
  }
  91.5% {
    opacity: 0.32;
  }
  94% {
    opacity: 0.14;
  }
}

/* Deep Obsidian & Azure Vignette Overlay for Crisp Typography Contrast */
.weather-photo-overlay {
  position: absolute;
  inset: 0;
  background: 
    radial-gradient(ellipse at 50% 28%, rgba(2, 7, 18, 0.4) 0%, rgba(2, 7, 18, 0.78) 60%, rgba(2, 7, 18, 0.95) 100%),
    linear-gradient(180deg, rgba(2, 7, 18, 0.7) 0%, rgba(3, 13, 34, 0.45) 35%, rgba(2, 7, 18, 0.85) 75%, rgba(2, 7, 18, 0.97) 100%);
  mix-blend-mode: multiply;
}

/* Neon Aurora Glowing Orbs */
.neon-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(100px);
  -webkit-filter: blur(100px);
  opacity: 0.22;
  will-change: transform;
  mix-blend-mode: screen;
}

.neon-orb-cyan {
  width: 580px;
  height: 580px;
  background: radial-gradient(circle, #00f2fe 0%, rgba(0, 242, 254, 0.45) 50%, transparent 75%);
  top: -120px;
  left: 8%;
  animation: floatOrbCyan 24s ease-in-out infinite alternate;
}

.neon-orb-emerald {
  width: 620px;
  height: 620px;
  background: radial-gradient(circle, #10b981 0%, rgba(16, 185, 129, 0.45) 50%, transparent 75%);
  top: 18%;
  right: 5%;
  animation: floatOrbEmerald 28s ease-in-out infinite alternate;
}

.neon-orb-azure {
  width: 680px;
  height: 680px;
  background: radial-gradient(circle, #0284c7 0%, rgba(2, 132, 199, 0.4) 50%, transparent 75%);
  bottom: 5%;
  left: 18%;
  animation: floatOrbAzure 32s ease-in-out infinite alternate;
}

.neon-orb-teal {
  width: 500px;
  height: 500px;
  background: radial-gradient(circle, #14b8a6 0%, rgba(20, 184, 166, 0.4) 50%, transparent 75%);
  top: 52%;
  right: 22%;
  animation: floatOrbTeal 26s ease-in-out infinite alternate;
}

@keyframes floatOrbCyan {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(80px, 60px, 0) scale(1.12); }
  100% { transform: translate3d(-40px, 100px, 0) scale(0.95); }
}

@keyframes floatOrbEmerald {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-70px, 80px, 0) scale(1.15); }
  100% { transform: translate3d(50px, -40px, 0) scale(0.92); }
}

@keyframes floatOrbAzure {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(90px, -60px, 0) scale(1.08); }
  100% { transform: translate3d(-60px, 40px, 0) scale(1.14); }
}

@keyframes floatOrbTeal {
  0% { transform: translate3d(0, 0, 0) scale(1); }
  50% { transform: translate3d(-50px, -80px, 0) scale(1.1); }
  100% { transform: translate3d(70px, 50px, 0) scale(0.96); }
}

/* Atmospheric Isobar Vector Lines Motion */
.neon-isobar-svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  filter: drop-shadow(0 0 8px rgba(0, 242, 254, 0.25));
}

.isobar-line {
  transition: all 0.5s ease;
}

.isobar-1 { animation: isobarDrift1 45s ease-in-out infinite alternate; }
.isobar-2 { animation: isobarDrift2 50s ease-in-out infinite alternate; }
.isobar-3 { animation: isobarDrift3 55s ease-in-out infinite alternate; }
.isobar-4 { animation: isobarDrift1 48s ease-in-out infinite alternate-reverse; }
.isobar-5 { animation: isobarDrift2 52s ease-in-out infinite alternate-reverse; }

@keyframes isobarDrift1 {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(30px, 15px, 0); }
}

@keyframes isobarDrift2 {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-25px, -12px, 0); }
}

@keyframes isobarDrift3 {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(20px, -18px, 0); }
}

/* ===================================================================
   ENHANCEMENT SUITE — ADS · MICRO-INTERACTIONS · POLISH · RESPONSIVE · A11Y
   =================================================================== */

/* --- 1. ADDITIONAL COMMERCIAL AD PLACEMENTS --- */

/* Sidebar Ad Slot (Right Rail, 300x250 equivalent) */
.sidebar-ad-slot {
  background: linear-gradient(145deg, rgba(3, 18, 42, 0.88) 0%, rgba(2, 28, 38, 0.9) 100%);
  border: 1px solid rgba(0, 242, 254, 0.3);
  border-radius: 16px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 8px 25px rgba(0, 0, 0, 0.55);
  padding: 16px;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.sidebar-ad-slot::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(16, 185, 129, 0.1), transparent);
  transform: skewX(-25deg);
  transition: left 0.7s ease;
}

.sidebar-ad-slot:hover::before {
  left: 160%;
}

.sidebar-ad-slot:hover {
  border-color: rgba(16, 185, 129, 0.65);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.16),
    0 12px 35px rgba(16, 185, 129, 0.18);
  transform: translateY(-2px);
}

/* In-Chart Overlay Ad (Sleek Ribbon atop chart containers) */
.in-chart-ad {
  background: linear-gradient(90deg, rgba(3, 14, 34, 0.92) 0%, rgba(2, 28, 38, 0.9) 50%, rgba(3, 14, 34, 0.92) 100%);
  border: 1px solid rgba(0, 242, 254, 0.25);
  border-radius: 12px;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  position: relative;
  overflow: hidden;
  transition: all 0.25s ease;
}

.in-chart-ad:hover {
  border-color: rgba(0, 242, 254, 0.55);
  box-shadow: 0 0 18px rgba(0, 242, 254, 0.15);
}

/* Footer Sponsor Strip */
.footer-sponsor-strip {
  background: linear-gradient(135deg, rgba(3, 14, 34, 0.95) 0%, rgba(2, 22, 34, 0.92) 100%);
  border-top: 1px solid rgba(0, 242, 254, 0.25);
  border-bottom: 1px solid rgba(16, 185, 129, 0.2);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.footer-sponsor-strip::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0, 242, 254, 0.5), rgba(16, 185, 129, 0.5), transparent);
}

.footer-sponsor-strip:hover {
  background: linear-gradient(135deg, rgba(4, 18, 42, 0.97) 0%, rgba(3, 28, 42, 0.95) 100%);
}

/* --- 2. MICRO-INTERACTION ENHANCEMENTS --- */

/* Enhanced Button Hover Glow + Scale */
.btn-hd-gradient {
  position: relative;
  overflow: hidden;
}

.btn-hd-gradient::after {
  content: "";
  position: absolute;
  inset: -2px;
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(0, 242, 254, 0.4), rgba(16, 185, 129, 0.4));
  opacity: 0;
  filter: blur(12px);
  transition: opacity 0.2s ease;
  z-index: -1;
}

.btn-hd-gradient:hover::after {
  opacity: 1;
}

.btn-hd-gradient:hover {
  transform: translateY(-1px) scale(1.02);
  box-shadow: 0 8px 32px rgba(0, 242, 254, 0.45), 0 0 18px rgba(16, 185, 129, 0.3);
}

.btn-hd-gradient:active {
  transform: translateY(0) scale(0.98);
}

/* Card Stagger Fade-In Entrance */
@keyframes cardFadeInUp {
  from {
    opacity: 0;
    transform: translateY(16px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.glass-panel,
.glass-panel-hd,
.glass-card-specular {
  animation: cardFadeInUp 0.35s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

/* Chart.js Tooltip Fade-In (via injected CSS for the tooltip container) */
.chartjs-tooltip,
[class*="chartjs-tooltip"] {
  transition: opacity 0.15s ease-in-out, transform 0.15s ease-in-out !important;
}

/* Variable-Speed Badge Pulse for Active Data */
@keyframes activePulseIntense {
  0% {
    transform: scale(0.92);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.9);
  }
  50% {
    transform: scale(1);
    box-shadow: 0 0 0 8px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.92);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

.live-badge-pulse-intense {
  animation: activePulseIntense 1.2s infinite;
}

/* Hover Lift for all interactive metric cards */
.glass-card-specular:hover,
.glass-panel:hover {
  transform: translateY(-2px);
}

/* --- 3. VISUAL POLISH --- */

/* Enhanced Specular Edge Glow on Glass Panels */
.glass-panel::before,
.glass-panel-hd::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(0, 242, 254, 0.45) 25%,
    rgba(16, 185, 129, 0.45) 50%,
    rgba(0, 242, 254, 0.45) 75%,
    transparent 100%);
  border-radius: inherit;
  opacity: 0.6;
  pointer-events: none;
}

.glass-panel,
.glass-panel-hd {
  position: relative;
}

/* Refined Neon Pulse — Faster for header, slower for footer */
header .live-badge-pulse {
  animation: neon-pulse-emerald 1.6s infinite;
}

footer .live-badge-pulse {
  animation: neon-pulse-emerald 3s infinite;
}

/* Enhanced Lightning Sync — Shorter, brighter bursts */
@keyframes lightningFlashIntense {
  0%, 85%, 87.5%, 90%, 93%, 100% {
    opacity: 0;
  }
  86.5% {
    opacity: 0.22;
  }
  88.5% {
    opacity: 0.42;
  }
  91% {
    opacity: 0.18;
  }
}

/* --- 4. RESPONSIVE BREAKPOINTS --- */

/* Sidebar + Main Content Layout for Large Screens */
.main-with-sidebar {
  display: flex;
  gap: 24px;
  align-items: flex-start;
}

.main-content-area {
  flex: 1;
  min-width: 0;
}

.sidebar-rail {
  width: 280px;
  flex-shrink: 0;
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Tablet (≥768px) */
@media (min-width: 768px) {
  .sidebar-rail {
    display: flex;
  }

  .in-chart-ad {
    padding: 10px 20px;
  }
}

/* Below 768px — Sidebar collapses */
@media (max-width: 767px) {
  .main-with-sidebar {
    flex-direction: column;
  }

  .sidebar-rail {
    width: 100%;
    position: static;
    flex-direction: row;
    overflow-x: auto;
    gap: 12px;
    padding-bottom: 8px;
  }

  .sidebar-ad-slot {
    min-width: 260px;
    flex-shrink: 0;
  }

  /* Ensure touch targets ≥44×44px */
  .tab-btn,
  .city-pill-btn,
  .blog-cat-btn,
  .btn-direct-chart,
  .btn-hd-gradient,
  button {
    min-height: 44px;
    min-width: 44px;
  }

  /* Footer sponsor strip stacks vertically */
  .footer-sponsor-strip {
    flex-direction: column;
    gap: 8px;
    padding: 16px;
  }
}

/* Large Desktop (≥1280px) */
@media (min-width: 1280px) {
  .sidebar-rail {
    width: 300px;
  }
}

/* Prevent horizontal overflow universally */
html, body {
  overflow-x: hidden;
  max-width: 100vw;
}

/* --- 5. ACCESSIBILITY ENHANCEMENTS --- */

/* High-contrast focus rings with glow (already present but ensure all interactive elements) */
a:focus-visible,
button:focus-visible,
select:focus-visible,
input:focus-visible,
textarea:focus-visible,
[role="tab"]:focus-visible {
  outline: 2px solid #00f2fe !important;
  outline-offset: 2px !important;
  box-shadow: 0 0 14px rgba(0, 242, 254, 0.6) !important;
}

/* Skip Navigation Link (visually hidden until focused) */
.skip-nav {
  position: absolute;
  top: -100%;
  left: 50%;
  transform: translateX(-50%);
  background: #00f2fe;
  color: #020712;
  padding: 8px 24px;
  border-radius: 0 0 12px 12px;
  font-weight: 900;
  font-size: 13px;
  z-index: 9999;
  transition: top 0.2s ease;
  text-decoration: none;
}

.skip-nav:focus {
  top: 0;
}

/* Screen Reader Only utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* High Contrast Mode Override */
@media (prefers-contrast: high) {
  .glass-panel,
  .glass-panel-hd,
  .glass-card-specular {
    border-width: 2px !important;
    border-color: #00f2fe !important;
  }

  body {
    background: #000000 !important;
    color: #ffffff !important;
  }

  .ad-slot-leaderboard,
  .sidebar-ad-slot,
  .in-chart-ad,
  .footer-sponsor-strip,
  .adsense-fallback-banner,
  #stickyBottomAdBar {
    border-width: 2px !important;
    border-color: #10b981 !important;
  }
}

/* --- CYBERNETIC COMMERCIAL FALLBACK BANNER --- */
.adsense-fallback-banner {
  transition: all 0.3s ease;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 4px 15px rgba(0, 0, 0, 0.4);
}

.adsense-fallback-banner:hover {
  border-color: rgba(0, 242, 254, 0.5);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 6px 20px rgba(0, 242, 254, 0.15);
}

/* Reduced Motion — respect user preference */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  .ticker-content {
    animation: none !important;
  }

  .weather-photo-backdrop {
    animation: none !important;
  }

  .weather-lightning-flash {
    animation: none !important;
  }
}

/* --- TECHNICAL TERMS INLINE TOOLTIP & GLOSSARY BADGES --- */
.tech-term {
  position: relative;
  cursor: help;
  border-bottom: 1.5px dotted var(--neon-cyan);
  display: inline-flex;
  align-items: center;
  gap: 3px;
  font-weight: 700;
  color: #38bdf8;
  transition: all 0.2s ease;
}

.tech-term:hover,
.tech-term:focus {
  color: #00f2fe;
  border-bottom-color: #10b981;
  text-shadow: 0 0 8px rgba(0, 242, 254, 0.4);
}

.tech-term::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 125%;
  left: 50%;
  transform: translateX(-50%) translateY(4px);
  padding: 8px 12px;
  border-radius: 10px;
  background: rgba(2, 7, 18, 0.96);
  border: 1px solid rgba(0, 242, 254, 0.45);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8), 0 0 14px rgba(0, 242, 254, 0.25);
  color: #e2e8f0;
  font-size: 11px;
  font-weight: 500;
  line-height: 1.45;
  white-space: normal;
  width: max-content;
  max-width: 280px;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.2s cubic-bezier(0.16, 1, 0.3, 1), transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 9999;
  backdrop-filter: blur(12px);
}

.tech-term:hover::after,
.tech-term:focus::after {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

@media (max-width: 640px) {
  .tech-term::after {
    left: 0;
    transform: translateY(4px);
    max-width: 220px;
  }
  .tech-term:hover::after,
  .tech-term:focus::after {
    transform: translateY(0);
  }
}

/* --- MODERN CORE WEB VITALS & HARDWARE ACCELERATION --- */
.tab-content {
  content-visibility: auto;
  contain-intrinsic-size: 1px 700px;
}

#faq-section,
#commercial-sponsors-hub {
  content-visibility: auto;
  contain-intrinsic-size: 1px 500px;
}

