/* ==========================================================================
   1. INSTELLINGEN & VARIABELEN (Base)
   ========================================================================== */

:root {
  --ink: #e9f4ff;
  --muted: #93aabe;
  --base: #071829;
  --base2: #0a2033;
  --card: rgba(16, 47, 70, .72);
  --edge: rgba(180, 226, 255, .14);
  --cyan: #51c4ff;
  --mint: #6ae8bd;
  --warm: #fb9c4a;
  --shadow: 0 18px 55px rgba(0, 0, 0, .25);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--ink);
  font: 15px/1.5 Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  background: radial-gradient(circle at 18% -5%, #17577a 0, transparent 34%), 
              linear-gradient(135deg, var(--base), var(--base2));
}

/* ==========================================================================
   2. SITE STRUCTUUR & LAYOUT
   ========================================================================== */


.site-header, 
main, 
footer {
  position: relative;
  max-width: 1320px;
  margin: auto;
}


.main-container-grid { 
  display: flex;
  flex-direction: column;
  gap: 15px;
}

main {
  padding: 48px 28px 30px;
}

/* ==========================================================================
   3. ACHTERGROND & ANIMATIES
   ========================================================================== */

.sky {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  opacity: .5;
  background: radial-gradient(ellipse at 85% 5%, rgba(98, 208, 255, .14), transparent 30%);
}

.sky span {
  position: absolute;
  width: 230px;
  height: 65px;
  border-radius: 50%;
  background: rgba(204, 239, 255, .035);
  filter: blur(14px);
  animation: float 25s linear infinite;
}

.sky span:nth-child(1) { top: 14%; left: -12%; }
.sky span:nth-child(2) { top: 27%; left: 32%; animation-delay: -8s; }
.sky span:nth-child(3) { top: 9%; left: 79%; animation-delay: -16s; }

@keyframes float {
  to { transform: translateX(115vw); }
}

/* ==========================================================================
   4. HEADER
   ========================================================================== */

.site-header {
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  border-bottom: 1px solid var(--edge);
}

.brand {
  display: flex;
  gap: 10px;
  align-items: center;
  color: inherit;
  text-decoration: none;
}

.brand svg {
  width: 36px;
  fill: none;
  stroke: var(--cyan);
  stroke-width: 3;
  stroke-linecap: round;
}

.brand strong, 
.brand small {
  display: block;
  line-height: 1.05;
}

.brand strong {
  font-size: 17px;
  letter-spacing: .08em;
}

.brand small {
  margin-top: 4px;
  font-size: 9px;
  letter-spacing: .18em;
  color: var(--muted);
}

.site-header nav {
  display: flex;
  gap: 8px;
}

.site-header nav a {
  padding: 8px 13px;
  border-radius: 9px;
  color: var(--muted);
  text-decoration: none;
  font-weight: 650;
}

.site-header nav a:hover, 
.site-header nav .active {
  color: var(--ink);
  background: rgba(137, 207, 245, .11);
}

.header-actions {
  display: flex;
  gap: 13px;
  align-items: center;
}

.icon-button {
  border: 0;
  background: transparent;
  color: var(--ink);
  font-size: 20px;
  cursor: pointer;
}

/* ==========================================================================
   ASTRONOMIE ANIMATIES
   ========================================================================== */

/* De zon zacht laten pulseren (straleneffect) */
.astro-block:has(.sun-icon) .sun-icon svg {
  animation: sunPulse 4s ease-in-out infinite;
}

@keyframes sunPulse {
  0%, 100% {
    filter: drop-shadow(0 0 6px rgba(255, 202, 40, 0.35));
    transform: scale(1);
  }
  50% {
    filter: drop-shadow(0 0 14px rgba(255, 202, 40, 0.65));
    transform: scale(1.03); /* Knippert niet, maar deint heel rustig mee */
  }
}

/* De maan zacht laten zweven */
.astro-block:has(.moon-icon) .moon-icon svg {
  animation: moonFloat 5s ease-in-out infinite;
}

@keyframes moonFloat {
  0%, 100% {
    transform: translateY(0px) rotate(0deg);
    filter: drop-shadow(0 0 6px rgba(81, 196, 255, 0.35));
  }
  50% {
    transform: translateY(-1.5px) rotate(-1deg); /* Zweeft minimaal omhoog en kantelt een fractie */
    filter: drop-shadow(0 0 12px rgba(81, 196, 255, 0.55));
  }
}

/* ==========================================================================
   5. HERO & TITELS (FORECAST EN ASTRONOMIE COMPACT)
   ========================================================================== */

/* Rij-indeling voor Icoon + Tekst */
.forecast-main-row {
  display: flex;
  align-items: center;
  gap: 25px;
  margin: 15px 0 25px 0;
  padding: 5px 0;
  width: 100%;
}

.weather-forecast-icon {
  flex-shrink: 0;
  display: inline-block;
  min-height: 100px;
}

/* Schaal en gloed van hoofdicoon */
.weather-forecast-icon svg {
  width: 100px;
  height: 100px;
  filter: drop-shadow(0 0 15px rgba(81, 196, 255, 0.25));
  transition: transform 0.3s ease;
}

.weather-forecast-icon svg:hover {
  transform: scale(1.05);
}

.forecast-text-block {
  flex: 1;
}

.forecast-text-block p {
  margin: 0;
  font-size: 15px;
  line-height: 1.6;
  color: var(--ink);
}

/* Horizontale uitlijning voor Zon & Maan sub-kaarten */
.astro-row {
  display: flex;
  gap: 15px;
  width: 100%;
}

