/* =========================================================
   BHF-System GmbH – Stylesheet
   Umsetzung: Palpromedia GmbH
   Aufbau: 1 Variablen · 2 Basis · 3 Layout · 4 Komponenten
           5 Seitenbereiche · 6 Hilfsklassen · 7 Bewegung
   Mobile first – Breakpoints: 600 / 768 / 1100 / 1440 px
   ========================================================= */

/* ---------- 0. Schriften (lokal gehostet) ----------
   Poppins (SIL Open Font License, frei auch für kommerzielle Nutzung) –
   geometrische Grotesk als freie Alternative zu TheFuture.
   Gewichte 100–599 → Regular, 600–900 → Bold. Auf Latin + Sonderzeichen reduziert. */
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-regular.woff") format("woff");
  font-weight: 100 599; font-style: normal; font-display: swap;
}
@font-face {
  font-family: "Poppins";
  src: url("../fonts/poppins-bold.woff") format("woff");
  font-weight: 600 900; font-style: normal; font-display: swap;
}

/* ---------- 1. Variablen ---------- */
:root {
  /* Farben (CI) */
  --white: #ffffff;
  --green: #83a735;          /* Akzent: Buttons, Icons, Linien, Flächen */
  --green-dark: #6b8a2a;     /* Hover-Zustände */
  --black: #111111;          /* Text, dunkle Flächen */
  --grey-light: #f4f5f2;     /* abgesetzte Sektionen */

  /* Abgeleitete Töne für Barrierefreiheit (WCAG AA)
     #83A735 erreicht auf Weiss nur 2.8:1 – für grünen TEXT auf hellem
     Grund wird deshalb dieser dunklere Ton verwendet (6.2:1). */
  --green-text: #4f6a1e;
  --text: var(--black);
  --text-muted: #555b50;     /* 7.0:1 auf Weiss */
  --text-on-dark: #ffffff;
  --text-on-dark-muted: #c4c8bd;
  --border: #e1e4dc;
  --border-strong: #c9cec1;
  --placeholder: #c8cac4;
  --error: #b42318;

  /* Typografie */
  --font: "Poppins", "Futura", "Century Gothic", "Helvetica Neue", Arial, sans-serif;
  --w-regular: 400;
  --w-heavy: 700;
  --fs-body: 1rem;                                  /* 16 px */
  --fs-lead: clamp(1.0625rem, 0.98rem + 0.4vw, 1.25rem);
  --fs-small: 0.875rem;
  --fs-h1: clamp(1.875rem, 1.3rem + 2.6vw, 3.125rem);
  --fs-h2: clamp(1.625rem, 1.25rem + 1.6vw, 2.5rem);
  --fs-h3: clamp(1.125rem, 1.05rem + 0.35vw, 1.3125rem);
  --lh: 1.6;
  --lh-tight: 1.2;

  /* Abstände & Raster */
  --container: 1240px;
  --container-narrow: 820px;
  --gutter: clamp(16px, 4vw, 40px);
  --section: clamp(64px, 9vw, 128px);
  --space-1: 0.5rem;
  --space-2: 1rem;
  --space-3: 1.5rem;
  --space-4: 2rem;
  --space-5: 3rem;
  --space-6: 4rem;

  /* Form */
  --radius: 8px;
  --radius-lg: 12px;
  --shadow-sm: 0 1px 2px rgba(17, 17, 17, .06);
  --shadow: 0 2px 6px rgba(17, 17, 17, .05), 0 10px 28px rgba(17, 17, 17, .07);
  --shadow-lg: 0 6px 16px rgba(17, 17, 17, .08), 0 24px 48px rgba(17, 17, 17, .10);

  --header-h: 68px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --focus: 0 0 0 3px var(--white), 0 0 0 6px var(--black);
}
@media (min-width: 1100px) {
  :root { --header-h: 84px; --fs-body: 1.0625rem; } /* 17 px auf Desktop */
}

/* ---------- 2. Basis ---------- */
*, *::before, *::after { box-sizing: border-box; }
html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}
body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: var(--lh);
  color: var(--text);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-synthesis: none;              /* kein künstliches Fett/Kursiv */
  overflow-x: hidden;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3, h4 {
  margin: 0 0 var(--space-2);
  line-height: var(--lh-tight);
  font-weight: var(--w-heavy);
  letter-spacing: -0.005em;
  text-wrap: balance;
}
h1 { font-size: var(--fs-h1); letter-spacing: -0.02em; line-height: 1.12; }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); letter-spacing: 0; line-height: 1.3; }
p { margin: 0 0 var(--space-2); }
p, li { text-wrap: pretty; }
ul, ol { margin: 0 0 var(--space-2); padding-left: 1.25rem; }
strong, b { font-weight: var(--w-heavy); }

a {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--green);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
  transition: color .2s, text-decoration-color .2s;
}
a:hover { color: var(--green-text); text-decoration-color: var(--green-dark); }

:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 4px; }
.bg-dark :focus-visible, .site-footer :focus-visible, .hero :focus-visible, .nav-panel :focus-visible {
  box-shadow: 0 0 0 3px var(--black), 0 0 0 6px var(--green);
}

