/* ==========================================================================
   Globale Styles fuer strassburg-therapie.de (Pilot: Verbundenes Atmen)

   Strategie: Mobile-First-Reset + Desktop-Layout ab >=869px.

   - Desktop (>=869px): 758px-Container, hg-home.jpg als Hintergrund, klassisches
     Lepton-Layout (Top-Nav, Main-Nav, 3-Spalten-Grid).
   - Mobile/Tablet (<869px): D2-Design — blau-grauer Gradient, Topbar mit Burger,
     Hero-Karte mit Aquarell + Claim, Pill-Button + ausklappbares Menue,
     Glass-Cards (rgba(255,255,255,0.36) + backdrop-blur).
   ========================================================================== */

/* ==========================================================================
   Webfonts (lokal gehostet — kein Google Fonts CDN, DSGVO-konform)
   Lato 400 / 700 + Source Sans 3 (Variable Font 400-700)
   Latin und Latin-Extended Subsets fuer deutsche Diakritik.
   ========================================================================== */
@font-face {
  font-family: 'Lato';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/lato-400-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Lato';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/lato-400-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Lato';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/lato-700-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Lato';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/lato-700-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/source-sans-3-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Source Sans 3';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/source-sans-3-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ==========================================================================
   Reset / Basis
   ========================================================================== */

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Lato', Arial, Helvetica, sans-serif;
  font-size: 14px;
  color: #333333;
}

a {
  color: #132477;
  text-decoration: none;
}

/* ==========================================================================
   Mobile-First (D2-Design, <869px)
   ========================================================================== */

body {
  /* Aeusserer Hintergrund: echtes Bild bg_aussen.png (cover, fixed). */
  background-color: #bdc2c1;
  background-image: url(../images/bg_aussen.png);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center top;
  background-attachment: fixed;
  font-family: 'Source Sans 3', 'Lato', Arial, Helvetica, sans-serif;
  color: #3a4252;
}

/* Desktop-Elemente: standardmaessig versteckt (werden ueber Media-Query gezeigt) */
.nav-top,
.nav-main {
  display: none;
}

/* Gap-Mask (Mobile): liegt fix zwischen Topbar-Unterkante und Bereich-Header-Unterkante.
   Deckt mit demselben bg_aussen.png (fixed-attachment) den Bereich ab, in dem sonst
   beim Scrollen Text-Bleed-through und Wrapper-Raender sichtbar waeren.
   z-index 5 — unter Topbar (50) und Bereich-Header (10), aber ueber Wrapper-Inhalt. */
.gap-mask {
  position: fixed;
  top: 77px;
  left: 0;
  right: 0;
  height: 21px;
  z-index: 5;
  pointer-events: none;
  background-color: #bdc2c1;
  background-image: url(../images/bg_aussen.png);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center top;
  background-attachment: fixed;
}

/* Topbar (Mobile) — sticky am oberen Rand.
   Nutzt dasselbe bg_aussen.png mit identischen background-* Eigenschaften wie der Body.
   Da background-attachment: fixed ist, deckt sich das Bild der Topbar nahtlos mit
   dem Bild des Body — kein sichtbarer "Streifen" oder Trennlinie. */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px max(14px, calc((100% - 720px) / 2));
  background-color: #bdc2c1;
  background-image: url(../images/bg_aussen.png);
  background-size: cover;
  background-repeat: no-repeat;
  background-position: center top;
  background-attachment: fixed;
  /* Schatten ist dynamisch — wird in app.js per Scroll-Position gesetzt.
     Fade-in beim Scrollen, fade-out wenn Bereich-Header sticky wird. */
  box-shadow: 0 6px 14px -6px rgba(15, 25, 45, 0);
  transition: box-shadow 0.05s linear;
}

.topbar-logo {
  width: 175px;
  height: auto;
}

.burger {
  width: 44px;
  height: 44px;
  background: rgba(255, 255, 255, 0.36);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 12px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 0;
}
.burger span {
  display: block;
  width: 20px;
  height: 2px;
  background: #1e3a6f;
  border-radius: 2px;
}
.burger:focus-visible {
  outline: 2px solid #1e3a6f;
  outline-offset: 2px;
}

/* Hero-Karte (Mobile): Aquarell + Claim */
.hero-card {
  position: relative;
  z-index: 6;            /* ueber der Gap-Mask (z=5), damit sie bei Scroll=0 nicht ueberdeckt wird */
  width: calc(100% - 28px);
  max-width: 720px;
  margin: 1px auto 0;    /* 1px Top-Margin: Topbar (position:fixed) verdeckt sonst genau 1px vom oberen Border */
  padding: 18px;
  background: rgba(255, 255, 255, 0.36);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-radius: 18px;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  text-align: center;
}

.hero-watercolor {
  width: 72%;
  max-width: 320px;
  height: auto;
  display: block;
  margin: 0 auto;
}

.hero-claim {
  margin: 12px 0 0 0;
  color: #1e3a6f;
  font-size: 13px;
  letter-spacing: 1.2px;
  font-weight: 500;
}
/* Drei farbige Kreis-Trenner: nach Erkennen (orange), Thematisieren (blau), Auflösen (gruen)
   Asymmetrische Margins: Kreis nah am vorhergehenden Wort, mehr Abstand zum naechsten. */
