/* Service-Landingpages (/leistungen/*) — ergänzt styles.css + homepage.css. */

/* ---------- Hero ----------
   Die Fläche trägt das Markenmuster (.brand-fill-hero aus styles.css),
   kein Foto. Mindesthöhe und gelbe Abschlusskante kommen zentral von dort. */
.lstg-hero {
  position: relative;
  display: flex;
  align-items: center;
  color: #fff;
  padding: clamp(120px, 16vw, 190px) 0 clamp(56px, 8vw, 90px);
}
.lstg-hero .container { max-width: 900px; position: relative; z-index: 1; }

/* Kopfbereich mit eigenem Motiv (Leistungen und Über uns).
   Dasselbe Mittel wie bei den CMS-Seiten (.pg-hero.has-media): das Bild liegt
   gedämpft dahinter, ein Verlauf darüber hält den Text lesbar — sonst
   entscheidet das Motiv darüber, ob die Überschrift noch zu entziffern ist.
   Die Schichtung ist ausdrücklich gesetzt, weil ::after sonst über dem Text
   läge: Bild 0, Verlauf 1, Inhalt 2. */
.lstg-hero.has-media { background-color: var(--c-bg-deep); border-bottom: 3px solid var(--c-primary); }
.lstg-hero .bg { position: absolute; inset: 0; z-index: 0; }
.lstg-hero .bg img { width: 100%; height: 100%; object-fit: cover; opacity: .35; }
.lstg-hero.has-media::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(10,10,11,.5), rgba(10,10,11,.85));
}
.lstg-hero.has-media .container { z-index: 2; }
.lstg-hero .crumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 600;
  font-size: 12.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}
.lstg-hero .crumb a:hover { color: var(--c-primary); }
.lstg-hero h1 {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  line-height: 0.98;
  letter-spacing: -0.01em;
  font-size: clamp(38px, 6vw, 82px);
  margin: 14px 0 18px;
  text-transform: none;
}
.lstg-hero .y { color: var(--c-primary); }
.lstg-hero .lead {
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(17px, 2vw, 21px);
  line-height: 1.5;
  max-width: 64ch;
}
.lstg-hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 28px; }

/* ---------- Fakten-Streifen ---------- */
/* padding: 0 ist hier kein Feinschliff, sondern Pflicht: styles.css gibt
   JEDEM <section> `padding: var(--section-y) 0` — auf breiten Schirmen sind
   das 140 px oben und unten. Der Streifen selbst ist nur rund 110 px hoch;
   ohne diese Zeile wird aus dem schmalen Band eine gelbe Fläche von fast
   400 px. Der Abstand, den die Zahlen brauchen, steckt in .lstg-fact. */
.lstg-facts { background: var(--c-primary); color: #0A0A0B; padding: 0; }
.lstg-facts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(190px, 100%), 1fr));
  /* Die Trennlinien entstehen aus dem Abstand: Der Raster-Hintergrund scheint
     1 px breit zwischen den Feldern durch. Das trennt auch dann sauber, wenn
     der Streifen auf schmalen Geräten umbricht — eine rechte Rahmenlinie am
     letzten Feld einer Zeile stünde dort frei in der Luft. */
  gap: 1px;
  background: rgba(0, 0, 0, 0.14);
  margin: 0;
}
.lstg-fact {
  padding: clamp(22px, 3vw, 34px) 22px;
  background: var(--c-primary);
  /* Jedes Feld übernimmt die zwei Zeilen des Rasters, statt sie für sich
     selbst zu setzen. Dadurch stehen alle Werte auf einer Linie, auch wenn
     eine Bezeichnung zwei Zeilen braucht und die Nachbarn nur eine. */
  display: grid;
  grid-template-rows: subgrid;
  grid-row: span 2;
  /* Ein Teilraster erbt sonst den 1-px-Abstand von oben — der würde als
     dunkle Linie zwischen Bezeichnung und Wert quer durchs Feld laufen. */
  gap: 0;
}
.lstg-fact dt {
  font-size: 12.5px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-weight: 600;
  opacity: 0.72;
  margin-bottom: 8px;
  /* Zweizeilige Bezeichnungen auf beide Zeilen verteilen, statt ein
     einzelnes Wort allein unten stehen zu lassen. */
  text-wrap: balance;
}
.lstg-fact dd {
  margin: 0;
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: clamp(20px, 2.4vw, 27px);
  line-height: 1.05;
  align-self: start;
}

/* ---------- Textabschnitte ---------- */
.lstg-body .container { max-width: 820px; }
.lstg-section { margin-bottom: clamp(40px, 6vw, 64px); }
.lstg-section:last-child { margin-bottom: 0; }

/* Abschnitt mit Bild: zweispaltig, und jeder zweite spiegelt die Seiten.
   Abschnitte ohne Bild bleiben unberührt einspaltig — deshalb hängt alles an
   der Klasse .hat-bild und nicht an .lstg-section selbst. */
.lstg-section.hat-bild {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(26px, 4vw, 56px);
  align-items: start;
}
/* Nur die BEBILDERTEN Abschnitte zählen für den Seitenwechsel: sonst würde ein
   textlicher Abschnitt dazwischen den Rhythmus kippen. */
.lstg-section.hat-bild:nth-of-type(even) .lstg-section-bild { order: -1; }
.lstg-section-text { min-width: 0; }
.lstg-section-bild { margin: 0; min-width: 0; }
/* Bildformat je Abschnitt, gesteuert im CMS.
   Text und Bild stehen nebeneinander; bei langem Text bleibt neben einem
   Querformat viel Spalte leer — dafür gibt es „Hochkant“. Der Beschnitt ist
   mittig (object-fit), das Motiv sollte also nicht am Rand liegen. */
