/* Zentrale Container-Breite, mehrfach verwendbar */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0; /* Seitenpadding entfernt */
}
:root {
  --color-light: #E3EAC5;
  --color-dark: #4b5d34;
  --color-accent: #517E04;
  --color-muted: #B0BB95;
  --font-family-base: 'Quicksand', sans-serif;
  --font-family-accent: 'Sacramento', cursive;
  --font-family-number: 'Rubik', sans-serif;
  --container-max: 980px; /* zentrale Spaltenbreite */
  --color-primary: #6b7a3a;
  --color-accent: #9bb14a;
  --color-light: #e6edd1; /* global hellgrüner Hintergrund */
  --color-content: #f5f7ea; /* heller Content-Hintergrund */
  --flow-gap: 2.2rem; /* Standardabstand zwischen Stripes */
  --flow-gap-first: 1.6rem; /* deutlich kleinerer Abstand vom Fließtext zum ersten Stripe */

  /* News/Teaser Farb-Token */
  --color-teaser-bg: #92aba5; /* Full-Bleed-Hintergrund wie Teaser */
  --color-news-date: var(--color-dark);
  --color-news-title: var(--color-dark);
  --color-badge-bg: #e5e5e5;
  --color-badge-text: #555;
  --color-news-text: var(--color-dark);
  --color-scheduled: #fd7e14;
}
/* Seite beim Laden sanft einblenden (CSS-only, 200ms) */
@keyframes page-fade-in { from { opacity: 0; } to { opacity: 1; } }
html, body { animation: page-fade-in 500ms ease-out both; }
/* Scrollbar-Gutter reservieren, um Layout-Shift zu vermeiden */
html { scrollbar-gutter: stable; }
/* View Transitions: global crossfade, short and subtle */
::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 250ms;
}
@media (prefers-reduced-motion: reduce) {
  ::view-transition-old(root),
  ::view-transition-new(root) {
    animation-duration: 0.001ms; /* effectively off */
  }
}
/* Sanftes Scrollen bei Anker-Sprüngen */
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
@supports not (scrollbar-gutter: stable) {
  html { overflow-y: auto; }
}