.astro-block {
  flex: 1; /* Forceert exact 50% breedte per sub-blok */
  display: flex;
  align-items: center;
  gap: 17px;
  padding: 18px !important; /* Fix: overschrijf eventuele verborgen dwingende paddings */
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.15) !important;
  border: 1px solid var(--edge);
}

.astro-icon {
  flex: none;
  width: 44px;
  height: 44px;
}

.astro-icon svg {
  width: 100%;
  height: 100%;
}

.sun-icon svg { filter: drop-shadow(0 0 8px rgba(255, 202, 40, 0.35)); }
.moon-icon svg { filter: drop-shadow(0 0 8px rgba(81, 196, 255, 0.35)); }

.astro-data {
  display: flex;
  flex-direction: column;
}

.astro-data span {
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  line-height: 1.3;
}

.astro-data strong {
  font-size: 17px;
  color: var(--ink);
  margin-bottom: 4px;
  line-height: 1.2;
}

.astro-data strong:last-child {
  margin-bottom: 0;
}

.phase-text {
  font-size: 14px !important;
}

/* Animatielogica voor de Zon-stralen */
.weather-forecast-icon:has(.sun-icon-group) svg {
  filter: drop-shadow(0 0 20px rgba(255, 179, 0, 0.55)) !important;
}

.weather-forecast-icon .sun-icon-group {
  transform-origin: 12px 12px;
  animation: slowSunSpin 45s linear infinite;
}

@keyframes slowSunSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Animatielogica voor zwevende Wolk */
.weather-forecast-icon svg path,
.weather-forecast-icon .raincloud-moving-group {
  transform-origin: center;
  animation: floatCloudContinuous 10s linear infinite;
}

/* De animatie die de wolk heel rustig heen en weer laat drijven */
@keyframes floatCloudContinuous {
  0% {
    transform: translateX(-13px); /* Start onzichtbaar aan de linkerkant, buiten het icoon */
    opacity: 0;
  }
  10% {
    opacity: 1; /* Wordt snel zichtbaar zodra hij in beeld komt */
  }
  90% {
    opacity: 1; /* Blijft de hele reis over de zon goed zichtbaar */
  }
  100% {
    transform: translateX(10px); /* Schuift volledig voorbij de zon uit het beeld aan de rechterkant */
    opacity: 0; /* Verdwijnt stilletjes voordat de loop opnieuw start */
  }
}


/* Hero elementen behouden */
.hero {
  display: grid;
  grid-template-columns: 1.25fr .9fr;
  gap: 25px;
  align-items: stretch;
  margin-bottom: 25px;
}

.eyebrow {
  margin: 0 0 10px;
  font-size: 10px;
  letter-spacing: .17em;
  color: var(--cyan);
  font-weight: 800;
}

.hero h1, 
.page-title h1 {
  margin: 12px 0 18px;
  font-size: clamp(70px, 10vw, 126px);
  line-height: .85;
  letter-spacing: -.09em;
}

.hero h1 sup {
  margin-left: 8px;
  font-size: .34em;
  vertical-align: top;
  letter-spacing: -.04em;
  color: var(--cyan);
}

.condition {
  margin: 0 0 9px;
  font-size: 15px;
}

.update {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
}

/* Mobiele responsive afhandeling */
@media (max-width: 600px) {
  .forecast-main-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 15px;
  }
  .astro-row {
    flex-direction: column;
    gap: 12px;
  }
}

/* ==========================================================================
   6. KAARTEN (Cards)
   ========================================================================== */

.card {
  background: linear-gradient(135deg, rgba(28, 69, 96, .72), var(--card));
  border: 1px solid var(--edge);
  box-shadow: var(--shadow);
  border-radius: 22px;
  backdrop-filter: blur(12px);
}

/* ==========================================================================
   7. METRICS & STATISTIEKEN
   ========================================================================== */

.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 15px;
}

.metric {
  position: relative;
  overflow: hidden;
  padding: 20px;
  height: 155px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.metric-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  font-size: 12px;
  color: var(--muted);
}

.metric-icon {
  font-size: 20px;
  color: var(--cyan);
}

.metric strong {
  display: block;
  margin: 10px 0 2px;
  font-size: 36px;
  letter-spacing: -.05em;
  line-height: 1;
}

.metric small {
  font-size: 14px;
  letter-spacing: 0;
  color: var(--muted);
  margin-left: 2px;
}

.metric p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  z-index: 2;
  position: relative;
}

.metric p b {
  color: var(--ink);
}

/* ==========================================================================
   8. VISUELE COMPONENTEN (DAVIS STATION)
   ========================================================================== */

.wind-scene {
  position: relative;
  overflow: hidden;
  min-height: 220px;
  padding: 24px;
}

.wind-scene:after {
  content: "";
  position: absolute;
  right: -70px;
  top: -80px;
  width: 200px;
  height: 200px;
  background: var(--cyan);
  filter: blur(100px);
  opacity: .13;
}

.scene-copy {
  position: relative;
  z-index: 1;
}

.scene-copy strong {
  display: block;
  font-size: 32px;
  letter-spacing: -.05em;
}

.scene-copy small {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--muted);
}

.scene-copy > span {
  font-size: 13px;
  color: var(--muted);
}

.weather-station {
  position: absolute;
  right: 0;
  bottom: 0;
  width: 78%;
  height: 89%;
}

.weather-station svg .station-metal,
.weather-station svg .station-dark,
.weather-station svg .station-body,
.weather-station svg ellipse,
.weather-station svg circle {
  display: inline !important;
  visibility: visible !important;
  opacity: 1 !important;
}

#davis-shield path {
  display: inline !important;
  visibility: visible !important;
  opacity: 1 !important;
  fill: #dce8f5 !important;
  stroke: #1c3d5a !important;
  stroke-width: 1px !important;
}

