/* Sachsenperle – STJUARD port additions.

   theme.css is an unmodified copy of the approved design
   (design repository: assets/css/themes/sachsenperle.css). This file only adds
   what the static design did not have: local fonts, the database driven menu
   card, event teasers, sub pages, and opening hours. It reuses the design's
   tokens, rules, frames, and breakpoints (1080 / 800 / 540 px).
*/

/* Fonts. The design loaded Cormorant Garamond and Source Sans 3 from Google
   Fonts. No font is downloaded here: both families are named first so an
   installed copy is used. Otherwise metric-adjusted local fallbacks keep the
   design's line lengths: Cormorant's light display weights map onto the
   regular cut of a classic serif, and a size-adjusted grotesk stands in for
   the narrower Source Sans. */
@font-face {
  font-family: "Sachsenperle Serif Baskerville";
  src: local("Baskerville"), local("Baskerville-Regular");
  font-style: normal;
  font-weight: 300 800;
  size-adjust: 96%;
}

@font-face {
  font-family: "Sachsenperle Serif Baskerville";
  src: local("Baskerville Italic"), local("Baskerville-Italic");
  font-style: italic;
  font-weight: 300 800;
  size-adjust: 96%;
}

@font-face {
  font-family: "Sachsenperle Serif Palatino";
  src: local("Palatino Linotype"), local("Book Antiqua"), local("Palatino");
  font-style: normal;
  font-weight: 300 800;
  size-adjust: 91%;
}

@font-face {
  font-family: "Sachsenperle Serif Palatino";
  src: local("Palatino Linotype Italic"), local("Book Antiqua Italic"), local("Palatino Italic");
  font-style: italic;
  font-weight: 300 800;
  size-adjust: 91%;
}

@font-face {
  font-family: "Sachsenperle Sans";
  src: local("Helvetica Neue"), local("HelveticaNeue"), local("Segoe UI"), local("Arial");
  font-weight: 300 450;
  size-adjust: 91%;
}

@font-face {
  font-family: "Sachsenperle Sans";
  src: local("Helvetica Neue Medium"), local("HelveticaNeue-Medium"), local("Segoe UI Semibold"),
    local("Arial Bold");
  font-weight: 451 650;
  size-adjust: 91%;
}

@font-face {
  font-family: "Sachsenperle Sans";
  src: local("Helvetica Neue Bold"), local("HelveticaNeue-Bold"), local("Segoe UI Bold"),
    local("Arial Bold");
  font-weight: 651 900;
  size-adjust: 91%;
}

:root {
  --serif: "Cormorant Garamond", "Sachsenperle Serif Baskerville", "Sachsenperle Serif Palatino",
    Georgia, serif;
  --sans: "Source Sans 3", "Sachsenperle Sans", system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, sans-serif;
}

/* Menu card: a printed Wirtshauskarte on paper */

.menu-card-section {
  background:
    linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,0)),
    var(--paper);
  border-top: 1px solid rgba(74,51,40,.08);
}

.menu-card {
  position: relative;
  max-width: 780px;
  margin: 62px auto 0;
  padding: 70px clamp(26px, 7vw, 84px) 58px;
  background:
    radial-gradient(circle at 16% 10%, rgba(255,255,255,.62), transparent 44%),
    linear-gradient(180deg, #fbf5e6 0%, #f3e6c6 100%);
  border: 1px solid rgba(72,52,34,.22);
  box-shadow: var(--shadow-strong);
  transform: rotate(-.35deg);
}

.menu-card::before,
.menu-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.menu-card::before {
  inset: 12px;
  border: 1px solid rgba(72,52,34,.30);
}

.menu-card::after {
  inset: 18px;
  border: 1px solid rgba(72,52,34,.12);
}

.menu-card-page {
  max-width: 860px;
  margin-top: 0;
  transform: none;
}

.menu-card-group + .menu-card-group { margin-top: 52px; }

.menu-card-category {
  margin: 0;
  color: var(--green-dark);
  font-family: var(--serif);
  font-size: clamp(25px, 2.8vw, 33px);
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: .16em;
  text-align: center;
  text-transform: uppercase;
}

.menu-card-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 12px 0 26px;
  color: var(--gold);
  font-size: 11px;
  line-height: 1;
}

.menu-card-ornament::before,
.menu-card-ornament::after {
  content: "";
  width: 56px;
  height: 1px;
  background: currentColor;
  opacity: .55;
}