.hero-claim .dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  vertical-align: middle;
  margin: 0 14px 0 2px;
  position: relative;
  top: -1px;
}
.hero-claim .dot-orange { background: #d49a3a; }
.hero-claim .dot-blue   { background: #3a9ad4; }
.hero-claim .dot-green  { background: #3aa44c; }

/* Container (Mobile): wir behalten den Container fuer Pill + Inhalt;
   Desktop-Layout wird erst in der Media-Query unten aktiviert. */
.container {
  width: calc(100% - 28px);
  max-width: 720px;
  margin: 14px auto 24px;
  padding: 0;
}

/* Content-Wrapper (Mobile, D3-a): nur Layout-Container.
   Die sichtbare Card-Border sitzt auf Sticky-Gruppe + Main-Content. So bleibt
   die Border am sticky Aufklapp-Menue, statt mit dem Gesamtwrapper zu scrollen. */
.content-wrapper {
  display: block;
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  overflow: visible;
}

.sidebar {
  margin: 0;
  position: relative;
}

/* Bereich-Header (Mobile, D3-a): weisser Header oben in der Karte.
   STICKY direkt unter der Topbar — bleibt beim Scrollen sichtbar.
   Border-radius matched die Karte, damit der Header bei Sticky-Position
   auch ohne Wrapper-overflow noch rund aussieht. */
/* Sticky-Gruppe (Mobile): umfasst Bereich-Header + Sidebar(mit Pill-Menue).
   Pinnt als EIN Element am oberen Rand — das absolute Pill-Menue erscheint
   visuell darunter und bleibt mit dem Header verbunden. Body-Text scrollt
   darunter weg (z-index 10 ueber Main-Content z=0).

   Eigener Overlay-BG + Border (passend zur Main-Content-Border), damit der
   Card-Look beim Sticky-Pinning *mit* dem Bereich-Header oben bleibt. */
.bereich-sticky-group {
  position: sticky;
  top: 78px;
  z-index: 10;
  background: rgba(255, 255, 255, 0.36);
  border: 1px solid rgba(255, 255, 255, 0.55);
  border-bottom: 0;
  border-radius: 18px 18px 0 0;
}

/* Bereich-Header (Mobile, D3-a): liegt im Sticky-Wrapper, daher nicht mehr
   selbst sticky. KEINE Top/Left/Right-Border (Sticky-Wrapper hat die schon),
   sonst Doppellinie. Border-Radius bleibt, damit die opaken cremefarbenen
   Ecken zur Rundung des Wrappers passen. */
.bereich-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px 14px 18px;
  background: #f8f7f3;        /* deckend */
  border-bottom: 1px solid rgba(30, 58, 111, 0.10);
  border-top-left-radius: 18px;
  border-top-right-radius: 18px;
}

@media (max-width: 868px) {
  .bereich-header {
    border-bottom: 0;
  }
}

.bereich-header-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.bereich-label {
  font-size: 11px;
  font-weight: 600;
  color: rgba(30, 58, 111, 0.6);
  text-transform: uppercase;
  letter-spacing: 1.2px;   /* exakt wie Original-Design */
  line-height: normal;
  margin: 0 0 2px 0;       /* Original: 2px Gap zwischen Label-Boden und Title-Top */
}
.bereich-title {
  font-size: 17px;
  font-weight: 700;
  color: #1f2533;
  line-height: normal;
  margin: 0;
}

/* Variante fuer Seiten OHNE Aufklapp-Submenue:
   Body bekommt Klasse "no-bereich-submenu" — dann werden Label, Counter, Chevron
   ausgeblendet, der Titel rueckt nach oben (vertikal zentriert in der Header-Hoehe). */
body.no-bereich-submenu .bereich-label,
body.no-bereich-submenu .bereich-header-controls {
  display: none;
}
body.no-bereich-submenu .bereich-header {
  align-items: center;
}
body.no-bereich-submenu .pill-menu {
  display: none;
}

/* Counter-Pill + Chevron-Button (rechts in Bereich-Header) */
.bereich-header-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}
.counter-pill {
  display: inline-flex;
  align-items: center;
  background: rgba(30, 58, 111, 0.1);
  border-radius: 999px;
  padding: 4px 10px;       /* exakt wie Original-Design */
  font-size: 13px;
  font-weight: 600;
  color: #1e3a6f;
  line-height: 1.4;        /* gibt 26.5px Pill-Hoehe wie Original */
}

.chevron-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  background: rgba(30, 58, 111, 0.08);
  border: 1px solid rgba(30, 58, 111, 0.18);
  border-radius: 10px;
  color: #1f2533;
  cursor: pointer;
}
.chevron-btn svg {
  transition: transform 0.2s ease;
}
.chevron-btn[aria-expanded="true"] svg {
  transform: rotate(180deg);
}
.chevron-btn:focus-visible {
  outline: 2px solid #1e3a6f;
  outline-offset: 2px;
}

/* Pill-Menue (Mobile, D3-a): unter dem Bereich-Header, initial geschlossen.
   ACHTUNG: Diese Regel wird auch auf Desktop angewandt (Desktop-Sidebar nutzt
   .pill-menu). Daher hier nur Eigenschaften, die auf BEIDEN gelten — alle
   Mobile-spezifischen Borders, Radii usw. gehoeren in .pill-menu.is-open
   (die is-open-Klasse wird per JS nur auf Mobile getoggelt). */
