/* ==========================================
   Café Kuchenliebe — Stylesheet
   ========================================== */

/* 1. CUSTOM PROPERTIES
   ========================================== */
:root {
  --c-creme:  #F5EFE6;
  --c-sand:   #EDE4D7;
  --c-text:   #2A1F1A;
  --c-muted:  #6B5C54;
  --c-sage:   #7A8C6E;
  --c-plum:   #8B5068;
  --c-footer: #1E1410;
  --c-border: rgba(42, 31, 26, 0.10);

  --f-serif:  'Cormorant Garamond', Georgia, serif;
  --f-sans:   'DM Sans', system-ui, -apple-system, sans-serif;

  --sp-2:  0.5rem;
  --sp-4:  1rem;
  --sp-6:  1.5rem;
  --sp-8:  2rem;
  --sp-10: 2.5rem;
  --sp-16: 4rem;
  --sp-24: 6rem;

  --max-w: 1200px;
  --nav-h: 72px;
  --ease:  0.22s ease;
}

/* 2. RESET & BASE
   ========================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--f-sans);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--c-text);
  background: var(--c-creme);
  -webkit-font-smoothing: antialiased;
}
img, picture { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; border: none; background: none; }
a { color: inherit; text-decoration: none; }
p { max-width: 60ch; }
address { font-style: normal; }
[hidden] { display: none !important; }

/* 3. TYPOGRAPHY
   ========================================== */
h1, h2 {
  font-family: var(--f-serif);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.015em;
}
h1 { font-size: clamp(2.75rem, 8vw, 5.5rem); }
h2 { font-size: clamp(2rem, 5vw, 3.25rem); }
h3 {
  font-family: var(--f-sans);
  font-size: 1.0625rem;
  font-weight: 500;
  line-height: 1.35;
}

.label {
  display: block;
  font-size: 0.6875rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-muted);
  margin-bottom: var(--sp-4);
}

/* 4. LAYOUT
   ========================================== */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--sp-6);
}

section[id] { scroll-margin-top: var(--nav-h); }

/* 5. BUTTONS
   ========================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.8125rem 1.625rem;
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: 0.025em;
  border: 1.5px solid transparent;
  border-radius: 2px;
  transition: background var(--ease), color var(--ease), border-color var(--ease);
  white-space: nowrap;
  line-height: 1;
}

.btn--primary {
  background: var(--c-text);
  color: var(--c-creme);
  border-color: var(--c-text);
}
.btn--primary:hover { background: #3D2D26; border-color: #3D2D26; }

.btn--outline {
  background: transparent;
  color: var(--c-text);
  border-color: var(--c-text);
}
.btn--outline:hover { background: var(--c-text); color: var(--c-creme); }

.btn--ghost {
  background: transparent;
  color: var(--c-creme);
  border-color: rgba(245,239,230,0.45);
}
.btn--ghost:hover {
  background: rgba(245,239,230,0.1);
  border-color: rgba(245,239,230,0.8);
}

.btn--ghost-dark {
  background: transparent;
  color: var(--c-text);
  border-color: var(--c-border);
}
.btn--ghost-dark:hover {
  background: rgba(42,31,26,0.06);
  border-color: rgba(42,31,26,0.3);
}

/* 6. IMAGE CONTAINERS
   ========================================== */
