/* ==========================================================================
   GlutHerd – Werkstatt-Editorial
   ========================================================================== */

:root {
  --paper:        #f4eee2;
  --paper-deep:   #ece4d1;
  --paper-soft:   #faf6ed;
  --ink:          #14110f;
  --ink-soft:     #3a3531;
  --ink-mute:     #6b645c;
  --ember:        #c4502a;
  --ember-deep:   #9c3e1f;
  --walnut:       #6b432a;
  --stone:        #2c2a28;
  --steel:        #8a8580;
  --line:         rgba(20, 17, 15, 0.12);
  --line-strong:  rgba(20, 17, 15, 0.28);
  --line-dark:    rgba(244, 238, 226, 0.18);

  --font-display: "Fraunces", "Georgia", serif;
  --font-body:    "DM Sans", system-ui, sans-serif;
  --font-mono:    "JetBrains Mono", ui-monospace, monospace;

  --shell-pad:    clamp(1.25rem, 3vw, 2.5rem);
  --shell-max:    1320px;

  --ease-out:     cubic-bezier(0.16, 1, 0.3, 1);
}

/* ------ Reset ------------------------------------------------------------- */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 104px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
ul { list-style: none; padding: 0; margin: 0; }
:focus-visible { outline: 2px solid var(--ember); outline-offset: 3px; border-radius: 2px; }

/* ------ Paper grain overlay ---------------------------------------------- */

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0.08  0 0 0 0 0.07  0 0 0 0 0.06  0 0 0 0.55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  opacity: 0.06;
  mix-blend-mode: multiply;
  z-index: 1;
}

/* ------ Layout shell ----------------------------------------------------- */

.shell {
  width: 100%;
  max-width: var(--shell-max);
  margin: 0 auto;
  padding-inline: var(--shell-pad);
}

main { position: relative; z-index: 2; }

section { position: relative; z-index: 2; }

/* ------ Typography ------------------------------------------------------- */

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.05;
  margin: 0;
  font-variation-settings: "opsz" 144, "SOFT" 30;
}

h1 { font-size: clamp(2.6rem, 6.4vw, 5.6rem); }
h2 { font-size: clamp(2.1rem, 4.6vw, 3.8rem); line-height: 1.08; }
h3 { font-size: clamp(1.35rem, 2vw, 1.7rem); line-height: 1.2; letter-spacing: -0.01em; }

.eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.72rem;
  color: var(--ink-mute);
  font-weight: 500;
  margin-bottom: 1.25rem;
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 1px;
  background: currentColor;
  opacity: 0.6;
}

.lede {
  font-size: clamp(1.05rem, 1.2vw, 1.2rem);
  color: var(--ink-soft);
  max-width: 56ch;
  line-height: 1.55;
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--ink-mute);
}

.italic-quote {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.6rem, 2.6vw, 2.4rem);
  line-height: 1.2;
  color: var(--ink);
  font-variation-settings: "opsz" 144, "SOFT" 100;
}