.pill-menu {
  list-style: none;
  margin: 0;
  padding: 6px;
  background: #ffffff;
  border-radius: 0;
  box-shadow: 0 6px 22px rgba(20, 40, 70, 0.08);
  display: none;
  border-bottom: 1px solid rgba(30, 58, 111, 0.08);
}
/* Mobile-Aufklapp-State: bildet zusammen mit Bereich-Header die geschlossene
   Box. Border + rounded bottom corners gleich wie Bereich-Header (oben).
   position: absolute — wichtig: Pill-Menue traegt nicht zum Layout-Flow bei.
   Sonst wuerde der Browser beim Aufklappen den Scroll-Anchor anpassen
   (automatischer Scroll-Sprung, weil Main-Content nach unten "geschoben" wird).
   Mit absolute haengt das Menue visuell unter dem Bereich-Header (top: 100%
   des Sidebars, welches direkt unter dem Bereich-Header sitzt), erbt aber
   den z-index des Sticky-Wrappers — pinnt damit mit. */
.pill-menu.is-open {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 100%;
  left: -1px;
  right: -1px;
  max-height: calc(100vh - 160px);
  overflow-y: auto;
  border-left: 1px solid rgba(255, 255, 255, 0.9);
  border-right: 1px solid rgba(255, 255, 255, 0.9);
  border-bottom: 1px solid rgba(255, 255, 255, 0.9);
  border-bottom-left-radius: 18px;
  border-bottom-right-radius: 18px;
}

.pill-menu li {
  margin: 0;
  padding: 0;
}
.pill-menu li a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 12px;
  color: #3a4252;
  font-size: 15px;
  border-radius: 8px;
  text-decoration: none;
}
.pill-menu li a:hover {
  background: rgba(30, 58, 111, 0.04);
}
.pill-menu li.current a {
  background: rgba(30, 58, 111, 0.08);
  color: #1e3a6f;
  font-weight: 700;
}
.pill-menu li.current a::after {
  content: "✓";
  color: #1e3a6f;
  font-weight: 700;
  margin-left: 8px;
}
/* Aktive Eintraege bleiben in DOM-Reihenfolge (keine Order-Manipulation):
   Holotropes Atmen erscheint dadurch korrekt an Position 6, nicht oben. */

/* (Entfernt: "+ N weitere"-Toggle — alle Eintraege werden direkt angezeigt) */

/* Haupt-Inhalt (Mobile) — eigene Innen-Padding, da .content-wrapper kein Padding mehr hat */
.main-content {
  position: relative;
  z-index: 0;
  background: rgba(255, 255, 255, 0.36);
  border-left: 1px solid rgba(255, 255, 255, 0.55);
  border-right: 1px solid rgba(255, 255, 255, 0.55);
  border-bottom: 1px solid rgba(255, 255, 255, 0.55);
  border-bottom-left-radius: 18px;
  border-bottom-right-radius: 18px;
  font-size: 15.5px;
  line-height: 1.6;
  color: #3a4252;
  padding: 18px 18px 24px 18px;
}
.main-content p {
  margin: 14px 0;
}
.main-content p:first-child {
  margin-top: 0;
}
.main-content p:last-child {
  margin-bottom: 0;
}
.main-content strong {
  color: #1f2533;
  font-weight: 700;
}
.main-content a {
  color: #2c4a85;
  text-decoration: underline;
  text-decoration-color: rgba(44, 74, 133, 0.4);
}

/* ==========================================================================
   Off-Canvas-Menue (Mobile) — Drawer-Stil nach Design-Referenz
   warmes Off-White, klare Zeilen, aktiver Eintrag mit 3px Navy-Border links.
   ========================================================================== */
.offcanvas {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(86vw, 360px);
  background: #f4f3ee;                    /* warm off-white wie Referenz */
  z-index: 1001;
  overflow-y: auto;
  transform: translateX(100%);
  transition: transform 0.28s cubic-bezier(.2,.8,.2,1);
  display: flex;
  flex-direction: column;
  box-shadow: -8px 0 30px rgba(0, 0, 0, 0.18);
}
.offcanvas.is-open {
  transform: translateX(0);
}

.offcanvas-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(15, 25, 45, 0.5);
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.offcanvas-backdrop.is-open {
  opacity: 1;
  pointer-events: auto;
}

/* Header: "MENU"-Label links, Close-Button rechts */
.offcanvas-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid #d8dde6;
}
.offcanvas-header-label {
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #6b7588;
  font-weight: 600;
}
.offcanvas-close {
  position: static;       /* nicht mehr absolute */
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid #d8dde6;
  background: transparent;
  color: #3b4760;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  line-height: 1;
  padding: 0;
}
.offcanvas-close:hover {
  background: rgba(30, 58, 111, 0.04);
}

/* Kontakt-CTA-Gruppe — Haupt-Button + Telefon-Icon-Button nebeneinander */
.offcanvas-cta-group {
  display: flex;
  align-items: stretch;
  gap: 8px;
  margin: 14px 16px 6px;
}

/* Haupt-Kontakt-Button (links, nimmt verfuegbaren Platz) */
.offcanvas-cta {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 14px;
  background: #1e3a6f;
  color: #ffffff;
  text-align: center;
  font-weight: 600;
  font-size: 15px;
  border-radius: 8px;
  text-decoration: none;
  min-height: 44px;
  border: 1px solid #1e3a6f;
}
.offcanvas-cta svg {
  flex-shrink: 0;
}
.offcanvas-cta:hover {
  background: #16305b;
}

