/* Analytics › Website (v237, public/website.js). Nur Variablen aus styles.css, damit der Nachtmodus von selbst passt. */

.ws-leiste { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 16px; margin-bottom: 18px; }
.ws-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.ws-chip {
  min-height: 38px; padding: 7px 14px; border-radius: var(--r-pille);
  border: 1.5px solid var(--line); background: var(--weiss); color: var(--text);
  font: inherit; font-size: var(--fs-fein); font-weight: 600; cursor: pointer;
}
.ws-chip:hover { border-color: var(--lilat); }
.ws-chip[aria-pressed="true"] { background: var(--lila); border-color: var(--lila); color: #fff; }
.ws-modus { display: inline-flex; align-items: center; gap: 8px; }
.ws-seg { display: inline-flex; background: var(--soft); border-radius: var(--r-pille); padding: 4px; }
.ws-seg button {
  min-height: 36px; padding: 7px 14px; border: 0; border-radius: var(--r-pille); background: none;
  font: inherit; font-size: var(--fs-fein); font-weight: 600; color: var(--tsoft); cursor: pointer;
}
.ws-seg button[aria-pressed="true"] { background: var(--weiss); color: var(--lilat); box-shadow: 0 1px 4px rgba(13, 6, 19, .14); }
.ws-eigen { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; width: 100%; }
.ws-eigen[hidden] { display: none; }
.ws-eigen label { display: flex; flex-direction: column; gap: 4px; font-size: var(--fs-fein); font-weight: 600; color: var(--tsoft); }
.ws-eigen input {
  min-height: 38px; padding: 7px 10px; border: 1.5px solid var(--feldrand); border-radius: var(--r2);
  background: var(--weiss); color: var(--text); font: inherit; font-size: 16px; /* unter 16 px zoomt iOS beim Antippen hinein */
}

/* Das Fragezeichen: 24 px (Fingerziel-Mindestmaß des Messstands), Trefferfläche 32 px (Finger am iPad). */
.ws-hilfe {
  position: relative; display: inline-flex; align-items: center; justify-content: center; flex: none;
  width: 24px; height: 24px; padding: 0; border-radius: 50%; vertical-align: middle;
  border: 1.5px solid var(--feldrand); background: var(--weiss); color: var(--lilat);
  font: 700 13px/1 Poppins, system-ui, sans-serif; cursor: pointer;
}
.ws-hilfe::before { content: ''; position: absolute; inset: -4px; }
.ws-hilfe:hover, .ws-hilfe[aria-expanded="true"] { background: var(--lila); border-color: var(--lila); color: #fff; }
.an-kpi .l .ws-hilfe { margin-left: 2px; }
#ws-pop {
  position: fixed; z-index: 130; width: max-content; max-width: min(340px, calc(100vw - 24px));
  padding: 12px 14px; border-radius: var(--r2); border: 1px solid var(--line);
  background: var(--ink); color: #fff; box-shadow: var(--shadow-lg);
  font-size: var(--fs-fein); line-height: 1.5;
}
#ws-pop b { display: block; margin-bottom: 4px; font-size: var(--fs-text); }
#ws-pop p { margin: 0; }
html.nacht #ws-pop { background: var(--soft); color: var(--text); }

/* Verlauf */
.ws-balken { display: flex; align-items: flex-end; gap: 3px; height: 190px; padding-top: 18px; border-bottom: 1px solid var(--line); cursor: pointer; touch-action: pan-y; }
.ws-balken:focus-visible { outline: 2px solid var(--lilat); outline-offset: 4px; border-radius: 4px; }
.ws-b {
  position: relative; flex: 1 1 0; min-width: 0; height: var(--h); padding: 0; border: 0;
  border-radius: 4px 4px 0 0; background: var(--lila);
}
.ws-b.teil { opacity: .45; }
.ws-b.leer { height: 3px; background: var(--line); }
.ws-b:hover, .ws-b.aktiv { background: var(--lila2); }
html.nacht .ws-b { background: #8a5cd6; } /* #6027A6 hat auf der dunklen Karte nur ~1,9:1 */
html.nacht .ws-b:hover, html.nacht .ws-b.aktiv { background: var(--lilat); }
.ws-wert { position: absolute; bottom: 100%; left: 50%; transform: translateX(-50%); padding-bottom: 2px; font-size: var(--fs-mikro); font-weight: 600; color: var(--tsoft); white-space: nowrap; }
.ws-achse { display: flex; gap: 3px; margin-top: 6px; }
.ws-achse span { flex: 1 1 0; min-width: 0; overflow: visible; white-space: nowrap; text-align: center; font-size: var(--fs-mikro); line-height: 1.25; color: var(--tsoft); }
.ws-auswahl { min-height: 1.5em; margin: 12px 0 0; font-size: var(--fs-fein); color: var(--tsoft); }

/* Seiten */
.ws-such { max-width: none; margin-bottom: 8px; }
table.ws-seiten tbody tr { cursor: default; }
table.ws-seiten td { padding: 9px 8px; }
.ws-name { font-weight: 600; overflow-wrap: anywhere; }
.ws-pfad { display: block; font-size: var(--fs-mikro); color: var(--tsoft); overflow-wrap: anywhere; text-decoration: none; }
a.ws-pfad { display: inline-block; min-width: 24px; padding: 5px 0; } /* „/“ allein wäre als Link nur 4 px breit */
a.ws-pfad:hover { color: var(--lilat); text-decoration: underline; }
.ws-anteil { width: 92px; }
.ws-anteil i, .ws-zeile i { display: block; height: 6px; border-radius: 3px; background: var(--soft); overflow: hidden; }
.ws-anteil i { margin-top: 5px; }
.ws-anteil b, .ws-zeile b { display: block; height: 100%; border-radius: 3px; background: var(--lila); }
html.nacht .ws-anteil b, html.nacht .ws-zeile b { background: var(--lilat); }
.ws-mehr { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 12px 0 0; font-size: var(--fs-fein); color: var(--tsoft); }
.ws-mehr:empty { display: none; }

/* Filter, Geräte, Länder */
.ws-trichter { display: grid; gap: 2px; }
.ws-f { display: grid; grid-template-columns: minmax(0, 1fr) auto 40px; align-items: baseline; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: var(--fs-text); }
.ws-f b { font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; }
.ws-f small { text-align: right; color: var(--tsoft); font-size: var(--fs-fein); }
.ws-f.minus span { padding-left: 12px; color: var(--tsoft); }
.ws-f.ende { border-bottom: 0; font-weight: 700; color: var(--lilat); }
.ws-neben { margin-top: 18px; }
.ws-liste { display: grid; gap: 10px; }
.ws-zeile { display: grid; grid-template-columns: minmax(5.5em, 42%) minmax(30px, 1fr) 40px; align-items: center; gap: 8px; font-size: var(--fs-text); }
.ws-zeile span { overflow-wrap: anywhere; line-height: 1.3; } /* „Vereinigte Staaten“ bricht lieber um, als abgeschnitten zu werden */
.ws-zeile i { height: 8px; }
.ws-zeile small { text-align: right; color: var(--tsoft); font-size: var(--fs-fein); }
.ws-fuss { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin: 18px 0 4px; font-size: var(--fs-fein); color: var(--tsoft); }

@media (max-width: 640px) {
  .ws-leiste { padding: 14px; }
  .ws-chip { padding: 7px 12px; }
  .ws-balken { height: 150px; gap: 2px; }
  .ws-achse { gap: 2px; }
  .ws-anteil { width: 64px; }
}
.ws-balken.ohne-werte .ws-wert { display: none; }
