*{box-sizing:border-box}:root{--bg:#f2f5f8;--card:#fff;--text:#132238;--muted:#708196;--line:#e3e9ef;--ok:#2c8b57;--bad:#c94949}
body{margin:0;background:var(--bg);color:var(--text);font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
main{max-width:1280px;margin:auto;padding:32px 22px 60px}.topbar{display:flex;justify-content:space-between;align-items:flex-end;gap:22px;margin-bottom:20px}
.eyebrow,.panelhead span,.chart-title span{font-size:12px;letter-spacing:.14em;font-weight:800;color:#678}h1{font-size:40px;margin:4px 0 3px;letter-spacing:-.035em}
#status,#updated,.meta-row{font-size:14px;color:var(--muted)}.station-state{display:flex;align-items:center;gap:11px;background:#fff;border:1px solid var(--line);border-radius:16px;padding:13px 16px;min-width:260px}
.state-dot{width:12px;height:12px;border-radius:999px;background:#aab5c0;box-shadow:0 0 0 5px #aab5c022}.state-dot.ok{background:var(--ok);box-shadow:0 0 0 5px #2c8b5720}.state-dot.bad{background:var(--bad);box-shadow:0 0 0 5px #c9494920}
.warning{padding:14px 16px;background:#fff1d6;color:#7a4a00;border-radius:12px;margin-bottom:18px;font-weight:650}.grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px}
.card,.panel{background:var(--card);border:1px solid var(--line);border-radius:18px;box-shadow:0 8px 30px rgba(30,50,70,.05)}.card{padding:19px;min-height:135px;display:flex;flex-direction:column;justify-content:space-between}
.card span{color:var(--muted);font-size:14px;font-weight:650}.card strong{font-size:30px;letter-spacing:-.03em}.card small{color:var(--muted)}.hero{grid-column:span 2}.hero strong{font-size:50px}
.panel{margin-top:16px;padding:20px}.panelhead{display:flex;justify-content:space-between;align-items:flex-end;gap:16px}.panelhead h2{margin:3px 0 0;font-size:24px}
.period-switch{display:flex;gap:8px;flex-wrap:wrap}.period{border:1px solid var(--line);background:#f7f9fb;color:#42556a;border-radius:999px;padding:9px 14px;font-weight:700;cursor:pointer}.period.active{background:#132238;color:#fff;border-color:#132238}
.meta-row{display:flex;justify-content:space-between;gap:15px;margin-top:12px}.charts-grid{display:grid;grid-template-columns:1fr 1fr;gap:16px}.chart-panel{margin-top:0}.chart-panel.wide{grid-column:1/-1}
.chart-title{display:flex;flex-direction:column;gap:3px}.chart-title strong{font-size:18px}canvas{display:block;width:100%;height:290px;margin-top:12px}
@media(max-width:900px){.grid{grid-template-columns:repeat(2,1fr)}.hero{grid-column:span 2}.charts-grid{grid-template-columns:1fr}.chart-panel.wide{grid-column:auto}}
@media(max-width:560px){main{padding:20px 12px 45px}.topbar{flex-direction:column;align-items:stretch}.station-state{min-width:0}h1{font-size:32px}.grid{grid-template-columns:1fr}.hero{grid-column:auto}.card{min-height:118px}.hero strong{font-size:42px}.panelhead{flex-direction:column;align-items:flex-start}.meta-row{flex-direction:column}.period-switch{width:100%}.period{flex:1}}
.main-tabs{display:flex;gap:8px;flex-wrap:wrap;margin:0 0 18px}
.main-tab{border:1px solid var(--line,#e3e9ef);background:#fff;color:#42556a;border-radius:999px;padding:10px 16px;font-weight:750;cursor:pointer}
.main-tab.active{background:#132238;color:#fff;border-color:#132238}
.view{display:none}.view.active{display:block}
.stats-controls{display:flex;gap:8px;flex-wrap:wrap}
.stats-controls select,.stats-controls input{border:1px solid var(--line,#e3e9ef);background:#fff;border-radius:10px;padding:9px 11px;color:#24364a;font:inherit}
.stats-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:14px;margin-top:16px}
.stat-card{background:#fff;border:1px solid var(--line,#e3e9ef);border-radius:18px;padding:18px;box-shadow:0 8px 30px rgba(30,50,70,.05)}
.stat-card span{display:block;color:#708196;font-size:13px;font-weight:700;margin-bottom:8px}
.stat-card strong{font-size:28px;letter-spacing:-.03em}
.stat-card small{display:block;margin-top:6px;color:#708196}
.muted{color:#708196;font-size:14px}
@media(max-width:900px){.stats-grid{grid-template-columns:repeat(2,1fr)}}
@media(max-width:560px){.stats-grid{grid-template-columns:1fr}.stats-controls{width:100%}.stats-controls>*{flex:1;min-width:120px}}

.stat-card small{line-height:1.45}
.date-list{display:flex;flex-wrap:wrap;gap:6px;margin-top:7px}
.date-chip{display:inline-block;padding:4px 8px;border-radius:999px;background:#f1f5f8;color:#526579;font-size:12px;font-weight:650}
.month-table{width:100%;border-collapse:collapse;margin-top:12px}
.month-table th,.month-table td{padding:10px 8px;text-align:right;border-bottom:1px solid #e7edf2}
.month-table th:first-child,.month-table td:first-child{text-align:left}
.month-table th{font-size:12px;color:#708196;letter-spacing:.04em}
.month-table td{font-size:14px}
@media(max-width:700px){.month-table{font-size:12px}.month-table th,.month-table td{padding:8px 5px}}

.table-wrap{overflow-x:auto}
.status-badge{display:inline-block;border-radius:999px;padding:4px 8px;font-size:12px;font-weight:700}
.status-badge.complete{background:#e8f6ee;color:#23724a}
.status-badge.partial{background:#fff2d8;color:#8a5b00}
.delta-pos{color:#b44a2d}.delta-neg{color:#26734c}.delta-neutral{color:#708196}

.section-block{margin-top:22px}
.section-heading{margin-bottom:12px}
.section-heading span{font-size:12px;letter-spacing:.14em;font-weight:800;color:#678}
.section-heading h2{margin:3px 0 0;font-size:23px}
.current-two-col{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:22px}
.current-two-col .panel{margin-top:0}
.astro-grid{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin-top:14px}
.astro-item{padding:14px;border-radius:14px;background:#f7f9fb;border:1px solid #e7edf2}
.astro-item span{display:block;color:#708196;font-size:12px;font-weight:700;margin-bottom:5px}
.astro-item strong{font-size:20px}
#windrose{display:block;width:100%;height:360px;margin-top:8px}
@media(max-width:900px){.current-two-col{grid-template-columns:1fr}}
@media(max-width:560px){.astro-grid{grid-template-columns:1fr}}

.wind-card{grid-column:span 2;display:grid;grid-template-columns:minmax(210px,.8fr) 1.2fr;align-items:center;gap:16px}
.wind-live{display:flex;flex-direction:column;justify-content:space-between;min-height:120px}
.windrose-wrap{min-width:0}
.windrose-wrap #windrose{height:250px;margin:0}
.chart-legend{display:flex;flex-wrap:wrap;gap:10px;margin-top:8px}
.legend-item{display:inline-flex;align-items:center;gap:6px;color:#65778a;font-size:12px;font-weight:700}
.legend-line{width:20px;height:3px;border-radius:3px;background:#888}
.axis-label{fill:#6d7e90;font-size:11px}
.info-help{display:block;margin-top:6px;color:#708196;font-size:12px;line-height:1.4}
@media(max-width:900px){.wind-card{grid-column:span 2;grid-template-columns:1fr}}
@media(max-width:560px){.wind-card{grid-column:auto}.windrose-wrap #windrose{height:230px}}

.info-label{display:inline-flex;align-items:center;gap:6px}
.info-tip{position:relative;display:inline-grid;place-items:center;width:17px;height:17px;border-radius:50%;background:#e9eff4;color:#4c6478;font-size:11px;font-weight:800;cursor:help}
.info-tip::after{content:attr(data-tip);position:absolute;left:50%;bottom:calc(100% + 9px);transform:translateX(-50%);width:min(280px,70vw);padding:9px 10px;border-radius:10px;background:#172536;color:#fff;font-size:12px;line-height:1.45;font-weight:500;opacity:0;pointer-events:none;transition:.15s;z-index:40;box-shadow:0 8px 24px #0003}
.info-tip:hover::after,.info-tip:focus::after{opacity:1}
.moon-extra{margin-top:18px;padding-top:16px;border-top:1px solid #e5ebef}
.moon-extra h3{margin:0 0 10px;font-size:17px}
.moon-sign{display:flex;align-items:center;gap:10px;margin-bottom:12px}
.moon-sign strong{font-size:22px}.moon-sign span{color:#6f7f8d}
.moon-advice{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}
.advice-card{background:#f7f9fb;border:1px solid #e6ecef;border-radius:14px;padding:13px}
.advice-card span{display:block;font-size:12px;color:#708196;font-weight:800;margin-bottom:5px}
.advice-card strong{font-size:14px;line-height:1.4}
.trad-note{margin-top:10px;color:#7a8792;font-size:11px;line-height:1.4}
@media(max-width:700px){.moon-advice{grid-template-columns:1fr}}

.range-windrose{margin-top:16px;padding-top:14px;border-top:1px solid #e8edf1}
#chart-windrose{height:260px;margin-top:8px}

.wind-history-grid{display:grid;grid-template-columns:minmax(0,1.45fr) minmax(250px,.75fr);gap:18px;align-items:center}
.wind-history-chart{min-width:0}
.range-windrose{margin:0;padding:0 0 0 18px;border:0;border-left:1px solid #e8edf1;min-width:0}
#chart-windrose{display:block;width:100%;height:290px;margin-top:6px}
.sunshine-subchart{margin-top:18px;padding-top:16px;border-top:1px solid #e8edf1}
#chart-sunshine{height:240px}
.chart-note{display:block;color:#748392;font-size:11px;line-height:1.45;margin-top:6px}
@media(max-width:900px){
 .wind-history-grid{grid-template-columns:1fr}
 .range-windrose{border-left:0;border-top:1px solid #e8edf1;padding-left:0;padding-top:14px}
}

#chart-windrose{display:block;width:100%;height:290px;margin-top:12px}
#chart-sunshine{display:block;width:100%;height:290px;margin-top:12px}

#chart-windrose{height:340px}
#chart-sunshine-bars{display:block;width:100%;height:220px;margin-top:8px}

/* v9.7: Tagesbalken liegen transparent im Sonnenscheindauer-Diagramm. */

#year-climate-chart{display:block;width:100%;height:360px;margin-top:14px}
.pressure-extra{display:block;margin-top:7px;color:#708196;font-size:12px;line-height:1.45}

.pressure-extra{display:block;margin-top:7px;color:#708196;font-size:12px;line-height:1.5}
.pressure-extra .date-list{display:inline-flex;margin:0 0 0 4px;vertical-align:middle}
.month-table th,.month-table td{white-space:nowrap}

.table-help{position:relative;cursor:help;border-bottom:1px dotted #9aa8b4}
.table-help::after{content:attr(data-tip);position:absolute;left:50%;bottom:calc(100% + 8px);transform:translateX(-50%);width:220px;padding:8px 10px;border-radius:9px;background:#172536;color:#fff;font-size:12px;line-height:1.4;font-weight:500;white-space:normal;opacity:0;pointer-events:none;transition:.15s;z-index:50;box-shadow:0 8px 24px #0003}
.table-help:hover::after{opacity:1}

/* v10.4: Tabellen-Hinweise dürfen nicht von der scrollbaren Tabelle abgeschnitten werden. */
#monthly-overview,
#monthly-overview.panel{overflow:visible!important}
#monthly-overview .table-wrap{overflow-x:auto;overflow-y:visible;padding-top:82px;margin-top:-82px}
#monthly-overview table{position:relative}
#monthly-overview thead,
#monthly-overview th{overflow:visible!important}
#monthly-overview .table-help{position:relative;z-index:100;display:inline-block}
#monthly-overview .table-help::after{
  position:fixed;
  left:auto;
  bottom:auto;
  transform:none;
  width:240px;
  z-index:99999;
}

/* v10.5: Zeitraum-/Datumswahl beim Scrollen sichtbar halten */
#view-charts > .panel:first-child,
#view-stats > .panel:first-child{
  position:sticky;
  top:10px;
  z-index:120;
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
  background:rgba(255,255,255,.94);
  box-shadow:0 8px 26px rgba(22,38,54,.10);
}

#view-charts > .panel:first-child::after,
#view-stats > .panel:first-child::after{
  content:"";
  position:absolute;
  inset:auto 0 -10px 0;
  height:10px;
  pointer-events:none;
}

@media(max-width:700px){
  #view-charts > .panel:first-child,
  #view-stats > .panel:first-child{
    top:6px;
  }
}

/* v10.6: normaler Kartenabstand unter der sticky Verlaufsauswahl */
#view-charts > .panel:first-child{margin-bottom:18px}

/* v10.7 */
#view-climate > .panel:first-child{
  position:sticky;
  top:10px;
  z-index:120;
  backdrop-filter:blur(10px);
  -webkit-backdrop-filter:blur(10px);
  background:rgba(255,255,255,.94);
  box-shadow:0 8px 26px rgba(22,38,54,.10);
  margin-bottom:18px;
}
#view-climate .table-wrap,
#view-climate .tablewrap{overflow-x:auto;overflow-y:visible}
#view-climate th{overflow:visible!important}
#view-climate .table-help{position:relative;z-index:100;display:inline-block}
@media(max-width:700px){#view-climate > .panel:first-child{top:6px}}

.record-subsection{margin-top:18px}

/* v10.9: Klima-Tooltip nicht innerhalb der scrollbaren Tabelle rendern */
.global-table-tooltip{
  position:fixed;
  z-index:100000;
  width:240px;
  padding:8px 10px;
  border-radius:9px;
  background:#172536;
  color:#fff;
  font-size:12px;
  line-height:1.4;
  box-shadow:0 8px 24px #0003;
  pointer-events:none;
  opacity:0;
  transition:opacity .12s;
}
.global-table-tooltip.show{opacity:1}
#view-climate .table-help::after,
#monthly-overview .table-help::after{display:none!important}

/* v11.1 Smartphone: Aktuell kompakter, sticky Zeitraum-/Datumsleisten schlanker */
@media(max-width:700px){

  /* Aktuell: weniger Leerraum, höhere Informationsdichte */
  #view-current{gap:10px}
  #view-current .panel{
    padding:12px;
    border-radius:14px;
  }
  #view-current .current-grid,
  #view-current .stats-grid,
  #view-current .mini-grid{
    gap:8px;
  }
  #view-current .metric,
  #view-current .stat-card{
    padding:10px;
    min-height:0;
  }
  #view-current .metric-label,
  #view-current .stat-label,
  #view-current .eyebrow{
    font-size:10px;
    line-height:1.2;
  }
  #view-current .metric-value,
  #view-current .stat-value{
    line-height:1.05;
  }
  #view-current .chart-title{margin-bottom:8px}
  #view-current .chart-title span{font-size:9px}
  #view-current .chart-title strong{font-size:14px}

  /* Kleine Werte bevorzugt zweispaltig */
  #view-current .stats-grid,
  #view-current .mini-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }

  /* Sticky Auswahlleisten in Verlauf / Statistik / Klima */
  #view-charts > .panel:first-child,
  #view-stats > .panel:first-child,
  #view-climate > .panel:first-child{
    top:4px;
    padding:7px 9px;
    border-radius:12px;
    margin-bottom:10px;
    box-shadow:0 5px 16px rgba(22,38,54,.09);
  }

  #view-charts > .panel:first-child .chart-title,
  #view-stats > .panel:first-child .chart-title,
  #view-climate > .panel:first-child .chart-title{
    margin-bottom:5px;
  }

  #view-charts > .panel:first-child .chart-title span,
  #view-stats > .panel:first-child .chart-title span,
  #view-climate > .panel:first-child .chart-title span{
    font-size:8px;
  }

  #view-charts > .panel:first-child .chart-title strong,
  #view-stats > .panel:first-child .chart-title strong,
  #view-climate > .panel:first-child .chart-title strong{
    font-size:12px;
  }

  #view-charts > .panel:first-child button,
  #view-stats > .panel:first-child button,
  #view-climate > .panel:first-child button,
  #view-charts > .panel:first-child select,
  #view-stats > .panel:first-child select,
  #view-climate > .panel:first-child select,
  #view-charts > .panel:first-child input,
  #view-stats > .panel:first-child input,
  #view-climate > .panel:first-child input{
    min-height:32px;
    height:32px;
    padding:4px 8px;
    font-size:12px;
  }

  #view-charts > .panel:first-child .segmented,
  #view-stats > .panel:first-child .segmented,
  #view-climate > .panel:first-child .segmented,
  #view-charts > .panel:first-child .controls,
  #view-stats > .panel:first-child .controls,
  #view-climate > .panel:first-child .controls{
    gap:5px;
  }
}

.has-title-tip{cursor:help;border-bottom:1px dotted #9aa8b4}

/* v11.3: alle neuen Hinweise verwenden denselben Tooltip wie Statistik */
.has-title-tip{border-bottom:0;cursor:inherit}
#view-current .table-help,
#view-climate .table-help,
#view-records .table-help{
  position:relative;
  cursor:help;
  border-bottom:1px dotted #9aa8b4;
}
#view-current .table-help::after,
#view-records .table-help::after{display:none!important}

#view-current .table-help{
  position:relative;
  cursor:help;
  border-bottom:1px dotted #9aa8b4;
}
.record-help{
  margin-top:7px;
  color:#708196;
  font-size:12px;
  line-height:1.4;
}

/* v11.5: Tooltip in Aktuell nur direkt über dem Beschriftungstext aktiv */
#view-current .table-help{
  display:inline-block;
  width:auto;
  max-width:max-content;
  align-self:flex-start;
}

/* v11.6: Tooltip-Hitbox nur Textbreite, ohne das Kartenlayout zu verändern */
#view-current .table-help{
  display:initial;
  width:auto;
  max-width:none;
  align-self:auto;
}
#view-current .table-help::before{
  content:"";
  position:absolute;
  inset:0;
  pointer-events:none;
}

/* v11.7: Kartenlabel bleibt Block, nur der Text selbst ist Tooltip-Ziel */
#view-current .card > span,
#view-current .stat-card > span{
  display:block;
}
#view-current .tip-text{
  display:inline;
  width:auto;
  cursor:help;
  border-bottom:1px dotted #9aa8b4;
}

/* v11.8 – Smartphone Feinschliff Aktuell: Temperatur/Luft, Wind, Niederschlag */
@media(max-width:700px){

  /* Allgemein kompakter, Werte aber weiterhin gut lesbar */
  #view-current{
    gap:9px;
  }
  #view-current .panel{
    padding:11px;
    margin-bottom:0;
  }
  #view-current .card,
  #view-current .stat-card{
    padding:9px 10px;
  }

  /* Temperatur / Luft: kleine Zusatzwerte dichter anordnen */
  #view-current .stats-grid,
  #view-current .mini-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:7px;
  }
  #view-current .stat-value,
  #view-current .metric-value{
    font-size:clamp(18px,5.2vw,24px);
  }
  #view-current .stat-label,
  #view-current .metric-label{
    font-size:10px;
  }

  /* Windbereich: Winddaten + Rose kompakter */
  #view-current .wind-layout,
  #view-current .wind-grid{
    gap:8px;
    align-items:center;
  }
  #view-current .windrose-wrap,
  #view-current .wind-rose-wrap{
    min-height:0;
  }
  #view-current #windrose,
  #view-current #wind-rose,
  #view-current canvas[id*="windrose"],
  #view-current canvas[id*="wind-rose"]{
    max-height:190px;
  }

  /* Niederschlag: vier Summen bevorzugt als 2x2 */
  #view-current .rain-grid,
  #view-current .precip-grid{
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:7px;
  }
  #view-current .rain-grid > *,
  #view-current .precip-grid > *{
    min-width:0;
  }

  /* Zusatzzeilen wie letzter Niederschlag kompakter */
  #view-current .subline,
  #view-current .meta,
  #view-current .small{
    line-height:1.3;
  }
}

@media(max-width:390px){
  #view-current .panel{padding:9px}
  #view-current .card,
  #view-current .stat-card{padding:8px}
  #view-current .stats-grid,
  #view-current .mini-grid,
  #view-current .rain-grid,
  #view-current .precip-grid{gap:6px}
}


/* =========================================================
   v12.1 – Dashboard-Redesign nach Referenzbild
   ========================================================= */

body{
  background:linear-gradient(180deg,#eef3f6 0,#f7f9fa 260px,#f7f9fa 100%);
}

/* Hero */
.hero-weather{
  position:relative;
  min-height:300px;
  border-radius:18px;
  overflow:hidden;
  margin-bottom:18px;
  background:
    linear-gradient(90deg,rgba(9,29,46,.78),rgba(9,29,46,.28) 58%,rgba(9,29,46,.62)),
    linear-gradient(180deg,#48769b,#244b67);
  box-shadow:0 12px 32px rgba(17,38,56,.18);
  color:white;
}
.hero-weather::before{
  content:"";
  position:absolute;
  inset:0;
  background:
    radial-gradient(circle at 22% 72%,rgba(117,170,109,.28),transparent 28%),
    radial-gradient(circle at 72% 65%,rgba(93,137,93,.20),transparent 30%);
  opacity:.9;
}
.hero-overlay{
  position:absolute;inset:0;
  background:linear-gradient(180deg,rgba(6,25,40,.05),rgba(6,25,40,.18));
}
.hero-copy{
  position:relative;
  z-index:2;
  padding:34px 34px 28px;
  max-width:58%;
}
.hero-place{font-size:15px;font-weight:700;opacity:.92}
.hero-temp{
  font-size:clamp(62px,8vw,108px);
  line-height:.96;
  font-weight:700;
  letter-spacing:-.055em;
  margin:18px 0 12px;
}
.hero-sub{font-size:23px;font-weight:600}
.hero-updated{
  display:inline-block;
  margin-top:20px;
  padding:8px 12px;
  border-radius:10px;
  background:rgba(5,20,34,.46);
  backdrop-filter:blur(8px);
  font-size:12px;
}
.hero-side{
  position:absolute;
  z-index:2;
  right:24px;
  top:26px;
  bottom:26px;
  width:min(280px,34%);
  display:flex;
  flex-direction:column;
  justify-content:center;
  gap:18px;
}
.hero-side>div{
  display:grid;
  grid-template-columns:34px 1fr;
  grid-template-areas:"icon label" "icon value";
  gap:1px 10px;
  align-items:center;
  padding:10px 12px;
  border-radius:12px;
  background:rgba(4,22,36,.28);
  backdrop-filter:blur(8px);
}
.hero-side span{grid-area:label;font-size:11px;opacity:.78}
.hero-side strong{grid-area:value;font-size:20px}
.hero-ico{grid-area:icon;width:28px;height:28px}

/* Karten mit Icon-Kopf */
.metric-head{
  display:flex!important;
  align-items:center;
  gap:8px;
}
.metric-icon{
  width:22px;
  height:22px;
  flex:0 0 auto;
}
#view-current .card,
#view-current .stat-card{
  background:linear-gradient(180deg,#fff,#fbfcfd);
  border:1px solid #e4eaee;
  box-shadow:0 7px 20px rgba(23,44,60,.055);
}
#view-current .card strong,
#view-current .stat-card strong{
  letter-spacing:-.025em;
}

/* visuelle Akzente */
#view-current .metric-head:has(use[href="#ico-temp"]){color:#c73f34}
#view-current .metric-head:has(use[href="#ico-drop"]){color:#2f76c4}
#view-current .metric-head:has(use[href="#ico-pressure"]){color:#4a9b48}
#view-current .metric-head:has(use[href="#ico-wind"]){color:#835ac6}
#view-current .metric-head:has(use[href="#ico-rain"]){color:#2f76c4}
#view-current .metric-head:has(use[href="#ico-sun"]){color:#e59b12}

/* Diagrammkarten */
.chart-panel{
  border:1px solid #e2e9ed;
  background:#fff;
}
.chart-title strong{
  font-size:18px;
  color:#1d3246;
}
.chart-title span{
  color:#5d7386;
}

/* Navigation stärker wie Referenz */
.main-tabs,.tabs{
  background:#0e2a40;
  border-radius:12px;
  padding:4px;
}
.main-tabs button,.tabs button{
  color:#dce7ef;
}
.main-tabs button.active,.tabs button.active{
  background:#fff;
  color:#0e2a40;
  box-shadow:0 2px 8px rgba(0,0,0,.12);
}

/* Footer/untere Bereiche */
footer{
  border-top:1px solid #dfe6ea;
}

/* Smartphone */
@media(max-width:700px){
  .hero-weather{
    min-height:230px;
    border-radius:14px;
  }
  .hero-copy{
    max-width:100%;
    padding:22px 18px 18px;
  }
  .hero-temp{font-size:58px;margin:12px 0 8px}
  .hero-sub{font-size:17px}
  .hero-side{
    position:relative;
    right:auto;top:auto;bottom:auto;
    width:auto;
    padding:0 14px 14px;
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:7px;
  }
  .hero-side>div{
    display:flex;
    flex-direction:column;
    align-items:flex-start;
    gap:3px;
    padding:9px;
  }
  .hero-side strong{font-size:15px}
  .hero-side span{font-size:9px}
  .hero-ico{width:20px;height:20px}
}


/* v12.2 – Hero-Messwerte wie Referenzbild */
.hero-side{
  right:28px;
  top:22px;
  bottom:22px;
  width:min(255px,31%);
  gap:8px;
}
.hero-side .hero-metric{
  display:grid;
  grid-template-columns:38px 1fr;
  gap:10px;
  align-items:start;
  padding:8px 10px;
  background:transparent;
  backdrop-filter:none;
  border-radius:0;
}
.hero-metric-copy{
  display:flex;
  flex-direction:column;
  line-height:1.08;
}
.hero-metric-copy strong{
  font-size:20px;
  line-height:1;
  margin-bottom:2px;
}
.hero-metric-copy b{
  font-size:25px;
  line-height:1.05;
  margin-top:3px;
  font-weight:750;
}
.hero-metric-copy span{
  font-size:11px;
  opacity:.86;
  margin-top:2px;
}
.hero-metric-copy small{
  font-size:10px;
  opacity:.76;
  margin-top:3px;
}
.hero-ico{
  width:31px;
  height:31px;
  margin-top:2px;
}
.hero-temp{
  font-size:clamp(72px,9vw,118px);
  font-weight:700;
}
.hero-sub{
  font-size:24px;
}
@media(max-width:700px){
  .hero-side{
    width:auto;
    right:auto;
    top:auto;
    bottom:auto;
    grid-template-columns:repeat(3,minmax(0,1fr));
    padding:0 12px 12px;
  }
  .hero-side .hero-metric{
    grid-template-columns:24px 1fr;
    gap:6px;
    padding:8px;
    background:rgba(4,22,36,.22);
    border-radius:10px;
  }
  .hero-metric-copy strong{font-size:14px}
  .hero-metric-copy b{font-size:15px}
  .hero-metric-copy span{font-size:9px}
  .hero-metric-copy small{font-size:8px}
  .hero-ico{width:21px;height:21px}
}


/* v12.3 – Messwertkacheln in Aktuell wie im Referenzbild */
#view-current .stats-grid{
  gap:10px;
}
#view-current .stat-card,
#view-current .card{
  position:relative;
  overflow:hidden;
}

/* obere Hauptmesswert-Kacheln */
#view-current .stats-grid .stat-card{
  min-height:142px;
  padding:16px 17px 13px;
  background:#fff;
  border:1px solid #e1e7eb;
  border-radius:11px;
  box-shadow:0 3px 12px rgba(22,42,58,.07);
}
#view-current .stats-grid .stat-card > span:first-child,
#view-current .stats-grid .stat-card .stat-label{
  font-size:11px;
  font-weight:800;
  letter-spacing:.035em;
  text-transform:uppercase;
  color:#34495c;
}
#view-current .stats-grid .stat-card .stat-value,
#view-current .stats-grid .stat-card > strong{
  font-size:27px;
  line-height:1.05;
  font-weight:750;
  color:#101b28;
  margin-top:7px;
}
#view-current .stats-grid .stat-card small,
#view-current .stats-grid .stat-card .small,
#view-current .stats-grid .stat-card .meta{
  font-size:10px;
  color:#52616e;
}

/* farbige große Icons links */
#view-current .stats-grid .metric-head{
  gap:10px;
}
#view-current .stats-grid .metric-icon{
  width:34px;
  height:34px;
  margin-right:3px;
}

/* Trennlinie für Min/Max bzw. Zusatzinfos */
#view-current .stats-grid .stat-card::after{
  content:"";
  position:absolute;
  left:14px;
  right:14px;
  bottom:39px;
  height:1px;
  background:#e8edf0;
  pointer-events:none;
}

/* Min/Max-Zeilen klarer */
#view-current .stats-grid .stat-card .subline,
#view-current .stats-grid .stat-card .meta:last-child{
  margin-top:auto;
  padding-top:12px;
}

/* Kacheln sollen wie eine saubere Messwertleiste wirken */
#view-current .stats-grid{
  grid-template-columns:repeat(5,minmax(0,1fr));
}
@media(max-width:1050px){
  #view-current .stats-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(max-width:700px){
  #view-current .stats-grid{
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:7px;
  }
  #view-current .stats-grid .stat-card{
    min-height:118px;
    padding:12px;
  }
  #view-current .stats-grid .stat-card .stat-value,
  #view-current .stats-grid .stat-card > strong{
    font-size:22px;
  }
  #view-current .stats-grid .metric-icon{
    width:27px;height:27px;
  }
  #view-current .stats-grid .stat-card::after{
    left:10px;right:10px;bottom:34px;
  }
}


