/* ============================================================
   Druckerei Wenin – Design-System
   Alles Zentrale steht in :root und ist pro Projekt tauschbar.
   ============================================================ */
:root {
  /* Palette */
  --paper: #f6f2ea;
  --paper-2: #efe8dc;
  --ink: #191614;
  --body: #3b352e;
  --muted: #8a7f70;
  --line: #e2d9ca;
  --accent: #12384e;
  --accent-deep: #0c2836;
  --dark: #16120e;
  --dark-2: #211b15;
  --gold: #c39a4e;
  --gold-soft: #d9ba7c;

  /* Form */
  --r: 16px;
  --r-sm: 10px;
  --container: 1180px;
  --gutter: clamp(1.1rem, 4vw, 2.2rem);
  --header-h: 74px;

  /* Typografie */
  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --step: clamp(3rem, 7vw, 6rem);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  color: var(--body);
  background: var(--paper);
  line-height: 1.65;
  font-size: 1.02rem;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3 { color: var(--ink); line-height: 1.1; font-weight: 600; }
p { margin: 0 0 1rem; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { max-width: 100%; }
em { font-style: italic; }

.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--step); }
.icon { display: inline-block; vertical-align: -0.18em; }

.skip-link {
  position: absolute; left: -999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--paper); padding: .6rem 1rem; border-radius: 0 0 var(--r-sm) 0;
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

/* ---------------- Buttons ---------------- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  padding: .78rem 1.3rem; border-radius: 999px;
  font-family: var(--font-sans); font-size: .96rem; font-weight: 600;
  border: 1px solid transparent; cursor: pointer; line-height: 1;
  transition: transform .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
  text-decoration: none;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn--accent { background: var(--accent); color: #fff; }
.btn--accent:hover { background: var(--accent-deep); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--ink); }
.btn--gold { background: var(--gold); color: #241c0d; }
.btn--gold:hover { background: var(--gold-soft); }
.btn--sm { padding: .55rem 1rem; font-size: .88rem; }
.btn--lg { padding: .95rem 1.6rem; font-size: 1.02rem; }

/* ---------------- Overline / Section-Head ---------------- */
.overline {
  display: inline-block; text-transform: uppercase; letter-spacing: .16em;
  font-size: .72rem; font-weight: 600; color: var(--accent); margin-bottom: .7rem;
}
.overline--gold { color: var(--gold); }

.section-head {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 1.5rem;
  padding-bottom: 1.1rem; margin-bottom: 2.2rem; border-bottom: 1px solid var(--line);
}
.section-title { font-family: var(--font-display); font-size: clamp(1.7rem, 3.4vw, 2.6rem); margin: 0; letter-spacing: -0.01em; }
.section-more { display: inline-flex; align-items: center; gap: .35rem; font-weight: 600; font-size: .92rem; white-space: nowrap; }

/* ---------------- Header ---------------- */
.nav-toggle { position: absolute; opacity: 0; pointer-events: none; }
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 80%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .2s ease, background .2s ease;
}
.site-header.is-scrolled { border-bottom-color: var(--line); background: color-mix(in srgb, var(--paper) 92%, transparent); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: var(--header-h); }

.brand { display: inline-flex; align-items: center; gap: .6rem; color: var(--ink); }
.brand:hover { text-decoration: none; }
.brand__logo { height: 52px; width: auto; display: block; }
.brand__mark svg { display: block; }
.brand__name { font-family: var(--font-display); font-weight: 600; font-size: 1.2rem; letter-spacing: -0.01em; }

.nav { display: flex; align-items: center; gap: 1.6rem; }
.nav__list { display: flex; align-items: center; gap: 1.4rem; list-style: none; margin: 0; padding: 0; }
.nav__link { color: var(--body); font-weight: 500; font-size: .96rem; }
.nav__link:hover { color: var(--ink); text-decoration: none; }
.nav__cta { margin-left: .4rem; }

.burger {
  display: none; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: var(--r-sm); color: var(--ink); cursor: pointer;
  border: 1px solid var(--line); background: color-mix(in srgb, var(--paper) 70%, transparent);
}
.burger__close { display: none; }

