/* ==========================================================================
   WeatherHere – Stylesheet
   Designsystem von OnThisDay (an ck1969.de angelehnt), ergänzt um
   Himmelsfarben für die Wetterkarte.
   ========================================================================== */

:root {
  --bg: #f7f8fa;
  --surface: rgba(255, 255, 255, 0.82);
  --surface-strong: #ffffff;
  --surface-soft: #eef2f4;
  --text: #16202a;
  --muted: #5f6d7a;
  --faint: #8a97a4;
  --line: rgba(22, 32, 42, 0.12);

  --blue: #007AFF;
  --green: #2EBF78;
  --teal: #1B8E85;
  --purple: #5E5CE6;
  --amber: #C77C21;
  --red: #E5484D;

  --shadow-sm: 0 10px 30px rgba(17, 24, 39, 0.08);
  --shadow-md: 0 16px 48px rgba(17, 24, 39, 0.10);
  --shadow-lg: 0 24px 80px rgba(17, 24, 39, 0.14);
  --radius-lg: 28px;
  --radius-md: 20px;
  --radius-sm: 14px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1419;
    --surface: rgba(25, 31, 38, 0.82);
    --surface-strong: #171d24;
    --surface-soft: #222a33;
    --text: #edf3f8;
    --muted: #aab8c5;
    --faint: #7d8b99;
    --line: rgba(237, 243, 248, 0.12);
    --amber: #E8A33D;
    --shadow-sm: 0 10px 30px rgba(0, 0, 0, 0.22);
    --shadow-md: 0 16px 48px rgba(0, 0, 0, 0.28);
    --shadow-lg: 0 24px 80px rgba(0, 0, 0, 0.34);
  }
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; background: var(--surface-soft); }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(0, 122, 255, 0.10), transparent 28%),
    radial-gradient(circle at top right, rgba(46, 191, 120, 0.10), transparent 30%),
    radial-gradient(circle at 50% 120%, rgba(94, 92, 230, 0.10), transparent 40%),
    linear-gradient(180deg, var(--bg), var(--surface-soft));
  background-repeat: no-repeat;
  min-height: 100vh;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
a { color: inherit; }
[hidden] { display: none !important; }

::selection { background: rgba(0, 122, 255, 0.22); }

:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--blue) 65%, transparent);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 20px 80px; }
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--surface-strong); padding: 12px 18px; border-radius: 0 0 12px 0;
}
.skip-link:focus { left: 0; }

/* --------------------------------------------------------------------------
   Kopfleiste
   -------------------------------------------------------------------------- */

.topbar {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background: color-mix(in srgb, var(--bg) 74%, transparent);
  border-bottom: 1px solid var(--line);
}
.topbar-inner {
  max-width: 1120px; margin: 0 auto; padding: 14px 20px;
  display: flex; align-items: center; justify-content: space-between; gap: 18px;
}
.topbar-right { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; min-height: 44px; }
.brand-mark {
  width: 42px; height: 42px; flex: 0 0 42px;
  display: grid; place-items: center;
  filter: drop-shadow(0 6px 16px rgba(17, 24, 39, 0.16));
}
.brand-mark svg { width: 42px; height: 42px; display: block; }
.brand-text strong { display: block; font-size: .98rem; letter-spacing: -0.01em; }
.brand-text span { display: block; color: var(--muted); font-size: .84rem; }

nav ul { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
nav a {
  text-decoration: none; min-height: 44px; display: inline-flex; align-items: center;
  padding: 10px 14px; border-radius: 999px; border: 1px solid transparent;
  color: var(--muted); font-size: .93rem; transition: background .18s, color .18s, border-color .18s;
}
nav a:hover, nav a:focus-visible { border-color: var(--line); color: var(--text); background: var(--surface); }
nav a.is-cta { color: #fff; background: linear-gradient(135deg, var(--blue), var(--teal)); font-weight: 650; }
nav a.is-cta:hover { color: #fff; filter: brightness(1.06); }

/* Sprachschalter: zwei Knöpfe in einer Pille */
.lang-switch {
  display: inline-flex; padding: 3px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
}
.lang-switch a {
  min-width: 40px; min-height: 36px; display: inline-grid; place-items: center;
  padding: 0 10px; border-radius: 999px; text-decoration: none;
  font-size: .82rem; font-weight: 750; letter-spacing: .04em; color: var(--muted);
  transition: background .16s, color .16s;
}
.lang-switch a:hover { color: var(--text); }
.lang-switch a.is-active { background: var(--text); color: var(--bg); }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero { padding: 56px 0 12px; display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 44px; align-items: center; }

.pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 14px 7px 10px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  font-size: .82rem; font-weight: 600; color: var(--muted);
  box-shadow: var(--shadow-sm);
}
.pill .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--green); box-shadow: 0 0 0 4px color-mix(in srgb, var(--green) 22%, transparent);
}

