/* ============================================
   SagMal Website - Gemeinsame Styles
   ============================================ */

/* ============================================
   Design Tokens (Healthcare / SaaS)
   ============================================ */
:root {
  /* Color system */
  --color-bg: #f6f8fb;
  --color-surface: #ffffff;
  --color-surface-2: #fbfcfe;

  --color-text-900: #0b1420; /* Anthrazit/Navy */
  --color-text-700: #243244;
  --color-text-500: #5a6b7d;

  /* Primary (Petrol/Teal basierend auf Logo) */
  --color-primary: #0d5d5a; /* Dunkles Petrol */
  --color-primary-hover: #0a4d4a;
  --color-link: #0f766e;
  --color-link-hover: #0d5d5a;

  /* Accent (helleres Teal für Akzente) */
  --color-accent: #14a399; /* Helles Teal */

  /* Semantic */
  --color-success: #14804a;
  --color-warning: #b45309;
  --color-danger: #b42318;
  --color-info: #2563eb;

  --tint-success: rgba(20, 128, 74, 0.10);
  --tint-warning: rgba(180, 83, 9, 0.10);
  --tint-danger: rgba(180, 35, 24, 0.10);
  --tint-info: rgba(37, 99, 235, 0.10);

  /* Borders */
  --color-border: rgba(11, 20, 32, 0.12);
  --color-border-subtle: rgba(11, 20, 32, 0.08);

  /* Typography */
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-weight-regular: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;

  --font-size-body: 1rem;
  --font-size-small: 0.9375rem;
  --font-size-h3: 1.125rem;
  --font-size-h2: 1.5rem;
  --font-size-h1: clamp(2rem, 3.2vw, 2.75rem);

  --line-height-body: 1.7;
  --line-height-heading: 1.2;

  /* Spacing scale */
  --space-4: 4px;
  --space-8: 8px;
  --space-12: 12px;
  --space-16: 16px;
  --space-24: 24px;
  --space-32: 32px;
  --space-48: 48px;
  --space-72: 72px;

  /* Radius */
  --radius-12: 12px;
  --radius-16: 16px;

  /* Shadows (subtil) */
  --shadow-1: 0 1px 2px rgba(11, 20, 32, 0.06), 0 8px 20px rgba(11, 20, 32, 0.06);
  --shadow-2: 0 2px 6px rgba(11, 20, 32, 0.10), 0 16px 40px rgba(11, 20, 32, 0.10);

  /* Layout */
  --container-max: 1120px;
  --container-narrow: 900px;
  --container-wide: 1180px;

  /* Focus */
  --focus-ring: 3px solid rgba(13, 93, 90, 0.28);
  --focus-offset: 2px;
}

/* Reset & Basis */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  font-family: var(--font-sans);
  line-height: var(--line-height-body);
  color: var(--color-text-900);
  background: var(--color-bg);
  min-height: 100vh;
  text-rendering: optimizeLegibility;
}

/* Header & Navigation (Product-Navigation) */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid var(--color-border-subtle);
  background: rgba(255, 255, 255, 0.82);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

.site-header.is-scrolled {
  box-shadow: var(--shadow-1);
}

.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-16);
  padding: var(--space-12) 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--space-12);
  color: var(--color-text-900);
  text-decoration: none;
  font-weight: var(--font-weight-semibold);
  white-space: nowrap;
}

.brand-logo {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  object-fit: contain;
}

.brand-name {
  letter-spacing: -0.01em;
}

.nav-toggle {
  display: none;
  cursor: pointer;
  position: relative;
  z-index: 2;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-8);
  padding: 0.55rem 0.75rem;
  border-radius: var(--radius-12);
  color: var(--color-text-700);
  text-decoration: none;
  font-weight: var(--font-weight-medium);
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  font: inherit;
}

.nav-link:hover {
  background: rgba(13, 93, 90, 0.06);
}

