/* ==========================================================================
   RettungsdienstApp – Website
   Alle Schriften werden lokal ausgeliefert (assets/fonts/), es werden keine
   externen Ressourcen geladen.
   ========================================================================== */

/* --- Schrift: Figtree (SIL Open Font License 1.1, siehe assets/fonts/OFL.txt)
       Variable Font, Achse wght 300–900. Lokal gehostet. ------------------- */
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('fonts/figtree-latin-var.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193,
    U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('fonts/figtree-latin-ext-var.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
    U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020,
    U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* --- Tokens ------------------------------------------------------------- */
:root {
  --ink: #141414;
  --ink-soft: #575757;
  --ink-mid: #2b2b2b;
  --ink-light: #606060;
  --line: #ededea;
  --red: #ff4b45;
  --red-dark: #e03b35;
  --red-deep: #c9342e;
  --teal: #0f9b8e;
  --teal-dark: #0b7a6f;
  --teal-deep: #0b6f65;
  --yellow: #f2f200;
  --wrap: 1120px;
  --ease: cubic-bezier(.16, .8, .3, 1);
  --pop: cubic-bezier(.2, .9, .3, 1.2);
}

/* --- Basis --------------------------------------------------------------- */
* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: #fff;
  color: var(--ink);
  font-family: Figtree, 'Helvetica Neue', Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--teal); text-decoration: none; }
a:hover { color: var(--teal-dark); }
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--teal);
  outline-offset: 3px;
  border-radius: 4px;
}

img { display: block; max-width: 100%; height: auto; }

h1, h2, h3 { text-wrap: balance; }
p, li { text-wrap: pretty; }

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding-inline: 24px;
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -60px;
  z-index: 99;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  transition: top .18s ease;
}
.skip-link:focus { top: 12px; color: #fff; }

/* --- Signalstreifen ----------------------------------------------------- */
.stripe {
  height: 5px;
  background-image: repeating-linear-gradient(90deg, var(--yellow) 0 56px, var(--red) 56px 112px);
}
.stripe--tall { height: 8px; }
.stripe--teal {
  background-image: repeating-linear-gradient(90deg, var(--yellow) 0 56px, var(--teal) 56px 112px);
}

/* --- Header ------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .93);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header--static { position: static; }

.site-header__bar {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 13px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  font-size: 16px;
  letter-spacing: .02em;
  text-transform: uppercase;
  color: var(--ink);
}
.brand__icon {
  flex: none;
  width: 26px;
  height: 26px;
  margin-right: 9px; /* kein flex-gap, sonst rutscht auch "App" von der Wortmarke weg */
  border-radius: 50%;
}
.brand:hover { color: var(--ink); }
.brand strong { font-weight: 800; }
.brand span { font-weight: 400; color: #5c5c5c; }

/* --- Hero --------------------------------------------------------------- */
.hero {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 86px 24px 70px;
}
.hero h1 {
  margin: 0;
  max-width: 21ch;
  font-size: clamp(38px, 6.6vw, 70px);
  line-height: 1.02;
  letter-spacing: -.035em;
  font-weight: 800;
}
.hero h1 em {
  font-style: normal;
  color: var(--red);
}
.hero__lead {
  margin: 28px 0 0;
  max-width: 56ch;
  font-size: clamp(17px, 2vw, 21px);
  line-height: 1.5;
  color: var(--ink-soft);
}
.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

/* --- Buttons ------------------------------------------------------------ */
.btn {
  display: inline-flex;
  align-items: center;
  padding: 14px 24px;
  border-radius: 999px;
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  transition: transform .25s var(--pop), box-shadow .25s ease, background .2s ease;
}
.btn:active { transform: translateY(-1px) scale(.99); }

.btn--red { background: var(--red); box-shadow: 0 4px 14px rgba(255, 75, 69, .28); }
.btn--red:hover {
  background: var(--red-dark);
  color: #fff;
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 14px 30px rgba(255, 75, 69, .38);
}

.btn--teal { background: var(--teal); box-shadow: 0 4px 14px rgba(15, 155, 142, .28); }
.btn--teal:hover {
  background: var(--teal-dark);
  color: #fff;
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 14px 30px rgba(15, 155, 142, .38);
}

/* --- Store-Badges ------------------------------------------------------- */
/* Offizielle Badges von Apple und Google, lokal ausgeliefert.
   Beide werden über die Höhe skaliert; das Google-PNG wurde dafür um seinen
   rein transparenten Rand beschnitten, damit die Motive gleich hoch stehen. */
.store-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 34px;
}