/* ------ Buttons / Links -------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.95rem 1.4rem;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.95rem;
  letter-spacing: 0.005em;
  border: 1px solid transparent;
  border-radius: 999px;
  transition: transform 0.4s var(--ease-out), background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); }

.btn-ember {
  background: var(--ember);
  color: var(--paper-soft);
}
.btn-ember:hover { background: var(--ember-deep); }

.btn-ghost {
  background: transparent;
  color: var(--paper-soft);
  border-color: rgba(244, 238, 226, 0.4);
}
.btn-ghost:hover { border-color: var(--paper-soft); }

.btn-outline-dark {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-outline-dark:hover { background: var(--ink); color: var(--paper-soft); border-color: var(--ink); }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--ember);
  font-weight: 500;
  position: relative;
  padding-bottom: 2px;
}
.link-arrow::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: currentColor;
  transform-origin: left;
  transform: scaleX(0.4);
  transition: transform 0.5s var(--ease-out);
}
.link-arrow:hover::after { transform: scaleX(1); }
.link-arrow svg { transition: transform 0.4s var(--ease-out); }
.link-arrow:hover svg { transform: translateX(4px); }

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding-block: 1rem;
  transition: background 0.4s ease, border-color 0.4s ease, padding 0.4s ease, backdrop-filter 0.4s ease;
  border-bottom: 1px solid transparent;
}
.site-header.is-stuck {
  background: rgba(244, 238, 226, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
  padding-block: 0.65rem;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--paper-soft);
  transition: color 0.4s ease;
}
.site-header.is-stuck .brand { color: var(--ink); }
.brand img { height: 110px; width: auto; filter: drop-shadow(0 2px 8px rgba(0,0,0,0.5)); transition: height 0.4s ease, filter 0.4s ease; }
.site-header.is-stuck .brand img { height: 72px; filter: invert(1); }
.brand__wordmark {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.01em;
}
.brand__tag {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  opacity: 0.65;
  margin-top: 2px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 1.6rem;
}
.nav__list {
  display: flex;
  align-items: center;
  gap: 1.8rem;
}
.nav__list a {
  font-size: 0.93rem;
  font-weight: 500;
  color: var(--paper-soft);
  transition: color 0.4s ease, opacity 0.3s ease;
  position: relative;
  opacity: 0.85;
}
.nav__list a:hover { opacity: 1; }
.site-header.is-stuck .nav__list a { color: var(--ink-soft); }
.site-header.is-stuck .nav__list a:hover { color: var(--ink); }

.nav__cta { padding: 0.6rem 1rem; font-size: 0.9rem; }

.nav__social {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--paper-soft);
  opacity: 0.85;
  transition: color 0.3s ease, opacity 0.3s ease, transform 0.3s ease;
}
.nav__social:hover { opacity: 1; color: var(--ember); transform: translateY(-1px); }
.nav__social svg { width: 22px; height: 22px; }
.site-header.is-stuck .nav__social { color: var(--ink-soft); }
.site-header.is-stuck .nav__social:hover { color: var(--ember); }

.nav-toggle {
  display: none;
  background: transparent;
  border: 0;
  padding: 0.5rem;
  color: var(--paper-soft);
}
.site-header.is-stuck .nav-toggle { color: var(--ink); }
.nav-toggle svg { width: 26px; height: 26px; }

/* mobile nav */
@media (max-width: 880px) {
  .nav__list, .nav__cta, .nav__social { display: none; }
  .nav-toggle { display: inline-flex; }
  .brand img { height: 80px; }
  .site-header.is-stuck .brand img { height: 60px; }
  .site-header.is-open .nav__list,
  .site-header.is-open .nav__social,
  .site-header.is-open .nav__cta { display: flex; }
  .site-header.is-open {
    background: var(--paper);
    backdrop-filter: none;
    border-bottom-color: var(--line);
  }
  .site-header.is-open .brand,
  .site-header.is-open .nav-toggle,
  .site-header.is-open .nav__social,
  .site-header.is-open .nav__list a { color: var(--ink); }
  .site-header.is-open .brand img { filter: invert(1); }
  .site-header.is-open .nav {
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--paper);
    padding: 1.5rem var(--shell-pad) 2rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.4rem;
    border-bottom: 1px solid var(--line);
  }
  .site-header.is-open .nav__list {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.1rem;
    width: 100%;
  }
  .site-header.is-open .nav__list a { font-size: 1.4rem; font-family: var(--font-display); }
  .site-header.is-open .nav__cta { display: inline-flex; }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  position: relative;
  min-height: min(100svh, 880px);
  display: flex;
  align-items: flex-end;
  padding: 8rem 0 3rem;
  color: var(--paper-soft);
  overflow: hidden;
  isolation: isolate;
}

.hero__media {
  position: absolute;
  inset: 0;
  z-index: -2;
}
.hero__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 40%;
  transform: scale(1.04);
  animation: hero-pan 18s ease-out 0.2s forwards;
}
@keyframes hero-pan {
  to { transform: scale(1); }
}

.hero__shade {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(180deg, rgba(20,17,15,0.55) 0%, rgba(20,17,15,0.05) 28%, rgba(20,17,15,0.15) 60%, rgba(20,17,15,0.85) 100%),
    radial-gradient(60% 80% at 50% 100%, rgba(196,80,42,0.16) 0%, rgba(20,17,15,0) 60%);
}

.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 2rem;
  align-items: end;
  width: 100%;
}
.hero__col {
  max-width: 760px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.hero__eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.22em;
  font-size: 0.74rem;
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--paper-soft);
  opacity: 0.75;
  text-shadow: 0 1px 2px rgba(15, 13, 11, 1), 0 2px 14px rgba(15, 13, 11, 0.85);
  animation: rise 0.9s var(--ease-out) 0.3s both;
}
.hero__eyebrow::before {
  content: "";
  width: 28px; height: 1px;
  background: currentColor;
}