.nav-link.active {
  color: var(--color-primary);
  background: rgba(13, 93, 90, 0.08);
  border-color: rgba(13, 93, 90, 0.16);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: var(--space-8);
}

.lang-switcher {
  display: inline-flex;
  align-items: center;
  background: rgba(13, 93, 90, 0.06);
  border: 1px solid rgba(13, 93, 90, 0.12);
  border-radius: var(--radius-12);
  padding: 2px;
  margin-right: var(--space-8);
  position: relative;
}

.lang-btn {
  background: transparent;
  border: none;
  color: var(--color-text-600);
  font-weight: var(--font-weight-medium);
  font-size: var(--font-size-small);
  padding: 0.5rem 0.85rem;
  cursor: pointer;
  border-radius: calc(var(--radius-12) - 2px);
  transition: all 0.2s ease;
  position: relative;
  z-index: 1;
  min-width: 44px;
  text-align: center;
}

.lang-btn:hover:not(.active) {
  color: var(--color-text-700);
}

.lang-btn.active {
  color: var(--color-primary);
  background: var(--color-surface);
  font-weight: var(--font-weight-semibold);
  box-shadow: 0 1px 2px rgba(11, 20, 32, 0.08);
}

.nav-dropdown {
  position: relative;
}

.nav-chevron {
  width: 10px;
  height: 10px;
  display: inline-block;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(45deg);
  opacity: 0.7;
  margin-top: -2px;
}

.nav-dropdown-panel {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: 340px;
  background: var(--color-surface);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-16);
  box-shadow: var(--shadow-2);
  padding: var(--space-8);
  display: none;
}

.nav-dropdown.is-open .nav-dropdown-panel {
  display: block;
}

.nav-dropdown-item {
  display: block;
  padding: var(--space-12) var(--space-12);
  border-radius: var(--radius-12);
  border: 1px solid transparent;
  text-decoration: none;
  color: var(--color-text-900);
}

.nav-dropdown-item:hover {
  background: rgba(13, 93, 90, 0.06);
  border-color: rgba(13, 93, 90, 0.12);
}

.nav-dropdown-item.active {
  background: rgba(13, 93, 90, 0.08);
  border-color: rgba(13, 93, 90, 0.16);
}

.nav-item-title {
  display: block;
  font-weight: var(--font-weight-semibold);
  line-height: 1.25;
}

.nav-item-desc {
  display: block;
  margin-top: 2px;
  color: var(--color-text-500);
  font-size: var(--font-size-small);
  line-height: 1.35;
}

@media (max-width: 980px) {
  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    width: 100%;
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-8);
    padding: var(--space-12);
    border: 1px solid var(--color-border-subtle);
    border-radius: var(--radius-16);
    background: rgba(255, 255, 255, 0.95);
  }

  .site-header.nav-open .site-nav {
    display: flex;
  }

  .nav-bar {
    flex-wrap: wrap;
  }

  .nav-cta {
    width: 100%;
  }

  .nav-cta .btn {
    width: 100%;
  }

  .nav-dropdown-panel {
    position: static;
    width: auto;
    box-shadow: none;
    border: 0;
    padding: 0 0 0 var(--space-8);
    margin-top: var(--space-8);
    background: transparent;
  }
}

/* Desktop Override:
   Auf Geräten mit Maus/Trackpad (fine pointer / hover) soll das Hamburger-Menü nicht erscheinen,
   auch wenn durch Zoom/Skalierung die CSS-Breite < 980px wird. */
@media (hover: hover) and (pointer: fine) {
  .nav-toggle {
    display: none !important;
  }

  .site-nav {
    display: flex !important;
    width: auto !important;
    flex-direction: row !important;
    align-items: center !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
  }

  .nav-dropdown-panel {
    position: absolute !important;
    width: 340px !important;
    box-shadow: var(--shadow-2) !important;
    border: 1px solid var(--color-border-subtle) !important;
    padding: var(--space-8) !important;
    margin-top: 0 !important;
    background: var(--color-surface) !important;
  }
}

