/*
 * Zweck: Homepage-Sections (Hero/Loc/CTA/Hero-Stats) + wiederverwendbare Section-Bausteine (text-block, check-list, prozess-list, usp-card, faq-list)
 * Verwendet von: includes/sections/*.php (Home + alle Service-Seiten)
 * Abhängigkeiten: base.css (Tokens), components.css (.btn-primary/.btn-ghost werden in CTA-Box überschrieben)
 * Hinweis: Seiten-spezifische Klassen liegen in assets/css/pages/<seite>.css (dynamisch via $page_css geladen)
 */

/* ─── Hero ─── */
.hero { padding: clamp(2.5rem, 6vw, 4.5rem) 0; }
.hero .container {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2.5rem;
  align-items: center;
}
.hero h1 { margin-bottom: 0.5rem; }
.hero p.hero-credentials {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin: 0 0 1rem;
  letter-spacing: 0.02em;
}
.hero p.lead { margin-bottom: 1.5rem; }
.hero-actions { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-bottom: 1.75rem; }
.hero-visual {
  background: var(--accent-soft);
  border-radius: var(--radius-lg);
  aspect-ratio: 5/6;
  overflow: hidden;
  position: relative;
}
.hero-visual img { width: 100%; height: 100%; object-fit: cover; object-position: right center; }
.hero-visual picture { display: block; width: 100%; height: 100%; }
.hero-visual picture img { border-radius: var(--radius-lg); }

/* ─── Sekundär-Bilder auf Service- und Detail-Seiten (Phase 3) ─── */
.kontakt-hero-image { margin: 0 0 1.5rem; }
.kontakt-hero-image picture,
.kontakt-hero-image img { width: 100%; height: auto; border-radius: var(--radius); display: block; box-shadow: 0 6px 20px rgba(0,0,0,0.1); }

.impressum-buero-image {
  max-width: 420px;
  margin: 1rem 0 1.25rem;
  border-radius: var(--radius);
  overflow: hidden;
}
.impressum-buero-image picture,
.impressum-buero-image img { width: 100%; height: auto; display: block; }
@media (max-width: 900px) {
  .impressum-buero-image { max-width: 100%; margin: 1rem 0; }
}

/* ─── Standort-Cards ─── */
.loc {
  background: var(--bg-white);
  border: 1px solid var(--line);
  border-top: 3px solid var(--success);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.loc iframe { width: 100%; height: 220px; border: 0; }
.loc .info { padding: 1.1rem 1.25rem; }
.loc h3 { font-size: 1.05rem; color: var(--accent); margin-bottom: 0.25rem; }
.loc .meta { font-size: 0.82rem; color: var(--text-muted); margin-top: 0.4rem; }
.loc a { color: var(--text-soft); }
.loc a:hover { color: var(--accent); }

/* ─── CTA Block ─── */
.cta-box {
  background: var(--text);
  color: white;
  padding: clamp(1.75rem, 4vw, 2.75rem);
  border-radius: var(--radius-lg);
  text-align: center;
}
.cta-box h2 { color: white; margin-bottom: 0.6rem; }
.cta-box p { color: rgba(255,255,255,.8); max-width: 540px; margin: 0 auto 1.5rem; }
.cta-box .btn-primary { background: white; color: var(--text); }
.cta-box .btn-primary:hover { background: var(--accent-soft); color: var(--accent); }
.cta-box .btn-ghost { color: white; border-color: rgba(255,255,255,.3); }
.cta-box .btn-ghost:hover { background: rgba(255,255,255,.1); color: white; border-color: white; }

/* ─── Hero-Stats (3-Spalten-Trust-Bar) ─── */
.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--line);
}
.stat { display: flex; flex-direction: column; align-items: flex-start; }
.stat-num {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  line-height: 1.1;
}
.stat-label {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

/* ─── Shared: Lang-Text-Container ─── */
.text-block { max-width: 760px; margin: 0 auto; }
.text-block h3 { margin: 1.75rem 0 0.5rem; }
.text-block p { margin-bottom: 0.85rem; }

/* ─── Shared: ✓-Liste ─── */
.check-list { list-style: none; padding: 0; }
.check-list li {
  position: relative;
  padding-left: 1.6rem;
  margin-bottom: 0.5rem;
  font-size: 0.95rem;
}
.check-list li::before {
  content: '✓';
  position: absolute;
  left: 0;
  top: -0.05em;
  color: var(--success);
  font-weight: 700;
  font-size: 1.05rem;
}

/* ─── Shared: Nummerierte Prozess-Schritte ─── */
.prozess-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  padding: 0;
  counter-reset: prozess;
}
@media (min-width: 541px) {
  .prozess-list { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 880px) {
  .prozess-list { grid-template-columns: repeat(4, 1fr); }
}
.prozess-list li {
  background: var(--bg-white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  position: relative;
}
.prozess-list .num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--accent);
  color: white;
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}
.prozess-list h3 { margin-bottom: 0.4rem; font-size: 1.05rem; }
.prozess-list p { font-size: 0.92rem; color: var(--text-soft); }

