/* ====================================================================
   Jahresanzeigen.de — Subpages stylesheet (legal / info)
   Shared by: impressum.html, datenschutz.html, agb.html,
              barrierefreiheit.html
   Self-contained, scoped under .subpage / .subpage-hdr to avoid
   clashes with styles.css. Reuses the design tokens (CSS variables)
   and the existing .ftr footer styles from styles.css.
   ==================================================================== */

/* ---------- Subpage sticky header --------------------------------- */
.subpage-hdr {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 100;
  padding: 12px 0;
  background: rgba(5, 11, 28, 0.78);
  backdrop-filter: saturate(140%) blur(18px);
  -webkit-backdrop-filter: saturate(140%) blur(18px);
  border-bottom: 1px solid var(--rule-on-dark);
}
.subpage-hdr__inner {
  display: flex; align-items: center; gap: 18px;
  min-height: 48px;
}
.subpage-hdr__brand { display: inline-flex; align-items: center; gap: 12px; flex-shrink: 0; }
.subpage-hdr__brand img { height: 40px; width: auto; filter: brightness(1.05); }
.subpage-hdr__back {
  margin-left: auto;
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13.5px;
  color: var(--text-on-dark-soft);
  transition: color var(--t-fast);
  white-space: nowrap;
}
.subpage-hdr__back:hover { color: var(--text-on-dark); }
.subpage-hdr__cta { flex-shrink: 0; }
@media (max-width: 560px) {
  .subpage-hdr__back span.label { display: none; }
  .subpage-hdr__brand img { height: 32px; }
}

/* ---------- Subpage layout ---------------------------------------- */
.subpage {
  background: var(--ink);
  color: var(--text-on-dark);
  /* Top padding clears the fixed header; section padding is fluid. */
  padding: clamp(110px, 14vw, 152px) 0 clamp(72px, 9vw, 112px);
  position: relative;
  overflow: hidden;
  min-height: 70vh;
}
.subpage::before {
  content: ''; position: absolute; inset: 0 0 auto 0; height: 420px;
  background:
    radial-gradient(ellipse 70% 100% at 50% -10%, rgba(0, 182, 240, 0.14), transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.subpage > .wrap-narrow { position: relative; z-index: 1; }

.subpage .eyebrow { margin-bottom: 18px; }
.subpage h1.display {
  font-size: clamp(34px, 5vw, 56px);
  letter-spacing: -0.028em;
  line-height: 1.04;
  margin-bottom: 14px;
  color: var(--text-on-dark);
}
.subpage .legal-meta {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--text-on-dark-mute);
  margin-bottom: 40px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--rule-on-dark);
}

/* ---------- Prose typography -------------------------------------- */
.prose {
  max-width: 70ch;
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-on-dark-soft);
}
.prose > * + * { margin-top: 18px; }

.prose h2 {
  font-family: var(--font-display);
  font-size: clamp(22px, 2.6vw, 28px);
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.18;
  color: var(--text-on-dark);
  margin-top: 52px;
  margin-bottom: 4px;
  padding-top: 8px;
  scroll-margin-top: 96px;
}
.prose h2:first-child { margin-top: 0; }
.prose h2 .brand-em,
.prose h3 .brand-em { color: var(--brand-glow); font-style: normal; }

.prose h3 {
  font-family: var(--font-display);
  font-size: clamp(17px, 1.8vw, 20px);
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.25;
  color: var(--text-on-dark);
  margin-top: 34px;
  margin-bottom: 2px;
  scroll-margin-top: 96px;
}

.prose p,
.prose li { color: var(--text-on-dark-soft); }

.prose strong { color: var(--text-on-dark); font-weight: 600; }

.prose a {
  color: var(--brand-glow);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  text-decoration-color: rgba(127, 224, 255, 0.45);
  transition: color var(--t-fast), text-decoration-color var(--t-fast);
}
.prose a:hover {
  color: #fff;
  text-decoration-color: var(--brand-glow);
}