.menu-card-category-desc {
  max-width: 520px;
  margin: -12px auto 26px;
  color: var(--muted);
  font-family: var(--serif);
  font-size: 19px;
  font-style: italic;
  line-height: 1.4;
  text-align: center;
}

.menu-card-items {
  margin: 0;
  padding: 0;
  list-style: none;
}

.menu-card-item { padding: 11px 0; }

.menu-card-line {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.menu-card-name {
  color: var(--ink);
  font-family: var(--serif);
  font-size: 24px;
  font-weight: 600;
  line-height: 1.2;
}

.menu-card-leader {
  flex: 1;
  min-width: 22px;
  border-bottom: 2px dotted rgba(72,52,34,.34);
  transform: translateY(-6px);
}

.menu-card-price {
  color: var(--wood-dark);
  font-family: var(--serif);
  font-size: 23px;
  font-weight: 600;
  font-variant-numeric: lining-nums tabular-nums;
  white-space: nowrap;
}

.menu-card-desc {
  max-width: 34em;
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.5;
}

.menu-card-variants {
  margin: 6px 0 0;
  padding: 0 0 0 20px;
  list-style: none;
}

.menu-card-variant { padding: 1px 0; }

.menu-card-variant .menu-card-name {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .02em;
}

.menu-card-variant .menu-card-price { font-size: 21px; }

.menu-card-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  margin-top: 46px;
}

.menu-card-footer .menu-card-ornament { margin: 0 0 8px; }
.menu-card-footer .text-link { margin-top: 0; }

.menu-card-empty {
  color: var(--muted);
  font-family: var(--serif);
  font-size: 28px;
  text-align: center;
}

/* Event teasers inside the design's event list */

.event-teaser {
  display: grid;
  grid-template-columns: 96px 1fr auto;
  gap: 30px;
  align-items: center;
  padding: 30px 0;
  border-bottom: 1px solid var(--line-light);
}

.event-teaser-date {
  min-height: 96px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(216,190,115,.35);
  background: rgba(255,255,255,.03);
  text-align: center;
}

.event-teaser-day {
  color: var(--gold-light);
  font-family: var(--serif);
  font-size: 44px;
  font-weight: 600;
  line-height: 1;
}