.hero h1 {
  font-weight: 600;
  font-variation-settings: "opsz" 144, "SOFT" 20;
  max-width: 18ch;
  text-shadow: 0 1px 3px rgba(15, 13, 11, 1), 0 2px 28px rgba(15, 13, 11, 0.85);
  animation: rise 1.1s var(--ease-out) 0.45s both;
}
.hero h1 em {
  font-style: italic;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  color: var(--ember);
}

.hero__sub {
  font-size: clamp(1.12rem, 1.4vw, 1.34rem);
  line-height: 1.55;
  max-width: 54ch;
  color: var(--paper-soft);
  text-shadow: 0 1px 3px rgba(15, 13, 11, 1), 0 2px 18px rgba(15, 13, 11, 0.85);
  animation: rise 1.1s var(--ease-out) 0.65s both;
}

.hero__claim {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(1.5rem, 2.6vw, 2.1rem);
  line-height: 1.1;
  color: var(--ember);
  margin-top: -0.4rem;
  text-shadow: 0 1px 3px rgba(15, 13, 11, 1), 0 2px 20px rgba(15, 13, 11, 0.85);
  animation: rise 1.1s var(--ease-out) 0.75s both;
}

.hero__ctas {
  display: flex;
  gap: 0.9rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
  animation: rise 1.1s var(--ease-out) 0.85s both;
}

.hero__meta {
  align-self: end;
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-family: var(--font-mono);
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--paper-soft);
  text-shadow: 0 1px 3px rgba(15, 13, 11, 1), 0 2px 16px rgba(15, 13, 11, 0.85);
  animation: rise 1.1s var(--ease-out) 1s both;
}
.hero__meta span:first-child {
  color: var(--ember);
  font-size: 1.04rem;
  letter-spacing: 0.18em;
}

@media (max-width: 720px) {
  .hero { padding-top: 7rem; min-height: 92svh; }
  .hero__grid { grid-template-columns: 1fr; }
  .hero__meta { text-align: left; }
}

@keyframes rise {
  from { opacity: 0; transform: translateY(22px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   Brand Story
   ========================================================================== */

.story {
  background: var(--paper-deep);
  padding: clamp(5rem, 9vw, 8rem) 0;
  position: relative;
  overflow: hidden;
}
.story::before {
  /* faint architectural lines */
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, var(--line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--line) 1px, transparent 1px);
  background-size: 110px 110px;
  opacity: 0.35;
  mask-image: radial-gradient(80% 60% at 20% 30%, #000 30%, transparent 80%);
  pointer-events: none;
}

.story__grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: clamp(2rem, 4vw, 4.5rem);
  align-items: start;
  position: relative;
}

.story__visuals {
  position: relative;
  min-height: 480px;
}
.story__sketch {
  position: absolute;
  background: var(--paper-soft);
  padding: 14px;
  border: 1px solid var(--line);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.6) inset,
    0 18px 40px -22px rgba(20,17,15,0.5),
    0 4px 14px -6px rgba(20,17,15,0.18);
}
.story__sketch img { width: 100%; height: auto; }
.story__sketch--a {
  top: 0; left: 0;
  width: 78%;
  transform: rotate(-2.4deg);
  z-index: 2;
}
.story__sketch--b {
  bottom: 0; right: 0;
  width: 70%;
  transform: rotate(2.6deg);
  z-index: 1;
}
.story__sketch::after {
  /* tape strip */
  content: "";
  position: absolute;
  top: -10px; left: 50%;
  width: 78px; height: 20px;
  background: rgba(196,80,42,0.22);
  transform: translateX(-50%) rotate(-3deg);
  mix-blend-mode: multiply;
}
.story__sketch--b::after { background: rgba(20,17,15,0.16); transform: translateX(-50%) rotate(4deg); }

.story__body { display: flex; flex-direction: column; gap: 1.6rem; }
.story__body h2 {
  max-width: 22ch;
  font-variation-settings: "opsz" 144, "SOFT" 20;
}
.story__body h2 em {
  font-style: italic;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  color: var(--ember);
}

.story__copy {
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--ink-soft);
  max-width: 56ch;
}
.story__copy p + p { margin-top: 1rem; }