/* ---------------- Hero (Vollbild-Hintergrund) ---------------- */
.hero {
  --hero-img: none;
  position: relative; isolation: isolate; overflow: hidden;
  background: var(--dark);              /* Fallback, falls kein Bild vorhanden */
  /* Genau ein Bildschirm: Header + Hero fuellen die Sichtflaeche. Ist das Bild
     hoeher, wird es unten beschnitten (cover) - beim Scrollen kommt sofort der
     naechste Abschnitt. svh = stabile Hoehe auf Mobilgeraeten. */
  height: calc(100vh - var(--header-h));
  height: calc(100svh - var(--header-h));
  min-height: 520px;
  display: flex;
  padding-block: clamp(1.6rem, 4vw, 2.8rem);
  color: #fff;
}
/* Hintergrundbild: leicht unscharf + entsättigt. Negatives inset, damit die
   weichen Blur-Ränder außerhalb des sichtbaren Bereichs liegen. */
.hero::before {
  content: ""; position: absolute; inset: -30px; z-index: -2;
  background-image: var(--hero-img);
  background-size: cover; background-position: center;
  filter: blur(3.4px) grayscale(.62);
}
/* Abdunkelung für Textkontrast: weicher Scrim hinter der Headline (das Foto hat
   oben hellen Himmel) + Basisverlauf. So bleibt das Bild an den Rändern sichtbar. */
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    radial-gradient(ellipse 76% 58% at 50% 54%, rgba(18,16,14,.46) 0%, rgba(18,16,14,.24) 55%, rgba(18,16,14,0) 80%),
    linear-gradient(180deg, rgba(18,16,14,.30) 0%, rgba(18,16,14,.34) 45%, rgba(18,16,14,.52) 100%);
}
/* Zeile 1 nimmt den Restplatz (schrumpft bei kleinen Fenstern), Zeile 3 ist
   genau so hoch wie ihr Inhalt - dadurch laeuft der Hero nie ueber. */
.hero__inner { display: grid; grid-template-rows: minmax(0, 1fr) auto auto; width: 100%; }

/* Headline mittig auf dem Bild */
.hero__center { grid-row: 2; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center; }
.hero .overline {
  color: #fff; text-shadow: 0 1px 10px rgba(0,0,0,.45);
  background: rgba(18,16,14,.30); backdrop-filter: blur(3px);
  padding: .42em .95em; border-radius: 999px;
  border: 1px solid rgba(255,255,255,.16);
}
.hero__title {
  font-family: var(--font-display); font-weight: 600; color: #fff;
  font-size: clamp(2.5rem, 7vw, 5rem); line-height: 1.03; letter-spacing: -0.02em;
  margin: .2rem 0 0; max-width: 18ch;
  text-shadow: 0 2px 24px rgba(0,0,0,.45);
}
.hero__title em { color: var(--gold-soft); font-style: italic; }

/* Alles Weitere darunter */
.hero__below { grid-row: 3; align-self: end; text-align: center; padding-top: clamp(1.6rem, 4vw, 2.6rem); }
.hero__lead {
  font-size: clamp(1.02rem, 1.6vw, 1.24rem); color: rgba(255,255,255,.92);
  max-width: 52ch; margin-inline: auto; text-shadow: 0 1px 12px rgba(0,0,0,.4);
}
.hero__actions { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 1.5rem; justify-content: center; }
.btn--on-image { background: rgba(255,255,255,.10); color: #fff; border-color: rgba(255,255,255,.55); backdrop-filter: blur(4px); }
.btn--on-image:hover { background: rgba(255,255,255,.20); border-color: #fff; }

/* Anker nicht unter dem sticky Header verstecken */
[id="anfahrt"], [id="kontakt"] { scroll-margin-top: calc(var(--header-h) + 12px); }

/* ---------------- Split ---------------- */
.split__grid { display: grid; grid-template-columns: 0.85fr 1.25fr; gap: clamp(1.6rem, 5vw, 4rem); }
.split__aside .section-head { border-bottom: 0; margin-bottom: 1rem; padding-bottom: 0; }
.lead { font-size: clamp(1.1rem, 1.7vw, 1.3rem); color: var(--ink); font-family: var(--font-display); line-height: 1.4; }
.tick-list { list-style: none; margin: 1.4rem 0 0; padding: 0; display: grid; gap: .7rem; }
.tick-list li { display: flex; align-items: center; gap: .6rem; }
.tick-list .icon { color: var(--accent); }

/* ---------------- Gallery / Bild-Slots ---------------- */
.gallery__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1rem, 2.5vw, 1.6rem); }
.gallery__item { margin: 0; aspect-ratio: 4 / 3; border-radius: var(--r); overflow: hidden; }
.gallery__item .ri { width: 100%; height: 100%; object-fit: cover; display: block; }

