/* ============================================================================
   einblicke.css — gemeinsames Stylesheet fuer den Wissensblog "Einblicke"
   (Uebersichtsseite + Artikelseiten unter /einblicke/).

   Abgeleitet aus dem <style>-Block von index_v2.html (gleiche Designsprache,
   gleiche Tokens). Pfade ROOT-ABSOLUT (/assets/...), weil die Seiten im
   Unterordner /einblicke/ liegen. Eingebunden via <link rel="stylesheet"> ->
   durch CSP `style-src 'self'` erlaubt, kein Hash noetig.
   ========================================================================== */

/* ---- Fonts (lokal, DSGVO-konform; absolute Pfade) ---- */
@font-face {
  font-family: 'Fraunces';
  src: url('/assets/fonts/Fraunces-VF.woff2') format('woff2-variations'),
       url('/assets/fonts/Fraunces-VF.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Fraunces';
  src: url('/assets/fonts/Fraunces-Italic-VF.woff2') format('woff2-variations'),
       url('/assets/fonts/Fraunces-Italic-VF.woff2') format('woff2');
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Afacad';
  src: url('/assets/fonts/Afacad-VF.woff2') format('woff2-variations'),
       url('/assets/fonts/Afacad-VF.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ---- Tokens (Spiegel von index_v2.html :root) ---- */
:root {
  --bg: #FAFAFA;
  --accent: #3C5A78;
  --accent-petrol: #3C5A78;
  --text: #4B4B4B;
  --accent-deep: #2A4259;
  --accent-soft: #E8EDF2;
  --accent-tint: #F1F4F8;
  --bg-warm: #F5F1E8;
  --text-strong: #1F1B16;
  --text-muted: #7A7A7A;
  --border: #E5DFD2;
  --border-soft: #EFEAE0;
  --surface-dark: #2A4259;
  --gold: #B89968;
  --gold-soft: #D4BC8A;
  --section-y: clamp(40px, 5vw, 72px);
  --container-x: clamp(20px, 5vw, 56px);
  --gap: clamp(16px, 3vw, 32px);
  --font-display: 'Fraunces', 'Cormorant Garamond', Georgia, serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Afacad', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-weight: 400;
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
.container { max-width: 1280px; margin: 0 auto; padding: 0 var(--container-x); }
.container-narrow { max-width: 960px; margin: 0 auto; padding: 0 var(--container-x); }

/* ---- Skip-Link (a11y) ---- */
.skip-link {
  position: absolute; top: -48px; left: 0;
  background: var(--accent); color: #fff;
  padding: 10px 18px; font-size: 15px; text-decoration: none;
  z-index: 1000; border-bottom-right-radius: 4px;
  transition: top 0.15s ease-out;
}
.skip-link:focus { top: 0; outline: none; }

/* ---- Navigation ---- */
nav.top {
  position: sticky; top: 0; z-index: 50;
  background: rgba(250, 250, 250, 0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border-soft);
}
nav.top .row { display: flex; justify-content: space-between; align-items: center; padding: 18px 0; }
.logo { display: flex; align-items: center; gap: 10px; color: var(--accent); text-decoration: none; font-size: 24px; font-weight: 600; letter-spacing: -0.01em; }
.logo img { height: 28px; width: auto; display: block; }
.nav-links { display: none; gap: 32px; align-items: center; }
.nav-links a { color: var(--text); text-decoration: none; font-size: 16px; transition: color 0.2s; }
.nav-links a:hover { color: var(--accent); }
.nav-links a[aria-current="page"] { color: var(--accent); font-weight: 600; }
.nav-links a.nav-cta { color: #fff; background: var(--accent); padding: 10px 20px; border-radius: 999px; font-weight: 500; }
.nav-links a.nav-cta:hover { background: var(--accent-deep); color: #fff; }
.menu-toggle { display: flex; flex-direction: column; justify-content: center; gap: 4px; background: none; border: none; padding: 8px; cursor: pointer; }
.menu-toggle span { display: block; width: 22px; height: 2px; background: var(--text-strong); border-radius: 1px; }
@media (min-width: 900px) {
  .nav-links { display: flex; }
  .menu-toggle { display: none; }
}
@media (max-width: 899px) {
  .nav-links.open {
    display: flex; flex-direction: column;
    position: absolute; top: 100%; left: 0; right: 0;
    background: var(--bg); border-bottom: 1px solid var(--border-soft);
    padding: 20px var(--container-x) 28px;
    gap: 18px; align-items: stretch;
  }
  .nav-links.open a { padding: 8px 0; font-size: 18px; border-bottom: 1px solid var(--border-soft); }
  .nav-links.open a:last-child { border-bottom: none; }
  .nav-links.open .nav-cta { margin-top: 8px; text-align: center; padding: 14px 20px; border-bottom: none; }
}

/* ---- Buttons ---- */
.btn { display: inline-flex; align-items: center; gap: 10px; padding: 16px 28px; border-radius: 999px; text-decoration: none; font-weight: 600; font-size: 16px; transition: transform 0.15s, background 0.2s, color 0.2s; border: 1px solid transparent; cursor: pointer; white-space: nowrap; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-deep); transform: translateY(-1px); }
.btn-secondary { background: var(--bg); color: var(--accent); border-color: var(--accent); }
.btn-secondary:hover { background: var(--accent); color: #fff; }
.btn-on-dark { background: #fff; color: var(--text-strong); }
.btn-on-dark:hover { background: var(--accent-soft); }

/* ---- Section-Heads ---- */
.section { padding: var(--section-y) 0; }
.section-eyebrow { color: var(--accent); font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 18px; display: flex; align-items: center; gap: 12px; }
.section-eyebrow::before { content: ""; width: 32px; height: 1px; background: var(--accent); }
.section-title { font-family: var(--font-display); font-size: clamp(34px, 4.2vw, 56px); font-weight: 600; color: var(--text-strong); line-height: 1.02; letter-spacing: -0.02em; margin-bottom: 20px; font-variation-settings: "opsz" 96; }
.section-lead { font-size: clamp(16px, 1.3vw, 19px); color: var(--text); line-height: 1.6; max-width: 660px; margin-bottom: clamp(32px, 4vw, 48px); }

/* ---- Breadcrumb ---- */
.breadcrumb { font-size: 13px; color: var(--text-muted); padding: clamp(20px, 3vw, 32px) 0 0; letter-spacing: 0.01em; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.breadcrumb li { display: flex; align-items: center; gap: 8px; }
.breadcrumb li:not(:last-child)::after { content: "/"; color: var(--border); }
.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb [aria-current="page"] { color: var(--text-strong); }

/* ---- Einblicke-Header (Uebersicht + Artikel) ---- */
.eb-header { padding: clamp(32px, 5vw, 56px) 0 clamp(8px, 2vw, 20px); }
.eb-eyebrow { color: var(--accent); font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: 16px; display: inline-flex; align-items: center; gap: 12px; }
.eb-eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--accent); }
.eb-title { font-family: var(--font-display); font-size: clamp(34px, 5vw, 60px); font-weight: 600; color: var(--text-strong); line-height: 1.04; letter-spacing: -0.02em; margin-bottom: 18px; font-variation-settings: "opsz" 144; max-width: 18ch; }
.eb-intro { font-size: clamp(16px, 1.3vw, 19px); color: var(--text); line-height: 1.6; max-width: 640px; }

/* ---- Karten-Grid (Uebersicht + "Weitere Einblicke") ---- */
.eb-grid { display: grid; gap: var(--gap); padding: clamp(24px, 3vw, 40px) 0 clamp(40px, 5vw, 64px); }
@media (min-width: 720px) { .eb-grid { grid-template-columns: 1fr 1fr; } }
.eb-card { background: #fff; border: 1px solid var(--border); border-left: 4px solid var(--accent); border-radius: 16px; padding: clamp(26px, 3vw, 36px); text-decoration: none; color: inherit; display: flex; flex-direction: column; gap: 12px; transition: border-color 0.2s, transform 0.2s, box-shadow 0.25s; }
.eb-card:hover { border-color: var(--accent); transform: translateY(-4px); box-shadow: 0 22px 44px -24px rgba(60, 90, 120, 0.3); }
.eb-card-tag { color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: 0.09em; text-transform: uppercase; }
.eb-card h3 { font-family: var(--font-display); font-size: clamp(21px, 2vw, 26px); font-weight: 600; color: var(--text-strong); line-height: 1.18; letter-spacing: -0.01em; }
.eb-card p { font-size: 15.5px; color: var(--text); line-height: 1.6; }
.eb-card-more { color: var(--accent); font-weight: 600; font-size: 15px; margin-top: auto; padding-top: 8px; display: inline-flex; align-items: center; gap: 8px; transition: gap 0.2s; }
.eb-card:hover .eb-card-more { gap: 12px; }

/* ---- Artikel ---- */
.article { padding: clamp(8px, 2vw, 20px) 0 clamp(40px, 6vw, 72px); }
.article-head { margin-bottom: clamp(28px, 4vw, 44px); }
.article h1 { font-family: var(--font-display); font-size: clamp(32px, 4.6vw, 54px); font-weight: 600; color: var(--text-strong); line-height: 1.05; letter-spacing: -0.022em; margin-bottom: 18px; font-variation-settings: "opsz" 144; }
.article-meta { display: flex; flex-wrap: wrap; gap: 8px 16px; font-size: 14px; color: var(--text-muted); align-items: center; }
.article-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--border); }
.article-hero { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 16px; margin: clamp(20px, 3vw, 32px) 0; display: block; box-shadow: 0 24px 50px -28px rgba(40, 60, 90, 0.35); }

/* Artikel-Fliesstext */
.article-body { font-size: clamp(17px, 1.15vw, 18.5px); line-height: 1.72; color: var(--text); }
.article-body > * + * { margin-top: 1.15em; }
.article-body .lead { font-size: clamp(19px, 1.5vw, 22px); line-height: 1.55; color: var(--text-strong); font-weight: 500; }
.article-body h2 { font-family: var(--font-display); font-size: clamp(24px, 2.6vw, 32px); font-weight: 600; color: var(--text-strong); line-height: 1.15; letter-spacing: -0.015em; margin-top: 1.8em; font-variation-settings: "opsz" 72; }
.article-body h3 { font-size: clamp(19px, 1.6vw, 22px); font-weight: 700; color: var(--text-strong); line-height: 1.25; margin-top: 1.5em; }
.article-body p { max-width: 82ch; }
.article-body a { color: var(--accent); border-bottom: 1px solid currentColor; text-decoration: none; }
.article-body a:hover { color: var(--accent-deep); }
.article-body strong { color: var(--text-strong); font-weight: 600; }
.article-body ul, .article-body ol { padding-left: 1.4em; max-width: 80ch; }
.article-body li { margin-top: 0.5em; padding-left: 0.3em; }
.article-body ul li::marker { color: var(--accent); }
.article-body blockquote { border-left: 3px solid var(--accent); padding: 4px 0 4px 22px; margin-left: 0; color: var(--text-strong); font-family: var(--font-display); font-style: italic; font-size: clamp(20px, 1.7vw, 24px); line-height: 1.45; }
.article-body figure img { width: 100%; border-radius: 12px; display: block; }
.article-body figcaption { font-size: 13px; color: var(--text-muted); margin-top: 8px; font-style: italic; }
.article-body table { width: 100%; border-collapse: collapse; font-size: 15px; }
.article-body th, .article-body td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border-soft); }
.article-body th { color: var(--text-muted); font-size: 12px; text-transform: uppercase; letter-spacing: 0.04em; }

/* Platzhalter-Hinweis (nur solange Text fehlt; bei Veroeffentlichung entfernen) */
.article-placeholder { background: var(--accent-tint); border: 1px dashed var(--accent); border-radius: 12px; padding: 20px 24px; color: var(--accent-deep); font-size: 15px; }

/* ---- Editoriale Bausteine (Artikel-Visualisierung, Stil der Startseite) ---- */

/* "Die kurze Antwort" — Highlight-Box am Artikelanfang */
.article-tldr { background: var(--accent-tint); border-left: 4px solid var(--accent); border-radius: 12px; padding: clamp(20px, 2.6vw, 28px); margin: clamp(20px, 3vw, 32px) 0; }
.article-tldr .tldr-label { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; display: inline-flex; align-items: center; gap: 10px; }
.article-tldr .tldr-label::before { content: ""; width: 24px; height: 1px; background: var(--accent); }
.article-tldr p { font-size: clamp(17px, 1.3vw, 19px); line-height: 1.6; color: var(--text-strong); max-width: none; margin: 0; }

/* Definitions-Karten (z. B. Asset-Management-Leistungen) */
.deflist { display: grid; gap: 14px; margin: 8px 0; max-width: none; }
@media (min-width: 680px) { .deflist--two { grid-template-columns: 1fr 1fr; } }
.deflist-item { background: #fff; border: 1px solid var(--border-soft); border-radius: 12px; padding: 18px 20px; }
.deflist-term { font-weight: 700; color: var(--accent-deep); font-size: 16px; margin-bottom: 4px; letter-spacing: -0.005em; }
.deflist-desc { font-size: 14.5px; color: var(--text); line-height: 1.55; }

/* Lücke-Diagramm: Eigentümer -> Lücke (Valurea) -> Hausverwaltung */
.gap-diagram { display: grid; gap: 12px; margin: clamp(24px, 3.5vw, 40px) 0; align-items: stretch; }
@media (min-width: 760px) { .gap-diagram { grid-template-columns: 1fr auto 1.5fr auto 1fr; align-items: center; } }
.gap-node { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 20px 22px; text-align: center; }
.gap-node--mid { background: var(--accent); border-color: var(--accent); color: #fff; box-shadow: 0 24px 50px -28px rgba(60, 90, 120, 0.5); }
.gap-node-label { font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.gap-node--mid .gap-node-label { color: #fff; }
.gap-node-text { font-size: 13.5px; color: var(--text-muted); line-height: 1.45; }
.gap-node--mid .gap-node-text { color: rgba(255, 255, 255, 0.85); }
.gap-arrow { display: flex; align-items: center; justify-content: center; color: var(--accent); }
.gap-arrow svg { width: 30px; height: 30px; }
@media (max-width: 759px) { .gap-arrow svg { transform: rotate(90deg); height: 22px; } }

/* Vergleichstabelle */
.table-scroll { overflow-x: auto; border: 1px solid var(--border-soft); border-radius: 12px; margin: clamp(20px, 3vw, 32px) 0; }
.compare-table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 15px; }
.compare-table thead th { background: var(--accent-deep); color: #fff; text-align: left; padding: 13px 16px; font-size: 13px; letter-spacing: 0.02em; font-weight: 600; }
.compare-table thead th:first-child { background: var(--surface-dark); }
.compare-table th[scope="row"] { text-align: left; font-weight: 600; color: var(--text-strong); background: var(--bg); white-space: nowrap; }
.compare-table td, .compare-table th { padding: 12px 16px; border-bottom: 1px solid var(--border-soft); vertical-align: top; line-height: 1.5; }
.compare-table tbody tr:last-child td, .compare-table tbody tr:last-child th { border-bottom: none; }
.compare-table .col-am { color: var(--text-strong); font-weight: 500; }

/* Pre-Check-Inline-Hinweis (heller Offer-Block im Fließtext) */
.offer-box { background: #fff; border: 1px solid var(--border); border-left: 4px solid var(--gold); border-radius: 12px; padding: clamp(20px, 2.6vw, 28px); margin: clamp(20px, 3vw, 32px) 0; }
.offer-box strong { color: var(--text-strong); }
.offer-price { font-family: var(--font-display); font-size: clamp(22px, 2vw, 26px); font-weight: 600; color: var(--accent); }

/* Rechenbeispiel-Box (kompakt, wertorientiert) */
.calc-box { background: var(--accent-tint); border: 1px solid var(--accent-soft); border-radius: 14px; padding: clamp(22px, 3vw, 30px); margin: clamp(20px, 3vw, 32px) 0; }
.calc-box .calc-label { font-size: 12px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; display: inline-flex; align-items: center; gap: 10px; }
.calc-box .calc-label::before { content: ""; width: 24px; height: 1px; background: var(--accent); }
.calc-box p { max-width: none; font-size: 15.5px; }
.calc-rows { margin: 14px 0 4px; }
.calc-row { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; border-bottom: 1px solid rgba(42, 66, 89, 0.1); font-size: 15px; }
.calc-row span:first-child { flex: 1; }
.calc-row span:last-child { font-weight: 600; color: var(--text-strong); white-space: nowrap; }
.calc-result { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-top: 14px; }
.calc-result-label { font-weight: 600; color: var(--text-strong); font-size: 15.5px; }
.calc-result-value { font-family: var(--font-display); font-size: clamp(24px, 2.6vw, 32px); font-weight: 600; color: var(--accent); line-height: 1; white-space: nowrap; }
.calc-note { font-size: 13px; color: var(--text-muted); margin-top: 14px; line-height: 1.55; font-style: italic; }

/* Info-/Hinweis-Box (z. B. bilanzieller Hinweis) */
.note-box { background: #fff; border: 1px solid var(--border); border-left: 4px solid var(--accent); border-radius: 12px; padding: clamp(18px, 2.4vw, 24px); margin: clamp(20px, 3vw, 32px) 0; }
.note-box .note-label { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 8px; }
.note-box p { max-width: none; font-size: 15.5px; margin: 0; }
.note-box p + p { margin-top: 10px; }
.note-box .fineprint { font-size: 13px; color: var(--text-muted); font-style: italic; }

/* FAQ-Akkordeon (gleicher Look wie die Startseite) */
.faq-list { margin: 10px 0 0; }
.faq-item { border-bottom: 1px solid var(--border-soft); }
.faq-item:first-child { border-top: 1px solid var(--border-soft); }
.faq-summary { cursor: pointer; padding: 20px 0; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 24px; font-size: clamp(16px, 1.4vw, 19px); font-weight: 600; color: var(--text-strong); transition: color 0.2s; letter-spacing: -0.005em; }
.faq-summary::-webkit-details-marker { display: none; }
.faq-summary::marker { content: ""; }
.faq-summary::after { content: "+"; color: var(--accent); font-size: 26px; font-weight: 300; flex-shrink: 0; line-height: 1; }
.faq-item[open] .faq-summary::after { content: "−"; }
.faq-summary:hover { color: var(--accent); }
.faq-answer { padding: 0 0 22px; font-size: 16px; line-height: 1.65; color: var(--text); }
.faq-answer p { margin: 0; max-width: 72ch; }

/* ---- Autoren-Box ---- */
.author-box { display: flex; gap: 18px; align-items: flex-start; background: #fff; border: 1px solid var(--border); border-radius: 16px; padding: clamp(22px, 3vw, 30px); margin: clamp(36px, 5vw, 56px) 0 0; }
.author-avatar { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--accent-soft); }
.author-name { font-weight: 700; color: var(--text-strong); font-size: 17px; }
.author-role { font-size: 13px; color: var(--text-muted); margin-bottom: 8px; }
.author-bio { font-size: 15px; color: var(--text); line-height: 1.6; }
.author-bio a { color: var(--accent); border-bottom: 1px solid currentColor; text-decoration: none; }

/* ---- Weitere Einblicke ---- */
.related { border-top: 1px solid var(--border-soft); margin-top: clamp(40px, 5vw, 64px); padding-top: clamp(32px, 4vw, 48px); }
.related h2 { font-family: var(--font-display); font-size: clamp(22px, 2.2vw, 28px); font-weight: 600; color: var(--text-strong); margin-bottom: clamp(18px, 2.5vw, 26px); letter-spacing: -0.01em; }

/* ---- CTA-Block ---- */
.eb-cta { background: var(--surface-dark); color: #fff; border-radius: 18px; padding: clamp(32px, 4.5vw, 52px); text-align: center; position: relative; overflow: hidden; margin: clamp(40px, 5vw, 64px) 0 0; }
.eb-cta::before { content: ""; position: absolute; top: -160px; left: 50%; transform: translateX(-50%); width: 560px; height: 560px; background: radial-gradient(circle, var(--gold) 0%, transparent 60%); opacity: 0.16; border-radius: 50%; pointer-events: none; }
.eb-cta > * { position: relative; z-index: 1; }
.eb-cta h2 { font-family: var(--font-display); font-size: clamp(26px, 3.2vw, 40px); font-weight: 600; margin-bottom: 14px; line-height: 1.1; letter-spacing: -0.02em; color: #fff; }
.eb-cta p { color: #C7D1DC; font-size: clamp(15px, 1.3vw, 18px); line-height: 1.6; max-width: 520px; margin: 0 auto 28px; }

/* ---- Footer ---- */
footer { padding: clamp(48px, 6vw, 72px) 0 32px; background: var(--bg); border-top: 3px solid var(--accent); }
.footer-grid { display: grid; gap: 40px; padding-bottom: 36px; border-bottom: 1px solid var(--border); margin-bottom: 24px; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }
.footer-col h5 { font-size: 13px; color: var(--text-strong); font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 14px; }
.footer-col a { display: block; color: var(--text); text-decoration: none; padding: 4px 0; font-size: 15px; }
.footer-col a:hover { color: var(--accent); }
.footer-tagline { font-size: 14px; color: var(--text-muted); line-height: 1.55; margin-top: 12px; max-width: 320px; }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; font-size: 13px; color: var(--text-muted); }
.footer-legal { color: var(--text-muted); }
.footer-legal--spaced { margin-right: 16px; }

/* ---- Focus-Styles (a11y) ---- */
:focus { outline: none; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 2px; }
.eb-cta :focus-visible { outline-color: var(--gold-soft); }

@media (prefers-reduced-motion: reduce) {
  .eb-card, .btn { transition: none; }
  html { scroll-behavior: auto; }
}
