/* ============================================================
   SoWo Baufinanzierung – Zusatz-Styles für Inhaltsseiten
   Wird NACH style.css geladen und ergänzt diese nur.
   (Produkt-, Standort- und Ratgeberseiten)
   ============================================================ */

/* ---------- Hero-Bild lokal statt von Unsplash laden ----------
   Vorher lud jede Unterseite ein 1920px-Foto von images.unsplash.com
   (externer Request, kein Cache, keine Kontrolle über Verfügbarkeit). */
.page-hero-bg {
  background-image: url('hero-frankfurt.jpg');
  background-image: image-set(
    url('hero-frankfurt.webp') type('image/webp'),
    url('hero-frankfurt.jpg')  type('image/jpeg')
  );
  background-position: center 30%;
  background-size: cover;
}

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  background: var(--bg-gray);
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}
.breadcrumb ol {
  display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  list-style: none; padding: 12px 0; margin: 0;
  color: var(--text-muted);
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--primary); text-decoration: underline; }
.breadcrumb li[aria-current] { color: var(--text); font-weight: 600; }
.breadcrumb .sep { opacity: .5; }

/* ---------- Lesbarer Textkörper ---------- */
.content-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 48px;
  align-items: start;
}
.prose { max-width: 760px; min-width: 0; font-size: 17px; line-height: 1.75; }
.prose > * + * { margin-top: 20px; }
.prose h2 {
  font-size: 1.7rem; line-height: 1.25; margin-top: 48px;
  scroll-margin-top: 100px; letter-spacing: -.01em;
}
.prose h3 {
  font-size: 1.22rem; margin-top: 32px; scroll-margin-top: 100px;
}
.prose h2 + p, .prose h3 + p { margin-top: 12px; }
.prose p { color: #24191a; }
.prose strong { color: var(--text); }
.prose a:not(.btn) {
  color: var(--primary); text-decoration: underline;
  text-decoration-thickness: 1px; text-underline-offset: 2px;
}
.prose a:not(.btn):hover { color: var(--primary-dark); }
.prose ul, .prose ol { padding-left: 22px; }
.prose ul li, .prose ol li { margin-bottom: 10px; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose ul.checklist { list-style: none; padding-left: 0; }
.prose ul.checklist li {
  position: relative; padding-left: 30px;
}
.prose ul.checklist li::before {
  content: '✓'; position: absolute; left: 0; top: -1px;
  color: var(--primary); font-weight: 700;
}
.prose blockquote {
  border-left: 3px solid var(--primary);
  padding: 4px 0 4px 20px; color: var(--text-muted); font-style: italic;
}

/* ---------- Inhaltsverzeichnis ---------- */
.toc {
  background: var(--bg-gray);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
}
.toc strong { display: block; margin-bottom: 10px; font-size: 15px; }
.toc ol { list-style: none; padding: 0; margin: 0; counter-reset: toc; }
.toc li { counter-increment: toc; margin-bottom: 8px; font-size: 15px; }
.toc li::before {
  content: counter(toc) '.'; color: var(--primary);
  font-weight: 700; margin-right: 8px;
}
.toc a { color: var(--text); text-decoration: none; }
.toc a:hover { color: var(--primary); text-decoration: underline; }

/* ---------- Hinweisboxen ---------- */
.callout {
  border-radius: var(--radius);
  padding: 20px 24px;
  background: var(--primary-light);
  border-left: 4px solid var(--primary);
}
.callout strong:first-child { display: block; margin-bottom: 6px; }
.callout p + p { margin-top: 10px; }
.callout-neutral { background: var(--bg-gray); border-left-color: var(--accent); }
.callout-warn { background: #fff8e6; border-left-color: #c49a00; }
.callout-fact {
  background: #fff; border: 1px solid var(--border);
  border-left: 4px solid var(--accent); box-shadow: var(--shadow);
}
.callout small { display: block; margin-top: 10px; color: var(--text-muted); font-size: 13px; }

/* ---------- Tabellen ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.data-table {
  width: 100%; border-collapse: collapse; font-size: 15px;
  min-width: 460px;
}
.data-table th, .data-table td {
  padding: 12px 14px; text-align: left;
  border-bottom: 1px solid var(--border); vertical-align: top;
}
.data-table thead th {
  background: var(--bg-gray); font-weight: 700; font-size: 14px;
  color: var(--text);
}
.data-table tbody tr:last-child td { border-bottom: none; }
.data-table td strong { color: var(--primary); }

/* ---------- Seitenspalte ---------- */
.sidebar { position: sticky; top: 96px; display: grid; gap: 20px; }
.side-card {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 24px;
  box-shadow: var(--shadow);
}
.side-card h3 { font-size: 1.1rem; margin-bottom: 10px; }
.side-card p { font-size: 15px; color: var(--text-muted); margin-bottom: 16px; }
.side-card-dark {
  background: var(--bg-dark); border: none; color: #fff;
}
.side-card-dark h3 { color: #fff; }
.side-card-dark p { color: rgba(255,255,255,.72); }
.side-contact { display: grid; gap: 10px; font-size: 15px; }
.side-contact a { color: inherit; font-weight: 600; }
.side-links { list-style: none; padding: 0; display: grid; gap: 10px; }
.side-links a {
  font-size: 15px; color: var(--text);
  display: flex; gap: 8px; align-items: baseline;
}
.side-links a::before { content: '→'; color: var(--primary); }
.side-links a:hover { color: var(--primary); }

/* ---------- Karten-Raster (Standorte, verwandte Artikel) ---------- */
.tile-grid {
  display: grid; gap: 20px;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}
.tile {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 24px;
  transition: transform .2s, box-shadow .2s, border-color .2s;
  display: flex; flex-direction: column;
}
.tile:hover {
  transform: translateY(-3px); box-shadow: var(--shadow-lg);
  border-color: rgba(126,1,1,.28);
}
.tile h3 { font-size: 1.12rem; margin-bottom: 8px; }
.tile p { font-size: 15px; color: var(--text-muted); flex: 1; }
.tile .tile-link {
  margin-top: 14px; font-weight: 600; color: var(--primary); font-size: 15px;
}
.tile-eyebrow {
  font-size: 12px; font-weight: 700; letter-spacing: .06em;
  text-transform: uppercase; color: var(--primary); margin-bottom: 8px;
}

/* ---------- Artikel-Kopf ---------- */
.article-head { max-width: 760px; }
.article-meta-row {
  display: flex; flex-wrap: wrap; gap: 10px; align-items: center;
  font-size: 14px; color: var(--text-muted); margin-top: 16px;
}
.article-meta-row .dot { opacity: .5; }
.author-box {
  display: flex; gap: 16px; align-items: flex-start;
  background: var(--bg-gray); border: 1px solid var(--border);
  border-radius: var(--radius-lg); padding: 22px; margin-top: 48px;
}
.author-box .team-avatar { flex: 0 0 56px; width: 56px; height: 56px; font-size: 18px; }
.author-box h4 { font-size: 1.05rem; margin-bottom: 4px; }
.author-box p { font-size: 14px; color: var(--text-muted); margin: 0; }
.author-box span.author-role {
  font-size: 13px; color: var(--primary); font-weight: 600;
  display: block; margin-bottom: 8px;
}

/* ---------- CTA-Band ---------- */
.cta-band {
  background: linear-gradient(135deg, #1a0505 0%, #5c0101 60%, #7e0101 100%);
  color: #fff; padding: 64px 0;
}
.cta-band h2 { color: #fff; font-size: 2rem; margin-bottom: 12px; }
.cta-band p { color: rgba(255,255,255,.76); font-size: 17px; margin-bottom: 28px; }
.cta-band-inner { max-width: 720px; margin: 0 auto; text-align: center; }
.cta-band-actions {
  display: flex; gap: 14px; justify-content: center; flex-wrap: wrap;
}
.cta-note {
  margin-top: 18px; font-size: 14px; color: rgba(255,255,255,.6);
}

/* ---------- Kurz-Fakten unter dem Hero ---------- */
.fact-row {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  margin-top: 32px;
}
.fact {
  background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.16);
  border-radius: var(--radius); padding: 16px 18px;
}
.fact-num { display: block; font-size: 1.35rem; font-weight: 800; color: #fff; }
.fact-label { font-size: 13px; color: rgba(255,255,255,.72); }

/* ---------- Floating WhatsApp (ohne JS) ---------- */
.float-simple {
  position: fixed; right: 20px; bottom: 20px; z-index: 90;
  width: 54px; height: 54px; border-radius: 50%;
  background: #25d366; color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 20px rgba(0,0,0,.22);
}
.float-simple svg { width: 26px; height: 26px; }
.float-simple:hover { transform: scale(1.06); }

/* ---------- Rechtlicher Hinweis am Seitenende ---------- */
.legal-footnote {
  font-size: 13px; color: var(--text-muted); line-height: 1.6;
  border-top: 1px solid var(--border); padding-top: 20px; margin-top: 40px;
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  /* minmax(0, 1fr) statt 1fr: sonst sprengen die Tabellen mit min-width
     die Spalte und die Seite scrollt horizontal. */
  .content-layout { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .sidebar { position: static; }
}
@media (max-width: 560px) {
  .data-table { min-width: 400px; }
  .table-wrap { margin-inline: -4px; }
}
@media (max-width: 640px) {
  .prose { font-size: 16px; }
  .prose h2 { font-size: 1.42rem; margin-top: 36px; }
  .cta-band h2 { font-size: 1.6rem; }
  .author-box { flex-direction: column; }
}
