/* ==========================================================================
   Maurice's Bieratlas — dunkles Editorial-Design
   ========================================================================== */

:root {
  --bg: #0b0d0f;
  --bg-soft: #101418;
  --surface: #151a1f;
  --surface-2: #1a2027;
  --line: rgba(244, 234, 216, 0.10);
  --line-strong: rgba(244, 234, 216, 0.18);
  --text: #f4ead8;
  --text-dim: #b7b0a4;
  --text-mute: #8d8779;
  --amber: #f2a33c;
  --amber-soft: #ffc773;
  --amber-deep: #b9711f;
  --cream: #f4ead8;
  --danger: #d9603f;
  --ok: #7fb77e;
  --shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  --radius: 14px;
  --radius-lg: 22px;
  --maxw: 1440px;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Fraunces", "Iowan Old Style", Georgia, serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 500px at 12% -8%, rgba(242, 163, 60, 0.16), transparent 62%),
    radial-gradient(900px 420px at 92% 4%, rgba(185, 113, 31, 0.14), transparent 60%),
    linear-gradient(180deg, #0b0d0f 0%, #0e1114 42%, #0b0d0f 100%);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.05;
  background-image:
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.6) 0 1px, transparent 1px 3px);
  mix-blend-mode: overlay;
}

.site-header,
.tabs,
.site-main,
.site-footer {
  position: relative;
  z-index: 1;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: clamp(16px, 4vw, 40px);
}

/* ---------- header ---------- */

.site-header {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  justify-content: space-between;
  align-items: flex-end;
  padding-block: clamp(28px, 5vw, 56px) clamp(20px, 3vw, 32px);
}

.eyebrow {
  margin: 0 0 8px;
  font-size: 0.74rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--amber);
  font-weight: 600;
}

.brand h1 {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(2.2rem, 6vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.02em;
}

.brand h1 em {
  font-style: italic;
  color: var(--amber-soft);
}

.lede {
  margin: 14px 0 0;
  max-width: 62ch;
  color: var(--text-dim);
  font-size: clamp(0.95rem, 1.4vw, 1.05rem);
}

.header-side {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.header-stamp,
.header-stat {
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  padding: 10px 16px;
  background: rgba(21, 26, 31, 0.7);
  backdrop-filter: blur(6px);
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 118px;
}

.stamp-label {
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-mute);
}

.header-stamp strong,
.header-stat strong {
  font-size: 1.05rem;
  font-weight: 600;
}

/* ---------- tabs ---------- */

.tabs {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  gap: 6px;
  padding-block: 10px;
  background: linear-gradient(180deg, rgba(11, 13, 15, 0.98), rgba(11, 13, 15, 0.9));
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  overflow-x: auto;
  scrollbar-width: none;
}

.tabs::-webkit-scrollbar { display: none; }

.tab {
  appearance: none;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-dim);
  font-family: var(--sans);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 10px 18px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  transition: color 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.tab:hover { color: var(--text); background: rgba(242, 163, 60, 0.08); }

.tab.is-active {
  color: #16120b;
  background: linear-gradient(135deg, var(--amber-soft), var(--amber));
  border-color: rgba(255, 199, 115, 0.6);
  font-weight: 600;
}

.tab-index {
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  opacity: 0.7;
  font-variant-numeric: tabular-nums;
}

/* ---------- main / panels ---------- */

.site-main { padding-block: clamp(24px, 4vw, 44px) 64px; }

.tab-panel { display: none; }
.tab-panel.is-active { display: block; animation: panel-in 0.35s ease both; }

@keyframes panel-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

.panel-head {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
  align-items: flex-end;
  margin-bottom: clamp(20px, 3vw, 32px);
}

.panel-head h2 {
  margin: 0;
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(1.7rem, 3.4vw, 2.5rem);
  letter-spacing: -0.015em;
}

.panel-lede {
  margin: 8px 0 0;
  max-width: 60ch;
  color: var(--text-dim);
}

.head-figure {
  text-align: right;
  border-right: 2px solid var(--amber);
  padding-right: 16px;
}

.head-figure strong {
  display: block;
  font-family: var(--display);
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  font-weight: 600;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  color: var(--amber-soft);
}

.head-figure span {
  font-size: 0.74rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-mute);
}

/* ---------- toolbar ---------- */

.toolbar {
  display: grid;
  grid-template-columns: minmax(200px, 1.5fr) repeat(4, minmax(132px, 1fr)) auto;
  gap: 12px;
  align-items: end;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 26, 31, 0.66);
  backdrop-filter: blur(8px);
  margin-bottom: 16px;
}

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }

.field > span {
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-mute);
}

.field input,
.field select {
  width: 100%;
  min-width: 0;
  background: var(--bg-soft);
  color: var(--text);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 10px 12px;
  font-family: var(--sans);
  font-size: 0.92rem;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.field input::placeholder { color: var(--text-mute); }

.field input:focus,
.field select:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(242, 163, 60, 0.18);
}

.field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-mute) 50%),
    linear-gradient(135deg, var(--text-mute) 50%, transparent 50%);
  background-position: calc(100% - 18px) 18px, calc(100% - 12px) 18px;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
  padding-right: 34px;
}

.field-compact input { background: var(--surface-2); }

.btn {
  font-family: var(--sans);
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 10px;
  padding: 11px 18px;
  cursor: pointer;
  border: 1px solid var(--line-strong);
  transition: transform 0.15s ease, background 0.18s ease, border-color 0.18s ease;
}

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

.btn-ghost {
  background: transparent;
  color: var(--text-dim);
}

.btn-ghost:hover { color: var(--text); border-color: var(--amber); }

.btn-solid {
  background: linear-gradient(135deg, var(--amber-soft), var(--amber));
  color: #16120b;
  border-color: transparent;
  box-shadow: 0 10px 26px rgba(242, 163, 60, 0.24);
}

.btn-solid:hover { filter: brightness(1.06); }

.btn-solid:disabled { opacity: 0.4; cursor: default; box-shadow: none; }

.result-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  margin-bottom: 14px;
}

.result-line p { margin: 0; font-size: 0.9rem; color: var(--text-dim); }
.result-line strong { color: var(--text); }
.muted { color: var(--text-mute); }

/* ---------- beer grid ---------- */

.beer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(284px, 1fr));
  gap: 14px;
}

.beer-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(26, 32, 39, 0.9), rgba(21, 26, 31, 0.9));
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.beer-card:hover {
  transform: translateY(-3px);
  border-color: rgba(242, 163, 60, 0.4);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.4);
}

.beer-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }

.beer-name {
  margin: 0;
  font-family: var(--display);
  font-size: 1.08rem;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.beer-brewery {
  margin: 2px 0 0;
  font-size: 0.8rem;
  color: var(--text-mute);
}

.beer-rating {
  flex-shrink: 0;
  min-width: 46px;
  text-align: center;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 5px 7px;
  font-size: 0.85rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--amber-soft);
  background: rgba(242, 163, 60, 0.09);
}

.beer-rating.is-low { color: var(--text-dim); background: rgba(244, 234, 216, 0.05); }
.beer-rating.is-none { color: var(--text-mute); background: transparent; }

.beer-style {
  align-self: flex-start;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--amber);
  border: 1px solid rgba(242, 163, 60, 0.28);
  background: rgba(242, 163, 60, 0.08);
  border-radius: 999px;
  padding: 3px 10px;
}

.beer-meta {
  margin-top: auto;
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  border-top: 1px dashed var(--line);
  padding-top: 10px;
  font-size: 0.78rem;
  color: var(--text-mute);
  font-variant-numeric: tabular-nums;
}

.beer-meta b { color: var(--text-dim); font-weight: 600; }

.load-more-wrap { margin-top: 24px; text-align: center; }

/* ---------- maps ---------- */

.map-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 348px;
  gap: 18px;
  align-items: start;
}

.map-shell {
  position: relative;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.map-canvas {
  height: clamp(480px, calc(100vh - 320px), 760px);
  width: 100%;
  background: #101418;
}

.map-corner {
  position: absolute;
  left: 12px;
  bottom: 12px;
  z-index: 500;
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
  pointer-events: none;
}

.coverage-badge {
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  color: var(--text-dim);
  background: rgba(11, 13, 15, 0.85);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 6px 12px;
  backdrop-filter: blur(6px);
}

.heat-legend {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.68rem;
  color: var(--text-mute);
  background: rgba(11, 13, 15, 0.85);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 5px 12px;
  backdrop-filter: blur(6px);
}

.heat-legend i {
  display: block;
  width: 92px;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(90deg, rgba(242, 163, 60, 0.15), rgba(242, 163, 60, 0.7), #ff7a3d, #ff4d2d);
}

.map-side { display: flex; flex-direction: column; gap: 14px; }

.side-block {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 26, 31, 0.7);
  padding: 16px;
}

.side-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.side-title-row h3 {
  margin: 0;
  font-family: var(--display);
  font-size: 1.1rem;
  font-weight: 600;
}

.seg {
  display: inline-flex;
  gap: 4px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 3px;
  background: var(--bg-soft);
}

.seg-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--text-mute);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.16s ease, color 0.16s ease;
}