.skip-link {
  position: absolute; left: 16px; top: -100px; z-index: 200;
  background: var(--black); color: var(--white); padding: 12px 18px;
  border-radius: var(--radius); text-decoration: none;
}
.skip-link:focus { top: 12px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- 3. Layout ---------- */
.container { width: 100%; max-width: calc(var(--container) + 2 * var(--gutter)); margin-inline: auto; padding-inline: var(--gutter); }
.container--narrow { max-width: calc(var(--container-narrow) + 2 * var(--gutter)); }

.section { padding-block: var(--section); }
.section--tight { padding-block: calc(var(--section) * .6); }
.bg-light { background: var(--grey-light); }
.bg-dark { background: var(--black); color: var(--text-on-dark); }
.bg-dark a { color: var(--white); }

.section-head { max-width: 720px; margin-bottom: clamp(32px, 5vw, 56px); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head p { color: var(--text-muted); font-size: var(--fs-lead); margin: 0; }
.bg-dark .section-head p { color: var(--text-on-dark-muted); }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  margin-bottom: var(--space-2);
  font-size: .9375rem; font-weight: var(--w-regular); letter-spacing: .01em;
  color: var(--green-text);
}
.eyebrow::before { content: ""; width: 24px; height: 2px; background: var(--green); border-radius: 2px; }
.bg-dark .eyebrow, .hero .eyebrow, .page-hero--dark .eyebrow { color: var(--green); }

.lead { font-size: var(--fs-lead); color: var(--text-muted); }

/* Raster */
.grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
@media (min-width: 600px) {
  .grid--2, .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1100px) {
  .grid--3 { grid-template-columns: repeat(3, 1fr); }
  .grid--4 { grid-template-columns: repeat(4, 1fr); }
}

/* Zweispaltig Text/Bild */
.split { display: grid; gap: clamp(32px, 5vw, 72px); align-items: center; }
@media (min-width: 768px) {
  .split { grid-template-columns: 1fr 1fr; }
  .split--reverse > :first-child { order: 2; }
  .split--top { align-items: start; }
}

/* ---------- 4. Komponenten ---------- */

/* Buttons */
.btn {
  --btn-bg: var(--green); --btn-fg: var(--black); --btn-bd: var(--green);
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 14px 26px;
  font: inherit; font-size: 1.0625rem; font-weight: var(--w-regular); line-height: 1.2;
  color: var(--btn-fg); background: var(--btn-bg);
  border: 2px solid var(--btn-bd); border-radius: var(--radius);
  text-decoration: none; cursor: pointer;
  transition: background-color .2s, border-color .2s, color .2s, transform .2s var(--ease), box-shadow .2s;
}
.btn:hover { --btn-bg: var(--green-dark); --btn-bd: var(--green-dark); color: var(--btn-fg); transform: translateY(-1px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); box-shadow: none; }
.btn svg { width: 20px; height: 20px; flex: none; }

.btn--outline { --btn-bg: transparent; --btn-fg: var(--black); --btn-bd: var(--black); }
.btn--outline:hover { --btn-bg: var(--black); --btn-fg: var(--white); --btn-bd: var(--black); }

.btn--outline-light { --btn-bg: transparent; --btn-fg: var(--white); --btn-bd: rgba(255,255,255,.85); }
.btn--outline-light:hover { --btn-bg: var(--white); --btn-fg: var(--black); --btn-bd: var(--white); }

.btn--dark { --btn-bg: var(--black); --btn-fg: var(--white); --btn-bd: var(--black); }
.btn--dark:hover { --btn-bg: #2a2a2a; --btn-bd: #2a2a2a; --btn-fg: var(--white); }

.btn--sm { min-height: 44px; padding: 10px 18px; font-size: .9375rem; }
.btn--block { width: 100%; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Textlink mit Pfeil */
.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: var(--w-regular); text-decoration: none; color: var(--text);
}
.link-arrow svg { width: 18px; height: 18px; color: var(--green-text); transition: transform .2s var(--ease); }
.link-arrow:hover { color: var(--green-text); }
.link-arrow:hover svg { transform: translateX(4px); }
.bg-dark .link-arrow svg { color: var(--green); }

/* Karten */
.card {
  position: relative;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(24px, 3vw, 32px);
  box-shadow: var(--shadow-sm);
  transition: box-shadow .25s, transform .25s var(--ease), border-color .25s;
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: var(--border-strong); }
.card h3 { margin-bottom: var(--space-1); }
.card p { margin: 0; color: var(--text-muted); }

.icon {
  display: grid; place-items: center;
  width: 56px; height: 56px; margin-bottom: var(--space-3);
  border-radius: var(--radius);
  background: rgba(131, 167, 53, .12);
  color: var(--green-text);
}
.icon svg { width: 28px; height: 28px; fill: none; stroke: currentColor; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

/* Bilder & Platzhalter */
.media {
  position: relative; margin: 0;
  border-radius: var(--radius); overflow: hidden;
  background: var(--placeholder);
  aspect-ratio: 4 / 3;
}
.media img { width: 100%; height: 100%; object-fit: cover; }
.media--portrait { aspect-ratio: 5 / 6; }
.media--wide { aspect-ratio: 16 / 9; }
.media figcaption {
  position: absolute; left: 12px; bottom: 12px;
  padding: 6px 12px; border-radius: 6px;
  font-size: var(--fs-small);
  background: rgba(255,255,255,.92); color: var(--black);
}

/* Häkchen-Liste */
.checklist { list-style: none; padding: 0; margin: 0 0 var(--space-3); display: grid; gap: 12px; }
.checklist li { position: relative; padding-left: 34px; }
.checklist li::before {
  content: ""; position: absolute; left: 0; top: .2em;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4 8-9'/%3E%3C/svg%3E") center / 14px no-repeat;
}

/* Hinweisbox */
.note {
  display: flex; gap: 14px; align-items: flex-start;
  padding: 18px 20px; border-radius: var(--radius);
  background: var(--grey-light); border-left: 4px solid var(--green);
}
.bg-light .note { background: var(--white); }
.note p { margin: 0; }

/* Tabelle (Garantien) */
.table-wrap { overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius); background: var(--white); }
.table { width: 100%; border-collapse: collapse; }
.table caption { text-align: left; padding: 16px 20px 0; font-weight: var(--w-heavy); }
.table th, .table td { padding: 14px 20px; text-align: left; border-bottom: 1px solid var(--border); vertical-align: top; }
.table thead th { background: var(--grey-light); font-size: var(--fs-small); font-weight: var(--w-heavy); }
.table tbody tr:last-child td, .table tbody tr:last-child th { border-bottom: 0; }
.table td:last-child { white-space: nowrap; font-weight: var(--w-heavy); }

/* FAQ-Akkordeon (details/summary – nativ per Tastatur bedienbar) */
.faq { display: grid; gap: 12px; }
.faq details {
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s;
}
.faq details[open] { border-color: var(--green); box-shadow: var(--shadow-sm); }
.faq summary {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 20px; cursor: pointer; list-style: none;
  font-weight: var(--w-heavy); font-size: 1.0625rem; line-height: 1.4;
  border-radius: var(--radius);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; flex: none; width: 28px; height: 28px; border-radius: 50%;
  background: var(--grey-light) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111' stroke-width='2.4' stroke-linecap='round'%3E%3Cpath d='M12 6v12M6 12h12'/%3E%3C/svg%3E") center / 16px no-repeat;
  transition: transform .25s var(--ease), background-color .2s;
}
.faq details[open] summary::after { transform: rotate(45deg); background-color: var(--green); }
.faq summary:hover::after { background-color: var(--green); }
.faq .faq__body { padding: 0 20px 20px; color: var(--text-muted); }
.faq .faq__body > :last-child { margin-bottom: 0; }
.faq .table-wrap { margin-top: 12px; color: var(--text); }

/* ---------- Header & Navigation ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--white); /* bewusst ohne backdrop-filter: sonst bricht position:fixed des Mobile-Menüs */
  border-bottom: 1px solid transparent;
  transition: border-color .2s, box-shadow .2s;
}
.site-header.is-scrolled { border-bottom-color: var(--border); box-shadow: var(--shadow-sm); }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--header-h); }

.brand { display: inline-flex; flex: none; text-decoration: none; }
.brand img { width: 150px; height: auto; }
@media (min-width: 1100px) { .brand img { width: 178px; } }