/* ─── Shared: USP-Karte (Warum-wir-Karten) ─── */
.usp-card {
  background: var(--bg-white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
}
.usp-card h3 {
  font-size: 1.05rem;
  color: var(--accent);
  margin-bottom: 0.5rem;
}
.usp-card p { font-size: 0.95rem; color: var(--text-soft); }

/* ─── Shared: FAQ-Aufklapper (<details>) ─── */
.faq-list {
  max-width: 760px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}
.faq-item {
  background: var(--bg-white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0;
  overflow: hidden;
}
.faq-item[open] { border-color: var(--accent); }
.faq-item summary {
  padding: 1rem 1.25rem;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.96rem;
  list-style: none;
  position: relative;
  padding-right: 2.5rem;
}
.faq-item summary::after {
  content: '+';
  position: absolute;
  right: 1.25rem;
  top: 1rem;
  font-size: 1.4rem;
  color: var(--accent);
  font-weight: 400;
  transition: transform var(--t);
}
.faq-item[open] summary::after { content: '−'; }
.faq-item p {
  padding: 0 1.25rem 1.25rem;
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-soft);
}

/* ─── Responsive ─── */
@media (max-width: 880px) {
  .hero .container { grid-template-columns: 1fr; }
  .hero-visual { max-width: 380px; margin: 0 auto; }
}
@media (max-width: 540px) {
  .hero-actions .btn { flex: 1; justify-content: center; }
  .loc iframe { height: 240px; }
  .hero-stats { gap: 0.25rem; }
  .stat-num { font-size: 1.25rem; }
  .stat-label { font-size: 0.72rem; }
}

/* ─── Tipp-Karte innerhalb prozess-list (grün, als 5. <li>) ─── */
.prozess-list .prozess-tipp {
  grid-column: 1 / -1;
  background: rgba(22, 163, 74, 0.06);
  border-color: rgba(22, 163, 74, 0.25);
  border-left: 4px solid var(--success);
  hyphens: auto;
  -webkit-hyphens: auto;
  overflow-wrap: break-word;
}
.prozess-list .prozess-tipp .ic {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: var(--success);
  color: white;
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}
.prozess-list .prozess-tipp h3 { color: var(--success); }
.prozess-list .prozess-tipp p { color: var(--text-soft); }

/* ─── Wussten-Sie-Tipp-Block (Homepage zwischen services und fachgebiete) ─── */
.wussten-sie-section { padding: 1.5rem 0; }
.wussten-sie-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.2rem;
  align-items: flex-start;
  background: linear-gradient(135deg, var(--accent-soft) 0%, rgba(255,255,255,0) 100%);
  border-left: 4px solid var(--success);
  padding: 1.4rem 1.6rem;
  border-radius: var(--radius);
}
[dir="rtl"] .wussten-sie-card {
  border-left: none;
  border-right: 4px solid var(--success);
}
.wussten-sie-icon { font-size: 2rem; line-height: 1; }
.wussten-sie-body h3 { margin: .2rem 0 .5rem; font-size: 1.1rem; }
.wussten-sie-body p { margin: 0 0 .6rem; color: var(--text-soft); font-size: 0.95rem; }
.wussten-sie-body .more { font-size: 0.9rem; }

/* ─── FAQ-Statistik-Liste (für Hintergrund-Zahlen-Frage) ─── */
.faq-stat-list { list-style: none; padding-left: 0; margin: .5rem 0 1rem; }
.faq-stat-list > li {
  padding: .6rem 0;
  border-bottom: 1px solid var(--line);
}
.faq-stat-list > li:last-child { border-bottom: none; }
.faq-stat-quellen {
  margin-top: 1rem;
  padding-top: .6rem;
  border-top: 1px solid var(--line);
  color: var(--text-muted);
}