.cover-wrap {
  position: relative;
  overflow: hidden;
  border-radius: 2px;
}
.cover-wrap > * {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.cover-wrap img { object-fit: cover; }

.placeholder-img {
  background: var(--c-sand);
  display: flex;
  align-items: center;
  justify-content: center;
}
.placeholder-img::after {
  content: 'Foto folgt';
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-muted);
  opacity: 0.4;
}
.placeholder-img--dark { background: #2A1F1A; }
.placeholder-img--dark::after { color: rgba(245,239,230,0.22); }

/* 7. NAVIGATION
   ========================================== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: var(--c-creme);
  border-bottom: 1px solid var(--c-border);
  transition: box-shadow var(--ease);
}
.site-header.is-scrolled {
  box-shadow: 0 2px 20px rgba(42,31,26,0.08);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  gap: var(--sp-8);
}

.nav__logo { display: flex; flex-shrink: 0; }
.nav__logo img {
  height: 50px;
  width: auto;
  mix-blend-mode: darken;
}

.nav__toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  width: 40px;
  height: 40px;
  align-items: center;
  justify-content: center;
  border-radius: 2px;
  transition: background var(--ease);
}
.nav__toggle:hover { background: rgba(42,31,26,0.06); }
.nav__toggle span {
  display: block;
  width: 22px;
  height: 1.5px;
  background: var(--c-text);
  border-radius: 1px;
  transition: transform var(--ease), opacity var(--ease);
}
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

.nav__menu {
  display: none;
  position: fixed;
  inset: var(--nav-h) 0 0;
  background: var(--c-creme);
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--sp-8);
  z-index: 99;
}
.nav__menu.is-open { display: flex; }

.nav__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--sp-6);
}
.nav__link {
  font-family: var(--f-serif);
  font-size: 2.25rem;
  font-weight: 400;
  color: var(--c-text);
  transition: opacity var(--ease);
}
.nav__link:hover { opacity: 0.5; }
.nav__link.is-active {
  text-decoration: underline;
  text-underline-offset: 5px;
  text-decoration-thickness: 1px;
}

.nav__cta { margin-top: var(--sp-4); }
.nav__reserve { display: none; }

/* 8. MODAL (Desktop Resmio)
   ========================================== */
.modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--sp-6);
}

.modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(26,15,10,0.65);
}

.modal__box {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 780px;
  height: min(82vh, 700px);
  background: #fff;
  border-radius: 3px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.modal__box iframe {
  flex: 1;
  border: none;
  width: 100%;
  display: block;
}

.modal__close {
  position: absolute;
  top: var(--sp-4);
  right: var(--sp-4);
  z-index: 10;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(245,239,230,0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--c-text);
  transition: background var(--ease);
}
.modal__close:hover { background: var(--c-creme); }
.modal__close svg { width: 16px; height: 16px; pointer-events: none; }

/* 9. HERO
   ========================================== */
.s-hero {
  position: relative;
  height: 100svh;
  min-height: 640px;
  display: flex;
  align-items: flex-end;
  padding-bottom: var(--sp-16);
}

.s-hero__bg { position: absolute; inset: 0; }
.s-hero__bg .cover-wrap { border-radius: 0; }

.s-hero__overlay {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to top,
    rgba(26,15,10,0.82) 0%,
    rgba(26,15,10,0.22) 50%,
    transparent 100%
  );
}

.s-hero__content {
  position: relative;
  z-index: 2;
  color: var(--c-creme);
}
.s-hero__content .label { color: rgba(245,239,230,0.6); }

.s-hero__headline {
  color: var(--c-creme);
  margin-bottom: var(--sp-8);
}

.s-hero__actions { display: flex; flex-wrap: wrap; gap: var(--sp-4); }

.hero-reserve--desktop { display: none; }
.hero-reserve--mobile  { display: inline-flex; }

/* 10. CAFÉ INTRO
    ========================================== */
.s-cafe {
  padding: var(--sp-16) 0;
  background: var(--c-creme);
}
.s-cafe__grid { display: grid; gap: var(--sp-10); }
.s-cafe__headline { margin-bottom: var(--sp-6); }
.s-cafe__body { color: var(--c-muted); margin-bottom: var(--sp-4); line-height: 1.75; }
.s-cafe__body:last-of-type { margin-bottom: 0; }
.s-cafe__img-wrap { aspect-ratio: 4/5; }

/* 11. ANGEBOT
    ========================================== */
.s-angebot {
  padding: var(--sp-16) 0;
  background: var(--c-sand);
}
.s-angebot__head { margin-bottom: var(--sp-16); }
.s-angebot__head h2 { margin-top: var(--sp-2); }

.angebot-items { display: flex; flex-direction: column; gap: var(--sp-16); }

.angebot-item { display: grid; gap: var(--sp-8); }
.angebot-item__img-wrap { aspect-ratio: 4/3; }
.angebot-item__text h3 { margin-bottom: var(--sp-4); }
.angebot-item__text p { color: var(--c-muted); line-height: 1.75; }

.s-angebot__cta { margin-top: var(--sp-16); text-align: center; }

/* 12. GALERIE
    ========================================== */
.s-galerie { background: var(--c-creme); }

.galerie-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: 200px;
  gap: 3px;
}