.nav-toggle {
  position: relative; flex: none;
  display: grid; place-items: center;
  width: 48px; height: 48px; padding: 0; margin-right: -4px;
  background: var(--grey-light); border: 1px solid var(--border); border-radius: 50%;
  color: var(--black); cursor: pointer;
  transition: background-color .25s, border-color .25s, transform .2s var(--ease);
}
.nav-toggle:hover { border-color: var(--green); }
.nav-toggle:active { transform: scale(.95); }
.nav-toggle__label {           /* nur für Screenreader */
  position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
}
.nav-toggle__bars { position: relative; width: 20px; height: 14px; }
.nav-toggle__bars span {
  position: absolute; left: 0; width: 100%; height: 2.5px; border-radius: 2px; background: var(--black);
  transition: transform .3s var(--ease), opacity .2s, top .3s var(--ease), background-color .25s;
}
.nav-toggle__bars span:nth-child(1) { top: 0; background: var(--green); }
.nav-toggle__bars span:nth-child(2) { top: 5.75px; }
.nav-toggle__bars span:nth-child(3) { top: 11.5px; }
.nav-toggle[aria-expanded="true"] { background: var(--black); border-color: var(--black); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(1) { top: 5.75px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bars span:nth-child(3) { top: 5.75px; transform: rotate(-45deg); background: var(--white); }

/* Mobile/Tablet: bildschirmfüllendes dunkles Menü */
.nav-panel {
  position: fixed; inset: var(--header-h) 0 0 0; z-index: 99;
  display: flex; flex-direction: column; gap: var(--space-4);
  padding: var(--space-3) var(--gutter) calc(var(--space-4) + env(safe-area-inset-bottom));
  background: var(--black); color: var(--white);
  overflow-y: auto; overscroll-behavior: contain;
  visibility: hidden; opacity: 0; transform: translateY(-8px);
  transition: opacity .25s var(--ease), transform .25s var(--ease), visibility 0s linear .25s;
}
.nav-panel.is-open { visibility: visible; opacity: 1; transform: none; transition-delay: 0s; }
.nav-list { list-style: none; margin: 0; padding: 0; }
.nav-list a {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,.12);
  color: var(--white); text-decoration: none;
  font-size: clamp(1.25rem, 1rem + 1.4vw, 1.625rem); font-weight: 700; letter-spacing: -0.01em;
}
@media (max-width: 1099px) {
  .nav-list a::after {
    content: ""; width: 10px; height: 10px; border-top: 2px solid var(--green); border-right: 2px solid var(--green);
    transform: rotate(45deg); margin-right: 4px;
  }
}
.nav-list a[aria-current="page"] { color: var(--green); }
.nav-panel__cta { display: grid; gap: 12px; margin-top: auto; }
.nav-panel__cta .btn--outline-light { justify-content: center; }
.nav-panel__meta { margin: 0; color: var(--text-on-dark-muted); font-size: var(--fs-small); }

.header-cta { display: none; }

html.nav-open { overflow: hidden; }

/* Desktop: horizontale Navigation */
@media (min-width: 1100px) {
  .nav-toggle { display: none; }
  .nav-panel {
    position: static; inset: auto; z-index: auto;
    flex-direction: row; align-items: center; gap: 28px; padding: 0;
    background: none; color: inherit; overflow: visible;
    visibility: visible; opacity: 1; transform: none; transition: none;
  }
  .nav-list { display: flex; align-items: center; gap: clamp(16px, 1.8vw, 28px); }
  .nav-list a {
    position: relative; padding: 8px 0; border: 0;
    color: var(--black); font-size: 1rem; font-weight: var(--w-regular); letter-spacing: 0;
  }
  .nav-list a::after {
    content: "";
    position: absolute; left: 0; right: 0; bottom: 0; width: auto; height: 2px; margin: 0;
    border: 0; transform: scaleX(0); transform-origin: left;
    background: var(--green); transition: transform .25s var(--ease);
  }
  .nav-list a:hover { color: var(--black); }
  .nav-list a:hover::after, .nav-list a[aria-current="page"]::after { transform: scaleX(1); }
  .nav-list a[aria-current="page"] { color: var(--black); }
  .nav-panel__cta, .nav-panel__meta { display: none; }
  .header-cta { display: inline-flex; }
}

/* ---------- 5. Seitenbereiche ---------- */

/* Hero (Startseite) */
.hero {
  position: relative; isolation: isolate;
  display: flex; align-items: flex-end;
  min-height: min(calc(100svh - var(--header-h)), 860px);
  padding-block: clamp(96px, 14vw, 160px) clamp(48px, 7vw, 96px);
  color: var(--white);
  background: var(--black);
  overflow: hidden;
}
@media (min-width: 768px) { .hero { min-height: min(calc(100svh - var(--header-h)), 780px); align-items: center; } }
.hero__media { position: absolute; inset: 0; z-index: -2; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }
.hero::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(17,17,17,.88) 0%, rgba(17,17,17,.70) 45%, rgba(17,17,17,.25) 100%),
    linear-gradient(0deg, rgba(17,17,17,.55) 0%, rgba(17,17,17,0) 45%);
}
.hero__content { max-width: 760px; }
.hero h1 { color: var(--white); margin-bottom: var(--space-3); }
.hero h1 .accent { color: var(--green); }
.hero__lead { font-size: var(--fs-lead); color: rgba(255,255,255,.9); max-width: 620px; margin-bottom: var(--space-4); }
.hero__facts {
  display: flex; flex-wrap: wrap; gap: 8px 22px;
  list-style: none; padding: 0; margin: var(--space-4) 0 0;
  font-size: .9375rem; font-weight: var(--w-regular); color: rgba(255,255,255,.9);
}
.hero__facts li { display: inline-flex; align-items: center; gap: 8px; }
.hero__facts svg { width: 18px; height: 18px; color: var(--green); fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
@media (max-width: 599px) { .hero .btn-row .btn { flex: 1 1 100%; } }

/* Seitenkopf Unterseiten */
.page-hero { padding-block: clamp(48px, 7vw, 96px) clamp(40px, 5vw, 72px); background: var(--grey-light); }
.page-hero h1 { max-width: 860px; }
.page-hero .lead { max-width: 720px; margin: 0; }
.page-hero--dark { background: var(--black); color: var(--white); }
.page-hero--dark .lead { color: var(--text-on-dark-muted); }

.breadcrumb { margin-bottom: var(--space-3); font-size: var(--fs-small); }
.breadcrumb ol { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0; color: var(--text-muted); }
.breadcrumb li + li::before { content: "/"; margin-right: 6px; color: var(--border-strong); }
.breadcrumb a { color: var(--text-muted); text-decoration-color: transparent; }
.breadcrumb a:hover { color: var(--black); text-decoration-color: var(--green); }

/* Einleitung */
.intro__text > p:not(.eyebrow) { color: var(--text-muted); }
.intro__text .lead { color: var(--text); font-weight: 500; }
.intro__media { position: relative; }
.badge {
  position: absolute; right: 16px; bottom: 16px;
  display: grid; gap: 2px; padding: 14px 18px;
  background: var(--green); color: var(--black);
  border-radius: var(--radius); box-shadow: var(--shadow);
  line-height: 1.2;
}
.badge strong { font-size: 1.75rem; letter-spacing: 0; }
.badge span { font-size: var(--fs-small); }
@media (min-width: 900px) { .badge { right: -20px; bottom: 32px; } }

/* Zahlen */
.stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 32px 20px; margin: 0; }
@media (min-width: 900px) { .stats { grid-template-columns: repeat(4, 1fr); gap: 32px; } }
.stat { position: relative; padding-top: 20px; border-top: 2px solid var(--green); display: flex; flex-direction: column; }
.stat dt { order: 2; color: var(--text-on-dark-muted); font-size: .9375rem; line-height: 1.45; }
.stat dd { order: 1; margin: 0 0 6px; font-size: clamp(2.25rem, 1.6rem + 2.6vw, 3.5rem); font-weight: var(--w-heavy); letter-spacing: -0.01em; line-height: 1; color: var(--green); white-space: nowrap; }
.stat dd small { font-size: .5em; font-weight: var(--w-heavy); color: var(--white); margin-left: 4px; letter-spacing: 0; }