/* Main Content */
main {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--space-72) var(--space-24);
}

/* Passungs-Check: etwas breiter, damit Ergebnis-Grid ruhiger wirkt */
.page-passungscheck main {
  max-width: var(--container-wide);
}

@media (max-width: 520px) {
  .page-passungscheck main {
    padding: 2.25rem 1.25rem;
  }
}

/* Header & Logo */
.header {
  text-align: center;
  margin-bottom: 2rem;
}

.header-logo {
  width: 120px;
  height: 120px;
  margin-bottom: 1rem;
  object-fit: contain;
}

/* Hero Section (Startseite) */
.hero {
  margin-bottom: var(--space-48);
  padding: var(--space-48);
  border-radius: var(--radius-16);
  border: 1px solid rgba(13, 93, 90, 0.10);
  background: linear-gradient(180deg, rgba(13, 93, 90, 0.06), rgba(13, 93, 90, 0.02));
}

.hero-logo {
  width: 140px;
  height: 140px;
  margin-bottom: 1.5rem;
  object-fit: contain;
}

.hero h1 {
  font-size: clamp(2.25rem, 4.2vw, 3rem);
  font-weight: var(--font-weight-bold);
  color: var(--color-text-900);
  margin-bottom: 0.75rem;
  letter-spacing: -0.015em;
  line-height: var(--line-height-heading);
}

.hero p {
  margin: 0;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: var(--space-48);
  align-items: center;
}

.hero-content {
  text-align: left;
}

.hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: var(--space-8);
  padding: 0.35rem 0.65rem;
  border-radius: 999px;
  background: rgba(13, 93, 90, 0.10);
  color: var(--color-primary);
  font-weight: var(--font-weight-semibold);
  font-size: var(--font-size-small);
  border: 1px solid rgba(13, 93, 90, 0.18);
  margin-bottom: var(--space-16);
}

.hero-title {
  margin-bottom: var(--space-12);
}

.hero-lead {
  margin: 0 0 var(--space-24);
  max-width: 56ch;
  font-size: 1.125rem;
  color: var(--color-text-700);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-12);
  align-items: center;
  margin-top: var(--space-16);
}

.hero-actions .btn {
  padding: 0.9rem 1.15rem;
}

.hero-meta {
  margin-top: var(--space-16);
  color: var(--color-text-500);
  font-size: var(--font-size-small);
}

.hero-media {
  display: flex;
  justify-content: center;
}

.device-mock {
  width: min(340px, 100%);
  border-radius: 28px;
  border: 1px solid rgba(11, 20, 32, 0.14);
  background: rgba(255, 255, 255, 0.65);
  box-shadow: var(--shadow-2);
  padding: 14px;
}

.device-screen {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 20px;
  border: 1px solid rgba(11, 20, 32, 0.10);
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-12);
  margin-top: var(--space-24);
}

.trust-item {
  display: inline-flex;
  align-items: center;
  gap: var(--space-8);
  padding: 0.55rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(11, 20, 32, 0.10);
  color: var(--color-text-700);
  font-weight: var(--font-weight-semibold);
  font-size: var(--font-size-small);
}

.trust-icon {
  width: 16px;
  height: 16px;
  display: inline-block;
}

.trust-dot {
  width: 10px;
  height: 10px;
  border-radius: 99px;
  background: var(--color-accent);
  opacity: 0.9;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--space-16);
}

.step-card {
  padding: var(--space-16);
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  background: var(--color-surface);
  box-shadow: var(--shadow-1);
}

.step-num {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  color: var(--color-primary);
  background: rgba(13, 93, 90, 0.10);
  border: 1px solid rgba(13, 93, 90, 0.16);
  margin-bottom: var(--space-12);
}

.step-title {
  margin-bottom: var(--space-8);
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-900);
}

.step-text {
  margin: 0;
  color: var(--color-text-700);
  font-size: 0.98rem;
  line-height: 1.55;
}

