/* =============================================
   SCHULDENEX – Clean Design System
   Mobile-first, modern, accessible
   ============================================= */

/* --- Design Tokens --- */
:root {
  --primary: #0f2b5b;
  --primary-light: #e8edf5;
  --primary-hover: #183d7a;
  --accent: #2563eb;
  --accent-light: #dbeafe;
  --accent-hover: #1d4ed8;
  --secondary: #2563eb;          /* Sekundärfarbe = Link-Blau (wie --accent) */
  --secondary-light: #dbeafe;
  --secondary-hover: #1d4ed8;
  --highlight: #f5ff00;
  --success: #16a34a;
  --success-light: #dcfce7;
  --danger: #dc2626;
  --danger-light: #fef2f2;
  --warning: #f59e0b;

  --text: #1e293b;
  --text-secondary: #475569;
  --text-muted: #94a3b8;
  --bg: #ffffff;
  --bg-subtle: #f8fafc;
  --bg-soft: #f1f5f9;             /* sanfte 2. Ebene */
  --surface: #f1f5f9;
  --card: #ffffff;
  --border: #e2e8f0;
  --border-soft: #eef2f7;
  --border-focus: var(--accent);

  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-pill: 999px;
  --shadow-sm: 0 1px 2px rgba(0,0,0,.05);
  --shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.04);
  --shadow-lg: 0 4px 12px rgba(0,0,0,.1);
  --shadow-hover: 0 6px 16px rgba(0,0,0,.12);
  --transition: .15s ease;
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html {
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  min-height: 100%;
}
body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  background: #ffffff;
  background-attachment: fixed;
}
body .page { background: transparent; }
.container { background: transparent; }

/* --- Typography --- */
h1, h2, h3, h4, h5, h6 {
  margin: 0 0 .5em;
  font-weight: 400;
  line-height: 1.25;
  color: var(--primary);
}
h1, .h1 { font-size: 1.75rem; font-weight: 400; color: var(--primary); }
h2, .h2 { font-size: 1.375rem; font-weight: 400; color: var(--primary); }
h3 { font-size: 1.125rem; font-weight: 400; }
p { margin: 0 0 1em; }
b, strong { font-weight: 600; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.small { font-size: .8125rem; color: var(--text-secondary); }

/* --- Layout --- */
.page { flex: 1 0 auto; }
.container {
  max-width: 880px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}
.home-container { max-width: 960px; }
.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

/* --- Fixed Header --- */
.header-fixed {
  position: fixed;
  left: 0; right: 0; top: 0;
  z-index: 200;
  background: #fff;
  border-bottom: 1px solid var(--border);
}
body.has-fixed-header { padding-top: 96px; }
body.has-fixed-header.app { padding-top: 132px; }

.nav {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: .5rem 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
}
.nav-brand { display: flex; align-items: center; flex: 1; justify-content: center; }
.nav-brand a { display: flex; align-items: center; }
.nav-brand img { height: auto; max-height: 96px; width: 100%; max-width: 520px; display: block; image-rendering: -webkit-optimize-contrast; }

/* Login link top right */
.nav-auth {
  position: fixed;
  right: 1rem;
  top: 96px;
  z-index: 199;
}

/* authbar removed – menu bar now below header via .app-menu-bar */

/* Icon links (Login, Registrieren) */
.icon-link {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .5rem .75rem;
  border-radius: var(--radius);
  color: var(--accent);
  font-size: .875rem;
  font-weight: 500;
  text-decoration: none;
  transition: background var(--transition);
  white-space: nowrap;
}
.icon-link:hover {
  background: var(--surface);
  text-decoration: none;
}
.icon-link svg { width: 18px; height: 18px; flex-shrink: 0; }
.icon-link .label { display: none; }
.icon-link.login-link svg { width: 20px; height: 20px; }

/* Menu toggle (app) */
.menu-toggle {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .5rem .75rem;
  border: 0;
  background: 0;
  color: var(--accent);
  font-size: .875rem;
  font-weight: 500;
  cursor: pointer;
  border-radius: var(--radius);
  transition: background var(--transition);
}
.menu-toggle:hover { background: var(--surface); }
.menu-toggle svg { width: 20px; height: 20px; }
.menu-toggle .label { display: none; }

/* --- Hero Section --- */
/* Hero verhält sich wie ein normaler Abschnitt (section-divider):
   gleicher linker Rand (0), gleicher Abstand zum nächsten Abschnitt.
   Bottom-Abstand = 2rem, damit zusammen mit section-divider(top:5rem)
   derselbe Gesamt-Abstand (7rem) entsteht wie zwischen den übrigen
   Abschnitten (features/steps/pricing bottom=2rem + section-divider top=5rem). */
.hero {
  position: relative;
  background: transparent;
  border: 0;
  border-radius: 0;
  padding: 0;
  margin: 2rem 0 0;
  text-align: left;
}
.hero, .hero .h1, .hero .lead, .hero .subtitle { padding-left: 0; margin-left: 0; }
/* Link "So funktioniert's" ohne Unterstrich (auch im :hover) */
.hero .subtitle a.sx-link-plain,
.sx-link-plain { text-decoration: none; }
.sx-link-plain:hover { text-decoration: none; }
.hero .hero-eyebrow {
  display: inline-block;
  font-size: .8125rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--secondary);
  background: transparent;
  border: 0;
  padding: 0;
  margin-bottom: .5rem;
}
.hero .h1 {
  font-size: 1.875rem;
  font-weight: 400;
  color: var(--primary);
  margin-bottom: .75rem;
  letter-spacing: -0.015em;
}
.hero .lead {
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--primary);
  font-weight: 400;
  max-width: 620px;
  margin-bottom: .75rem;
}
.hero .subtitle {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 640px;
}
.hero-cta {
  margin-top: 1.5rem;
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
}
/* Header slogan removed – logo fills header fully */
.hero-cta .btn { font-size: 1rem; }

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .375rem;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-size: .9375rem;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: all var(--transition);
  line-height: 1.4;
  white-space: nowrap;
}
.btn:hover {
  border: 0;
  background: transparent;
  text-decoration: underline;
}
.btn.small {
  padding: .375rem .75rem;
  font-size: .8125rem;
}
.btn.primary {
  background: transparent;
  border: 0;
  color: var(--accent);
}
.btn.primary:hover {
  background: transparent;
  text-decoration: underline;
}
.btn.outline {
  border: 0;
  color: var(--accent);
  font-weight: 600;
}
.btn.outline:hover {
  background: transparent; text-decoration: underline;
}
.btn:disabled {
  opacity: .45;
  pointer-events: none;
}
.btn.has-icon { gap: .5rem; }
.btn-icon { display: inline-flex; align-items: center; pointer-events: none; }