/* Ablauf */
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 28px; counter-reset: step; }
@media (min-width: 768px) { .steps { grid-template-columns: repeat(2, 1fr); gap: 36px 28px; } }
@media (min-width: 1100px) { .steps { grid-template-columns: repeat(4, 1fr); } }
.step { position: relative; padding-left: 68px; counter-increment: step; }
.step::before {
  content: counter(step);
  position: absolute; left: 0; top: 0;
  display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%;
  background: var(--white); border: 2px solid var(--green);
  font-weight: var(--w-heavy); font-size: 1.125rem; color: var(--black);
}
.step h3 { margin: 10px 0 6px; }
.step p { margin: 0; color: var(--text-muted); }
@media (min-width: 1100px) {
  .step { padding-left: 0; padding-top: 72px; }
  .step::after {
    content: ""; position: absolute; top: 23px; left: 60px; right: -16px; height: 2px;
    background: repeating-linear-gradient(90deg, var(--green) 0 8px, transparent 8px 14px);
  }
  .step:last-child::after { display: none; }
  .step h3 { margin-top: 0; }
}

/* Galerie */
.gallery { display: grid; gap: clamp(12px, 2vw, 24px); grid-template-columns: 1fr; list-style: none; margin: 0; padding: 0; }
@media (min-width: 600px) { .gallery { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .gallery { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 768px) { .gallery--3 { grid-template-columns: repeat(3, 1fr); } }
@media (min-width: 768px) and (max-width: 1099px) { .split--lg { grid-template-columns: 1fr; } .split--lg .section-head { margin-bottom: 0; } }
.gallery-item { margin: 0; }
.gallery-item .media { margin-bottom: 12px; }
.gallery-item figcaption { position: static; padding: 0; background: none; }
.gallery-item__title { display: block; font-weight: var(--w-heavy); }
.gallery-item__place { display: block; font-size: var(--fs-small); color: var(--text-muted); }

/* Team */
.team-card { margin: 0; }
.team-card .media { margin-bottom: 16px; }
.team-card h3 { margin-bottom: 2px; }
.team-card p { margin: 0 0 6px; color: var(--text-muted); }
.team-card a { font-weight: var(--w-regular); }

/* Kontaktband / CTA */
.cta-band { background: var(--green); color: var(--black); }
.cta-band__inner { display: grid; gap: var(--space-4); align-items: center; padding-block: clamp(48px, 7vw, 88px); }
@media (min-width: 900px) { .cta-band__inner { grid-template-columns: 1.4fr 1fr; } }
.cta-band h2 { margin-bottom: var(--space-1); }
.cta-band p { margin: 0; font-size: var(--fs-lead); }
.cta-band__actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
@media (min-width: 900px) { .cta-band__actions { justify-content: flex-end; } }
.cta-band .btn--outline:hover { --btn-bg: var(--black); --btn-fg: var(--white); }
.phone-link {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: clamp(1.25rem, 1rem + 1vw, 1.5rem); font-weight: var(--w-heavy); letter-spacing: 0;
  color: var(--black); text-decoration: none; white-space: nowrap;
}
.phone-link svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 2; }
.phone-link:hover { color: var(--black); text-decoration: underline; text-decoration-color: var(--black); }

/* Kontaktliste */
.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.contact-list li { display: flex; gap: 14px; align-items: flex-start; }
.contact-list .icon { width: 44px; height: 44px; margin: 0; flex: none; border-radius: 50%; }
.contact-list .icon svg { width: 20px; height: 20px; }
.contact-list small { display: block; color: var(--text-muted); font-size: var(--fs-small); }
.contact-list a { font-weight: var(--w-regular); }

/* Formulare */
.form { display: grid; gap: 20px; }
.form-row { display: grid; gap: 20px; }
@media (min-width: 600px) {
  .form-row--2 { grid-template-columns: 1fr 1fr; }
  .form-row--plz { grid-template-columns: 140px 1fr; }
}
.form fieldset { border: 0; margin: 0; padding: 0; display: grid; gap: 20px; min-width: 0; }
.form legend { padding: 0; margin-bottom: 4px; font-weight: var(--w-heavy); font-size: 1.125rem; }
.field { display: grid; gap: 6px; }
.field label, .field .label { font-weight: var(--w-regular); font-size: .9375rem; }
.field .req { color: var(--green-text); }
.field .hint { font-size: var(--fs-small); color: var(--text-muted); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 50px; padding: 12px 14px;
  font: inherit; font-size: 1rem; color: var(--black);
  background: var(--white); border: 1.5px solid var(--border-strong); border-radius: var(--radius);
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { min-height: 140px; resize: vertical; }
.field select {
  appearance: none; -webkit-appearance: none; padding-right: 44px;
  background: var(--white) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23111' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 14px center / 18px no-repeat;
}
.field input:hover, .field select:hover, .field textarea:hover { border-color: #8f9586; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--black); box-shadow: 0 0 0 3px rgba(131,167,53,.45); }
.field input[type="file"] { padding: 10px; min-height: 0; background: var(--grey-light); border-style: dashed; cursor: pointer; }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: var(--error); }
.field-error { color: var(--error); font-size: var(--fs-small); font-weight: var(--w-regular); }
.field-error:empty { display: none; }

.check { display: flex; gap: 12px; align-items: flex-start; font-size: .9375rem; }
.check input { flex: none; width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--green-dark); cursor: pointer; }
.check.has-error { color: var(--error); }

.form-note { font-size: var(--fs-small); color: var(--text-muted); margin: 0; }
.form-status { padding: 14px 16px; border-radius: var(--radius); font-weight: var(--w-regular); }
.form-status:empty { display: none; }
.form-status--ok { background: rgba(131,167,53,.16); border-left: 4px solid var(--green); }
.form-status--error { background: #fdecea; border-left: 4px solid var(--error); color: var(--error); }

.form-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius-lg); padding: clamp(20px, 4vw, 40px); box-shadow: var(--shadow); }

/* Umschalter Kontakt / Offerte */
.tabs { display: inline-flex; gap: 4px; padding: 4px; margin-bottom: var(--space-4); background: var(--grey-light); border-radius: calc(var(--radius) + 4px); max-width: 100%; }
.tabs [role="tab"] {
  min-height: 44px; padding: 10px 18px; border: 0; border-radius: var(--radius);
  font: inherit; font-weight: var(--w-regular); font-size: 1rem; color: var(--text-muted);
  background: none; cursor: pointer;
}
.tabs [role="tab"][aria-selected="true"] { background: var(--white); color: var(--black); box-shadow: var(--shadow-sm); }

/* Karten-Platzhalter */
.map-placeholder {
  display: grid; place-items: center; gap: 8px; text-align: center;
  aspect-ratio: 4 / 3; padding: 24px; border-radius: var(--radius);
  background: var(--placeholder); color: var(--black); font-weight: var(--w-regular);
}

/* Video-Platzhalter */
.video { position: relative; border-radius: var(--radius-lg); overflow: hidden; aspect-ratio: 16 / 9; background: var(--black); }
.video img { width: 100%; height: 100%; object-fit: cover; opacity: .85; }
.video__play {
  position: absolute; inset: 0; margin: auto; width: 84px; height: 84px; border-radius: 50%;
  display: grid; place-items: center; border: 0; cursor: pointer;
  background: var(--green); color: var(--black); box-shadow: var(--shadow-lg);
  transition: transform .2s var(--ease), background-color .2s;
}
.video__play:hover { transform: scale(1.06); background: var(--green-dark); }
.video__play svg { width: 30px; height: 30px; margin-left: 4px; fill: currentColor; }