.story__points {
  list-style: none;
  display: grid;
  gap: 0.7rem;
  margin: 0.4rem 0 0;
  max-width: 52ch;
}
.story__points li {
  position: relative;
  padding-left: 1.5rem;
  font-size: 0.98rem;
  line-height: 1.5;
  color: var(--ink-soft);
}
.story__points li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.55em;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--ember);
}
.story__points strong { color: var(--ink); font-weight: 600; }

.story__pull {
  border-left: 2px solid var(--ember);
  padding: 0.5rem 0 0.5rem 1.4rem;
  margin: 0.5rem 0 0;
  max-width: 52ch;
}
.story__pull p {
  margin: 0;
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 400;
  font-size: clamp(1.35rem, 2vw, 1.75rem);
  line-height: 1.2;
  color: var(--ink);
  font-variation-settings: "opsz" 144, "SOFT" 100;
}

@media (max-width: 880px) {
  .story__grid { grid-template-columns: 1fr; }
  .story__visuals { min-height: 360px; margin-bottom: 1rem; }
  .story__sketch--a { width: 70%; }
  .story__sketch--b { width: 64%; }
}

/* ==========================================================================
   Galerie
   ========================================================================== */

.gallery {
  padding: clamp(5rem, 9vw, 8rem) 0;
  background: var(--paper);
}
.gallery__head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 2rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}
.gallery__head h2 em {
  font-style: italic;
  font-variation-settings: "opsz" 144, "SOFT" 100;
  color: var(--ember);
}
.gallery__head .lede { max-width: 40ch; margin: 0; }

.gallery__grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-auto-rows: 90px;
  grid-auto-flow: dense;
  gap: 1rem;
}
.tile {
  position: relative;
  overflow: hidden;
  background: var(--ink);
  cursor: zoom-in;
  border-radius: 2px;
  transform: translateY(20px);
  opacity: 0;
  transition: transform 0.9s var(--ease-out), opacity 0.9s var(--ease-out);
}
.tile.is-in { transform: translateY(0); opacity: 1; }
.tile img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 1s var(--ease-out);
}
.tile:hover img { transform: scale(1.05); }
.tile__caption {
  position: absolute;
  left: 16px; bottom: 16px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--paper-soft);
  background: rgba(20,17,15,0.7);
  padding: 8px 12px;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.4s ease, transform 0.5s var(--ease-out);
}
.tile:hover .tile__caption { opacity: 1; transform: translateY(0); }

/* Kleine Standard-Kachel (≈ halbe Größe der früheren kleinen Tiles, 3:2) */
.tile--sm { grid-column: span 3; grid-row: span 2; }
/* Große Feature-Kachel: exakt 2×2 Module → packt mit dense-Flow lückenlos */
.tile--lg { grid-column: span 6; grid-row: span 4; }

@media (max-width: 880px) {
  .gallery__grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: auto; }
  .tile { aspect-ratio: 3/2; grid-column: auto !important; grid-row: auto !important; }
  .tile--lg { grid-column: 1 / -1 !important; }
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(20,17,15,0.94);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}
.lightbox.is-open { display: flex; }
.lightbox__figure {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  max-width: min(100%, 1100px);
}
.lightbox img {
  max-width: 100%;
  max-height: 82vh;
  object-fit: contain;
  box-shadow: 0 20px 60px rgba(0,0,0,0.6);
}
.lightbox__caption {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(244,238,226,0.82);
  text-align: center;
  max-width: 60ch;
}
.lightbox__close {
  position: absolute;
  top: 1.5rem; right: 1.5rem;
  background: transparent;
  border: 1px solid rgba(244,238,226,0.4);
  color: var(--paper-soft);
  width: 44px; height: 44px;
  border-radius: 50%;
  display: grid; place-items: center;
  z-index: 2;
}
.lightbox__close:hover { background: var(--ember); border-color: var(--ember); }