.hero h1 {
  margin: 20px 0 0;
  font-size: clamp(2.3rem, 5.2vw, 3.5rem);
  line-height: 1.06; letter-spacing: -0.035em; font-weight: 800;
}
.grad {
  background: linear-gradient(115deg, var(--blue), var(--teal) 45%, var(--purple));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero .lead { margin: 20px 0 0; font-size: 1.11rem; color: var(--muted); max-width: 56ch; }

.hero-actions { margin-top: 28px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; }

.hero-meta { margin-top: 26px; display: flex; gap: 26px; flex-wrap: wrap; }
.hero-meta div strong { display: block; font-size: 1.35rem; letter-spacing: -0.02em; }
.hero-meta div span { font-size: .84rem; color: var(--muted); }

/* Wetterkarte im Hero – wie der Kopf der Mail */
.wx-card {
  position: relative; overflow: hidden; color: #fff;
  border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  background: #5b6b80 center / cover no-repeat;
  padding: 24px 24px 22px; text-align: center; min-height: 380px;
  display: flex; flex-direction: column;
}
.wx-card::after {
  content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 55%, rgba(4, 12, 28, .28));
}
.wx-card > * { position: relative; z-index: 1; }
.wx-card, .wx-card * { text-shadow: 0 1px 14px rgba(0, 0, 0, .25); }
.wx-top { display: flex; justify-content: space-between; align-items: center; font-size: .84rem; font-weight: 600; opacity: .95; }
.wx-top span:first-child { display: inline-flex; align-items: center; gap: 7px; }
.wx-live { width: 8px; height: 8px; border-radius: 50%; background: #7CF2B4; box-shadow: 0 0 0 4px rgba(124, 242, 180, .25); }
.wx-place { margin-top: 22px; font-size: 1.85rem; font-weight: 650; letter-spacing: -0.02em; line-height: 1.15; }
.wx-region { font-size: .9rem; opacity: .85; }
.wx-temp { font-size: 6rem; font-weight: 200; line-height: 1; letter-spacing: -0.04em; margin: 6px 0 2px 1.1rem; }
.wx-cond { font-size: 1.15rem; font-weight: 650; }
.wx-meta { font-size: .95rem; font-weight: 500; opacity: .95; }
.wx-hours {
  margin-top: auto; padding-top: 20px;
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px;
}
.wx-hours div {
  padding: 9px 2px 8px; border-radius: 14px;
  background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .18);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  font-size: .78rem; font-weight: 600;
}
.wx-hours img { width: 30px; height: 30px; margin: 5px auto; }
.wx-hours strong { display: block; font-size: 1rem; }

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  text-decoration: none; min-height: 48px; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 22px; border-radius: 16px; font-weight: 700; font-size: .97rem;
  border: 1px solid var(--line); font-family: inherit;
  transition: transform .16s ease, filter .16s ease, background .16s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary {
  background: linear-gradient(135deg, var(--blue), var(--teal));
  color: #fff; border-color: transparent; box-shadow: 0 12px 30px rgba(0, 122, 255, 0.28);
}
.btn-primary:hover { filter: brightness(1.06); }
.btn-secondary { background: var(--surface-strong); color: var(--text); }
.btn-secondary:hover { background: var(--surface-soft); }
.btn-ghost { background: transparent; color: var(--muted); }
.btn-ghost:hover { background: var(--surface); color: var(--text); }
.btn-danger { background: var(--surface-strong); color: var(--red); border-color: color-mix(in srgb, var(--red) 35%, transparent); }
.btn-danger:hover { background: color-mix(in srgb, var(--red) 10%, var(--surface-strong)); }
.btn-sm { min-height: 38px; padding: 8px 14px; font-size: .86rem; border-radius: 11px; }
.btn[disabled] { opacity: .55; cursor: not-allowed; transform: none; }

/* --------------------------------------------------------------------------
   Karten und Abschnitte
   -------------------------------------------------------------------------- */

.card {
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--surface); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  box-shadow: var(--shadow-lg);
}
.card-pad { padding: 30px; }

.section { padding-top: 64px; }
.section-head { max-width: 62ch; }
.kicker {
  font-size: .78rem; text-transform: uppercase; letter-spacing: .1em;
  color: var(--muted); font-weight: 800;
}
.section h2 { margin: 8px 0 0; font-size: clamp(1.6rem, 3vw, 2.1rem); letter-spacing: -0.028em; }
.section > .section-head > p { color: var(--muted); margin: 12px 0 0; }

/* --------------------------------------------------------------------------
   Ablauf in drei Schritten
   -------------------------------------------------------------------------- */