/* Aktuelles / News Stripe */
.stripe-section.news { 
  background-color: var(--color-teaser-bg); /* Full-Bleed-Hintergrund wie Teaser */
}
.news .stripe-inner { --section-max: 960px; }
.news h2 { 
  text-align: center;
  font-family: 'Quicksand', Arial, Helvetica, sans-serif;
  font-weight: 300;
  font-size: 36px;
  margin-bottom: 0.5rem;
  color: var(--color-content);
}
.news .updates {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.news .update-item {
  background: var(--color-content);
  border-radius: 12px;
  padding: 16px 20px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.06);
}
.news .update-item .date { 
  display: inline-block; 
  color: var(--color-news-date); 
  font-size: 14px; 
  margin-bottom: 4px; 
}
.news .update-item .title { 
  font-size: 20px; 
  margin: 0 0 6px; 
  color: var(--color-news-title);
  font-weight: 600;
}
.news .update-item .title .status-badge {
  display: inline-block;
  background: var(--color-badge-bg);
  color: var(--color-badge-text);
  font-size: 11px;
  font-weight: 500;
  padding: 2px 6px;
  border-radius: 3px;
  margin-left: 8px;
  vertical-align: middle;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.news .update-item .title .scheduled-badge {
  background: var(--color-scheduled);
  color: white;
  padding: 2px 6px;
  border-radius: 3px;
  font-size: 11px;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin-left: 8px;
}

.scheduled-badge svg {
  width: 10px;
  height: 10px;
  fill: currentColor;
}

.news .update-item .text { 
  margin: 0; 
  color: var(--color-news-text); 
  line-height: 1.8; 
}
.news .update-item .more { 
  margin: 0.5rem 0 0; 
}
.news .update-item .link { 
  color: #4b5d34; 
  font-weight: 700; 
  text-decoration: none; 
  border-bottom: 2px solid #9bb14a; 
  padding-bottom: 2px; 
}
.news .update-item .link:hover, 
.news .update-item .link:focus { 
  color: #767e4e; 
}

/* etwas mehr vertikaler Atemraum für den Stripe */
.stripe-section.news .stripe-inner { padding-top: 36px; padding-bottom: 36px; }

@media (min-width: 601px) {
  /* Updates untereinander auch auf Desktop */
  .news .updates { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .news .stripe-inner { --section-pad-x: 24px; }
}

/* Startseite: Kontaktbox vertikale Polsterung wie "Aktuelles" */
.contact-box.home-top-pad .stripe-inner { padding-top: 36px; padding-bottom: 36px; }

/* Stripe-Section Utilities: Module mit durchlaufendem Content-Hintergrund */
.stripe-section {
  position: relative;
  background: transparent;
}

.stripe-section::before {
  content: "";
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  top: 0;
  bottom: 0;
  width: min(var(--section-max, 960px), 100%);
  /* Content-Background entfernt: nur noch Full-Bleed-Varianten nutzen */
  background: transparent;
  z-index: 0;
}

/* Optional zentrierter Content-Background nur bei Bedarf */
.stripe-section.content-bg::before {
  background: var(--color-content);
}

.stripe-section .stripe-inner {
  position: relative;
  z-index: 1;
  max-width: min(var(--section-max, 960px), 100%);
  margin: 0 auto;
  padding-left: var(--section-pad-x, 140px);
  padding-right: var(--section-pad-x, 140px);
  /* Zentrale Regel: oben immer 0, unten 1.5rem als Default */
  padding-top: 0;
  padding-bottom: var(--section-pad-bottom, var(--flow-gap));
}

/* Sicherheitsnetz: falls Variablen nicht greifen, explizit auf 0 setzen */
/* pad-none: nur vertikal unten 0 (oben ist ohnehin 0); X bleibt unberührt */
.stripe-section.pad-none .stripe-inner {
  padding-bottom: 0 !important;
}

/* Nur horizontales Padding entfernen */
.stripe-section.padx-none .stripe-inner {
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Full-bleed Variante: Content-Hintergrund über volle Seitenbreite */
.stripe-section.full-bleed::before {
  left: 0;
  right: 0;
  transform: none;
  width: auto; /* über gesamte Sektion */
}

/* Breiten-Varianten */
.stripe-section.w-narrow { --section-max: 820px; }
.stripe-section.w-regular { --section-max: 960px; }
.stripe-section.w-wide { --section-max: 1120px; }
.stripe-section.w-full { --section-max: 100%; }

/* Padding-Varianten */
.stripe-section.pad-none { --section-pad-x: 0; --section-pad-top: 0; --section-pad-bottom: 0; }
/* pad-*: nur unteren Abstand steuern; oben bleibt 0 */
.stripe-section.pad-s { --section-pad-x: 60px;  --section-pad-bottom: 1rem; }
.stripe-section.pad-m { --section-pad-x: 100px; --section-pad-bottom: 1.25rem; }
.stripe-section.pad-l { --section-pad-x: 140px; --section-pad-bottom: 1.5rem; }

/* Nur horizontale Padding-Skala (X): s/m/l analog zu pad-* Breakpoints */
.stripe-section.padx-s { --section-pad-x: 60px; }
.stripe-section.padx-m { --section-pad-x: 100px; }
.stripe-section.padx-l { --section-pad-x: 140px; }

@media (max-width: 1200px) {
  .stripe-section.pad-l { --section-pad-x: 100px; }
}
@media (max-width: 980px) {
  .stripe-section.pad-l, .stripe-section.pad-m { --section-pad-x: 60px; }
}
@media (max-width: 600px) {
  .stripe-section.pad-l, .stripe-section.pad-m, .stripe-section.pad-s { --section-pad-x: 24px; }
}

/* Breakpoints für padx-* entsprechen der vertikalen Skala */
@media (max-width: 1200px) {
  .stripe-section.padx-l { --section-pad-x: 100px; }
}
@media (max-width: 980px) {
  .stripe-section.padx-l, .stripe-section.padx-m { --section-pad-x: 60px; }
}
@media (max-width: 600px) {
  .stripe-section.padx-l, .stripe-section.padx-m, .stripe-section.padx-s { --section-pad-x: 24px; }
}

/* Maps-Box Layout (nutzt stripe-inner für Padding/Max-Breite) */
.maps-box .maps {
  display: block; /* nur die Karte, keine 2-Spalten-Grid mehr */
}

/* Flowtext-Stripe: übernimmt Content-Typografie */
.flowtext-box .stripe-inner {
  max-width: 960px;
}

/* Contactbox: exakt gleiche Innenbreite wie Flowtext */
.contact-box .stripe-inner { max-width: 960px; }
/* Sicherheitsnetz: Karte darf nicht breiter als Container werden */
.contact-box .contact-card { max-width: 100%; }
.flowtext-box .stripe-inner p,
.flowtext-box .stripe-inner li { 
  font-size: 18px; 
  line-height: 1.9; 
  color: #4b5e34;
}
.flowtext-box .stripe-inner p { margin: 0 0 1rem; }
.flowtext-box .stripe-inner h2 { 
  font-size: 32px; 
  font-weight: 400; 
  margin-top: 2rem; 
  color: #182f05;
}

/* Erste/letzte Kante im Flowtext entschärfen: keine Zusatzlücke */
.flowtext-box .stripe-inner > :first-child { margin-top: 0; }
.flowtext-box .stripe-inner > :last-child { margin-bottom: 0; }

/* Media-Layout für Flowtext-Stripe */
.flowtext-box.has-media .flowtext-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: start;
}
.flowtext-box.has-media .flowtext-media img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
}
.flowtext-box.has-media .flowtext-media figcaption {
  font-size: 14px;
  color: #4b5e34;
  margin-top: 0.5rem;
}

/* Zweispaltig ab 768px, Bildposition links/rechts steuerbar */
@media (min-width: 768px) {
  .flowtext-box.has-media .flowtext-grid { grid-template-columns: 1fr 1fr; }
  .flowtext-box.has-media.image-left .flowtext-media { order: 1; }
  .flowtext-box.has-media.image-left .flowtext-content { order: 2; }
  .flowtext-box.has-media.image-right .flowtext-content { order: 1; }
  .flowtext-box.has-media.image-right .flowtext-media { order: 2; }
}

/* Keine doppelte Vertikal-Lücke zwischen zwei Stripes */
.stripe-section + .stripe-section { padding-top: 0; margin-top: 0; }

/* Standard: keine Zusatzlücke zwischen Stripes */
.stripe-section + .flowtext-box { padding-top: 0; margin-top: 0; }

/* Speziell: folgt Flowtext (mit Content-Background) direkt auf Maps, gebe dem Flowtext oben Innenabstand,
   damit der Content-Background durchläuft und der Abstand korrekt wirkt */
.maps-box + .flowtext-box.content-bg .stripe-inner {
  padding-top: var(--flow-gap-first);
}
/* Ausnahme: folgt auf ein full-bleed Element ein normales, setze Standard-Top-Abstand */
.stripe-section.full-bleed + .stripe-section:not(.full-bleed) .stripe-inner { 
  padding-top: var(--flow-gap);
}
/* Wenn ein Nicht-Stripe (z.B. .services oder .content) auf einen full-bleed Stripe trifft: Top-Abstand auf dem full-bleed herstellen */
/* Wenn ein Nicht-Stripe (z.B. .services oder .content) auf einen full-bleed Stripe trifft: Top-Abstand auf dem full-bleed herstellen */
.services + .stripe-section.full-bleed .stripe-inner { 
  padding-top: var(--flow-gap);
}
.content + .stripe-section.full-bleed .stripe-inner {
  padding-top: var(--flow-gap);
}
.stripe-section:has(+ .flowtext-box) { padding-bottom: 0; }
/* Letztes Element im vorherigen Stripe nicht zusätzlich unten abstehen lassen */
.stripe-section:has(+ .flowtext-box) .stripe-inner > :last-child { margin-bottom: 0; }

/* Tablet und kleiner: erst ab 600px untereinander */
@media (max-width: 600px) {
  .maps-box .maps { grid-template-columns: 1fr; }
}

.maps-box img,
.maps-box iframe,
.maps-box #map,
.maps-box .map-canvas {
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  border-radius: 0; /* keine abgerundeten Ecken für die Karte */
}

.maps-box iframe,
.maps-box #map,
.maps-box .map-canvas {
  min-height: 300px;
}

/* Kleinste Auflösung: gleiche Höhe für Google Maps und Skizze */
@media (max-width: 600px) {
  .maps-box iframe,
  .maps-box img,
  .maps-box #map,
  .maps-box .map-canvas {
    height: 260px; /* gleiche definierte Höhe */
  }
  .maps-box img { object-fit: cover; }
}

/* Zweitkleinste Auflösung (601–768px): zweispaltig, gleiche Höhe */
@media (min-width: 601px) and (max-width: 768px) {
  .maps-box iframe,
  .maps-box img,
  .maps-box #map,
  .maps-box .map-canvas {
    height: 300px; /* gleiche definierte Höhe im 2-Spalten-Layout */
  }
  .maps-box img { object-fit: cover; }
}
/* Desktop: fixe Navi-Höhe 75px */
@media (min-width: 821px) {
  .site-header .container {
    height: 75px;
  }
  .nav {
    padding: 0; /* Höhe kommt über Link-Zeilenhöhe */
    margin: 0;  /* keine vertikalen Außenabstände */
  }
  .nav a {
    height: 75px;
    /* 60px vom Text bis zum nächsten Trenner (rechts) */
    padding: 0 60px 0 0;
  }
  /* 15px Abstand nach dem Trenner links nur für Links mit Trenner */
  .nav a + a { padding-left: 15px; }
  /* Vertikale Trenner: exakt 35px hoch, mittig ausgerichtet */
  .nav a + a::before {
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    width: 1px;
    height: 35px;
    background: rgba(24, 47, 3, 0.25);
    transform: translateY(-50%);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: var(--font-family-base);
  font-size: 18px;
  line-height: 1.6;
  color: var(--color-dark);
  background-color: var(--color-light);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3 {
  margin-top: 0;
  font-family: var(--font-family-base);
  color: var(--color-dark);
}

h1 {
  font-size: 56px;
}

h2 {
  font-size: 36px;
}

h3 {
  font-size: 32px;
}

.container {
  width: 90%;
  max-width: 1050px;
  margin: 0 auto;
}

.site-header {
  background-color: var(--color-light);
  border-bottom: 1px solid var(--color-muted);
  position: sticky;
  top: 0;
  z-index: 100;
  /* subtile Schattenkante wie im Original */
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.15);
  padding-top: 0;
  padding-bottom: 0;
}

.site-header .container {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.menu-toggle {
  display: none;
  background: transparent;
  border: 0;
  padding: 0.25rem;
  cursor: pointer;
}

.menu-toggle .burger {
  display: inline-flex;
  flex-direction: column;
  gap: 5px;
}

.menu-toggle .burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-dark);
  border-radius: 2px;
  transition: transform 200ms ease, opacity 200ms ease;
}

/* Animate into an X when menu is open */
.site-header.open .menu-toggle .burger span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.site-header.open .menu-toggle .burger span:nth-child(2) {
  opacity: 0;
}
.site-header.open .menu-toggle .burger span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.nav {
  display: flex;
  justify-content: flex-start;
  gap: 0;
  padding: 1rem 0;
}

.nav a {
  text-decoration: none;
  color: var(--color-dark);
  font-weight: 400; /* normal */
  font-size: 16px; /* gewünschte Größe */
  font-family: "Roboto Condensed", "DIN Neuzeit Grotesk", "DIN 2014", "FF DIN", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  padding: 0.4rem 0.65rem; /* enger wie Original */
  position: relative;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.1;
  letter-spacing: 0;
  display: inline-flex;
  align-items: center;
  /* Reserve space for active underline to avoid vertical shift */
  border-bottom: 2px solid transparent;
  box-sizing: border-box;
}

/* Desktop-Abstände NACH Basisregel überschreiben (Cascade-Sicherheit) */
/* Desktop-Basis: keine Kompression oberhalb 1220px */
@media (min-width: 1221px) {
  .nav { gap: 8px; }
  .nav a { height: 75px; padding: 0 60px 0 0 !important; font-size: 16px; }
  .nav a + a { padding-left: 15px !important; }
}

/* Kompression nur zwischen 821px und 1220px aktivieren */
@media (min-width: 821px) and (max-width: 1220px) {
  /* Linear from 8px @1220 -> 4px @821 (sanfter) */
  .nav { gap: clamp(4px, calc(1.003vw - 4.25px), 8px); }
  .nav a {
    height: 75px;
    /* Linear from 60px @1220 -> 20px @821 (sanfter) */
    padding: 0 clamp(20px, calc(10.025vw - 62.31px), 60px) 0 0 !important;
    /* Linear from 16px @1220 -> 15.5px @821 (sanfter) */
    font-size: clamp(15.5px, calc(0.1253vw + 14.473px), 16px);
  }
  /* Linear from 15px @1220 -> 8px @821 (sanfter) */
  .nav a + a { padding-left: clamp(8px, calc(1.755vw - 6.41px), 15px) !important; }
}

.nav a + a {
  /* Trenner wird als Pseudo-Element gezeichnet (siehe Desktop-Query) */
  padding-left: 0; /* Abstand kommt über symmetrisches Link-Padding */
  margin-left: 0rem;
}

.nav a.active { border-bottom-color: var(--color-accent); }

/* Hero section on the homepage */
.hero {
  background-image: url('/assets/startseite_header.avif');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  height: 497px; /* um 2px reduziert */
  padding: 0; /* keine zusätzliche vertikale Höhe */
  display: flex;
  align-items: center; /* Inhalt vertikal zentrieren */
  color: #fff;
  margin-bottom: -2px; /* verhindert feine Linie unter dem Hero */
}

/* Ab 1418px: Bild nicht weiter skalieren, Hintergrundfarbe füllt den Rest */
@media (min-width: 1418px) {
  .hero {
    background-size: 1418px auto; /* feste Bildbreite */
    background-position: center;  /* mittig ausrichten */
    background-color: #92aba5;    /* Unicolor Hintergrund */
  }
}

/* Globales Overlay entfernt – Teaser übernimmt die Tönung */

.hero-content {
  position: relative;
  width: 540px; /* feste Teaserbreite */
  margin-left: 0; /* an Containerkante ausrichten */
  padding: 28px 28px 44px; /* unten mehr Platz für Button-Ansatz */
  background: rgba(24, 47, 3, 0.7);
  border-radius: 0 22px 22px 0; /* rechts oben/unten abgerundet */
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
  z-index: 1;
}

.hero h1 {
  font-size: 36px;
  font-weight: 400;
  color: #fff;
  line-height: 1.15;
  margin-bottom: 5px; /* weiter reduziert */
}

.hero .footnote-text {
  font-size: 12px;
  font-style: italic;
  margin-top: 0; /* keine Zusatzhöhe nach der Headline */
  margin-bottom: 11px; /* um 5px reduziert */
}

.hero .lead {
  font-size: 18px;
  margin-top: 0; /* verhindert Margin-Collapse mit Fußnote */
  margin-bottom: 1rem;
}

.hero .signature {
  font-family: var(--font-family-accent);
  font-size: 32px;
  color: var(--color-light);
  margin-top: 1rem;
  margin-bottom: 0; /* kein Abstand nach der Signatur */
  line-height: 1; /* kompaktere Zeilenhöhe */
}

.hero .subtitle {
  font-size: 14px;
  color: var(--color-light);
  margin-top: 5px; /* noch näher an die Signatur heran */
  line-height: 1; /* kompaktere Zeilenhöhe */
}

/* Anker-Button am unteren Rand des Teasers */
.teaser-anchor {
  position: absolute;
  left: 50%;
  bottom: -17px; /* 17px nach unten versetzt (überhängend) */
  transform: translateX(-50%);
  width: 43px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: row;
  flex-grow: 1; /* entspricht computed, ohne Layout zu stören */
  flex-basis: auto;
  padding: 0;
  margin: 0;
  overflow: hidden;
  background: #4b5d34; /* Markenfarbe */
  background-clip: border-box;
  background-origin: padding-box;
  border: 2px solid #e1eac5; /* helle Kontur (2px) */
  border-radius: 18px; /* abgerundete Ecken passend zur Höhe */
  color: #fff;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 10px;
  vertical-align: baseline;
  cursor: pointer;
  outline: none;
  text-decoration: none;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: all 0.2s ease, visibility 0s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}

.teaser-anchor::after {
  content: "";
  display: block;
  width: 16px; /* größer/fetter */
  height: 16px; /* größer/fetter */
  background-color: #e1eac5; /* Icon in hellem Grün */
  -webkit-mask-image: url('/assets/anchor-link.svg');
  mask-image: url('/assets/anchor-link.svg');
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
}

.teaser-anchor:hover,
.teaser-anchor:focus {
  background: #767e4e; /* Hover-Farbe gemäß Vorgabe */
}

/* Services section */
.services {
  padding: 50px 0 4rem; /* 50px Abstand nach dem Hero, unten unverändert */
  background-color: var(--color-light);
}
/* Explizit für das Ankerziel #leistungen (höchste Spezifität) */
#leistungen { scroll-margin-top: 60px; }

.services .services-inner {
  max-width: 980px; /* unsichtbarer innerer Container */
  margin: 0 auto;   /* zentriert im äußeren Container */
}

.services h2 {
  text-align: center;
  font-family: 'Quicksand', Arial, Helvetica, sans-serif; /* Family name: Quicksand */
  font-size: 36px; /* gewünschte Größe */
  font-weight: 300; /* Light */
  margin-bottom: 1rem;
}

.services .cards {
  display: flex;
  flex-wrap: wrap;
  justify-content: center; /* innerhalb des inneren Containers zentrieren */
  gap: 2rem;
}

/* Desktop: exakte Zentrierung der drei Karten innerhalb des Containers */
@media (min-width: 981px) {
  .services .cards {
    gap: 1rem; /* Desktop-Abstand, Gruppe bleibt mittig in services-inner */
  }
}

.card {
  background-color: #f5f7ea;
  padding: 1rem;
  border-radius: 16px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  /* Dynamische Breite: schrumpft bis ~232px, wächst nie über 305px */
  flex: 1 1 calc((100% - 4rem) / 3); /* 3 Karten, 2 Gaps à 2rem in Summe 4rem */
  max-width: 305px;
  min-width: 210px; /* weiter schrumpfen, damit 3 Karten länger nebeneinander passen */
  text-align: center;
  position: relative; /* für absolut positionierten Button */
  color: #4b5e34; /* vereinheitlichte Fließtextfarbe in Leistungsteasern */
}

.card img {
  width: 132px;
  height: 132px;
  display: block;
  margin: 2em auto 0.5em;
}

/* Feinkorrektur: Coaching-Icon hat offenbar optischen Rand im SVG */
.cards .card:nth-child(1) img {
  transform: translateX(5px);
}

.cards .card:nth-child(3) img {
  transform: translateX(12px);
}

.card h3 {
  font-size: 20px;
  margin-bottom: 0.5rem;
  color: #1a3105; /* Headlines in Karten */
}

.card p {
  font-size: 16px;
  margin-bottom: 1rem;
  line-height: 1.9;
  color: #1a3105; /* Fließtext in Karten */
}

.card .button {
  position: absolute;
  left: 50%;
  bottom: -17px; /* überlappend wie Anchor */
  transform: translateX(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px; /* wie Anchor */
  padding: 0 15px 0 21px; /* Content 3px nach rechts geschoben, Gesamtbreite bleibt gleich */
  background: #4b5d34; /* wie Anchor */
  border: 2px solid #e1eac5; /* wie Anchor */
  border-radius: 18px; /* wie Anchor */
  color: #e1eac5; /* Icon-Farbe als Textfarbe */
  text-decoration: none;
  font-size: 14px;
  letter-spacing: 0.02em;
  font-weight: 700;
  white-space: nowrap; /* Zeilenumbruch verhindern */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,0.15);
}

.card .button:hover,
.card .button:focus {
  background: #767e4e; /* Hover wie Anchor */
}

/* Dekoratives Icon im Button, gedreht um 90° und hinter dem Text positioniert (optisch danach) */
.card .button::after {
  content: "";
  display: inline-block;
  width: 14px;
  height: 14px;
  background-color: #e1eac5; /* gleiche Farbe wie Text/Icon */
  -webkit-mask-image: url('/assets/anchor-link.svg');
  mask-image: url('/assets/anchor-link.svg');
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
  transform: rotate(-90deg);
  margin-left: 8px; /* Abstand zum Text */
}

/* Contact teaser: Layout via stripe-section; nur die Karte selbst wird gestylt */

/* Sicherheit: Footer soll direkt anschließen, ohne eigenen oberen Abstand */
.site-footer { 
  margin-top: 0; 
}

.contact-box .contact-card {
  position: relative;
  width: 100%;
  max-width: none; /* wie .news .update-item: volle Stripe-Breite innerhalb stripe-inner */
  margin: 0 auto;
  background: #92aba5; /* Box-Hintergrund */
  color: #fff; /* Text in der Box: weiß */
  border-radius: 12px;
  padding: 16px 20px; /* wie .news .update-item */
  box-shadow: 0 4px 14px rgba(0,0,0,0.06); /* wie News-Card */
}

.contact-box h2 {
  font-size: 34px;
  margin-bottom: 0.5rem; /* enger unter der Headline */
  color: #fff;
  font-weight: 400;
  /* Platz für die linke runde Icon-Marke (50px) + Abstand (18px) abzüglich Card-Padding (20px) + Sicherheitsabstand */
  padding-left: 60px;
}

.contact-box p {
  margin: 0.25rem 0; /* enger ober- und unterhalb */
  font-size: 16px;
  line-height: 1.9;
}

.contact-box .phone {
  font-family: var(--font-family-number);
  font-size: 30px;
  font-weight: 400;
  color: #fff;
}

/* Links in der Kontaktbox ebenfalls weiß */
.contact-box a { color: #fff; }

/* Telefonlink ohne Unterstreichung */
.contact-box .phone a {
  text-decoration: none;
  color: inherit; /* übernimmt #fff aus .contact-box */
}

/* Obere linke Kreis-Ikone */
.contact-box .corner-icon {
  position: absolute;
  top: 20px; 
  left: 18px; 
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: #92aba5; /* Hintergrund der Boxfarbe für Durchgängigkeit */
  border: 3px solid #f5f7ea; /* gewünschte Border */
  display: inline-block;
}

.contact-box .corner-icon::after {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 30px;
  height: 30px;
  background-color: #f5f7ea; /* Icon-Farbe im Kreis */
  -webkit-mask-image: url('/assets/telephone.svg');
  mask-image: url('/assets/telephone.svg');
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
}

/* Footer */
.site-footer {
  background-color: #223c18; /* gewünschter Hintergrund */
  color: #f5f7ea; /* helle Schrift auf dunklem Grund */
  padding: 22px 2rem; /* vertikal 10px geringer */
  font-size: 14px;
  text-align: center; /* Text zentriert */
  border-top: none;
}

.site-footer .footer-nav {
  margin-top: 1rem;
}

.site-footer .footer-nav a {
  color: #f5f7ea;
  margin: 0 0.5rem;
  text-decoration: underline; /* Links unterstrichen */
  text-transform: uppercase; /* IMPRESSUM, DATENSCHUTZ */
  font-weight: 700;
}

/* Erste Zeile im Footer fett */
.site-footer p:first-of-type {
  font-weight: 700;
}

/* Page hero for inner pages */
.page-hero {
  /* Vollbreites Header-Bild */
  background-image: url('/assets/background_bubbles.avif');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  height: 370px; /* gewünschte Höhe */
  padding: 0; /* Bild füllt den Bereich */
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.page-hero h1 {
  font-size: 56px;
  font-weight: 400;
  color: #182f05; /* gewünschte Headline-Farbe */
}

/* Falls ein Bild-Tag für Hero/Banner verwendet wird: darf über die Eigenbreite skalieren */
.hero img,
.page-hero img {
  width: 100%;
  height: auto;
  max-width: none;
  display: block;
}

/* Generic content styling */
.content {
  padding: 2rem 5%;
  max-width: 800px;
  margin: 0 auto;
}

/* Subpage Content-Box: direkt nach dem Header-Bild */
.page-hero + .content {
  position: relative;
  z-index: 1;
  display: flow-root; /* verhindert Margin-Collapse der Kind-Elemente */
  /* Überlappung: obere Kante 140px unterhalb der Header-Oberkante → 370 - 140 = 230 */
  margin-top: -230px;
  background: #f5f7ea; /* abgetrennter Bereich */
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  /* Volle Breite mit Innenabstand laut Vorgabe */
  max-width: 960px; /* Gesamte Boxbreite wie Startseite */
  margin-left: auto;
  margin-right: auto;
  padding-left: 140px;
  padding-right: 140px;
  padding-top: calc(2.5rem + 8px);
  padding-bottom: 2.5rem;
}

/* Breitester Viewport: H1 im Subpage-Content auf 36px (nur Folgeseiten) */
@media (min-width: 1201px) {
  .page-hero + .content h1 {
    font-size: 40px;
  }
}

/* Wenn direkt ein Modul (.stripe-section) folgt, unteren Innenabstand entfernen */
.page-hero + .content:has(+ .stripe-section) {
  padding-bottom: 0;
}

/* Verhindert Margin-Collapse der letzten Kindmarge im Content-Bereich */
.page-hero + .content:has(+ .stripe-section) > :last-child {
  margin-bottom: var(--flow-gap-first, var(--flow-gap)); /* etwas kleiner als Stripe-Default */
}

/* Sicherheit: Modul direkt nach Content ohne oberen Außenabstand */
.page-hero + .content + .stripe-section {
  margin-top: 0;
}

/* Typografie im Subpage-Content */
.page-hero + .content p,
.page-hero + .content li {
  font-size: 18px;
  color: #4b5e34; /* vereinheitlichte Fließtextfarbe */
  line-height: 1.9;
}

/* Standard-Fließtextabstände im Content definieren */
.page-hero + .content p { margin: 0 0 1rem; }

.page-hero + .content h1,
.page-hero + .content h2,
.page-hero + .content h3 {
  color: #182f05;
}

/* Links im inhaltlichen Bereich: Farbe & Fett, ohne Navi/Footer/Contactbox zu beeinflussen */
.page-hero + .content a {
  color: #182f05;
  font-weight: 500;
}
.flowtext-box .stripe-inner a {
  color: #182f05;
  font-weight: 500;
}

/* Feinausrichtung: Überschriften 6px nach links */
.page-hero + .content h1,
.page-hero + .content h2,
.page-hero + .content h3 {
  margin-left: -4px;
}

/* Ausnahme: Coaching-Seite ohne Links-Offset */
.page-hero + .content.coaching-page h1,
.page-hero + .content.coaching-page h2,
.page-hero + .content.coaching-page h3 {
  margin-left: -1px;
}

/* Korrektur: h2 exakt links bündig mit Fließtext und geringerer Abstand darunter */
.page-hero + .content h2 { margin-left: 0; margin-bottom: 0.2em; }
.page-hero + .content.coaching-page h2 { margin-left: 0; margin-bottom: 0.2em; }

/* Korrektur: h3 typografisch an Layout anpassen (Größe, Gewicht, Bund) */
.page-hero + .content h3 {
  margin-left: 0;         /* bündig wie Fließtext */
  font-weight: 400;       /* keine fette Unterüberschrift */
  font-size: 24px;        /* Hierarchiestufe unter h2 (36px) */
  margin-bottom: 0.2em;   /* ~50% des Default-Abstands */
}

/* Überschrift im Contentbereich: Gewicht 400 und geringerer Abstand zum Fließtext */
.page-hero + .content h1 {
  font-weight: 400;
  margin-bottom: 16px; /* ~20px weniger als Browser-Default */
  position: relative; /* Icon absolut innerhalb der H1 platzieren */
}

/* Speziell: Wenn direkt ein h2 folgt, reduzieren wir die wirksame Lücke */
.page-hero + .content h1:has(+ h2) {
  margin-bottom: 10px; /* Basis der kollabierenden Marge */
}

/* Icons neben Überschriften im Padding-Bereich (Größe wie Startseite) */
.page-hero + .content h1 .title-icon {
  position: absolute;
  width: 100px;
  height: 100px;
  left: -110px; /* im linken Padding-Bereich platzieren, ohne Text zu verschieben */
  top: -5px; /* optische Vertikal-Justierung zur H1 */
  margin: 0;
  transform: none;
  pointer-events: none;
}

/* Coaching-Seite: eigener Left-Offset für das Titel-Icon (bei Bedarf hier feinjustieren) */
.page-hero + .content.coaching-page h1 .title-icon {
  left: -105px;
}

/* 404-Seite: eigener Left-Offset für das Titel-Icon (bei Bedarf hier feinjustieren) */
.page-hero + .content.page-404 h1 .title-icon { left: -103px; }

/* Responsive Anpassungen für die Innenabstände der Subpage-Box */
@media (max-width: 1200px) {
  .page-hero + .content {
    padding-left: 100px;
    padding-right: 100px;
  }
  .page-hero + .content h1 {
    font-size: 40px;
  }
  .page-hero + .content h1 .title-icon {
    left: -70px;
    top: 10px;
    width: 60px;
    height: 60px;
  }
  /* Coaching-Seite: eigener Left-Offset (Breakpoint ≤1200px) */
  .page-hero + .content.coaching-page h1 > .title-icon {
    left: -70px;
  }
}

@media (max-width: 980px) {
  .page-hero + .content {
    padding-left: 60px;
    padding-right: 60px;
  }
  .page-hero + .content h1 .title-icon {
    display: none; /* Icons unterhalb 980px vollständig ausblenden */
  }
  /* Coaching-Seite: eigener Left-Offset (Breakpoint ≤980px) */
  .page-hero + .content.coaching-page h1 .title-icon {
    display: none;
  }
}

@media (max-width: 600px) {
  .page-hero {
    height: 260px; /* mobile etwas niedriger */
  }
  .page-hero + .content {
    margin-top: -190px; /* größere Überlappung: Abstand zur Navi ~halbiert */
    padding-left: 24px;
    padding-right: 24px;
    border-top-left-radius: 16px;
    border-top-right-radius: 16px;
  }
  .page-hero h1 {
    font-size: 40px;
  }
  /* Kontaktbox Headline auf kleinsten Screens verkleinern */
  .contact-box h2 {
    font-size: 24px;   /* vorher 34px */
    line-height: 1.15; /* kompakter für lange Worte */
    padding-left: 42px; /* reduzierter Abstand für kleineres Icon */
  }
  /* Icon in der Kontaktbox anpassen */
  .contact-box .corner-icon {
    width: 35px;     /* vorher 50px */
    height: 35px;    /* vorher 50px */
    top: 13px;       /* vertikal zentrieren */
    left: 20px;      /* leicht nach rechts rücken */
  }
  .contact-box .corner-icon::after {
    width: 24px;     /* vorher 30px */
    height: 24px;    /* vorher 30px */
  }
}

.content h2 {
  font-size: 32px;
  font-weight: 400;
  margin-top: 2rem;
}


.content ul {
  list-style: disc;
  padding-left: 1.5rem;
}

.content ul li {
  margin-bottom: 0.5rem;
}

/* Über mich – Profilbild mit weißem Rand und runden Ecken */
.content.about .profile-image {
  display: block;
  width: 100%;
  height: auto;
  max-width: 520px; /* mobil/tablet: großzügig, zentriert */
  border: 4px solid #fff;
  border-radius: 12px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.08);
  margin: 1rem auto 1.5rem; /* mobil: zentriert */
}

/* Float-Layout auf größeren Screens: Bild rechts neben dem Text */
@media (min-width: 980px) {
  .content.about .profile-image {
    float: right;
    width: 330px;
    height: 200px;
    object-fit: cover; /* falls das Seitenverhältnis abweicht */
    margin: 0 0 1.25rem 2rem; /* Abstand links zum Fließtext */
  }
  /* Clear Float am Container, damit Footer/Contactbox korrekt anschließen */
  .content.about::after {
    content: "";
    display: table;
    clear: both;
  }
}

.content img.profile-image {
  max-width: 300px;
  border-radius: 50%;
  margin: 2rem auto;
  display: block;
}


/* Responsive adjustments */
/* Tablet and below */
@media (max-width: 820px) {
  /* Header-Bar im Hamburger-Modus: gleiche Höhe wie Desktop */
  .site-header .container {
    height: 75px;
    justify-content: space-between;
    position: relative;
    padding-right: 0; /* Hintergrund darf bis zur 12px-Padding-Kante des Menüs gehen */
  }
  /* Home/Brand links fix links halten */
  .site-header .container > a:first-child,
  .site-header .container > .logo,
  .site-header .container > .site-title { order: 1; margin-right: auto; }

  /* Hamburger rechts und vertikal mittig in der Bar */
  .menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 75px;
    margin: 0 0 0 auto; /* nach rechts schieben */
    order: 2;           /* sicherstellen: nach dem Logo */
    min-width: 56px;    /* ausreichend große Touch-Fläche */
    padding: 0 16px;    /* mehr horizontaler Innenabstand, bleibt ausgerichtet zum Menü */
  }
  .site-header { position: sticky; z-index: 100; padding-right: 0; }
  .site-header .nav {
    display: none;
    position: absolute;
    top: 75px;            /* direkt unter der Bar */
    right: 0;             /* Hintergrund bündig am Rand */
    left: auto;
    padding: 0.75rem 16px 1rem; /* mehr left/right Padding, ausgerichtet zum Hamburger */
    background: var(--color-light);
    box-shadow: 0 6px 18px rgba(0,0,0,0.08);
    border-bottom-left-radius: 10px;
    align-items: flex-end;   /* Inhalt rechtsbündig */
    text-align: right;
    gap: 0.75rem;
    min-width: 220px;
    width: max-content;   /* so breit wie nötig */
  }
  .site-header.open .nav {
    display: flex;
    flex-direction: column;
    align-items: flex-end; /* Menü rechts platzieren */
  }
  .nav a {
    display: block;            /* volle Breite für saubere Kante rechts */
    width: 100%;
    padding: 0.6rem 0 0.6rem 0; /* Abstand auf Container verlegt, rechts bündig */
    min-height: 44px;          /* WCAG-Empfehlung für Touch-Ziele */
    font-size: 18px;           /* besser lesbar mobil */
    line-height: 1.35;
  }
  /* Aktiver Link: Unterstreichung mit Background, damit sie mit der rechten Einrückung mitwandert */
  .nav a.active {
    border-bottom-color: transparent; /* Border deaktivieren, sonst randbündig */
    background-image: linear-gradient(var(--color-accent), var(--color-accent));
    background-repeat: no-repeat;
    background-position: left bottom;  /* unter dem Text starten */
    background-size: 100% 2px;         /* volle Breite des Content-Bereichs */
    background-origin: content-box;    /* Position relativ zum Content (nach Padding) */
    background-clip: content-box;      /* zusätzlich clippen auf Content-Box */
  }
  .nav a + a {
    border-left: none;
    padding-left: 0;
    margin-left: 0;
  }
  .hero {
    padding: 4rem 0;
  }
  .hero h1 {
    font-size: 36px;
  }
  .services .cards {
    gap: 1.25rem;
  }
}

/* Zwei-Spalten-Layout ab 850px bis 601px */
@media (max-width: 850px) and (min-width: 601px) {
  .services .cards {
    /* mehr vertikaler Abstand zwischen den Reihen, horizontales Gap bleibt */
    row-gap: 3rem;
  }
  .services .card {
    /* zwei Spalten: verfügbare Breite minus ein Gap */
    flex: 1 1 calc((100% - 1.25rem) / 2);
    max-width: 305px; /* nicht größer als aktuell */
    min-width: 0;     /* darf kleiner werden als Basis, bis max-width greift */
  }
}

/* Mobile */
@media (max-width: 600px) {
  body {
    font-size: 16px;
  }
  h1 {
    font-size: 40px;
  }
  h2 {
    font-size: 30px;
  }
  h3 {
    font-size: 24px;
  }
  .container {
    width: 92%;
  }
  .hero h1 {
    font-size: 28px;
  }
  /* Abstand zwischen Hero und "Leistungen" auf Mobil etwas verringern */
  .services {
    padding-top: 32px; /* vorher 50px */
  }
  /* ID-spezifisch auch mobil absichern */
  #leistungen { scroll-margin-top: 60px; }
  /* Startseiten-Welcome-Teaser mobil: konsistente Breite wie Services/Contact */
  .hero-content {
    width: auto;
    max-width: none;       /* keine Breitenbegrenzung */
    margin: 0;             /* kein Außenabstand */
    border-radius: 0;      /* runde Ecken entfernen */
    padding: 28px 24px 44px; /* 24px Seitenabstand wie Services */
  }
  .services .cards {
    flex-direction: column;
    align-items: center;
    gap: 3rem; /* mehr vertikaler Abstand wie im nächsthöheren Breakpoint */
  }
  /* Services-Bereich mobil: gleiche Breite wie Welcome-Teaser (24px Seitenabstand) */
  .services,
  .services .stripe-inner,
  .stripe-section.services,
  .stripe-section.services .stripe-inner {
    --section-pad-x: 24px; /* steuert padding-left/right der stripe-inner */
  }
  /* Contact-Box-Stripe: gleiche Breite wie Services/Hero */
  .stripe-section.contact-box .stripe-inner {
    --section-pad-x: 24px;
  }
  /* Interne Polsterung der Kontaktkarte (Element: .contact-card) auf mobile: wie News-Item */
  .contact-box .contact-card {
    padding: 16px 20px;
  }
  .card {
    width: 100%;
    max-width: none; /* volle Breite statt 305px Limit */
    min-width: 0;    /* schrumpfen bis zur Containerbreite zulassen */
  }
  .page-hero h1 {
    font-size: 32px;
  }
}