/* ============================================================
   Gasthaus – Stylesheet
   Eine Datei für alle Seiten. Aufbau von oben nach unten:
   1. Variablen  2. Grundlagen  3. Kopf/Navigation  4. Hero
   5. Bausteine  6. Speisekarte  7. Fuß  8. Handy-Anpassungen
   ============================================================ */

/* ---------- 1. Variablen: hier zentral Farben & Maße ändern ---------- */
:root {
  --farbe-text: #2b2521;
  --farbe-text-leise: #6f665e;
  --farbe-akzent: #7a3527;        /* warmes Ziegelrot – prägt die Seite */
  --farbe-akzent-hell: #a2523f;
  --farbe-hintergrund: #faf7f2;   /* warmes Off-White, kein grelles Weiß */
  --farbe-flaeche: #ffffff;
  --farbe-linie: #e3dbd0;

  --schrift-titel: Georgia, "Times New Roman", serif;
  --schrift-text: "Segoe UI", system-ui, -apple-system, Helvetica, Arial, sans-serif;

  --breite: 1080px;
  --abstand: 1.5rem;
}

/* ---------- 2. Grundlagen ---------- */
* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--schrift-text);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--farbe-text);
  background: var(--farbe-hintergrund);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: var(--schrift-titel);
  font-weight: normal;
  line-height: 1.2;
  margin: 0 0 0.6em;
}

h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); }
h3 { font-size: 1.25rem; }
h4 { font-size: 1.05rem; margin-top: 2rem; }

p { margin: 0 0 1.1em; }

a { color: var(--farbe-akzent); }

img { max-width: 100%; height: auto; display: block; }

.inhalt {
  max-width: var(--breite);
  margin: 0 auto;
  padding: 0 var(--abstand);
}

/* Kleine Zierlinie unter Abschnittsüberschriften */
.zierlinie::after {
  content: "";
  display: block;
  width: 60px;
  height: 2px;
  background: var(--farbe-akzent);
  margin: 1rem auto 0;
}

.mitte { text-align: center; }

/* Sprungmarke für Tastatur-Nutzer (erscheint erst bei Fokus) */
.skip-link {
  position: absolute;
  left: -9999px;
  background: var(--farbe-akzent);
  color: #fff;
  padding: 0.75rem 1rem;
  z-index: 100;
}
.skip-link:focus { left: 0; top: 0; }

/* ---------- 3. Kopf & Navigation ---------- */
.kopf {
  background: var(--farbe-flaeche);
  border-bottom: 1px solid var(--farbe-linie);
  position: sticky;
  top: 0;
  z-index: 50;
}

.kopf-innen {
  max-width: var(--breite);
  margin: 0 auto;
  padding: 0.9rem var(--abstand);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.logo {
  font-family: var(--schrift-titel);
  font-size: 1.4rem;
  color: var(--farbe-text);
  text-decoration: none;
  letter-spacing: 0.02em;
}
.logo span {
  display: block;
  font-family: var(--schrift-text);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--farbe-text-leise);
}

.navigation {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.4rem;
}

.navigation a {
  color: var(--farbe-text);
  text-decoration: none;
  font-size: 0.95rem;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
}
.navigation a:hover,
.navigation a:focus-visible { border-bottom-color: var(--farbe-akzent); }

/* Aktuelle Seite in der Navigation hervorheben */
.navigation a[aria-current="page"] {
  color: var(--farbe-akzent);
  border-bottom-color: var(--farbe-akzent);
}

/* Telefonnummer im Kopf – der wichtigste Knopf der ganzen Seite */
.tel-knopf {
  background: var(--farbe-akzent);
  color: #fff !important;
  padding: 0.5rem 1rem !important;
  border-radius: 3px;
  border-bottom: none !important;
  white-space: nowrap;
}
.tel-knopf:hover { background: var(--farbe-akzent-hell); }

/* ---------- 4. Hero (großes Bild auf der Startseite) ---------- */
.hero {
  /* Farbverlauf liegt ÜBER dem Foto, damit die weiße Schrift lesbar bleibt.
     Fehlt das Foto noch, sieht man einfach die Farbfläche darunter. */
  background:
    linear-gradient(rgba(43, 37, 33, 0.45), rgba(43, 37, 33, 0.6)),
    var(--farbe-akzent) url("../bilder/hero.jpg") center / cover no-repeat;
  color: #fff;
  text-align: center;
  padding: clamp(5rem, 16vw, 10rem) var(--abstand);
}