.steps { margin-top: 28px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step {
  padding: 26px; border: 1px solid var(--line); border-radius: var(--radius-lg);
  background: var(--surface); backdrop-filter: blur(18px); box-shadow: var(--shadow-sm);
}
.step-no {
  width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center;
  font-weight: 800; font-size: 1.05rem; color: #fff; margin-bottom: 14px;
}
.step:nth-child(1) .step-no { background: linear-gradient(135deg, var(--blue), var(--teal)); }
.step:nth-child(2) .step-no { background: linear-gradient(135deg, var(--green), var(--teal)); }
.step:nth-child(3) .step-no { background: linear-gradient(135deg, var(--purple), var(--blue)); }
.step h3 { margin: 0 0 6px; font-size: 1.1rem; letter-spacing: -0.02em; }
.step p { margin: 0; color: var(--muted); font-size: .95rem; }

/* --------------------------------------------------------------------------
   Formular
   -------------------------------------------------------------------------- */

.signup { margin-top: 28px; }
.signup-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; }
.signup-form { padding: 34px; min-width: 0; }
.signup-side {
  padding: 34px; border-left: 1px solid var(--line);
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
  background:
    radial-gradient(circle at 80% 0%, color-mix(in srgb, var(--blue) 14%, transparent), transparent 55%),
    var(--surface-soft);
}
.signup-side h3 { margin: 0 0 14px; font-size: 1.05rem; letter-spacing: -0.02em; }
.check-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 13px; }
.check-list li { display: flex; gap: 11px; font-size: .93rem; color: var(--muted); line-height: 1.55; }
.check-list svg { flex: 0 0 20px; margin-top: 2px; color: var(--green); }

.field { margin-bottom: 22px; min-width: 0; }
.field > label, .field > .label, .field legend {
  display: block; font-size: .84rem; font-weight: 700; letter-spacing: .02em;
  margin-bottom: 8px; color: var(--text);
}
.field .hint { display: block; font-weight: 500; color: var(--muted); font-size: .82rem; margin-top: 7px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.input, select.input {
  width: 100%; font: inherit; font-size: 1rem; color: var(--text);
  padding: 14px 16px; min-height: 52px;
  border-radius: var(--radius-sm); border: 1px solid var(--line);
  background: var(--surface-strong);
  transition: border-color .16s, box-shadow .16s;
  -webkit-appearance: none; appearance: none;
}
.input::placeholder { color: var(--faint); }
.input:focus {
  outline: none; border-color: color-mix(in srgb, var(--blue) 60%, transparent);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--blue) 16%, transparent);
}
.input[aria-invalid="true"] { border-color: color-mix(in srgb, var(--red) 60%, transparent); }

