/*
 * Zweck: Page-CSS nur für /agb/
 * Verwendet von: agb.php (dynamisch via $page_css)
 * Abhängigkeiten: base.css (Tokens). Überschreibt widgets.css (Floats werden ausgeblendet).
 */

/* ─── Hero (kompakter als Service-Hero, keine Visuals/Stats) ─── */
.agb-hero {
  padding: clamp(2rem, 5vw, 3.5rem) 0 1.5rem;
}
.agb-hero .container { max-width: 760px; }
.agb-hero h1 { margin: 0.4rem 0 0.25rem; }
.agb-subtitle {
  font-size: 1rem;
  color: var(--text-soft);
  margin-bottom: 0.75rem;
}
.agb-hero .lead { margin-bottom: 1rem; }
.agb-stand {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
}
.agb-download { margin-top: 1rem; }
.agb-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

/* ─── Inhaltsverzeichnis ─── */
.agb-toc-section { padding: 0.5rem 0 2rem; }
.agb-toc {
  max-width: 760px;
  margin: 0 auto;
  background: var(--bg-white);
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
}
.agb-toc h2 {
  font-size: 1rem;
  margin-bottom: 0.6rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.agb-toc ol {
  margin: 0;
  padding-left: 1.3rem;
  font-size: 0.93rem;
  line-height: 1.7;
}
.agb-toc a { color: var(--text); text-decoration: none; }
.agb-toc a:hover { color: var(--accent); text-decoration: underline; }

/* ─── Hauptinhalt: lesefreundliche Textsäule ─── */
.agb-inhalt { padding: 1rem 0 3rem; }
.agb-inhalt .container { max-width: 760px; }
.agb-abschnitt {
  padding-top: 1.5rem;
  scroll-margin-top: 90px;
}
.agb-abschnitt + .agb-abschnitt {
  border-top: 1px solid var(--line);
  margin-top: 1.5rem;
}
.agb-abschnitt h2 {
  font-size: 1.3rem;
  color: var(--accent);
  margin-bottom: 1rem;
}
.agb-abschnitt p {
  font-size: 0.96rem;
  line-height: 1.7;
  margin-bottom: 0.75rem;
  color: var(--text);
}
.abs-nr {
  display: inline-block;
  font-weight: 700;
  color: var(--accent);
  margin-right: 0.25rem;
  scroll-margin-top: 90px;
}
.agb-list {
  list-style: disc;
  padding-left: 1.5rem;
  margin: 0.5rem 0 1rem;
}
.agb-list li {
  font-size: 0.94rem;
  line-height: 1.65;
  margin-bottom: 0.35rem;
  color: var(--text);
}

/* ─── Float-Buttons + Cookie-Banner auf Rechtstext-Seite ausblenden ─── */
/* (Specificity gleich, agb.css lädt nach widgets.css → gewinnt) */
.call-float,
.wa-float { display: none; }

/* Print-Footer (nur sichtbar im Druck) */
.agb-print-footer { display: none; }

/* ─── Print-View ─── */
/* Greift bei echtem Druck (Cmd+P) UND bei /agb/?print=1 (body.printview wird
   in agb.php gesetzt). Zweite Variante nötig weil wkhtmltopdf 0.12.6
   (unpatched Qt) --print-media-type ignoriert. */

@media print {
  .topbar,
  .header,
  .footer,
  .agb-toc-section,
  .agb-download,
  .call-float,
  .wa-float,
  .cookies { display: none !important; }
  body { color: #000; background: #fff; font-size: 11pt; }
  .agb-inhalt .container,
  .agb-hero .container { max-width: 100%; }
  .agb-abschnitt { page-break-inside: avoid; }
  .agb-abschnitt h2 { page-break-after: avoid; }
  a { color: #000; text-decoration: none; }
  .agb-print-footer {
    display: block;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #999;
    font-size: 9pt;
    color: #666;
    text-align: center;
  }
}

/* Mirror der Print-Regeln für ?print=1 (body.printview) */
body.printview .topbar,
body.printview .header,
body.printview .footer,
body.printview .agb-toc-section,
body.printview .agb-download,
body.printview .call-float,
body.printview .wa-float,
body.printview .cookies { display: none !important; }
body.printview {
  color: #000;
  background: #fff;
  font-size: 11pt;
  /* Inter-Webfont raus → System-Sans-Serif → PDF wird klein UND durchsuchbar */
  font-family: 'Helvetica', 'Arial', sans-serif;
}
body.printview h1,
body.printview h2,
body.printview h3,
body.printview h4 { font-family: 'Helvetica', 'Arial', sans-serif; }
body.printview .agb-inhalt .container,
body.printview .agb-hero .container { max-width: 100%; }
body.printview .agb-abschnitt { page-break-inside: avoid; }
body.printview .agb-abschnitt h2 { page-break-after: avoid; }
body.printview a { color: #000; text-decoration: none; }
body.printview .agb-print-footer {
  display: block;
  margin-top: 2rem;
  padding-top: 1rem;
  border-top: 1px solid #999;
  font-size: 9pt;
  color: #666;
  text-align: center;
}