.seg-btn.is-on { background: rgba(242, 163, 60, 0.9); color: #16120b; }

.switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 0.74rem;
  color: var(--text-dim);
}

.switch input {
  appearance: none;
  width: 34px;
  height: 18px;
  border-radius: 999px;
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  position: relative;
  cursor: pointer;
  transition: background 0.18s ease;
}

.switch input::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--text-mute);
  transition: transform 0.18s ease, background 0.18s ease;
}

.switch input:checked { background: rgba(242, 163, 60, 0.85); border-color: transparent; }
.switch input:checked::after { transform: translateX(16px); background: #16120b; }

.rank-list,
.data-list {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.rank-item {
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.16s ease, border-color 0.16s ease;
}

.rank-item:hover { background: rgba(242, 163, 60, 0.08); border-color: rgba(242, 163, 60, 0.25); }
.rank-item.is-focus { background: rgba(242, 163, 60, 0.14); border-color: rgba(242, 163, 60, 0.45); }

.rank-index {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--amber);
  font-variant-numeric: tabular-nums;
}

.rank-name {
  font-size: 0.86rem;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.rank-sub {
  display: block;
  font-size: 0.72rem;
  color: var(--text-mute);
  font-weight: 400;
}

.rank-value {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--amber-soft);
  font-variant-numeric: tabular-nums;
}

.side-note {
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 14px 16px;
  color: var(--text-mute);
  font-size: 0.82rem;
  background: rgba(16, 20, 24, 0.55);
}

.side-note p { margin: 0 0 8px; }
.side-note p:last-child { margin-bottom: 0; }
.side-note strong { color: var(--text-dim); }

/* ---------- stats ---------- */

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 14px 18px;
  align-items: flex-end;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 26, 31, 0.66);
  backdrop-filter: blur(8px);
  margin-bottom: 16px;
}

.filter-group { display: flex; flex-direction: column; gap: 6px; }
.filter-wide { flex: 1 1 340px; min-width: 0; }

/* Auch Selects, die nicht in einem .field-Label stecken, bekommen das
   dunkle Aussehen — sonst fallen sie auf Browser-Standard zurück. */
.filter-group > select {
  width: 100%;
  min-width: 0;
  background: var(--bg-soft);
  color: var(--text);
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  padding: 8px 12px;
  font-family: var(--sans);
  font-size: 0.84rem;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.filter-group > select:focus {
  outline: none;
  border-color: var(--amber);
  box-shadow: 0 0 0 3px rgba(242, 163, 60, 0.18);
}

.filter-label {
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-mute);
}

.chipbar { display: flex; flex-wrap: wrap; gap: 6px; }

.chip {
  appearance: none;
  border: 1px solid var(--line-strong);
  background: var(--bg-soft);
  color: var(--text-dim);
  font-family: var(--sans);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  padding: 5px 11px;
  border-radius: 999px;
  cursor: pointer;
  transition: color 0.15s ease, background 0.15s ease, border-color 0.15s ease;
  white-space: nowrap;
}

.chip:hover { color: var(--text); border-color: rgba(242, 163, 60, 0.45); }

.chip.is-on {
  background: rgba(242, 163, 60, 0.9);
  border-color: transparent;
  color: #16120b;
  font-weight: 600;
}

.chip .chip-count {
  opacity: 0.6;
  margin-left: 5px;
  font-variant-numeric: tabular-nums;
  font-size: 0.68rem;
}

.btn-small { padding: 9px 14px; font-size: 0.8rem; align-self: flex-end; }

.month-range { display: flex; align-items: center; gap: 8px; }
.month-range select { min-width: 116px; }
.range-dash { color: var(--text-mute); }

.scope-bar {
  min-height: 8px;
  margin-bottom: 16px;
}
.scope-bar:empty { display: none; }

.scope-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid rgba(242, 163, 60, 0.35);
  background: rgba(242, 163, 60, 0.1);
  color: var(--amber-soft);
  font-size: 0.76rem;
  padding: 5px 8px 5px 12px;
  border-radius: 999px;
}

