/* Restaurant: Gaststube, Auszug der Karte, Mittagstisch, Terrasse, Familien und Gruppen, Oeffnungszeiten.
   Hell, Weinrot und Kupfer aus thema-restaurant.css (in Kombinationen die Farbe der Fassung). Breakpoints nur 490, 768, 1040.
   Tippziele ab 44 px. Kein overflow hidden, kein display none als Loesung, kein backdrop-filter, kein fixed Hintergrund.
   Bewegung: drei scrollgebundene Bausteine aus dem Effektkatalog (Parallax Ebenen, Maskenwuchs, Hebung mit Staffel),
   Regeln wortgleich aus effekte.css, nur im Schalter fuer Bewegung und animation-timeline. Ohne Bewegung ist alles da. */

@media (prefers-reduced-motion: no-preference) {
  @supports (animation-timeline: view()) {
    .fx-parallax-buehne { position: relative; overflow: clip; }
    .fx-parallax-ebene {
      animation-name: fx-par-ebene;
      animation-duration: auto;
      animation-timing-function: linear;
      animation-fill-mode: both;
      animation-timeline: view();
      animation-range: cover;
      will-change: transform;
    }
    @keyframes fx-par-ebene {
      from { transform: translateY(calc(var(--fx-tempo, 40) * 0.5px)); }
      to   { transform: translateY(calc(var(--fx-tempo, 40) * -0.5px)); }
    }
    .fx-maskenwuchs {
      animation-name: fx-maske-k;
      animation-duration: auto;
      animation-timing-function: linear;
      animation-fill-mode: both;
      animation-timeline: view();
      animation-range: entry 0% cover 50%;
    }
    @keyframes fx-maske-k {
      from { clip-path: inset(28% 22% 28% 22% round 16px); }
      to   { clip-path: inset(0 0 0 0 round 0); }
    }
    .fx-staffel > * {
      --fx-versatz: calc((sibling-index() - 1) * var(--fx-takt, 7%));
    }
    @keyframes fx-hebung-k {
      from { transform: translateY(18px) scale(0.985); opacity: 0.25; }
      to   { transform: translateY(0) scale(1);        opacity: 1; }
    }

    /* Anpassungen fuer diese Seite (Variablen und Selektoren, nicht die Regeln) */
    /* Die Gerichte kommen fertig aus speisekarte.json (article.gericht), deshalb Hebung ueber den Selektor statt der Klasse.
       Bereich enger als im Katalog (entry 5 bis 75 statt entry 12 bis cover 45): die Karten sind rund 450 px hoch und
       standen bei 1280 x 800 sonst noch halb durchsichtig da, waehrend man sie liest. */
    .rs-gerichte > .gericht {
      animation-name: fx-hebung-k;
      animation-duration: auto;
      animation-timing-function: linear;
      animation-fill-mode: both;
      animation-timeline: view();
      animation-range: entry calc(5% + var(--fx-versatz)) entry calc(75% + var(--fx-versatz));
    }
    /* Staffel rechnet mit sibling-index (Chrome 138, Safari 26.2). Davor derselbe Versatz fest je Stelle. */
    @supports not (order: sibling-index()) {
      .fx-staffel > * { --fx-versatz: 0%; }
      .fx-staffel > :nth-child(2) { --fx-versatz: var(--fx-takt, 7%); }
      .fx-staffel > :nth-child(3) { --fx-versatz: calc(2 * var(--fx-takt, 7%)); }
      .fx-staffel > :nth-child(4) { --fx-versatz: calc(3 * var(--fx-takt, 7%)); }
    }
    /* Hoechstens drei scrollgebundene Bausteine je Seite: in Kombinationen bringen Zimmer und Festsaal Linienzug und
       Maskenwuchs mit, dort stehen die Ebenen der Gaststube still (Hebung und Maskenwuchs bleiben). */
    :root:not([data-angebot="tische"]) .rs-buehne .fx-parallax-ebene { animation: none; will-change: auto; }
    /* Ebenen der Gaststube: hinten langsam, vorn schnell, Abstand 75 (Grenze 90). Mobil halbiert. */
    .rs-buehne__bild--hinten { --fx-tempo: 20; }
    .rs-buehne__bild--mitte { --fx-tempo: 55; }
    .rs-buehne__bild--vorn { --fx-tempo: 95; }
    @media (max-width: 767.98px) {
      .rs-buehne__bild--hinten { --fx-tempo: 10; }
      .rs-buehne__bild--mitte { --fx-tempo: 28; }
      .rs-buehne__bild--vorn { --fx-tempo: 48; }
      /* Maskenwuchs mobil: seitlich nur 10 Prozent, sonst bleibt zu wenig sichtbar (Bausteindatei, Abschnitt Mobil) */
      .fx-maskenwuchs { animation-name: rs-maske-schmal; }
      @keyframes rs-maske-schmal {
        from { clip-path: inset(22% 10% 22% 10% round 16px); }
        to   { clip-path: inset(0 0 0 0 round 0); }
      }
    }
  }
}