/* v12.4 – Windbereich wie Referenzbild */
.wind-overview-card{
  padding:18px 20px;
}
.wind-overview-layout{
  display:grid;
  grid-template-columns:minmax(0,1.5fr) minmax(190px,.65fr);
  gap:18px;
  align-items:stretch;
  margin-top:12px;
}
.windrose-large-wrap{
  min-width:0;
  padding-right:18px;
  border-right:1px solid #e7ecef;
}
.windrose-large-wrap #windrose{
  display:block;
  width:100%;
  height:330px;
  margin:0;
}
.windrose-legend{
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:6px 14px;
  margin-top:6px;
  font-size:11px;
  color:#566b7d;
}
.windrose-legend span{
  display:flex;
  align-items:center;
  gap:6px;
}
.wr-dot{
  display:inline-block;
  width:10px;
  height:10px;
  border-radius:2px;
}
.wr-b1{background:#3f82c5}
.wr-b2{background:#67a94f}
.wr-b3{background:#3f9f5d}
.wr-b4{background:#e49a22}

.wind-summary{
  display:flex;
  flex-direction:column;
  justify-content:center;
}
.wind-summary-item{
  padding:15px 4px 15px;
  border-bottom:1px solid #e7ecef;
}
.wind-summary-item:last-child{
  border-bottom:0;
}
.wind-summary-item span{
  display:block;
  font-size:12px;
  font-weight:750;
  color:#607486;
  margin-bottom:3px;
}
.wind-summary-item strong{
  display:block;
  font-size:28px;
  line-height:1.05;
  letter-spacing:-.025em;
  color:#122235;
}
.wind-summary-item small{
  display:block;
  margin-top:4px;
  font-size:13px;
  color:#506276;
}

@media(max-width:700px){
  .wind-overview-layout{
    grid-template-columns:1fr;
  }
  .windrose-large-wrap{
    padding-right:0;
    border-right:0;
    border-bottom:1px solid #e7ecef;
    padding-bottom:12px;
  }
  .windrose-large-wrap #windrose{
    height:270px;
  }
  .wind-summary{
    display:grid;
    grid-template-columns:repeat(3,minmax(0,1fr));
    gap:0;
  }
  .wind-summary-item{
    border-bottom:0;
    border-right:1px solid #e7ecef;
    padding:10px;
  }
  .wind-summary-item:last-child{
    border-right:0;
  }
  .wind-summary-item strong{
    font-size:19px;
  }
  .wind-summary-item small{
    font-size:10px;
  }
}


/* v12.5 – neue gestapelte Windrose */
.windrose-large-wrap #windrose{
  height:350px;
}
.windrose-legend{
  justify-items:start;
}


/* v12.6 – alte Windkacheln weg, Niederschlag wie Referenz */
#view-current .legacy-wind-card{display:none!important}

.rain-reference-card{padding:18px 20px}
.rain-reference-layout{
  display:grid;
  grid-template-columns:minmax(190px,.8fr) minmax(0,1.6fr);
  gap:18px;
  align-items:center;
  margin-top:14px;
}
.rain-main{
  display:flex;
  align-items:center;
  gap:15px;
  padding-right:20px;
  border-right:1px solid #e6ecef;
}
.rain-big-icon{width:52px;height:52px;color:#347fc3;flex:0 0 auto}
.rain-main span,.rain-reference-stats span{
  display:block;font-size:11px;font-weight:750;color:#637789
}
.rain-main strong{
  display:block;font-size:34px;line-height:1.05;margin-top:3px;color:#15283b
}
.rain-reference-stats{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
}
.rain-reference-stats>div{
  padding:7px 16px;
  border-right:1px solid #e6ecef;
}
.rain-reference-stats>div:last-child{border-right:0}
.rain-reference-stats strong{
  display:block;font-size:22px;margin-top:4px;color:#172b3d
}
.rain-bars{
  height:54px;
  display:flex;
  align-items:flex-end;
  gap:5px;
  margin-top:17px;
  padding-top:10px;
  border-top:1px solid #edf1f3;
}
.rain-bar{
  flex:1;
  min-width:4px;
  max-width:20px;
  border-radius:3px 3px 0 0;
  background:#4d91c8;
  opacity:.82;
}
.rain-bar.zero{height:2px!important;opacity:.18}

@media(max-width:700px){
 .rain-reference-layout{grid-template-columns:1fr;gap:10px}
 .rain-main{border-right:0;border-bottom:1px solid #e6ecef;padding:4px 0 12px}
 .rain-reference-stats>div{padding:7px 9px}
 .rain-reference-stats strong{font-size:17px}
 .rain-main strong{font-size:28px}
}

/* v12.8 - nur Aktuell: Niederschlag wie Referenz */
#view-current .rain-reference-24h{padding:18px 20px}
#view-current .rain24-layout{display:grid;grid-template-columns:230px minmax(0,1fr);gap:22px;align-items:stretch;margin-top:12px}
#view-current .rain24-summary{display:grid;grid-template-columns:48px 1fr;gap:4px 13px;align-content:center;padding-right:20px;border-right:1px solid #e6ecef}
#view-current .rain24-summary .rain-big-icon{grid-row:1/3;width:45px;height:45px;color:#347fc3}
#view-current .rain24-primary span,#view-current .rain24-last span{display:block;font-size:11px;font-weight:750;color:#627789}
#view-current .rain24-primary strong{display:block;font-size:31px;line-height:1.05;color:#14283b;margin-top:3px}
#view-current .rain24-last{grid-column:2;margin-top:14px}
#view-current .rain24-last strong{display:block;font-size:18px;color:#172b3d;margin-top:3px}
#view-current .rain24-chart-wrap{position:relative;min-width:0;padding-left:32px;padding-bottom:22px}
#view-current .rain24-chart{height:145px;display:flex;align-items:flex-end;gap:2px;border-bottom:1px solid #cfd9df;background:linear-gradient(to bottom,transparent 32%,#edf2f5 33%,transparent 34%),linear-gradient(to bottom,transparent 65%,#edf2f5 66%,transparent 67%)}
#view-current .rain24-chart .rain-bar{flex:1;min-width:2px;background:#438cc4;opacity:.88;border-radius:2px 2px 0 0}
#view-current .rain24-chart .rain-bar.zero{height:1px!important;opacity:.12}
#view-current .rain24-scale{position:absolute;left:0;top:0;bottom:22px;display:flex;flex-direction:column;justify-content:space-between;font-size:9px;color:#738391}
#view-current .rain24-axis{position:absolute;left:32px;right:0;bottom:0;display:flex;justify-content:space-between;font-size:9px;color:#738391}
@media(max-width:700px){
 #view-current .rain24-layout{grid-template-columns:1fr;gap:12px}
 #view-current .rain24-summary{grid-template-columns:42px 1fr 1fr;border-right:0;border-bottom:1px solid #e6ecef;padding:0 0 12px}
 #view-current .rain24-summary .rain-big-icon{grid-row:auto}
 #view-current .rain24-last{grid-column:auto;margin-top:0}
 #view-current .rain24-chart{height:115px}
}

/* v12.9 – Niederschlag exakt nach Referenzbild, nur Aktuell */
#view-current .rain-reference-exact{
  padding:18px 20px 17px;
  background:#fff;
  border:1px solid #dfe6eb;
  border-radius:10px;
  box-shadow:0 3px 12px rgba(22,42,58,.06);
}

#view-current .rain-exact-layout{
  display:grid;
  grid-template-columns:245px minmax(0,1fr);
  gap:22px;
  align-items:center;
}

#view-current .rain-exact-values{
  display:grid;
  grid-template-columns:1fr 1fr;
  gap:15px;
  align-items:center;
}

#view-current .rain-exact-block{
  display:grid;
  grid-template-columns:42px 1fr;
  gap:10px;
  align-items:center;
}