/* Rechtstexte */
.prose { max-width: 760px; }
.prose h2 { font-size: clamp(1.375rem, 1.2rem + .8vw, 1.75rem); margin-top: var(--space-5); }
.prose h3 { margin-top: var(--space-4); }
.prose p, .prose li { color: #2b2e28; }

/* Footer */
.site-footer { background: var(--black); color: var(--text-on-dark-muted); font-size: .9375rem; }
.site-footer a { color: var(--white); text-decoration-color: transparent; }
.site-footer a:hover { color: var(--green); text-decoration-color: var(--green); }
.footer-grid { display: grid; gap: 40px; padding-block: clamp(56px, 7vw, 88px) 40px; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .footer-grid { grid-template-columns: 1.5fr 1fr 1fr 1fr; } }
.footer-brand img { width: 170px; margin-bottom: 20px; }
.footer-brand p { max-width: 320px; margin: 0; }
.site-footer h2 { font-size: 1rem; color: var(--white); margin-bottom: 14px; letter-spacing: 0; }
.footer-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.site-footer address { font-style: normal; }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between;
  padding-block: 22px calc(22px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(255,255,255,.12); font-size: var(--fs-small);
}
.footer-bottom ul { display: flex; flex-wrap: wrap; gap: 8px 20px; list-style: none; margin: 0; padding: 0; }

/* Nach-oben-Button */
.to-top {
  position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 90;
  display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%;
  background: var(--green); color: var(--black); border: 0; cursor: pointer; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .25s, transform .25s var(--ease), visibility 0s linear .25s, background-color .2s;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.to-top:hover { background: var(--green-dark); }
.to-top svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
html.nav-open .to-top { display: none; }

/* ---------- 6. Hilfsklassen ---------- */
.mt-0 { margin-top: 0; } .mb-0 { margin-bottom: 0; }
.mt-4 { margin-top: var(--space-4); }
.text-center { text-align: center; }
.muted { color: var(--text-muted); }
.section-foot { margin-top: clamp(32px, 4vw, 48px); display: flex; flex-wrap: wrap; gap: 16px 28px; align-items: center; }
.section-head--center + * + .section-foot, .section-foot--center { justify-content: center; }

/* ---------- 7. Bewegung ---------- */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.js .reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

@media print {
  .site-header, .nav-panel, .to-top, .cta-band, .site-footer { display: none !important; }
  body { font-size: 11pt; }
}
.site-footer strong { color: var(--white); }

/* =========================================================
   8. Erweiterungen (Unterseiten, Formulare, Cookies, Lightbox)
   ========================================================= */

/* Hero-Wasserzeichen: Mäander aus dem Logo */
.hero__mark {
  position: absolute; z-index: -1; pointer-events: none;
  right: max(-60px, calc((100vw - var(--container)) / 2 - 120px));
  bottom: -40px; width: clamp(220px, 34vw, 480px); opacity: .05;
}
@media (max-width: 767px) { .hero__mark { right: -70px; bottom: auto; top: 24px; width: 220px; opacity: .07; } }

/* Seitenkopf mit Mäander */
.page-hero { position: relative; overflow: hidden; }
.page-hero::after {
  content: ""; position: absolute; right: -40px; bottom: -60px; width: 260px; aspect-ratio: 191 / 258;
  background: url("../img/favicon.svg") center / contain no-repeat; opacity: .12; pointer-events: none;
}
.page-hero > .container { position: relative; z-index: 1; }
@media (max-width: 599px) { .page-hero::after { width: 160px; right: -50px; bottom: -40px; } }

/* Zahlen-Kacheln hell (Unterseiten) */
.fact { padding: clamp(22px, 3vw, 30px); border-radius: var(--radius); background: var(--white); border: 1px solid var(--border); }
.fact__value { display: block; margin-bottom: 6px; font-weight: var(--w-heavy); font-size: clamp(1.875rem, 1.5rem + 1.5vw, 2.5rem); line-height: 1; color: var(--black); }
.fact__value::after { content: ""; display: block; width: 36px; height: 3px; margin-top: 14px; background: var(--green); border-radius: 2px; }
.fact p { margin: 0; color: var(--text-muted); }

/* Zitat / Motto */
.quote { margin: 0; padding: clamp(28px, 5vw, 56px); border-radius: var(--radius-lg); background: var(--black); color: var(--white); position: relative; overflow: hidden; }
.quote p { margin: 0; font-weight: var(--w-heavy); font-size: clamp(1.5rem, 1.1rem + 2vw, 2.5rem); line-height: 1.15; }
.quote p span { color: var(--green); }
.quote footer { margin-top: 18px; color: var(--text-on-dark-muted); }

/* Kontaktbereich */
.contact-grid { display: grid; gap: clamp(32px, 5vw, 64px); }
@media (min-width: 1000px) { .contact-grid { grid-template-columns: 1.5fr 1fr; align-items: start; } }
.contact-aside { display: grid; gap: 28px; }
@media (min-width: 1000px) { .contact-aside { position: sticky; top: calc(var(--header-h) + 24px); } }
.contact-aside h2, .contact-aside h3 { font-size: 1.25rem; margin-bottom: 14px; }
.contact-aside address { font-style: normal; }

/* Karte: gezeichnete Vorschau, Google Maps erst nach Einwilligung */
.map {
  position: relative; overflow: hidden; isolation: isolate;
  width: 100%; height: clamp(360px, 36vw, 440px);
  border-radius: var(--radius-lg); border: 1px solid var(--border);
  background: #eef0ea;
}
.map__art { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; }
.map__pin {
  position: absolute; left: 50%; top: 44%; width: 40px; height: 52px; transform: translate(-50%, -100%);
  filter: drop-shadow(0 6px 8px rgba(17,17,17,.25));
}
.map__pin::after {   /* Schatten unter der Nadel */
  content: ""; position: absolute; left: 50%; bottom: -6px; width: 18px; height: 6px; margin-left: -9px;
  border-radius: 50%; background: rgba(17,17,17,.18);
}
.map__card {
  position: absolute; left: 12px; right: 12px; bottom: 12px;
  display: grid; gap: 10px; padding: 16px 18px;
  background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow);
  font-size: .9375rem;
}
.map__address { margin: 0; line-height: 1.45; }
.map__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 18px; }
/* Radio-/Checkbox-Chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; }
.chip input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.chip span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 10px 16px;
  border: 1.5px solid var(--border-strong); border-radius: 999px; background: var(--white);
  font-size: .9375rem; cursor: pointer; transition: border-color .2s, background-color .2s;
}
.chip span:hover { border-color: #8f9586; }
.chip input:checked + span { background: var(--green); border-color: var(--green); color: var(--black); }
.chip input:focus-visible + span { box-shadow: var(--focus); }
.field.has-error .chip span { border-color: var(--error); }
.form-section { padding-top: 24px; border-top: 1px solid var(--border); }
.form-honey { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.btn[aria-busy="true"] { opacity: .7; pointer-events: none; }

.tabpanel[hidden] { display: none; }
.no-js-only { display: none; }
html:not(.js) .tabs { display: none; }

/* FAQ-Gruppen */
.faq-group + .faq-group { margin-top: clamp(40px, 5vw, 56px); }
.faq-group h2 { font-size: clamp(1.25rem, 1.1rem + .6vw, 1.5rem); margin-bottom: 18px; }
.faq-layout { display: grid; gap: clamp(32px, 5vw, 64px); }
@media (min-width: 1000px) { .faq-layout { grid-template-columns: 1fr 340px; align-items: start; } .faq-layout aside { position: sticky; top: calc(var(--header-h) + 24px); } }
.help-box { padding: 28px; border-radius: var(--radius); background: var(--black); color: var(--white); }
.help-box h2 { font-size: 1.25rem; color: var(--white); }
.help-box p { color: var(--text-on-dark-muted); }
.help-box a:not(.btn) { color: var(--white); }