/* Icon-Buttons (Mail / Telefon) — quadratisch, gleiche Hoehe wie Haupt-Button */
.offcanvas-cta-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  min-height: 44px;
  background: #1e3a6f;
  color: #ffffff;
  border-radius: 8px;
  border: 1px solid #1e3a6f;
  text-decoration: none;
  flex-shrink: 0;
}
.offcanvas-cta-icon:hover {
  background: #16305b;
}
.offcanvas-cta-icon svg {
  display: block;
}

/* Hauptmenue-Liste */
.offcanvas-nav {
  flex: 1;
  padding: 6px 0;
}
.offcanvas-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.offcanvas-list > li {
  /* Trennlinie pro Reihe (auch fuer Buttons) */
}
.offcanvas-list > li > a,
.offcanvas-list .submenu-trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 14px 22px;
  color: #18253b;
  font-size: 17px;
  font-weight: 400;
  text-decoration: none;
  background: transparent;
  border: 0;
  border-bottom: 1px solid #e8ecf2;
  font-family: inherit;
  cursor: pointer;
  text-align: left;
}
.offcanvas-list > li:last-child > a,
.offcanvas-list > li:last-child > .submenu-trigger {
  /* letzte Zeile keine Border-Bottom */
}
.offcanvas-list > li > a:hover,
.offcanvas-list .submenu-trigger:hover {
  background: rgba(30, 58, 111, 0.025);
}

/* Aktiver Eintrag (Top-Level): Navy-Text + heller Navy-BG + 3px-Border links */
.offcanvas-list > li > a.is-active,
.offcanvas-list .has-submenu.is-active-parent > .submenu-trigger {
  color: #1e3a6f;
  font-weight: 600;
  background: rgba(30, 58, 111, 0.05);
  border-left: 3px solid #1e3a6f;
  padding-left: 19px;
}

/* Submenu-Trigger: Chevron rechts */
.submenu-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #1e3a6f;
  transition: transform 0.25s ease;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.submenu-trigger[aria-expanded="true"] .submenu-chevron {
  transform: rotate(180deg);
}

/* Submenu-Liste — sanfter, eingerueckt, geringerer Kontrast */
.submenu {
  list-style: none;
  margin: 0;
  padding: 0;
  background: rgba(0, 0, 0, 0.02);
  display: none;
  border-bottom: 1px solid #e8ecf2;
}
.submenu.is-open {
  display: block;
}
.submenu li a {
  display: block;
  padding: 12px 22px 12px 38px;       /* mehr Einrueckung als Indent */
  color: #3b4760;
  font-size: 15px;
  text-decoration: none;
  border-top: 1px solid #e8ecf2;
}
.submenu li:first-child a {
  border-top: 0;
}
.submenu li a:hover {
  background: rgba(30, 58, 111, 0.03);
  color: #1e3a6f;
}
/* Aktiver Untermenupunkt:
   anders markiert als der aktive Uebermenupunkt — Haekchen rechts statt Border links.
   So unterscheidet sich visuell die Ebene (Border links = Parent, Haekchen rechts = Sub). */
.submenu li.current a {
  color: #1e3a6f;
  font-weight: 600;
  background: rgba(30, 58, 111, 0.07);
  display: flex;
  align-items: center;
  justify-content: space-between;
  /* padding-left bleibt bei 38px (Submenu-Indent), kein Left-Border */
}
.submenu li.current a::after {
  content: "✓";
  margin-left: 14px;
  color: #1e3a6f;
  font-weight: 700;
  font-size: 15px;
  line-height: 1;
}

/* Footer: Impressum + Datenschutz */
.offcanvas-footer {
  padding: 14px 22px 18px;
  border-top: 1px solid #d8dde6;
  color: #6b7588;
  font-size: 13px;
  text-align: left;
}
.offcanvas-footer a {
  color: #6b7588;
  text-decoration: none;
}
.offcanvas-footer a:hover {
  color: #1e3a6f;
  text-decoration: underline;
}
.offcanvas-footer-sep {
  color: rgba(30, 58, 111, 0.25);
  margin: 0 10px;
}

/* ==========================================================================
   Desktop-Layout (>= 869px)
   Hier ueberschreiben wir Mobile-Styles und stellen den Lepton-Look wieder her.
   ========================================================================== */