#view-current .rain-exact-icon{
  width:39px;
  height:39px;
  color:#347fc3;
}

#view-current .rain-exact-block span{
  display:block;
  font-size:11px;
  line-height:1.15;
  color:#445d70;
  font-weight:700;
}

#view-current .rain-exact-block strong{
  display:block;
  margin-top:4px;
  font-size:24px;
  line-height:1;
  color:#10283b;
  font-weight:750;
  letter-spacing:-.025em;
}

#view-current .rain-exact-chart-area{
  min-width:0;
}

#view-current .rain-exact-title{
  margin-bottom:5px;
  font-size:11px;
  font-weight:700;
  color:#445d70;
}

#view-current .rain-exact-chart-shell{
  display:grid;
  grid-template-columns:29px minmax(0,1fr);
  gap:4px;
  align-items:stretch;
}

#view-current .rain-exact-ylabels{
  position:relative;
  height:82px;
  font-size:9px;
  color:#6d7d89;
}

#view-current .rain-exact-ylabels span{
  position:absolute;
  right:2px;
}
#view-current .rain-exact-ylabels span:nth-child(1){top:-4px}
#view-current .rain-exact-ylabels span:nth-child(2){top:36px}
#view-current .rain-exact-ylabels span:nth-child(3){bottom:-3px}