.galerie-item { overflow: hidden; background: var(--c-sand); }
.galerie-item .cover-wrap { border-radius: 0; height: 100%; }
.galerie-item img { transition: transform 0.5s ease; }
.galerie-item:hover img { transform: scale(1.04); }
.galerie-item--wide { grid-column: span 2; }
.galerie-item--tall { grid-row: span 2; }

.galerie-foot {
  padding: var(--sp-6) var(--sp-6);
  text-align: right;
}
.galerie-foot a {
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  color: var(--c-muted);
  border-bottom: 1px solid currentColor;
  padding-bottom: 2px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color var(--ease);
}
.galerie-foot a:hover { color: var(--c-text); }
.galerie-foot svg { width: 14px; height: 14px; flex-shrink: 0; }

/* 13. WORKSHOPS
    ========================================== */
.s-workshops {
  padding: var(--sp-16) 0;
  background: var(--c-sand);
  border-top: 1px solid var(--c-border);
}
.workshops__grid { display: grid; gap: var(--sp-10); }
.workshops__headline { margin-bottom: var(--sp-6); }
.workshops__body { color: var(--c-muted); line-height: 1.75; margin-bottom: var(--sp-4); }
.workshops__body:last-of-type { margin-bottom: 0; }

.workshops__facts {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-6) var(--sp-10);
  padding: var(--sp-8) 0;
  border-top: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
  margin: var(--sp-8) 0;
}
.fact { display: flex; flex-direction: column; gap: 5px; }
.fact__value {
  font-family: var(--f-serif);
  font-size: 2rem;
  font-weight: 400;
  line-height: 1;
  color: var(--c-text);
}
.fact__label {
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-muted);
}

.workshops__note {
  font-size: 0.875rem;
  font-style: italic;
  color: var(--c-muted);
  margin-bottom: var(--sp-8);
  max-width: 50ch;
}
.workshops__actions { display: flex; flex-wrap: wrap; gap: var(--sp-4); }
.workshops__img-wrap { aspect-ratio: 3/4; }

/* 14. BESUCH
    ========================================== */
.s-besuch {
  padding: var(--sp-16) 0;
  background: var(--c-creme);
}
.besuch__grid { display: grid; gap: var(--sp-10); }
.besuch__headline { margin-bottom: var(--sp-10); }
.besuch__block { margin-bottom: var(--sp-8); }

.block-label {
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-muted);
  margin-bottom: var(--sp-4);
}

.oeffnungszeiten { width: 100%; border-collapse: collapse; }
.oeffnungszeiten tr { border-bottom: 1px solid var(--c-border); }
.oeffnungszeiten td {
  padding: 0.5625rem 0;
  font-size: 0.9375rem;
  line-height: 1.4;
  vertical-align: top;
}
.oeffnungszeiten td:first-child {
  color: var(--c-muted);
  width: 52%;
  padding-right: var(--sp-4);
}
.oeffnungszeiten .is-ruhetag td { opacity: 0.4; }
.oeffnungszeiten .is-workshop td:last-child { color: var(--c-plum); font-style: italic; }

.besuch__address { line-height: 1.8; margin-bottom: var(--sp-2); }
.besuch__maplink {
  display: inline-block;
  font-size: 0.875rem;
  color: var(--c-sage);
  border-bottom: 1px solid currentColor;
  margin-top: var(--sp-2);
  transition: color var(--ease);
}
.besuch__maplink:hover { color: var(--c-text); }

.besuch__contact a {
  display: block;
  margin-bottom: 4px;
  transition: color var(--ease);
}
.besuch__contact a:hover { color: var(--c-sage); }

.besuch__reserve-wrap { margin-top: var(--sp-8); display: flex; flex-wrap: wrap; gap: var(--sp-4); }
.besuch-reserve--desktop { display: none; }
.besuch-reserve--mobile  { display: inline-flex; }

.besuch__map-wrap {
  aspect-ratio: 4/3;
  border-radius: 3px;
  overflow: hidden;
}
.besuch__map-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  filter: saturate(0.7) contrast(0.95);
}

/* 15. FOOTER
    ========================================== */
.site-footer {
  background: var(--c-footer);
  color: var(--c-creme);
  padding: var(--sp-16) 0;
}
.footer__grid { display: grid; gap: var(--sp-8); }