.diagram {
  width: 100%;
  height: auto;
  display: block;
  margin-top: var(--space-24);
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  background: var(--color-surface);
}

@media (max-width: 980px) {
  .hero {
    padding: var(--space-24);
  }
  .hero-grid {
    grid-template-columns: 1fr;
  }
  .hero-media {
    order: -1;
  }
  .steps-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 520px) {
  .steps-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   Page layouts (Article / Tutorial / Legal)
   ============================================ */
.page-article main,
.page-tutorial main,
.page-legal main {
  max-width: var(--container-narrow);
}

.page-header {
  padding: var(--space-32);
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  background: var(--color-surface);
  box-shadow: var(--shadow-1);
  margin-bottom: var(--space-24);
}

.page-header .kicker {
  display: inline-flex;
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
  background: rgba(13, 93, 90, 0.10);
  border: 1px solid rgba(13, 93, 90, 0.16);
  color: var(--color-primary);
  font-size: var(--font-size-small);
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--space-12);
}

.page-header h1 {
  margin: 0 0 var(--space-8);
}

.page-header .subtitle {
  margin: 0;
  color: var(--color-text-500);
}

.prose {
  max-width: 72ch;
}

.prose h2 {
  margin-top: var(--space-32);
}

.prose ul,
.prose ol {
  padding-left: 1.25rem;
}

.prose li {
  margin: 0.35rem 0;
}

/* Stepper (Versorgung / Prozess) */
.stepper {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: var(--space-12);
}

.stepper-item {
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: var(--space-12);
  align-items: start;
  padding: var(--space-16);
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  background: var(--color-surface);
  box-shadow: var(--shadow-1);
}

.stepper-marker {
  width: 36px;
  height: 36px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  color: var(--color-primary);
  background: rgba(13, 93, 90, 0.10);
  border: 1px solid rgba(13, 93, 90, 0.16);
}

.stepper-title {
  font-weight: var(--font-weight-semibold);
  color: var(--color-text-900);
  margin: 0 0 6px;
}

.stepper-text {
  margin: 0;
  color: var(--color-text-700);
}

/* Tutorial: Karten-Layout für Schritte/Konzepte */
.guide-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-16);
}

.guide-card {
  padding: var(--space-16);
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  background: var(--color-surface);
  box-shadow: var(--shadow-1);
}

.guide-card h3 {
  margin: 0 0 var(--space-8);
  font-size: 1.125rem;
  color: var(--color-text-900);
}

.guide-card p {
  margin: 0;
  color: var(--color-text-700);
}

.key-box {
  margin-top: var(--space-16);
  padding: var(--space-16);
  border-radius: var(--radius-16);
  border: 1px solid rgba(37, 99, 235, 0.18);
  background: var(--tint-info);
}

.key-box h3 {
  margin: 0 0 var(--space-8);
  font-size: 1.05rem;
}

@media (max-width: 900px) {
  .guide-grid {
    grid-template-columns: 1fr;
  }
}

/* Utility classes */
.mt-12 {
  margin-top: var(--space-12);
}

.mt-8 {
  margin-top: var(--space-8);
}

.mt-n4 {
  margin-top: calc(var(--space-4) * -1);
}

/* Typography */
h1 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
  color: var(--color-text-900);
  letter-spacing: -0.01em;
  line-height: var(--line-height-heading);
}

h2 {
  font-size: 1.5rem;
  color: var(--color-text-900);
  margin-bottom: 1rem;
  line-height: var(--line-height-heading);
}

.subtitle {
  color: var(--color-text-500);
  font-size: 1.125rem;
  margin-bottom: 1rem;
}

p {
  margin-bottom: 1rem;
  color: var(--color-text-700);
  line-height: 1.8;
}

/* Sections */
section {
  background: var(--color-surface);
  padding: 2.5rem;
  margin-bottom: 2rem;
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  box-shadow: var(--shadow-1);
}

.section {
  background: var(--color-surface);
  padding: 2.5rem;
  margin-bottom: 2rem;
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  box-shadow: var(--shadow-1);
}

