/*
 * Traum Cafe: Hero
 *
 * Alles, was sich beim Scrollen bewegt, hängt an einer Zahl: --p.
 * --p läuft von 0 (erste Pizza) bis Anzahl-1 (letzte Pizza) und wird von
 * hero.js weich nachgeführt. Jede Pizza und jeder Text kennt seinen Index --i;
 * --d = --p - --i ist der Abstand zur Mitte. Auch das Hintergrundfoto und die
 * Schleierfarbe (--surface) fließen mit --p von Pizza zu Pizza.
 *   --d = 0     Pizza liegt in der Mitte
 *   --d < 0     Pizza kommt von rechts
 *   --d > 0     Pizza rollt nach links hinaus
 */

/* ---------- Schriften (lokal, keine Anfrage an Google) ---------- */

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("../fonts/bricolage-grotesque-latin.woff2") format("woff2");
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Figtree";
  src: url("../fonts/figtree-latin.woff2") format("woff2");
  font-weight: 300 900;
  font-style: normal;
  font-display: swap;
}

@property --p {
  syntax: "<number>";
  inherits: true;
  initial-value: 0;
}

/* Auftritt beim Laden: die erste Pizza rollt von rechts herein (1 -> 0) */
@property --intro {
  syntax: "<number>";
  inherits: true;
  initial-value: 0;
}

/* ---------- Tokens ---------- */

:root {
  color-scheme: light;

  --bg: #f3f3f0;           /* Mehl */
  --ink: #1b1b19;          /* Ofen */
  --muted: #3d3c37;        /* Asche, dunkel genug für Text auf den Fotos */
  --line: rgb(27 27 25 / 0.16);
  --tomato: #b3140e;       /* Logo-Rot, für Flächen */
  --tomato-text: #9e100b;  /* Logo-Rot, für Schrift (etwas dunkler für die Fotos) */
  --on-tomato: #fffdfb;
  --shadow: rgb(48 22 8 / 0.32);

  /* Helle Fassung der Tischfläche je Foto: Marmor, Eiche, Stein, Terrakotta.
     Farbe für Schleier, Kopfzeile und Browserleiste; fließt mit --p mit. */
  --surface-0: #eef0f1;
  --surface-1: #f1e4d3;
  --surface-2: #f3ece4;
  --surface-3: #f6d9c6;
  --surface: color-mix(in oklab, var(--surface-3) calc(clamp(0, var(--p) - 2, 1) * 100%),
             color-mix(in oklab, var(--surface-2) calc(clamp(0, var(--p) - 1, 1) * 100%),
             color-mix(in oklab, var(--surface-1) calc(clamp(0, var(--p), 1) * 100%), var(--surface-0))));

  --font-display: "Bricolage Grotesque", "Arial Narrow", sans-serif;
  --font-body: "Figtree", system-ui, -apple-system, sans-serif;

  --header-h: 4.5rem;
  /* Mittelton des durchgehenden Tischs unter den Abschnitten (sections.css: .tables) */
  --page-table: #e6e3de;
  --gutter: clamp(1rem, 4vw, 3rem);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Basis ---------- */

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

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

/* Große Bildschirme: alles in rem wächst ab 1600 px mit, bis 22 px (bei 2200 px).
   Sonst schrumpft die Seite auf 1920/2560 px zu einer kleinen Insel in der Mitte.
   Prozent statt px, damit eine größere Browser-Schrift weiter gilt. */
@media (min-width: 1600px) {
  html {
    font-size: clamp(100%, 1vw, 137.5%);
  }
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

:focus-visible {
  outline: 3px solid var(--tomato-text);
  outline-offset: 3px;
}

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

.sprite {
  position: absolute;
}

.icon {
  width: 1.25rem;
  height: 1.25rem;
  flex: none;
}

/* ---------- Kopfzeile ---------- */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(max-content, 1fr);
  column-gap: 1.5rem;
  align-items: center;
  height: var(--header-h);
  padding-inline: var(--gutter);
  /* Milchglas: die Tische der Abschnitte scheinen weich durch */
  background: color-mix(in oklab, var(--bg) 80%, transparent);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  transition: background-color 0.3s;
}

/* Über dem Hero durchsichtig; der Schleier im Hero hellt oben weich auf (keine Kante) */
[data-over-hero] .site-header {
  background: transparent;
  -webkit-backdrop-filter: none;
  backdrop-filter: none;
}

.site-nav {
  grid-column: 2;
  grid-row: 1;
}

.site-nav ul {
  display: flex;
  gap: clamp(1.75rem, 3.5vw, 5rem);
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: inline-block;
  padding-block: 0.5rem;
  font-size: 1.0625rem;
  font-weight: 500;
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100% / 0 2px no-repeat;
  transition: background-size 0.35s var(--ease-out);
}

.site-nav a:hover,
.site-nav a[aria-current="page"],
.site-nav a[aria-current="location"] {
  background-size: 100% 2px;
}

/* Logo links (rund, von der bisherigen Website), immer sichtbar, auch über dem Hero */
.site-header__logo {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
  display: block;
  width: calc(var(--header-h) * 0.8);
  aspect-ratio: 1;
  border-radius: 50%;
}

.site-header__logo img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 50%;
}