.footer__brand {}
.footer__logo {
  height: 54px;
  width: auto;
  filter: invert(1);
  mix-blend-mode: lighten;
  opacity: 0.88;
  margin-bottom: var(--sp-4);
}
.footer__tagline {
  font-size: 0.8125rem;
  color: rgba(245,239,230,0.38);
  max-width: none;
}

.footer__social { display: flex; gap: var(--sp-6); align-items: center; }
.footer__social a {
  color: rgba(245,239,230,0.5);
  display: flex;
  transition: color var(--ease);
}
.footer__social a:hover { color: var(--c-creme); }
.footer__social svg { width: 20px; height: 20px; }

.footer__legal { display: flex; flex-wrap: wrap; gap: var(--sp-4) var(--sp-6); }
.footer__legal a {
  font-size: 0.8125rem;
  color: rgba(245,239,230,0.3);
  transition: color var(--ease);
}
.footer__legal a:hover { color: rgba(245,239,230,0.65); }

/* 16. SPEISEKARTE PAGE
    ========================================== */
.page-speisekarte main { padding-top: var(--nav-h); }

/* Narrower column for menu readability */
.sk-wrap {
  max-width: 760px;
  margin: 0 auto;
}

.sk-hero {
  padding: var(--sp-16) 0 var(--sp-10);
  border-bottom: 1px solid var(--c-border);
}
.sk-hero h1 { font-size: clamp(2.5rem, 7vw, 4.5rem); margin-top: var(--sp-2); }

.menu-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.875rem;
  color: var(--c-muted);
  margin-bottom: var(--sp-8);
  transition: color var(--ease);
}
.menu-back:hover { color: var(--c-text); }
.menu-back svg { width: 14px; height: 14px; }

.menu-intro {
  padding: var(--sp-8) 0;
  color: var(--c-muted);
  font-size: 0.9375rem;
  line-height: 1.75;
  border-bottom: 1px solid var(--c-border);
}

/* Section blocks – alternating backgrounds via full-bleed wrapper */
.menu-section-wrap {
  margin: 0 calc(-1 * var(--sp-6));
  padding: var(--sp-10) var(--sp-6);
  border-bottom: 1px solid var(--c-border);
}
.menu-section-wrap:last-of-type { border-bottom: none; }
.menu-section-wrap--alt { background: var(--c-sand); }

.menu-section__title {
  font-family: var(--f-serif);
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 400;
  line-height: 1.1;
  margin-bottom: var(--sp-2);
}
.menu-section__note {
  font-size: 0.875rem;
  color: var(--c-muted);
  font-style: italic;
  margin-bottom: var(--sp-6);
  margin-top: var(--sp-2);
}

.menu-list { list-style: none; margin-top: var(--sp-6); }
.menu-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--sp-6);
  padding: 0.8125rem 0;
  border-bottom: 1px solid var(--c-border);
}
.menu-item:last-child { border-bottom: none; }
.menu-item__name { font-size: 0.9375rem; line-height: 1.4; }
.menu-item__desc {
  font-size: 0.8125rem;
  color: var(--c-muted);
  margin-top: 4px;
  max-width: 44ch;
  line-height: 1.5;
}
.menu-item__price {
  font-family: var(--f-serif);
  font-size: 1.125rem;
  font-weight: 400;
  white-space: nowrap;
  flex-shrink: 0;
  color: var(--c-text);
}
.menu-item__price--inquiry {
  font-family: var(--f-sans);
  font-size: 0.8125rem;
  color: var(--c-muted);
  font-style: italic;
}
.menu-item__variant {
  font-size: 0.8125rem;
  color: var(--c-muted);
  font-style: italic;
  margin-top: 3px;
}

/* Allergen + label tags */
.menu-tag {
  display: inline-block;
  font-size: 0.625rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 2px 7px;
  border-radius: 2px;
  vertical-align: middle;
  margin-left: 6px;
  position: relative;
  top: -1px;
}
.menu-tag--vegan    { background: rgba(122,140,110,0.18); color: var(--c-sage); }
.menu-tag--allergen { background: rgba(139,80,104,0.12);  color: var(--c-plum); }
.menu-tag--season   { background: rgba(107,92,84,0.10);   color: var(--c-muted); }

