/* ════════════════════════════════════════════════════════════════
   BASIS
   Grundregeln für alle Seiten: Schrift, Überschriften, Bilder,
   Knöpfe und Formularfelder.
   Farben, Schriften und Abstände änderst du in einstellungen.css.
   ════════════════════════════════════════════════════════════════ */

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--farbe-hintergrund);
  color: var(--farbe-schrift);
  font-family: var(--schrift-text);
  font-size: var(--groesse-text);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
p { margin: 0 0 24px; }
ul { list-style: none; margin: 0; padding: 0; }
figure { margin: 0; }

/* Große Überschrift */
h1, h2 {
  font-family: var(--schrift-titel);
  font-weight: 400;
  font-size: var(--groesse-titel);
  line-height: 1.1;
  margin: 0 0 32px;
  text-wrap: balance;
}

/* Kleine Überschrift in Großbuchstaben */
h3 {
  font-size: var(--groesse-text);
  font-weight: 400;
  line-height: 1.3;
  letter-spacing: .12em;
  text-transform: uppercase;
  margin: 0 0 8px;
}

::selection { background: var(--farbe-akzent); color: var(--farbe-papier); }
:focus-visible { outline: 1px dashed currentColor; outline-offset: 4px; }


/* ── Hilfsklassen ─────────────────────────────────────────────── */

/* Kleinere Schrift, z. B. für Datumsangaben */
.klein { font-size: var(--groesse-klein); }

/* Nur für Screenreader sichtbar (z. B. die H1 auf der Startseite) */
.nur-vorlesen {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* Das Logo als Fläche, eingefärbt in der Schriftfarbe.
   Einfach einem leeren <div> oder <a> diese Klasse geben und eine Breite setzen. */
.logo-form {
  display: block;
  aspect-ratio: var(--logo-format);
  background: currentColor;
  -webkit-mask: var(--logo) center / contain no-repeat;
  mask: var(--logo) center / contain no-repeat;
}


/* ── Handgeschriebene Überschrift ─────────────────────────
   <h2 class="handschrift titel-menue"><span class="nur-vorlesen">Menü</span></h2>

   Sichtbar ist die PNG, der Text daneben ist für Screenreader und
   Suchmaschinen da. Die PNGs sind schwarz und werden wie das Logo
   automatisch in die Schriftfarbe eingefärbt – Farbe ändern also in
   einstellungen.css (--farbe-schrift), Höhe mit --groesse-handschrift.

   Neue Überschrift: PNG mit durchsichtigem Hintergrund nach
   website/img/ legen und unten eine Zeile ergänzen. */

.handschrift {
  height: var(--groesse-handschrift);
  background: currentColor;
  -webkit-mask: var(--handschrift) left center / contain no-repeat;
  mask: var(--handschrift) left center / contain no-repeat;
}

.titel-menue          { --handschrift: url("../img/titel-menue.png"); }
.titel-studio-alfie   { --handschrift: url("../img/titel-das-studio-alfie.png"); }
.titel-booking-events { --handschrift: url("../img/titel-booking-events.png"); }
.titel-team           { --handschrift: url("../img/titel-team.png"); }
.titel-unsere-idee    { --handschrift: url("../img/titel-unsere-idee.png"); }


/* ── Bilder ───────────────────────────────────────────────────────
   <figure>
     <div class="bild hoch"><img src="img/…" alt="…"></div>
     <figcaption>Bildunterschrift</figcaption>
   </figure>

   Format-Klassen (das Bild wird passend zugeschnitten):
   hoch = 4:5 · quer = 3:2 · quadrat = 1:1 · schmal = 2:3

   Bild im Bild (wie bei Elm): ein zweites, kleineres Bild mittig darauf
   <div class="bild hoch">
     <img src="img/grosses-bild.jpg" alt="…">
     <div class="bild-innen"><img src="img/kleines-bild.jpg" alt="…"></div>
   </div> */

.bild {
  position: relative;
  overflow: hidden;
  aspect-ratio: 4 / 5;
}
.bild.hoch    { aspect-ratio: 4 / 5; }
.bild.quer    { aspect-ratio: 3 / 2; }
.bild.quadrat { aspect-ratio: 1 / 1; }
.bild.schmal  { aspect-ratio: 2 / 3; }

.bild img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(var(--zoom, 1));   /* --zoom setzt main.js beim Scrollen */
  transition: scale .5s;
}