.event-teaser-month {
  margin-top: 5px;
  color: rgba(255,248,237,.62);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.event-teaser h3 {
  margin: 6px 0;
  font-family: var(--serif);
  font-size: clamp(30px, 3vw, 40px);
  font-weight: 600;
  line-height: 1.02;
}

.event-teaser p {
  max-width: 520px;
  margin: 0;
  color: rgba(255,248,237,.66);
  font-size: 15px;
}

.event-teaser-more {
  display: inline-flex;
  gap: 10px;
  color: var(--gold-light);
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
}

.event-teaser-more span { transition: transform .2s ease; }
.event-teaser:hover .event-teaser-more span { transform: translateX(4px); }
.event-teaser:hover h3 { color: #fff; }

/* Sub page hero (Speisekarte, Veranstaltung, Impressum, Datenschutz) */

.page-hero {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(115deg, rgba(27,41,31,.97) 0%, rgba(55,76,49,.95) 35%, rgba(96,71,47,.92) 100%);
  color: #fff8ed;
}

.page-hero::before {
  content: "";
  position: absolute;
  width: 46vw;
  height: 46vw;
  right: -14vw;
  top: -26vw;
  border-radius: 50%;
  border: 1px solid rgba(216,190,115,.18);
  box-shadow:
    0 0 0 90px rgba(216,190,115,.025),
    0 0 0 190px rgba(216,190,115,.018);
  pointer-events: none;
}

.page-hero::after {
  content: "";
  position: absolute;
  left: 7%;
  bottom: 44px;
  width: 300px;
  height: 1px;
  background: linear-gradient(90deg, var(--gold), transparent);
  opacity: .55;
}

.page-hero-inner {
  position: relative;
  z-index: 2;
  padding: 172px 0 96px;
}

.page-hero h1 {
  max-width: 900px;
  margin: 0;
  font-family: var(--serif);
  font-size: clamp(54px, 6.4vw, 92px);
  font-weight: 600;
  line-height: .95;
  letter-spacing: -.025em;
  text-shadow: 0 2px 10px rgba(18,12,8,.18);
}

.page-hero-lead {
  max-width: 640px;
  margin: 26px 0 0;
  color: rgba(255,248,237,.81);
  font-size: clamp(18px, 1.5vw, 21px);
}

.page-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 36px;
}

.page-back {
  display: flex;
  width: fit-content;
  gap: 10px;
  margin-bottom: 28px;
  color: rgba(255,248,237,.70);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.page-back:hover { color: var(--gold-light); }

.page-section {
  background:
    linear-gradient(180deg, rgba(255,255,255,.14), rgba(255,255,255,0)),
    var(--cream-light);
}

.page-section-paper {
  background:
    linear-gradient(180deg, rgba(255,255,255,.10), rgba(255,255,255,0)),
    var(--paper);
}

/* Event detail */

.event-detail-grid {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(50px, 8vw, 110px);
  align-items: start;
}

.event-detail-media {
  aspect-ratio: 4 / 3;
  margin: 0 0 44px;
  transform: rotate(-.6deg);
}

.event-detail-copy .lead { margin-top: 0; }
.event-detail-copy p:not(.lead) { color: var(--muted); }

.event-facts .button { margin-top: 30px; }

/* Opening hours inside the design's visit block */

.hours-list {
  display: grid;
  gap: 3px;
  margin: 2px 0 0;
}

.hours-list div {
  display: flex;
  justify-content: space-between;
  gap: 18px;
}

.hours-list dt {
  font-family: var(--serif);
  font-size: 21px;
  font-weight: 600;
}

.hours-list dd {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.hours-note {
  display: block;
  margin-top: 10px;
  color: var(--muted);
  font-size: 14px;
}

/* Legal pages */

.legal-card {
  max-width: 820px;
  padding: 58px clamp(24px, 6vw, 72px);
  background:
    linear-gradient(180deg, rgba(255,255,255,.22), rgba(255,255,255,0)),
    var(--paper);
  border: 1px solid rgba(72,52,34,.18);
  box-shadow: var(--shadow-soft);
}

.legal-card h2 {
  margin: 0 0 16px;
  font-family: var(--serif);
  font-size: 36px;
  font-weight: 600;
  line-height: 1.05;
}

.legal-card h2:not(:first-child) { margin-top: 38px; }

.legal-notice {
  margin: 34px 0 0;
  padding: 18px 22px;
  border-left: 3px solid var(--gold);
  background: rgba(255,255,255,.38);
  color: var(--muted);
  font-size: 15px;
}

/* Tour modal: keep the header text clear of the close button (the design
   only reserved that space below 800 px). */
.tour-modal-header { padding-right: 64px; }

/* Shared STJUARD attribution, embedded in the design's quiet footer line
   (.made-with in theme.css). */
.stjuard-attribution.made-with { margin: 0; }

.made-with a {
  border-bottom: 1px solid rgba(216,190,115,.30);
  transition: color .2s ease, border-color .2s ease;
}

.made-with a:hover {
  color: var(--gold-light);
  border-bottom-color: currentColor;
}

/* Responsive, following the design's breakpoints */

@media (max-width: 1080px) {
  .event-teaser { grid-template-columns: 86px 1fr; }
  .event-teaser-more { grid-column: 2; }
}

@media (max-width: 800px) {
  .menu-card {
    margin-top: 46px;
    padding: 56px 26px 46px;
    transform: none;
  }

  .menu-card-name { font-size: 22px; }
  .menu-card-price { font-size: 21px; }

  .page-hero-inner { padding: 140px 0 78px; }

  .event-detail-grid {
    grid-template-columns: 1fr;
    gap: 45px;
  }

  .event-detail-media { transform: none; }
}

@media (max-width: 540px) {
  .menu-card {
    padding: 48px 20px 40px;
    border-left: 0;
    border-right: 0;
  }

  .menu-card::before { inset: 8px; }
  .menu-card::after { inset: 13px; }

  .menu-card-category { letter-spacing: .1em; }
  .menu-card-name { font-size: 20px; }
  .menu-card-price { font-size: 19px; }
  .menu-card-variants { padding-left: 12px; }

  .event-teaser {
    grid-template-columns: 70px 1fr;
    gap: 18px;
  }

  .event-teaser-date { min-height: 76px; }
  .event-teaser-day { font-size: 34px; }

  .page-hero-inner { padding: 122px 0 64px; }
  .page-hero h1 { font-size: 47px; }

  .page-hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .legal-card { padding: 40px 20px; }
}