/* Galerie-Links + Lightbox */
.gallery-item a { display: block; text-decoration: none; color: inherit; border-radius: var(--radius); }
.gallery-item a .media img { transition: transform .5s var(--ease); }
.gallery-item a:hover .media img { transform: scale(1.04); }
.lightbox { padding: 0; border: 0; background: transparent; max-width: 100vw; max-height: 100vh; width: 100vw; height: 100vh; }
.lightbox::backdrop { background: rgba(17,17,17,.92); }
.lightbox__inner { position: relative; width: 100%; height: 100%; display: grid; place-items: center; padding: 64px 16px; }
.lightbox figure { margin: 0; display: grid; gap: 12px; justify-items: center; max-width: min(1200px, 100%); }
.lightbox img { max-height: calc(100vh - 180px); width: auto; border-radius: var(--radius); }
.lightbox figcaption { color: var(--white); text-align: center; }
.lightbox button {
  position: absolute; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%;
  border: 0; background: var(--white); color: var(--black); cursor: pointer;
}
.lightbox button:hover { background: var(--green); }
.lightbox button svg { width: 22px; height: 22px; }
.lightbox__close { top: 16px; right: 16px; }
.lightbox__prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lightbox__next { right: 16px; top: 50%; transform: translateY(-50%); }
.lightbox__prev svg { transform: rotate(180deg); }
@media (max-width: 599px) { .lightbox__prev, .lightbox__next { top: auto; bottom: 16px; transform: none; } }

/* Video-Platzhalter */
.video__label { position: absolute; left: 16px; bottom: 16px; padding: 6px 12px; border-radius: 6px; background: rgba(255,255,255,.92); font-size: var(--fs-small); }
.video__play { pointer-events: none; }

/* Rechtstexte */
.prose h2:first-child { margin-top: 0; }
.prose dl { display: grid; grid-template-columns: max-content 1fr; gap: 6px 20px; margin: 0 0 var(--space-3); }
.prose dt { color: var(--text-muted); }
.prose dd { margin: 0; }
@media (max-width: 479px) { .prose dl { grid-template-columns: 1fr; } .prose dd { margin-bottom: 8px; } }
.prose .updated { color: var(--text-muted); font-size: var(--fs-small); }

/* Cookie-Hinweis */
.cookie {
  position: fixed; left: 16px; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); z-index: 150;
  max-width: 560px; padding: 22px; border-radius: var(--radius-lg);
  background: var(--white); color: var(--text); box-shadow: var(--shadow-lg); border: 1px solid var(--border);
}
@media (min-width: 600px) { .cookie { left: 24px; bottom: 24px; padding: 26px 28px; } }
.cookie[hidden] { display: none; }
.cookie h2 { font-size: 1.125rem; margin-bottom: 8px; }
.cookie p { font-size: .9375rem; color: var(--text-muted); margin-bottom: 16px; }
.cookie .btn-row .btn { flex: 1 1 180px; }
html.cookie-open .to-top { display: none; }
.footer-bottom .link-button { padding: 0; border: 0; background: none; font: inherit; color: var(--white); cursor: pointer; }
.footer-bottom .link-button:hover { color: var(--green); }

/* 404 / Danke */
.center-page { min-height: 60vh; display: grid; place-items: center; text-align: center; }
.center-page .btn-row { justify-content: center; }
.js .no-js-heading { display: none; }
.no-js-heading { font-size: 1.375rem; }
.tabpanel + .tabpanel { margin-top: 32px; }
.js .tabpanel + .tabpanel { margin-top: 0; }
h1, h2 { overflow-wrap: break-word; }
.cookie .btn-row .btn { flex: 1 1 140px; }

/* Referenzen: Objekte mit je 3 Bildern */
.ref-year + .ref-year { margin-top: clamp(48px, 6vw, 80px); }
.ref-year__title { display: flex; align-items: baseline; gap: 14px; padding-bottom: 14px; margin-bottom: clamp(20px, 3vw, 32px); border-bottom: 2px solid var(--green); font-size: clamp(1.75rem, 1.4rem + 1.4vw, 2.5rem); }
.ref-year__title span { font-family: var(--font); font-weight: var(--w-regular); font-size: 1rem; color: var(--text-muted); letter-spacing: 0; }
.ref-grid { display: grid; gap: clamp(28px, 3vw, 40px) clamp(16px, 2.4vw, 28px); }
@media (min-width: 600px) { .ref-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .ref-grid { grid-template-columns: repeat(3, 1fr); } }
.ref-card { margin: 0; scroll-margin-top: calc(var(--header-h) + 24px); }
.ref-card__media { display: grid; gap: 8px; margin-bottom: 14px; }
.ref-card__thumbs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ref-card__main, .ref-card__thumb { display: block; overflow: hidden; border-radius: var(--radius); background: var(--placeholder); aspect-ratio: 4 / 3; }
.ref-card__thumb { aspect-ratio: 16 / 9; }
.ref-card__main img, .ref-card__thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.ref-card__main:hover img, .ref-card__thumb:hover img { transform: scale(1.04); }
.ref-card__title { margin: 0 0 2px; font-size: 1.125rem; }
.ref-card__meta { margin: 0; color: var(--text-muted); font-size: .9375rem; }
.ref-card:target .ref-card__title { color: var(--green-text); }
.nav-toggle:focus-visible { border-radius: 50%; }
/* Objekt mit nur 2 Bildern: zweites Bild als breiter Streifen (gleiche Höhe wie 2 Vorschaubilder) */
.ref-card__thumbs--single { grid-template-columns: 1fr; }
.ref-card__thumbs--single .ref-card__thumb { aspect-ratio: auto; height: 100%; }
.ref-card__thumbs--single { aspect-ratio: 3.63; }
/* Objekt mit nur 1 Bild: ein hohes Bild, gleiche Gesamthöhe wie Kacheln mit 3 Bildern */
.ref-card__media--single { display: block; }
/* Höhe = Hauptbild (4:3) + 8px Abstand + Vorschaubilder ((Breite − 8px) / 2 × 9/16) */
.ref-card__media--single .ref-card__main { aspect-ratio: auto; height: auto; }
.ref-card__media--single .ref-card__main::before { content: ""; display: block; padding-top: calc(75% + 8px + (100% - 8px) * 0.28125); }
.ref-card__media--single .ref-card__main { position: relative; }
.ref-card__media--single .ref-card__main img { position: absolute; inset: 0; }