.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(20,17,15,0.55);
  border: 1px solid rgba(244,238,226,0.4);
  color: var(--paper-soft);
  width: 48px; height: 48px;
  border-radius: 50%;
  display: grid; place-items: center;
  z-index: 2;
  transition: background 0.25s ease, border-color 0.25s ease;
}
.lightbox__nav:hover { background: var(--ember); border-color: var(--ember); }
.lightbox__nav--prev { left: 1.5rem; }
.lightbox__nav--next { right: 1.5rem; }
.lightbox__nav[hidden] { display: none; }
.lightbox__counter {
  position: absolute;
  bottom: 1.5rem; left: 50%;
  transform: translateX(-50%);
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  color: rgba(244,238,226,0.7);
}
.lightbox__counter[hidden] { display: none; }

@media (max-width: 720px) {
  .lightbox__nav--prev { left: 0.7rem; }
  .lightbox__nav--next { right: 0.7rem; }
  .lightbox__nav { width: 42px; height: 42px; }
}

/* ==========================================================================
   Preise & Beispiele
   ========================================================================== */

/* ------ Modul-Banner (vollflächig unter dem Hero) ----------------------- */
.module-banner { background: var(--ink); }
.module-banner img { width: 100%; height: auto; display: block; }

.examples {
  padding: clamp(5rem, 9vw, 8rem) 0;
  background: var(--paper);
}
.examples__head {
  max-width: 720px;
  margin: 0 auto 4rem;
  text-align: center;
}
.examples__head h2 { margin-bottom: 1rem; }
.examples__head h2 em { font-style: italic; color: var(--ember); font-variation-settings: "opsz" 144, "SOFT" 100; }
.examples__head .lede { margin: 0 auto; }

.examples__grid {
  display: grid;
  /* minmax(0, 1fr) statt 1fr: verhindert, dass die Flex-Karten (Bild + Text)
     durch ihre min-content-Breite die Spalten aufblähen und das Grid nach
     rechts über den Shell-Inhaltsbereich hinausläuft. */
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.8rem;
}
.example {
  display: flex;
  gap: 1.4rem;
  align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: var(--paper-soft);
  padding: 1.2rem;
  transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
}
.example:hover {
  border-color: var(--ember);
  box-shadow: 0 14px 34px rgba(20, 17, 15, 0.1);
  transform: translateY(-2px);
}
.example__media {
  flex: 0 0 42%;
  position: relative;
  aspect-ratio: 4 / 3;
  /* KEIN schwarzer Hintergrund: auf iOS Safari scheint var(--ink) sonst beim Scrollen
     an der geclippten Kante (overflow:hidden) als schwarzer Balken durch. Heller
     Karten-Hintergrund fällt selbst bei einer Rundungs-Lücke nicht auf. */
  background: var(--paper-soft);
  border-radius: 1px;
  overflow: hidden;
}
/* Bild absolut über die ganze Box (inset:0): füllt die Kachel IMMER vollständig,
   egal ob deren Höhe per aspect-ratio oder per Flex-stretch (langer Text) bestimmt wird.
   transform: scale() = iOS-sicherer Overscan gegen Subpixel-Kanten beim Scrollen. */
.example__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform: scale(1.04); transition: transform 0.7s var(--ease-out); }

/* Klickbare Beispiel-Karte → öffnet Bildergalerie */
.example__open {
  position: relative;
  padding: 0;
  border: 0;
  cursor: zoom-in;
  width: auto;
}
.example:hover .example__open img { transform: scale(1.08); }
.example__zoom {
  position: absolute;
  left: 12px; bottom: 12px;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--paper-soft);
  background: rgba(20,17,15,0.7);
  padding: 7px 11px;
  border-radius: 2px;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.35s ease, transform 0.45s var(--ease-out);
}
.example__open:is(:hover, :focus-visible) .example__zoom,
.example:hover .example__zoom { opacity: 1; transform: translateY(0); }
.example__cta {
  align-self: flex-start;
  margin-top: 0.4rem;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ember);
  transition: gap 0.25s ease, color 0.25s ease;
}
.example__cta:hover { gap: 0.75rem; color: var(--ember-deep); }
.example__cta svg { transition: transform 0.25s ease; }
.example__cta:hover svg { transform: translateX(2px); }
.example__ph,
.partner__ph {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(244,238,226,0.5);
}
.example__body {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  justify-content: center;
}
.example__title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.005em;
}
.example__text {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink-soft);
}
.example__meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.example__price {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  letter-spacing: 0.03em;
  font-weight: 600;
  color: var(--ink);
  margin-top: 0.2rem;
}