/* Back button */
.btn.back {
  color: var(--accent);
}
.btn.back:hover { background: transparent; text-decoration: underline; }
.btn.back .sx-ico { width: 18px; height: 18px; }

/* CTA link style */
.sx-cta-link {
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: .25rem;
}
.sx-cta-link:hover { text-decoration: underline; }
.sx-cta-link-lg { font-size: 1.0625rem; }

/* --- Cards --- */
.card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--card);
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
}
.card + .card { margin-top: 1rem; }
.card h3 { margin: 0 0 .5rem; }

/* --- Feature Cards (Landing) --- */
.features {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin: 1.5rem 0;
}
.feature-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  background: #fff;
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition);
}
.feature-card:hover {
  box-shadow: var(--shadow-hover);
}
.feature-card .feature-head {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: .75rem;
}
.feature-card .feature-icon {
  width: 48px; height: 48px;
  border-radius: var(--radius);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--primary);
}
.feature-card .feature-icon svg { width: 24px; height: 24px; }
.feature-card h3 { font-size: 1.125rem; margin-bottom: 0; }
.feature-card p { color: var(--text-secondary); font-size: 1rem; margin: 0; line-height: 1.6; }

/* --- Steps Overview (Landing) --- */
.steps-overview {
  display: grid;
  grid-template-columns: 1fr;
  gap: .75rem;
  margin: 1.5rem 0;
  counter-reset: step;
}
.step-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  counter-increment: step;
  transition: box-shadow var(--transition);
}
.step-item:hover {
  box-shadow: var(--shadow-hover);
}
.step-number {
  flex-shrink: 0;
  color: var(--primary);
  font-weight: 400;
  font-size: 2rem;
  line-height: 1;
  min-width: 24px;
  padding-top: 2px;
}
.step-item h4 { margin: 0 0 .25rem; font-size: 1.0625rem; font-weight: 400; }
.step-item p { margin: 0; font-size: 1rem; color: var(--text-secondary); line-height: 1.5; }

/* --- Pricing Card (Landing) --- */
.pricing-card {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: left;
  background: #fff;
  margin: 1.5rem 0;
  box-shadow: var(--shadow-sm);
}
.pricing-card .price {
  font-size: 1.75rem;
  font-weight: 500;
  color: var(--accent);
  line-height: 1;
}
.pricing-card .price-period {
  font-size: 1rem;
  color: var(--text-secondary);
  font-weight: 400;
}
.pricing-card .price-features {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0;
  text-align: left;
}
.pricing-card .price-features li {
  padding: .5rem 0;
  padding-left: 1.75rem;
  position: relative;
  color: var(--text-secondary);
  font-size: 1rem;
}
.pricing-card .price-features li::before {
  content: "";
  position: absolute;
  left: 0; top: .3rem;
  width: 18px; height: 18px;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' stroke='%230f2b5b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E") no-repeat center/contain;
  border: none;
  transform: none;
}

/* --- FAQ --- */
.faq {
  margin: .5rem 0 2rem;
  background: #ffffff;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(15,23,42,.04), 0 4px 14px rgba(15,23,42,.05);
  padding: .25rem 1.25rem;
}
.faq details {
  border-bottom: 1px solid var(--border-soft);
}
.faq details:last-of-type { border-bottom: 0; }
.faq details:last-of-type .answer { padding-bottom: 0; }
.faq details:last-of-type .answer > *:last-child { margin-bottom: 0; }
/* Weniger Abstand am unteren Rand jeder FAQ-Sektion */
.sx-static > .sx-accordion-body { padding-bottom: .5rem; }
.faq details + details { margin-top: 0; }
.faq summary {
  cursor: pointer;
  padding: 1rem 2rem 1rem 0;
  font-size: 1rem;
  font-weight: 400;
  color: var(--text);
  list-style: none;
  position: relative;
  line-height: 1.5;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  font-size: 1.25rem;
  font-weight: 300;
  color: var(--text-muted);
  transition: transform var(--transition);
}
details[open] > .faq summary::after,
.faq details[open] > summary::after {
  content: "\2212";
}
.faq .answer {
  padding: 0 0 1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  font-size: 1rem;
}
.faq .answer ol, .faq .answer ul {
  margin: .5rem 0 .5rem 1.25rem;
}