#view-current .rain-exact-plot{
  position:relative;
  height:103px;
}

#view-current .rain-exact-bars{
  position:absolute;
  left:0;
  right:0;
  top:0;
  height:82px;
  display:grid;
  grid-template-columns:repeat(24,minmax(2px,1fr));
  align-items:end;
  gap:2px;
  border-bottom:1px solid #cfd7dd;
}

#view-current .rain-exact-bar{
  display:block;
  width:100%;
  min-height:1px;
  background:#3f8ac4;
  border-radius:1px 1px 0 0;
}

#view-current .rain-exact-bar.zero{
  opacity:.10;
  height:1px!important;
}

#view-current .rain-exact-gridline{
  position:absolute;
  left:0;
  right:0;
  border-top:1px solid #e7ecef;
  pointer-events:none;
}
#view-current .rain-exact-gridline-top{top:0}
#view-current .rain-exact-gridline-mid{top:41px}

#view-current .rain-exact-xaxis{
  position:absolute;
  left:0;
  right:0;
  bottom:0;
  display:grid;
  grid-template-columns:repeat(6,1fr);
  font-size:9px;
  color:#6d7d89;
}
#view-current .rain-exact-xaxis span{
  text-align:left;
}
#view-current .rain-exact-xaxis span:last-child{
  text-align:right;
}