/* Letzte Karte: über beide Spalten, Panorama unbeschnitten */
.example--wide {
  grid-column: 1 / -1;
  flex-direction: column;
  gap: 1rem;
}
.example--wide .example__body { justify-content: flex-start; }
.example--wide .example__media {
  flex: none;
  width: 100%;
  aspect-ratio: auto;
  background: var(--ink);
}
/* Panorama (contain): Bild im normalen Fluss (bestimmt die Höhe selbst), kein Overscan/Hover-Zoom,
   behält schwarzen Letterbox-Hintergrund (Regel oben) */
.example--wide .example__media img { position: static; width: 100%; height: auto; object-fit: contain; transform: none; }
.example--wide:hover .example__open img { transform: none; }
/* Galerie-Indikator der Wide-Karte dauerhaft sichtbar (kein Hover auf Touch) */
.example--wide .example__zoom { opacity: 1; transform: none; }

/* Play-Button + Hinweistext unter dem Bild → öffnet dieselbe Galerie */
.example__play {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  width: 100%;
  margin-top: 1rem;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.example__play-btn {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--ember);
  color: #fff;
  transition: background 0.3s ease, transform 0.3s ease;
}
.example__play-btn svg { width: 20px; height: 20px; margin-left: 2px; }
.example__play:is(:hover, :focus-visible) .example__play-btn { background: var(--ember-deep); transform: scale(1.06); }
.example__play-text { display: flex; flex-direction: column; gap: 0.25rem; }
.example__play-title {
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
  color: var(--ink);
  transition: color 0.3s ease;
}
.example__play:is(:hover, :focus-visible) .example__play-title { color: var(--ember-deep); }
.example__play-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ember);
}

@media (max-width: 880px) {
  .examples__grid { grid-template-columns: 1fr; }
  .example { flex-direction: column; }
  .example__media { flex: none; width: 100%; }
}

/* ==========================================================================
   Starke regionale Partner
   ========================================================================== */

.partners {
  padding: clamp(5rem, 9vw, 8rem) 0;
  background: var(--paper-soft);
  color: var(--ink);
}
.partners__head {
  max-width: 720px;
  margin: 0 auto 4rem;
  text-align: center;
}
.partners__head .eyebrow { color: var(--ink-mute); }
.partners__head h2 { margin-bottom: 1rem; color: var(--ink); font-variation-settings: "opsz" 144, "SOFT" 30; }
.partners__head h2 em { font-style: italic; color: var(--ember); font-variation-settings: "opsz" 144, "SOFT" 100; }
.partners__head .lede { margin: 0 auto; color: var(--ink-soft); }

.partners__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1.5rem;
}
.partner {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 1.6rem;
  transition: background 0.4s ease, border-color 0.4s ease;
}
.partner:hover {
  background: var(--paper-deep);
  border-color: var(--line-strong);
}
.partner__logo {
  aspect-ratio: 16 / 9;
  display: grid;
  place-items: center;
  background: var(--paper-deep);
  border-radius: 1px;
  margin-bottom: 0.6rem;
  overflow: hidden;
}
.partner__logo img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.7s var(--ease-out); }
.partner:hover .partner__logo img { transform: scale(1.04); }
.partner__ph { color: var(--ink-mute); }
.partner__name {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--ink);
}
.partner__place {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ember);
}
.partner__text {
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink-soft);
  flex: 1;
}
.partner .link-arrow { color: var(--ember); margin-top: 0.4rem; }

@media (max-width: 1080px) {
  .partners__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .partners__grid { grid-template-columns: 1fr; }
}

/* ==========================================================================
   Kontakt
   ========================================================================== */

.contact {
  padding: clamp(5rem, 9vw, 8rem) 0;
  background: var(--paper);
  position: relative;
  overflow: hidden;
}
.contact::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='600' height='600' viewBox='0 0 600 600'><g fill='none' stroke='%2314110f' stroke-width='0.6' opacity='0.18'><path d='M40 520 L120 460 L210 470 L290 410 L380 430 L470 380 L560 400'/><path d='M40 480 L120 420 L210 430 L290 370 L380 390 L470 340 L560 360'/><circle cx='290' cy='410' r='8'/></g></svg>");
  background-position: right -120px bottom -120px;
  background-repeat: no-repeat;
  background-size: 720px auto;
  pointer-events: none;
  opacity: 0.5;
}