/* Ortssuche mit Vorschlagsliste */
.place-search { position: relative; }
.place-search .input { padding-left: 46px; padding-right: 54px; }
.place-icon { position: absolute; left: 15px; top: 16px; color: var(--faint); pointer-events: none; }
.locate-btn {
  position: absolute; right: 6px; top: 6px; width: 40px; height: 40px;
  display: grid; place-items: center; border-radius: 11px; cursor: pointer;
  border: 0; background: transparent; color: var(--blue);
  transition: background .16s;
}
.locate-btn:hover { background: color-mix(in srgb, var(--blue) 10%, transparent); }
.locate-btn.is-busy svg { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.place-list {
  position: absolute; left: 0; right: 0; top: calc(100% + 6px); z-index: 30;
  list-style: none; margin: 0; padding: 6px;
  background: var(--surface-strong); border: 1px solid var(--line);
  border-radius: var(--radius-md); box-shadow: var(--shadow-lg);
  max-height: 340px; overflow-y: auto;
}
.place-list li {
  display: flex; gap: 12px; align-items: center;
  padding: 10px 12px; border-radius: 12px; cursor: pointer;
}
.place-list li[aria-selected="true"], .place-list li:hover { background: color-mix(in srgb, var(--blue) 10%, var(--surface-strong)); }
.place-list .flag { font-size: 1.35rem; line-height: 1; width: 1.6rem; text-align: center; }
.place-list strong { display: block; font-size: .98rem; }
.place-list em { display: block; font-style: normal; font-size: .84rem; color: var(--muted); }
.place-list .empty { color: var(--muted); font-size: .9rem; cursor: default; }
.place-list .empty:hover { background: transparent; }

.place-chosen {
  display: flex; gap: 10px; align-items: center; margin: 10px 0 0;
  padding: 10px 14px; border-radius: 12px; font-size: .92rem; color: var(--muted);
  background: color-mix(in srgb, var(--green) 9%, var(--surface-strong));
  border: 1px solid color-mix(in srgb, var(--green) 30%, transparent);
}
.place-chosen strong { color: var(--text); }
.place-chosen .flag { font-size: 1.25rem; line-height: 1; }

.choices, .tz-choice { border: 0; margin: 12px 0 0; padding: 0; display: grid; gap: 8px; }
.choices legend, .tz-choice legend { margin-bottom: 8px; }
.choice, .tz-choice label {
  display: flex; gap: 10px; align-items: center; cursor: pointer;
  padding: 10px 14px; border-radius: 12px; border: 1px solid var(--line);
  background: var(--surface-strong); font-size: .93rem;
}
.choice em { font-style: normal; color: var(--muted); margin-left: 4px; }
.choice input, .tz-choice input { accent-color: var(--blue); width: 18px; height: 18px; flex: 0 0 18px; }

/* Umschalter mit zwei Möglichkeiten */
.segmented {
  display: flex; padding: 4px; gap: 4px; border-radius: 15px;
  border: 1px solid var(--line); background: var(--surface-soft);
}
.segmented label { flex: 1; position: relative; cursor: pointer; }
.segmented input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.segmented span {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  min-height: 42px; padding: 6px 10px; border-radius: 11px;
  font-size: .93rem; font-weight: 650; color: var(--muted);
  transition: background .16s, color .16s, box-shadow .16s;
}
.segmented small { font-size: .75rem; font-weight: 600; opacity: .75; }
.segmented input:checked + span { background: var(--surface-strong); color: var(--text); box-shadow: 0 2px 8px rgba(17, 24, 39, .10); }
.segmented input:focus-visible + span { outline: 3px solid color-mix(in srgb, var(--blue) 65%, transparent); outline-offset: 1px; }

.time-row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.time-row .input { max-width: 150px; }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip {
  border: 1px solid var(--line); background: var(--surface-strong); color: var(--muted);
  border-radius: 999px; padding: 8px 14px; font: inherit; font-size: .86rem; font-weight: 650;
  cursor: pointer; min-height: 38px; transition: all .16s;
}
.chip:hover { color: var(--text); border-color: color-mix(in srgb, var(--blue) 40%, var(--line)); }
.chip.is-active {
  background: color-mix(in srgb, var(--blue) 12%, var(--surface-strong));
  border-color: color-mix(in srgb, var(--blue) 45%, transparent); color: var(--blue);
}

.field > label.consent {
  display: flex; gap: 12px; align-items: flex-start; margin: 0;
  font-size: .89rem; font-weight: 500; letter-spacing: 0; color: var(--muted);
}
.consent a { color: var(--text); }
.consent input[type="checkbox"] {
  width: 21px; height: 21px; margin: 2px 0 0; flex: 0 0 21px; accent-color: var(--blue); cursor: pointer;
}
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Liste „Deine Orte“ auf der Einstellungsseite */
.place-subs { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.place-subs a {
  display: flex; gap: 11px; align-items: flex-start; text-decoration: none;
  padding: 11px 13px; border-radius: 14px; border: 1px solid var(--line);
  background: var(--surface-strong); transition: border-color .16s;
}
.place-subs a:hover { border-color: color-mix(in srgb, var(--blue) 40%, var(--line)); }
.place-subs .is-current a { border-color: color-mix(in srgb, var(--blue) 55%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--blue) 14%, transparent); }
.place-subs .flag { font-size: 1.3rem; line-height: 1.2; }
.place-subs strong { display: block; font-size: .95rem; }
.place-subs em { display: block; font-style: normal; font-size: .8rem; color: var(--muted); line-height: 1.45; }
.place-subs em strong { display: inline; font-size: inherit; }

/* --------------------------------------------------------------------------
   Meldungen
   -------------------------------------------------------------------------- */

.alert {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 16px 18px; border-radius: var(--radius-md);
  border: 1px solid var(--line); background: var(--surface-strong);
  margin-bottom: 22px; font-size: .95rem; box-shadow: var(--shadow-sm);
}
.alert > div > strong { display: block; margin-bottom: 3px; }
.alert p strong { color: var(--text); }
.alert p { margin: 0; color: var(--muted); }
.alert-icon { flex: 0 0 24px; margin-top: 1px; }
.alert-success { border-color: color-mix(in srgb, var(--green) 45%, transparent); background: color-mix(in srgb, var(--green) 8%, var(--surface-strong)); }
.alert-success .alert-icon { color: var(--green); }
.alert-error { border-color: color-mix(in srgb, var(--red) 45%, transparent); background: color-mix(in srgb, var(--red) 8%, var(--surface-strong)); }
.alert-error .alert-icon { color: var(--red); }
.alert-info { border-color: color-mix(in srgb, var(--blue) 40%, transparent); background: color-mix(in srgb, var(--blue) 8%, var(--surface-strong)); }
.alert-info .alert-icon { color: var(--blue); }

/* --------------------------------------------------------------------------
   Vorschau der Mail
   -------------------------------------------------------------------------- */

.preview-card { margin-top: 28px; padding: 12px; position: relative; overflow: hidden; background: #eef2f5; }
@media (prefers-color-scheme: dark) { .preview-card { background: #e9eef2; } }
.preview-frame { display: block; width: 100%; height: 2400px; border: 0; border-radius: 20px; background: #eef2f5; }
.preview-loading {
  position: absolute; inset: 12px; z-index: 2; display: grid; place-items: center;
  border-radius: 20px; background: rgba(238, 242, 245, .72); color: #5f6d7a; font-weight: 650;
  backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px);
}
.preview-loading[hidden] { display: none; }

/* Hinweis auf die Web-App (Startseite) */
.app-teaser { display: flex; gap: 24px; align-items: center; }
.app-teaser-icon svg { width: 64px; height: 64px; filter: drop-shadow(0 10px 24px rgba(0, 122, 255, .28)); }
.app-teaser-text { flex: 1; min-width: 0; }
.app-teaser h2 { margin: 6px 0 4px; font-size: clamp(1.35rem, 2.6vw, 1.7rem); letter-spacing: -0.025em; }
.app-teaser p { margin: 0; color: var(--muted); }
@media (max-width: 720px) { .app-teaser { flex-direction: column; align-items: flex-start; } }

/* --------------------------------------------------------------------------
   Web-App (app.php): nur das Wetter, darüber eine schmale Leiste
   -------------------------------------------------------------------------- */

/* Der Bericht ist hell gestaltet – die App bleibt deshalb immer hell */
body.app-page {
  color-scheme: light;
  --bg: #f7f8fa; --surface: rgba(255, 255, 255, 0.86); --surface-strong: #ffffff; --surface-soft: #eef2f4;
  --text: #16202a; --muted: #5f6d7a; --faint: #8a97a4; --line: rgba(22, 32, 42, 0.12);
  background: #eef2f5; min-height: 100vh;
}
.app-bar {
  position: sticky; top: 0; z-index: 50;
  background: rgba(238, 242, 245, .86); border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
  padding-top: env(safe-area-inset-top);
}
.app-bar-inner {
  max-width: 680px; margin: 0 auto; padding: 10px 12px;
  display: flex; align-items: center; gap: 10px;
}
.app-bar .brand { min-height: 40px; gap: 9px; flex: 0 0 auto; }
.app-bar .brand-mark, .app-bar .brand-mark svg { width: 36px; height: 36px; flex-basis: 36px; }
.app-bar .brand-text strong { font-size: .95rem; }
.app-place { flex: 1; min-width: 0; }
.app-place .field { margin: 0; }
.app-place .field > label, .app-place [data-place-chosen], .app-place [data-place-hint], .app-place .choices { display: none !important; }
.app-place .input { min-height: 42px; padding-top: 9px; padding-bottom: 9px; font-size: .95rem; border-radius: 12px; }
.app-place .place-icon { top: 11px; left: 13px; }
.app-place .place-search .input { padding-left: 40px; padding-right: 44px; }
.app-place .locate-btn { top: 3px; right: 3px; width: 36px; height: 36px; }
.app-switches { display: flex; gap: 6px; align-items: center; flex: 0 0 auto; }
.lang-switch button {
  min-width: 36px; min-height: 34px; padding: 0 8px; border: 0; border-radius: 999px; cursor: pointer;
  background: transparent; font: inherit; font-size: .82rem; font-weight: 750; color: var(--muted);
}
.lang-switch button.is-active { background: var(--text); color: var(--bg); }
.app-bar .lang-switch a { min-width: 36px; min-height: 34px; padding: 0 8px; }
.app-install {
  width: 40px; height: 40px; border-radius: 12px; border: 0; cursor: pointer; display: grid; place-items: center;
  color: #fff; background: linear-gradient(135deg, var(--blue), var(--teal));
}
.app-main { position: relative; max-width: 680px; margin: 0 auto; }
.app-main .preview-loading { inset: 0; border-radius: 0; min-height: 300px; align-items: start; padding-top: 120px; }
.app-frame { display: block; width: 100%; height: 900px; border: 0; background: #eef2f5; }
.app-foot {
  max-width: 680px; margin: 0 auto; padding: 4px 16px calc(24px + env(safe-area-inset-bottom));
  text-align: center; font-size: .8rem; color: var(--faint);
}
.app-foot a { color: var(--muted); text-decoration: none; }
.app-foot a:hover { text-decoration: underline; }

@media (max-width: 560px) {
  .app-bar-inner { flex-wrap: wrap; }
  .app-place { order: 3; flex-basis: 100%; }
  .app-switches { margin-left: auto; }
}

/* --------------------------------------------------------------------------
   Regenradar (Web-App, assets/radar.js)
   -------------------------------------------------------------------------- */

.app-report { min-height: 300px; }
.rdr {
  position: relative; height: 400px; border-radius: 18px; overflow: hidden; isolation: isolate;
  background: #dfe7ee; font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}
.rdr-map { position: absolute; inset: 0; background: #dfe7ee; }
.rdr.is-full { position: fixed; inset: 0; z-index: 3000; height: auto; border-radius: 0; }
html.rdr-lock, html.rdr-lock body { overflow: hidden; }

.rdr-btn {
  position: absolute; top: 12px; right: 12px; z-index: 1000;
  width: 44px; height: 44px; border-radius: 50%; border: 0; cursor: pointer;
  display: grid; place-items: center; color: #fff;
  background: rgba(40, 54, 46, .80); box-shadow: 0 6px 18px rgba(0, 0, 0, .18);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.rdr.is-full .rdr-btn { top: calc(14px + env(safe-area-inset-top)); right: 14px; }
.rdr.is-full .leaflet-top { top: env(safe-area-inset-top); }

.rdr-panel {
  position: absolute; left: 10px; right: 10px; bottom: 22px; z-index: 1000;
  padding: 8px 12px 10px; border-radius: 20px; color: #fff;
  background: rgba(44, 58, 50, .84); box-shadow: 0 10px 28px rgba(0, 0, 0, .22);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
}
.rdr.is-full .rdr-panel { left: 14px; right: 14px; bottom: calc(26px + env(safe-area-inset-bottom)); max-width: 680px; margin: 0 auto; }
.rdr-shortcuts { display: flex; gap: 2px; justify-content: center; overflow-x: auto; scrollbar-width: none; margin-bottom: 4px; }
.rdr-shortcuts::-webkit-scrollbar { display: none; }
.rdr-chip {
  flex: 0 0 auto; border: 0; border-radius: 999px; cursor: pointer; background: transparent; color: #fff;
  padding: 6px 10px; font: 600 .95rem/1.1 inherit; white-space: nowrap;
}
.rdr-chip:hover, .rdr-chip:focus-visible { background: rgba(255, 255, 255, .16); }
.rdr-chip-place { max-width: 50%; overflow: hidden; text-overflow: ellipsis; }

.rdr-row { display: flex; align-items: center; gap: 10px; }
.rdr-play {
  flex: 0 0 42px; width: 42px; height: 42px; border-radius: 50%; cursor: pointer;
  border: 2.5px solid #fff; background: transparent; color: #fff; display: grid; place-items: center; padding: 0;
}
.rdr-time { flex: 0 0 auto; min-width: 66px; font-size: 1.12rem; font-weight: 700; line-height: 1.15; font-variant-numeric: tabular-nums; }
.rdr-time b { display: block; font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; opacity: .8; }
.rdr-tag { display: block; font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #9fd0ff; }
.rdr-track { flex: 1; min-width: 0; --future: 0%; }
.rdr-ends { display: flex; justify-content: space-between; font-size: .76rem; opacity: .75; font-variant-numeric: tabular-nums; }
.rdr-note { margin-top: 4px; text-align: center; font-size: .74rem; opacity: .8; }

/* Zeitleiste: gestreift, der Vorhersage-Teil heller abgesetzt */
.rdr-slider { -webkit-appearance: none; appearance: none; display: block; width: 100%; height: 26px; margin: 0; background: transparent; cursor: pointer; }
.rdr-slider:focus { outline: none; }
.rdr-slider::-webkit-slider-runnable-track {
  height: 16px; border-radius: 8px;
  background:
    repeating-linear-gradient(90deg, transparent 0 4px, rgba(44, 58, 50, .9) 4px 6px),
    linear-gradient(90deg, rgba(255, 255, 255, .72) calc(100% - var(--future)), rgba(159, 208, 255, .55) calc(100% - var(--future)));
}
.rdr-slider::-moz-range-track {
  height: 16px; border-radius: 8px;
  background:
    repeating-linear-gradient(90deg, transparent 0 4px, rgba(44, 58, 50, .9) 4px 6px),
    linear-gradient(90deg, rgba(255, 255, 255, .72) calc(100% - var(--future)), rgba(159, 208, 255, .55) calc(100% - var(--future)));
}
.rdr-slider::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none; width: 9px; height: 24px; margin-top: -4px;
  border-radius: 5px; background: #1f7bff; box-shadow: 0 0 0 2px #fff;
}
.rdr-slider::-moz-range-thumb { width: 9px; height: 24px; border: 0; border-radius: 5px; background: #1f7bff; box-shadow: 0 0 0 2px #fff; }
.rdr-slider:focus-visible::-webkit-slider-thumb { box-shadow: 0 0 0 2px #fff, 0 0 0 5px rgba(31, 123, 255, .5); }

.rdr-status { position: absolute; inset: 0; z-index: 900; display: grid; place-items: center; color: #5f6d7a; font-weight: 600; background: rgba(238, 242, 245, .6); }
.rdr .leaflet-control-attribution { font-size: 10px; background: rgba(255, 255, 255, .7); }
.rdr .leaflet-control-zoom a { width: 34px; height: 34px; line-height: 34px; }

/* Eigener Ort auf dem Radar */
.rdr-pin { position: relative; background: none; border: 0; }
.rdr-pin-icon { position: relative; z-index: 2; display: block; filter: drop-shadow(0 2px 3px rgba(0, 0, 0, .35)); }
.rdr-pin-pulse {
  position: absolute; z-index: 1; left: 50%; bottom: -1px; width: 16px; height: 8px; margin-left: -8px;
  border-radius: 50%; background: rgba(242, 98, 46, .55);
  animation: rdr-pulse 2.2s ease-out infinite;
}
@keyframes rdr-pulse {
  0%   { transform: scale(.6); opacity: .9; }
  100% { transform: scale(3.2); opacity: 0; }
}
.rdr-pin-label {
  position: absolute; z-index: 2; left: 50%; top: 100%; margin-top: 4px; transform: translateX(-50%);
  padding: 2px 8px; border-radius: 999px; white-space: nowrap;
  font: 700 12px/1.4 system-ui, -apple-system, "Segoe UI", sans-serif; color: #16202a;
  background: rgba(255, 255, 255, .92); box-shadow: 0 1px 4px rgba(0, 0, 0, .25);
}
@media (prefers-reduced-motion: reduce) {
  .rdr-pin-pulse { animation: none; opacity: 0; }
}

@media (max-width: 420px) {
  .rdr { height: 380px; }
  .rdr-chip { padding: 6px 7px; font-size: .9rem; }
  .rdr-time { min-width: 58px; font-size: 1rem; }
}

/* --------------------------------------------------------------------------
   FAQ
   -------------------------------------------------------------------------- */

.faq { margin-top: 26px; display: grid; gap: 12px; }
.faq details {
  border: 1px solid var(--line); border-radius: var(--radius-md);
  background: var(--surface); overflow: hidden;
}
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 22px; font-weight: 700; font-size: 1rem;
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: '+'; font-size: 1.4rem; font-weight: 400; color: var(--muted); line-height: 1; transition: transform .2s;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > p { margin: 0; padding: 0 22px 20px; color: var(--muted); font-size: .95rem; }

/* --------------------------------------------------------------------------
   Zustandsseiten (Bestätigung / Abmeldung)
   -------------------------------------------------------------------------- */

.state { max-width: 660px; margin: 60px auto 0; text-align: center; padding: 46px 34px; }
.state-icon {
  width: 76px; height: 76px; border-radius: 24px; margin: 0 auto 22px;
  display: grid; place-items: center; color: #fff;
}
.state-icon.ok { background: linear-gradient(135deg, var(--green), var(--teal)); box-shadow: 0 16px 40px rgba(46, 191, 120, .30); }
.state-icon.info { background: linear-gradient(135deg, var(--blue), var(--purple)); box-shadow: 0 16px 40px rgba(0, 122, 255, .28); }
.state-icon.warn { background: linear-gradient(135deg, #E8A33D, var(--amber)); box-shadow: 0 16px 40px rgba(199, 124, 33, .28); }
.state-icon.err { background: linear-gradient(135deg, #f0666a, var(--red)); box-shadow: 0 16px 40px rgba(229, 72, 77, .26); }
.state h1 { margin: 0; font-size: clamp(1.7rem, 4vw, 2.2rem); letter-spacing: -0.03em; }
.state p { color: var(--muted); margin: 14px 0 0; }
.state .actions { margin-top: 28px; display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.state .actions form { margin: 0; }

/* --------------------------------------------------------------------------
   Fußbereich
   -------------------------------------------------------------------------- */

footer.site {
  margin-top: 70px; padding-top: 26px; border-top: 1px solid var(--line);
  color: var(--muted); font-size: .84rem;
  display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap;
}
footer.site a { color: var(--muted); text-decoration: none; }
footer.site a:hover { color: var(--text); text-decoration: underline; }
footer.site nav ul { gap: 16px; }
footer.site nav a { min-height: 0; padding: 0; border: 0; }
footer.site nav a:hover { background: none; }

/* --------------------------------------------------------------------------
   Inhaltsseiten (Datenschutz)
   -------------------------------------------------------------------------- */

.prose { margin-top: 26px; max-width: 76ch; }
.prose h3 { margin: 26px 0 8px; font-size: 1.1rem; letter-spacing: -0.02em; }
.prose h3:first-child { margin-top: 0; }
.prose p, .prose li { color: var(--muted); }
.prose a { color: var(--blue); }

/* --------------------------------------------------------------------------
   Admin
   -------------------------------------------------------------------------- */

.admin-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding: 44px 0 0; }
.admin-head h1 { margin: 6px 0 0; font-size: clamp(1.7rem, 3.5vw, 2.3rem); letter-spacing: -0.03em; }

.stats { margin-top: 26px; display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.stat {
  padding: 22px; border-radius: var(--radius-md); border: 1px solid var(--line);
  background: var(--surface); box-shadow: var(--shadow-sm);
}
.stat b { display: block; font-size: 2rem; letter-spacing: -0.035em; line-height: 1.1; }
.stat span { font-size: .8rem; color: var(--muted); text-transform: uppercase; letter-spacing: .07em; font-weight: 700; }
.stat.accent-blue b { color: var(--blue); }
.stat.accent-green b { color: var(--green); }
.stat.accent-amber b { color: var(--amber); }
.stat.accent-purple b { color: var(--purple); }
.stat.accent-teal b { color: var(--teal); }

.toolbar { margin-top: 26px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; justify-content: space-between; }
.toolbar form { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.toolbar .input { min-height: 44px; padding: 10px 14px; width: auto; min-width: 240px; }
.toolbar select.input { min-width: 160px; }

.table-card { margin-top: 18px; overflow: hidden; }
.table-scroll { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: .92rem; min-width: 980px; }
table.data th {
  text-align: left; font-size: .72rem; text-transform: uppercase; letter-spacing: .09em;
  color: var(--muted); font-weight: 800; padding: 16px 18px; border-bottom: 1px solid var(--line);
  white-space: nowrap; background: color-mix(in srgb, var(--surface-soft) 60%, transparent);
}
table.data td { padding: 14px 18px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data tbody tr:last-child td { border-bottom: 0; }
table.data tbody tr:hover { background: color-mix(in srgb, var(--blue) 4%, transparent); }
table.data .mail { font-weight: 650; overflow-wrap: anywhere; min-width: 220px; }
table.data .num { font-variant-numeric: tabular-nums; color: var(--muted); white-space: nowrap; }
table.data .place { min-width: 180px; }
table.data .place small { display: block; color: var(--faint); font-size: .78rem; }
table.data .actions { text-align: right; white-space: nowrap; }

.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px;
  font-size: .76rem; font-weight: 750; border: 1px solid var(--line); white-space: nowrap;
}
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge-active { color: var(--green); background: color-mix(in srgb, var(--green) 10%, transparent); border-color: color-mix(in srgb, var(--green) 30%, transparent); }
.badge-pending { color: var(--amber); background: color-mix(in srgb, var(--amber) 10%, transparent); border-color: color-mix(in srgb, var(--amber) 30%, transparent); }

.empty { padding: 56px 24px; text-align: center; color: var(--muted); }
.empty strong { display: block; font-size: 1.1rem; color: var(--text); margin-bottom: 6px; }

.login { max-width: 460px; margin: 8vh auto 0; padding: 38px; }
.login h1 { margin: 0 0 6px; font-size: 1.6rem; letter-spacing: -0.03em; }
.login p.sub { margin: 0 0 26px; color: var(--muted); font-size: .95rem; }

.log-list { list-style: none; margin: 0; padding: 0; font-size: .88rem; }
.log-list li { display: flex; gap: 14px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.log-list li:last-child { border-bottom: 0; }
.log-list time { flex: 0 0 148px; color: var(--faint); font-variant-numeric: tabular-nums; font-size: .82rem; }
.log-list .ev { flex: 0 0 130px; font-weight: 700; font-size: .8rem; color: var(--muted); }
.log-list .msg { flex: 1; color: var(--muted); min-width: 0; word-break: break-word; }

code.snippet {
  display: block; padding: 14px 16px; border-radius: var(--radius-sm);
  background: var(--surface-soft); border: 1px solid var(--line);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: .84rem; word-break: break-all; margin-top: 10px;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 980px) {
  .hero { grid-template-columns: 1fr; gap: 36px; padding-top: 40px; }
  .signup-grid { grid-template-columns: 1fr; }
  .signup-side { border-left: 0; border-top: 1px solid var(--line); border-radius: 0 0 var(--radius-lg) var(--radius-lg); }
  .steps { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 720px) {
  /* Kopfleiste auf dem Handy einzeilig: Marke, Abonnieren, Sprache */
  .topbar-inner { padding-block: 10px; gap: 10px; }
  .topbar nav li:not(.nav-cta) { display: none; }
  .topbar-right { flex-wrap: nowrap; gap: 8px; }
  nav a.is-cta { padding: 9px 14px; min-height: 40px; }
  .lang-switch a { min-width: 34px; min-height: 34px; padding: 0 8px; }
  .log-list li { flex-wrap: wrap; gap: 4px 12px; }
  .log-list time, .log-list .ev { flex: 0 0 auto; }
}

@media (max-width: 420px) {
  .brand-text span { display: none; }
  .brand-mark, .brand-mark svg { width: 36px; height: 36px; flex-basis: 36px; }
}

@media (max-width: 640px) {
  .wrap { padding-inline: 16px; }
  .topbar-inner { padding-inline: 16px; }
  .card, .step, .wx-card { border-radius: 22px; }
  .card-pad, .signup-form, .signup-side { padding: 22px; }
  .state { padding: 34px 22px; }
  .stats { grid-template-columns: 1fr; }
  .field-row { grid-template-columns: 1fr; gap: 0; }
  .wx-temp { font-size: 4.8rem; }
  .wx-hours { grid-template-columns: repeat(4, 1fr); }
  .wx-hours div:nth-child(n+5) { display: none; }
  .preview-card { padding: 6px; border-radius: 22px; }
  .preview-frame { border-radius: 16px; }
  nav a { padding: 10px 11px; }
}