@media(max-width:700px){
  #view-current .rain-reference-exact{
    padding:13px;
  }
  #view-current .rain-exact-layout{
    grid-template-columns:1fr;
    gap:14px;
  }
  #view-current .rain-exact-values{
    gap:8px;
  }
  #view-current .rain-exact-block{
    grid-template-columns:34px 1fr;
    gap:7px;
  }
  #view-current .rain-exact-icon{
    width:31px;
    height:31px;
  }
  #view-current .rain-exact-block strong{
    font-size:20px;
  }
}

/* v13.0 – nur Aktuell: Regenkarte nach Referenz, halbbreit + höher */
#view-current .rain-tall-card{
  width:calc(50% - 8px);
  min-height:390px;
  padding:17px 18px 15px;
  align-self:start;
}
#view-current .rain-card-title{
  font-size:12px;
  font-weight:800;
  color:#18344f;
  margin-bottom:7px;
}
#view-current .rain-card-body{
  display:grid;
  grid-template-columns:minmax(0,1fr) 105px;
  gap:14px;
  align-items:start;
}
#view-current .rain-chart-column{min-width:0}
#view-current .rain-unit{
  font-size:9px;color:#536b7d;margin-bottom:2px
}
#view-current .rain-chart-shell{
  display:grid;
  grid-template-columns:28px minmax(0,1fr);
  gap:4px;
}
#view-current .rain-y-axis{
  position:relative;
  height:245px;
  font-size:9px;
  color:#657888;
}
#view-current .rain-y-axis span{
  position:absolute;
  right:2px;
  transform:translateY(50%);
}
#view-current .rain-plot{
  position:relative;
  height:270px;
}
#view-current .rain-grid{
  position:absolute;
  left:0;right:0;top:0;
  height:245px;
  pointer-events:none;
}
#view-current .rain-grid i{
  position:absolute;left:0;right:0;
  border-top:1px solid #e6ecef;
}
#view-current .rain-bars-web{
  position:absolute;
  left:0;right:0;top:0;
  height:245px;
  display:flex;
  align-items:flex-end;
  gap:2px;
  border-bottom:1px solid #cbd6dd;
}
#view-current .rain-bars-web .rain-web-bar{
  flex:1;
  min-width:1px;
  background:#3f8bc6;
  border-radius:1px 1px 0 0;
  opacity:.86;
}
#view-current .rain-bars-web .rain-web-bar.zero{
  opacity:.08;
  height:1px!important;
}
#view-current .rain-x-axis{
  position:absolute;
  left:0;right:0;bottom:0;
  display:flex;
  justify-content:space-between;
  font-size:9px;
  color:#657888;
}
#view-current .rain-side-values{
  padding-top:11px;
}
#view-current .rain-side-values>div{
  margin-bottom:17px;
}
#view-current .rain-side-values span{
  display:block;
  font-size:10px;
  line-height:1.15;
  color:#4e6577;
}
#view-current .rain-side-values strong{
  display:block;
  margin-top:2px;
  font-size:16px;
  color:#10243a;
  white-space:nowrap;
}
#view-current .rain-range-buttons{
  display:flex;
  justify-content:flex-start;
  gap:9px;
  margin-top:11px;
}
#view-current .rain-range{
  min-width:60px;
  padding:7px 12px;
  border:1px solid #d4dde4;
  border-radius:5px;
  background:#fff;
  color:#405568;
  font-size:11px;
  cursor:pointer;
}
#view-current .rain-range.active{
  border-color:#176ac0;
  background:#176ac0;
  color:#fff;
  box-shadow:0 2px 5px rgba(23,106,192,.2);
}

@media(max-width:900px){
  #view-current .rain-tall-card{width:100%}
}
@media(max-width:520px){
  #view-current .rain-card-body{grid-template-columns:minmax(0,1fr) 78px;gap:8px}
  #view-current .rain-y-axis,#view-current .rain-grid,#view-current .rain-bars-web{height:190px}
  #view-current .rain-plot{height:214px}
  #view-current .rain-range-buttons{gap:4px}
  #view-current .rain-range{min-width:0;flex:1;padding:7px 3px;font-size:10px}
  #view-current .rain-side-values strong{font-size:14px}
}

/* ================================================================
   v14.0 – AKTUELL exakt nach Beispielgrafik
   Andere Views bleiben strukturell unverändert.
   ================================================================ */