.section-title {
  text-align: center;
  font-size: 1.75rem;
  color: var(--color-text-900);
  margin-bottom: 2rem;
  font-weight: 600;
}

/* Buttons & Links */
.container {
  width: min(calc(100% - (2 * var(--space-24))), var(--container-max));
  margin-left: auto;
  margin-right: auto;
}

.container--narrow {
  width: min(calc(100% - (2 * var(--space-24))), var(--container-narrow));
  margin-left: auto;
  margin-right: auto;
}

.container--wide {
  width: min(calc(100% - (2 * var(--space-24))), var(--container-wide));
  margin-left: auto;
  margin-right: auto;
}

.section-stack {
  display: flex;
  flex-direction: column;
  gap: var(--space-24);
}

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-16);
  box-shadow: var(--shadow-1);
}

.card--tint {
  background: rgba(13, 93, 90, 0.04);
  border-color: rgba(13, 93, 90, 0.12);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 44px;
  line-height: 1;
  text-decoration: none;
  color: var(--color-text-900);
}

.btn--primary {
  background: var(--color-primary);
  border-color: rgba(13, 93, 90, 0.35);
  color: #fff;
  box-shadow: 0 10px 24px rgba(13, 93, 90, 0.18);
}

.btn--primary:hover {
  background: var(--color-primary-hover);
  color: #fff !important;
  text-decoration: underline;
}

.btn--secondary {
  background: rgba(13, 93, 90, 0.04);
  border-color: rgba(13, 93, 90, 0.18);
  color: var(--color-primary);
}

.btn--secondary:hover {
  background: rgba(13, 93, 90, 0.07);
}

.btn--ghost {
  background: transparent;
  border-color: transparent;
  color: var(--color-primary);
}

.btn--ghost:hover {
  background: rgba(13, 93, 90, 0.06);
  border-color: rgba(13, 93, 90, 0.12);
}

.cta-button {
  display: inline-block;
  background: var(--color-primary);
  color: #fff;
  padding: 1rem 2rem;
  border-radius: var(--radius-12);
  text-decoration: none;
  font-weight: 600;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 10px 24px rgba(13, 93, 90, 0.18);
  min-height: 48px;
  box-sizing: border-box;
}

.cta-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(13, 93, 90, 0.24);
  color: #fff !important;
  text-decoration: underline;
}

a {
  color: var(--color-link);
  text-decoration: none;
}

a:hover:not(.cta-button):not(.btn):not(.btn--primary):not(.cookie-banner-button) {
  color: var(--color-link-hover);
  text-decoration: underline;
}

/* Features Grid (Startseite) */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 2rem;
}

.feature {
  background: var(--color-surface);
  padding: 2rem;
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  box-shadow: var(--shadow-1);
  transition: transform 0.2s;
  display: flex;
  flex-direction: column;
}

.feature:hover {
  transform: translateY(-4px);
}

.feature h3 {
  font-size: 1.3rem;
  margin-bottom: 1rem;
  color: var(--color-text-900);
}

.feature p {
  color: var(--color-text-700);
  flex-grow: 1;
}

.feature .cta-button {
  margin-top: auto;
  width: 100%;
  text-align: center;
}

/* Utility Items (Tutorial) */
.utility-item {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 1rem;
  margin-bottom: 1rem;
  background: var(--color-surface-2);
  border-radius: var(--radius-12);
  border: 1px solid var(--color-border-subtle);
}

.utility-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-12);
  flex-shrink: 0;
  object-fit: contain;
  background: rgba(13, 93, 90, 0.08);
  padding: 8px;
}

.speak-button {
  width: 56px;
  height: 56px;
  border-radius: 28px;
  background-color: var(--color-surface-2);
  border: 1px solid var(--color-border-subtle);
  display: flex;
  justify-content: center;
  align-items: center;
  flex-shrink: 0;
}