/* Sprachwahl DE / FR / IT */
.header-tools { display: flex; align-items: center; gap: 10px; }
.lang-switch { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.lang-switch a {
  display: grid; place-items: center; min-width: 34px; min-height: 34px; padding: 0 6px;
  border-radius: 6px; font-size: .8125rem; letter-spacing: .04em; text-decoration: none; color: var(--text-muted);
}
.lang-switch a:hover { color: var(--black); background: var(--grey-light); }
.lang-switch a[aria-current="true"] { color: var(--black); font-weight: var(--w-heavy); box-shadow: inset 0 -2px 0 var(--green); border-radius: 0; }
.lang-switch--footer { margin-top: 20px; }
.lang-switch--footer a { color: var(--text-on-dark-muted); }
.lang-switch--footer a:hover { color: var(--white); background: rgba(255,255,255,.08); }
.lang-switch--footer a[aria-current="true"] { color: var(--white); }
@media (min-width: 1100px) {
  .site-header__inner .nav-panel { order: 2; margin-left: auto; }
  .header-tools { order: 3; }
  .lang-menu { padding-left: 10px; border-left: 1px solid var(--border); }
}
@media (max-width: 1099px) {
  .brand { margin-right: auto; }
}
@media (max-width: 380px) {
  .brand img { width: 128px; }
  .lang-switch a { min-width: 30px; padding: 0 4px; }
  .header-tools { gap: 6px; }
}

/* Desktop-Navigation: Platz für längere FR/IT-Bezeichnungen */
@media (min-width: 1100px) {
  .nav-list a { white-space: nowrap; }
  .header-cta { display: none; } /* Platz für FR/IT – Offerte-Button steht in Hero, Kontaktband und Footer */
}
@media (min-width: 1100px) and (max-width: 1279px) {
  .brand img { width: 150px; }
  .nav-list { gap: 16px; }
  .nav-list a { font-size: .9375rem; }
  .site-header__inner { gap: 18px; }
}
/* Desktop: Menüpunkt «Kontakt» als grüner Button (ersetzt den separaten Offerte-Button im Header) */
@media (min-width: 1100px) {
  .nav-list li:last-child a {
    padding: 9px 18px; border-radius: var(--radius); background: var(--green); color: var(--black);
    transition: background-color .2s;
  }
  .nav-list li:last-child a::after { display: none; }
  .nav-list li:last-child a:hover, .nav-list li:last-child a[aria-current="page"] { background: var(--green-dark); color: var(--black); }
}

/* ---------- Datei-Upload: gestylter Button (übersetzbar) ----------
   Ohne JS bleibt das native Feld sichtbar; mit JS wird es nur visuell versteckt
   (per Tastatur erreichbar) und durch Label-Button + Statuszeile ersetzt. */
.upload__btn, .upload__status { display: none; }
.js .upload { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; }
.js .upload__btn { display: inline-flex; }
.js .upload__status { display: block; min-width: 0; font-size: var(--fs-small); color: var(--text-muted); overflow-wrap: anywhere; }
.js .field .upload input[type="file"] {
  position: absolute; width: 1px; height: 1px; min-height: 0; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.upload:has(input:focus-visible) .upload__btn { box-shadow: var(--focus); }
@supports not selector(:has(*)) { .upload:focus-within .upload__btn { box-shadow: var(--focus); } }
.field.has-error .upload__btn { border-color: var(--error); }

/* ---------- Mobile-Menü: Header bleibt beim offenen Menü sichtbar ----------
   html.nav-open sperrt das Scrollen (overflow: hidden) – dadurch greift position: sticky
   nicht mehr und der Header würde mit der Seite nach oben wegrutschen. Darum während
   des offenen Menüs fest am oberen Rand fixieren und die Höhe im Fluss reservieren. */
@media (max-width: 1099px) {
  html.nav-open .site-header { position: fixed; top: 0; left: 0; right: 0; }
  html.nav-open body { padding-top: calc(var(--header-h) + 1px); }
}

/* ---------- Seitenkopf der Unterseiten mit Titelbild ---------- */
.page-hero--image {
  isolation: isolate; color: var(--white); background: var(--black);
  padding-block: clamp(64px, 9vw, 128px) clamp(48px, 6vw, 88px);
}
.page-hero__media { position: absolute; inset: 0; z-index: -2; }
.page-hero__media img { width: 100%; height: 100%; object-fit: cover; object-position: center 60%; }
.page-hero--image::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background:
    linear-gradient(90deg, rgba(17,17,17,.90) 0%, rgba(17,17,17,.74) 50%, rgba(17,17,17,.35) 100%),
    linear-gradient(0deg, rgba(17,17,17,.45) 0%, rgba(17,17,17,0) 50%);
}
@media (max-width: 767px) { .page-hero--image::before { background: rgba(17,17,17,.78); } }
.page-hero--image::after { opacity: .1; }
.page-hero--image h1 { color: var(--white); }
.page-hero--image .lead { color: rgba(255,255,255,.88); }
.page-hero--image .eyebrow { color: var(--green); }
.page-hero--image .breadcrumb ol, .page-hero--image .breadcrumb a { color: rgba(255,255,255,.78); }
.page-hero--image .breadcrumb a:hover, .page-hero--image .breadcrumb [aria-current] { color: var(--white); }
.page-hero--image .breadcrumb li + li::before { color: rgba(255,255,255,.4); }
.page-hero--image :focus-visible { box-shadow: 0 0 0 3px var(--black), 0 0 0 6px var(--green); }

/* ---------- Download-Seite ---------- */
.mt-section { margin-top: clamp(48px, 7vw, 88px); }
.dl-grid { display: grid; gap: clamp(16px, 2.4vw, 28px); }
@media (min-width: 700px) { .dl-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .dl-grid { grid-template-columns: repeat(3, 1fr); } }
.dl-card {
  display: grid; grid-template-columns: 96px 1fr; gap: 18px; align-items: start;
  background: var(--white); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 20px; box-shadow: var(--shadow-sm);
}
.dl-card__thumb { display: block; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; background: var(--grey-light); }
.dl-card__thumb img { display: block; width: 100%; height: auto; }
.dl-card h3 { font-size: 1.0625rem; line-height: 1.35; margin: 0 0 6px; }
.dl-card p { margin: 0 0 10px; color: var(--text-muted); font-size: .9375rem; }
.dl-card .dl-card__meta { font-size: .8125rem; margin-bottom: 14px; }
.dl-note { margin: clamp(32px, 5vw, 56px) 0 0; font-size: .875rem; color: var(--text-muted); }

/* ---------- Video (Hochformat) mit Kapiteln ---------- */
.video--portrait { aspect-ratio: 478 / 850; width: 100%; max-width: 380px; margin: 0 auto; box-shadow: var(--shadow); }
.video--portrait video { display: block; width: 100%; height: 100%; object-fit: cover; background: var(--black); }
@media (max-width: 599px) { .video--portrait { max-width: 320px; } }
.chapters { margin: 24px 0; }
.chapters__label { margin: 0 0 10px; font-weight: var(--w-heavy); }
.chapters__label span { font-weight: var(--w-regular); color: var(--text-muted); font-size: var(--fs-small); }
.chapters__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; counter-reset: ch; }
.chapters__btn {
  display: flex; align-items: center; gap: 14px; width: 100%; min-height: 48px; padding: 10px 14px;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--white);
  font: inherit; color: var(--text); text-align: left; cursor: pointer;
  transition: border-color .2s, box-shadow .2s;
}
.chapters__btn:hover { border-color: var(--green); box-shadow: var(--shadow-sm); }
.chapters__btn.is-active { border-color: var(--green); box-shadow: inset 4px 0 0 var(--green); }
.chapters__time { flex: none; min-width: 44px; padding: 2px 8px; border-radius: 6px; background: var(--grey-light); font-size: var(--fs-small); font-variant-numeric: tabular-nums; text-align: center; }
.bg-light .chapters__time { background: var(--grey-light); }