.prose ul,
.prose ol { padding-left: 22px; }
.prose ul { list-style: none; padding-left: 0; }
.prose ul > li {
  position: relative;
  padding-left: 24px;
  margin-top: 10px;
}
.prose ul > li::before {
  content: '';
  position: absolute;
  left: 2px; top: 11px;
  width: 7px; height: 7px;
  border-radius: 2px;
  background: linear-gradient(135deg, var(--brand-glow), var(--brand));
  box-shadow: 0 0 8px rgba(0, 182, 240, 0.5);
}
.prose ol { padding-left: 26px; }
.prose ol > li { margin-top: 10px; }
.prose ol > li::marker { color: var(--brand-glow); font-family: var(--font-mono); }

/* ---------- Definition list / data rows (Impressum) --------------- */
.prose dl.data-rows {
  margin-top: 16px;
  display: grid;
  grid-template-columns: minmax(150px, 230px) 1fr;
  gap: 0;
  border: 1px solid var(--rule-on-dark);
  border-radius: var(--r-md);
  overflow: hidden;
  background: linear-gradient(155deg, rgba(17, 38, 74, 0.40) 0%, rgba(8, 19, 43, 0.40) 100%);
}
.prose dl.data-rows > dt,
.prose dl.data-rows > dd {
  padding: 14px 18px;
  border-top: 1px solid var(--rule-on-dark);
  margin: 0;
}
.prose dl.data-rows > dt:first-of-type,
.prose dl.data-rows > dt:first-of-type + dd { border-top: 0; }
.prose dl.data-rows > dt {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--text-on-dark-mute);
  background: rgba(127, 224, 255, 0.03);
  align-self: stretch;
  display: flex;
  align-items: center;
}
.prose dl.data-rows > dd {
  color: var(--text-on-dark);
  font-size: 15px;
}
@media (max-width: 560px) {
  .prose dl.data-rows { grid-template-columns: 1fr; }
  .prose dl.data-rows > dt { border-top: 1px solid var(--rule-on-dark); padding-bottom: 4px; }
  .prose dl.data-rows > dd { border-top: 0; padding-top: 6px; }
  .prose dl.data-rows > dt:first-of-type + dd { border-top: 0; }
}

/* ---------- Tables (e.g. data-processing overview) ---------------- */
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
  font-size: 14.5px;
  border: 1px solid var(--rule-on-dark);
  border-radius: var(--r-md);
  overflow: hidden;
}
.prose th,
.prose td {
  text-align: left;
  padding: 12px 16px;
  border-bottom: 1px solid var(--rule-on-dark);
  vertical-align: top;
}
.prose th {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand-glow);
  background: rgba(127, 224, 255, 0.04);
  font-weight: 500;
}
.prose td { color: var(--text-on-dark-soft); }
.prose tr:last-child td { border-bottom: 0; }

/* ---------- Info / recommendation callout ------------------------- */
.prose .note {
  margin-top: 22px;
  padding: 18px 20px;
  border-radius: var(--r-md);
  background: rgba(17, 38, 74, 0.45);
  border: 1px solid var(--glass-dark-border);
  border-left: 3px solid var(--brand);
  font-size: 14.5px;
  line-height: 1.6;
}
.prose .note strong { color: var(--brand-glow); }
.prose .note > * + * { margin-top: 10px; }

/* ---------- Placeholder highlight ([BITTE ERGÄNZEN: …]) ----------- */
.placeholder {
  display: inline;
  font-family: var(--font-mono);
  font-size: 0.9em;
  font-style: normal;
  color: #FFD79A;
  background: rgba(255, 184, 77, 0.10);
  border: 1px dashed rgba(255, 196, 110, 0.55);
  border-radius: var(--r-xs);
  padding: 1px 7px;
  white-space: normal;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}
.placeholder::before { content: '✎ '; opacity: 0.7; }

