/* Mamma Mia Ansbach: Hero-Entwurf
   Aufbau: Foto aus Treviso randlos, darüber ein Rundbogen aus Porzellan (oder Rot), auf dem Scheitel das rote Siegel mit dem Herzlogo. */

@font-face {
  font-family: "Bodoni Moda";
  src: url("../fonts/bodoni-moda-normal.woff2") format("woff2");
  font-weight: 400 700; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Bodoni Moda";
  src: url("../fonts/bodoni-moda-italic.woff2") format("woff2");
  font-weight: 400 700; font-style: italic; font-display: swap;
}
@font-face {
  font-family: "Hanken Grotesk";
  src: url("../fonts/hanken-grotesk-normal.woff2") format("woff2");
  font-weight: 400 700; font-style: normal; font-display: swap;
}

:root {
  --font-display: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --font-text: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;
  --gutter: clamp(16px, 4vw, 48px);
  --ease-out: cubic-bezier(.16, 1, .3, 1);

  --seal: clamp(8.5rem, 14.4vw, 13.25rem);
  --arch-w: clamp(20.5rem, 62vw, 56rem);
  --bar-h: 0px;

  --arch-bg: var(--surface);
  --arch-ink: var(--ink);
  --arch-ink-2: rgb(42 22 18 / .78);
  --arch-icon: var(--mm-rot);
  --seal-bg: var(--surface-brand);
  --seal-ink: var(--ink-on-brand);
  --btn-bg: var(--action);
  --btn-ink: var(--ink-on-brand);
  --btn-bg-hover: var(--surface-brand-deep);
  --link-ink: var(--ink);
  --link-hover: var(--mm-rot);
  --arch-focus: var(--focus);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0;
  background: var(--surface);
  color: var(--ink);
  font: 400 1rem/1.55 var(--font-text);
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
::selection { background: var(--mm-rot); color: var(--mm-milchschaum); }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.icon { width: 1.15em; height: 1.15em; fill: currentColor; flex: none; }

.skip {
  position: absolute; left: var(--gutter); top: -100px; z-index: 50;
  background: var(--mm-espresso); color: var(--mm-milchschaum);
  padding: .6rem 1rem; border-radius: 999px; font-weight: 600; text-decoration: none;
}
.skip:focus { top: 12px; }

/* ---------- Entwurfs-Leiste ---------- */
.draftbar {
  position: relative; z-index: 20;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: .4rem 1.25rem;
  padding: .45rem var(--gutter);
  background: var(--mm-espresso); color: var(--mm-milchschaum);
  font-size: .8125rem; line-height: 1.35;
}
.draftbar__note { margin: 0; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  isolation: isolate;
  height: calc(100svh - var(--bar-h));
  min-height: 37rem;
  max-height: 64rem;
  overflow: hidden;
  background: var(--mm-espresso);
}
.hero__photo { position: absolute; inset: 0; z-index: -2; }
.hero__photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 42%; }
.hero__photo[data-photo="tempel"] img { object-position: 15% 50%; }
.hero__photo[data-photo="kirche"] img { object-position: 50% 50%; }
.hero__photo[data-photo="huegel"] img { object-position: 50% 42%; }
@media (max-width: 700px) { .hero__photo img, .hero__photo[data-photo] img { object-position: 50% 50%; } }
.hero::before {
  /* Schatten nur oben, damit die Navigation auf hellem Himmel lesbar bleibt */
  content: ""; position: absolute; inset: 0 0 auto 0; height: 14rem; z-index: -1;
  background: linear-gradient(to bottom, rgb(42 22 18 / .74), rgb(42 22 18 / .56) 2.75rem, rgb(42 22 18 / .3) 6.5rem, rgb(42 22 18 / .1) 10rem, rgb(42 22 18 / 0));
  pointer-events: none;
}