.store-badge {
  display: inline-block;
  border-radius: 8px;
  transition: opacity .2s ease;
}
.store-badge:hover { opacity: .78; }

.store-badge img {
  display: block;
  height: 44px;
  width: auto;
}

/* --- App-Sektionen ------------------------------------------------------ */
.app-section { scroll-margin-top: 76px; }
.app-section--rd { background: #fff7f6; border-top: 1px solid #f3ddda; }
.app-section--bos { background: #f3fbfa; border-top: 1px solid #d5ece9; }

.app-grid {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 70px 24px 78px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 56px;
  align-items: center;
}
.app-grid > * { min-width: 0; }

.badge {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
}
.badge--red { background: #ffe3e1; color: var(--red-deep); }
.badge--teal { background: #d3efec; color: var(--teal-deep); }

.app-grid h2 {
  margin: 18px 0 0;
  font-size: clamp(32px, 4.6vw, 48px);
  line-height: 1.04;
  letter-spacing: -.03em;
  font-weight: 800;
}
.app-grid__lead {
  margin: 18px 0 0;
  font-size: 18px;
  line-height: 1.55;
  color: #565656;
  max-width: 46ch;
}

.feature-list {
  list-style: none;
  margin: 28px 0 0;
  padding: 0;
  display: grid;
  gap: 13px;
}
.feature-list li {
  position: relative;
  padding-left: 19px;
  font-size: 16px;
  line-height: 1.45;
  color: var(--ink-mid);
}
.feature-list li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--bullet, var(--red));
}
.app-section--bos .feature-list { --bullet: var(--teal); }

.shot-frame { display: flex; justify-content: center; }
.shot {
  width: 100%;
  max-width: 380px;
  /* Beide Screenshots sind freigestellte Geräte-Mockups mit transparentem
     Hintergrund. drop-shadow folgt der Silhouette; ein box-shadow würde
     einen rechteckigen Schein um das unsichtbare Bildfeld legen.
     Wichtig: drop-shadow entsteht erst mit der dekodierten Bitmap – die
     Bilder dürfen deshalb nicht lazy geladen werden, sonst poppt der
     Schatten beim Heranscrollen auf. */
  filter: drop-shadow(0 16px 30px var(--shot-shadow, rgba(20, 20, 20, .18)));
}
.shot--rd  { --shot-shadow: rgba(201, 52, 46, .20); }
.shot--bos { --shot-shadow: rgba(15, 155, 142, .24); }

/* --- Zitatkarte in der App-Sektion -------------------------------------- */
.quote {
  --accent: var(--red);
  position: relative;
  margin: 30px 0 0;
  padding: 20px 26px 18px;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(20, 20, 20, .05), 0 14px 30px rgba(20, 20, 20, .07);
  overflow: hidden;
}
.app-section--bos .quote { --accent: var(--teal); }

/* farbige Kante links */
.quote::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--accent); /* Fallback für Browser ohne color-mix() */
  background: linear-gradient(180deg, var(--accent), color-mix(in srgb, var(--accent) 55%, #fff));
}

.quote__stars {
  margin: 0 0 10px;
  font-size: 17px;
  letter-spacing: .12em;
  color: #e0a400;
}
/* Goldverlauf, wo unterstützt – sonst bleibt das Gold oben stehen */
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .quote__stars span[aria-hidden] {
    background: linear-gradient(180deg, #ffdc6b 0%, #f2ad00 52%, #d18700 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 1px 0 rgba(255, 255, 255, .6));
  }
}

.quote blockquote {
  margin: 0;
  position: relative;
  z-index: 1;
  font-size: 16.5px;
  line-height: 1.5;
  font-weight: 500;
  color: var(--ink-mid);
}

.quote figcaption {
  margin-top: 14px;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 3px 10px;
  font-size: 13px;
  line-height: 1.4;
}
.quote__author { font-weight: 700; color: var(--ink); }
.quote__meta { color: #7d7d7d; }

/* --- USP-Reihe ---------------------------------------------------------- */
.usp-section { border-top: 1px solid var(--line); }
.usp-grid {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 64px 24px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
}
.usp svg {
  display: block;
  margin: 0 0 12px;
  fill: none;
  stroke: var(--ink);
  stroke-width: 2;
}
.usp h3 {
  margin: 0;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -.015em;
}
.usp p {
  margin: 10px 0 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--ink-light);
}

/* --- Footer ------------------------------------------------------------- */
.site-footer { background: var(--ink); color: #fff; }
.site-footer__bar {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 44px 24px;
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  align-items: center;
  justify-content: space-between;
}
.site-footer--slim .site-footer__bar { padding: 36px 24px; }
.site-footer__copy { font-size: 14px; color: rgba(255, 255, 255, .6); }
.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  font-size: 14px;
  font-weight: 600;
}
.site-footer nav a { color: #fff; display: inline-flex; align-items: center; gap: 8px; }
.site-footer nav a:hover { color: var(--yellow); }
.site-footer nav svg { flex: none; fill: none; stroke: currentColor; stroke-width: 2; }

/* --- Rechtsseiten ------------------------------------------------------- */
.legal {
  max-width: 760px;
  margin: 0 auto;
  padding: 64px 24px 88px;
}
.legal h1 {
  margin: 0;
  font-size: clamp(32px, 5vw, 48px);
  line-height: 1.05;
  letter-spacing: -.03em;
  font-weight: 800;
}
.legal__lead {
  margin: 20px 0 0;
  font-size: 18px;
  line-height: 1.6;
  color: #565656;
  max-width: 52ch;
}
.legal h2 {
  margin: 44px 0 0;
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -.015em;
}
.legal h2 + p { margin: 12px 0 0; }
.legal h2 ~ h2 { margin-top: 36px; }
.legal p {
  font-size: 16px;
  line-height: 1.65;
  color: #3c3c3c;
}
.legal a { text-decoration: underline; text-underline-offset: 2px; }
.legal__note {
  margin: 48px 0 0;
  font-size: 15px;
  line-height: 1.6;
  color: #8a8a8a;
}

/* --- Scroll-Reveal ------------------------------------------------------
   Wird nur aktiv, wenn JavaScript läuft (Klasse .js auf <html>). Ohne JS
   sind alle Inhalte sofort sichtbar – wichtig für Suchmaschinen und
   Screenreader.                                                           */
.js [data-reveal] {
  opacity: 0;
  transition:
    opacity .75s var(--ease) var(--reveal-delay, 0s),
    transform .75s var(--ease) var(--reveal-delay, 0s);
}
/* Nur vertikal: eine seitliche Verschiebung ragt auf schmalen Viewports
   über den Rand hinaus und erzeugt horizontales Scrollen. */
.js [data-reveal='up'] { transform: translateY(26px); }
.js [data-reveal='rise'] { transform: translateY(40px); }

.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

.d1 { --reveal-delay: .1s; }
.d2 { --reveal-delay: .2s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .btn { transition: none; }
  .btn:hover { transform: none; }
  .store-badge { transition: none; }
}
