/* ----------------------------------------------------------------------------
   Eigene Ergaenzungen (ersetzen die frueher von der React-App gesteuerten
   Zustaende). Enthaelt Hero-Slider- und Mobile-Menue-Styles.
---------------------------------------------------------------------------- */

/* Hero-Slider: nur der aktive Slide ist sichtbar */
.hero-slide {
  opacity: 0;
  transition: opacity 1s ease-in-out;
  pointer-events: none;
}
.hero-slide.is-active {
  opacity: 1;
  z-index: 10;
  pointer-events: auto;
}
/* Verhindert das kurze Aufblitzen des alt-Textes, solange das grosse Slider-Bild
   noch laedt: der alt-Text wird unsichtbar geschaltet (bleibt im Markup fuer
   Screenreader und SEO erhalten), und als Platzhalter dient ein Hintergrund in
   Markenfarbe statt des weissen Seitenhintergrunds. */
.hero-slide { background-color: #003d7a; }
.hero-slide img { color: transparent; }

/* Fallback, falls kein JavaScript laeuft: ersten Slide zeigen */
.no-js .hero-slide:first-child {
  opacity: 1;
  z-index: 10;
  pointer-events: auto;
}

/* ----------------------------------------------------------------------------
   Hero-Slider auf dem Smartphone (Startseite)
   Die Hero-Bilder sind breite Panoramen (z.B. 1920x518). In einem 700px hohen,
   schmalen Hochkant-Hero zeigt object-cover nur einen extrem hineingezoomten
   Mittelstreifen -> das Motiv ist kaum erkennbar. Ausserdem schneidet das
   overflow-hidden lange Komposita (Krankenversicherung, Berufsunfaehigkeit)
   rechts ab. Darum auf schmalen Screens: flacheres Hero (mehr Bild, weniger
   Zoom), helleres Overlay und umbrechende/getrennte Ueberschriften.
---------------------------------------------------------------------------- */
@media (max-width: 767px) {
  .hero-viewport {
    height: 560px;
  }

  /* Lange Woerter umbrechen bzw. mit Silbentrennung brechen statt abschneiden;
     Schriftgroesse an die Viewport-Breite koppeln, damit nichts ueberlaeuft. */
  .hero-slide h2 {
    font-size: clamp(1.75rem, 8vw, 2.75rem);
    line-height: 1.15;
    -webkit-hyphens: auto;
    hyphens: auto;
    overflow-wrap: break-word;
    word-break: break-word;
  }

  /* Overlay weniger dunkel, damit vom Hintergrundbild mehr sichtbar bleibt
     (Text bleibt dank drop-shadow und kleinerer Ueberschrift gut lesbar). */
  .hero-slide .bg-gradient-to-r {
    background-image: linear-gradient(to right, rgba(0, 0, 0, .55), rgba(0, 0, 0, .35), rgba(0, 0, 0, .05)) !important;
  }
}

/* Die seitlichen Vor-/Zurueck-Pfeile sind vertikal zentriert und liegen unter
   der vollen Desktop-Breite (< lg) mitten auf der Ueberschrift/dem Text --
   auch auf dem iPad im Hochformat (768-834px). Daher auf Smartphone UND Tablet
   ausblenden; navigiert wird ueber die Punkte unten und den automatischen
   Wechsel. Erst ab 1024px (Desktop) ist seitlich genug Platz. */
@media (max-width: 1023px) {
  .hero-viewport [aria-label="Previous slide"],
  .hero-viewport [aria-label="Next slide"] {
    display: none;
  }
}

/* ----------------------------------------------------------------------------
   Navigations-Dropdowns (Desktop): oeffnen per Hover, Fokus (Tastatur) oder
   .open (Klick/Touch via main.js). Das pt-* am .nav-dropdown bildet eine
   transparente Bruecke, damit der Hover zwischen Button und Panel nicht abreisst.
---------------------------------------------------------------------------- */
/* Nur opacity/visibility animieren - KEIN transform, damit Tailwinds
   -translate-x-1/2 (Zentrierung der breiten Mega-Menues) erhalten bleibt. */
.nav-dropdown {
  opacity: 0;
  visibility: hidden;
  transition: opacity .18s ease, visibility .18s;
}
.nav-item:hover > .nav-dropdown,
.nav-item:focus-within > .nav-dropdown,
.nav-item.open > .nav-dropdown {
  opacity: 1;
  visibility: visible;
}
.nav-trigger .ri-arrow-down-s-line {
  transition: transform .2s ease;
}
.nav-item:hover > .nav-trigger .ri-arrow-down-s-line,
.nav-item.open > .nav-trigger .ri-arrow-down-s-line {
  transform: rotate(180deg);
}

/* Kompakte Kopfgrafik der Rechner-Seiten */
.rechner-hero { height: 225px; }
@media (min-width: 768px) { .rechner-hero { height: 315px; } }

/* In der kompilierten app.css nicht enthaltene Tailwind-Utilities (nachgeruestet) */
.w-\[900px\] { width: 900px; }
.w-\[1100px\] { width: 1100px; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.list-disc { list-style-type: disc; }
.list-inside { list-style-position: inside; }
.aspect-video { aspect-ratio: 16 / 9; }
.max-h-14 { max-height: 3.5rem; }
.object-contain { object-fit: contain; }
.underline { text-decoration-line: underline; }
.mt-14 { margin-top: 3.5rem; }
.object-right { object-position: right; }

/* Further plain Tailwind utilities missing from the compiled app.css bundle -- retrofitted here
   the same way as above. Includes the "space-y-*" utilities used on most bulleted lists on the
   site, and the "pb-5"/"md:pb-7" padding used on every hero image's text overlay. */
.space-y-0\.5 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.125rem; }
.space-y-1 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.25rem; }
.space-y-1\.5 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.375rem; }
.space-y-2 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.5rem; }
.space-y-3 > :not([hidden]) ~ :not([hidden]) { margin-top: 0.75rem; }
.space-y-4 > :not([hidden]) ~ :not([hidden]) { margin-top: 1rem; }
.space-y-5 > :not([hidden]) ~ :not([hidden]) { margin-top: 1.25rem; }
.space-y-6 > :not([hidden]) ~ :not([hidden]) { margin-top: 1.5rem; }
.space-y-8 > :not([hidden]) ~ :not([hidden]) { margin-top: 2rem; }
.space-y-10 > :not([hidden]) ~ :not([hidden]) { margin-top: 2.5rem; }