.lstg-section-bild img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  max-width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.12);
}
.lstg-section-bild.ist-hochkant img { aspect-ratio: 3 / 4; }
.lstg-section-bild.ist-hochformat img { aspect-ratio: 9 / 16; }
/* Ohne Beschnitt bestimmt das Bild selbst die Höhe. */
.lstg-section-bild.ist-original img { aspect-ratio: auto; height: auto; object-fit: contain; }

/* Hohe Formate laufen mit, statt oben wegzuscrollen.
   Der Text ist oft deutlich länger als das Bild hoch ist; ohne dies stünde
   neben der zweiten Texthälfte wieder nichts. Erst ab der zweispaltigen
   Darstellung sinnvoll — darunter liegen Bild und Text ohnehin untereinander.
   Der Abstand nach oben hält die Navigationsleiste frei. */
@media (min-width: 821px) {
  .lstg-section-bild.ist-hochkant,
  .lstg-section-bild.ist-hochformat {
    position: sticky;
    top: 104px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .lstg-section-bild.ist-hochkant,
  .lstg-section-bild.ist-hochformat { position: static; }
}
.lstg-section-bild figcaption {
  margin-top: 10px;
  font-size: 13.5px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.5);
}
@media (max-width: 820px) {
  .lstg-section.hat-bild { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  /* Gespiegelt oder nicht — schmal steht das Bild immer unter dem Text. */
  .lstg-section.hat-bild:nth-of-type(even) .lstg-section-bild { order: 0; }
}
.lstg-section h2 {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: clamp(26px, 3.4vw, 40px);
  line-height: 1.05;
  margin: 0 0 16px;
  padding-left: 18px;
  border-left: 4px solid var(--c-primary);
}
.lstg-prose { color: rgba(255, 255, 255, 0.8); font-size: 17px; line-height: 1.62; }
.lstg-prose strong { color: #fff; font-weight: 600; }
.lstg-prose a { color: var(--c-primary); text-decoration: underline; text-underline-offset: 2px; }
.lstg-bullets {
  list-style: none;
  margin: 20px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}
.lstg-bullets li {
  position: relative;
  padding-left: 28px;
  color: rgba(255, 255, 255, 0.86);
  line-height: 1.45;
}
.lstg-bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  width: 15px;
  height: 15px;
  background: var(--c-primary);
  -webkit-mask: var(--marker-haken) center / contain no-repeat;
  mask: var(--marker-haken) center / contain no-repeat;
}

/* ---------- FAQ (Akkordeon, ohne JS) ---------- */
.lstg-faq .container { max-width: 860px; }
.lstg-faqlist { display: grid; gap: 12px; }
.lstg-faqitem {
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.02);
  overflow: hidden;
}
.lstg-faqitem summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 52px 18px 20px;
  position: relative;
  font-weight: 600;
  font-size: 17px;
  color: #fff;
}
.lstg-faqitem summary::-webkit-details-marker { display: none; }
.lstg-faqitem summary::after {
  content: "+";
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 26px;
  line-height: 1;
  color: var(--c-primary);
  transition: transform 0.2s ease;
}
.lstg-faqitem[open] summary::after { content: "–"; }
.lstg-faqanswer {
  padding: 0 20px 20px;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.6;
}

/* ---------- Verwandte Leistungen ---------- */
.lstg-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
  gap: 16px;
}
.lstg-related-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  padding: 26px 24px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  color: #fff;
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease, background 0.2s ease;
}
.lstg-related-card:hover { border-color: var(--c-primary); transform: translateY(-3px); background: rgba(255, 255, 255, 0.03); }
.lstg-related-card h3 {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: 23px;
  line-height: 1.08;
  margin: 0;
}
.lstg-related-more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--c-primary);
  font-weight: 600;
  font-size: 14px;
}
.lstg-related-more svg { width: 18px; height: 12px; }

/* ---------- Hub-Übersicht (/leistungen.html) ---------- */
.lstg-hub-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  gap: 22px;
}
.lstg-hub-card {
  display: flex;
  flex-direction: column;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  overflow: hidden;
  color: #fff;
  text-decoration: none;
  background: rgba(255, 255, 255, 0.02);
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.lstg-hub-card:hover { border-color: var(--c-primary); transform: translateY(-4px); }
/* Kopfband der Karte: Markenmuster (.brand-fill) mit Ziffer und Leistungsart
   statt Bildplatz — feste Mindesthöhe hält die Karten im Raster gleichmäßig. */
.lstg-hub-head {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 8px;
  min-height: 116px;
  padding: 26px 24px 20px;
  border-bottom: 1px solid rgba(250, 223, 0, 0.35);
  transition: border-color 0.2s ease;
}
.lstg-hub-card:hover .lstg-hub-head { border-bottom-color: var(--c-primary); }
.lstg-hub-num {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: 34px;
  line-height: 0.9;
  color: var(--c-primary);
}
.lstg-hub-type {
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.14em;
  line-height: 1.35;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.78);
}
.lstg-hub-body { padding: 24px 24px 26px; display: flex; flex-direction: column; gap: 12px; flex: 1; min-height: 210px; }
.lstg-hub-body h2 {
  font-family: "Barlow Condensed", sans-serif;
  font-weight: 700;
  font-size: clamp(22px, 2.6vw, 28px);
  line-height: 1.06;
  margin: 0;
}
.lstg-hub-body p { color: rgba(255, 255, 255, 0.72); font-size: 15px; line-height: 1.55; margin: 0; flex: 1; }
.lstg-hub-body .lstg-related-more { margin-top: 4px; }
