/* =====================================================
   MOUNTAINWATCH — STYLESHEET
   Design: alpine instrument panel — topographic lines,
   glacier-blue data accents, amber reserved for status.
   ===================================================== */

/* ---------- DESIGN TOKENS ---------- */
:root {
  /* Colors */
  --color-bg: #161D27;
  --color-bg-alt: #10151D;
  --color-panel: #1E2733;
  --color-panel-border: #2E3A48;
  --color-text: #EAF0F1;
  --color-text-muted: #93A3AF;
  --color-accent: #5B8AA6;
  --color-accent-bright: #7FB3D3;
  --color-warn: #D9A24B;
  --color-green: #5FAE7C;

  /* Type */
  --font-display: 'Barlow Condensed', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', monospace;

  /* Layout */
  --max-width: 1180px;
  --radius: 3px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background-color: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: 0.02em;
  margin: 0;
}

p { margin: 0 0 1em 0; }
p:last-child { margin-bottom: 0; }

a { color: inherit; }

button { font-family: var(--font-body); cursor: pointer; }

:focus-visible {
  outline: 2px solid var(--color-accent-bright);
  outline-offset: 2px;
}

/* ---------- LAYOUT HELPERS ---------- */
main {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 56px;
}

section { scroll-margin-top: 90px; }

/* ---------- HEADER ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
 
  
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--color-panel-border);
}

.header-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: radial-gradient(rgba(82, 4, 82, 0.658),black) transparent 24%;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-mark { font-size: 1.7rem; line-height: 1; }

.brand-text { display: flex; flex-direction: column; }

.brand-name {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  line-height: 1.1;
}

.brand-sub {
  font-size: 0.72rem;
  color: var(--color-text-muted);
  letter-spacing: 0.02em;
}

.main-nav {
  display: flex;
  gap: 15px;
  animation: 2s bounce;
  font-size: xx-large;
  

}
@keyframes bounce{
  from{transform: scale(0.5);}
  end{transform: scale(1.5);}
}

.main-nav a {
  text-decoration: none;
  color: var(--color-text-muted);
  font-size: 0.9rem;
  font-weight: 500;
  padding: 8px 14px;
  border-radius: var(--radius);
  transition: color 0.15s ease, background-color 0.15s ease;
}

.main-nav a:hover {
  color: var(--color-text);
  background: rgba(255,255,255,0.04);
}

/* ---------- HERO ---------- */
.hero { padding: 64px 0 8px; }

.hero-inner { max-width: 760px; }

.hero-badges {
  display: flex;
  gap: 10px;
  margin-bottom: 22px;
  flex-wrap: wrap;
}

.badge {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  padding: 5px 10px;
  border-radius: var(--radius);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.badge-outline {
  border: 1px solid var(--color-panel-border);
  color: var(--color-text-muted);
}

.badge-status {
  background: rgba(95, 174, 124, 0.12);
  color: var(--color-green);
  border: 1px solid rgba(95, 174, 124, 0.3);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}

.status-dot--green { background: var(--color-green); box-shadow: 0 0 6px rgba(95,174,124,0.7); }
.status-dot--large { width: 14px; height: 14px; }

.hero-title {
  font-size: clamp(2rem, 5vw, 3.1rem);
  line-height: 1.08;
  margin-bottom: 20px;
  color: var(--color-text);
}

.hero-description {
  font-size: 1.05rem;
  color: var(--color-text-muted);
  max-width: 620px;
}

/* ---------- PANELS (shared card style) ---------- */
.panel {
  background: var(--color-panel);
  border: 1px solid var(--color-panel-border);
  border-radius: var(--radius);
  padding: 26px 28px;
  position: relative;
}

/* subtle topographic contour lines in the corner of every panel */
.panel::before {
  content: "";
  position: absolute;
  top: 0; right: 0;
  width: 140px; height: 140px;
  pointer-events: none;
  border-top-right-radius: var(--radius);
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 20px;
}

.panel-header--section { margin-bottom: 22px; }

.panel-header h2 {
  font-size: 1.3rem;
  letter-spacing: 0.03em;
}

.phase-tag {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.03em;
  color: var(--color-warn);
  background: rgba(217, 162, 75, 0.1);
  border: 1px solid rgba(217, 162, 75, 0.28);
  padding: 4px 9px;
  border-radius: var(--radius);
  white-space: nowrap;
}

/* ---------- DASHBOARD GRID (weather + status) ---------- */
.dashboard-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 20px;
}