/* Bestellknopf in der Kopfzeile (Desktop); am Handy übernimmt die Bestellleiste unten */
.site-header__order {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-height: 2.75rem;
  padding: 0 1rem 0 1.15rem;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-size: 0.9375rem;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 0.3s,
    color 0.3s;
}

.site-header__order .icon {
  width: 1rem;
  height: 1rem;
}

.site-header__order:hover {
  background: var(--tomato);
  color: var(--on-tomato);
}

/* Handy und Tablet hochkant: die Bestellleiste unten übernimmt (gleiche Abfrage wie bestellleiste.js) */
@media (max-width: 960px), (max-width: 1199px) and (orientation: portrait) {
  .site-header__order {
    display: none;
  }
}

/* 768–1199 px (Navigation noch als Zeile): sechs Links passen neben Knöpfe und Logo nur enger */
@media (min-width: 768px) and (max-width: 1199px) {
  .site-nav ul {
    gap: 1.25rem;
  }

  .site-nav a {
    font-size: 1rem;
  }
}

.site-header__actions {
  grid-column: 3;
  grid-row: 1;
  justify-self: end;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1.5px solid var(--line);
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  transition:
    background-color 0.25s,
    border-color 0.25s,
    color 0.25s;
}

.icon-button:hover {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--bg);
}

.site-header__toggle {
  display: none;
}

/* ---------- Hero: Rahmen ---------- */

.hero {
  --count: 4;
  --step: 85svh;
  /* Pizza-Durchmesser. 1.3 = Pizza plus Platz für das Bogen-Logo darüber */
  --pizza: clamp(15rem, min(40vw, (100svh - var(--header-h) - 7rem) / 1.3), 40rem);
  --arc-space: calc(var(--pizza) * 0.3);

  position: relative;
  height: calc(100svh + (var(--count) - 1) * var(--step));
}

.hero__stage {
  position: sticky;
  top: 0;
  height: 100svh;
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  padding: var(--header-h) var(--gutter) clamp(1rem, 3svh, 2rem);
  overflow: hidden;
  overflow: clip;
  background: var(--surface);
}

/* Tische übereinander: der untere bleibt stehen, jeder weitere blendet mit --p ein */
.hero__backdrops {
  position: absolute;
  inset: 0;
  z-index: 0;
}

/* Übergang zum durchgehenden Tisch: beim Hinausscrollen läuft der untere Rand des Hero
   in den Ton des Tischs aus (--leave aus hero.js, folgt dem Scrollen) */
.hero__backdrops::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 22svh;
  background: linear-gradient(transparent, var(--page-table));
  opacity: var(--leave, 0);
  pointer-events: none;
}

.no-js .hero__backdrops::after {
  opacity: 1;
}

