/* Nur heller Modus. Farben aus App/Ressourcen/Assets.xcassets (Hintergrund, Kachel, AccentColor, Erzeugung) und iOS-Systemfarben */
:root {
  --hintergrund: #F2F2F7;
  --flaeche: #FFFFFF;
  --text: #1C1C1E;
  --text-leise: #6C6C70;
  --linie: rgba(60, 60, 67, .14);
  --akzent: #FA9E33;
  --akzent-text: #B85F00;
  --orange: #FF9500;
  --gelb: #D19400;
  --gruen: #34C759;
  --blau: #007AFF;
  --rot: #FF3B30;
  --lila: #AF52DE;
  /* Zählwerk in Grau statt Schwarz, wie im App-Icon */
  --fenster: #3A3A3C;
  --walze: #55555A;
  --walze-rot: #E0313D;
  --rahmen: #D1D1D6;

  --schrift: ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ziffern: system-ui, -apple-system, "Segoe UI", sans-serif;
  --breite: 1080px;
  --radius: 22px;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--hintergrund);
  color: var(--text);
  font-family: var(--schrift);
  font-size: 1.0625rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--akzent); outline-offset: 3px; border-radius: 8px; }
.versteckt { position: absolute; }

svg {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

h1, h2, h3 { text-wrap: balance; }
h2 {
  font-size: clamp(1.875rem, 4.5vw, 2.75rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0 0 20px;
}
h3 { font-size: 1.1875rem; line-height: 1.3; margin: 0 0 6px; }

/* Kopf */
.kopf {
  max-width: var(--breite);
  margin: 0 auto;
  padding: 20px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.marke { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.125rem; text-decoration: none; }
.marke img { border-radius: 9px; }
.hinweis { color: var(--text-leise); font-size: 0.9375rem; }

main { max-width: var(--breite); margin: 0 auto; padding: 0 16px; }
section { padding: 72px 0; }

/* Held */
.held { display: grid; gap: 48px; padding-top: 32px; }
h1 {
  font-size: clamp(2.25rem, 6vw, 3.75rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 20px;
  max-width: 13ch;
}
.einleitung { font-size: 1.25rem; color: var(--text-leise); max-width: 34ch; margin: 0 0 32px; }
.versprechen { list-style: none; padding: 0; margin: 0 0 28px; display: grid; gap: 10px; }
.versprechen li { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.versprechen svg { color: var(--gruen); stroke-width: 3; font-size: 1.1rem; }
.verfuegbar { margin: 0; font-weight: 600; color: var(--akzent-text); }

/* Rollenzählwerk wie am Stromzähler, läuft live (zaehlwerk.js) */
.zaehlwerk { margin: 0 0 36px; max-width: 420px; }
.zaehlwerk-fenster { display: flex; align-items: flex-end; gap: 12px; }
.walzen {
  display: flex;
  gap: 3px;
  padding: 6px;
  background: var(--fenster);
  border-radius: 12px;
}
.walze {
  --h: clamp(48px, 9vw, 62px);
  width: calc(var(--h) * .62);
  height: var(--h);
  overflow: hidden;
  background: var(--walze);
  border-radius: 5px;
  position: relative;
}
/* Wölbung der Walze */
.walze::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(rgba(0,0,0,.45), transparent 30%, transparent 70%, rgba(0,0,0,.45));
  pointer-events: none;
}
.walze.rot { background: var(--walze-rot); margin-left: 5px; }
.walze-band { display: flex; flex-direction: column; }
.walze-band span {
  height: var(--h);
  display: grid;
  place-items: center;
  color: #FFFFFF;
  font-family: var(--ziffern);
  font-size: calc(var(--h) * .6);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.walze-band.anlauf { transition: transform 1.6s cubic-bezier(.2, .7, .1, 1); }
.einheit { font-weight: 700; font-size: 1.25rem; color: var(--text-leise); padding-bottom: 6px; }

/* Ferraris-Scheibe: ihr Rand im Schlitz, die rote Marke wandert langsam vorbei */
.scheibe {
  margin-top: 14px;
  width: min(100%, 300px);
  height: 14px;
  padding: 3px;
  border-radius: 7px;
  background: var(--fenster);
}
.scheibe-band {
  height: 100%;
  border-radius: 4px;
  background:
    linear-gradient(90deg, transparent 0 46%, var(--walze-rot) 46% 54%, transparent 54% 100%) 0 0 / 100% 100% repeat-x,
    linear-gradient(#E5E5EA, #AEAEB2);
}
.zaehlwerk figcaption { margin-top: 12px; color: var(--text-leise); font-size: 0.9375rem; max-width: 36ch; }

/* iPhone-Rahmen um die Platzhalter-Screenshots */
.telefon {
  justify-self: center;
  width: min(320px, 82vw);
  padding: 10px;
  background: var(--rahmen);
  border-radius: 54px;
  box-shadow: 0 30px 60px -24px rgba(0,0,0,.3);
}
.telefon img { border-radius: 44px; }

/* Prognose */
.prognose { display: grid; gap: 40px; border-top: 1px solid var(--linie); }
.prognose-text p { max-width: 42ch; margin: 0 0 16px; color: var(--text-leise); font-size: 1.1875rem; }

/* Funktionen */
.funktionen { border-top: 1px solid var(--linie); }
.raster { display: grid; gap: 32px; margin-top: 40px; }
.funktion p { margin: 0; color: var(--text-leise); max-width: 36ch; }
.symbol {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-bottom: 14px;
  border-radius: 12px;
  color: #FFFFFF;
  font-size: 1.375rem;
}
.symbol.orange { background: var(--orange); }
.symbol.gelb { background: var(--gelb); }
.symbol.gruen { background: var(--gruen); }
.symbol.blau { background: var(--blau); }
.symbol.rot { background: var(--rot); }
.symbol.lila { background: var(--lila); }

/* Vergleich Gratis und Pro */
.vergleich { border-top: 1px solid var(--linie); }
.vergleich-einleitung { color: var(--text-leise); font-size: 1.1875rem; max-width: 46ch; margin: 0 0 32px; }
.tabelle-rahmen { background: var(--flaeche); border-radius: var(--radius); padding: 8px 20px; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 14px 8px; text-align: left; border-bottom: 1px solid var(--linie); vertical-align: middle; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
thead th { font-size: 0.9375rem; color: var(--text-leise); font-weight: 600; }
thead th.pro { color: var(--akzent-text); }
thead th:not(:first-child) { text-align: center; }
tbody th { font-weight: 500; }
td { width: 24%; text-align: center; color: var(--text-leise); font-size: 0.9375rem; }
td svg { color: var(--gruen); stroke-width: 3; font-size: 1.25rem; }
.vergleich-fuss { color: var(--text-leise); font-size: 0.9375rem; margin: 20px 0 0; }

/* Nur für Screenreader */
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

/* Fuß */
.fuss {
  max-width: var(--breite);
  margin: 0 auto;
  padding: 24px 16px 40px;
  display: flex;
  gap: 24px;
  font-size: 0.9375rem;
  color: var(--text-leise);
}

/* Rechtstexte */
.rechtstext { max-width: 680px; padding-bottom: 64px; }
.rechtstext h1 { font-size: 2.25rem; max-width: none; }
.rechtstext h2 { font-size: 1.375rem; margin-top: 32px; }

@media (min-width: 820px) {
  .held { grid-template-columns: 1.15fr 0.85fr; align-items: center; padding-top: 56px; }
  .prognose { grid-template-columns: 0.85fr 1.15fr; align-items: center; }
  .raster { grid-template-columns: repeat(3, 1fr); gap: 48px 40px; }
}

@media (max-width: 480px) {
  .tabelle-rahmen { padding: 4px 12px; }
  th, td { padding: 12px 4px; }
  tbody th { font-size: 0.9375rem; }
}

@media (prefers-reduced-motion: reduce) {
  .walze-band.anlauf { transition: none; }
}

/* Häufige Fragen */
.fragen { border-top: 1px solid var(--linie); }
.fragen-liste { background: var(--flaeche); border-radius: var(--radius); padding: 4px 20px; margin-top: 32px; }
.fragen details { border-bottom: 1px solid var(--linie); }
.fragen details:last-child { border-bottom: 0; }
.fragen summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 32px 18px 0;
  font-weight: 600;
  position: relative;
}
.fragen summary::-webkit-details-marker { display: none; }
.fragen summary::after {
  content: "+";
  position: absolute;
  right: 4px;
  top: 50%;
  translate: 0 -50%;
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--akzent-text);
  transition: rotate .2s;
}
.fragen details[open] summary::after { rotate: 45deg; }
.fragen details p { margin: 0 0 18px; color: var(--text-leise); max-width: 64ch; }

/* Vorschauseite (bald.html) */
.bald {
  min-height: calc(100vh - 90px);
  max-width: 560px;
  margin: 0 auto;
  padding: 72px 16px 32px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.bald-icon { border-radius: 28px; box-shadow: 0 16px 40px -16px rgba(0,0,0,.3); margin-bottom: 32px; }
.bald h1 { max-width: none; }
.bald .einleitung { margin-left: auto; margin-right: auto; }
.bald .zaehlwerk { display: flex; flex-direction: column; align-items: center; margin-bottom: 28px; }
.bald .zaehlwerk figcaption { margin-left: auto; margin-right: auto; }
.bald-fuss { justify-content: center; }