@media (min-width: 869px) {

  body {
    background: #B1BABB url(../images/hg-home.jpg) no-repeat center top;
    background-attachment: scroll;
    font-family: 'Lato', Arial, Helvetica, sans-serif;
    font-size: 14px;
    color: #333333;
  }

  /* Mobile-Only-Elemente verstecken */
  .topbar,
  .gap-mask,
  .hero-card,
  .bereich-header,
  .offcanvas,
  .offcanvas-backdrop {
    display: none !important;
  }

  /* Sticky-Wrapper aufloesen, damit Sidebar wieder direktes Grid-Kind ist */
  .bereich-sticky-group {
    display: contents;
  }

  /* Desktop-Container: 758px Center */
  .container {
    width: 758px;
    max-width: 758px;
    margin: 0 auto;
    padding-top: 139px;
    padding-left: 0;
    padding-right: 0;
    background: transparent;
    border: 0;
    border-radius: 0;
    backdrop-filter: none;
  }

  /* Desktop-Navs sichtbar */
  .nav-top {
    display: block;
    color: #FFFFFF;
    font-size: 13px;
    font-weight: normal;
    letter-spacing: 1px;
    margin-bottom: 165px;
  }
  .nav-top a { color: #FFFFFF; text-decoration: none; }
  .nav-top a:hover { color: #132477; }
  .nav-top .current,
  .nav-top .current a { color: #132477; }

  .nav-main {
    display: block;
    color: #FFFFFF;
    font-size: 13px;
    font-weight: normal;
    letter-spacing: 1px;
    margin-bottom: 60px;
  }
  .nav-main a { color: #FFFFFF; text-decoration: none; }
  .nav-main a:hover { color: #132477; }
  .nav-main .current a,
  .nav-main .parent a { color: #132477; }

  /* Inhalts-Bereich: Grid wie im Original (Sidebar 141 + Gap 32 + Content 585 = 758) */
  .content-wrapper {
    display: grid;
    grid-template-columns: 141px 32px 585px;
    align-items: start;
    background: transparent;
    border: 0;
    border-radius: 0;
    padding: 0;
    backdrop-filter: none;
  }

  /* Sidebar (Desktop) */
  .sidebar {
    grid-column: 1;
    color: #FFFFFF;
    font-size: 14px;
    letter-spacing: normal;
    margin-bottom: 0;
    background: transparent;
    border: 0;
    padding: 0;
  }

  /* Sidebar-Liste (Desktop) — ersetzt das Mobile-Pill-Menue */
  .pill-menu {
    display: block !important;
    list-style: none;
    padding: 0;
    margin: 14px 0;
    padding-top: 19px;
    background: transparent;
    border-radius: 0;
    box-shadow: none;
    border-bottom: 0;  /* Mobile-Border-Bottom auf Desktop ausblenden */
  }
  .pill-menu li {
    padding-bottom: 20px;
    order: 0;  /* DOM-Reihenfolge auf Desktop */
  }
  .pill-menu li.current { order: 0; }
  .pill-menu li a {
    display: block;
    padding: 0;
    color: #FFFFFF;
    font-size: 14px;
    background: transparent;
    border-radius: 0;
    text-align: left;
    justify-content: flex-start;
  }
  .pill-menu li a::after {
    content: none !important;  /* Kein Häkchen im Desktop */
  }
  .pill-menu li a:hover {
    color: #132477;
    background: transparent;
  }
  .pill-menu li.current a {
    color: #132477;
    background: transparent;
    font-weight: normal;
  }

  /* Hauptinhalt rechts (Desktop) */
  .main-content {
    grid-column: 3;
    position: static;
    z-index: auto;
    background: transparent;
    border: 0;
    border-radius: 0;
    color: #333333;
    line-height: 130%;
    font-size: 14px;
    padding: 0;  /* Mobile-Padding zuruecksetzen */
  }
  .main-content h1 {
    color: #132477;
    line-height: 120%;
    font-size: 12px;
  }
  .main-content a {
    color: #132477;
    text-decoration: none;
  }
  .main-content p {
    margin: 14px 0;
  }
  .main-content p:first-child {
    margin-top: 14px;  /* explizit, da Mobile :first-child auf 0 setzt */
  }
  .main-content strong {
    font-weight: bold;
    color: #333333;
  }
}

/* ============================================================
   Phase E: Body-Klassen-gesteuerte Hintergrundbilder (Desktop)
   --------------------------------------------------------------
   Additiv. Greift nur, wenn <body> die jeweilige Klasse traegt.
   Default (body ohne dieser Klassen) bleibt hg-home.jpg unveraendert.
   Mobile-Hintergrund (bg_aussen.png + watercolor.png) bleibt gleich.
   ============================================================ */
@media (min-width: 869px) {
  body.bg-themen        { background-image: url(../images/hg-themen.jpg); }
  body.bg-ueberblick    { background-image: url(../images/hg-ueberblick.jpg); }
  body.bg-therapieformen { background-image: url(../images/hg-therapieformen.jpg); }
  body.bg-kontakt       { background-image: url(../images/hg-kontakt.jpg); }

  /* Lange Seiten (Weiterfuehrende Therapie-Infos, Datenschutz): hg-home.jpg
     ist nur 1984px hoch — bei langem Content sieht man unten den Fallback-
     Color. hg-oversize.jpg (das untere Zehntel) wird nahtlos ab y=1984
     angehaengt und vertikal wiederholt, um beliebig langen Content abzudecken. */
  body.bg-extend {
    background-color: #B1BABB;
    background-image:
      url(../images/hg-home.jpg),
      url(../media/hg-oversize.jpg);
    background-position:
      center top,
      center 1984px;
    background-repeat:
      no-repeat,
      repeat-y;
    background-attachment: scroll;
  }
}

/* ============================================================
   Home-spezifisches Layout (additiv, greift nur bei body.is-home)
   --------------------------------------------------------------
   Home hat keine Sidebar-Navigation (es ist Top-Level ohne Submenu),
   nutzt aber eine interne <table> mit Text+Portrait nebeneinander.
   Desktop: Container-Breite voll nutzen (kein Sidebar-Spalten-Versatz).
   Mobile: Layout-Tabelle aufbrechen, alles untereinander stapeln.
   ============================================================ */

/* === Desktop (>=869px): Top-Level-Seiten ohne Submenu nutzen volle Container-Breite ===
   Greift bei: is-home (Home) UND no-bereich-submenu (Ihre Themen, Supervision,
   Nachsorgegruppe, Kontakt, Impressum, Honorar, Gedanken).
   Detail-/Übersichts-Seiten mit Sidebar bleiben beim 141+32+585-Grid. */
@media (min-width: 869px) {
  body.is-home .content-wrapper,
  body.no-bereich-submenu .content-wrapper {
    grid-template-columns: 1fr;
  }
  body.is-home .sidebar,
  body.no-bereich-submenu .sidebar {
    display: none;
  }
  body.is-home .main-content,
  body.no-bereich-submenu .main-content {
    grid-column: 1;
  }
  /* Original-Lepton-Layout hat 145px Linksversatz für no-Submenu Pages
     (leere Sidebar-Spalte + Spacer rendern sich zusammen zu ~145px).
     Home (is-home) hat eigene 3-Spalten-Tabelle und braucht volle Breite. */
  body.no-bereich-submenu:not(.is-home) .main-content {
    padding-left: 145px;
  }
  /* Kontakt: 40px weiter links als andere no-Submenu Pages */
  body.bg-kontakt.no-bereich-submenu .main-content {
    padding-left: 105px;
  }
}

/* === Mobile (<760px): Layout-Tabelle aufbrechen, Bilder responsive === */
@media (max-width: 868.98px) {
  /* Layout-Tabelle in vertikalen Stack umbrechen */
  body.is-home .main-content table,
  body.is-home .main-content tbody,
  body.is-home .main-content tr {
    display: block;
    width: 100%;
  }
  body.is-home .main-content td {
    display: block;
    width: 100% !important;
    padding: 0;
  }
  /* Bilder responsive skalieren, max innerhalb der Overlay-Box */
  body.is-home .main-content img {
    max-width: 100%;
    height: auto;
    display: block;
  }
  /* Spacer-Zelle ausblenden */
  body.is-home .main-content td:empty {
    display: none;
  }
  /* Portrait + Buchcover zentrieren auf Mobile */
  body.is-home .main-content td:last-child img,
  body.is-home .main-content p > a > img {
    margin-left: auto;
    margin-right: auto;
  }
  /* Headline-Image (Wenn Ihr Leben ein Haus wäre) sauber zentrieren */
  body.is-home .main-content td:first-child > p:first-child img {
    margin-left: auto;
    margin-right: auto;
  }
}

/* ============================================================
   Layout-Hilfsklassen für Body-Content (Mobile + Desktop)
   --------------------------------------------------------------
   Werden vom Cleaner aus DB-inline-styles erzeugt.
   Nur in .main-content gescopet, damit kein Pilot-Layout-Risk.
   ============================================================ */
.main-content .float-right { float: right; margin: 0 0 12px 16px; max-width: 50%; height: auto; }
.main-content .float-left  { float: left;  margin: 0 16px 12px 0; max-width: 50%; height: auto; }
.main-content .text-center { text-align: center; }
.main-content .text-right  { text-align: right; }

/* Float-Container-Clear: nur dort wo Floats wirklich auftreten (Home + Kontakt + Therapie-Infos) */
body.is-home .main-content td::after { content: ""; display: table; clear: both; }

/* Mobile: floats deaktivieren — alles untereinander */
@media (max-width: 868.98px) {
  .main-content .float-right,
  .main-content .float-left {
    float: none;
    margin: 12px auto;
    max-width: 100%;
    display: block;
  }
}

/* ============================================================
   Home Mobile-Restructure (additiv, nur body.is-home)
   --------------------------------------------------------------
   Auf Mobile: Portrait wird nach dem 2. Text-Paragraph eingeblendet
   (mobile-only-portrait), das Original in TD2 (desktop-only) ist hidden.
   Leere Spacer-Paragraphen sind nur auf Desktop sichtbar (Original-Spacing).
   ============================================================ */
@media (min-width: 869px) {
  /* Desktop: Mobile-Portrait und Mobile-Wrapper aus */
  body.is-home .mobile-only-portrait,
  body.is-home .mobile-portrait-wrap { display: none; }
}
@media (max-width: 868.98px) {
  /* Mobile: Desktop-Portrait und alle Spacer aus */
  body.is-home .desktop-only { display: none; }
  body.is-home .spacer-only { display: none; }
  /* Auch TD2 (rechter Spacer + Portrait-TD) hidden, da Portrait jetzt inline kommt */
  body.is-home .main-content tr > td:nth-child(2),
  body.is-home .main-content tr > td:nth-child(3) { display: none; }
  /* Mobile-Portrait sauber zentriert in der Box */
  body.is-home .mobile-portrait-wrap {
    text-align: center;
    margin: 16px 0;
  }
  body.is-home .mobile-only-portrait {
    max-width: 100%;
    height: auto;
    display: inline-block;
  }
}

/* Home Headline-Image (Wenn Ihr Leben…) — Mobile/Tablet: 15px oben + 15px unten am Image
   (jeweils +10px vom letzten Wert), Folge-Text 30px margin-top (+10 mehr) */
@media (max-width: 868.98px) {
  body.is-home .headline-img-p {
    margin-top: 15px;
    margin-bottom: 15px;
  }
  /* Direktes Folge-<p> ohne Spacer dazwischen: top-Margin auf 30px */
  body.is-home .headline-img-p + p:not(.spacer-only) {
    margin-top: 30px;
  }
  /* Mit dazwischenliegendem (hidden) spacer-only: trotzdem nächstes Text-p anpassen */
  body.is-home .headline-img-p + .spacer-only + p {
    margin-top: 30px;
  }
}

/* Home Mobile/Tablet: Buchcover linksbündig (override des Mittig-Defaults) */
@media (max-width: 868.98px) {
  body.is-home .main-content img.float-right,
  body.is-home .main-content img.float-left {
    margin-left: 0;
    margin-right: auto;
  }
}

/* ============================================================
   Mobile/Tablet: Lepton-Spacer aus dem Body-Content ausblenden
   --------------------------------------------------------------
   Die <p> </p> Spacer waren im Original Desktop-Layout-Hilfen.
   Auf Mobile innerhalb der schmalen Overlay-Box wirken sie als
   überflüssiger Whitespace und werden unterdrückt.
   ============================================================ */
@media (max-width: 868.98px) {
  /* Utility: Elemente nur auf Mobile verstecken (Desktop sieht sie normal) */
  .hide-on-mobile { display: none; }
  .main-content .spacer-only { display: none; }
  /* Mobile: padding-bottom moderat (8 → 14px), damit der letzte Paragraph
     genügend Luft zum Overlay-Rand hat aber kein Riesen-Whitespace entsteht */
  .main-content { padding-bottom: 14px; }
  /* Mobile: Wenn der Body mit versteckten spacer-only(s) beginnt, soll der
     erste echte Inhalt kein margin-top haben (sonst doppelter Abstand
     durch padding-top + margin-top). Deckt 1-3 leading spacers ab. */
  .main-content > .spacer-only:first-child + p,
  .main-content > .spacer-only:first-child + h1,
  .main-content > .spacer-only:first-child + h2,
  .main-content > .spacer-only:first-child + h3,
  .main-content > .spacer-only:first-child + h4,
  .main-content > .spacer-only:first-child + .spacer-only + p,
  .main-content > .spacer-only:first-child + .spacer-only + h1,
  .main-content > .spacer-only:first-child + .spacer-only + h2,
  .main-content > .spacer-only:first-child + .spacer-only + h3,
  .main-content > .spacer-only:first-child + .spacer-only + h4,
  .main-content > .spacer-only:first-child + .spacer-only + .spacer-only + p,
  .main-content > .spacer-only:first-child + .spacer-only + .spacer-only + h1,
  .main-content > .spacer-only:first-child + .spacer-only + .spacer-only + h2,
  .main-content > .spacer-only:first-child + .spacer-only + .spacer-only + h3,
  .main-content > .spacer-only:first-child + .spacer-only + .spacer-only + h4 {
    margin-top: 0;
  }
  /* Mobile: alle Body-Content-Bilder skalieren, damit sie nicht ueber die
     Overlay-Box hinausragen (z.B. Tango_Erfahrung 400px, Nachsorgegruppe-Foto). */
  .main-content img {
    max-width: 100%;
    height: auto;
  }
  /* <br> am Ende der ersten Heading-Zeile (innerhalb <strong>) auf Mobile suppressen
     → sie waren im Lepton-Editor als Spacer eingefügt, sind auf Mobile aber zu viel. */
  body.no-bereich-submenu .main-content > p:first-child strong br,
  body.no-bereich-submenu .main-content > p:first-child span br {
    display: none;
  }
}

/* ============================================================
   Kontakt-Seite: Photos-Grid, Flyer-Block, Maps-Bild, Routenplaner
   ============================================================ */

/* Kontakt-Grid: 3 Praxis-Photos + Flyer-Block. Desktop 2 Spalten / 2 Zeilen,
   Mobile 1 Spalte (alles untereinander). */
.kontakt-grid {
  margin: 24px 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 869px) {
  .kontakt-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
    align-items: start;
  }
}
.kontakt-grid-photo img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 6px;
  box-shadow: 0 3px 10px rgba(20, 40, 70, 0.14);
  object-fit: cover;
  aspect-ratio: 4 / 3;
}
.kontakt-grid-flyer {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}
.kontakt-flyer-image {
  display: inline-block;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 3px 10px rgba(20, 40, 70, 0.18);
  transition: transform 0.2s ease;
  max-width: 100%;
}
.kontakt-flyer-image:hover {
  transform: translateY(-2px);
}
.kontakt-flyer-image img {
  display: block;
  width: 100%;
  max-width: 320px;
  height: auto;
}
.kontakt-flyer-caption {
  margin: 0;
  color: #3a4252;
  line-height: 1.5;
}

/* Maps-Vorschaubild — ganz unten auf der Seite */
.kontakt-map {
  margin: 30px 0 0 0;
  text-align: center;
}
@media (min-width: 869px) {
  .kontakt-map { margin-bottom: 50px; }
}
.kontakt-map a {
  display: inline-block;
  max-width: 100%;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(20, 40, 70, 0.18);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.kontakt-map a:hover {
  box-shadow: 0 6px 18px rgba(20, 40, 70, 0.28);
  transform: translateY(-1px);
}
.kontakt-map img {
  display: block;
  width: 100%;
  height: auto;
  max-width: 700px;
}

/* Routenplaner-Link: Pille mit Pfeil */
.map-routenplaner-link {
  margin: 8px 0 14px 0;
}
.map-routenplaner-link a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #132477;
  font-weight: 600;
  text-decoration: none;
  padding: 6px 12px 6px 0;
  transition: gap 0.2s ease;
}
.map-routenplaner-link a:hover {
  gap: 10px;
  text-decoration: underline;
}
.map-routenplaner-link svg {
  flex-shrink: 0;
}

/* ============================================================
   Body-Content Typografie (h2/h3/h4, address) — für Datenschutz
   und ähnliche längere Texte
   ============================================================ */
.main-content h2 {
  color: #3a4252;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.25;
  margin: 28px 0 14px;
}
.main-content h2:first-child { margin-top: 0; }

.main-content h3 {
  color: #3a4252;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.3;
  margin: 28px 0 10px;
  padding-top: 6px;
  border-top: 1px solid rgba(30, 58, 111, 0.12);
}
.main-content h3:first-of-type { border-top: 0; padding-top: 0; }

.main-content h4 {
  color: #3a4252;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
  margin: 18px 0 8px;
}

.main-content address {
  font-style: normal;
  margin: 8px 0 14px;
  padding: 10px 14px;
  background: rgba(30, 58, 111, 0.04);
  border-left: 3px solid rgba(30, 58, 111, 0.4);
  border-radius: 4px;
  line-height: 1.6;
}

.main-content ul { margin: 10px 0 14px 0; padding-left: 24px; }
.main-content ul li { margin-bottom: 6px; }

/* ============================================================
   Generische Mobile/Desktop-Image-Switches (auch außerhalb is-home)
   ============================================================ */
@media (min-width: 869px) {
  .main-content .mobile-image-wrap,
  .main-content .mobile-only-block-image { display: none; }
}
@media (max-width: 868.98px) {
  .main-content img.desktop-only { display: none; }
  .main-content .mobile-image-wrap {
    text-align: center;
    margin: 18px 0;
  }
  .main-content .mobile-only-block-image {
    max-width: 100%;
    height: auto;
    display: inline-block;
    border-radius: 4px;
  }
}

/* ==========================================================================
   Mobile-CTA-Sektion (alle Seiten) — selbe Optik wie offcanvas-cta-group:
   grosser "Kontakt aufnehmen" + quadratisches Telefon-Icon nebeneinander.
   ========================================================================== */
.mobile-cta-section {
  display: none;
}

@media (max-width: 868.98px) {
  .mobile-cta-section {
    display: flex;
    align-items: stretch;
    gap: 8px;
    margin-top: 24px;
    padding: 0 0 12px;
  }
  a.mobile-cta-main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 14px;
    background: #1e3a6f;
    color: #ffffff;
    text-align: center;
    font-weight: 600;
    font-size: 15px;
    border-radius: 8px;
    text-decoration: none;
    min-height: 44px;
    border: 1px solid #1e3a6f;
  }
  a.mobile-cta-main svg {
    flex-shrink: 0;
  }
  a.mobile-cta-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    min-height: 44px;
    background: #1e3a6f;
    color: #ffffff;
    border-radius: 8px;
    border: 1px solid #1e3a6f;
    text-decoration: none;
    flex-shrink: 0;
  }
  a.mobile-cta-icon svg {
    display: block;
  }
}

/* Mobile-Geraete >= 560px breit: "Kontakt aufnehmen" nur noch auf halber Breite
   (linksbuendig), damit er auf breiteren Phones/Tablets nicht uebermaessig
   gestreckt aussieht. */
@media (min-width: 560px) and (max-width: 868.98px) {
  a.mobile-cta-main {
    flex: 0 0 calc(50% - 4px);
  }
}

/* ==========================================================================
   iOS Safari/Chrome Fix (Mobile only):
   - body-bg via body::before mit position:fixed (viewport-stabil).
   - Topbar wird position:FIXED statt sticky (iOS WebKit bricht sticky bei
     bg-attachment:fixed → fixed umgeht das Problem komplett). Body padding-
     top kompensiert den Flow-Verlust.
   - Topbar und Gap-Mask haben transparente bg + ein ::before-Pseudo mit
     position:absolute (relativ zum fixed-parent). Overflow:hidden auf parent
     clipt das pseudo auf parent-Hoehe. Pseudo zeigt denselben Viewport-
     relativen Bildausschnitt wie das Body-Pseudo → nahtloser Look.
   Desktop unveraendert (Topbar ist auf Desktop display:none).
   ========================================================================== */
@media (max-width: 868.98px) {
  body {
    background-image: none;
    padding-top: 77px;  /* Platz fuer position:fixed Topbar */
  }
  body::before {
    content: '';
    position: fixed;
    inset: 0;
    background-color: #bdc2c1;
    background-image: url(../images/bg_aussen.png);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center top;
    z-index: -1;
    pointer-events: none;
    transform: translate3d(0, 0, 0);
    -webkit-transform: translate3d(0, 0, 0);
    will-change: transform;
  }

  .topbar {
    position: fixed;
    left: 0;
    right: 0;
    /* top: 0 ist schon im base CSS */
    background-image: none;
    background-attachment: scroll;
    overflow: hidden;
  }
  .topbar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #bdc2c1;
    background-image: url(../images/bg_aussen.png);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center top;
    z-index: -1;
    pointer-events: none;
  }

  .gap-mask {
    background-image: none;
    background-attachment: scroll;
    overflow: hidden;
  }
  .gap-mask::before {
    content: '';
    position: absolute;
    top: -77px;   /* gap-mask sitzt 77px unter viewport-top; pseudo um 77px
                     hoch verschieben, damit es bei viewport-y 0 beginnt */
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: #bdc2c1;
    background-image: url(../images/bg_aussen.png);
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center top;
    z-index: -1;
    pointer-events: none;
  }
}