/* Allergen footnote codes (superscript) */
.al {
  font-size: 0.625rem;
  vertical-align: super;
  color: var(--c-muted);
  font-family: var(--f-sans);
  font-weight: 400;
  margin-left: 2px;
  letter-spacing: 0.02em;
}

/* Allergen key block at bottom */
.allergen-block {
  margin-top: var(--sp-10);
  padding: var(--sp-8);
  background: var(--c-sand);
  border-radius: 2px;
}
.allergen-block__title {
  font-size: 0.6875rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-muted);
  margin-bottom: var(--sp-4);
}
.allergen-key {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: var(--sp-2) var(--sp-6);
  font-size: 0.8125rem;
  color: var(--c-muted);
  line-height: 1.6;
}
.allergen-key dt {
  display: inline;
  font-weight: 500;
  color: var(--c-text);
}
.allergen-key dd { display: inline; margin: 0; }
.allergen-key dd::after { content: ''; display: block; }
.allergen-disclaimer {
  margin-top: var(--sp-6);
  font-size: 0.8125rem;
  color: var(--c-muted);
  line-height: 1.65;
  font-style: italic;
  padding-top: var(--sp-4);
  border-top: 1px solid var(--c-border);
}

.menu-cta {
  padding: var(--sp-10) 0;
  text-align: center;
  border-top: 1px solid var(--c-border);
  margin-top: var(--sp-4);
}

/* 17. RESPONSIVE — md ≥ 768px
    ========================================== */
@media (min-width: 768px) {

  /* Nav */
  .nav__toggle { display: none; }
  .nav__reserve { display: inline-flex; }
  .nav__menu {
    display: flex !important;
    position: static;
    background: transparent;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: var(--sp-8);
    flex: 1;
    inset: auto;
    z-index: auto;
  }
  .nav__list { flex-direction: row; gap: var(--sp-8); }
  .nav__link { font-family: var(--f-sans); font-size: 0.875rem; font-weight: 400; }
  .nav__cta { display: none; }

  /* Hero */
  .hero-reserve--desktop { display: inline-flex; }
  .hero-reserve--mobile  { display: none; }

  /* Besuch */
  .besuch-reserve--desktop { display: inline-flex; }
  .besuch-reserve--mobile  { display: none; }

  /* Café */
  .s-cafe__grid { grid-template-columns: 1fr 1fr; align-items: center; }

  /* Angebot */
  .angebot-item { grid-template-columns: 1fr 1fr; align-items: center; }
  .angebot-item--flip .angebot-item__img-wrap { order: 2; }
  .angebot-item--flip .angebot-item__text    { order: 1; }

  /* Galerie */
  .galerie-grid {
    grid-template-columns: repeat(3, 1fr);
    grid-auto-rows: 260px;
  }
  .galerie-item--wide { grid-column: span 2; }
  .galerie-item--tall { grid-row: span 2; }

  /* Workshops */
  .workshops__grid { grid-template-columns: 1fr 1fr; align-items: start; }

  /* Besuch */
  .besuch__grid { grid-template-columns: 1fr 1fr; align-items: start; }

  /* Footer */
  .footer__grid { grid-template-columns: 1fr auto auto; align-items: center; }
}

/* 18. RESPONSIVE — lg ≥ 1024px
    ========================================== */
@media (min-width: 1024px) {
  :root { --sp-16: 5rem; }

  .s-cafe__grid  { grid-template-columns: 2fr 3fr; gap: var(--sp-16); }

  .angebot-item       { grid-template-columns: 3fr 2fr; gap: var(--sp-10); }
  .angebot-item--flip { grid-template-columns: 2fr 3fr; }

  .galerie-grid { grid-auto-rows: 320px; }

  .workshops__grid { grid-template-columns: 3fr 2fr; gap: var(--sp-16); }
  .besuch__grid    { gap: var(--sp-16); }
}

/* 19. RESPONSIVE — xl ≥ 1280px
    ========================================== */
@media (min-width: 1280px) {
  :root { --sp-16: 6rem; }
  .galerie-grid { grid-auto-rows: 380px; }
}

/* 20. PRINT
    ========================================== */
@media print {
  .site-header, .site-footer, .btn, .menu-back, .modal { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  .page-speisekarte main { padding-top: 0; }
  .menu-section { page-break-inside: avoid; }
  .menu-item { border-bottom: 0.5pt solid #ccc; }
}