/* Contact & Support */
.contact-box {
  background: rgba(13, 93, 90, 0.06);
  padding: 2rem;
  border-radius: var(--radius-12);
  margin-top: 1.5rem;
  border: 1px solid rgba(13, 93, 90, 0.10);
}

.email-link {
  color: var(--color-link);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.1rem;
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: var(--color-surface);
  border-radius: 8px;
  margin-top: 1rem;
  border: 1px solid var(--color-border-subtle);
}

.email-link:hover {
  background: rgba(13, 93, 90, 0.06);
  border-color: rgba(13, 93, 90, 0.12);
}

.email-link:hover {
  background: rgba(13, 93, 90, 0.06);
  text-decoration: none;
}

/* FAQ */
.faq-item {
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--color-border-subtle);
}

.faq-item:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.faq-question {
  font-weight: 600;
  color: var(--color-text-900);
  margin-bottom: 0.5rem;
}

.faq-answer {
  color: var(--color-text-500);
}

/* Highlight Boxes */
.highlight {
  background: rgba(13, 93, 90, 0.06);
  padding: 1.5rem;
  border-radius: var(--radius-12);
  margin: 1.5rem 0;
  border: 1px solid rgba(13, 93, 90, 0.10);
}

.version-info {
  background: var(--color-surface-2);
  padding: 1rem;
  border-radius: 8px;
  margin-top: 1.5rem;
  border: 1px solid var(--color-border-subtle);
}

/* Legal Pages (Privacy, Impressum) */
.wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 28px;
  background: var(--color-surface);
  margin-top: 2rem;
  border-radius: var(--radius-16);
  border: 1px solid var(--color-border-subtle);
  box-shadow: var(--shadow-1);
  margin-bottom: 2rem;
}

.meta {
  color: var(--color-text-500);
  font-size: 0.95rem;
  margin-bottom: 1rem;
}

.box {
  background: var(--color-surface-2);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-12);
  padding: 16px;
  margin: 12px 0;
}

code {
  background: rgba(11, 20, 32, 0.06);
  padding: 0.08rem 0.3rem;
  border-radius: 5px;
}

/* Footer */
footer {
  text-align: center;
  padding: 2rem;
  color: var(--color-text-500);
  margin-top: 4rem;
  border-top: 1px solid var(--color-border-subtle);
}

footer a {
  color: var(--color-text-500);
}

footer a:hover {
  color: var(--color-link-hover);
  text-decoration: underline;
}

/* ============================================
   Cookie Banner (Modal Design)
   ============================================ */

/* Overlay - dunkelt den Hintergrund ab */
#cookie-banner-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 9999;
  display: none;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}

#cookie-banner-overlay.show {
  display: block;
  opacity: 1;
}

/* Modal Container */
#cookie-banner {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  background: var(--color-surface);
  border-radius: var(--radius-16);
  box-shadow: var(--shadow-2);
  padding: 2.5rem;
  z-index: 10000;
  max-width: 600px;
  width: 90%;
  border: 1px solid var(--color-border-subtle);
  display: none;
  opacity: 0;
  transition: all 0.3s ease-in-out;
}

#cookie-banner.show {
  display: block;
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}

.cookie-banner-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.cookie-banner-text {
  color: var(--color-text-700);
  font-size: 1.1rem;
  line-height: 1.7;
}

.cookie-banner-text strong {
  color: var(--color-text-900);
  font-weight: 600;
}

.cookie-banner-text a {
  color: var(--color-link);
  text-decoration: underline;
  font-weight: 500;
}

.cookie-banner-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.cookie-banner-button {
  padding: 1rem 2rem;
  border-radius: var(--radius-12);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: all 0.2s;
  border: none;
  text-decoration: none;
  display: inline-block;
  flex: 1;
  min-width: 140px;
}

.cookie-banner-button-accept {
  background: var(--color-primary);
  color: #fff;
  box-shadow: 0 10px 24px rgba(13, 93, 90, 0.18);
}

