/* Native CSS-Scroll-Snap-Bildspur; der gemeinsame Hero-Text bleibt fest. */
.hero-stage-slider__track {
  position: absolute;
  inset: 0;
  z-index: -2;
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
}

.hero-stage-slider__track::-webkit-scrollbar { display: none; }

.hero-stage-slider__slide {
  position: relative;
  flex: 0 0 100%;
  min-width: 0;
  height: 100%;
  scroll-snap-align: start;
  scroll-snap-stop: always;
}

.hero-stage-slider .hero-stage__image {
  inset: 0;
  width: 100%;
  z-index: auto;
}

.hero-stage-slider .hero-stage__composition { pointer-events: none; }

.hero-stage-slider__controls {
  pointer-events: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  width: fit-content;
  max-width: 100%;
  margin-top: 32px;
  padding: 8px;
  border-radius: 32px;
  background: #003454;
}

.hero-stage-slider__controls[hidden] { display: none; }
.hero-stage-slider__controls ion-icon { display: block; font-size: 20px; }

.hero-stage-slider__controls button {
  min-width: 44px;
  min-height: 44px;
  padding: 8px 12px;
  border: 2px solid transparent;
  border-radius: 24px;
  background: transparent;
  color: white;
  font: 700 14px/1.5 Arial, sans-serif;
  cursor: pointer;
  touch-action: manipulation;
  -webkit-user-select: none;
  user-select: none;
}

.hero-stage-slider__controls button:focus-visible {
  outline: 3px solid white;
  outline-offset: 3px;
}

.hero-stage-slider__arrow[aria-disabled="true"] {
  color: #afc8d8;
  cursor: default;
}

@media (hover: hover) and (pointer: fine) {
  .hero-stage-slider__controls button:not([aria-disabled="true"]):hover { border-color: white; }
}

/* Progressive Dekoration nach der Chrome-Guidance, ohne Polyfill. */
@supports ((animation-timeline: view()) and (animation-range: entry)) {
  @media (prefers-reduced-motion: no-preference) {
    .hero-stage-slider__slide {
      animation: hero-slider-image-reveal auto linear both;
      animation-timeline: view(inline);
    }
  }
}

@keyframes hero-slider-image-reveal {
  0%, 100% { opacity: .65; }
  50% { opacity: 1; }
}

/* In schmalen und Portrait-Ansichten steht das Motiv über dem Text.
   Der Fokus liegt rechts im Originalbild; cover darf nur Hintergrund kürzen. */
@media (max-width: 768px) {
  .hero-stage.hero-stage-slider {
    display: grid;
    grid-template-rows: 1fr max-content;
    align-items: stretch;
    padding: 0;
    background: #00434b;
  }

  .hero-stage-slider .hero-stage__composition {
    grid-row: 2;
    width: 100%;
    margin: 0;
    padding: clamp(28px, 4svh, 48px) 7vw 24px;
  }

  .hero-stage-slider .hero-stage__headline {
    font-size: clamp(40px, 6.8vw, 72px);
  }

  .hero-stage-slider .hero-stage__copy {
    max-width: 620px;
    margin-top: 20px;
    font-size: clamp(17px, 2.4vw, 22px);
  }

  .hero-stage-slider__controls {
    justify-self: end;
    margin-top: 20px;
    margin-inline-start: auto;
  }

  .hero-stage-slider__track {
    position: relative;
    inset: auto;
    grid-row: 1;
    min-height: 60svh;
  }

  .hero-stage-slider .hero-stage__image {
    object-position: 72% 100%;
  }

  .hero-stage-slider__slide::after {
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: 80px;
    background: linear-gradient(transparent, #00434b);
    pointer-events: none;
  }
}

@media (max-width: 650px) {
  .hero-stage-slider .hero-stage__composition { padding: 28px 24px 20px; }
  .hero-stage-slider .hero-stage__headline { font-size: clamp(34px, 9.6vw, 48px); }
  .hero-stage-slider .hero-stage__copy { font-size: 17px; }
  .hero-stage-slider .hero-stage__actions { margin-top: 20px; }
  .hero-stage-slider__track { min-height: 52svh; }
  .hero-stage-slider__controls { gap: 4px; padding: 6px; border-radius: 16px; }
  .hero-stage-slider__controls button { padding-inline: 8px; font-size: 13px; }
}

@media (max-width: 360px) {
  .hero-stage-slider .hero-stage__composition { padding-inline: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .hero-stage-slider__track { scroll-behavior: auto; }
}

@media (prefers-reduced-motion: no-preference) {
  .hero-stage-slider__track { scroll-behavior: smooth; }
}

@media (forced-colors: active) {
  .hero-stage-slider__controls { border: 1px solid CanvasText; }
  .hero-stage-slider__controls button { border-color: ButtonText; }
}