/* Beim Hinausscrollen: Foto endet 2px über der Unterkante, sonst scheint es an einer
   Bruchpixel-Kante zum Tisch als Haarlinie durch */
:root:not([data-over-hero]) .backdrop {
  clip-path: inset(0 0 2px);
}

.backdrop {
  position: absolute;
  inset: 0;
  overflow: hidden;
  opacity: clamp(0, var(--p) - var(--i) + 1, 1);
}

.backdrop:first-child {
  opacity: 1;
}

.backdrop__surface {
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
}

.backdrop__items {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* Zutat: Schatten und Foto liegen übereinander. Ruhezustand hier im CSS;
   ingredients.js spielt den Fall als Animation ab, die genau hier endet. */
.ingredient {
  position: absolute;
}

.ingredient img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
}

.ingredient__body {
  transform: rotate(var(--rot, 0deg));
}

.ingredient__shadow {
  opacity: 0.3;
  filter: brightness(0) blur(var(--blur, 2px));
  transform: translate(var(--sx, 0px), var(--sy, 0px)) rotate(var(--rot, 0deg));
}

.backdrop__items.is-waiting .ingredient {
  visibility: hidden;
}

.backdrop__veil {
  --veil: color-mix(in oklab, var(--surface) 72%, transparent);
  --veil-soft: color-mix(in oklab, var(--surface) 58%, transparent);

  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(180deg, var(--veil) 0, var(--veil-soft) calc(var(--header-h) * 0.8), transparent calc(var(--header-h) * 1.9)),
    radial-gradient(30% 20% at 50% 15%, var(--veil-soft), transparent),
    linear-gradient(90deg, var(--veil) 0%, var(--veil-soft) 24%, transparent 46%);
}

.hero__grid {
  position: relative;
  z-index: 1;
  align-self: center;
  align-self: safe center;
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--pizza) minmax(0, 1fr);
  column-gap: clamp(2rem, 6vw, 6rem);
  width: min(100%, 90rem);
  margin-inline: auto;
}

/* ---------- Links: Name, Beschreibung, Preis ---------- */

.hero__dishes {
  position: relative;
  z-index: 1;
  container-type: inline-size;
  display: grid;
  align-content: center;
  justify-self: end;
  width: min(100%, 22rem);
  min-height: calc(var(--arc-space) + var(--pizza));
  padding-top: var(--arc-space);
}

.dish {
  --d: calc(var(--p) - var(--i));
  --ad: max(var(--d), var(--d) * -1);

  grid-area: 1 / 1;
  /* voll sichtbar bis |d| = 0.3, unsichtbar genau in der Mitte zwischen zwei Pizzen */
  opacity: clamp(0, (0.5 - var(--ad)) * 5, 1);
  transform: translate3d(0, calc(var(--d) * -2.5rem), 0);
}