.cookie-banner-button-accept:hover {
  background: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 14px 34px rgba(13, 93, 90, 0.24);
  color: #fff !important;
  text-decoration: underline;
}

.cookie-banner-button-reject {
  background: rgba(11, 20, 32, 0.06);
  color: var(--color-text-900);
  border: 1px solid var(--color-border-subtle);
}

.cookie-banner-button-reject:hover {
  background: rgba(11, 20, 32, 0.08);
}

@media (max-width: 768px) {
  #cookie-banner {
    padding: 2rem 1.5rem;
    width: 95%;
    max-width: none;
  }

  .cookie-banner-text {
    font-size: 1rem;
  }

  .cookie-banner-buttons {
    flex-direction: column;
  }

  .cookie-banner-button {
    width: 100%;
    min-width: auto;
  }
}


/* ============================================
   Passungs-Check Tool
   ============================================ */

.callout {
  background: var(--color-surface);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-16);
  padding: var(--space-24);
  box-shadow: var(--shadow-1);
}

.callout--warning {
  background: var(--tint-warning);
  border-color: rgba(180, 83, 9, 0.28);
}

.callout--danger {
  background: var(--tint-danger);
  border-color: rgba(180, 35, 24, 0.28);
}

.tool-intro .callout {
  background: var(--color-surface);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-16);
  padding: 1.5rem;
  box-shadow: var(--shadow-1);
}

.callout h2 {
  margin-bottom: 0.75rem;
}

.callout.warning {
  border-color: rgba(180, 83, 9, 0.35);
}

.bullet {
  margin: 1rem 0 0.5rem;
  padding-left: 1.25rem;
}

.bullet li {
  margin: 0.35rem 0;
}

.small-muted {
  font-size: 0.92rem;
  color: var(--color-text-500);
}

.tool-controls {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.tool-controls-right {
  display: flex;
  gap: 0.75rem;
}

.btn {
  appearance: none;
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  padding: 0.65rem 0.9rem;
  border-radius: var(--radius-12);
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-1);
  background: rgba(13, 93, 90, 0.04);
}

.btn:active {
  transform: translateY(0);
  box-shadow: none;
}

/* Button-System (Varianten) – bewusst NACH der späten .btn-Definition,
   damit Primary/Secondary/… nicht wieder von .btn überschrieben werden. */
.btn.btn--primary {
  background: var(--color-primary);
  border-color: rgba(13, 93, 90, 0.35);
  color: #fff;
  box-shadow: 0 10px 24px rgba(13, 93, 90, 0.18);
}

.btn.btn--primary:hover {
  background: var(--color-primary-hover);
  color: #fff !important;
  text-decoration: underline;
}

.btn.btn--secondary {
  background: rgba(13, 93, 90, 0.04);
  border-color: rgba(13, 93, 90, 0.18);
  color: var(--color-primary);
}

.btn.btn--secondary:hover {
  background: rgba(13, 93, 90, 0.07);
}

.btn.btn--ghost {
  background: transparent;
  border-color: transparent;
  color: var(--color-primary);
  box-shadow: none;
}

.btn.btn--ghost:hover {
  background: rgba(13, 93, 90, 0.06);
  border-color: rgba(13, 93, 90, 0.12);
}

.btn-success {
  border-color: rgba(20, 128, 74, 0.35);
  background: var(--tint-success);
}

.criteria-root {
  margin-top: 1rem;
}

.axis-details {
  background: var(--color-surface);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-16);
  padding: 0.25rem 1rem 1rem;
  margin-bottom: 1rem;
  box-shadow: var(--shadow-1);
}

.axis-summary {
  list-style: none;
  cursor: pointer;
  padding: 1rem 0.25rem 0.75rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.axis-summary::-webkit-details-marker {
  display: none;
}

.axis-summary-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.axis-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 86px;
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
  background: rgba(13, 93, 90, 0.10);
  color: var(--color-primary);
  font-weight: 700;
  font-size: 0.92rem;
}

.axis-title {
  font-weight: 700;
  color: var(--color-text-900);
}