/* ---------- Startbild: Karte "Heute noch frei" ---------- */
.rs-heute {
  display: grid; gap: var(--a-3); justify-items: start; margin: 0 auto var(--a-7); inline-size: min(100% - 2 * var(--a-5), var(--rahmen));
  padding: var(--a-5); border-radius: 22px; background: rgb(255 253 248 / 0.96); color: var(--tinte);
  box-shadow: 0 2px 4px rgb(10 6 3 / 0.12), 0 30px 60px -26px rgb(10 6 3 / 0.55), inset 0 1px 0 #fff;
  border-block-start: 3px solid var(--thema-gold, #B4863F);
}
.rs-heute__titel { font: 600 var(--t-klein) / 1.2 var(--f-text); letter-spacing: 0.12em; text-transform: uppercase; color: var(--thema-gold-text, #7A3F1C); }
.rs-heute__zeiten { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--a-2); min-block-size: 40px; }
.rs-heute__zeiten:empty { min-block-size: 0; }
.rs-heute__zeiten li { display: inline-flex; align-items: center; min-block-size: 40px; padding: 0 14px; border-radius: 999px; background: var(--thema-gold-flaeche, #F1EADB); border: 1px solid var(--thema-gold-rand, #DCCBA6); font: 600 1.125rem / 1 var(--f-text); font-variant-numeric: tabular-nums; color: var(--salbei-tief); }
.rs-heute__satz { font-size: var(--t-klein); color: var(--tinte-weich); max-inline-size: 19em; }
.rs-heute .knopf--haupt { background: var(--salbei-tief); color: #FFFDF8; }
@media (min-width: 768px) {
  .rs-heute {
    position: absolute; z-index: 1; inset-inline-end: max(var(--a-5), calc((100% - var(--rahmen)) / 2)); inset-block-start: var(--a-10);
    inline-size: 19rem; margin: 0; padding: var(--a-5) var(--a-6) var(--a-6);
    animation: auftauchen 900ms 600ms var(--kurve) both;
  }
  :root[data-angebot*="zimmer"] .rs-heute { inset-block-start: 300px; }
}
@media (min-width: 768px) and (max-width: 1039.98px) {
  /* Tablet: Text links bleibt frei, die Karte steht unten rechts im Bild statt neben der Ueberschrift */
  .rs-heute { inset-block-start: auto; inset-block-end: var(--a-7); inline-size: 17rem; }
  :root[data-angebot*="zimmer"] .rs-heute { inset-block-start: auto; }
  .held:has(.rs-heute) .held__text { padding-inline-end: 18rem; }
}
@media (min-width: 1040px) and (hover: hover) and (pointer: fine) and (prefers-reduced-motion: no-preference) {
  .rs-heute { translate: calc(var(--px, 0) * 16px) calc(var(--py, 0) * 12px); transition: translate 1200ms var(--kurve); }
}
@media (prefers-reduced-motion: reduce) { .rs-heute { animation: none; } }

/* ---------- Gaststube: Text links, drei Fotos in Ebenen rechts ---------- */
.rs-stube { background-image: radial-gradient(70% 60% at 100% 20%, rgb(var(--thema-gold-rgb, 180 134 63) / 0.14), transparent 70%); }
.rs-stube__raster { display: grid; gap: var(--a-7); grid-template-columns: minmax(0, 1fr); align-items: center; }
@media (min-width: 1040px) { .rs-stube__raster { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: var(--a-8); } }
.rs-stube h2, .rs-karte h2, .rs-gruppen h2, .rs-zeiten h2, .rs-terrasse h2 { color: var(--salbei-tief); }
.rs-merkmale { list-style: none; margin: 0 0 var(--a-6); padding: 0; display: grid; gap: var(--a-3); grid-template-columns: minmax(0, 1fr); }
@media (min-width: 490px) { .rs-merkmale { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.rs-merkmale li {
  display: flex; align-items: center; gap: var(--a-3); min-block-size: 56px; padding: var(--a-3) var(--a-4); border-radius: 16px;
  background: var(--papier); box-shadow: var(--schweben); font-weight: 600; line-height: 1.35;
  transition: translate 500ms var(--kurve), box-shadow 500ms var(--kurve);
}
.rs-merkmale__zeichen { flex: none; inline-size: 12px; block-size: 12px; border-radius: 50% 0; rotate: -45deg; background: var(--thema-gold, #B4863F); box-shadow: 0 0 0 4px rgb(var(--thema-gold-rgb, 180 134 63) / 0.18); }
@media (hover: hover) and (pointer: fine) { .rs-merkmale li:hover { translate: 0 -4px; box-shadow: var(--schweben-hoch); } }

.rs-buehne { position: relative; overflow: clip; overflow-clip-margin: 40px; aspect-ratio: 620 / 500; perspective: 1400px; }
.rs-buehne__bild {
  position: absolute; margin: 0; border-radius: 22px; overflow: clip; background: var(--sand);
  box-shadow: var(--schweben-foto, 0 30px 60px -22px rgb(60 40 20 / 0.38)); border: 4px solid var(--papier);
  rotate: y -5deg; transform-origin: 50% 50%;
}
.rs-buehne__bild img { inline-size: 100%; block-size: 100%; object-fit: cover; aspect-ratio: 16 / 9; }
.rs-buehne__bild--hinten { inset-inline-start: 0; inset-block-start: 8%; inline-size: 76%; }
.rs-buehne__bild--mitte { inset-inline-end: 0; inset-block-start: 1%; inline-size: 46%; rotate: y -9deg; }
.rs-buehne__bild--vorn { inset-inline-start: 6%; inset-block-start: 50%; inline-size: 46%; rotate: y -3deg; }
@media (max-width: 767.98px) {
  .rs-buehne { aspect-ratio: 1 / 0.82; }
  .rs-buehne__bild { border-width: 3px; border-radius: 16px; }
  .rs-buehne__bild--hinten { inline-size: 78%; inset-block-start: 12%; }
  .rs-buehne__bild--mitte { inline-size: 50%; inset-block-start: 1%; }
  .rs-buehne__bild--vorn { inline-size: 54%; inset-inline-start: 4%; inset-block-start: 54%; }
  .rs-buehne .ki__marke { font-size: 0.75rem; }
}
@media (prefers-reduced-motion: reduce) { .rs-buehne__bild { rotate: none; } }

/* ---------- Aus der Kueche: drei Gerichte als schwebende Karten ---------- */
.rs-karte { background-image: linear-gradient(180deg, rgb(255 253 248 / 0.7) 0%, rgb(255 253 248 / 0) 100%); }
.rs-karte__kopf { max-inline-size: 48rem; }
.rs-gerichte { --fx-takt: 6%; display: grid; gap: var(--a-6); grid-template-columns: minmax(0, 1fr); perspective: 1200px; }
@media (min-width: 768px) { .rs-gerichte { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1040px) { .rs-gerichte { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.rs-gerichte .gericht {
  display: flex; flex-direction: column; gap: var(--a-2); padding: var(--a-3) var(--a-3) var(--a-5); border-radius: 26px;
  background: var(--papier); box-shadow: var(--schweben); border: 1px solid rgb(var(--thema-tief-rgb, 17 47 77) / 0.06);
  rotate: var(--rs-neig, 0 0 1 0deg); translate: 0 var(--rs-hub, 0px);
  transition: rotate 600ms var(--kurve), translate 600ms var(--kurve), box-shadow 600ms var(--kurve);
}
.rs-gerichte .gericht__foto { order: -1; max-inline-size: none; margin: 0 0 var(--a-3); border-radius: 18px; box-shadow: none; position: relative; }
.rs-gerichte .gericht__foto img { transition: transform 1200ms var(--kurve); }
.rs-gerichte .gericht__kopf, .rs-gerichte .gericht__text, .rs-gerichte .gericht__zeichen { padding-inline: var(--a-3); }
.rs-gerichte .gericht__name { color: var(--salbei-tief); font-size: 1.4375rem; }
.rs-gerichte .gericht__kennung { color: var(--thema-gold-text, #7A3F1C); }
@media (hover: hover) and (pointer: fine) {
  .rs-gerichte .gericht:hover { --rs-hub: -8px; box-shadow: var(--schweben-hoch); }
  .rs-gerichte .gericht:hover .gericht__foto img { transform: scale(1.05); }
}
.rs-karte__weiter { margin-block-start: var(--a-7); display: flex; justify-content: center; }
@media (max-width: 489.98px) { .rs-karte__weiter .knopf { flex: 1 1 100%; justify-content: center; } }

/* ---------- Mittagstisch: die dunkle Tafel aus der Speisekarte, auf der Seite mit Knopf ---------- */
.rs-mittag { padding-block: var(--a-7) var(--a-8); }
.rs-mittag .mittag { padding-block: 0; }
.rs-mittag__knopf { display: flex; justify-content: center; margin-block-start: var(--a-6); }
.rs-mittag__knopf .knopf { color: var(--salbei-tief); }
@media (max-width: 489.98px) { .rs-mittag__knopf .knopf { flex: 1 1 100%; justify-content: center; } }

/* ---------- Terrasse: Foto oeffnet sich, Karte schwebt darueber ---------- */
.rs-terrasse { padding-block-start: var(--a-7); }
.rs-terrasse__rahmen { position: relative; }
.rs-terrasse__bild { margin: 0; border-radius: 28px; overflow: clip; box-shadow: var(--schweben-foto, 0 30px 60px -22px rgb(60 40 20 / 0.38)); background: var(--sand); }
.rs-terrasse__bild img { inline-size: 100%; aspect-ratio: 16 / 8; object-fit: cover; }
.rs-terrasse__karte {
  position: relative; z-index: 1; display: grid; gap: var(--a-4); justify-items: start;
  margin: calc(-1 * var(--a-7)) var(--a-4) 0; padding: var(--a-6) var(--a-5);
  border-radius: 24px; background: var(--papier); box-shadow: var(--schweben-hoch); border-block-start: 3px solid var(--thema-gold, #B4863F);
}
.rs-terrasse__karte .kicker { margin: 0; }
.rs-terrasse__karte h2 { font-size: clamp(1.875rem, 1.4rem + 1.6vw, 2.625rem); }
.rs-terrasse__karte p:not(.kicker) { color: var(--tinte-weich); }
@media (max-width: 767.98px) { .rs-terrasse__bild img { aspect-ratio: 4 / 3; } .rs-terrasse__karte .knopf { inline-size: 100%; justify-content: center; } }
@media (min-width: 768px) { .rs-terrasse__karte { margin: calc(-1 * var(--a-9)) 0 0 var(--a-7); max-inline-size: 30rem; padding: var(--a-7) var(--a-7) var(--a-6); } }
@media (min-width: 1040px) { .rs-terrasse__karte { margin-block-start: calc(-1 * var(--a-10) - var(--a-6)); } }

/* ---------- Familien und Gruppen ---------- */
.rs-gruppen__raster { display: grid; gap: var(--a-7); grid-template-columns: minmax(0, 1fr); align-items: center; }
@media (min-width: 1040px) { .rs-gruppen__raster { grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: var(--a-8); } }
.rs-gruppen__bild { position: relative; margin: 0; border-radius: 26px; overflow: clip; box-shadow: var(--schweben-foto, 0 30px 60px -22px rgb(60 40 20 / 0.38)); background: var(--sand); }
.rs-gruppen__bild img { inline-size: 100%; aspect-ratio: 16 / 10; object-fit: cover; }
.rs-gruppen__marke {
  position: absolute; inset-block-start: var(--a-4); inset-inline-start: var(--a-4); display: grid; justify-items: center;
  padding: var(--a-3) var(--a-4); border-radius: 18px; background: rgb(255 253 248 / 0.95); box-shadow: var(--schweben-hoch);
}
.rs-gruppen__zahl { font: 500 2.75rem / 1 var(--f-anzeige); color: var(--salbei-tief); }
.rs-gruppen__wort { font: 600 0.875rem / 1.2 var(--f-text); color: var(--tinte); }
.rs-liste { list-style: none; margin: 0 0 var(--a-6); padding: 0; display: grid; gap: var(--a-3); }
.rs-liste li { position: relative; padding-inline-start: 34px; line-height: 1.5; }
.rs-liste li::before { content: ""; position: absolute; inset-inline-start: 4px; inset-block-start: 0.32em; inline-size: 18px; block-size: 10px; border-inline-start: 3px solid var(--salbei-tief); border-block-end: 3px solid var(--salbei-tief); rotate: -45deg; transform-origin: 30% 60%; }
.rs-gruppen__fein { margin-block-start: var(--a-4); }
@media (max-width: 489.98px) { .rs-gruppen .knopfreihe .knopf { flex: 1 1 100%; justify-content: center; } }

/* ---------- Oeffnungszeiten gross und Reservieren ---------- */
.rs-zeiten { background-image: linear-gradient(180deg, rgb(255 253 248 / 0) 0%, var(--thema-gold-flaeche, #F1EADB) 30%, var(--thema-gold-flaeche, #F1EADB) 70%, rgb(255 253 248 / 0) 100%); }
.rs-zeiten__kopf { max-inline-size: 48rem; }
.rs-zeiten__raster { display: grid; gap: var(--a-6); grid-template-columns: minmax(0, 1fr); align-items: start; }
@media (min-width: 1040px) { .rs-zeiten__raster { grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); gap: var(--a-7); } }
.rs-zeiten__tafel[hidden] { display: none; }
.rs-reservieren {
  display: grid; gap: var(--a-4); justify-items: start; padding: var(--a-7) var(--a-6); border-radius: 28px;
  background: var(--papier); box-shadow: var(--schweben-hoch); border-block-start: 4px solid var(--thema-gold, #B4863F);
  position: relative;
}
.rs-reservieren .kicker { margin: 0; }
.rs-reservieren h3 { font-size: clamp(1.5rem, 1.2rem + 1vw, 1.875rem); color: var(--salbei-tief); }
.rs-reservieren p:not(.kicker) { color: var(--tinte-weich); }
.rs-reservieren__knopf { inline-size: 100%; justify-content: center; }
.rs-reservieren__telefon a { display: inline-flex; align-items: center; min-block-size: 44px; font-weight: 700; white-space: nowrap; }
@media (max-width: 767.98px) { .rs-reservieren { padding: var(--a-6) var(--a-5); } }

/* Lichtstreif der Karten beim Erscheinen wie im Rest der Seite (musterhof-raum.css), hier fuer die eigenen Karten */
.rs-reservieren, .rs-terrasse__karte { isolation: isolate; }
@media (prefers-reduced-motion: no-preference) {
  .rs-reservieren.ist-da::before, .rs-terrasse__karte.ist-da::before {
    content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; pointer-events: none;
    background: linear-gradient(105deg, rgb(255 251 240 / 0) 32%, rgb(255 251 240 / 0.7) 47%, rgb(var(--thema-gold-rgb, 240 214 160) / 0.22) 53%, rgb(255 251 240 / 0) 68%) no-repeat;
    background-size: 260% 100%; background-position: 135% 0; opacity: 0;
    animation: schimmer 2100ms var(--kurve) 300ms 1 both;
  }
}

/* Logo im Kopf und im Fenster in der Farbe der Fassung (das Logo traegt Nachtblau als feste Fuellung) */
:root[data-thema="restaurant"] .logo [fill="#112f4d"] { fill: var(--thema-tief); }

/* Tischfenster: Name der Seite ueber dem Titel, auch am Handy (dort fehlt das Logo der Seitenleiste) */
#vr-modal-table .vr-modal__eyebrow { display: block; margin: 0 0 var(--a-3); font: 600 0.875rem / 1.3 var(--f-text) !important; font-style: normal; letter-spacing: 0.14em; color: var(--vr-creme, #F8F3EA); }
