.fullpage-slide:has(.slide-lottie) .outer,
.fullpage-slide:has(.slide-lottie) .inner {
  overflow: visible;
}
/* Lottie above blur overlay so white strokes stay crisp (overlay tints SVG sections) */
.fullpage-slide .slide-lottie {
  display: block;
  box-sizing: border-box;
  pointer-events: none;
  z-index: 2;
  color: #ffffff;
  isolation: isolate;
  background: transparent;
}

/* Raum infotheke banner: soften hard top edge under glass nav */
.slide-lottie--wide-banner {
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 clamp(3.5rem, 16%, 7rem));
  mask-image: linear-gradient(to bottom, transparent 0%, #000 clamp(3.5rem, 16%, 7rem));
}

/* Full-bleed canvas (no split stack): viewport-centered, then nudged up */
.fullpage-slide .bg > .slide-lottie {
  position: absolute;
  left: 50%;
  top: 50%;
  width: min(130vw, 100rem);
  max-width: none;
  height: min(85dvh, 100%);
  max-height: min(85dvh, 100%);
  transform: translate(-50%, -50%);
  margin-top: -4rem;
}

/* Lottie + title: stack sizes the canvas; animation uses contain inside canvas */
.fullpage-slide .lottie-split-stack {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  margin-top: clamp(-10rem, -12dvh, -4rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(1rem, 3dvh, 2rem);
  z-index: 2;
  pointer-events: none;
  width: min(130vw, 90rem);
  max-width: none;
  box-sizing: border-box;
}

.fullpage-slide .lottie-split-stack .slide-lottie {
  position: relative;
  inset: auto;
  width: 100%;
  height: auto;
  max-height: min(85dvh, 100%);
}


.lottie-split-title {
  text-align: center;
}

.fullpage-slide .lottie-split-title {
  max-width: min(130vw, 90rem);
  margin: 0;
  padding: 0 1rem;
  box-sizing: border-box;
  color: #fff;
  font-family: "Source Sans Pro", sans-serif;
  font-size: clamp(1.25rem, 4vmin + 1.5vw + 0.25vh, 5.375rem);
  font-style: normal;
  font-weight: 600;
  line-height: 1.06;
}
@media (max-width: 1079px) {
  .fullpage-slide:has(#gebaeude-scroll-lottie) .bg > .slide-lottie {
    transform: translate(-50%, calc(-50% + 4rem));
  }
}

@media (max-height: 700px) {
  .fullpage-slide .bg > .slide-lottie {
    height: min(85dvh, 100%);
    max-height: min(85dvh, 100%);
    min-height: 50dvh;
  }

  .fullpage-slide .lottie-split-title {
    display: none;
  }

  .fullpage-slide .lottie-split-stack {
    top: var(--glass-nav-safe-top);
    bottom: var(--fullpage-next-reserve);
    transform: translate(-50%, 0);
    margin-top: 0;
    gap: 0;
    justify-content: center;
  }

  .fullpage-slide .lottie-split-stack .slide-lottie {
    flex: 1 1 auto;
    min-height: 0;
    max-height: 100%;
    width: 100%;
    height: auto;
  }
}

@media (max-height: 700px) and (max-width: 1079px) {
  .fullpage-slide .lottie-split-stack {
    top: env(safe-area-inset-top, 0px);
  }

  .fullpage-slide[data-fullpage-primary="service"] .lottie-split-stack {
    transform: translate(-50%, -5rem);
  }

  .fullpage-slide[data-fullpage-primary="statistik"] .lottie-split-stack {
    transform: translate(-50%, -2rem);
  }

  .fullpage-slide[data-fullpage-primary="kultur"] .lottie-split-stack {
    transform: translate(-50%, -2rem);
  }
}