#davis-cups {
  transform-origin: 244px 21px !important;
  will-change: transform;
  animation: davis3dRotation var(--cups-speed, 2s) linear infinite;
}

#davis-cups.paused {
  animation-play-state: paused !important;
}

#davis-cups line,
#davis-cups use {
  filter: drop-shadow(0px 3px 2px rgba(0, 0, 0, 0.4));
}

@keyframes davis3dRotation {
  0% { transform: rotateX(72deg) rotateZ(0deg); }
  100% { transform: rotateX(72deg) rotateZ(360deg); }
}

#davis-vane-new {
  transform-origin: 0px 0px !important;
  transform-style: preserve-3d;
  transition: transform 0.8s cubic-bezier(0.25, 1, 0.5, 1);
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.thermal {
  position: relative;
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, .1);
  border-radius: 6px;
  overflow: hidden;
  margin-top: 10px;
}

.thermal i {
  display: block;
  width: 0%;
  height: 100%;
  background: linear-gradient(90deg, #51c4ff, #6ae8bd, #fb9c4a);
  border-radius: inherit;
  transition: width .8s ease;
}

.droplets {
  position: absolute;
  right: 18px;
  bottom: 18px;
  display: flex;
  align-items: flex-end;
  gap: 4px;
  height: 28px;
  z-index: 1;
}

.droplets i {
  width: 6px;
  background: var(--cyan);
  opacity: .2;
  border-radius: 4px;
  transition: opacity 0.3s, height 0.3s;
}

.spark {
  position: absolute;
  right: 15px;
  bottom: 12px;
  width: 110px;
  height: 35px;
  z-index: 1;
  opacity: 0.6;
}

.spark svg {
  width: 100%;
  height: 100%;
}

.spark path {
  fill: none;
  stroke: var(--cyan);
  stroke-width: 2.5;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}

/* ==========================================================================
   9. STATUS KLASSEN & UTILITIES
   ========================================================================== */

.live {
  font-size: 11px;
  letter-spacing: .1em;
  font-weight: 800;
  color: var(--mint);
}

.live i, 
.ok {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: var(--mint);
  border-radius: 50%;
  box-shadow: 0 0 13px var(--mint);
  margin-right: 6px;
}

.error {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: #e74c3c;
  border-radius: 50%;
  box-shadow: 0 0 13px #e74c3c;
  margin-right: 6px;
}

.live i {
  animation: pulse 1.9s infinite;
}

@keyframes pulse {
  50% {
    opacity: .35;
    box-shadow: none;
  }
}

/* HERSTELD: Deze klasse dwingt het knipperlicht nu succesvol op rood */
.error-pulse {
  background: #e74c3c !important;
  box-shadow: 0 0 13px #e74c3c !important;
  animation: redPulse 1.9s infinite !important;
}

/* ==========================================================================
   9. STATUS KLASSEN, UTILITIES & ANIMATIES
   ========================================================================== */

.live {
  font-size: 11px;
  letter-spacing: .1em;
  font-weight: 800;
  color: var(--mint);
}

/* Standaard actieve statusindicatoren (Groen) */
.live i, 
.ok {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: var(--mint);
  border-radius: 50%;
  box-shadow: 0 0 13px var(--mint);
  margin-right: 6px;
}

/* Algemene storingsindicator (Rood) */
.error {
  display: inline-block;
  width: 7px;
  height: 7px;
  background: #e74c3c;
  border-radius: 50%;
  box-shadow: 0 0 13px #e74c3c;
  margin-right: 6px;
}

/* Groene pulseer-animatie voor live status */
.live i {
  animation: pulse 1.9s infinite;
}

@keyframes pulse {
  50% {
    opacity: .35;
    box-shadow: none;
  }
}

/* Rode pulseer-animatie voor de LIVE top-indicator bij storing */
.error-pulse {
  background: #e74c3c !important;
  box-shadow: 0 0 13px #e74c3c !important;
  animation: redPulse 1.9s infinite !important;
}

@keyframes redPulse {
  0% { opacity: 1; box-shadow: 0 0 13px #e74c3c; }
  50% { opacity: .35; box-shadow: none; }
  100% { opacity: 1; box-shadow: 0 0 13px #e74c3c; }
}

/* ==========================================================================
   10. METERS & WIND-COMPONENTEN (GEARRANGEERD)
   ========================================================================== */

/* Neerslag-diagram rechtsonder in de kaart */
.rain-bars {
  position: absolute;
  right: 18px;
  bottom: 18px;
  display: flex;
  gap: 4px;
  align-items: flex-end;
  height: 30px;
  z-index: 1;
}

.rain-bars i {
  width: 5px;
  background: var(--cyan);
  border-radius: 3px;
  opacity: .3;
  transition: height 0.4s ease, opacity 0.4s ease;
}

.rain-bars i.active {
  opacity: .9;
  box-shadow: 0 0 6px var(--cyan);
}

.rain-bars i:nth-child(1) { height: 8px; }
.rain-bars i:nth-child(2) { height: 14px; }
.rain-bars i:nth-child(3) { height: 21px; }
.rain-bars i:nth-child(4) { height: 11px; }
.rain-bars i:nth-child(5) { height: 17px; }

.wind-card {
  padding: 25px;
}

.wind-content {
  display: flex;
  gap: 20px;
  align-items: center;
  justify-content: space-around;
  margin-top: 18px;
  flex-wrap: wrap;
}

/* De ronde kompas- en windmeters */
.compass {
  position: relative;
  flex: none;
  width: 155px;
  height: 155px;
  border: 1px solid rgba(180, 226, 255, .24);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(81, 196, 255, .1), transparent 55%);
}

.compass span.north, 
.compass span.east, 
.compass span.south, 
.compass span.west {
  position: absolute;
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
}

.north { top: 8px; left: 50%; transform: translateX(-50%); }
.east  { top: 50%; right: 9px; transform: translateY(-50%); }
.south { bottom: 8px; left: 50%; transform: translateX(-50%); }
.west  { top: 50%; left: 9px; transform: translateY(-50%); }

#bearing-value {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}

/* Getallen rondom de schaalmeters */
.gauge-num {
  position: absolute;
  font-size: 11px;
  font-weight: 800;
  color: var(--muted);
  z-index: 1;
  pointer-events: none;
}

.g-min { bottom: 16px; left: 22px; }  
.g-low { top: 22px; left: 22px; }     
.g-mid { top: 22px; right: 22px; }    
.g-max { bottom: 16px; right: 22px; } 

.gauge-center-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  z-index: 2;
  pointer-events: none;
  width: 100%;
}

.gauge-center-text strong {
  display: block;
  font-size: 20px;
  line-height: 1;
  color: var(--ink);
}

.gauge-center-text small {
  display: block;
  margin-top: 4px;
  font-size: 10px;
  font-weight: 600;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Wijzers en naalden van de meters */
#compass-needle,
#speed-gauge-needle,
#gust-gauge-needle {
  position: absolute;
  top: 20px;
  left: calc(50% - 2px);
  width: 4px;
  height: 57.5px;
  transform-origin: 50% 100% !important;
  transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
  z-index: 0;
}

#compass-needle {
  background: linear-gradient(var(--warm) 0 48%, var(--cyan) 48%);
  clip-path: polygon(50% 0, 100% 22%, 70% 100%, 30% 100%, 0 22%);
}