/* ---------- WEATHER CARD ---------- */
.weather-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.weather-stat {
  background: var(--color-bg-alt);
  border: 1px solid var(--color-panel-border);
  border-radius: var(--radius);
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.weather-stat--wide { grid-column: span 2; }

.weather-value {
  font-family: var(--font-mono);
  font-size: 1.6rem;
  color: var(--color-accent-bright);
  font-weight: 500;
}

.weather-value--text {
  font-size: 1rem;
  color: var(--color-text-muted);
  font-style: italic;
}

.weather-label {
  font-size: 0.74rem;
  color: var(--color-text-muted);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.weather-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding-top: 16px;
  border-top: 1px solid var(--color-panel-border);
}

.weather-updated {
  font-size: 0.82rem;
  color: var(--color-text-muted);
}

/* ---------- STATUS PANEL ---------- */
.status-panel { display: flex; flex-direction: column; min-width: 0; }

.status-display {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 4px 0 8px;
}

.status-text {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--color-green);
  letter-spacing: 0.04em;
}

.status-summary {
  color: var(--color-text-muted);
  font-size: 0.82rem;
  min-height: 42px;
  margin-bottom: 14px;
}

.status-metrics {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}

.status-metric {
  background: var(--color-bg-alt);
  border: 1px solid var(--color-panel-border);
  border-radius: var(--radius);
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.status-metric-value {
  font-family: var(--font-mono);
  font-size: 0.76rem;
  color: var(--color-accent-bright);
}

.status-metric-value[data-level="elevated"] { color: var(--color-warn); }
.status-metric-value[data-level="moderate"] { color: var(--color-warn); }
.status-metric-value[data-level="high"] { color: #d86a6a; }

.status-metric-label {
  color: var(--color-text-muted);
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.04em;
}

.status-details {
  display: grid;
  gap: 7px;
  padding-top: 11px;
  border-top: 1px solid var(--color-panel-border);
}

.status-details > div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.status-detail-label {
  color: var(--color-text-muted);
  font-family: var(--font-mono);
  font-size: 0.58rem;
  white-space: nowrap;
}

.status-detail-value {
  color: var(--color-text);
  font-size: 0.68rem;
  text-align: right;
}

.status-footer {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: auto;
  padding-top: 12px;
  border-top: 1px solid var(--color-panel-border);
  color: var(--color-text-muted);
  font-size: 0.62rem;
}

.status-dot--normal {
  background: var(--color-green);
  box-shadow: 0 0 8px rgba(95,174,124,0.75);
}

.status-dot--elevated,
.status-dot--moderate {
  background: var(--color-warn);
  box-shadow: 0 0 8px rgba(217,162,75,0.75);
}

.status-dot--high {
  background: #d86a6a;
  box-shadow: 0 0 8px rgba(216,106,106,0.75);
}

.status-panel[data-status="elevated"] .status-text { color: var(--color-warn); }
.status-panel[data-status="moderate"] .status-text { color: var(--color-warn); }
.status-panel[data-status="high"] .status-text { color: #d86a6a; }

/* ---------- BUTTONS ---------- */
.btn {
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 11px 18px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  transition: transform 0.1s ease, background-color 0.15s ease, border-color 0.15s ease;
}

.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--color-warn);
  color: #1A1206;
}

.btn-primary:hover { background: #e5ad57; }

.btn-secondary {
  background: transparent;
  border-color: var(--color-accent);
  color: var(--color-accent-bright);
}

.btn-secondary:hover { background: rgba(91, 138, 166, 0.12); }

/* ---------- MAP ---------- */
.map-section { display: flex; flex-direction: column; }

#map {
  width: 100%;
  height: 460px;
  border-radius: var(--radius);
  border: 1px solid var(--color-panel-border);
  background: var(--color-panel);
}

/* Leaflet popup theming so it matches the dashboard */
.leaflet-popup-content-wrapper {
  background: var(--color-panel);
  color: var(--color-text);
  border-radius: var(--radius);
}

.leaflet-popup-tip { background: var(--color-panel); }

/* ---------- ROAD REPORTS / EMPTY STATE ---------- */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  border: 1px dashed var(--color-panel-border);
  border-radius: var(--radius);
}

.empty-state-title {
  display: block;
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--color-text-muted);
  margin-bottom: 6px;
}

.empty-state-text {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: 22px;
}