.topnav {
  position: absolute; inset: 0 0 auto 0; z-index: 5;
  display: flex; align-items: center; gap: 1.5rem;
  padding: 1.35rem var(--gutter);
  color: var(--ink-on-brand);
  font-weight: 600; font-size: .9375rem; letter-spacing: .01em;
}
.topnav__links { display: flex; gap: clamp(1.25rem, 2.4vw, 2.25rem); list-style: none; margin: 0; padding: 0; }
.topnav a { text-decoration: none; text-underline-offset: .4em; text-decoration-thickness: 1.5px; }
.topnav__links a:hover { text-decoration-line: underline; }
.topnav__tel { margin-left: auto; display: inline-flex; align-items: center; gap: .5rem; font-variant-numeric: tabular-nums; }
.topnav__tel:hover .topnav__num { text-decoration: underline; text-underline-offset: .4em; text-decoration-thickness: 1.5px; }
.topnav__menu {
  display: none; align-items: center; gap: .45rem;
  font: inherit; color: inherit; background: rgb(42 22 18 / .28); cursor: pointer;
  border: 1px solid rgb(255 243 234 / .45); border-radius: 999px; padding: .5rem .9rem; min-height: 44px;
}
.topnav__menu .icon--close { display: none; }
.topnav__menu[aria-expanded="true"] .icon--open { display: none; }
.topnav__menu[aria-expanded="true"] .icon--close { display: block; }
.topnav :focus-visible { outline-color: var(--mm-milchschaum); }

.menu {
  position: absolute; z-index: 6; top: 4.6rem; left: var(--gutter); right: var(--gutter);
  background: var(--surface); color: var(--ink);
  border-radius: 1.25rem; padding: .75rem 1.25rem 1.1rem;
  box-shadow: 0 18px 40px -18px rgb(42 22 18 / .55), 0 2px 8px rgb(42 22 18 / .18);
}
.menu ul { list-style: none; margin: 0; padding: 0; }
.menu li + li { border-top: 1px solid var(--line); }
.menu ul a { display: block; padding: .85rem 0; font: 500 1.375rem/1.2 var(--font-display); text-decoration: none; }
.menu__tel { margin: .6rem 0 0; font-size: .9375rem; color: rgb(42 22 18 / .78); }
.menu__tel a { color: var(--mm-rot); font-weight: 700; text-decoration: none; margin-left: .35rem; font-variant-numeric: tabular-nums; }

/* ---------- Bogen ---------- */
.arch {
  position: absolute; z-index: 3; bottom: 0; left: 0; right: 0;
  width: min(var(--arch-w), calc(100% - 2 * 16px));
  margin-inline: auto;
  padding: max(calc(var(--seal) / 2 + 2.25rem), calc(var(--arch-w) * .16)) clamp(1.25rem, 4vw, 3.5rem) clamp(1.75rem, 4.2svh, 3.25rem);
  border-radius: 999px 999px 0 0;
  background: var(--arch-bg);
  color: var(--arch-ink);
  text-align: center;
  display: flex; flex-direction: column; align-items: center;
}

/* Porzellanfläche des Bogens als eigene Ebene: beim Scrollen öffnet sie sich auf die volle Breite (site.js) */
.arch__bg {
  --aw: min(var(--arch-w), calc(100vw - 32px));
  position: absolute; z-index: -1; top: 0; bottom: 0; left: 50%;
  width: 100vw; translate: -50% 0;
  background: var(--arch-bg);
  clip-path: inset(0 calc((100vw - var(--aw)) / 2) 0 calc((100vw - var(--aw)) / 2) round calc(var(--aw) / 2) calc(var(--aw) / 2) 0 0);
}