.hero h1 { color: #fff; margin-bottom: 0.4em; }

.hero p {
  font-size: 1.15rem;
  max-width: 46ch;
  margin: 0 auto 2rem;
  opacity: 0.95;
}

/* Kleiner Hero für die Unterseiten */
.hero-klein {
  background: var(--farbe-akzent);
  color: #fff;
  text-align: center;
  padding: clamp(3rem, 8vw, 5rem) var(--abstand);
}
.hero-klein h1 { color: #fff; margin: 0; }

/* ---------- 5. Bausteine ---------- */
.abschnitt { padding: clamp(3rem, 8vw, 5.5rem) 0; }
.abschnitt-hell { background: var(--farbe-flaeche); }

.knopf {
  display: inline-block;
  background: var(--farbe-akzent);
  color: #fff;
  text-decoration: none;
  padding: 0.8rem 1.8rem;
  border-radius: 3px;
  font-size: 1rem;
}
.knopf:hover { background: var(--farbe-akzent-hell); }

.knopf-hell {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.7);
}
.knopf-hell:hover { background: rgba(255, 255, 255, 0.15); }

/* Dreispaltiges Raster – bricht auf schmalen Displays automatisch um */
.raster {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.karte {
  background: var(--farbe-flaeche);
  border: 1px solid var(--farbe-linie);
  padding: 2rem;
  border-radius: 4px;
}
.karte h3 { color: var(--farbe-akzent); }
.karte p:last-child { margin-bottom: 0; }

/* Karte mit Foto obendrauf. Das feste Seitenverhältnis sorgt dafür, dass
   nebeneinanderliegende Karten gleich hoch bleiben – auch wenn die Fotos
   unterschiedlich zugeschnitten sind. */
.karte-bild {
  background: var(--farbe-flaeche);
  border: 1px solid var(--farbe-linie);
  border-radius: 4px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.karte-bild img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
}
.karte-bild-text {
  padding: 1.75rem;
  flex: 1;
}
.karte-bild-text h3 {
  color: var(--farbe-akzent);
  margin-bottom: 0.4em;
}
.karte-bild-text > :last-child { margin-bottom: 0; }

/* Fotos in zweispaltigen Abschnitten */
.zweispaltig img { border-radius: 4px; }

/* Breites Panoramabild über die volle Fensterbreite, als Trenner zwischen
   zwei Abschnitten. Für Bilder, die viel breiter als hoch sind – in einer
   schmalen Spalte würden die nur angeschnitten wirken. */
.panorama {
  display: block;
  width: 100%;
  height: clamp(180px, 26vw, 340px);
  object-fit: cover;
  object-position: center 60%;   /* etwas tiefer: die Schirme sind wichtiger als der Himmel */
}

/* Zwei Spalten: Text neben Bild/Info */
.zweispaltig {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: center;
}

/* Öffnungszeiten-Tabelle */
.zeiten {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
}
.zeiten th,
.zeiten td {
  text-align: left;
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--farbe-linie);
  font-weight: normal;
}
.zeiten td { text-align: right; color: var(--farbe-text-leise); }
.zeiten tr:last-child th,
.zeiten tr:last-child td { border-bottom: none; }
.zeiten .ruhetag td { color: var(--farbe-akzent); }

/* ---------- 6. Speisekarte ---------- */
.karte-gruppe { margin-bottom: 3.5rem; }

.karte-gruppe > h2 {
  border-bottom: 2px solid var(--farbe-akzent);
  padding-bottom: 0.4rem;
  margin-bottom: 1.5rem;
}

.gericht {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.9rem 0;
  border-bottom: 1px dotted var(--farbe-linie);
}
.gericht:last-child { border-bottom: none; }

.gericht-name { font-weight: 600; }

.gericht-beschreibung {
  display: block;
  font-weight: normal;
  font-size: 0.92rem;
  color: var(--farbe-text-leise);
  margin-top: 0.15rem;
}

.gericht-preis {
  font-family: var(--schrift-titel);
  font-size: 1.1rem;
  white-space: nowrap;
}

.hinweis {
  font-size: 0.88rem;
  color: var(--farbe-text-leise);
  font-style: italic;
}

/* Hervorgehobener Kasten für Dinge, die Gäste vorher wissen müssen
   (Ruhetage, Küchenschluss, Barzahlung) – erspart Diskussionen an der Tür. */
.hinweis-box {
  background: #fdf3ee;
  border-left: 4px solid var(--farbe-akzent);
  padding: 1.2rem 1.5rem;
  margin: 2rem 0;
  border-radius: 0 4px 4px 0;
}
.hinweis-box p:last-child { margin-bottom: 0; }
.hinweis-box strong { color: var(--farbe-akzent); }

/* Aufzählung ohne Punkte, für Ausstattungslisten */
.merkmale {
  list-style: none;
  padding: 0;
  margin: 0 0 1.5rem;
}
.merkmale li {
  padding: 0.45rem 0 0.45rem 1.6rem;
  position: relative;
  border-bottom: 1px solid var(--farbe-linie);
}
.merkmale li::before {
  content: "•";
  color: var(--farbe-akzent);
  position: absolute;
  left: 0.4rem;
  font-size: 1.2rem;
  line-height: 1.4;
}
.merkmale li:last-child { border-bottom: none; }

/* ---------- 7. Fuß ---------- */
.fuss {
  background: #2b2521;
  color: #cfc6bc;
  padding: 3.5rem 0 2rem;
  margin-top: 0;
}
.fuss a { color: #e8ded2; }
.fuss h3 { color: #fff; font-size: 1.05rem; }

.fuss-raster {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}

.fuss-unten {
  border-top: 1px solid #443b34;
  padding-top: 1.5rem;
  font-size: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 1rem;
}

/* ---------- 8. Handy-Anpassungen ---------- */
@media (max-width: 720px) {
  .zweispaltig { grid-template-columns: 1fr; gap: 2rem; }

  .kopf-innen { justify-content: center; text-align: center; }
  .navigation { justify-content: center; gap: 1rem; }

  /* Sticky-Kopf frisst auf kleinen Displays zu viel Platz */
  .kopf { position: static; }
}

/* Rücksicht auf Nutzer, die Bewegung reduziert haben wollen */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
}

/* ---------- Druckansicht (Gäste drucken gern die Speisekarte) ---------- */
@media print {
  .kopf, .fuss, .hero, .hero-klein, .knopf { display: none; }
  body { background: #fff; font-size: 11pt; }
}

/* ---------- 9. Cookie-Zustimmung ---------- */

.ck-leiste {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 200;
  background: var(--farbe-flaeche);
  border-top: 3px solid var(--farbe-akzent);
  box-shadow: 0 -4px 20px rgba(43, 37, 33, 0.15);
  padding: 1.4rem var(--abstand);
  padding-bottom: calc(1.4rem + env(safe-area-inset-bottom, 0px));
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 1.2rem 2.5rem;
  transform: translateY(100%);
  transition: transform 0.3s ease;
}
.ck-leiste.ist-sichtbar { transform: translateY(0); }

.ck-leiste-text { max-width: 60ch; }
.ck-leiste-text h2 {
  font-size: 1.1rem;
  margin: 0 0 0.4rem;
}
.ck-leiste-text p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
}
.ck-links {
  margin-top: 0.5rem !important;
  font-size: 0.82rem !important;
  color: var(--farbe-text-leise);
}

.ck-leiste-knoepfe {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  flex-shrink: 0;
  min-width: 13rem;
}

/* ---- Knöpfe ---- */
.ck-knopf {
  font-family: inherit;
  font-size: 0.92rem;
  padding: 0.65rem 1.5rem;
  border-radius: 3px;
  cursor: pointer;
  border: 1px solid transparent;
  white-space: nowrap;
}
.ck-knopf-haupt {
  background: var(--farbe-akzent);
  color: #fff;
  border-color: var(--farbe-akzent);
}
.ck-knopf-haupt:hover { background: var(--farbe-akzent-hell); border-color: var(--farbe-akzent-hell); }

.ck-knopf-leise {
  background: transparent;
  color: var(--farbe-text);
  border-color: var(--farbe-linie);
}
.ck-knopf-leise:hover { background: var(--farbe-hintergrund); border-color: var(--farbe-text-leise); }

.ck-knopf-text {
  background: none;
  color: var(--farbe-text-leise);
  text-decoration: underline;
  padding: 0.3rem;
  font-size: 0.85rem;
}
.ck-knopf-text:hover { color: var(--farbe-akzent); }

/* ---- Einstellungen-Dialog ---- */
.ck-hintergrund {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(43, 37, 33, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--abstand);
  opacity: 0;
  transition: opacity 0.25s ease;
}
.ck-hintergrund.ist-sichtbar { opacity: 1; }

.ck-dialog {
  background: var(--farbe-flaeche);
  border-radius: 4px;
  padding: 2rem;
  max-width: 34rem;
  width: 100%;
  max-height: 85vh;
  overflow-y: auto;
}
.ck-dialog h2 { margin-top: 0; font-size: 1.3rem; }

.ck-kategorie {
  border-top: 1px solid var(--farbe-linie);
  padding: 1.1rem 0;
}
.ck-kategorie-kopf {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
}
.ck-kategorie-kopf input { width: 1.05rem; height: 1.05rem; accent-color: var(--farbe-akzent); }
.ck-kategorie-kopf input:disabled { cursor: not-allowed; }
.ck-kategorie-name { font-weight: 600; }
.ck-immer {
  margin-left: auto;
  font-size: 0.78rem;
  color: var(--farbe-text-leise);
  font-style: italic;
}
.ck-kategorie-text {
  margin: 0.45rem 0 0 1.65rem;
  font-size: 0.87rem;
  line-height: 1.5;
  color: var(--farbe-text-leise);
}

.ck-dialog-knoepfe {
  display: flex;
  gap: 0.6rem;
  justify-content: flex-end;
  border-top: 1px solid var(--farbe-linie);
  padding-top: 1.3rem;
  margin-top: 0.5rem;
}

@media (max-width: 720px) {
  .ck-leiste {
    padding: 1rem;
    padding-bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
    gap: 0.9rem;
    max-height: 70vh;
    overflow-y: auto;
  }
  .ck-leiste-text h2 { font-size: 1rem; }
  .ck-leiste-text p { font-size: 0.82rem; line-height: 1.45; }
  .ck-leiste-knoepfe { width: 100%; min-width: 0; }
  .ck-dialog { padding: 1.5rem 1.25rem; }
  .ck-dialog-knoepfe { flex-direction: column-reverse; }
  .ck-dialog-knoepfe .ck-knopf { width: 100%; }
}

@media print { .ck-leiste, .ck-hintergrund { display: none !important; } }

/* ---------- 10. Rechtliche Seite ---------- */

/* Auffälliger Kasten für noch fehlende Pflichtangaben.
   Der ganze Block im HTML wird entfernt, sobald alles ergänzt ist. */
.offen-kasten {
  background: #fff8e6;
  border: 2px solid #c08a1e;
  border-radius: 4px;
  padding: 1.5rem 1.75rem;
  margin-bottom: 3rem;
}
.offen-kasten h2 {
  margin-top: 0;
  font-size: 1.15rem;
  color: #8a5f10;
}
.offen-kasten ol { margin: 0 0 1rem; padding-left: 1.3rem; }
.offen-kasten li { margin-bottom: 0.6rem; }
.offen-kasten > :last-child { margin-bottom: 0; }

/* Platzhalter für eine Angabe, die noch fehlt */
.fehlt {
  background: #fdecec;
  color: #a01c1c;
  border: 1px dashed #a01c1c;
  padding: 0.1rem 0.5rem;
  border-radius: 3px;
  font-size: 0.88rem;
  font-style: italic;
}

/* Auf der Rechtsseite stehen viele Zwischenüberschriften dicht
   beieinander – etwas mehr Luft darüber hilft beim Lesen. */
.inhalt h3 { margin-top: 2.5rem; }
.inhalt h3 + p,
.inhalt h3 + ul,
.inhalt h3 + table { margin-top: 0.75rem; }

/* ---------- 11. Dienstanbieter-Blöcke in der Datenschutzerklärung ---------- */
.dienst {
  background: var(--farbe-hintergrund);
  border-left: 3px solid var(--farbe-linie);
  padding: 1rem 1.25rem;
  margin: 1.25rem 0 2rem;
  font-size: 0.9rem;
}
.dienst dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 0.35rem 1rem; }
.dienst dt { font-weight: 600; color: var(--farbe-text-leise); }
.dienst dd { margin: 0; overflow-wrap: anywhere; }

@media (max-width: 620px) {
  .dienst dl { grid-template-columns: 1fr; gap: 0.1rem; }
  .dienst dd { margin-bottom: 0.6rem; }
}