body{background:#f4f7f9}

/* top menu */
.reference-masthead{
  height:68px;
  display:grid;
  grid-template-columns:250px 1fr 220px;
  align-items:center;
  gap:18px;
  padding:0 26px;
  margin:-24px -24px 0;
  background:#0a263d;
  color:#fff;
  position:relative;
  z-index:20;
}
.reference-brand{
  display:flex;align-items:center;gap:10px;
  color:#fff;text-decoration:none
}
.reference-brand-icon{width:44px;height:44px}
.reference-brand span{display:flex;flex-direction:column}
.reference-brand strong{font-size:17px;letter-spacing:.03em}
.reference-brand small{font-size:11px;opacity:.8;margin-top:2px}
.reference-menu{
  display:flex;
  justify-content:center;
  gap:18px;
  background:transparent!important;
  padding:0!important;
}
.reference-menu .main-tab{
  border:0!important;
  border-radius:0!important;
  background:transparent!important;
  color:#fff!important;
  padding:24px 5px 17px!important;
  font-size:12px;
  font-weight:800;
  text-transform:uppercase;
  border-bottom:3px solid transparent!important;
  box-shadow:none!important;
}
.reference-menu .main-tab.active{
  color:#fff!important;
  border-bottom-color:#4e9cf0!important;
}
.reference-station-state{
  justify-self:end;
  display:flex;align-items:center;gap:9px;
  font-size:11px;text-align:right
}
.reference-station-state>div{display:flex;flex-direction:column}
.reference-station-state strong{font-size:11px}
.reference-station-state span:last-child{opacity:.72;margin-top:2px}

/* Hero */
.reference-current{margin-top:0}
.reference-hero{
  height:320px;
  margin:0 -24px 14px;
  position:relative;
  overflow:hidden;
  background:
    linear-gradient(90deg,rgba(5,25,42,.72),rgba(6,25,40,.10) 58%,rgba(5,25,42,.67)),
    url('assets/pfalzen-header.jpg') center center/cover no-repeat;
  color:#fff;
}
.reference-hero-shade{
  position:absolute;inset:0;
  background:linear-gradient(180deg,rgba(4,20,33,.06),rgba(4,20,33,.20))
}
.reference-hero-left{
  position:absolute;z-index:2;left:36px;top:25px;
}
.reference-place{font-size:17px;font-weight:600}
.reference-altitude{font-size:12px;opacity:.88;margin-top:3px}
.reference-hero-temp{
  font-size:86px;line-height:.95;
  font-weight:700;letter-spacing:-.055em;
  margin-top:23px
}
.reference-weather-label{font-size:21px;margin-top:10px}
.reference-updated{
  display:inline-block;margin-top:20px;
  padding:8px 11px;border-radius:6px;
  background:rgba(3,18,29,.62);font-size:11px
}
.reference-hero-right{
  position:absolute;z-index:2;right:32px;top:26px;
  width:220px;display:flex;flex-direction:column;gap:12px
}
.reference-hero-row{
  display:grid;grid-template-columns:32px 1fr;gap:9px;align-items:start
}
.reference-hero-row svg{width:28px;height:28px}
.reference-hero-row strong{display:block;font-size:20px;line-height:1}
.reference-hero-row span{display:block;font-size:11px;margin-top:2px}
.reference-hero-row small{display:block;font-size:10px;opacity:.78;margin-top:2px}

/* five cards */
.reference-five{
  display:grid;grid-template-columns:repeat(5,minmax(0,1fr));
  gap:10px;margin-bottom:12px
}
.reference-metric{
  min-height:144px;
  background:#fff;border:1px solid #dfe6eb;border-radius:9px;
  box-shadow:0 3px 12px rgba(23,42,58,.07);
  padding:16px 15px 11px;
  display:grid;grid-template-columns:42px 1fr;grid-template-rows:1fr auto;
  gap:0 11px
}
.reference-metric>svg{width:37px;height:37px;margin-top:5px}
.reference-metric-main span{
  display:block;font-size:10px;font-weight:800;color:#344d61;letter-spacing:.03em
}
.reference-metric-main strong{
  display:block;font-size:27px;line-height:1.02;color:#0f1d2a;
  margin-top:6px;letter-spacing:-.025em
}
.reference-metric-main small{
  display:block;font-size:10px;color:#415465;margin-top:6px
}
.reference-metric-bottom{
  grid-column:1/-1;
  border-top:1px solid #e8edf0;
  padding-top:10px;margin-top:12px;
  display:flex;justify-content:space-between;gap:8px;
  font-size:10px;color:#43586b
}
.reference-temp>svg{color:#d63b30}
.reference-humidity>svg{color:#347ec7}
.reference-pressure>svg{color:#45a149}
.reference-wind>svg{color:#8151cf}
.reference-rain>svg{color:#347ec7}
.reference-metric b{font-weight:700}

/* section layout */
.reference-grid{display:grid;gap:12px;margin-bottom:12px}
.reference-primary-row{grid-template-columns:1fr 1fr}
.reference-secondary-row{grid-template-columns:1.05fr .95fr .75fr}
.reference-current .panel{
  border:1px solid #dfe6eb;
  border-radius:9px;
  background:#fff;
  box-shadow:0 3px 12px rgba(23,42,58,.06)
}
.reference-panel-title{
  font-size:13px;font-weight:850;color:#18354f;margin-bottom:8px
}
.reference-subtitle{
  font-size:11px;font-weight:800;color:#234460;margin-bottom:4px
}

/* charts */
.reference-temp-panel,.reference-pressure-panel{padding:15px}
#current-temp-chart{height:265px}
#current-pressure-chart{height:220px}
.reference-mini-buttons{
  display:flex;gap:8px;margin-top:8px
}
.reference-mini-buttons button,
.rain-range{
  border:1px solid #d7e0e6;background:#fff;color:#45596a;
  padding:7px 13px;border-radius:5px;font-size:10px
}
.reference-mini-buttons button.active,
.rain-range.active{
  background:#176dc4;color:#fff;border-color:#176dc4
}

/* wind */
.reference-wind-panel{padding:15px}
.reference-wind-panel .wind-overview-layout{
  grid-template-columns:minmax(0,1fr) 150px;
  gap:12px
}
.reference-wind-panel .windrose-large-wrap{
  border-right:1px solid #e7ecef;padding-right:14px
}
.reference-wind-panel #windrose{height:300px}
.reference-wind-panel .wind-summary-item{padding:13px 2px}
.reference-wind-panel .wind-summary-item strong{font-size:24px}

/* rain */
.reference-rain-panel{padding:15px}
.reference-rain-panel .rain-card-body{
  display:grid;grid-template-columns:minmax(0,1fr) 82px;gap:10px
}
.reference-rain-panel .rain-y-axis{height:165px}
.reference-rain-panel .rain-plot{height:190px}
.reference-rain-panel .rain-grid,
.reference-rain-panel .rain-bars-web{height:165px}
.reference-rain-panel .rain-side-values{padding-top:12px}
.reference-rain-panel .rain-side-values>div{margin-bottom:13px}
.reference-rain-panel .rain-side-values span{font-size:9px}
.reference-rain-panel .rain-side-values strong{font-size:13px}
.reference-rain-panel .rain-range-buttons{gap:5px;margin-top:8px}
.reference-rain-panel .rain-range{padding:6px 8px;min-width:0}

/* pressure */
.reference-pressure-panel .reference-pressure-meta{
  display:flex;justify-content:space-between;
  font-size:10px;color:#4b6174;margin-top:5px
}

/* sun */
.reference-sun-panel{padding:15px}
.reference-sun-grid{
  display:grid;grid-template-columns:1fr 1fr;gap:16px 12px;margin-top:20px
}
.reference-sun-grid>div{
  min-width:0
}
.reference-sun-grid svg{width:32px;height:32px;color:#ef9b0c}
.reference-sun-grid span{display:block;font-size:9px;color:#506577;margin-top:5px}
.reference-sun-grid strong{display:block;font-size:17px;color:#13263a;margin-top:2px}

/* bottom overview */
.reference-overview{padding:14px 15px;margin-bottom:12px}
.reference-overview .stats-grid{
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:8px
}
.reference-bottom-grid{
  display:grid;grid-template-columns:1fr 1fr;gap:12px
}
.reference-bottom-grid>.panel{padding:15px}

/* responsive */
@media(max-width:1050px){
  .reference-masthead{grid-template-columns:210px 1fr 170px}
  .reference-menu{gap:8px}
  .reference-five{grid-template-columns:repeat(3,1fr)}
  .reference-secondary-row{grid-template-columns:1fr 1fr}
  .reference-sun-panel{grid-column:1/-1}
}
@media(max-width:760px){
  .reference-masthead{
    height:auto;grid-template-columns:1fr auto;
    padding:10px 14px;margin:-18px -14px 0
  }
  .reference-menu{
    grid-column:1/-1;grid-row:2;
    overflow-x:auto;justify-content:flex-start;width:100%
  }
  .reference-menu .main-tab{padding:10px 5px 8px!important;white-space:nowrap}
  .reference-station-state{grid-column:2;grid-row:1}
  .reference-brand strong{font-size:14px}

  .reference-hero{height:330px;margin:0 -14px 10px}
  .reference-hero-left{left:18px;top:20px}
  .reference-hero-temp{font-size:62px}
  .reference-hero-right{
    left:18px;right:18px;top:auto;bottom:16px;width:auto;
    display:grid;grid-template-columns:repeat(2,1fr);gap:7px 14px
  }
  .reference-hero-row svg{width:22px;height:22px}
  .reference-hero-row strong{font-size:15px}
  .reference-hero-row span{font-size:9px}

  .reference-five{grid-template-columns:repeat(2,1fr);gap:7px}
  .reference-metric{min-height:120px;padding:11px;grid-template-columns:32px 1fr}
  .reference-metric>svg{width:28px;height:28px}
  .reference-metric-main strong{font-size:21px}

  .reference-primary-row,.reference-secondary-row,.reference-bottom-grid{grid-template-columns:1fr}
  .reference-sun-panel{grid-column:auto}
  .reference-wind-panel .wind-overview-layout{grid-template-columns:1fr}
  .reference-wind-panel .windrose-large-wrap{
    border-right:0;border-bottom:1px solid #e7ecef;padding:0 0 10px
  }
  .reference-wind-panel .wind-summary{
    display:grid;grid-template-columns:repeat(3,1fr)
  }
  .reference-overview .stats-grid{grid-template-columns:1fr}
}

/* v14.2 – nur Aktuell: Jahres-Kenntage + Sonne/Mond */

.reference-ytd-panel{
  padding:14px 16px 13px;
  margin-bottom:12px;
  background:linear-gradient(90deg,#f1f8ef,#f8fbf6);
  border-color:#e0e9dc!important;
}
.reference-ytd-title{
  font-size:11px;
  font-weight:850;
  color:#223a4d;
  margin-bottom:9px;
}
.reference-ytd-grid{
  display:grid;
  grid-template-columns:repeat(8,minmax(0,1fr));
  align-items:center;
}
.reference-ytd-item{
  min-width:0;
  min-height:58px;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  padding:4px 10px;
  border-right:1px solid #dce5df;
}
.reference-ytd-item:last-child{border-right:0}
.reference-ytd-item svg{
  width:32px;
  height:32px;
  flex:0 0 auto;
}
.reference-ytd-item strong{
  display:block;
  font-size:21px;
  line-height:1;
  letter-spacing:-.025em;
  color:#13273a;
  white-space:nowrap;
}
.reference-ytd-item span{
  display:block;
  margin-top:4px;
  font-size:9px;
  line-height:1.15;
  color:#42586a;
  white-space:nowrap;
}
.ytd-severe svg{color:#356fbc}
.ytd-ice svg{color:#5a9be7}
.ytd-frost svg{color:#4388d8}
.ytd-summer svg{color:#efa315}
.ytd-hot svg{color:#d94735}
.ytd-rain-days svg{color:#438cc9}
.ytd-rain svg{color:#347fc3}
.ytd-sun svg{color:#efa315}

.reference-astro-panel{
  padding:17px 18px;
  margin-bottom:12px;
}
.reference-astro-layout{
  display:grid;
  grid-template-columns:1fr 1fr 1.2fr;
  gap:0;
  margin-top:12px;
}
.reference-astro-main{
  padding:6px 24px 6px 6px;
  border-right:1px solid #e7ecef;
}
.reference-astro-moon{padding-left:24px}
.reference-astro-icon-wrap{
  width:48px;height:48px;
  display:grid;place-items:center;
  border-radius:50%;
  background:#f5f8fa;
  margin-bottom:6px;
}
.reference-astro-icon-wrap svg{width:31px;height:31px}
.reference-astro-sun .reference-astro-icon-wrap{color:#efa315}
.reference-astro-moon .reference-astro-icon-wrap{color:#46688e}
.reference-astro-title{
  font-size:16px;font-weight:800;color:#18364f;margin-bottom:12px
}
.reference-astro-row{
  display:flex;justify-content:space-between;gap:12px;
  padding:6px 0;border-bottom:1px solid #edf1f3
}
.reference-astro-row:last-child{border-bottom:0}
.reference-astro-row span{font-size:10px;color:#657887}
.reference-astro-row strong{font-size:13px;color:#172a3b;text-align:right}
.reference-astro-next{
  padding:6px 0 6px 24px;
  display:grid;grid-template-columns:1fr 1fr;
  gap:14px;align-content:start
}
.reference-astro-next>div:not(.reference-moon-advice){
  padding:11px 12px;border-radius:8px;background:#f7f9fa
}
.reference-astro-next span{display:block;font-size:9px;color:#667988}
.reference-astro-next strong{display:block;font-size:15px;color:#172a3b;margin-top:4px}
.reference-moon-advice{
  grid-column:1/-1;padding:12px 13px;border-radius:8px;background:#f7f9fa
}
.reference-moon-advice strong{font-size:12px;line-height:1.45}
.reference-moon-advice small{
  display:block;margin-top:5px;font-size:9px;color:#87939d
}

@media(max-width:1100px){
  .reference-ytd-grid{grid-template-columns:repeat(4,1fr);row-gap:10px}
  .reference-ytd-item:nth-child(4),
  .reference-ytd-item:nth-child(8){border-right:0}
  .reference-astro-layout{grid-template-columns:1fr 1fr}
  .reference-astro-next{
    grid-column:1/-1;border-top:1px solid #e7ecef;
    padding:16px 0 0;margin-top:14px
  }
}
@media(max-width:700px){
  .reference-ytd-panel{overflow-x:auto}
  .reference-ytd-grid{
    min-width:720px;
    grid-template-columns:repeat(8,90px);
    row-gap:0
  }
  .reference-ytd-item:nth-child(4){border-right:1px solid #dce5df}
  .reference-ytd-item{justify-content:flex-start;padding:4px 9px}
  .reference-ytd-item svg{width:27px;height:27px}
  .reference-ytd-item strong{font-size:18px}

  .reference-astro-layout{grid-template-columns:1fr}
  .reference-astro-main,.reference-astro-moon{
    padding:10px 0 14px;
    border-right:0;border-bottom:1px solid #e7ecef
  }
  .reference-astro-moon{padding-top:15px}
  .reference-astro-next{
    grid-column:auto;border-top:0;padding:15px 0 0;margin-top:0
  }
}

/* v14.3 – Temperatur Heute + Regen technisch sauber */
#view-current #current-temp-chart{
  display:block;
  width:100%;
  height:265px;
}
#view-current .reference-temp-panel .chart-legend{
  display:flex;
  flex-wrap:wrap;
  gap:12px;
  margin:0 0 5px;
  font-size:9px;
}
#view-current .rain-y-axis span{
  position:absolute;
  right:2px;
}
#view-current .rain-grid i{
  position:absolute;
  left:0;
  right:0;
  border-top:1px solid #e6ecef;
}
#view-current .rain-x-axis span{
  position:absolute;
  transform:translateX(-50%);
  white-space:nowrap;
}
#view-current .rain-x-axis span:first-child{transform:none}
#view-current .rain-x-axis span:last-child{transform:translateX(-100%)}

/* v14.4 – Kacheln ausgerichtet und gleich hoch */
.reference-five{
  align-items:stretch;
  grid-auto-rows:1fr;
}
.reference-five .reference-metric{
  height:100%;
  min-height:148px;
  grid-template-rows:minmax(82px,1fr) auto;
  align-content:stretch;
}
.reference-five .reference-metric>svg{
  align-self:start;
}
.reference-five .reference-metric-main{
  min-height:82px;
  display:flex;
  flex-direction:column;
  justify-content:flex-start;
}
.reference-five .reference-metric-main strong{
  min-height:29px;
}
.reference-five .reference-metric-main small{
  min-height:20px;
}
.reference-five .reference-metric-bottom{
  align-self:end;
  min-height:31px;
  margin-top:8px;
  align-items:center;
}
.reference-primary-row,
.reference-secondary-row{
  align-items:stretch;
}
.reference-primary-row>.panel{
  min-height:395px;
  height:100%;
}
.reference-secondary-row>.panel{
  min-height:325px;
  height:100%;
}
.reference-mini-buttons .temp-range.active{
  background:#176dc4;
  color:#fff;
  border-color:#176dc4;
}
@media(max-width:760px){
  .reference-five .reference-metric{min-height:126px}
  .reference-primary-row>.panel,
  .reference-secondary-row>.panel{min-height:0}
}

/* ================================================================
   v14.5 – Webcam Pfalzen
   ================================================================ */
.reference-menu{gap:12px}
.webcam-view{padding:18px 0 28px}
.webcam-page-head{
  display:flex;justify-content:space-between;align-items:flex-end;gap:20px;
  margin:0 0 14px;padding:0 2px;
}
.webcam-eyebrow{
  display:block;font-size:10px;font-weight:850;letter-spacing:.12em;color:#3176b7;margin-bottom:4px
}
.webcam-page-head h1{margin:0;color:#15344e;font-size:25px;letter-spacing:-.02em}
.webcam-page-head p{margin:5px 0 0;color:#617689;font-size:11px}
.webcam-live-state{
  display:flex;align-items:center;gap:7px;white-space:nowrap;
  border:1px solid #d9e6dc;background:#f5fbf6;color:#375847;
  border-radius:999px;padding:7px 11px;font-size:10px;font-weight:700
}
.webcam-live-state i{width:8px;height:8px;border-radius:50%;background:#39a259;box-shadow:0 0 0 3px rgba(57,162,89,.12)}
.webcam-live-state.offline{border-color:#eadcdc;background:#fff8f8;color:#765050}
.webcam-live-state.offline i{background:#c74a4a;box-shadow:0 0 0 3px rgba(199,74,74,.12)}

.webcam-main-card{padding:0!important;overflow:hidden;margin-bottom:12px}
.webcam-image-stage{
  position:relative;background:#102231;aspect-ratio:16/9;overflow:hidden;min-height:360px
}
.webcam-image-stage>a{display:block;width:100%;height:100%}
.webcam-image-stage img{display:block;width:100%;height:100%;object-fit:cover;background:#102231}
.webcam-image-loading{
  position:absolute;inset:0;display:grid;place-items:center;color:#c9d4dc;font-size:12px;
  background:linear-gradient(145deg,#122b3d,#0b1d2b);z-index:1
}
.webcam-image-loading[hidden]{display:none}
.webcam-image-overlay{
  position:absolute;z-index:2;left:0;right:0;bottom:0;
  display:flex;justify-content:space-between;align-items:flex-end;gap:12px;
  padding:36px 20px 16px;color:#fff;
  background:linear-gradient(transparent,rgba(3,15,25,.72));pointer-events:none
}
.webcam-image-overlay strong{display:block;font-size:18px}
.webcam-image-overlay span{display:block;font-size:11px;margin-top:2px}
.webcam-current-badge{
  border:1px solid rgba(255,255,255,.45);border-radius:999px;padding:6px 9px!important;
  font-size:9px!important;font-weight:800;letter-spacing:.08em;background:rgba(7,24,37,.55)
}
.webcam-current-badge.live{background:#21854b;border-color:#43b66e}

.webcam-toolbar{
  display:flex;align-items:center;justify-content:space-between;gap:12px;
  padding:12px 15px;border-top:1px solid #e4ebef;background:#fff
}
.webcam-nav-controls{display:flex;align-items:center;gap:7px}
.webcam-icon-btn,.webcam-play-btn,.webcam-secondary-btn{
  appearance:none;border:1px solid #d4dee5;background:#fff;color:#2c4d67;border-radius:6px;
  height:36px;padding:0 12px;font-size:11px;font-weight:700;cursor:pointer
}
.webcam-icon-btn{width:38px;padding:0;font-size:24px;line-height:1}
.webcam-play-btn{min-width:128px;background:#176dc4;border-color:#176dc4;color:#fff}
.webcam-icon-btn:hover,.webcam-secondary-btn:hover{background:#f4f8fa}
.webcam-play-btn:hover{background:#125da8}
.webcam-date-control{display:flex;align-items:center;gap:8px;margin-left:auto}
.webcam-date-control span{font-size:10px;font-weight:700;color:#50677a}
.webcam-date-control input{
  height:36px;border:1px solid #d4dee5;border-radius:6px;padding:0 9px;background:#fff;color:#243f55;font:inherit
}

.webcam-meta{
  display:grid;grid-template-columns:repeat(5,minmax(0,1fr));border-top:1px solid #edf1f3;background:#f9fbfc
}
.webcam-meta>div{padding:10px 13px;border-right:1px solid #e5ebef;min-width:0}
.webcam-meta>div:last-child{border-right:0}
.webcam-meta span{display:block;font-size:8px;text-transform:uppercase;letter-spacing:.06em;color:#7c8c98}
.webcam-meta strong{display:block;margin-top:3px;font-size:11px;color:#243e52;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

.webcam-day-card{padding:14px 15px!important;margin-bottom:12px}
.webcam-section-head{display:flex;justify-content:space-between;align-items:end;gap:12px;margin-bottom:11px}
.webcam-section-head>div span{display:block;font-size:9px;font-weight:800;color:#6b7f8e;letter-spacing:.08em}
.webcam-section-head>div strong{display:block;font-size:15px;color:#173750;margin-top:3px}
.webcam-section-head>span{font-size:10px;color:#687c8c}
.webcam-filmstrip-wrap{position:relative;padding:0 32px}
.webcam-filmstrip{
  display:flex;gap:7px;overflow-x:auto;scrollbar-width:thin;scroll-snap-type:x proximity;padding:2px 0 7px
}
.webcam-thumb{
  flex:0 0 132px;scroll-snap-align:center;border:2px solid transparent;border-radius:7px;padding:3px;
  background:#f4f7f9;color:#41596c;cursor:pointer;transition:.15s ease
}
.webcam-thumb:hover{background:#eaf2f7}
.webcam-thumb.active{border-color:#2478c7;background:#eef6fd;box-shadow:0 0 0 2px rgba(36,120,199,.08)}
.webcam-thumb img{display:block;width:100%;aspect-ratio:16/9;object-fit:cover;border-radius:4px;background:#172c3c}
.webcam-thumb span{display:block;text-align:center;font-size:9px;font-weight:700;padding:5px 2px 2px}
.webcam-strip-arrow{
  position:absolute;top:50%;transform:translateY(-55%);z-index:2;width:27px;height:54px;
  border:1px solid #d6e0e6;border-radius:6px;background:rgba(255,255,255,.94);color:#35566f;
  font-size:23px;cursor:pointer;box-shadow:0 2px 7px rgba(22,42,58,.08)
}
.webcam-strip-arrow.left{left:0}.webcam-strip-arrow.right{right:0}
.webcam-empty{text-align:center;padding:24px 10px;color:#748593;font-size:11px}

.webcam-info-card{
  padding:13px 15px!important;display:grid;grid-template-columns:repeat(3,1fr);gap:12px;background:#f8fbfc!important
}
.webcam-info-card>div{display:grid;grid-template-columns:31px 1fr;gap:9px;align-items:start}
.webcam-info-icon{
  width:29px;height:29px;border-radius:50%;display:grid;place-items:center;background:#eaf3fa;color:#2474b9;font-weight:800
}
.webcam-info-card strong{display:block;font-size:10px;color:#24445d}
.webcam-info-card p{margin:3px 0 0;font-size:9px;line-height:1.45;color:#6c7f8e}
.webcam-info-card code{font-size:8px;color:#315d7e}

@media(max-width:1050px){
  .reference-menu{gap:5px}
  .reference-menu .main-tab{font-size:10px!important}
  .webcam-meta{grid-template-columns:repeat(3,1fr)}
  .webcam-meta>div:nth-child(3){border-right:0}
  .webcam-meta>div:nth-child(n+4){border-top:1px solid #e5ebef}
}
@media(max-width:760px){
  .webcam-view{padding-top:12px}
  .webcam-page-head{align-items:flex-start;flex-direction:column;gap:9px}
  .webcam-page-head h1{font-size:21px}
  .webcam-image-stage{min-height:0;aspect-ratio:16/10}
  .webcam-image-overlay{padding:30px 12px 10px}
  .webcam-image-overlay strong{font-size:14px}
  .webcam-toolbar{flex-wrap:wrap;padding:10px}
  .webcam-nav-controls{width:100%;justify-content:center}
  .webcam-play-btn{flex:1}
  .webcam-date-control{margin-left:0;flex:1}
  .webcam-date-control input{flex:1;min-width:0}
  .webcam-secondary-btn{flex:0 0 auto}
  .webcam-meta{grid-template-columns:repeat(2,1fr)}
  .webcam-meta>div{border-top:1px solid #e5ebef}
  .webcam-meta>div:nth-child(odd){border-right:1px solid #e5ebef}
  .webcam-meta>div:nth-child(even){border-right:0}
  .webcam-thumb{flex-basis:108px}
  .webcam-filmstrip-wrap{padding:0 25px}
  .webcam-strip-arrow{width:22px}
  .webcam-info-card{grid-template-columns:1fr}
}
.webcam-bestof-card{padding:14px 15px!important;margin-bottom:12px}
.webcam-bestof-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:9px}
.webcam-bestof-item{appearance:none;border:1px solid #dce5ea;border-radius:7px;background:#fff;padding:4px;overflow:hidden;cursor:pointer;text-align:left;color:#29485f}
.webcam-bestof-item:hover{border-color:#8bb8db;background:#f7fbfe}
.webcam-bestof-item img{display:block;width:100%;aspect-ratio:16/9;object-fit:cover;border-radius:4px;background:#132b3d}
.webcam-bestof-item span{display:flex;justify-content:space-between;gap:6px;align-items:center;padding:6px 4px 3px}
.webcam-bestof-item b{font-size:9px}.webcam-bestof-item small{font-size:8px;color:#718492}
@media(max-width:900px){.webcam-bestof-grid{grid-template-columns:repeat(3,1fr)}}
@media(max-width:600px){.webcam-bestof-grid{grid-template-columns:repeat(2,1fr)}}