#speed-gauge-needle {
  background: var(--cyan);
  clip-path: polygon(50% 0, 100% 22%, 70% 100%, 30% 100%, 0 22%);
}

#gust-gauge-needle {
  background: var(--warm);
  clip-path: polygon(50% 0, 100% 22%, 70% 100%, 30% 100%, 0 22%);
}

/* ==========================================================================
   11. LOWER GRID & RECORD CARDS
   ========================================================================== */

.lower-grid {
  display: grid;
  grid-template-columns: 1.25fr .8fr;
  gap: 18px;
}

.status-card {
  padding: 25px;
}

.status-card ul {
  margin: 21px 0 0;
  padding: 0;
  list-style: none;
}

.status-card li {
  display: grid;
  grid-template-columns: 16px 1fr auto;
  padding: 12px 0;
  border-top: 1px solid var(--edge);
  font-size: 12px;
  color: var(--muted);
}

.status-card li b {
  color: var(--ink);
  font-weight: 600;
}

.highlights {
  grid-column: 1 / -1;
  padding: 25px;
}

.highlights .section-heading a {
  font-size: 12px;
  color: var(--cyan);
  text-decoration: none;
}

.mini-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-top: 23px;
}

.mini-stats div {
  padding: 14px;
  border-radius: 13px;
  background: rgba(0, 0, 0, .13);
}

.mini-stats span {
  display: block;
  font-size: 11px;
  color: var(--muted);
}

.mini-stats b {
  display: block;
  margin-top: 4px;
  font-size: 20px;
}

/* ==========================================================================
   12. RECORD SECTIE
   ========================================================================== */

.page-title {
  margin: 12px 0 40px;
}

.page-title h1 {
  margin-bottom: 14px;
  font-size: clamp(42px, 6vw, 76px);
}

.page-title > p:last-child {
  margin: 0;
  color: var(--muted);
}

.record-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 22px;
}

.record {
  padding: 22px;
}

.record span {
  font-size: 12px;
  color: var(--muted);
}

.record strong {
  display: block;
  margin: 17px 0 3px;
  font-size: 30px;
  letter-spacing: -.06em;
}

.record p {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
}