.contact__grid {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: clamp(2rem, 4vw, 4rem);
  align-items: start;
  position: relative;
}
.contact__head h2 {
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  max-width: 16ch;
  margin-bottom: 1.5rem;
}
.contact__head h2 em { font-style: italic; color: var(--ember); font-variation-settings: "opsz" 144, "SOFT" 100; }
.contact__head .lede { margin-bottom: 2rem; max-width: 40ch; }
.contact__alt {
  display: flex; flex-direction: column;
  gap: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  color: var(--ink-soft);
}
.contact__alt a { color: var(--ink); transition: color 0.3s ease; }
.contact__alt a:hover { color: var(--ember); }
.contact__phone { display: inline-flex; align-items: center; gap: 0.55rem; }
.contact__whatsapp { display: inline-flex; align-items: center; }
.contact__whatsapp svg { width: 20px; height: 20px; }
.contact__alt span {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.contact__note {
  margin-top: 1.6rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--line);
  max-width: 40ch;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--ink-soft);
}

.form {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.2rem;
}
.form__field { display: flex; flex-direction: column; gap: 0.45rem; }
.form__field--wide { grid-column: span 2; }
.form__field label {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ink-mute);
}
.form__field input,
.form__field textarea {
  font-family: var(--font-body);
  font-size: 1rem;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line-strong);
  padding: 0.7rem 0;
  color: var(--ink);
  transition: border-color 0.3s ease;
}
.form__field input:focus,
.form__field textarea:focus {
  outline: none;
  border-bottom-color: var(--ember);
}
.form__field textarea { resize: vertical; min-height: 120px; }

/* Datei-Upload (Bilder) */
.form__field--upload input[type="file"] {
  font-family: var(--font-body);
  font-size: 0.9rem;
  color: var(--ink-soft);
  padding: 0.6rem 0;
}
.form__field--upload input[type="file"]::file-selector-button {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 0.55rem 1rem;
  margin-right: 0.9rem;
  cursor: pointer;
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
.form__field--upload input[type="file"]::file-selector-button:hover {
  background: var(--ink);
  color: var(--paper-soft);
  border-color: var(--ink);
}
.form__hint {
  font-family: var(--font-body);
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.5;
  color: var(--ink);
  background: rgba(196, 80, 42, 0.09);
  border-left: 3px solid var(--ember);
  border-radius: 2px;
  padding: 0.7rem 0.85rem;
  margin: 0.2rem 0 0;
}
.form__previews {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  padding: 0;
  margin: 0.2rem 0 0;
}
.form__preview {
  position: relative;
  width: 76px;
  height: 76px;
  border-radius: 2px;
  overflow: hidden;
  background: var(--paper-deep);
  border: 1px solid var(--line);
}
.form__preview img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.form__preview button {
  position: absolute;
  top: 3px; right: 3px;
  width: 20px; height: 20px;
  display: grid;
  place-items: center;
  background: rgba(20, 17, 15, 0.72);
  color: var(--paper-soft);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  line-height: 1;
  font-size: 0.78rem;
  transition: background 0.25s ease;
}
.form__preview button:hover { background: var(--ember); }
.form__submit {
  grid-column: span 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 0.5rem;
}
.form__submit small {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-mute);
  max-width: 30ch;
}

@media (max-width: 880px) {
  .contact__grid { grid-template-columns: 1fr; }
  .form { grid-template-columns: 1fr; }
  .form__field--wide, .form__submit { grid-column: span 1; }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  background: var(--ink);
  color: rgba(244,238,226,0.8);
  padding: 4rem 0 2.5rem;
  font-size: 0.93rem;
}
.footer__top {
  display: grid;
  grid-template-columns: 2fr repeat(3, 1fr);
  gap: 2.5rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--line-dark);
}
.footer__brand {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 360px;
}
.footer__brand img { height: 96px; width: auto; align-self: flex-start; }
.footer__brand p { color: rgba(244,238,226,0.6); line-height: 1.6; }
.footer__social {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  align-self: flex-start;
  color: rgba(244,238,226,0.85);
  font-size: 0.9rem;
  transition: color 0.3s ease, transform 0.3s ease;
}
.footer__social:hover { color: var(--ember); transform: translateX(3px); }
.footer__social svg { width: 22px; height: 22px; }