.gap-0\.5 { gap: 0.125rem; }
.gap-10 { gap: 2.5rem; }
.gap-x-8 { column-gap: 2rem; }
.gap-y-10 { row-gap: 2.5rem; }

.mt-1\.5 { margin-top: 0.375rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-10 { margin-top: 2.5rem; }
.ml-2 { margin-left: 0.5rem; }

.pt-1 { padding-top: 0.25rem; }
.pt-6 { padding-top: 1.5rem; }
.pt-10 { padding-top: 2.5rem; }
.pt-16 { padding-top: 4rem; }
.pb-5 { padding-bottom: 1.25rem; }
.pb-6 { padding-bottom: 1.5rem; }
.pb-16 { padding-bottom: 4rem; }

.h-2\.5 { height: 0.625rem; }
.h-auto { height: auto; }
.w-2\.5 { width: 0.625rem; }
.w-24 { width: 6rem; }
.w-auto { width: auto; }
.min-w-0 { min-width: 0px; }

.left-1 { left: 0.25rem; }
.right-1 { right: 0.25rem; }

.border-l { border-left-width: 1px; }
.break-all { word-break: break-all; }
.flex-shrink-0 { flex-shrink: 0; }
.scroll-smooth { scroll-behavior: smooth; }
.transition { transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter; transition-duration: .15s; transition-timing-function: cubic-bezier(.4,0,.2,1); }
.max-w-md { max-width: 28rem; }
.text-6xl { font-size: 3.75rem; line-height: 1; }
.text-\[11px\] { font-size: 11px; }
.text-yellow-400 { color: #facc15; }
.hover\:text-green-700:hover { color: #15803d; }
/* Middle stop for the same three-color hero-overlay gradient as from-black/65 and to-transparent
   (both already compiled into app.css), using the same --tw-gradient-* custom-property pattern
   Tailwind generates for gradient utilities. */
.via-black\/35 { --tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), rgb(0 0 0 / 0.35) var(--tw-gradient-via-position), var(--tw-gradient-to); }

@media (min-width: 640px) {
  .sm\:-left-5 { left: -1.25rem; }
  .sm\:-right-5 { right: -1.25rem; }
  .sm\:w-11 { width: 2.75rem; }
  .sm\:h-11 { height: 2.75rem; }
}
@media (min-width: 768px) {
  .md\:pb-7 { padding-bottom: 1.75rem; }
  .md\:pt-24 { padding-top: 6rem; }
  .md\:py-14 { padding-top: 3.5rem; padding-bottom: 3.5rem; }
  .md\:col-span-2 { grid-column: span 2 / span 2; }
  .md\:w-1\/2 { width: 50%; }
  .md\:object-center { object-position: center; }
  .md\:flex-row { flex-direction: row; }
}

/* Semantic "primary/foreground/background/accent" color utilities used throughout the
   templates (buttons, borders, body text) are not part of the compiled app.css bundle
   either -- retrofitted here the same way as the plain utilities above. Values: primary
   reuses the site's existing brand blue shades (#0053a1 / #003d7a / #00254d, already used
   as literal colors elsewhere); foreground/background reuse Tailwind's own default gray
   scale (already compiled into app.css as text-gray-* / bg-gray-*, so this keeps the two
   naming schemes visually identical); accent reuses Tailwind's default cyan scale. */
.bg-primary-50 { background-color: #eef5fb; }
.bg-primary-100 { background-color: #d6e8f5; }
.bg-primary-500 { background-color: #0053a1; }
.hover\:bg-primary-300:hover { background-color: #8cb2d5; }
.hover\:bg-primary-600:hover { background-color: #003d7a; }
.border-primary-500 { border-color: #0053a1; }
.hover\:border-primary-300:hover { border-color: #8cb2d5; }
.hover\:border-primary-500:hover { border-color: #0053a1; }
.focus\:border-primary-500:focus { border-color: #0053a1; }
.text-primary-500 { color: #0053a1; }
.text-primary-600 { color: #003d7a; }
.hover\:text-primary-600:hover { color: #003d7a; }
.hover\:text-primary-700:hover { color: #00254d; }
.group:hover .group-hover\:text-primary-700 { color: #00254d; }
.ring-primary-500 { --tw-ring-color: #0053a1; }
.focus\:ring-primary-500:focus { --tw-ring-color: #0053a1; }
.focus\:ring-primary-100:focus { --tw-ring-color: #d6e8f5; }
.from-primary-500 { --tw-gradient-from: #0053a1 var(--tw-gradient-from-position); --tw-gradient-to: #0053a100 var(--tw-gradient-to-position); --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to); }
.to-primary-700 { --tw-gradient-to: #00254d var(--tw-gradient-to-position); }

.bg-background-50 { background-color: #f9fafb; }
.bg-background-100 { background-color: #f3f4f6; }
.bg-background-300 { background-color: #d1d5db; }
.border-background-200 { border-color: #e5e7eb; }
.border-background-300 { border-color: #d1d5db; }
.hover\:border-background-300:hover { border-color: #d1d5db; }
.text-background-50 { color: #f9fafb; }

.text-foreground-400 { color: #9ca3af; }
.text-foreground-500 { color: #6b7280; }
.text-foreground-600 { color: #4b5563; }
.text-foreground-700 { color: #374151; }
.text-foreground-900 { color: #111827; }
.hover\:text-foreground-900:hover { color: #111827; }

.bg-accent-100 { background-color: #cffafe; }
.text-accent-600 { color: #0891b2; }

/* Mobile-Accordion */
.mobile-sub.open {
  display: block;
}
.mobile-acc.open .ri-arrow-down-s-line {
  transform: rotate(180deg);
}
.mobile-acc .ri-arrow-down-s-line {
  transition: transform .2s ease;
}

/* ----------------------------------------------------------------------------
   Cookie-Consent-Banner (PrivacyPolicies.com) – kompakter & im Altera-Blau,
   exakt wie auf www.altera-finanz.de.
---------------------------------------------------------------------------- */
.cc-nb-main-container,
.cc-cp-container {
  font-size: 13px !important;
  line-height: 1.45 !important;
}
.cc-nb-main-container {
  max-width: 760px !important;
  margin: 0 auto 12px !important;
  padding: 10px 12px !important;
  border-radius: 8px !important;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .12) !important;
}
.cc-nb-title,
.cc-cp-head {
  font-size: 14px !important;
  font-weight: 600 !important;
}
.cc-nb-text,
.cc-cp-body {
  font-size: 13px !important;
}
.cc-nb-buttons-container {
  gap: 8px !important;
}
.cc-nb-okagree,
.cc-nb-reject,
.cc-nb-changep,
.cc-cp-foot-save,
.cc-cp-foot-accept {
  background: #0053a1 !important;
  border: 1px solid #0053a1 !important;
  color: #ffffff !important;
  border-radius: 4px !important;
  font-size: 12px !important;
  font-weight: 500 !important;
  padding: 7px 12px !important;
  min-height: 34px !important;
}
.cc-nb-okagree:hover,
.cc-nb-reject:hover,
.cc-nb-changep:hover,
.cc-cp-foot-save:hover,
.cc-cp-foot-accept:hover {
  background: #004481 !important;
  border-color: #004481 !important;
}
@media only screen and (max-width: 767px) {
  .cc-nb-main-container {
    max-width: calc(100% - 16px) !important;
    margin: 0 8px 8px !important;
    padding: 8px 10px !important;
  }
}