.scope-chip button {
  appearance: none;
  border: 0;
  background: rgba(0, 0, 0, 0.28);
  color: inherit;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 0.78rem;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.scope-chip button:hover { background: rgba(242, 163, 60, 0.4); color: #16120b; }

.scope-total {
  font-size: 0.78rem;
  color: var(--text-mute);
  padding-left: 6px;
  font-variant-numeric: tabular-nums;
}

.chart-section { margin-bottom: 26px; }

.section-head {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.head-toggles { display: flex; flex-wrap: wrap; gap: 8px; }

.section-head h3 {
  margin: 0;
  font-family: var(--display);
  font-size: 1.28rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.section-note {
  margin: 0 0 16px;
  font-size: 0.8rem;
  color: var(--text-mute);
  max-width: 76ch;
}

.section-note strong { color: var(--amber-soft); }

/* Die Höhe für breite Diagramme steht weiter unten direkt hinter .chart-box,
   weil sonst die spätere .chart-Box-Regel sie überschreibt. */

.matrix-card { margin-top: 14px; }
.matrix-wrap { overflow-x: auto; }

.matrix {
  border-collapse: collapse;
  font-size: 0.74rem;
  min-width: 100%;
}

.matrix th,
.matrix td {
  padding: 6px 9px;
  text-align: right;
  border-bottom: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.matrix th {
  color: var(--text-mute);
  font-weight: 600;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: right;
}

.matrix th:first-child,
.matrix td:first-child { text-align: left; }

.matrix td.cell { color: var(--text); min-width: 42px; }

.matrix .cell-top {
  color: var(--amber-soft);
  font-weight: 600;
}

.matrix .row-total { color: var(--text-mute); }

.compare-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: flex-end;
  margin-bottom: 14px;
}

.compare-ranges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-dim);
  padding-bottom: 2px;
}

.compare-ranges .range-tag {
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  padding: 4px 10px;
}

.compare-kpis {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}

.delta {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 26, 31, 0.7);
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.delta-label {
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-mute);
}

.delta-value {
  font-family: var(--display);
  font-size: 1.24rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.delta-up { color: #8fce8b; }
.delta-down { color: #e8836a; }
.delta-flat { color: var(--text-dim); }

.empty-note {
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 18px;
  color: var(--text-mute);
  font-size: 0.86rem;
  text-align: center;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(178px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}

.kpi {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(26, 32, 39, 0.9), rgba(21, 26, 31, 0.9));
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  position: relative;
  overflow: hidden;
}

.kpi::after {
  content: "";
  position: absolute;
  right: -28px;
  top: -28px;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(242, 163, 60, 0.22), transparent 68%);
}

.kpi-value {
  font-family: var(--display);
  font-size: 1.72rem;
  font-weight: 600;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.kpi-label {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-mute);
}

.kpi-hint { font-size: 0.76rem; color: var(--text-dim); }

.highlight-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(252px, 1fr));
  gap: 12px;
  margin-bottom: 26px;
}

.highlight {
  border: 1px solid rgba(242, 163, 60, 0.24);
  border-radius: var(--radius);
  background: linear-gradient(140deg, rgba(242, 163, 60, 0.12), rgba(21, 26, 31, 0.9) 62%);
  padding: 16px 18px;
}

.highlight .kpi-label { color: var(--amber); }

.highlight-name {
  font-family: var(--display);
  font-size: 1.24rem;
  font-weight: 600;
  line-height: 1.25;
  margin: 4px 0 2px;
}

.highlight-sub { font-size: 0.8rem; color: var(--text-dim); }

.chart-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 26px;
}

.chart-wide { grid-column: 1 / -1; }

.chart-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 26, 31, 0.7);
  padding: 18px;
}

.chart-head { margin-bottom: 14px; }

.chart-head h3 {
  margin: 0;
  font-family: var(--display);
  font-size: 1.12rem;
  font-weight: 600;
}

.chart-head p { margin: 2px 0 0; font-size: 0.78rem; color: var(--text-mute); }

.chart-box { position: relative; height: 300px; }
.chart-box-tall { height: 380px; }

.stats-lists {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 14px;
  margin-bottom: 22px;
}

.list-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(21, 26, 31, 0.7);
  padding: 18px;
}

.list-card h3 {
  margin: 0;
  font-family: var(--display);
  font-size: 1.06rem;
  font-weight: 600;
}

.data-list { margin-top: 12px; }

.data-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px dashed var(--line);
  font-size: 0.86rem;
}

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