.warm strong { color: #ffb66e; }
.cold strong { color: #79d6ff; }
.wind strong { color: var(--mint); }
.wet strong  { color: #a6dfff; }

/* ==========================================================================
   13. TABELLEN, HEADINGS & FOOTER
   ========================================================================== */

.section-heading h2 {
  margin: 0;
  font-size: 19px;
  letter-spacing: -.03em;
  color: var(--ink);
}

.badge {
  padding: 5px 8px;
  border: 1px solid rgba(106, 232, 189, .35);
  border-radius: 7px;
  font-size: 11px;
  color: var(--mint);
}

footer {
  padding: 25px 28px 35px;
  font-size: 11px;
  color: var(--muted);
}

footer span {
  margin: 0 7px;
  color: var(--cyan);
}

/* ==========================================================================
   14. THEMA-MODIFIERS
   ========================================================================== */

body.light {
  --ink: #0d2a3c;
  --muted: #587287;
  --base: #e6f5fb;
  --base2: #c8e6f4;
  --card: rgba(250, 254, 255, .75);
  --edge: rgba(13, 71, 101, .14);
  --shadow: 0 16px 45px rgba(17, 75, 101, .13);
}

/* ==========================================================================
   15. MEDIA QUERIES (Responsiviteit)
   ========================================================================== */

@media (max-width: 1024px) {
  .hero { grid-template-columns: 1fr; }
  .metrics { grid-template-columns: repeat(2, 1fr); } 
  .lower-grid { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  .site-header { height: auto; padding: 16px 18px; gap: 15px; flex-wrap: wrap; }
  .site-header nav { order: 3; width: 100%; justify-content: space-between; }
  main { padding: 35px 18px 25px; }
  .hero h1 { font-size: 82px; }
  .metrics { grid-template-columns: 1fr; gap: 12px; } 
  .compass { width: 130px; height: 130px; }
}
/* Fix: Dwing het maan-icoon volledig naar links en voorkom afsnijden */
.astro-block .moon-icon {
  width: 44px !important;
  height: 44px !important;
  display: flex !important;
  align-items: center;
  justify-content: flex-start; /* Uitlijnen aan de linkerkant van de eigen container */
  margin-left: 0;
  margin-right: 8px; /* Ruimte tussen het icoon en de tekst 'MAANFASE' */
}

/* Zorg dat de SVG zelf niet buiten zijn boekje boekje treedt */
.astro-block .moon-icon svg {
  width: 100% !important;
  height: 100% !important;
  overflow: visible; /* Voorkomt dat de gloed (drop-shadow) wordt afgekapt */
}

/* Zorg dat de regendruppels een eigen animatie krijgen voor het vallen */
.weather-forecast-icon svg .rain-drop {
  transform-origin: center;
  animation: fallRainContinuous 0.8s linear infinite;
}

/* Staggered delay zodat niet alle druppels tegelijk vallen */
.weather-forecast-icon svg .rain-drop:nth-child(2) {
  animation-delay: 0.2s;
}
.weather-forecast-icon svg .rain-drop:nth-child(3) {
  animation-delay: 0.4s;
}

/* De animatie die de druppels snel naar beneden laat vallen en laat refaden */
@keyframes fallRainContinuous {
  0% {
    transform: translateY(-2px);
    opacity: 0;
  }
  20% {
    opacity: 1; /* Snel zichtbaar worden zodra ze onder de wolk vandaan komen */
  }
  80% {
    opacity: 1;
  }
  100% {
    transform: translateY(6px); /* Valt vloeiend naar beneden */
    opacity: 0; /* Verdwijnt netjes aan de onderkant */
  }
}
/* ==========================================================================
   WIND SCENES & VERGELIJKING GRID LAYOUT
   ========================================================================== */

/* De container die de twee kaarten dwingt om naast elkaar te staan */
.station-comparison-grid {
  display: flex !important;
  flex-direction: row !important; /* Altijd naast elkaar als basis op desktop */
  justify-content: space-between !important;
  align-items: stretch !important;
  gap: 20px !important;
  width: 100% !important;
  margin-top: 15px;
}

/* Stijlen voor elke individuele wind-kaart (Vue en VP2) */
.wind-scene {
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center !important;
  min-width: 0 !important;
  padding: 24px !important;
  position: relative !important;
  overflow: visible !important;
}

/* Fix: Herstel de positie van de SVG's zodat ze NIET meer over de tekst zweven */
.wind-scene svg,
.wind-scene .weather-station {
  position: relative !important; /* Haalt de SVG uit de absolute zweefstand */
  right: auto !important;
  bottom: auto !important;
  width: 145px !important; /* Dwing een vaste breedte af */
  height: 130px !important; /* Dwing een vaste hoogte af */
  max-width: 100% !important;
  margin: 15px auto 0 !important;
  display: block !important;
}

/* Zorg dat de tekstblokken in de scene netjes centreren */
.wind-scene .scene-copy {
  position: relative !important;
  width: 100% !important;
  margin-bottom: 5px !important;
}

/* Netjes onder elkaar klappen op mobiel en extra ruimte geven */
@media (max-width: 620px) {
  .station-comparison-grid {
    flex-direction: column !important;
    gap: 30px !important; /* Meer ruimte tussen de Vue en VP2 kaart */
  }

  .wind-scene {
    padding: 20px !important;
  }
  
  /* Mobiele fix: Dwing pixel-maten af zodat de SVG niet onzichtbaar wordt naar 0px */
  .wind-scene svg,
  .wind-scene .weather-station {
    width: 160px !important; 
    height: 140px !important;
    margin: 20px auto 10px !important;
  }
}

/* Kolom opbouw */
.station-column {
  overflow: hidden;
  padding: 0 !important; 
}

.station-header {
  padding: 20px 25px;
  border-bottom: 1px solid var(--edge);
}

.station-header.vp2 { background: linear-gradient(90deg, rgba(81, 196, 255, 0.1), transparent); }
.station-header.vue { background: linear-gradient(90deg, rgba(251, 156, 74, 0.1), transparent); }

.station-header h2 {
  margin: 0;
  font-size: 20px;
  color: var(--ink);
}

.station-header h2 span {
  display: block;
  font-size: 12px;
  color: var(--muted);
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 4px;
}

/* Data rijen binnen de kolommen */
.station-metrics {
  padding: 10px 25px 25px;
}

.compare-row {
  display: grid;
  grid-template-columns: 1fr 120px 110px;
  align-items: center;
  padding: 14px 0;
  border-bottom: 1px solid var(--edge);
}

.compare-row:last-child {
  border-bottom: 0;
}

.metric-label {
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
}

.metric-value strong {
  font-size: 24px;
  letter-spacing: -0.03em;
  color: var(--ink);
}

.metric-value small {
  font-size: 13px;
  color: var(--muted);
  margin-left: 3px;
}

.metric-bounds {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  font-size: 12px;
  color: var(--muted);
}

.metric-bounds .max { color: var(--warm); }
.metric-bounds .min { color: var(--cyan); }

/* Onderste balk */
.communal-metrics {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 15px;
  font-size: 14px;
  color: var(--muted);
}
.communal-metrics strong { color: var(--ink); }

@media (max-width: 500px) {
  /* Zorg dat de rijen flexibel worden in plaats van een knellende grid */
  .compare-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px 0;
    align-items: stretch;
  }

  /* Het label krijgt de ruimte bovenin de rij */
  .metric-label {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    color: var(--cyan); /* Geeft een mooie subtiele scheiding tussen de datablokken */
  }

  /* We maken een container die de live-waarde en uitersten netjes verdeelt */
  .station-metrics .compare-row {
    display: flex;
    flex-direction: column;
  }

  /* Truc om waarde en uitersten horizontaal op één lijn te krijgen onder het label */
  .compare-row::after {
    content: "";
    display: table;
    clear: both;
  }

  /* Zorg dat de hoofdwaarde links uitlijnt en niet meer afkapt */
  .metric-value {
    float: left;
    display: inline-block;
    width: auto;
  }

  .metric-value strong {
    font-size: 22px; /* Iets compacter voor mobiel */
  }

  /* Forceer de min/max uitersten en subteksten naar de rechterkant op dezelfde hoogte */
  .metric-bounds {
    float: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    text-align: right;
    font-size: 12px;
    margin-top: 4px; /* Brengt de kleine cijfers op gelijke hoogte met de grote letters */
  }
}

/* Bovenste Dashboard Grid */
.top-dashboard-grid {
  display: grid;
  grid-template-columns: 1.25fr 0.75fr;
  gap: 15px;
  margin-bottom: 15px;
  align-items: start;
}

.top-card {
  padding: 22px 25px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Astronomie Dashboard Koppeling */
.astro-dash-content {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
  height: 100%;
  align-items: center;
}

.astro-dash-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.astro-label {
  font-size: 11px;
  color: var(--cyan);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.astro-dash-item strong {
  font-size: 16px;
  color: var(--ink);
}

.moon-illum-sub {
  font-size: 12px;
  color: var(--muted);
  margin-top: 4px;
}

@media (max-width: 1024px) {
  .top-dashboard-row {
    grid-template-columns: 1fr;
  }
  .station-comparison-grid {
    flex-direction: column !important;
    gap: 25px;
  }
}
/* ==========================================================================
   EXTRA ACCENTEN VOOR DE WINDBEKERS (CUPJES)
   ========================================================================== */

/* Geef de cupjes van beide stations een fellere kleur en een mooie diepte-gloed */
#davis-cups path,
#davis-cups-vp2 path,
.wind-scene svg [fill="var(--cyan)"],
.wind-scene svg circle[fill*="cyan"] {
  fill: #00b0ff !important; /* Krachtiger, helder elektrisch blauw */
  stroke: #ffffff !important; /* Een ragdun wit randje zodat ze scherp afsteken */
  stroke-width: 0.4px !important;
  filter: drop-shadow(0px 2px 5px rgba(0, 176, 255, 0.65)) !important; /* Neon-achtige blauwe gloed */
  transition: fill 0.3s ease;
}

/* Optioneel: Als je wilt dat de cupjes nóg intenser oplichten wanneer het hard waait */
.wind-scene:hover #davis-cups path,
.wind-scene:hover #davis-cups-vp2 path {
  fill: #6ae8bd !important; /* Verandert naar muntgroen als je eroverheen hovert */
  filter: drop-shadow(0px 2px 8px rgba(106, 232, 189, 0.8)) !important;
}

/* ==========================================================================
   NIEUWE LAY-OUT: LIVE WIND OVER VOLLEDIGE BREEDTE
   ========================================================================== */

/* 1. Dwing de hoofdkaart over de hele breedte van de grid */
.full-width-wind-card {
  width: 100% !important;
  grid-column: 1 / -1 !important; /* Mocht je in een grid zitten, vult hij alle kolommen */
  padding: 30px 25px !important;
}

.card-header-center {
  text-align: center;
  margin-bottom: 25px;
}

/* 2. De container die de twee stations scheidt met een subtiele lijn in het midden */
.stations-split-container {
  display: flex !important;
  flex-direction: row !important;
  justify-content: space-around !important;
  align-items: stretch !important;
  gap: 40px !important;
  width: 100% !important;
}

/* Elke station-helft krijgt exact evenveel ruimte */
.station-side {
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center !important;
  padding: 10px 20px !important;
}

/* Subtiele verticale scheidingslijn tussen de twee stations op desktop */
.vue-side {
  border-right: 1px solid var(--edge);
}

.station-side h3 {
  margin: 0 0 15px 0 !important;
  font-size: 18px !important;
  letter-spacing: -0.02em;
  color: var(--ink);
}

/* 3. De gegevens (Snelheid & Richting) strak naast elkaar geplaatst */
.station-data-row {
  display: flex !important;
  gap: 35px !important;
  margin-bottom: 20px !important;
  justify-content: center !important;
  align-items: baseline !important;
}

.data-block {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
}

.data-block strong {
  font-size: 28px !important; /* Lekker duidelijk leesbaar */
  letter-spacing: -0.04em !important;
  line-height: 1 !important;
  color: var(--ink);
}

.data-block small {
  font-size: 11px !important;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 5px;
}

/* Zorg dat de stations-SVG's mooi gecentreerd onder de data staan */
.station-visual svg,
.station-visual .weather-station {
  position: relative !important;
  right: auto !important;
  bottom: auto !important;
  width: 160px !important;
  height: 140px !important;
  margin: 10px auto 0 !important;
  display: block !important;
}

/* Responsieve weergave voor mobiel: onder elkaar klappen */
@media (max-width: 768px) {
  .stations-split-container {
    flex-direction: column !important;
    gap: 35px !important;
  }
  
  .vue-side {
    border-right: 0 !important;
    border-bottom: 1px solid var(--edge); /* Lijn verhuist naar de onderkant op mobiel */
    padding-bottom: 30px !important;
  }
}
/* Geef het temperatuurcijfer in de vergelijker een warmere tint */
.temp-block strong {
  color: var(--warm, #fb9c4a) !important;
}

/* Zorg dat op mobiel drie blokken nog steeds netjes naast elkaar passen */
@media (max-width: 480px) {
  .station-data-row {
    gap: 15px !important; /* Maakt de tussenruimte iets compacter op smalle telefoons */
  }
  .data-block strong {
    font-size: 22px !important; /* Cijfers fractie kleiner op mini-schermen */
  }
}
/* ==========================================================================
   VOLLEDIGE BREEDTE DASHBOARD KAART
   ========================================================================== */

/* 1. Dwing de .hero container om over te stappen van kolommen naar één brede rij */
.hero {
  display: flex !important;
  flex-direction: column !important; /* Zet alle elementen binnen .hero recht onder elkaar */
  width: 100% !important;
  gap: 20px !important;
}

/* 2. Zorg dat de LIVE SENSORS kaart gegarandeerd 100% breedte pakt */
.full-width-wind-card {
  width: 100% !important;
  max-width: 100% !important;
  flex: 1 1 100% !important;
  display: block !important;
}

/* 3. Zorg dat de stations-container daarbinnen alle ruimte optimaal benut */
.stations-split-container {
  display: flex !important;
  flex-direction: row !important;
  justify-content: space-around !important;
  width: 100% !important;
  gap: 40px !important;
}
/* ==========================================================================
   RESPONSIVE FIX VOOR MOBIEL (ONDER ELKAAR KLAPPEN)
   ========================================================================== */

@media (max-width: 768px) {
  /* 1. Klap de twee stations onder elkaar in plaats van naast elkaar */
  .stations-split-container {
    flex-direction: column !important;
    gap: 30px !important;
    width: 100% !important;
  }

  /* 2. Zorg dat elke station-helft de volledige breedte van het telefoonscherm benut */
  .station-side {
    width: 100% !important;
    max-width: 100% !important;
    padding: 10px 0 !important;
  }

  /* 3. Haal de verticale scheidingslijn weg en maak er een horizontale lijn van */
  .vue-side {
    border-right: 0 !important;
    border-bottom: 1px solid var(--edge) !important;
    padding-bottom: 25px !important; /* Extra ademruimte boven de lijn */
  }

  /* 4. Zorg dat de data-rij met de drie blokken netjes binnen het scherm past */
  .station-data-row {
    gap: 15px !important; /* Iets compacter op mobiel */
    width: 100% !important;
  }

  .data-block strong {
    font-size: 22px !important; /* Cijfers fractie kleiner op mobiel tegen afkappen */
  }
}
/* ==========================================================================
   NIEUWE COMPACTE VERGELIJKINGSLIJST (DUO-GRID)
   ========================================================================== */

/* Grid dat de categorie-blokken netjes verdeelt (2x2 op desktop) */
.comparison-blocks-grid {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr) !important;
  gap: 25px !important;
  width: 100% !important;
}

/* Elk los categorie-blok */
.comparison-category-block {
  background: rgba(0, 0, 0, 0.13) !important;
  border: 1px solid var(--edge);
  border-radius: 16px;
  padding: 100px !important;
}

.category-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--cyan);
  border-bottom: 1px solid var(--edge);
  padding-bottom: 10px;
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Een datarij binnen een blok: verdeeld in Label, Vue-kolom, VP2-kolom */
.compare-row-v2 {
  display: grid !important;
  grid-template-columns: 1.2fr 1fr 1fr !important;
  align-items: center !important;
  padding: 12px 0 !important;
  border-bottom: 1px solid rgba(180, 226, 255, 0.05);
}

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

.row-label {
  font-size: 14px;
  color: var(--muted);
  font-weight: 500;
}

/* De waardeboxen per station */
.station-val-box {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center;
}

.station-val-box strong {
  font-size: 20px !important;
  color: var(--ink);
  line-height: 1;
}

.station-val-box small {
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
}

/* Subtiele kleurindicatie per station voor de getallen */
.vue-color strong { color: #ffb66e !important; }  /* Warm oranje accent voor de Vue */
.vp2-color strong { color: #79d6ff !important; }  /* Helder blauw accent voor de VP2 */

/* De min/max weergave onder de hoofdwaarde */
.station-val-box .bounds {
  display: flex !important;
  gap: 8px !important;
  font-size: 11px;
  margin-top: 4px;
}

.station-val-box .sub-info {
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
}

.station-val-box .max, .bounds .max { color: var(--warm, #fb9c4a); }
.station-val-box .min, .bounds .min { color: var(--cyan, #51c4ff); }

/* Responsieve weergave: op tablets en smartphones klappen de blokken en rijen netjes onder elkaar */
@media (max-width: 900px) {
  .comparison-blocks-grid {
    grid-template-columns: 1fr !important; /* Blokken onder elkaar */
    gap: 20px !important;
  }
}

@media (max-width: 550px) {
  .compare-row-v2 {
    grid-template-columns: 1fr !important; /* Rij breekt open op mobiel */
    gap: 10px !important;
    padding: 15px 0 !important;
    text-align: center;
  }
  
  .row-label {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--cyan);
    margin-bottom: 4px;
  }
  
  .station-val-box {
    flex-direction: row !important; /* Zet waarde en min/max naast elkaar op mobiel */
    justify-content: transform-origin;
    gap: 15px;
    background: rgba(0, 0, 0, 0.08);
    padding: 6px 12px;
    border-radius: 8px;
    width: 100% !important;
  }
  
  .station-val-box .bounds, .station-val-box .sub-info {
    margin-top: 0;
    margin-left: auto; /* Dringt de uitersten naar rechts */
  }
}
/* ==========================================================================
   STATION VERGELIJKING MET VISUELE HEADERS & SCHEIDINGSLIJN
   ========================================================================== */

.full-width-comparison-card {
  background: transparent !important;  /* Haalt de lichte achtergrond weg */
  border: none !important;             /* Haalt de buitenste rand weg */
  box-shadow: none !important;         /* Haalt eventuele schaduw weg */
  padding: 0 !important;               /* Zorgt dat de blokken mooi aansluiten */
}

/* 1. De visuele header waarin de twee stations strak naast elkaar staan */
.stations-visual-header {
  display: flex !important;
  flex-direction: row !important;
  justify-content: space-around !important;
  align-items: center !important;
  width: 100% !important;
  margin-bottom: 35px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--edge); /* Horizontale lijn onder het visuele deel */
}

.header-station-box {
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center !important;
  padding: 10px 20px !important;
}

/* FIX: De duidelijke verticale scheidingslijn tussen de twee weerstations */
.vue-header {
  border-right: 2px solid var(--edge) !important; /* Duidelijke streep aan de rechterkant van de Vue */
}

.header-station-box h3 {
  margin: 0 0 10px 0 !important;
  font-size: 18px !important;
  color: var(--ink);
  font-weight: 700;
}

/* De SVG-weerstations bovenin de tabel */
.station-visual-top svg,
.station-visual-top .weather-station {
  position: relative !important;
  right: auto !important;
  bottom: auto !important;
  width: 200px !important;
  height: 170px !important;
  margin: 5px auto 0 !important;
  display: block !important;
}

/* 2. Grid dat de categorie-blokken netjes verdeelt (2x2 op desktop) */
.comparison-blocks-grid {
  display: grid !important;
  grid-template-columns: repeat(2, 1fr !important;
  gap: 25px !important;
  width: 100% !important;
}

.category-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--cyan);
  border-bottom: 1px solid var(--edge);
  padding-bottom: 10px;
  margin-bottom: 15px;
}

/* Datarij binnen een blok: verdeeld in Label, Vue-kolom, VP2-kolom */
.compare-row-v2 {
  display: grid !important;
  grid-template-columns: 1.2fr 1fr 1fr !important;
  align-items: center !important;
  padding: 12px 0 !important;
  border-bottom: 1px solid rgba(180, 226, 255, 0.05);
}

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

.row-label {
  font-size: 14px;
  color: var(--muted);
}

.station-val-box {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
}

.vue-color strong { color: #ffb66e !important; }  
.vp2-color strong { color: #79d6ff !important; }  

.station-val-box .bounds, .station-val-box .sub-info {
  font-size: 11px;
  color: var(--muted);
  margin-top: 4px;
}

.bounds .max { color: var(--warm); margin-right: 5px; }
.bounds .min { color: var(--cyan); }

/* Responsieve weergave voor mobiel */
@media (max-width: 850px) {
  .stations-visual-header {
    flex-direction: column !important;
    gap: 25px;
  }
  .vue-header {
    border-right: 0 !important;
    border-bottom: 2px solid var(--edge) !important; /* Streep verhuist naar onderkant op mobiel */
    padding-bottom: 25px !important;
  }
  .comparison-blocks-grid {
    grid-template-columns: 1fr !important;
  }
}
/* ==========================================================================
   MOBIEL OPTIMALISATIE: RUIME BADGE-INDELING VOOR DE TABEL
   ========================================================================== */

@media (max-width: 550px) {
  /* 1. Breek de drie krappe kolommen open naar een verticale stapeling */
  .compare-row-v2 {
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    padding: 16px 0 !important;
    border-bottom: 1px solid rgba(180, 226, 255, 0.08) !important;
  }

  /* 2. Geef het label een prominente plek bovenaan de rij */
  .row-label {
    font-size: 13px !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--cyan);
    text-align: left !important;
    margin-bottom: 2px;
  }

  /* 3. Zet de waardeboxen van de Vue en VP2 als twee brede balken naast elkaar */
  .compare-row-v2 {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
  }

  /* Container om de twee stationsblokken op mobiel strak naast elkaar te zetten */
  .compare-row-v2 .station-val-box {
    display: flex !important;
    flex-direction: row !important; /* Zet waarde en min/max op één lijn */
    justify-content: space-between !important; /* Live waarde links, uitersten rechts */
    align-items: center !important;
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(180, 226, 255, 0.06);
    padding: 10px 14px !important;
    border-radius: 10px;
    margin-top: 4px;
    width: 100% !important;
    text-align: left;
  }

  /* Voeg een subtiel labeltje toe voor herkenbaarheid per balk */
  .compare-row-v2 .vue-color::before {
    content: "Vue: ";
    font-size: 11px;
    color: var(--muted);
    font-weight: 600;
    margin-right: 5px;
  }

  .compare-row-v2 .vp2-color::before {
    content: "VP2: ";
    font-size: 11px;
    color: var(--muted);
    font-weight: 600;
    margin-right: 5px;
  }

  /* Zorg dat de hoofdwaarde netjes aansluit */
  .station-val-box strong {
    font-size: 18px !important;
  }

  /* De uitersten (min/max) of sub-info worden netjes naar rechts gedrukt */
  .station-val-box .bounds, 
  .station-val-box .sub-info {
    margin-top: 0 !important;
    margin-left: auto !important; /* Schuift alles naar de rechterkant van de balk */
    font-size: 12px !important;
    display: flex !important;
    align-items: center;
  }

  /* Ruimte tussen de min en max pijlen op mobiel */
  .bounds .max {
    margin-right: 10px !important;
  }
}