/* ---------- Downloads: Hinweise auf der Seite Einfräs-System ---------- */
.dl-inline { margin: 20px 0 0; }
.dl-inline a { display: inline-flex; align-items: center; gap: 8px; font-weight: var(--w-heavy); }
.dl-inline svg { width: 18px; height: 18px; flex: none; }
.section-head--split { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 32px; }
.section-head--split > div { max-width: 640px; }
.section-head--split .btn svg { width: 18px; height: 18px; }

/* ---------- Heizkreisplan: ganzer Plan sichtbar, per Klick vergrössern ---------- */
.media--plan { aspect-ratio: auto; background: var(--white); border: 1px solid var(--border); }
.media--plan a { display: block; cursor: zoom-in; }
.media--plan img { height: auto; object-fit: contain; }
.media--plan figcaption { position: static; border-radius: 0; padding: 10px 14px; background: var(--grey-light); border-top: 1px solid var(--border); }

/* ---------- Bilder: weisser Hintergrund für Zeichnungen, Abstand unter Bild ---------- */
.media--white { background: var(--white); border: 1px solid var(--border); }
.media--white img { object-fit: contain; }
.mb-figure { margin-bottom: 20px; }

/* ---------- YouTube: erst nach Klick laden (Datenschutz) ---------- */
.yt-section { margin-top: clamp(48px, 7vw, 80px); padding-top: clamp(32px, 5vw, 48px); border-top: 1px solid var(--border); }
.yt-section__title { margin: 0 0 6px; }
.yt-section__lead { margin: 0 0 24px; color: var(--text-muted); max-width: 640px; }
.yt-grid { display: grid; gap: clamp(20px, 3vw, 32px); }
@media (min-width: 768px) { .yt-grid { grid-template-columns: repeat(2, 1fr); } }
.yt { margin: 0; }
.yt__frame { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius-lg); overflow: hidden; background: var(--black); box-shadow: var(--shadow-sm); }
.yt__frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.yt__btn { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: pointer; }
.yt__btn img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.72); transition: filter .25s; }
.yt__btn:hover img { filter: brightness(.85); }
.yt__play { position: absolute; left: 50%; top: 50%; width: 72px; height: 72px; margin: -36px 0 0 -36px; display: grid; place-items: center; border-radius: 50%; background: var(--green); color: var(--black); box-shadow: 0 8px 24px rgba(0,0,0,.3); transition: transform .2s; }
.yt__btn:hover .yt__play { transform: scale(1.06); }
.yt__play svg { width: 30px; height: 30px; margin-left: 4px; fill: currentColor; }
.yt__btn:focus-visible { outline: 3px solid var(--green); outline-offset: -3px; }
.yt figcaption { margin-top: 12px; display: grid; gap: 4px; }
.yt figcaption span { font-size: var(--fs-small); color: var(--text-muted); }

/* ---------- Sprachwahl im Header als Dropdown ---------- */
.lang-menu { position: relative; }
.lang-menu summary {
  display: flex; align-items: center; gap: 5px; min-height: 40px; padding: 0 8px; border-radius: 8px;
  list-style: none; cursor: pointer; user-select: none; font-size: .8125rem; font-weight: var(--w-heavy); letter-spacing: .04em; color: var(--black);
}
.lang-menu summary::-webkit-details-marker { display: none; }
.lang-menu summary:hover, .lang-menu[open] summary { background: var(--grey-light); }
.lang-menu summary:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.lang-menu svg { fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.lang-menu__globe { width: 18px; height: 18px; color: var(--text-muted); }
.lang-menu__chev { width: 14px; height: 14px; transition: transform .2s; }
.lang-menu[open] .lang-menu__chev { transform: rotate(180deg); }
.lang-menu__list {
  position: absolute; right: 0; top: calc(100% + 6px); z-index: 60; min-width: 170px; margin: 0; padding: 6px;
  list-style: none; background: var(--white); border: 1px solid var(--border); border-radius: 10px; box-shadow: var(--shadow-sm), 0 12px 32px rgba(0,0,0,.12);
}
.lang-menu__list a {
  display: flex; align-items: center; gap: 10px; min-height: 40px; padding: 0 10px; border-radius: 6px;
  text-decoration: none; color: var(--black); font-size: .9375rem;
}
.lang-menu__list a:hover { background: var(--grey-light); }
.lang-menu__list a[aria-current="true"] { font-weight: var(--w-heavy); box-shadow: inset 3px 0 0 var(--green); }
.lang-menu__code { min-width: 22px; font-size: .75rem; letter-spacing: .04em; color: var(--text-muted); }
@media (max-width: 380px) { .lang-menu summary { padding: 0 6px; } .lang-menu__globe { display: none; } }
.site-header:has(.lang-menu[open]) { z-index: 160; } /* offenes Menü über dem Cookie-Hinweis */

/* ---------- Google-Bewertungen ---------- */
.stars { display: inline-flex; gap: 2px; color: #d99a0b; vertical-align: -3px; }
.stars svg { width: 20px; height: 20px; fill: currentColor; }
.stars svg.half { opacity: .5; } .stars svg.empty { color: var(--border-strong); }
.rv-bar { border-bottom: 1px solid var(--border); background: var(--white); }
.rv-bar .container { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; padding-block: 20px; }
.rv-bar__score { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin: 0; }
.rv-bar__score strong { font-size: 1.75rem; letter-spacing: -0.03em; line-height: 1; color: var(--black); }
.rv-bar__acts { margin-left: auto; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
@media (max-width: 599px) { .rv-bar__acts { margin-left: 0; width: 100%; justify-content: space-between; } }
.rv-cta { display: grid; gap: 24px 48px; align-items: center; margin-top: clamp(48px, 7vw, 80px); padding-top: clamp(32px, 5vw, 48px); border-top: 1px solid var(--border); }
.section--rv .rv-cta { margin-top: 0; }
@media (min-width: 900px) { .rv-cta { grid-template-columns: 1fr minmax(320px, 420px); } }
.rv-cta h2 { margin-bottom: var(--space-2); }
.rv-cta__text p { margin: 0; color: var(--text-muted); font-size: var(--fs-lead); max-width: 36em; }
.rv-card { background: var(--white); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; display: grid; gap: 16px; }
.bg-light .rv-card { border-color: transparent; }
.rv-card__score { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; margin: 0; }
.rv-card__score strong { font-size: 2.5rem; letter-spacing: -0.04em; line-height: 1; color: var(--black); }
.footer-hours { margin: 18px 0 0; }
.footer-hours strong { color: var(--white); }
