/* Ratgeber-Seiten (serverseitig gerendert) – nutzt Farben, Schriften, Navigation und Buttons aus /app/index.css */
.rg-body { background: var(--canvas); color: var(--ink); font-family: var(--font-body); margin: 0; }
.rg-skip { position: absolute; left: -9999px; top: 8px; z-index: 50; background: var(--ink); color: var(--white); padding: 10px 14px; border-radius: var(--r-s); }
.rg-skip:focus { left: 8px; }
.rg { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* Kopf */
.rg-hero { padding: clamp(32px, 6vw, 72px) 0 clamp(28px, 4vw, 44px); max-width: 860px; }
.rg-crumbs { font-size: var(--t-xs); color: var(--muted); margin-bottom: 18px; }
.rg-crumbs a { color: var(--muted); }
.rg-hero h1 { font-family: var(--font-display); font-size: clamp(2.1rem, 4.6vw, 3.6rem); line-height: 1.05; letter-spacing: -0.02em; margin: 0 0 18px; text-wrap: balance; }
.rg-lead { font-size: var(--t-lg); line-height: 1.5; color: var(--ink-soft); margin: 0 0 26px; max-width: 62ch; }
.rg-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.rg-hero__actions .btn { flex: none; }
.rg-btn-ghost { --bg: transparent; --fg: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.rg-meta { font-size: var(--t-xs); color: var(--muted); margin: 18px 0 0; }

/* Inhalt mit Inhaltsverzeichnis */
.rg-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: start; padding-bottom: 40px; }
.rg-toc { position: sticky; top: 88px; font-size: var(--t-sm); border-left: 2px solid var(--line); padding-left: 16px; }
.rg-toc__h { font-weight: 700; margin: 0 0 8px; }
.rg-toc ol { list-style: none; margin: 0 0 18px; padding: 0; display: grid; gap: 7px; }
.rg-toc a { color: var(--ink-soft); text-decoration: none; }
.rg-toc a:hover { color: var(--brand); text-decoration: underline; }
.rg-toc__cta { min-height: 40px; font-size: var(--t-xs); padding: 0 16px; }

.rg-content { max-width: 72ch; font-size: var(--t-md); line-height: 1.7; }
.rg-content--wide { max-width: 860px; padding-bottom: 56px; }
.rg-content h2 { font-family: var(--font-display); font-size: clamp(1.5rem, 2.6vw, 2rem); line-height: 1.15; letter-spacing: -0.01em; margin: 2.2em 0 0.6em; scroll-margin-top: 90px; text-wrap: balance; }
.rg-content h2:first-child { margin-top: 0; }
.rg-content h3 { font-size: var(--t-lg); line-height: 1.3; margin: 1.6em 0 0.4em; }
.rg-content p, .rg-content ul, .rg-content ol { margin: 0 0 1.1em; }
.rg-content li { margin-bottom: 0.4em; }
.rg-content a { color: var(--brand); text-underline-offset: 3px; }
.rg-content strong { color: var(--ink); }
.rg-content code { font-size: 0.9em; background: var(--tint-soft); padding: 2px 6px; border-radius: 6px; }
.rg-content blockquote { margin: 1.4em 0; padding: 14px 20px; border-left: 4px solid var(--accent); background: var(--paper); border-radius: 0 var(--r-s) var(--r-s) 0; }
.rg-content blockquote p:last-child { margin-bottom: 0; }
.rg-content table { width: 100%; border-collapse: collapse; margin: 0 0 1.4em; font-size: var(--t-sm); line-height: 1.5; display: block; overflow-x: auto; }
.rg-content th, .rg-content td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.rg-content th { background: var(--tint-soft); font-weight: 700; }

/* Testphasen-Box */
.rg-cta { display: flex; gap: 20px 28px; align-items: center; justify-content: space-between; flex-wrap: wrap; margin: 2.2em 0; padding: clamp(22px, 3vw, 32px);
  background: radial-gradient(ellipse 70% 120% at 100% 0%, #39c46f2e, transparent 60%), var(--ink); color: var(--tint); border-radius: var(--r-m); }
.rg-cta > div { flex: 1 1 320px; }
.rg-cta p { margin: 0; line-height: 1.55; font-size: var(--t-sm); }
.rg-cta .rg-cta__title { font-family: var(--font-display); font-size: var(--t-lg); color: var(--white); margin-bottom: 6px; line-height: 1.25; }
.rg-cta .btn { flex: none; }

/* Video: lädt erst bei Klick */
.rg-video { margin: 2.2em 0; }
.rg-video a { position: relative; display: block; border-radius: var(--r-m); overflow: hidden; background: var(--ink); aspect-ratio: 16 / 9; }
.rg-video img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s ease; }
.rg-video a:hover img { transform: scale(1.02); }
.rg-video__play { position: absolute; inset: 0; margin: auto; width: 76px; height: 76px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: var(--ink);
  box-shadow: 0 0 0 10px #d4af3740; }
.rg-video__len { position: absolute; right: 12px; bottom: 12px; background: #0b1a12cc; color: var(--white); font-size: var(--t-xs); padding: 3px 8px; border-radius: 6px; }
.rg-video__player { display: block; width: 100%; aspect-ratio: 16 / 9; border-radius: var(--r-m); background: var(--ink); }
.rg-video figcaption { font-size: var(--t-xs); color: var(--muted); margin-top: 8px; }
.rg-video a:focus-visible { box-shadow: var(--focus); outline: none; }

/* Übersicht + andere Systeme */
.rg-cards, .rg-more ul { list-style: none; margin: 0 0 40px; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.rg-cards a, .rg-more a { display: flex; flex-direction: column; gap: 6px; height: 100%; box-sizing: border-box; padding: 20px 22px; background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--r-m); color: var(--ink); text-decoration: none; transition: border-color 0.2s, transform 0.2s; }
.rg-cards a:hover, .rg-more a:hover { border-color: var(--brand-soft); transform: translateY(-2px); }
.rg-cards b, .rg-more b { font-family: var(--font-display); font-size: var(--t-lg); }
.rg-cards span, .rg-more span { font-size: var(--t-sm); color: var(--ink-soft); line-height: 1.5; }
.rg-cards i { font-style: normal; font-weight: 700; color: var(--brand); font-size: var(--t-sm); margin-top: auto; padding-top: 8px; }
.rg-more { border-top: 1px solid var(--line); padding-top: 36px; }
.rg-more h2 { font-family: var(--font-display); font-size: var(--t-xl); margin: 0 0 18px; }
/* Übersicht: Gruppen „Nach Shopsystem“ und „Themen“ */
.rg-group__h { font-family: var(--font-display); font-size: var(--t-xl); margin: 0 0 18px; }
.rg-footer { margin-top: 24px; padding-bottom: 32px; }
.rg-footer .footer__cols { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.rg-footer .footer__cols a { min-height: 36px; }
.rg-footer .footer__base { max-width: var(--max); margin: 32px auto 0; }

@media (max-width: 900px) {
  .rg-layout { grid-template-columns: minmax(0, 1fr); }
  .rg-toc { position: static; border-left: 0; padding: 16px 18px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r-m); }
  .rg-toc__cta { display: none; }
}
@media (max-width: 1100px) {
  .rg-footer .footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 760px) {
  .rg-footer .footer__cols { grid-template-columns: 1fr; }
  .rg-footer .footer__cols a { min-height: 44px; }
}
@media (max-width: 640px) {
  .rg-hero__actions .btn, .rg-cta .btn { width: 100%; }
  .rg-video__play { width: 60px; height: 60px; }
}
@media (prefers-reduced-motion: reduce) {
  .rg-video img, .rg-cards a, .rg-more a { transition: none; }
}

.rg-body .nav__home { text-decoration: none; }

/* Video im Hochformat auf dem Handy */
.rg-video picture { display: block; width: 100%; height: 100%; }
.rg-video__len--mob { display: none; }
@media (max-width: 700px) {
  .rg-video a, .rg-video__player--mob { aspect-ratio: 9 / 16; max-height: 82vh; width: auto; max-width: 100%; margin: 0 auto; }
  .rg-video__len--desk { display: none; }
  .rg-video__len--mob { display: block; }
  .rg-video figcaption { text-align: center; }
}

/* Rechtstexte */
.rg-legal address { font-style: normal; margin: 0 0 1.1em; }
.rg-legal table th[scope="row"] { width: 28%; }
.rg-toc a[aria-current="page"] { color: var(--ink); font-weight: 700; }

