/* ============================================================
   Ratgeber / Blog — editorial article styling
   Warm magazine look: cream paper, navy ink, green accent,
   Fraunces display serif + Inter body. Mobile-first.
   ============================================================ */

:root {
  --display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --ink: var(--navy, #1a2d52);
  --paper: var(--cream-light, #f8f4e8);
}

/* ---- staggered load reveal ---- */
@keyframes hd-rise {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: no-preference) {
  .article-hero > *, .article-layout, .deals-widget, .related, .faq {
    animation: hd-rise 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
  }
  .article-layout { animation-delay: 0.06s; }
  .deals-widget   { animation-delay: 0.04s; }
}

/* ============================ HERO ============================ */
.article-hero {
  position: relative;
  background:
    radial-gradient(120% 140% at 85% -10%, rgba(122, 185, 74, 0.18), transparent 55%),
    radial-gradient(110% 120% at 0% 0%, rgba(26, 45, 82, 0.06), transparent 50%),
    var(--cream, #f0ead8);
  border-bottom: 1px solid var(--border);
  overflow: hidden;
}
.article-hero::after { /* subtle paw texture echo */
  content: "🐾";
  position: absolute; right: -0.15em; bottom: -0.35em;
  font-size: clamp(8rem, 22vw, 18rem); line-height: 1;
  opacity: 0.05; transform: rotate(-12deg); pointer-events: none;
}
.article-hero .container { position: relative; z-index: 1; padding-top: 28px; padding-bottom: 40px; }

.article-hero.has-image { color: #fff; }
.article-hero.has-image::before {
  content: ""; position: absolute; inset: 0;
  background-size: cover; background-position: center;
  background-image: var(--hero-img);
}
.article-hero.has-image::after { opacity: 0.12; color: #fff; }
.article-hero.has-image .hero-scrim {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15,27,54,0.45) 0%, rgba(15,27,54,0.78) 100%);
}
.article-hero.has-image h1,
.article-hero.has-image .article-lead { color: #fff; }
.article-hero.has-image .breadcrumbs,
.article-hero.has-image .breadcrumbs a,
.article-hero.has-image .article-meta { color: rgba(255,255,255,0.85); }

.article-hero h1 {
  font-family: var(--display);
  font-weight: 600;
  font-size: clamp(2rem, 5.5vw, 3.4rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0.35em 0 0.3em;
  max-width: 18ch;
}
.article-lead {
  font-size: clamp(1.05rem, 2.4vw, 1.3rem);
  line-height: 1.55;
  color: var(--text-muted);
  max-width: 56ch;
  margin: 0;
}
.article-meta {
  margin-top: 18px; font-size: 0.85rem; font-weight: 600;
  letter-spacing: 0.02em; color: var(--text-muted);
  display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
}
.article-meta .dot { width: 4px; height: 4px; border-radius: 50%; background: currentColor; opacity: 0.5; }

/* ========================= BREADCRUMBS ========================= */
.breadcrumbs {
  display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
  font-size: 0.82rem; font-weight: 600; color: var(--text-muted);
}
.breadcrumbs a { color: var(--text-muted); transition: color 0.15s; }
.breadcrumbs a:hover { color: var(--green-dark, #5e9436); }
.breadcrumbs .bc-sep { opacity: 0.5; }
.breadcrumbs [aria-current] { color: var(--ink); }
.article-hero.has-image .breadcrumbs [aria-current] { color: #fff; }

/* ====================== LAYOUT + TOC ====================== */
.article-layout {
  display: grid; grid-template-columns: 1fr; gap: 32px;
  padding-top: 40px; padding-bottom: 8px;
}
@media (min-width: 960px) {
  .article-layout { grid-template-columns: 240px minmax(0, 1fr); gap: 56px; }
}
.toc {
  font-size: 0.9rem;
  align-self: start;
}
@media (min-width: 960px) {
  .toc { position: sticky; top: 90px; }
}
.toc-title {
  font-weight: 700; font-size: 0.72rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--text-muted); margin: 0 0 12px;
}
.toc ol { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--border); }
.toc li { margin: 0; }
.toc a {
  display: block; padding: 7px 0 7px 16px; margin-left: -2px;
  border-left: 2px solid transparent; color: var(--text-muted);
  font-weight: 500; line-height: 1.35; transition: all 0.15s;
}
.toc a:hover { color: var(--ink); border-left-color: var(--green); }

/* ========================== PROSE ========================== */
.prose { max-width: 72ch; font-size: 1.075rem; line-height: 1.75; color: var(--text); }
.prose > * + * { margin-top: 1.15em; }
.prose h2 {
  font-family: var(--display); font-weight: 600;
  font-size: clamp(1.5rem, 3.2vw, 2rem); line-height: 1.2;
  margin-top: 1.9em; scroll-margin-top: 90px; letter-spacing: -0.01em;
}
.prose h2::before {
  content: ""; display: block; width: 44px; height: 4px; border-radius: 2px;
  background: linear-gradient(90deg, var(--green), var(--green-dark)); margin-bottom: 0.5em;
}
.prose h3 {
  font-family: var(--display); font-weight: 600;
  font-size: 1.28rem; margin-top: 1.6em; scroll-margin-top: 90px;
}
.prose p { margin: 0; }
.prose a {
  color: var(--green-dark, #5e9436); font-weight: 600;
  text-decoration: underline; text-decoration-color: rgba(122,185,74,0.4);
  text-underline-offset: 3px; transition: text-decoration-color 0.15s;
}
.prose a:hover { text-decoration-color: var(--green-dark); }
.prose ul, .prose ol { margin: 1.1em 0; padding-left: 0; list-style: none; }
.prose ul li, .prose ol li { position: relative; padding-left: 1.9em; margin: 0.55em 0; }
.prose ul li::before {
  content: "🐾"; position: absolute; left: 0; top: 0.05em; font-size: 0.9em;
}
.prose ol { counter-reset: hd-step; }
.prose ol li::before {
  counter-increment: hd-step; content: counter(hd-step);
  position: absolute; left: 0; top: 0.05em;
  width: 1.5em; height: 1.5em; border-radius: 50%;
  background: var(--ink); color: #fff; font-size: 0.75em; font-weight: 700;
  display: grid; place-items: center;
}
.prose strong { color: var(--ink); font-weight: 700; }
.prose blockquote {
  border-left: 4px solid var(--green); padding: 0.2em 0 0.2em 1.1em;
  margin: 1.4em 0; color: var(--text-muted); font-style: italic;
  font-family: var(--display); font-size: 1.15rem;
}
/* "Kurz gesagt" answer-first box (a blockquote whose first <strong> leads). */
.prose blockquote {
  background: linear-gradient(0deg, rgba(122,185,74,0.07), rgba(122,185,74,0.07));
  border-radius: 0 12px 12px 0; font-style: normal; color: var(--text);
}
.prose blockquote strong { color: var(--green-dark, #5e9436); }

/* Comparison tables */
.prose table {
  width: 100%; border-collapse: collapse; margin: 1.5em 0; font-size: 0.97rem;
  background: var(--white, #fff); border: 1px solid var(--border);
  border-radius: var(--radius, 16px); overflow: hidden; display: block; overflow-x: auto;
}
.prose thead { background: var(--navy, #1a2d52); }
.prose th {
  text-align: left; padding: 12px 14px; color: #fff; font-weight: 700;
  font-size: 0.82rem; letter-spacing: 0.02em; white-space: nowrap;
}
.prose td { padding: 11px 14px; border-top: 1px solid var(--border); vertical-align: top; }
.prose tbody tr:nth-child(even) { background: rgba(26,45,82,0.025); }
.prose td:first-child { font-weight: 600; color: var(--ink); }

/* ======================= DEALS WIDGET ======================= */
.deals-widget { margin: 48px 0; }
.deals-widget > h2 {
  font-family: var(--display); font-weight: 600; font-size: 1.6rem;
  display: flex; align-items: center; gap: 10px;
}
.deals-widget > h2::before { content: "🔥"; }
.dw-grid {
  display: grid; gap: 18px; margin-top: 20px;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.dw-state { color: var(--text-muted); grid-column: 1 / -1; padding: 8px 0; }
.dw-card {
  display: flex; flex-direction: column; background: var(--white, #fff);
  border: 1px solid var(--border); border-radius: var(--radius, 16px);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: transform 0.18s, box-shadow 0.18s;
}
.dw-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.dw-card img { width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #fff; padding: 12px; }
.dw-body { padding: 14px 14px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.dw-body h3 { font-size: 0.92rem; line-height: 1.35; font-weight: 600; color: var(--ink); margin: 0; }
.dw-price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.dw-price strong { font-size: 1.25rem; color: var(--ink); }
.dw-was { color: var(--text-muted); text-decoration: line-through; font-size: 0.9rem; }
.dw-pct {
  background: var(--green); color: #173404; font-weight: 800; font-size: 0.78rem;
  padding: 2px 7px; border-radius: 7px;
}
.dw-rating { font-size: 0.82rem; color: var(--text-muted); font-weight: 600; }
.dw-note { margin-top: 14px; font-size: 0.78rem; color: var(--text-muted); }

/* ========================= RELATED ========================= */
.related { margin: 48px 0; }
.related > h2 { font-family: var(--display); font-weight: 600; font-size: 1.5rem; }
.related ul {
  list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}
.related li { margin: 0; }
.related a {
  display: block; background: var(--white, #fff); border: 1px solid var(--border);
  border-radius: var(--radius, 16px); padding: 18px 20px; font-weight: 600; color: var(--ink);
  box-shadow: var(--shadow-sm); transition: transform 0.16s, box-shadow 0.16s, border-color 0.16s;
  position: relative;
}
.related a::after { content: "→"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%); color: var(--green-dark); transition: transform 0.16s; }
.related a:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: rgba(122,185,74,0.5); }
.related a:hover::after { transform: translate(4px, -50%); }

/* =========================== FAQ =========================== */
.faq { margin: 48px 0; max-width: 760px; }
.faq > h2 { font-family: var(--display); font-weight: 600; font-size: 1.6rem; }
.faq-item {
  border: 1px solid var(--border); border-radius: 14px; background: var(--white, #fff);
  margin-top: 12px; overflow: hidden;
}
.faq-item summary {
  cursor: pointer; list-style: none; padding: 18px 52px 18px 20px; position: relative;
  font-weight: 600; color: var(--ink); font-size: 1.02rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: "+"; position: absolute; right: 18px; top: 50%; transform: translateY(-50%);
  font-size: 1.5rem; font-weight: 400; color: var(--green-dark); transition: transform 0.2s;
}
.faq-item[open] summary::after { content: "−"; }
.faq-item[open] summary { color: var(--green-dark); }
.faq-item p { margin: 0; padding: 0 20px 20px; color: var(--text); line-height: 1.65; }

/* ===================== updated note ===================== */
.article .updated { color: var(--text-muted); font-size: 0.85rem; margin: 24px 0 56px; font-style: italic; }