.img-ph {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem;
  width: 100%; height: 100%; min-height: 200px;
  background:
    repeating-linear-gradient(45deg, var(--paper-2), var(--paper-2) 12px, #ece4d6 12px, #ece4d6 24px);
  border: 1px dashed #cdc2b0; border-radius: var(--r); color: var(--muted);
}
.img-ph__num { font-family: var(--font-display); font-size: 2rem; color: #b7ab98; line-height: 1; }
.img-ph__name { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .82rem; }

/* ---------------- Process ---------------- */
.process__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }
.step { padding: 1.6rem clamp(1rem, 2.2vw, 1.8rem); border-left: 1px solid var(--line); position: relative; }
.step:first-child { border-left: 0; padding-left: 0; }
.step__no { display: block; font-family: var(--font-display); font-size: 1rem; color: var(--gold); letter-spacing: .1em; }
.step__icon { display: inline-flex; margin: .9rem 0 .7rem; color: var(--accent); }
.step__title { font-size: 1.2rem; margin: 0 0 .4rem; }
.step__text { color: var(--body); margin: 0; }

/* ---------------- Dunkle Kontrast-Sektion ---------------- */
.section-dark { background: var(--dark); color: #ece5da; padding-block: clamp(3rem, 7vw, 5.5rem); }
.section-dark__inner { max-width: 760px; }
.statement {
  font-family: var(--font-display); font-size: clamp(1.6rem, 3.6vw, 2.6rem);
  line-height: 1.25; color: #f4eee3; margin: .3rem 0 1.7rem;
}
.statement em { color: var(--gold-soft); }

/* ---------------- Kontakt-Karte / Anfahrt ---------------- */
.contact-card {
  display: block; font-style: normal; margin-top: 1.4rem;
  background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r);
  padding: 1.3rem 1.4rem; line-height: 1.8;
}
.contact-card__name { display: block; font-family: var(--font-display); font-size: 1.15rem; color: var(--ink); margin-bottom: .3rem; }
.contact-card__links { display: block; margin-top: .8rem; }

/* ---------------- Consent-Embed ---------------- */
.embed {
  position: relative; aspect-ratio: var(--embed-ratio, 4 / 3);
  background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden;
}
.embed__gate { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1rem; text-align: center; padding: 1.4rem; }
.embed__text { max-width: 42ch; font-size: .9rem; color: var(--body); margin: 0; }
.embed iframe { width: 100%; height: 100%; border: 0; display: block; }

/* ---------------- Anfahrt: Eingangsbild ---------------- */
.entrance { margin: clamp(1.4rem, 3vw, 2.2rem) 0 0; }
.entrance .ri { width: 100%; height: auto; display: block; border: 1px solid var(--line); border-radius: var(--r); }
.entrance .img-ph { aspect-ratio: 16 / 7; min-height: 220px; }
.entrance figcaption { margin-top: .6rem; font-size: .82rem; color: var(--muted); font-style: italic; }

/* ---------------- CTA ---------------- */
.cta__inner { text-align: center; }
.cta .section-head { justify-content: center; text-align: center; border-bottom: 0; margin-bottom: 1rem; }
.cta .section-head__main { display: inline-block; }
.cta__actions { display: flex; flex-wrap: wrap; gap: .9rem; justify-content: center; margin-top: 1.6rem; }

/* ---------------- Rechtstexte ---------------- */
.page-title { font-family: var(--font-display); font-size: clamp(2rem, 4vw, 3rem); margin: .2rem 0 1.8rem; letter-spacing: -0.01em; }
.legal__inner { max-width: 760px; }
.prose { font-size: 1rem; }
.prose__intro { color: var(--muted); }
.prose h2 { font-family: var(--font-display); font-size: 1.25rem; margin: 2rem 0 .5rem; }
.prose a { text-decoration: underline; text-underline-offset: 2px; }
.prose code { background: var(--paper-2); padding: .1em .4em; border-radius: 5px; font-size: .88em; }
.prose__note {
  margin-top: 2rem; padding: 1rem 1.2rem; background: var(--paper-2);
  border-left: 3px solid var(--accent); border-radius: 0 var(--r-sm) var(--r-sm) 0;
  font-size: .9rem; color: var(--muted);
}

/* ---------------- Footer ---------------- */
.site-footer { background: var(--dark); color: #cbc2b4; margin-top: var(--step); padding-block: clamp(2.6rem, 5vw, 4rem) 1.4rem; }
.site-footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr 1fr; gap: 2rem; }
.site-footer__name { font-family: var(--font-display); font-size: 1.35rem; color: #fff; }
.site-footer__tag { color: #9a9081; margin: .4rem 0 0; }
.foot-col__title { font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--gold-soft); margin: 0 0 .8rem; }
.foot-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.foot-col a, .foot-col li { color: #cbc2b4; }
.foot-col a:hover { color: #fff; }
.site-footer__bottom {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem;
  margin-top: 2.4rem; padding-top: 1.2rem; border-top: 1px solid rgba(255,255,255,.12);
  font-size: .84rem; color: #9a9081;
}

/* ---------------- Back-to-top ---------------- */
.to-top {
  position: fixed; right: 1.1rem; bottom: 1.1rem; z-index: 40;
  width: 46px; height: 46px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--accent); color: #fff; box-shadow: 0 6px 20px rgba(0,0,0,.18);
  opacity: 0; visibility: hidden; transform: translateY(10px); transition: opacity .25s, transform .25s, visibility .25s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { background: var(--accent-deep); text-decoration: none; }

/* ---------------- Crossfade ---------------- */
.crossfade { position: relative; border-radius: var(--r); overflow: hidden; }
.crossfade > div { position: absolute; inset: 0; }
.crossfade__a, .crossfade__b { animation: cf 12s infinite; }
.crossfade__b { animation-delay: 6s; }
.crossfade .ri { width: 100%; height: 100%; object-fit: cover; }
@keyframes cf { 0%,40% { opacity: 1; } 50%,90% { opacity: 0; } 100% { opacity: 1; } }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  .burger { display: inline-flex; }
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--paper); border-bottom: 1px solid var(--line);
    padding: 1rem var(--gutter) 1.4rem; transform: translateY(-8px); opacity: 0; pointer-events: none;
    transition: opacity .2s ease, transform .2s ease;
  }
  .nav__list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav__link { display: block; padding: .85rem 0; border-bottom: 1px solid var(--line); }
  .nav__cta { margin: 1rem 0 0; justify-content: center; }
  .nav-toggle:checked ~ .site-header .nav { opacity: 1; transform: translateY(0); pointer-events: auto; }
  .nav-toggle:checked ~ .site-header .burger__open { display: none; }
  .nav-toggle:checked ~ .site-header .burger__close { display: inline-flex; }

  .split__grid { grid-template-columns: 1fr; }
  .process__grid { grid-template-columns: 1fr; }
  .step { border-left: 0; border-top: 1px solid var(--line); padding-left: 0; }
  .step:first-child { border-top: 0; }
  .site-footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 560px) {
  .gallery__grid { grid-template-columns: 1fr; }
  .site-footer__grid { grid-template-columns: 1fr; }
  .section-head { flex-direction: column; align-items: flex-start; gap: .6rem; }
  .brand__logo { height: 44px; }
  .hero::before { filter: blur(3px) grayscale(.62); }
  .hero__title { max-width: 14ch; }
  .hero__actions, .cta__actions { flex-direction: column; align-items: stretch; }
  .hero__actions .btn, .cta__actions .btn { width: 100%; justify-content: center; }
  .site-footer__bottom { flex-direction: column; }
  .to-top { right: .8rem; bottom: .8rem; }
}