.dish__name {
  margin: 0 0 1rem;
  font-family: var(--font-display);
  font-weight: 800;
  font-stretch: 75%;
  /* "MARGHERITA" ist der längste Name und muss in die Spalte passen */
  font-size: clamp(2rem, 18.5cqi, 4.75rem);
  line-height: 0.9;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.dish__desc {
  max-width: 28ch;
  margin: 0 0 1.25rem;
  color: var(--muted);
  font-size: 1.0625rem;
  line-height: 1.55;
  text-wrap: pretty;
}

.dish__price {
  margin: 0;
  color: var(--tomato-text);
  font-size: 1.125rem;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}

/* ---------- Mitte: Bogen-Logo und rollende Pizzen ---------- */

.wheel {
  position: relative;
  padding-top: var(--arc-space);
}

.wheel__arc {
  position: absolute;
  top: calc(var(--arc-space) - var(--pizza) * 0.35);
  left: 50%;
  width: calc(var(--pizza) * 1.7);
  max-width: none;
  overflow: visible;
  translate: -50% 0;
  pointer-events: none;
}

.wheel__arc-title {
  fill: var(--ink);
  font-family: var(--font-display);
  font-size: 92px;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.wheel__arc-sub {
  fill: var(--muted);
  font-family: var(--font-body);
  font-size: 34px;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.wheel__pizzas {
  position: relative;
  width: var(--pizza);
  aspect-ratio: 1;
}

.wheel__roll {
  position: absolute;
  inset: 0;
}

/*
 * Wechsel nacheinander statt nebeneinander: die alte Pizza rollt ein Stück
 * nach links und ist bei |d| = 0.5 verschwunden, danach rollt die neue von
 * rechts herein. Rollweg 0.6 Durchmesser je Schritt, Drehung = Weg / Radius.
 */
.pizza {
  --d: calc(var(--p) - var(--i) - var(--intro));
  --ad: max(var(--d), var(--d) * -1);

  position: absolute;
  inset: 0;
  margin: 0;
  opacity: clamp(0, (0.5 - var(--ad)) * 4, 1);
  transform:
    translate3d(calc(var(--d) * -0.6 * var(--pizza)), 0, 0)
    scale(calc(1 - min(var(--ad), 1) * 0.3));
  will-change: transform, opacity;
}

/* Lädt die Seite mitten im Hero, rollt nur die vordere Pizza herein */
.pizza[aria-hidden] {
  --intro: 0;
}

.pizza::before {
  content: "";
  position: absolute;
  inset: 6% -3% -8%;
  z-index: -1;
  border-radius: 50%;
  background: radial-gradient(closest-side, var(--shadow), transparent);
}

.pizza img {
  width: 100%;
  height: 100%;
  transform: rotate(calc(var(--d) * -1.2rad + var(--turn, 0deg)));
  will-change: transform;
}

/* ---------- Rechts: Rabatt und Bestellen ---------- */

.hero__aside {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-rows: 1fr auto;
  align-items: start;
  justify-items: start;
  min-height: calc(var(--arc-space) + var(--pizza));
  padding-top: calc(var(--arc-space) + var(--pizza) * 0.04);
}

.offer {
  position: relative;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 0.3rem;
  width: clamp(7.75rem, 10vw, 9.5rem);
  aspect-ratio: 1;
  padding: 1rem;
  border-radius: 50%;
  background: var(--tomato);
  color: var(--on-tomato);
  text-align: center;
  text-decoration: none;
  rotate: -8deg;
  box-shadow: 0 14px 30px -14px rgb(179 20 14 / 0.6);
  transition:
    rotate 0.45s var(--ease-out),
    scale 0.45s var(--ease-out);
}

.offer::before {
  content: "";
  position: absolute;
  inset: 0.4rem;
  border: 1.5px dashed rgb(255 253 251 / 0.55);
  border-radius: 50%;
}

.offer:hover {
  rotate: -2deg;
  scale: 1.05;
}

.offer__value {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 3.2vw, 2.9rem);
  font-weight: 800;
  font-stretch: 75%;
  line-height: 0.9;
}

.offer__text {
  max-width: 12ch;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.25;
}

.cta {
  align-self: end;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 3.5rem;
  padding: 0 1.25rem 0 1.75rem;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-size: 1.0625rem;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 0.3s,
    color 0.3s,
    scale 0.2s var(--ease-out);
}

.cta .icon {
  width: 1.125rem;
  height: 1.125rem;
  transition: translate 0.3s var(--ease-out);
}

.cta:hover {
  background: var(--tomato);
  color: var(--on-tomato);
}

.cta:hover .icon {
  translate: 2px -2px;
}

.cta:active {
  scale: 0.98;
}

/* ---------- Unten: Pizza-Auswahl ---------- */

.hero__tabs {
  position: relative;
  z-index: 1;
  justify-self: center;
  display: flex;
  justify-content: center;
  gap: 0.25rem;
  margin-top: clamp(0.75rem, 2svh, 1.5rem);
  padding: 0.3rem;
  border-radius: 999px;
  background: color-mix(in oklab, var(--surface) 70%, transparent);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.tab {
  padding: 0.55rem 1.05rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition:
    background-color 0.25s,
    color 0.25s;
}

.tab:hover {
  color: var(--ink);
}

.tab[aria-current="true"] {
  background: var(--ink);
  color: var(--bg);
}

/* ---------- Abschnittsmarken (unsichtbar) ---------- */

.hero__marks {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

/* Marke i deckt den Scrollbereich ab, in dem Pizza i die nächste ist. */
.hero__mark {
  position: absolute;
  left: 0;
  top: calc(var(--step) * (var(--i) - 0.5));
  width: 1px;
  height: var(--step);
}

/* ---------- Platzhalter für die nächsten Abschnitte ---------- */

.next-placeholder {
  display: grid;
  place-items: center;
  min-height: 40vh;
  padding: 3rem var(--gutter);
  border-top: 1px solid var(--line);
  color: var(--muted);
}

/* ---------- Auftritt beim Laden ---------- */

@media (prefers-reduced-motion: no-preference) {
  .js .wheel__roll {
    animation: roll-in 1.3s var(--ease-out) backwards;
  }

  .js .wheel__arc {
    animation: fade-in 0.9s 0.15s ease-out backwards;
  }

  .js .hero__dishes,
  .js .hero__aside {
    animation: rise-in 0.8s 0.35s var(--ease-out) backwards;
  }

  .js .offer {
    animation: stamp-in 0.6s 0.8s var(--ease-out) backwards;
  }
}

@keyframes roll-in {
  from {
    --intro: 1;
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translate3d(0, 1.5rem, 0);
  }
}

@keyframes stamp-in {
  from {
    opacity: 0;
    scale: 0.6;
  }
}

/* ---------- Weniger Bewegung: Überblenden statt Rollen ---------- */

@media (prefers-reduced-motion: reduce) {
  .pizza {
    opacity: clamp(0, 1 - var(--ad), 1);
    transform: none;
  }

  .pizza img {
    transform: rotate(var(--turn, 0deg));
  }

  .dish {
    transform: none;
  }

  .site-nav a,
  .icon-button,
  .offer,
  .cta,
  .cta .icon,
  .tab {
    transition: none;
  }
}

/* ---------- Ohne JavaScript: erste Pizza, kein Festhalten ---------- */

.no-js .hero {
  height: auto;
}

.no-js .hero__stage {
  position: relative;
  min-height: 100svh;
  height: auto;
}

.no-js .pizza:not(:first-child),
.no-js .dish:not(:first-child),
.no-js .hero__tabs,
.no-js .hero__marks {
  display: none;
}

/* ---------- Tablet und Handy: alles untereinander ----------
   Tablets hochkant (iPad Pro 1024 px) gehören dazu: das breite Layout verteilt sich dort
   verloren über die Höhe. Dieselbe Abfrage steht in about/hours/sections/gallery.css
   und in creator.js. */

@media (max-width: 960px), (max-width: 1199px) and (orientation: portrait) {
  .hero {
    /* 29rem = Kopfzeile, Text, Rabatt, Knopf und Auswahl darunter */
    --pizza: clamp(8rem, min(74vw, (100svh - var(--header-h)) * 0.42, (100svh - 29rem) / 1.3), 28rem);
    --step: 75svh;
  }

  .hero__grid {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
    row-gap: clamp(0.75rem, 2.2svh, 1.25rem);
  }

  .wheel {
    order: -1;
  }

  /* Text liegt unter der Pizza: Schleier von unten, dazu hinter dem Logo-Bogen */
  .backdrop__veil {
    background:
      linear-gradient(180deg, var(--veil) 0, var(--veil-soft) calc(var(--header-h) * 0.8), transparent calc(var(--header-h) * 1.9)),
      radial-gradient(60% 14% at 50% 15%, var(--veil-soft), transparent),
      linear-gradient(0deg, var(--veil) 0%, var(--veil) 30%, var(--veil-soft) 42%, transparent 58%);
  }

  .hero__dishes {
    justify-self: stretch;
    width: 100%;
    min-height: 0;
    padding-top: 0;
    text-align: center;
  }

  .dish__name {
    margin-bottom: 0.5rem;
    font-size: clamp(2.25rem, 10vw, 3.5rem);
  }

  .dish__desc {
    max-width: 32ch;
    margin: 0 auto 0.5rem;
    font-size: 1rem;
  }

  .hero__aside {
    grid-template-rows: none;
    justify-items: center;
    row-gap: 0.75rem;
    min-height: 0;
    padding-top: 0;
  }

  .offer,
  .offer:hover {
    rotate: 0deg;
    scale: 1;
  }

  .offer {
    display: inline-flex;
    align-items: baseline;
    gap: 0.5rem;
    width: auto;
    aspect-ratio: auto;
    padding: 0.4rem 1rem;
    border-radius: 999px;
    box-shadow: none;
  }

  .offer::before {
    display: none;
  }

  .offer__value {
    font-size: 1.25rem;
  }

  .offer__text {
    max-width: none;
    font-size: 0.8125rem;
  }

  .cta {
    align-self: auto;
  }
}

@media (max-width: 640px) {
  :root {
    --header-h: 3.75rem;
  }

  .hero {
    /* 21rem = Kopfzeile, Text, Rabatt und Knopf; Rest bekommt Pizza + Bogen */
    --pizza: clamp(8rem, min(80vw, (100svh - 21rem) / 1.3), 28rem);
  }

  .hero__stage {
    grid-template-rows: minmax(0, 1fr);
    padding-bottom: max(1rem, env(safe-area-inset-bottom));
  }

  .hero__tabs {
    display: none;
  }
}

/* Klappmenü statt Zeile bis 767 px: sechs Links passen erst ab 768 px neben Logo und Knöpfe */
@media (max-width: 767px) {
  .site-header__toggle {
    display: inline-grid;
  }

  .site-header__toggle .icon--close,
  .site-header__toggle[aria-expanded="true"] .icon--open {
    display: none;
  }

  .site-header__toggle[aria-expanded="true"] .icon--close {
    display: block;
  }

  .site-nav {
    grid-area: auto; /* sonst ist die 0 px breite Mittelspalte der Bezugsrahmen: Menü nur halb breit */
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    display: none;
    max-height: calc(100svh - var(--header-h));
    padding: 0.5rem var(--gutter) 1.5rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    border-bottom: 1px solid var(--line);
    background: var(--bg);
  }

  .site-nav[data-open] {
    display: block;
  }

  [data-over-hero] .site-nav {
    background: var(--surface);
  }

  .site-nav ul {
    flex-direction: column;
    gap: 0;
  }

  .site-nav a {
    display: block;
    padding-block: 0.6rem;
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 700;
    font-stretch: 75%;
    background: none;
  }

  .no-js .site-header__toggle {
    display: none;
  }

  .no-js .site-nav {
    grid-area: 1 / 2;
    position: static;
    display: block;
    padding: 0;
    border: 0;
    background: none;
  }

  .no-js .site-nav ul {
    flex-direction: row;
    gap: 1rem;
    overflow-x: auto;
  }

  .no-js .site-nav a {
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 500;
  }
}

/* Kleine Handys (z. B. iPhone SE) */
@media (max-width: 640px) and (max-height: 700px) {
  .dish__desc {
    font-size: 0.9375rem;
  }

  .wheel__arc-sub {
    font-size: 46px;
    letter-spacing: 0.06em;
  }
}

/* Handy quer und niedrige Fenster bis 960 px: Pizza links, Text rechts */
@media (max-width: 960px) and (orientation: landscape) and (max-height: 800px) {
  :root {
    --header-h: 3.25rem;
  }

  .hero {
    --pizza: min(40vw, (100svh - var(--header-h) - 1.5rem) / 1.3);
  }

  .hero__stage {
    grid-template-rows: minmax(0, 1fr);
  }

  .hero__tabs {
    display: none;
  }

  .hero__grid {
    grid-template-columns: var(--pizza) minmax(0, 24rem);
    justify-content: center;
    align-items: center;
    column-gap: 2.5rem;
  }

  .wheel {
    grid-row: 1 / span 2;
    grid-column: 1;
  }

  /* Text rechts neben der Pizza: Schleier von rechts */
  .backdrop__veil {
    background:
      linear-gradient(180deg, var(--veil) 0, var(--veil-soft) calc(var(--header-h) * 0.8), transparent calc(var(--header-h) * 1.9)),
      radial-gradient(28% 22% at 30% 20%, var(--veil-soft), transparent),
      linear-gradient(270deg, var(--veil) 0%, var(--veil-soft) 40%, transparent 62%);
  }

  .hero__dishes,
  .hero__aside {
    grid-column: 2;
    justify-self: start;
    justify-items: start;
    text-align: left;
  }

  .dish__desc {
    margin-inline: 0;
  }

  .dish__name {
    font-size: clamp(1.75rem, 8svh, 2.75rem);
  }
}

/* Sehr niedrige Fenster (z. B. 400 % Zoom): nichts festhalten, Inhalt fließt
   normal, die Auswahl-Knöpfe wechseln die Pizza direkt (hero.js). */
@media (max-height: 300px) {
  .hero {
    --pizza: min(60vw, 16rem);

    height: auto;
  }

  .hero__stage {
    position: relative;
    height: auto;
    min-height: 100svh;
    overflow: visible;
    overflow-x: clip;
  }

  .hero__marks {
    display: none;
  }

  /* ohne Scroll-Wechsel wählt man die Pizza über die Knöpfe */
  .hero__tabs {
    display: flex;
    flex-wrap: wrap;
  }

  .hero__grid {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
  }

  .wheel,
  .hero__dishes,
  .hero__aside {
    grid-row: auto;
    grid-column: auto;
  }

  .hero__dishes,
  .hero__aside {
    justify-self: stretch;
    justify-items: center;
    text-align: center;
  }

  .dish__desc {
    margin-inline: auto;
  }

  .dish__name {
    font-size: clamp(1.5rem, 11vw, 2.5rem);
  }
}

/* Windows-Kontrastmodus: Auswahl und Formen sichtbar halten */
@media (forced-colors: active) {
  .tab,
  .cta,
  .offer {
    border: 2px solid transparent;
  }

  .tab[aria-current="true"] {
    forced-color-adjust: none;
    background: SelectedItem;
    color: SelectedItemText;
  }

  .site-nav a[aria-current="page"] {
    text-decoration: underline 2px;
    text-underline-offset: 0.35em;
  }
}

/* ---------- Weicher Wechsel zu Impressum und Datenschutz ---------- */

@media (prefers-reduced-motion: no-preference) {
  @view-transition {
    navigation: auto;
  }
}

/* ---------- Sprunglink für die Tastatur (alle Seiten) ---------- */

.skip-link {
  position: fixed;
  top: -5rem;
  left: var(--gutter);
  z-index: 30;
  transition: top 0.2s;
}

.skip-link:focus {
  top: 0.75rem;
}

#inhalt {
  scroll-margin-top: var(--header-h);
}

/* Finger statt Maus: Tippfläche mindestens 44 px hoch (Apple HIG / WCAG 2.5.5) */
@media (pointer: coarse) {
  .site-nav a {
    padding-block: 0.6rem;
  }

  .tab {
    min-height: 2.75rem;
  }
}

/* Rabatt-Pille (Handy/Tablet) ist ein Link: Tippfläche unsichtbar auf 44 px erweitern,
   ohne die Pille größer zu zeichnen (auf flachen Handys bliebe sonst der Knopf darunter weg) */
@media (pointer: coarse) and (max-width: 960px), (pointer: coarse) and (max-width: 1199px) and (orientation: portrait) {
  .offer::after {
    content: "";
    position: absolute;
    inset: -0.5rem 0;
  }
}