.axis-hint {
  color: var(--color-text-500);
  font-size: 0.92rem;
  max-width: 360px;
  text-align: right;
}

.axis-quick {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
  padding: 0 0.25rem 0.75rem;
}

.pill {
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  border-radius: 999px;
  padding: 0.35rem 0.65rem;
  cursor: pointer;
  font-weight: 700;
}

.pill:hover {
  background: rgba(13, 93, 90, 0.06);
}

.criteria-list {
  display: grid;
  gap: 0.75rem;
}

.criteria-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 1rem;
  align-items: center;
  background: rgba(13, 93, 90, 0.03);
  border: 1px solid var(--color-border-subtle);
  border-radius: 14px;
  padding: 1rem;
}

.criteria-question {
  font-weight: 600;
  color: var(--color-text-900);
  margin-bottom: 0.25rem;
}

.criteria-meta {
  margin: 0;
}

.weight-fieldset {
  border: 0;
  padding: 0;
  margin: 0;
}

.weight-options {
  display: flex;
  gap: 0.4rem;
  justify-content: flex-end;
}

.weight-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.weight-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 40px;
  border-radius: var(--radius-12);
  border: 1px solid var(--color-border);
  background: var(--color-surface);
  cursor: pointer;
  font-weight: 800;
}

.weight-option input:focus + .weight-pill {
  outline: var(--focus-ring);
  outline-offset: var(--focus-offset);
}

.weight-option input:checked + .weight-pill {
  background: rgba(13, 93, 90, 0.10);
  border-color: rgba(13, 93, 90, 0.28);
  color: var(--color-primary);
}

.weight-pill-num {
  font-size: 1.05rem;
}

.results-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.results-grid {
  margin-top: 1.25rem;
  display: grid;
  /* Gleichmäßige Kartenbreiten wirken ruhiger. */
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.chart-card,
.summary-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-16);
  padding: 1.25rem;
  box-shadow: var(--shadow-1);
}

.chart-wrap {
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
}

.chart-wrap canvas {
  width: 100%;
  height: auto;
  display: block;
}

.legend {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
}


.axis-legend {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--color-border-subtle);
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.45rem;
  font-size: 0.92rem;
  color: #444;
}

.axis-legend-item {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
}

.axis-legend-key {
  flex: 0 0 auto;
  width: 1.25rem;
  font-weight: 900;
  color: var(--color-text-900);
}

.axis-legend-label {
  line-height: 1.25;
}

@media (min-width: 620px) {
  .axis-legend {
    grid-template-columns: 1fr 1fr;
  }
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: var(--color-text-700);
}

.legend-swatch {
  width: 12px;
  height: 12px;
  border-radius: 4px;
}

.summary-text {
  margin-top: 0.35rem;
}

.divider {
  height: 1px;
  background: var(--color-border-subtle);
  margin: 1rem 0;
}

.table-wrap {
  overflow-x: auto;
}

.result-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.result-table th,
.result-table td {
  padding: 0.7rem 0.6rem;
  border-bottom: 1px solid rgba(0,0,0,0.08);
  vertical-align: top;
}

.result-table thead th {
  text-align: left;
  font-size: 0.92rem;
  color: var(--color-text-500);
}

.td-num,
.td-weight {
  white-space: nowrap;
  text-align: right;
  font-weight: 700;
}

.td-axis-title {
  font-weight: 700;
  color: var(--color-text-900);
  margin-bottom: 0.25rem;
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

@media (max-width: 900px) {
  .results-grid {
    grid-template-columns: 1fr;
  }
  .axis-hint {
    max-width: 240px;
  }
  .criteria-row {
    grid-template-columns: 1fr;
  }
  .weight-options {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .btn,
  nav a {
    transition: none;
  }
}

/* Globale Fokus-Stati (sichtbar, konsistent) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[role="button"]:focus-visible {
  outline: var(--focus-ring);
  outline-offset: var(--focus-offset);
}