.footer__col h4 {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(244,238,226,0.5);
  margin-bottom: 1.2rem;
}
.footer__col a,
.footer__col .footer__legal {
  display: block;
  padding: 0.35rem 0;
  color: rgba(244,238,226,0.85);
  transition: color 0.3s ease, transform 0.3s ease;
}
.footer__col a:hover,
.footer__col .footer__legal:hover { color: var(--ember); transform: translateX(3px); }
.footer__col a.footer__wa { display: inline-flex; align-items: center; gap: 0.5rem; }
.footer__col a.footer__wa svg { width: 17px; height: 17px; flex: none; }
.footer__legal {
  background: none;
  border: 0;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.footer__bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 2.5rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(244,238,226,0.45);
  flex-wrap: wrap;
  gap: 1rem;
}
.footer__bottom strong { color: var(--ember); font-weight: 500; }

@media (max-width: 880px) {
  .footer__top { grid-template-columns: 1fr; gap: 2rem; }
}

/* ==========================================================================
   Rechtliches-Popup (Impressum / Datenschutz)
   ========================================================================== */

.legal {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(20,17,15,0.94);
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(1rem, 5vh, 3.5rem) 1rem;
}
.legal.is-open { display: flex; }

.legal__panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 760px;
  max-height: 100%;
  overflow-y: auto;
  background: var(--paper-soft);
  color: var(--ink);
  border: 1px solid var(--line);
  border-radius: 2px;
  box-shadow: 0 30px 80px -20px rgba(0,0,0,0.6);
  padding: clamp(1.75rem, 4vw, 3.25rem);
}

.legal__close {
  position: sticky;
  top: 0;
  align-self: flex-end;
  margin-bottom: -1.5rem;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  color: var(--ink);
  width: 42px; height: 42px;
  flex-shrink: 0;
  border-radius: 50%;
  display: grid; place-items: center;
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}
.legal__close:hover { background: var(--ember); border-color: var(--ember); color: var(--paper-soft); }

.legal__doc h2 {
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
  margin-bottom: 1.5rem;
}
.legal__doc h2 em { font-style: italic; color: var(--ember); }
.legal__doc h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.005em;
  margin: 1.8rem 0 0.5rem;
}
.legal__doc p {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--ink-soft);
  margin: 0 0 0.85rem;
  max-width: 64ch;
}
.legal__doc a { color: var(--ember); text-decoration: underline; text-underline-offset: 2px; }
.legal__credit-logo {
  display: inline-block;
  margin: 0.4rem 0 1rem;
  text-decoration: none;
  transition: opacity 0.3s ease;
}
.legal__credit-logo:hover { opacity: 0.75; }
.legal__credit-logo img { display: block; width: 200px; max-width: 100%; height: auto; }
.legal__heart { color: var(--ember); }
.legal__meta {
  margin-top: 2.2rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-mute);
}

.legal-ph {
  font-family: var(--font-mono);
  font-size: 0.82em;
  background: rgba(196,80,42,0.12);
  color: var(--ember-deep);
  padding: 0.05em 0.45em;
  border-radius: 2px;
  border: 1px dashed rgba(196,80,42,0.55);
}

@media (max-width: 620px) {
  .legal { padding: 0; align-items: stretch; }
  .legal__panel { max-width: none; max-height: 100%; border: 0; border-radius: 0; }
}

/* ==========================================================================
   Scroll reveal
   ========================================================================== */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1.1s var(--ease-out), transform 1.1s var(--ease-out);
}
.reveal.is-in { opacity: 1; transform: translateY(0); }

/* ==========================================================================
   Zum Anfang der Seite
   ========================================================================== */

.to-top {
  position: fixed;
  bottom: clamp(1.2rem, 3vw, 2rem);
  right: clamp(1.2rem, 3vw, 2rem);
  z-index: 90;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  background: var(--ember);
  color: var(--paper-soft);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 10px 28px rgba(20, 17, 15, 0.22);
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px);
  transition: opacity 0.4s var(--ease-out), transform 0.4s var(--ease-out),
              visibility 0.4s, background 0.3s ease;
}
.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.to-top:hover {
  background: var(--ember-deep);
  transform: translateY(-2px);
}
.to-top:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001s !important;
    transition-duration: 0.001s !important;
  }
  .hero__media img { animation: none; }
}