/* --- Accordion (Wizard) --- */
.sx-accordion {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: #fff;
  margin-top: 1rem;
}
/* Rounded corners without overflow:hidden (which kills position:sticky) */
.sx-accordion > .sx-accordion-summary:first-child { border-radius: var(--radius-lg) var(--radius-lg) 0 0; }
.sx-accordion:not([open]) > .sx-accordion-summary:first-child { border-radius: var(--radius-lg); }
.sx-accordion-summary {
  list-style: none;
  cursor: pointer;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
  background: var(--surface, #f1f5f9);
}
.sx-accordion-summary::-webkit-details-marker { display: none; }
.sx-accordion-summary::after {
  content: "\203A";
  transform: rotate(90deg);
  opacity: .5;
  font-size: 1.25rem;
  line-height: 1;
  flex-shrink: 0;
  margin-left: .5rem;
}
details[open] > .sx-accordion-summary::after { transform: rotate(-90deg); }
.sx-accordion-body { padding: 0 1.25rem 1.25rem; display: flow-root; }

/* Kein Abstand zwischen Accordion-Summary und Tabelle */
.sx-accordion-body .table { margin-top: 0; }

/* Grey header bar for table columns inside accordions ("Unterbalken") */
.sx-accordion-body .table thead th {
  background: #f7f8fa;
  position: sticky;
  top: 0;
  z-index: 1;
}
/* Tabelle in Accordion volle Breite (ragt über Padding hinaus) */
.sx-accordion-body .table-scroll-hint {
  margin-left: -1.25rem;
  margin-right: -1.25rem;
  max-width: none;
  width: calc(100% + 2.5rem);
  box-sizing: content-box;
}

/* Hinweis-Box: identisch mit sx-accordion (gleicher Balken) */
details.sx-hint-bar {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: #fff;
  margin-top: 1rem;
}
details.sx-hint-bar > summary {
  list-style: none;
  cursor: pointer;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
  background: var(--surface, #f1f5f9);
  border-radius: var(--radius-lg) var(--radius-lg) 0 0;
}
details.sx-hint-bar:not([open]) > summary { border-radius: var(--radius-lg); }
details.sx-hint-bar > summary .section-title { margin: 0; }
details.sx-hint-bar > summary::-webkit-details-marker { display: none; }
details.sx-hint-bar > summary::after {
  content: "\203A";
  transform: rotate(90deg);
  opacity: .5;
  font-size: 1.25rem;
  line-height: 1;
  flex-shrink: 0;
  margin-left: .5rem;
}
details[open].sx-hint-bar > summary::after { transform: rotate(-90deg); }
/* hint-bar body: gleiche Schriftgröße wie normale accordion-body */

.sx-accordion-footer {
  margin-top: 1rem;
  display: flex;
  justify-content: flex-end;
}

/* Static accordion (always open) */
details.sx-static > .sx-accordion-summary { cursor: default; pointer-events: none; }
details.sx-static > .sx-accordion-summary::after { display: none; }

/* Disabled accordion summary (cannot be opened until precondition is met) */
.sx-accordion-summary.sx-disabled {
  cursor: not-allowed;
  opacity: .55;
}
.sx-accordion-summary.sx-disabled::after { opacity: .3; }

/* Schritt 6: Ergebnis-Text (gleiche Textgröße wie andere Boxen) */
.sx-result-text { font-size: .875rem; line-height: 1.6; color: var(--text-secondary); }
.sx-result-text h2 { font-size: 1rem; }
.sx-result-text p { margin: 0 0 .75em; }
.sx-result-text ul { margin: 0 0 .75em; padding-left: 18px; }
.sx-result-text li { margin-bottom: .375em; }

/* Home accordion */
.home-accordion { margin-top: 0; border-radius: 0; border-left: 0; border-right: 0; border-top: 0; }
.home-accordion .sx-accordion-summary { padding: 1.25rem 0; }
.home-accordion .sx-accordion-summary .h2 { font-size: 1.25rem; }
.home-accordion .sx-accordion-body { padding: 0 0 1.5rem; }
.home-accordion .sx-accordion-body ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.home-accordion .sx-accordion-body li {
  padding: .5rem 0 .5rem 1.75rem;
  position: relative;
  color: var(--text-secondary);
  line-height: 1.6;
}
.home-accordion .sx-accordion-body li::before {
  content: "";
  position: absolute;
  left: 0; top: .8rem;
  width: 12px; height: 7px;
  border-left: 2.5px solid var(--success);
  border-bottom: 2.5px solid var(--success);
  transform: rotate(-45deg);
}

/* --- Forms --- */
.form { max-width: 720px; }
label {
  display: block;
  font-size: .875rem;
  font-weight: 600;
  margin: .875rem 0 .375rem;
  color: var(--text);
}
input, select, textarea {
  width: 100%;
  padding: .625rem .75rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  font: inherit;
  font-size: 1rem;
  color: var(--text);
  background: #fff;
  transition: border-color var(--transition), box-shadow var(--transition);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}
textarea { min-height: 120px; resize: vertical; }
select {
  appearance: auto;
  -webkit-appearance: auto;
  background-color: #fff;
}

/* Auth form */
.auth-form label { font-size: .9375rem; font-weight: 500; }

/* --- Segmented Control --- */
.sx-segment {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}
.sx-segment input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.sx-segment label {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .25rem .5rem;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-size: .875rem;
  font-weight: 500;
  line-height: 1;
  user-select: none;
  margin: 0;
  transition: all var(--transition);
  text-decoration: none;
}
.sx-segment label:hover { color: var(--accent); text-decoration: underline; }
.sx-segment input[type="radio"]:checked + label {
  border: 0;
  color: var(--accent);
  background: transparent;
  font-weight: 600;
}
.sx-segment.small label { padding: .375rem .625rem; font-size: .75rem; }
.sx-segment.small { flex-wrap: wrap; gap: .375rem; }
/* Vertikale Variante – Optionen untereinander */
.sx-segment.sx-segment-vertical {
  flex-direction: column;
  align-items: flex-start;
  gap: .25rem;
}
.sx-segment.sx-segment-vertical label {
  justify-content: flex-start;
  padding: .25rem 0;
  white-space: nowrap;
}

/* Form sub-headings ("Unterbalken") – visuelle Gliederung.
   position:relative zur sx-accordion-body, dann absolut links/rechts stretchen. */
.sx-accordion-body { position: relative; }
.sx-form-heading {
  font-size: .8125rem;
  font-weight: 600;
  letter-spacing: .02em;
  color: var(--primary);
  background: #f7f8fa;
  padding: .5rem 1.25rem;
  margin-top: 0;
  margin-bottom: 10px;
  /* Volle Breite: ragt über den max-width:720px der .form hinaus */
  margin-left: -1.25rem;
  margin-right: -1.25rem;
  width: auto;
  box-sizing: border-box;
}
/* Kein Abstand zwischen Oberbalken und erstem Unterbalken */
.sx-form-heading:first-child { margin-top: 0; }
p + .sx-form-heading { margin-top: 0; }
#sx_claims_list { margin-top: 0; }
.sx-creditor-block:first-child > .sx-form-heading:first-child { margin-top: 0; }

/* Formulare in Accordion-Body dürfen Unterbalken nicht einschränken */
.sx-accordion-body > form,
.sx-accordion-body > form.form {
  max-width: none;
}

/* Step 4: Creditor block layout */
.sx-creditor-block {
  margin-bottom: 0;
}
/* Kein weißer Abstand zwischen den Gläubiger-Headings */
.sx-creditor-block > .sx-form-heading {
  margin-bottom: 0;
}
.sx-unknown-label {
  color: var(--text-secondary, #475569);
  user-select: none;
}
.sx-unknown-label input[type="checkbox"] {
  accent-color: var(--accent, #2563eb);
  width: 16px;
  height: 16px;
  cursor: pointer;
}
/* Claim fields row: inline grid */
.sx-claim-fields {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr auto auto;
  gap: 8px;
  align-items: end;
  padding: 4px 0 8px;
}
.sx-claim-fields input {
  font-size: .8125rem;
  padding: .5rem .625rem;
}
.sx-claim-field { min-width: 0; }
.sx-field-label {
  display: block;
  font-size: .6875rem;
  color: var(--text-muted);
  margin-bottom: 2px;
  white-space: nowrap;
}
.sx-claim-field input {
  width: 100%;
}
.sx-claim-total {
  font-size: .8125rem;
  padding-top: 1rem;
  white-space: nowrap;
}
.sx-claim-del-wrap {
  padding-top: .85rem;
}
.sx-claim-add-row {
  padding: 2px 0 6px;
}
.sx-form-group {
  padding-bottom: 4px;
  margin-bottom: 6px;
}

/* Anrede-Segment: exakt gleiche Höhe wie benachbarte Input-Felder */
.sx-row-person > div:first-child {
  display: flex;
  flex-direction: column;
}
.sx-segment.sx-segment-anrede {
  flex: 1;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: .75rem .5rem;
  background: #fff;
  min-height: 42px;
  box-sizing: border-box;
}
.sx-segment.sx-segment-anrede label {
  padding: 0 .5rem;
  font-size: .8125rem;
  line-height: 1.6;
  margin: 0;
}

/* Disabled Button: Grey-Variante (z.B. E-Mail senden ohne Adresse) */
.btn.primary[disabled]:not(.btn-keep-color),
.btn.primary:disabled:not(.btn-keep-color) {
  opacity: .45;
  cursor: not-allowed;
  pointer-events: none;
}
/* Komplett ausgegraut – nur für Aktions-Buttons ohne E-Mail */
.btn-grey-disabled[disabled],
.btn-grey-disabled:disabled {
  opacity: .55;
  cursor: not-allowed;
  pointer-events: none;
  background: transparent !important;
  color: #9ca3af !important;
  border-color: transparent !important;
  box-shadow: none !important;
}

/* --- Alerts --- */
.notice { border: 1px solid var(--border); background: var(--surface, #f1f5f9); color: var(--text); padding: .75rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: .8125rem; line-height: 1.6; }
.ok     { border: 1px solid #bbf7d0; background: #f0fdf4; color: #166534; padding: .75rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; }
.err    { border: none; background: none; color: #dc2626; padding: 0 0 .5rem; margin-bottom: .5rem; font-size: .875rem; }
.notice.white { border-color: var(--border); background: #fff; color: var(--accent); }
.notice.white strong { color: var(--accent); }
.field-err { margin-top: .25rem; font-size: .8125rem; color: #991b1b; }

/* --- Tables --- */
.table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-top: .625rem;
}
.table th, .table td {
  padding: .625rem;
  border-bottom: 1px solid var(--border);
  text-align: left;
  font-size: .875rem;
  vertical-align: top;
}
.table th { color: var(--text-secondary); font-weight: 600; }

/* --- Badge --- */
.badge {
  display: inline-block;
  padding: .25rem .625rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border);
  font-size: .75rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* --- Progress --- */
.progress-bar {
  height: 8px;
  background: var(--surface);
  border-radius: var(--radius-pill);
  overflow: hidden;
  border: 1px solid var(--border);
}
.progress-bar-fill {
  height: 100%;
  background: var(--primary);
  border-radius: var(--radius-pill);
  transition: width .3s ease;
}

/* --- Footer --- */
.footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
  padding: 1.25rem 1.5rem;
  background: var(--primary);
  color: #fff;
  font-size: .8125rem;
}
.footer a { color: #fff; }
.footer a:hover { color: #fff; text-decoration: underline; }
.footer-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .75rem;
  flex-wrap: wrap;
}
.footer-sep { color: #fff; opacity: .7; }
.footer-copy { color: #fff; opacity: 1; }

/* Footer social media row - removed */
.footer-social { display: none; }

/* Content back link (legal pages - shown in page content, not footer) */
.content-back-link {
  display: block;
  text-align: center;
  margin: 2rem 0 0;
  font-size: .9375rem;
}
.content-back-link a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}
.content-back-link a:hover {
  text-decoration: underline;
}

/* --- SVG Icons --- */
.sx-ico { width: 20px; height: 20px; flex-shrink: 0; }

/* --- Step Navigation --- */
.stepnav {
  display: flex;
  flex-direction: column;
  gap: .5rem;
  margin: .875rem 0;
}
.stepnav a, .stepnav span {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .625rem .75rem;
  border-radius: var(--radius);
  font-size: 1rem;
  font-weight: 400;
  text-decoration: none;
  line-height: 1.3;
  transition: all var(--transition);
}
.stepnav a {
  color: var(--primary);
  background: #fff;
  border: 1px solid transparent;
}
.stepnav a:hover {
  background: var(--primary-light);
  text-decoration: none;
}
.stepnav a.current {
  background: var(--primary);
  color: #fff;
  font-weight: 400;
}
.stepnav a.current .stepicon { color: #fff; }
.stepnav a.done { color: var(--primary); }
.stepnav span.disabled {
  color: var(--text-muted);
  cursor: default;
  pointer-events: none;
}
.stepnav .stepicon {
  width: 16px; height: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: currentColor;
}
.stepnav .stepicon svg { stroke: currentColor; }
.stepnav .stepicon.placeholder { width: 16px; height: 16px; visibility: hidden; }

/* --- Side Drawer (App Menu) --- */
.side-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
  z-index: 400;
}
.side-backdrop.open { opacity: 1; pointer-events: auto; }

.side-drawer {
  position: fixed;
  top: 0; right: 0;
  height: 100%;
  width: min(320px, 85vw);
  background: #fff;
  border-left: 1px solid var(--border);
  transform: translateX(102%);
  transition: transform .22s ease;
  z-index: 450;
  display: flex;
  flex-direction: column;
  will-change: transform;
  box-shadow: -4px 0 20px rgba(0,0,0,.1);
}
.side-drawer.open { transform: translateX(0); }
.side-drawer.dragging { transition: none; }

.side-drawer .side-inner {
  flex: 1 1 auto;
  padding: 1rem 1rem 1.5rem;
  overflow-y: auto;
}
.side-drawer .side-logo {
  display: flex;
  justify-content: center;
  margin: .5rem 0 1rem;
}
.side-drawer .side-logo img {
  width: 100%;
  max-width: 100%;
  height: auto;
  display: block;
  border-radius: var(--radius-sm);
}

.side-bottom {
  padding: 1rem;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: .5rem;
}
.side-bottom-link {
  display: block;
  color: var(--primary);
  text-decoration: none;
  font-size: 1rem;
  padding: .375rem 0;
  font-weight: 400;
}
.side-bottom-link:hover { color: var(--accent); text-decoration: none; }
.side-logout {
  display: flex;
  align-items: center;
  gap: .5rem;
  color: var(--accent);
  text-decoration: none;
  font-weight: 400;
  font-size: 1rem;
  padding: .5rem 0;
}
.side-logout:hover { text-decoration: none; opacity: .85; }
.side-logout .sx-ico { color: var(--accent); }

/* Side drawer step nav */
.side-drawer .stepnav a,
.side-drawer .stepnav span {
  padding: .5rem 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  font-size: 1rem;
  font-weight: 400;
}
.side-drawer .stepnav a:hover {
  background: transparent;
  text-decoration: none;
  color: var(--accent);
}
.side-drawer .stepnav a:hover .stepicon { color: var(--accent); }
.side-drawer .stepnav a.current {
  background: transparent;
  color: var(--accent);
  font-weight: 400;
}
.side-drawer .stepnav a.current .stepicon { color: var(--accent); }
.side-drawer .stepnav .done { background: transparent; }

/* --- App Header (minimal) --- */
.header-fixed.app .nav { justify-content: center; }
.header-fixed.app .nav-brand img { height: auto; max-height: 96px; width: 100%; max-width: 520px; image-rendering: -webkit-optimize-contrast; }

/* Menu bar below app header */
.app-menu-bar {
  position: fixed;
  top: 96px; /* below header-fixed */
  right: 0;
  z-index: 99;
  padding: .375rem .75rem;
}
.app-menu-bar .menu-toggle {
  background: transparent;
  border: 0;
  border-radius: var(--radius);
  padding: .375rem;
}

/* --- Wizard Helpers --- */
.page-intro {
  margin: .5rem 0 1.25rem;
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 1rem;
}
.section-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--primary);
}

.sx-actions {
  display: flex;
  gap: .75rem;
  align-items: center;
  flex-wrap: wrap;
}
.page-actions {
  display: flex;
  gap: .75rem;
  flex-wrap: wrap;
  align-items: center;
}
.page-actions > :first-child { margin-right: auto; }
.page-actions.right { justify-content: flex-end; }
.page-actions.right > :first-child { margin-right: 0; }

/* Money input */
.sx-money { display: flex; align-items: center; gap: .5rem; }
.sx-money input { flex: 1 1 auto; }
.sx-unit { white-space: nowrap; opacity: .7; font-size: .875rem; }

/* Row actions (tables) – erster Button feste Breite für vertikale Ausrichtung */
.sx-row-actions { display: flex; gap: .5rem; flex-wrap: nowrap; align-items: center; }
.sx-row-actions form { margin: 0; }
.sx-row-actions .btn { font-size: .75rem; padding: .375rem .625rem; white-space: nowrap; }
.sx-dl-btn { width: 180px; flex: 0 0 180px; justify-content: flex-start; text-align: left; }

/* Utility */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  white-space: nowrap;
  border: 0;
}
hr { border: 0; border-top: 1px solid var(--border); margin: 1.25rem 0; }

/* --- Labels with info buttons --- */
.sx-label-info { display: flex; align-items: center; gap: .5rem; }
.sx-info-btn {
  display: inline;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--accent);
  cursor: pointer;
  font-size: .875rem;
  font-weight: 500;
  text-decoration: none;
  transition: all var(--transition);
}
.sx-info-btn .sx-ico { display: none; }
.sx-info-btn:hover { color: var(--accent-hover); }

/* --- Modals --- */
.sx-modal { position: fixed; inset: 0; z-index: 9999; }
.sx-modal[hidden] { display: none; }
.sx-modal-backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.45); }
.sx-modal-panel {
  position: relative;
  width: min(640px, calc(100% - 2rem));
  max-height: calc(100% - 2rem);
  overflow: auto;
  margin: 1rem auto;
  background: #fff;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  padding: 1.25rem;
}
.sx-modal-panel h3 { margin: 0 0 .75rem; }
.sx-modal-body { font-size: 1rem; line-height: 1.55; }
.sx-modal-body p { margin: 0 0 .625rem; }
.sx-modal-body ul { margin: .375rem 0 .75rem 1.125rem; }
.sx-modal-close {
  position: absolute;
  top: .625rem; right: .625rem;
  width: 32px; height: 32px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: #fff;
  font-size: 1.125rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
.sx-modal-close:hover { background: var(--surface); }
body.sx-modal-open { overflow: hidden; }

/* --- Info Boxes --- */
.sx-infobox {
  border: 1px solid var(--border);
  background: var(--bg-subtle);
  border-radius: var(--radius);
  padding: .75rem;
  font-size: .875rem;
}
.sx-infobox p { margin: .5rem 0; }
.sx-infobox-title { font-weight: 600; margin: 0 0 .375rem; }
.sx-infobox-grid { display: grid; grid-template-columns: 1fr; gap: .75rem; }

/* --- Inline Checkbox --- */
.sx-inline-check {
  display: flex;
  gap: .5rem;
  align-items: flex-start;
  font-weight: 500;
}
.sx-inline-check input {
  margin: 2px 0 0;
  width: auto;
  flex-shrink: 0;
}

/* --- Text Link --- */
.text-link, a.text-link {
  display: inline;
  padding: 0; border: 0;
  background: transparent;
  color: var(--accent);
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
}
.text-link:hover, a.text-link:hover { text-decoration: underline; }
.sx-link { font-size: .8125rem; color: var(--accent); text-decoration: underline; }
.sx-link:hover { opacity: .85; }

/* --- Focus --- */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}
a, button, summary { cursor: pointer; }

/* --- Table scroll on mobile --- */
.table-scroll-hint {
  position: relative;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
  padding-bottom: .375rem;
}
.table-scroll-hint > .table { min-width: 580px; }
.scroll-hint-badge { display: none !important; }

/* --- Home page hero footer --- */
.home-hero-footer {
  margin-top: .75rem;
  display: flex;
  justify-content: flex-start;
}
.home-hero-footer .sx-cta-link { font-weight: 600; }

/* --- Reduced motion --- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* --- Section Divider --- */
.section-divider {
  margin: 5rem 0 1.25rem;
  scroll-margin-top: 120px;
  text-align: left;
  position: relative;
}
.section-divider::before { display: none; }
.section-divider h2 {
  font-size: 1.75rem;
  font-weight: 400;
  color: var(--primary);
  margin-bottom: .5rem;
  letter-spacing: -0.01em;
}
.section-divider p {
  color: var(--text-secondary);
  font-size: 1rem;
  margin: 0;
  max-width: 640px;
}

/* --- Legal Pages --- */
.legal h2 { margin-top: 2rem; font-size: 1.25rem; }
.legal h3 { margin-top: 1.5rem; font-size: 1.0625rem; }
.legal p, .legal li { font-size: 1rem; line-height: 1.7; color: var(--text-secondary); }
.legal ul, .legal ol { margin: .5rem 0 1rem 1.25rem; }
.legal li { margin-bottom: .375rem; }

/* ======================
   RESPONSIVE
   ====================== */

/* Tablet */
@media (min-width: 640px) {
  .features { grid-template-columns: 1fr 1fr; }
  .features-flat { grid-template-columns: 1fr 1fr; }
  .steps-flat { grid-template-columns: 1fr 1fr; }
  .steps-overview { grid-template-columns: 1fr 1fr; }
  .sx-infobox-grid { grid-template-columns: 1fr 1fr; }
}

/* Desktop */
@media (min-width: 768px) {
  h1, .h1 { font-size: 1.75rem; }
  .hero .h1 { font-size: 2.375rem; }
  .hero .lead { font-size: 1.1875rem; }
  .hero .subtitle { font-size: 1.0625rem; }
  .hero { padding: 0; margin: 2rem 0 0; }
  .features { grid-template-columns: repeat(3, 1fr); }
  /* features-flat & steps-flat sind jetzt eine Sammelbox – einspaltig */
  .sx-row-person { grid-template-columns: auto 1fr 1fr; align-items: end; }
  .container { padding: 2.5rem 2rem; }
  .sx-modal-body .sx-infobox-grid { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1024px) {
  .steps-flat { grid-template-columns: repeat(3, 1fr); }
  .home-container { max-width: 1040px; }
}

/* Mobile fixes */
@media (max-width: 640px) {
  .container { padding: 1.25rem 1rem; }
  h1, .h1 { font-size: 1.5rem; }
  h2, .h2 { font-size: 1.1875rem; }
  .row { grid-template-columns: 1fr; }
  .row > * { min-width: 0; max-width: 100%; }
  .nav { padding: .75rem 1rem; }
  .nav-brand img { max-height: 56px; max-width: none; }
  .nav-auth { right: .5rem; top: 68px; }
  body.has-fixed-header { padding-top: 68px; }
  body.has-fixed-header.app { padding-top: 104px; }
  .hero .h1 { font-size: 1.5rem; }
  .section-divider h2 { font-size: 1.5rem; }

  /* Row actions: nichts zu überschreiben, flex-wrap reicht */

  /* Claim fields stack on mobile */
  .sx-claim-fields {
    grid-template-columns: 1fr 1fr;
  }
  .sx-claim-total, .sx-claim-del-wrap {
    padding-top: 0;
  }

  /* Prevent horizontal scroll (swimming fix) */
  html, body { position: relative; width: 100%; max-width: 100vw; overflow-x: hidden; }
  body.app { overflow-x: hidden; overscroll-behavior-x: none; }
  body.app .container, body.app main { max-width: 100%; overflow-x: hidden; }
  .page { min-width: 0; width: 100%; }

  /* Accordion content overflow */
  .sx-accordion, .sx-accordion-body { max-width: 100%; }
  .sx-accordion-body { min-width: 0; }
  .sx-accordion-body input,
  .sx-accordion-body textarea,
  .sx-accordion-body select { max-width: 100%; }

  /* Tables scroll – horizontal und vertikal, damit die Seite weiter scrollbar bleibt */
  body.app .table-scroll-hint { touch-action: pan-x pan-y; }

  /* Segment wrap (NOT overflow-x scroll) */
  .sx-segment { flex-wrap: wrap; overflow-x: visible; scrollbar-width: auto; }
  .sx-segment::-webkit-scrollbar { display: block; }
  .sx-segment label { flex-shrink: 0; }

  /* Input zoom prevention */
  input, select, textarea { touch-action: manipulation; }

  /* Footer */
  .footer { padding: 1rem; }
  .footer-links { gap: .5rem; font-size: .75rem; }

  .cta-bottom { font-size: 1rem; padding: .5rem 1.5rem; }
  /* Hero adjustments for mobile */
  .hero { margin: 1.5rem 0 0; padding: 0; }
  .section-divider { margin: 3.5rem 0 1rem; }

  /* Menu bar mobile */
  .app-menu-bar { top: 68px; padding: .25rem .5rem; }
  .header-fixed.app .nav-brand img { max-height: 56px; max-width: none; }
}

/* Very small screens */
@media (max-width: 380px) {
  h1, .h1 { font-size: 1.375rem; }
  .container { padding: 1rem .75rem; }
  .nav { padding: .625rem .75rem; }
  .nav-brand img { max-height: 44px; max-width: none; }
}

/* --- Print --- */
@media print {
  .header-fixed, .app-menu-bar, .footer, .side-drawer, .side-backdrop, .menu-toggle { display: none; }
  body.has-fixed-header { padding-top: 0; }
  .container { max-width: 100%; padding: 0; }
}

/* --- Features Flat (Landing) --- */
.features-flat {
  display: block;
  margin: 1rem 0 2rem;
  background: #ffffff;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(15,23,42,.04), 0 4px 14px rgba(15,23,42,.05);
  padding: .5rem 1.75rem;
}
.feature-flat {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.125rem 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  transition: none;
}
.feature-flat + .feature-flat { border-top: 0; }
.feature-flat:hover,
.feature-flat:focus,
.feature-flat:active { outline: none; background: transparent; border: 0; box-shadow: none; transform: none; }
.feature-flat .feature-icon {
  width: 28px; height: 28px;
  flex-shrink: 0;
  color: var(--secondary);
  background: transparent;
  border: 0;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -4px;
}
.feature-flat .feature-icon svg { width: 22px; height: 22px; stroke-width: 1.5; }
.feature-flat h3 { font-size: 1rem; font-weight: 400; margin: 0; color: var(--primary); }
.feature-flat p { margin: .25rem 0 0; color: var(--text-secondary); font-size: .9375rem; line-height: 1.6; }
/* Highlight-Feature entfernt - alle Boxen einheitlich */
.feature-highlight {
  background: #ffffff;
  border: 1px solid var(--border);
}
.feature-highlight .feature-icon { color: var(--secondary); border: 0; }
.feature-highlight h3 { color: var(--primary); }

/* --- Steps Flat (Landing) --- */
.steps-flat {
  display: block;
  margin: 1rem 0 2rem;
  background: #ffffff;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(15,23,42,.04), 0 4px 14px rgba(15,23,42,.05);
  padding: .5rem 1.75rem;
  counter-reset: stepflat;
}
.step-flat {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.125rem 0;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  transition: none;
}
.step-flat + .step-flat { border-top: 0; }
.step-flat:hover,
.step-flat:focus,
.step-flat:active { outline: none; background: transparent; border: 0; box-shadow: none; transform: none; }
/* Nummer als umrandetes Kreis-Icon (passt zum SVG-Outline-Stil der anderen Icons) */
.step-flat-num {
  flex-shrink: 0;
  width: 26px; height: 26px;
  background: transparent;
  color: var(--secondary);
  border: 1.5px solid var(--secondary);
  border-radius: 50%;
  font-weight: 500;
  font-size: .8125rem;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: none;
  margin-top: 0.5px;
  font-feature-settings: "tnum";
}
.step-flat h4 { margin: 0 0 .125rem; font-size: 1rem; font-weight: 400; color: var(--primary); }
.step-flat p { margin: 0; font-size: .9375rem; color: var(--text-secondary); line-height: 1.55; }

/* --- Pricing List (Landing) --- */
.pricing-list {
  list-style: none;
  padding: 1.75rem 2rem;
  margin: 1rem 0 2rem;
  background: #ffffff;
  border: 1px solid var(--border-soft);
  border-radius: 14px;
  box-shadow: 0 1px 2px rgba(15,23,42,.04), 0 4px 14px rgba(15,23,42,.05);
}
.pricing-list li {
  padding: .5rem 0 .5rem 1.875rem;
  position: relative;
  color: var(--text);
  font-size: 1rem;
  line-height: 1.5;
}
.pricing-list li + li { border-top: 0; }
.pricing-list li::before {
  content: "";
  position: absolute;
  left: 0; top: .8rem;
  width: 18px; height: 18px;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 24 24' fill='none' stroke='%232563eb' stroke-width='3' stroke-linecap='round' stroke-linejoin='round' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M20 6L9 17l-5-5'/%3E%3C/svg%3E") no-repeat center/contain;
}
.pricing-list .pricing-highlight {
  color: var(--primary);
  font-weight: 400;
  padding: 0 0 1rem;
  text-align: left;
  margin-bottom: .5rem;
  border: 0;
  display: flex;
  align-items: baseline;
  gap: .5rem;
}
.pricing-list .pricing-highlight::before { display: none; }
.pricing-list .pricing-highlight .price-main {
  color: var(--accent);
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1;
}
.pricing-list .pricing-highlight .price-sub {
  color: var(--text-secondary);
  font-size: 1rem;
  font-weight: 400;
}

/* --- CTA Fixed Bar --- */
.cta-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  text-align: center;
  padding: .625rem 1rem;
  background: #fff;
  border-top: 1px solid var(--border);
  box-shadow: 0 -2px 8px rgba(0,0,0,.06);
}
.cta-bottom {
  display: inline-block;
  background: #ffffff;
  color: var(--accent);
  font-size: 1.125rem;
  font-weight: 500;
  padding: .5rem 2rem;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  text-decoration: none;
  transition: background var(--transition), color var(--transition);
}
.cta-bottom:hover {
  background: var(--accent-light);
  color: var(--accent);
  text-decoration: none;
}

/* --- Accordion flat (no dark blue border) --- */
.sx-accordion.sx-flat {
  border-left: 1px solid var(--border);
}

/* --- Navigationsleiste auf oeffentlichen Seiten --- */
/* Liegt als eigene fixierte Leiste unter dem Logo-Header. Das Layout des
   Mitgliederbereichs (body.app) bleibt davon vollstaendig unberuehrt. */
.public-nav {
  background: #fff;
  border-top: 1px solid var(--border);
}
.public-nav-inner {
  max-width: 880px;
  margin: 0 auto;
  padding: .35rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}
.public-nav-links {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  overflow-x: auto;
  scrollbar-width: none;
}
.public-nav-links::-webkit-scrollbar { display: none; }
.public-nav-links a {
  color: var(--primary);
  text-decoration: none;
  font-size: .875rem;
  white-space: nowrap;
  padding: .3rem 0;
}
.public-nav-links a:hover { text-decoration: underline; }
.public-nav-auth {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-shrink: 0;
}
body.has-fixed-header.public { padding-top: 143px; }

/* Sprungziele nicht unter den fixierten Header rutschen lassen */
.section-divider[id] { scroll-margin-top: 155px; }

/* Gemessene Headerhoehen inkl. Navigationsleiste:
   >=641px = 138px, 381-640px = 127px, <=380px = 111px.
   Das Padding haelt jeweils rund 5px Abstand. */
@media (max-width: 640px) {
  .public-nav-inner { padding: .3rem .75rem; gap: .75rem; }
  .public-nav-links { gap: .9rem; }
  .public-nav-links a { font-size: .8125rem; }
  body.has-fixed-header.public { padding-top: 132px; }
  .section-divider[id] { scroll-margin-top: 144px; }
}

@media (max-width: 380px) {
  body.has-fixed-header.public { padding-top: 116px; }
  .section-divider[id] { scroll-margin-top: 128px; }
}

@media print {
  .public-nav { display: none; }
  body.has-fixed-header.public { padding-top: 0; }
}
