:root {
  --brand: #1f4d5c; /* wird pro Seite via head.ejs überschrieben */
  --brand-600: color-mix(in srgb, var(--brand) 82%, black);
  --brand-050: color-mix(in srgb, var(--brand) 8%, white);
  --ink: #1a1f24;
  --muted: #5b6670;
  --line: #e3e8eb;
  --bg: #ffffff;
  --bg-soft: #f7f9fa;
  --radius: 12px;
  --maxw: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
}
h1, h2, h3 { line-height: 1.25; color: var(--ink); }
h1 { font-size: 2rem; margin: 0 0 .5rem; }
h2 { font-size: 1.4rem; margin: 2rem 0 .75rem; }
h3 { font-size: 1.1rem; margin: 0 0 .4rem; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
p { margin: 0 0 1rem; }
img { max-width: 100%; height: auto; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 1.25rem; }
.muted { color: var(--muted); }
.meta { color: var(--muted); font-size: .9rem; }

.skip-link {
  position: absolute; left: -999px; top: 0; background: var(--brand); color: #fff;
  padding: .5rem 1rem; z-index: 100;
}
.skip-link:focus { left: 0; }

/* Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 20; }
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: 1rem; }
.brand { display: inline-flex; align-items: center; gap: .55rem; font-weight: 700; color: var(--ink); font-size: 1.1rem; }
.brand:hover { text-decoration: none; }
.main-nav ul { display: flex; gap: 1.25rem; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; }
.main-nav a { color: var(--ink); font-weight: 500; font-size: .98rem; }
.main-nav a[aria-current="page"] { color: var(--brand); }

/* Hero */
.hero { padding: 3rem 0 2rem; }
.hero h1 { font-size: 2.4rem; max-width: 18ch; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 62ch; }
.hero-actions { display: flex; gap: .75rem; margin-top: 1.5rem; flex-wrap: wrap; }

.btn {
  display: inline-block; background: var(--brand); color: #fff; padding: .7rem 1.25rem;
  border-radius: 999px; font-weight: 600; border: 1px solid var(--brand);
}
.btn:hover { background: var(--brand-600); text-decoration: none; }
.btn-ghost { background: transparent; color: var(--brand); }
.btn-ghost:hover { background: var(--brand-050); }

/* Cards */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 1rem; margin: 1rem 0 2rem; }
.card {
  display: block; padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--bg); color: var(--ink); transition: box-shadow .15s, transform .15s;
}
.card:hover { text-decoration: none; box-shadow: 0 6px 20px rgba(0,0,0,.07); transform: translateY(-2px); }
.card h2, .card h3 { color: var(--brand); }

/* Breadcrumbs */
.breadcrumbs { margin: 1.25rem 0 .5rem; font-size: .9rem; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: .35rem; list-style: none; margin: 0; padding: 0; color: var(--muted); }
.breadcrumbs li:not(:last-child)::after { content: "›"; margin-left: .35rem; color: var(--muted); }

.page-head { margin: 1rem 0 1.5rem; }
.tag { display: inline-block; background: var(--brand-050); color: var(--brand); padding: .2rem .7rem; border-radius: 999px; font-size: .8rem; font-weight: 600; margin-bottom: .5rem; }
.tag:hover { text-decoration: none; }

/* Prose */
.prose { max-width: 72ch; }
.prose h2 { border-top: 1px solid var(--line); padding-top: 1.25rem; }
.checklist { list-style: none; padding: 0; }
.checklist li { position: relative; padding-left: 1.75rem; margin-bottom: .5rem; }
.checklist li::before { content: "✓"; position: absolute; left: 0; color: var(--brand); font-weight: 700; }
.steps { padding-left: 1.25rem; }
.steps li { margin-bottom: .5rem; }

/* Tables */
.table-wrap { overflow-x: auto; margin: 1rem 0 1.5rem; }
table { border-collapse: collapse; width: 100%; font-size: .96rem; }
th, td { text-align: left; padding: .65rem .8rem; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: var(--bg-soft); font-weight: 600; }

/* Callouts */
.callout { border-left: 4px solid var(--brand); background: var(--bg-soft); padding: 1rem 1.15rem; border-radius: 0 var(--radius) var(--radius) 0; margin: 1.25rem 0; }
.callout p { margin: 0; }
.callout-title { display: block; margin-bottom: .25rem; }
.callout-info { border-color: #2b7bb9; background: #eef5fb; }
.callout-tip { border-color: #2e9e6b; background: #ecf8f1; }
.callout-warning { border-color: #d98324; background: #fdf3e7; }

/* Partner (gekennzeichnete Werbung) */
.partner { border: 1px dashed #c7ced3; border-radius: var(--radius); padding: 1.25rem; margin: 2rem 0; background: #fbfcfd; }
.partner-label { display: inline-block; font-size: .72rem; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); background: #eef1f3; padding: .2rem .55rem; border-radius: 4px; margin-bottom: .6rem; }
.partner p { margin: 0 0 .9rem; }
.partner .link-list { margin: .2rem 0 0; padding-left: 1.15rem; }
.partner .link-list li { margin-bottom: .35rem; }
.partner .link-list a { font-weight: 500; }

/* FAQ */
.faq details { border: 1px solid var(--line); border-radius: var(--radius); padding: .25rem 1rem; margin-bottom: .6rem; }
.faq summary { cursor: pointer; font-weight: 600; padding: .75rem 0; }
.faq summary::-webkit-details-marker { color: var(--brand); }
.faq details[open] summary { border-bottom: 1px solid var(--line); }
.faq details p { padding-top: .75rem; }

/* Glossary */
.glossary dt { font-weight: 700; color: var(--brand); margin-top: 1rem; }
.glossary dd { margin: .25rem 0 0; }

.related { border-top: 1px solid var(--line); margin-top: 2.5rem; padding-top: 1rem; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); margin-top: 3rem; padding: 2.5rem 0 1.5rem; background: var(--bg-soft); }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 2rem; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: .4rem; }
.footer-legal { margin-top: 2rem; padding-top: 1rem; border-top: 1px solid var(--line); font-size: .88rem; }

@media (max-width: 720px) {
  body { font-size: 16px; }
  .hero h1 { font-size: 1.9rem; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.25rem; }
  .main-nav ul { gap: .9rem; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