/* ---------- STATISTICS ---------- */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.stat-card {
  background: var(--color-panel);
  border: 1px solid var(--color-panel-border);
  border-radius: var(--radius);
  padding: 22px 16px;
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.stat-value {
  font-family: var(--font-mono);
  font-size: 2.1rem;
  color: var(--color-accent-bright);
  font-weight: 500;
}

.stat-value--text {
  font-size: 1.15rem;
  color: var(--color-text-muted);
}

.stat-label {
  font-size: 0.75rem;
  color: var(--color-text-muted);
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.stats-note {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.82rem;
  margin-top: 16px;
}

/* ---------- HOW IT WORKS ---------- */
.process-flow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.process-step {
  width: 100%;
  max-width: 420px;
  background: var(--color-panel);
  border: 1px solid var(--color-panel-border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.process-icon { font-size: 1.4rem; }

.process-title {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  display: block;
}

.process-desc {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  display: block;
}

.process-step > .process-icon + * {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.process-arrow {
  color: var(--color-panel-border);
  font-size: 1.1rem;
  line-height: 1;
}

.how-it-works-note {
  text-align: center;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  margin-top: 20px;
  max-width: 520px;
  margin-left: auto;
  margin-right: auto;
}



/* ---------- ABOUT ---------- */
.about-panel p { color: var(--color-text-muted); }
.about-panel p:first-of-type { color: var(--color-text); }

/* ---------- FOOTER ---------- */
.site-footer {
  margin-top: 70px;
  padding: 36px 24px 48px;
  border-top: 1px solid var(--color-panel-border);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  text-align: center;
}

.footer-brand {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.footer-line {
  font-size: 0.82rem;
  color: var(--color-text-muted);
}

.footer-tagline {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  font-style: italic;
  margin-top: 6px;
}

/* ---------- RESPONSIVE ---------- */
@media (max-width: 860px) {
  .dashboard-grid { grid-template-columns: 1fr; }
  .weather-grid { grid-template-columns: repeat(2, 1fr); }
  .weather-stat--wide { grid-column: span 2; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .header-inner { flex-direction: column; align-items: flex-start; gap: 10px; }
  .main-nav { width: 100%; justify-content: flex-start; }
}

@media (max-width: 520px) {
  .hero { padding-top: 44px; }
  .weather-grid { grid-template-columns: 1fr 1fr; }
  #map { height: 340px; }
  .panel { padding: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}


/* ---------- LIVE SYSTEM
.weather-location {
  margin: -10px 0 18px;
  color: var(--color-text-muted);
  font-size: 0.82rem;
  font-family: var(--font-mono);
}

.phase-tag--live {
  color: var(--color-green);
  background: rgba(95, 174, 124, 0.10);
  border-color: rgba(95, 174, 124, 0.28);
}

.weather-source {
  margin-top: 10px;
  color: var(--color-text-muted);
  font-size: 0.72rem;
  font-family: var(--font-mono);
}

.weather-error {
  min-height: 0;
  margin-top: 10px;
  color: var(--color-warn);
  font-size: 0.82rem;
}

.weather-error:empty {
  display: none;
}

.weather-loading {
  opacity: 0.65;
}

/* =====================================================
   LIVE SYSTEM
   ===================================================== */
.reports-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 18px;
  margin-bottom: 18px;
}

.report-filters {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.report-filters label,
#road-report-form > label {
  display: flex;
  flex-direction: column;
  gap: 7px;
  color: var(--color-text-muted);
  font-size: 0.76rem;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.report-filters select,
#road-report-form select,
#road-report-form textarea {
  background: var(--color-bg);
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-radius: 5px;
  padding: 10px 12px;
  font: inherit;
  text-transform: none;
  outline: none;
}

.report-filters select:focus,
#road-report-form select:focus,
#road-report-form textarea:focus {
  border-color: var(--color-green);
}

.reports-list {
  display: grid;
  gap: 10px;
}

.report-card {
  border: 1px solid var(--color-border);
  border-left: 4px solid var(--color-green);
  border-radius: 6px;
  padding: 15px 16px;
  background: rgba(255,255,255,0.015);
}

.report-card--medium { border-left-color: var(--color-warn); }
.report-card--high { border-left-color: #d86a6a; }

.report-card-top,
.report-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.report-type {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.severity-badge {
  display: inline-block;
  margin-left: 8px;
  padding: 3px 7px;
  border-radius: 4px;
  font-size: 0.65rem;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.severity-low { color: var(--color-green); background: rgba(95,174,124,0.12); }
.severity-medium { color: var(--color-warn); background: rgba(229,173,87,0.12); }
.severity-high { color: #e78a8a; background: rgba(216,106,106,0.12); }

.report-time,
.report-card-bottom {
  color: var(--color-text-muted);
  font-size: 0.72rem;
  font-family: var(--font-mono);
}

.report-description {
  margin: 11px 0;
  line-height: 1.5;
}

.text-button {
  background: transparent;
  border: 0;
  color: var(--color-green);
  cursor: pointer;
  font: 600 0.7rem var(--font-mono);
}

.info-note {
  margin-top: 14px;
  color: var(--color-text-muted);
  font-size: 0.72rem;
  line-height: 1.5;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(0,0,0,0.72);
  overflow-y: auto;
}

.modal-backdrop[hidden] { display: none; }
body.modal-open { overflow: hidden; }

.report-modal {
  width: min(680px, 100%);
  max-height: calc(100vh - 36px);
  overflow-y: auto;
  background: var(--color-panel);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 20px 70px rgba(0,0,0,0.45);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 22px;
}

.modal-header h2 {
  margin: 10px 0 0;
}

.modal-close {
  width: 38px;
  height: 38px;
  border: 1px solid var(--color-border);
  border-radius: 5px;
  background: transparent;
  color: var(--color-text);
  font-size: 1.5rem;
  cursor: pointer;
}

#road-report-form {
  display: grid;
  gap: 18px;
}

.location-tools {
  display: grid;
  gap: 10px;
  padding: 15px;
  border: 1px solid var(--color-border);
  border-radius: 6px;
}

.location-tools strong {
  font-family: var(--font-display);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.location-tools p {
  margin: 5px 0 0;
  color: var(--color-text-muted);
  font-family: var(--font-mono);
  font-size: 0.8rem;
}

.location-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.form-message {
  color: var(--color-text-muted);
  font-size: 0.78rem;
  line-height: 1.45;
}

.form-message.is-warning { color: var(--color-warn); }

#road-report-form textarea {
  resize: vertical;
  min-height: 110px;
  width: 100%;
  box-sizing: border-box;
}

.char-counter {
  align-self: end;
  margin-top: -4px;
  color: var(--color-text-muted);
  font: 0.68rem var(--font-mono);
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 4px;
}

.map-popup { min-width: 190px; }
.map-popup p { margin: 6px 0; }
.map-popup small { color: #666; }

@media (max-width: 620px) {
  .reports-toolbar,
  .report-card-top,
  .report-card-bottom {
    align-items: stretch;
    flex-direction: column;
  }

  .reports-toolbar .btn { width: 100%; }
  .report-filters { display: grid; grid-template-columns: 1fr 1fr; }
  .report-filters label select { width: 100%; box-sizing: border-box; }
  .location-buttons .btn { width: 100%; }
  .modal-actions { flex-direction: column-reverse; }
  .modal-actions .btn { width: 100%; }
}



@media (max-width: 860px) {
  .status-details > div {
    flex-direction: column;
    gap: 2px;
  }

  .status-detail-value {
    text-align: left;
  }
}

/* Phase 3 map-location selection hint */
.map-selection-hint {
  position: fixed;
  top: 90px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3000;
  width: min(420px, calc(100vw - 32px));
  padding: 12px 16px;
  border: 1px solid var(--color-accent);
  border-radius: 8px;
  background: var(--color-panel);
  color: var(--color-text);
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.82rem;
}

.map-selection-hint span {
  color: var(--color-text-muted);
}

.map-selection-hint[hidden] {
  display: none;
}

/* ============================
   LIVE SYSTEM
   ============================ */
#cloud-status {
    display: inline-block;
    margin-top: 0.25rem;
    font-size: 0.72rem;
    letter-spacing: 0.05em;
}

#cloud-status.is-warning {
    opacity: 0.9;
}



/* Earthquake map rows are interactive */
.earthquake-row:hover {
  transform: translateX(3px);
  background: rgba(255,255,255,0.045);
}

/* =====================================================
   MOUNTAINWATCH VISUAL EXPERIENCE — FINAL POLISH
   ===================================================== */
:root {
  --color-bg: #08121b;
  --color-bg-alt: #0b1722;
  --color-panel: rgba(17, 31, 44, 0.88);
  --color-panel-border: rgba(102, 166, 197, 0.22);
  --color-border: rgba(102, 166, 197, 0.22);
  --color-text: #edf7fb;
  --color-text-muted: #91a9b8;
  --color-accent: #3e9bc4;
  --color-accent-bright: #7bd8ff;
  --color-warn: #f0ad4e;
  --color-green: #38d39f;
  --color-danger: #ff6676;
  --shadow-panel: 0 18px 55px rgba(0, 0, 0, .28);
  --glow-blue: 0 0 28px rgba(62, 155, 196, .16);
  --radius: 8px;
}

html { background: #061019; }
body {
  position: relative;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 12% 8%, rgba(17, 59, 77, 0.14), transparent 28%),
    radial-gradient(circle at 88% 18%, rgba(69, 3, 122, 0.788), transparent 30%),
    linear-gradient(180deg, #07121c 0%, #0a1722 45%, #07111a 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -3;
  opacity: .22;
  background-image:
    linear-gradient(rgba(120, 190, 220, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(120, 190, 220, .06) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}

.ambient-grid { position: fixed; inset: 0; pointer-events: none; z-index: -2; overflow: hidden; }
.ambient-grid::after {
  content: "";
  position: absolute;
  width: 70vw;
  height: 70vw;
  right: -25vw;
  top: 5vh;
  border: 1px solid rgba(123, 216, 255, .08);
  border-radius: 50%;
  box-shadow: 0 0 0 60px rgba(123,216,255,.025), 0 0 0 120px rgba(123,216,255,.018);
  animation: orbitGlow 16s ease-in-out infinite alternate;
}
.ambient-glow { position: fixed; width: 420px; height: 420px; border-radius: 50%; pointer-events:none; z-index:-1; filter: blur(60px); opacity:.18; }
.ambient-glow--one { left:-180px; top:28%; background:#2f9bc5; animation: floatGlow 12s ease-in-out infinite; }
.ambient-glow--two { right:-180px; bottom:12%; background:#6a4bd8; animation: floatGlow 15s ease-in-out infinite reverse; }

.page-loader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: grid;
  place-items: center;
  background: #061019;
  transition: opacity .65s ease, visibility .65s ease;
}
.page-loader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.loader-core { position: relative; display:flex; flex-direction:column; align-items:center; gap:16px; animation: loaderIn .8s ease both; }
.loader-core img { width:130px; height:130px; object-fit:contain; filter: drop-shadow(0 0 28px rgba(79,193,237,.3)); }
.loader-core span { color:#82cbe8; font:600 .68rem var(--font-mono); letter-spacing:.16em; }
.loader-ring { position:absolute; width:170px; height:170px; border:1px solid rgba(123,216,255,.15); border-top-color:#7bd8ff; border-radius:50%; animation: spin 1.2s linear infinite; }

.site-header {
  background: rgba(5, 15, 24, .72);
  border-bottom-color: rgba(123,216,255,.13);
  box-shadow: 0 8px 35px rgba(0,0,0,.2);
  
}
.site-header::after {
  content:""; position:absolute; left:0; bottom:-1px; width:27%; height:1px;
  background: linear-gradient(190deg, transparent, #ff5555, transparent);
  animation: headerSweep 5s ease-in-out infinite;
  padding: 2px;
}
.header-inner { padding-top:11px; padding-bottom:11px; }
.brand-logo { width:48px; height:48px; object-fit:contain; border-radius:10px; filter: drop-shadow(0 0 12px rgba(75,190,235,.22)); transition: transform .35s ease, filter .35s ease; }
.brand:hover .brand-logo { transform: rotate(-3deg) scale(1.06); filter: drop-shadow(0 0 20px rgba(75,190,235,.4)); }
.brand-name { letter-spacing:.055em; }
.main-nav a { position:relative; transition: color .25s ease, background .25s ease, transform .25s ease; }
.main-nav a::after { content:""; position:absolute; left:14px; right:14px; bottom:3px; height:2px; transform:scaleX(0); transform-origin:center; background:#66d7ff; transition:transform .25s ease; }
.main-nav a:hover { transform:translateY(-1px); }
.main-nav a:hover::after { transform:scaleX(1); }

.hero { position:relative; padding:82px 0 18px; min-height:330px; display:flex; align-items:center; }
.hero::before { content:""; position:absolute; width:520px; height:260px; left:-100px; top:20px; background:radial-gradient(ellipse, rgba(47,155,197,.18), transparent 68%); pointer-events:none; }
.hero-inner { position:relative; z-index:1; }
.hero-badges { animation: riseIn .75s .1s both; }
.hero-title { font-size:clamp(2.5rem, 6vw, 4.5rem); letter-spacing:.015em; text-shadow:0 0 35px rgba(113,211,248,.11); animation: titleIn .9s .18s both; }
.hero-description { font-size:1.04rem; max-width:700px; animation: riseIn .8s .3s both; }
.hero-live-strip { display:flex; flex-wrap:wrap; gap:9px; margin-top:24px; animation: riseIn .8s .42s both; }
.hero-live-strip span { display:inline-flex; align-items:center; gap:7px; padding:7px 10px; border:1px solid rgba(92,177,212,.18); background:rgba(10,26,38,.6); border-radius:999px; color:#8fb9cb; font:600 .61rem var(--font-mono); letter-spacing:.08em; }
.hero-live-strip i { width:6px; height:6px; border-radius:50%; background:#35d3a0; box-shadow:0 0 10px rgba(53,211,160,.85); animation: pulseDot 1.8s infinite; }

.panel, .map-section, .stats-section, .how-it-works {
  box-shadow: var(--shadow-panel);
  border-color:rgba(108,177,209,.18);
  backdrop-filter: blur(10px);
  overflow:hidden;
}
.panel::after, .map-section::after {
  content:""; position:absolute; inset:0; pointer-events:none; border-radius:inherit;
  background:linear-gradient(120deg, rgba(123,216,255,.05), transparent 28%, transparent 72%, rgba(123,216,255,.025));
  opacity:.8;
}
.panel-header h2 { letter-spacing:.055em; }
.phase-tag { border-radius:999px; padding:5px 10px; box-shadow:0 0 18px rgba(53,211,160,.06); }
.phase-tag--live { animation: statusShimmer 3.2s ease-in-out infinite; }

.weather-stat, .status-metric, .stat-card, .process-step, .earthquake-row, .report-card {
  transition: transform .28s cubic-bezier(.2,.8,.2,1), border-color .28s ease, box-shadow .28s ease, background .28s ease;
}
.weather-stat:hover, .status-metric:hover, .stat-card:hover, .process-step:hover, .earthquake-row:hover, .report-card:hover {
  transform: translateY(-5px);
  border-color:rgba(104,205,245,.4);
  box-shadow:0 12px 30px rgba(0,0,0,.22), 0 0 24px rgba(48,151,197,.08);
  background:rgba(16,39,55,.86);
}
.weather-value, .status-metric-value, .stat-value { text-shadow:0 0 18px rgba(123,216,255,.16); }

.status-panel { position:relative; }
.status-panel[data-status="normal"] { box-shadow:var(--shadow-panel), inset 0 1px 0 rgba(53,211,160,.12); }
.status-panel[data-status="elevated"], .status-panel[data-status="moderate"] { box-shadow:var(--shadow-panel), inset 0 1px 0 rgba(240,173,78,.16); }
.status-panel[data-status="high"] { box-shadow:var(--shadow-panel), inset 0 1px 0 rgba(255,102,118,.2); }
.status-dot--large { animation: statusPulse 2s infinite; }
.status-summary { color:#aac1cd; }

.btn { position:relative; overflow:hidden; border-radius:7px; transition:transform .25s ease, box-shadow .25s ease, background .25s ease, border-color .25s ease; }
.btn::before { content:""; position:absolute; inset:0; transform:translateX(-120%); background:linear-gradient(100deg, transparent, rgba(255,255,255,.18), transparent); transition:transform .55s ease; }
.btn:hover::before { transform:translateX(120%); }
.btn:hover { transform:translateY(-2px); box-shadow:0 9px 22px rgba(0,0,0,.2); }
.btn-primary { background:linear-gradient(135deg,#f0ad4e,#ffc56e); box-shadow:0 6px 18px rgba(240,173,78,.12); }
.btn-secondary:hover { box-shadow:0 0 24px rgba(62,155,196,.13); }

.map-section { position:relative; padding:20px; background:rgba(13,28,41,.82); }
.map-section .panel-header--section { padding:0 6px; }
#map { height:500px; border-radius:10px; border-color:rgba(99,185,222,.22); box-shadow:inset 0 0 0 1px rgba(255,255,255,.02), 0 15px 40px rgba(0,0,0,.22); animation: mapBreath 8s ease-in-out infinite; }
.leaflet-control-zoom a { background:#0e202e !important; color:#d8f4ff !important; border-color:#315064 !important; }
.leaflet-control-attribution { background:rgba(7,17,25,.82) !important; color:#7895a5 !important; }
.leaflet-popup-content-wrapper { box-shadow:0 16px 50px rgba(0,0,0,.35); border:1px solid rgba(113,201,235,.22); }

.earthquake-panel { background:linear-gradient(145deg, rgba(18,35,49,.94), rgba(11,24,35,.92)); }
.earthquake-value { color:#75d9ff; text-shadow:0 0 20px rgba(117,217,255,.18); }
.earthquake-row { position:relative; overflow:hidden; }
.earthquake-row::after { content:""; position:absolute; top:0; bottom:0; left:-70%; width:45%; background:linear-gradient(90deg,transparent,rgba(255,255,255,.035),transparent); transform:skewX(-18deg); animation: rowSweep 6s ease-in-out infinite; }

.stats-section { padding:22px 24px; background:rgba(14,29,42,.76); }
.stat-card { position:relative; min-height:112px; justify-content:center; background:linear-gradient(150deg,rgba(21,42,58,.92),rgba(9,21,31,.8)); }
.stat-card::before { content:""; position:absolute; left:0; top:0; width:2px; height:100%; background:linear-gradient(180deg,#67d9ff,transparent); opacity:.7; }

.process-step { position:relative; border-radius:10px; background:linear-gradient(150deg,rgba(18,39,54,.9),rgba(9,22,32,.86)); }
.process-arrow { color:#4ea4c9; animation: arrowPulse 2s ease-in-out infinite; }
.how-it-works { padding:28px; }

.about-panel { background:linear-gradient(150deg,rgba(18,35,49,.88),rgba(9,21,31,.84)); }
.about-panel p:first-of-type { font-size:1rem; }

.site-footer { position:relative; margin-top:40px; padding:48px 24px 56px; background:linear-gradient(180deg,transparent,rgba(6,15,23,.55)); }
.site-footer::before { content:""; position:absolute; top:0; width:min(720px,80%); height:1px; background:linear-gradient(90deg,transparent,#4bb9e4,transparent); box-shadow:0 0 16px rgba(75,185,228,.35); }
.footer-brand { font-size:1.45rem; }
.footer-credit { color:#8bb7c9; font:600 .72rem var(--font-mono); letter-spacing:.05em; }

.reveal-on-scroll { opacity:0; transform:translateY(28px); transition:opacity .7s ease var(--reveal-delay), transform .7s cubic-bezier(.2,.8,.2,1) var(--reveal-delay); }
.reveal-on-scroll.is-visible { opacity:1; transform:none; }
.interactive-card { animation: cardIn .55s ease both; animation-delay:var(--card-delay); }


@keyframes loaderIn { from {opacity:0; transform:scale(.88) translateY(12px)} to {opacity:1; transform:none} }
@keyframes spin { to { transform:rotate(360deg); } }
@keyframes riseIn { from {opacity:0; transform:translateY(20px)} to {opacity:1; transform:none} }
@keyframes titleIn { from {opacity:0; transform:translateY(24px) scale(.985); filter:blur(4px)} to {opacity:1; transform:none; filter:none} }
@keyframes pulseDot { 0%,100% {transform:scale(1); opacity:.8} 50% {transform:scale(1.6); opacity:1} }
@keyframes statusPulse { 0%,100% { box-shadow:0 0 0 0 rgba(56,211,159,.22),0 0 8px rgba(56,211,159,.7)} 50% { box-shadow:0 0 0 9px rgba(56,211,159,0),0 0 16px rgba(56,211,159,.95)} }
@keyframes statusShimmer { 0%,100% { box-shadow:0 0 0 rgba(53,211,160,0)} 50% { box-shadow:0 0 22px rgba(53,211,160,.1)} }
@keyframes headerSweep { 0%,100% { transform:translateX(-10vw); opacity:.15 } 50% { transform:translateX(300%); opacity:1 } }
@keyframes orbitGlow { from {transform:translate3d(0,0,0) rotate(0deg)} to {transform:translate3d(-3vw,2vh,0) rotate(7deg)} }
@keyframes floatGlow { 0%,100% {transform:translate(0,0)} 50% {transform:translate(35px,-25px)} }
@keyframes mapBreath { 0%,100% { box-shadow:inset 0 0 0 1px rgba(255,255,255,.02),0 15px 40px rgba(0,0,0,.22) } 50% { box-shadow:inset 0 0 0 1px rgba(111,211,248,.05),0 18px 48px rgba(0,0,0,.27) } }
@keyframes rowSweep { 0%,70% { transform:translateX(0) skewX(-18deg); opacity:0 } 80% { opacity:1 } 100% { transform:translateX(390%) skewX(-18deg); opacity:0 } }
@keyframes arrowPulse { 0%,100% {transform:translateY(0);opacity:.45} 50% {transform:translateY(4px);opacity:1} }
@keyframes cardIn { from {opacity:0; transform:translateY(8px)} to {opacity:1; transform:none} }

@media (max-width:860px) {
  .hero { padding-top:58px; }
  #map { height:430px; }
}
@media (max-width:520px) {
  .brand-sub { display:none; }
  .brand-logo { width:42px; height:42px; }
  .hero { min-height:280px; padding-top:46px; }
  .hero-live-strip span { font-size:.55rem; }
  #map { height:350px; }
  .map-section { padding:12px; }
}

@media (prefers-reduced-motion: reduce) {
  .page-loader, .loader-ring, .ambient-grid::after, .ambient-glow, .hero-badges, .hero-title, .hero-description, .hero-live-strip,
  .phase-tag--live, .status-dot--large, #map, .earthquake-row::after, .process-arrow, .interactive-card { animation:none !important; }
  .reveal-on-scroll { opacity:1; transform:none; transition:none; }
}

/* =====================================================
   VERIFIED WEATHER DESK
   ===================================================== */
.weather-desk { margin-top: 28px; }
.weather-desk-grid { display:grid; grid-template-columns:1.35fr .65fr; gap:18px; }
.weather-news-list { display:grid; gap:0; }
.weather-news-item { display:grid; grid-template-columns:34px 1fr auto; gap:12px; align-items:center; padding:15px 16px; border-top:1px solid var(--color-panel-border); transition:background .25s ease, transform .25s ease; }
.weather-news-item:first-child { border-top:0; }
.weather-news-item:hover { background:rgba(62, 184, 214, .05); transform:translateX(4px); }
.weather-news-index { font:700 .72rem var(--font-mono); color:var(--color-accent); }
.weather-news-title { color:var(--color-text); font-weight:600; line-height:1.35; font-size:.88rem; }
.weather-news-meta { color:var(--color-text-muted); font:500 .61rem var(--font-mono); text-align:right; white-space:nowrap; }
.weather-news-source { color:#5e91ad; font-size:.65rem; margin-top:3px; }
.weather-desk-note { padding:16px; border:1px solid rgba(76,164,198,.18); border-radius:12px; background:linear-gradient(145deg, rgba(24,45,61,.8), rgba(8,18,28,.9)); }
.weather-desk-note strong { display:block; font:700 1rem var(--font-heading); color:#eef7fb; margin-bottom:8px; }
.weather-desk-note p { color:var(--color-text-muted); font-size:.78rem; line-height:1.65; margin:0 0 12px; }
.weather-desk-links { display:flex; flex-wrap:wrap; gap:8px; }
.weather-desk-links a { color:#8bd8ef; border:1px solid rgba(86,190,219,.25); border-radius:999px; padding:6px 9px; font:600 .62rem var(--font-mono); text-decoration:none; }
.weather-desk-links a:hover { border-color:#55cde8; background:rgba(85,205,232,.08); }

@media (max-width: 1080px) {
  .weather-desk-grid { grid-template-columns:1fr; }
}

/* City / map filtering for road reports */
.reports-toolbar .report-filters {
    display: flex;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 12px;
    flex: 1;
}

.reports-toolbar .report-filters label {
    min-width: 150px;
}

#report-city-filter {
    border-color: rgba(61, 190, 224, 0.55);
}

.filter-result-count {
    align-self: center;
    margin-left: 2px;
    padding: 8px 10px;
    border: 1px solid var(--color-panel-border);
    border-radius: 6px;
    color: var(--color-text-muted);
    font-family: var(--font-mono);
    font-size: 0.68rem;
    letter-spacing: 0.04em;
    white-space: nowrap;
}

.report-location-label {
    color: var(--color-text-muted);
}

@media (max-width: 900px) {
    .reports-toolbar .report-filters {
        width: 100%;
    }

    .filter-result-count {
        width: 100%;
    }
}