.seal {
  position: absolute; top: 0; left: 50%;
  translate: -50% -50%;
  width: var(--seal); aspect-ratio: 1;
  border-radius: 50%;
  background: var(--seal-bg); color: var(--seal-ink);
  display: grid; place-items: center;
  box-shadow: 0 14px 32px -14px rgb(42 22 18 / .55), 0 3px 8px -2px rgb(42 22 18 / .28);
}
.seal__ring { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.seal__line { fill: none; stroke: currentColor; stroke-width: 1; opacity: .6; }
.seal__dot { fill: currentColor; }
.seal__text {
  fill: currentColor;
  font: 600 12.5px var(--font-text);
  letter-spacing: 1.6px;
}
.seal__logo {
  position: relative;
  width: 74%; height: auto; aspect-ratio: 916 / 468;
  --logo-line: 9;
  --logo-weight: 2.2;
  overflow: visible;
  translate: 0 2%;
}

.arch__name {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.5rem, 5.4vw, 5rem);
  line-height: 1;
  letter-spacing: .07em;
  margin-right: -.07em; /* Sperrung optisch mittig */
  text-transform: uppercase;
  text-wrap: balance;
}
.arch__line {
  margin: .7rem 0 0;
  font-family: var(--font-display);
  font-size: clamp(1.0625rem, 1.55vw, 1.4rem);
  line-height: 1.35;
  color: var(--arch-ink-2);
  text-wrap: balance;
  max-width: 34ch;
}
.arch__line em { font-style: italic; color: var(--arch-ink); }
.arch__status {
  margin: clamp(1rem, 2.2svh, 1.4rem) 0 0;
  display: inline-flex; align-items: center; gap: .45rem;
  font-weight: 600; font-size: .9375rem; color: var(--arch-ink);
  font-variant-numeric: tabular-nums;
}
.arch__status .icon { color: var(--arch-icon); width: 1.2em; height: 1.2em; }
.arch__actions {
  margin-top: clamp(.9rem, 2svh, 1.25rem);
  display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: .75rem 1.5rem;
}
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  min-height: 3rem; padding: 0 1.5rem;
  border-radius: 999px;
  background: var(--btn-bg); color: var(--btn-ink);
  font-weight: 700; font-size: 1rem; letter-spacing: .01em; text-decoration: none;
  box-shadow: 0 8px 18px -10px rgb(158 18 25 / .7);
  transition: background-color .25s var(--ease-out), translate .2s var(--ease-out), box-shadow .25s var(--ease-out);
}
.btn:hover { background: var(--btn-bg-hover); box-shadow: 0 12px 22px -12px rgb(158 18 25 / .8); }
.btn:active { translate: 0 1px; }
.link {
  display: inline-flex; align-items: center; gap: .4rem;
  min-height: 3rem;
  font-weight: 600; color: var(--link-ink);
  text-decoration: underline; text-underline-offset: .35em; text-decoration-thickness: 1.5px;
  transition: color .2s var(--ease-out);
}
.link .icon { transition: translate .25s var(--ease-out); }
.link:hover { color: var(--link-hover); }
.link:hover .icon { translate: 3px 0; }
.arch :focus-visible { outline-color: var(--arch-focus); }

/* ---------- Bewegung: ein Moment beim Laden, das Siegel dreht beim Scrollen ---------- */
@media (prefers-reduced-motion: no-preference) {
  .hero__photo img { animation: mm-settle 1.9s var(--ease-out) both; }
  .arch { animation: mm-rise 1.1s var(--ease-out) .08s both; }
  .seal { animation: mm-stamp 1s var(--ease-out) .3s both; }
  @keyframes mm-settle { from { transform: scale(1.07); } }
  @keyframes mm-rise { from { transform: translateY(1.75rem); } }
  @keyframes mm-stamp { from { scale: 1.14; rotate: -12deg; } }

  @supports (animation-timeline: scroll()) {
    .seal__ring { animation: mm-turn linear both; animation-timeline: scroll(root); }
    .hero__photo { animation: mm-drift linear both; animation-timeline: scroll(root); animation-range: 0 100svh; }
    @keyframes mm-turn { to { rotate: 160deg; } }
    @keyframes mm-drift { to { transform: translateY(9%); } }
  }
}

/* ---------- Schmal ---------- */
@media (max-width: 860px) {
  .topnav__links { display: none; }
  .topnav__menu { display: inline-flex; }
  .topnav__tel { margin-left: auto; }
}
@media (max-width: 560px) {
  .draftbar { font-size: .75rem; gap: .35rem; padding-block: .4rem; }
  .draftbar__long { display: none; }
  .topnav { padding-top: 1rem; gap: .75rem; }
  .topnav__num { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .topnav__tel {
    width: 44px; height: 44px; justify-content: center;
    border-radius: 50%; border: 1px solid rgb(255 243 234 / .45); background: rgb(42 22 18 / .28);
  }
  .topnav__tel .icon { width: 1.25rem; height: 1.25rem; }
  .topnav__menu { order: -1; }
  .topnav__tel { order: 2; }
  .arch { width: calc(100% - 2 * 16px); --arch-w: calc(100vw - 32px); }
  .arch__name { letter-spacing: .055em; margin-right: -.055em; }
  .arch__actions { gap: .5rem 1.25rem; }
}
@media (max-height: 640px) and (min-width: 561px) {
  .arch__status { display: none; }
}