.bild-innen {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 62%;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  translate: -50% -50%;
}

figcaption {
  font-size: var(--groesse-klein);
  margin-top: 8px;
}


/* ── Knopf ─────────────────────────────────────────────────────────
   Großbuchstaben mit feinem Strich darunter.
   <a class="knopf" href="…">Text</a>
   Größer (z. B. zum Absenden):  class="knopf gross" */

.knopf {
  display: inline-block;
  padding: 0 2px;
  font: var(--groesse-klein) / 32px var(--schrift-text);
  letter-spacing: .06em;
  text-transform: uppercase;
  color: inherit;
  background: none;
  border: 0;
  border-bottom: 1px solid currentColor;
  cursor: pointer;
  transition: opacity .3s;
}
.knopf.gross {
  font-size: 20px;
  line-height: 50px;
}
.knopf:hover { opacity: .55; }

/* Mehrere Knöpfe nebeneinander */
.knoepfe {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px 48px;
  margin-top: 16px;
}


/* ── Formularfelder (Stil wie die Formulare bei Elm) ─────────────
   <label class="feld">
     <span>Name *</span>
     <input name="Name" required>
   </label> */

.feld {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 16px;
  line-height: 1.3;
  text-align: left;
}
.feld input:not([type="radio"], [type="checkbox"]),
.feld select,
.feld textarea {
  width: 100%;
  min-height: 50px;
  padding: 12px 22px;
  border: 1px solid transparent;
  border-radius: 30px;
  background: var(--farbe-papier);
  color: var(--farbe-schrift);
  font: inherit;
  font-size: 16px;
}
.feld textarea {
  min-height: 200px;
  resize: vertical;
}
.feld input:focus,
.feld select:focus,
.feld textarea:focus {
  border-color: var(--farbe-schrift);
  outline: 0;
}
.feld ::placeholder { color: var(--farbe-schrift); opacity: .5; }
.feld input[type="date"],
.feld input[type="time"] { accent-color: var(--farbe-schrift); }

/* Auswahlpunkte und Häkchen: runde Kreise in der Schriftfarbe */
.feld legend { padding: 0; margin-bottom: 6px; }
.wahl {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 34px;
  cursor: pointer;
}
.wahl input {
  appearance: none;
  flex-shrink: 0;
  display: grid;
  place-content: center;
  width: 22px;
  height: 22px;
  margin: 0;
  border: 2px solid color-mix(in srgb, var(--farbe-schrift) 35%, transparent);
  border-radius: 50%;
  background: var(--farbe-papier);
  cursor: pointer;
}
.wahl input::before {
  content: "";
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--farbe-schrift);
  scale: 0;
  transition: scale .2s;
}
.wahl input:checked { border-color: var(--farbe-schrift); }
.wahl input:checked::before { scale: 1; }
.wahl a { text-decoration: underline; text-underline-offset: 3px; }


/* ── Einblenden beim Scrollen (main.js vergibt die Klassen) ──── */

.einblenden {
  opacity: 0;
  translate: 0 32px;
  transition: opacity .8s ease, translate .8s ease;
}
.einblenden.sichtbar {
  opacity: 1;
  translate: 0 0;
}


/* Wer in den Systemeinstellungen "Bewegung reduzieren" aktiviert hat,
   bekommt keine Animationen. */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: .01ms !important;
    animation: none !important;
  }
}