.data-row .row-name { font-weight: 500; }
.data-row .row-sub { display: block; font-size: 0.72rem; color: var(--text-mute); }
.data-row .row-value { color: var(--amber-soft); font-weight: 700; font-variant-numeric: tabular-nums; }

.coverage-panel {
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  padding: 18px 20px;
  color: var(--text-dim);
  font-size: 0.86rem;
  background: rgba(16, 20, 24, 0.5);
}

.coverage-panel h3 {
  margin: 0 0 8px;
  font-family: var(--display);
  font-size: 1.04rem;
  color: var(--text);
  font-weight: 600;
}

.coverage-panel p { margin: 0 0 8px; }
.coverage-panel p:last-child { margin-bottom: 0; }

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  padding-block: 26px 40px;
  color: var(--text-mute);
  font-size: 0.8rem;
}

.site-footer p { margin: 0 0 6px; }
.site-footer strong { color: var(--text-dim); }

/* ---------- leaflet tweaks ---------- */

.leaflet-container { background: #0e1114; font-family: var(--sans); }

/* OSM-Kacheln sind hell; das hier legt sie in das Dunkel-Design um.
   Wichtig: die Filter-Eigenschaft darf nicht auf .leaflet-tile-pane sitzen —
   sie erzeugt einen containing block und zerstört Leaflets Kachel-Positionierung.
   Direkt auf den Kachel-Bildern ist es unschädlich. */
.leaflet-tile-pane.tiles-dark .leaflet-tile {
  filter: invert(92%) hue-rotate(180deg) brightness(78%) contrast(108%) saturate(62%);
}

.leaflet-control-attribution {
  background: rgba(11, 13, 15, 0.78) !important;
  color: var(--text-mute) !important;
  font-size: 0.66rem !important;
}

.leaflet-control-attribution a { color: var(--amber-soft) !important; }

.leaflet-bar a {
  background: rgba(16, 20, 24, 0.92) !important;
  color: var(--text) !important;
  border-bottom-color: var(--line) !important;
}

.leaflet-bar a:hover { background: rgba(242, 163, 60, 0.22) !important; }

.leaflet-popup-content-wrapper,
.leaflet-popup-tip {
  background: rgba(15, 18, 22, 0.97);
  color: var(--text);
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  box-shadow: var(--shadow);
}

.leaflet-popup-content { margin: 14px 16px; font-size: 0.84rem; line-height: 1.5; }

.popup-title {
  font-family: var(--display);
  font-size: 1.04rem;
  font-weight: 600;
  margin: 0 0 2px;
}

.popup-sub { color: var(--text-mute); font-size: 0.76rem; margin: 0 0 8px; }

.popup-rows { display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }

.popup-row {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  font-size: 0.8rem;
}

.popup-row span:last-child { color: var(--amber-soft); font-weight: 600; }

.popup-tags { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }

.popup-tag {
  font-size: 0.66rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--amber);
  border: 1px solid rgba(242, 163, 60, 0.28);
  border-radius: 999px;
  padding: 2px 8px;
}

.popup-note {
  margin: 8px 0 0;
  font-size: 0.7rem;
  color: var(--text-mute);
  font-style: italic;
}

.popup-link { color: var(--amber-soft); }

/* ---------- responsive ---------- */

@media (max-width: 1080px) {
  .map-layout { grid-template-columns: 1fr; }
  .map-canvas { height: clamp(400px, 56vh, 560px); }
  .map-side { order: 2; }
}

@media (max-width: 900px) {
  .toolbar { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chart-grid { grid-template-columns: 1fr; }
  .chart-wide { grid-column: auto; }
  .chart-box { height: 280px; }
  .chart-box-tall { height: 320px; }
  .filter-bar { gap: 12px; }
  .filter-wide { flex-basis: 100%; }
}

@media (max-width: 640px) {
  .site-header { align-items: flex-start; }
  .head-figure { text-align: left; border-right: 0; border-left: 2px solid var(--amber); padding: 0 0 0 12px; }
  .toolbar { grid-template-columns: 1fr; }
  .beer-grid { grid-template-columns: 1fr; }
  .chart-box { height: 250px; }
  .chart-box-tall { height: 280px; }
  .side-title-row { flex-direction: column; align-items: flex-start; }
  .filter-bar { flex-direction: column; align-items: stretch; }
  .btn-small { align-self: stretch; }
  .month-range select { min-width: 0; flex: 1; }
  .compare-ranges { flex-direction: column; }
}

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