/* A whole block to be supplied (e.g. full AGB text) */
.placeholder-block {
  margin-top: 22px;
  padding: 22px 24px;
  border-radius: var(--r-md);
  background: rgba(255, 184, 77, 0.06);
  border: 1px dashed rgba(255, 196, 110, 0.55);
  color: #FFD79A;
  font-family: var(--font-mono);
  font-size: 14px;
  line-height: 1.6;
}
.placeholder-block strong { color: #FFE3B8; }

/* ---------- Phone helper (never break) ---------------------------- */
.nowrap { white-space: nowrap; }

/* ---------- Footer cookie-settings trigger ------------------------ */
/* The footer "Cookie-Einstellungen" is a button rendered inline with
   the link list; style it so it visually matches the surrounding
   anchors in .ftr ul. */
.ftr ul .cookie-trigger {
  font: inherit;
  font-size: 14px;
  color: var(--text-on-dark-soft);
  background: none;
  border: 0;
  padding: 0;
  cursor: pointer;
  text-align: left;
  transition: color var(--t-fast);
}
.ftr ul .cookie-trigger:hover { color: var(--brand-glow); }

/* ---------- Cookie-Einstellungen dialog (injected by JS) ---------- */
.ja-cookie-overlay {
  position: fixed; inset: 0;
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  background: rgba(5, 11, 28, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: ja-cookie-fade 280ms var(--ease-out);
}
.ja-cookie-overlay[hidden] { display: none; }
@keyframes ja-cookie-fade { from { opacity: 0; } to { opacity: 1; } }

.ja-cookie-card {
  position: relative;
  width: 100%; max-width: 520px;
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  padding: clamp(24px, 4vw, 36px);
  border-radius: var(--r-xl);
  background: linear-gradient(155deg, rgba(17, 38, 74, 0.92) 0%, rgba(8, 19, 43, 0.94) 100%);
  border: 1px solid var(--glass-dark-border);
  box-shadow: var(--shadow-xl);
  color: var(--text-on-dark);
}
.ja-cookie-eyebrow {
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--brand-glow);
  margin-bottom: 10px;
}
.ja-cookie-card h2 {
  font-family: var(--font-display);
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 600; letter-spacing: -0.02em;
  color: var(--text-on-dark);
  margin-bottom: 12px;
}
.ja-cookie-card > p {
  font-size: 14.5px; line-height: 1.6;
  color: var(--text-on-dark-soft);
  margin-bottom: 20px;
}
.ja-cookie-card a { color: var(--brand-glow); text-decoration: underline; text-underline-offset: 3px; }
.ja-cookie-list { list-style: none; display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.ja-cookie-row {
  display: flex; gap: 12px; align-items: flex-start;
  padding: 14px 16px;
  border-radius: var(--r-md);
  background: rgba(127, 224, 255, 0.04);
  border: 1px solid var(--rule-on-dark);
  cursor: pointer;
}
.ja-cookie-row input { margin-top: 3px; accent-color: var(--brand); width: 16px; height: 16px; flex-shrink: 0; }
.ja-cookie-row strong { display: block; font-size: 14.5px; color: var(--text-on-dark); font-weight: 600; }
.ja-cookie-row small { display: block; font-size: 12.5px; color: var(--text-on-dark-mute); margin-top: 2px; line-height: 1.45; }
.ja-cookie-actions { display: flex; gap: 12px; flex-wrap: wrap; justify-content: flex-end; }
.ja-cookie-close {
  position: absolute; top: 14px; right: 16px;
  width: 32px; height: 32px;
  font-size: 22px; line-height: 1;
  color: var(--text-on-dark-mute);
  border-radius: var(--r-sm);
  transition: color var(--t-fast), background var(--t-fast);
}
.ja-cookie-close:hover { color: var(--text-on-dark); background: rgba(127, 224, 255, 0.08); }

/* ---------- Reduced motion ---------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  .subpage::before { display: none; }
  .ja-cookie-overlay { animation: none; }
}
