/* Homepage photo carousel: independent background layer, never blocks hero controls. */
.ssl-hero__background {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  /* Confine animated photo paints to the background rectangle. */
  contain: paint;
  background: #061321;
}
.ssl-hero__background img {
  position: absolute;
  inset: -2%;
  width: 104%;
  height: 104%;
  display: block;
  object-fit: cover;
  object-position: center center;
  opacity: 0;
  /* Avoid animating zoom + GPU filters on seven full-bleed photos.
     Those competing composited surfaces could flash on CTA/nav hover.
     Preserve the timed crossfade with a single animated property. */
  animation: ssl-hero-photo-cycle 42s linear infinite both;
}
/* Seven 6-second scenes. Continuous transitions, including the last-to-first handoff. */
.ssl-hero__background img:nth-child(1) { animation-delay: 0s; object-position: 58% 48%; }
.ssl-hero__background img:nth-child(2) { animation-delay: -36s; object-position: 60% 47%; }
.ssl-hero__background img:nth-child(3) { animation-delay: -30s; object-position: 60% 47%; }
.ssl-hero__background img:nth-child(4) { animation-delay: -24s; object-position: 44% 48%; }
.ssl-hero__background img:nth-child(5) { animation-delay: -18s; object-position: 50% 51%; }
.ssl-hero__background img:nth-child(6) { animation-delay: -12s; object-position: 56% 47%; }
.ssl-hero__background img:nth-child(7) { animation-delay: -6s; object-position: 54% 51%; }
/* The dark gradient keeps headline and CTA legible over any photograph. */
.ssl-hero__background::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(5, 15, 28, .89) 0%, rgba(5, 15, 28, .80) 38%, rgba(5, 15, 28, .59) 70%, rgba(5, 15, 28, .55) 100%),
    linear-gradient(180deg, rgba(5, 15, 28, .38), transparent 32%, rgba(5, 15, 28, .44));
}
.ssl-hero > .ssl-hero__container { position: relative; z-index: 2; }
/* Preserve the seven-scene sequence and last-to-first crossfade while
   animating opacity only, so hover changes do not force zoom rerasterization. */
@keyframes ssl-hero-photo-cycle {
  0%    { opacity: .78; }
  10%   { opacity: .78; }
  12.5% { opacity: 0; }
  97.5% { opacity: 0; }
  100%  { opacity: .78; }
}
@media (max-width: 1050px) {
  .ssl-hero__background::after {
    background: linear-gradient(180deg, rgba(5,15,28,.77), rgba(5,15,28,.61) 48%, rgba(5,15,28,.71));
  }
}
@media (max-width: 650px) {
  /* Lighter photos, with an even navy scrim to protect white/orange copy. */
  .ssl-hero__background img { object-fit: cover; }
  /* Preserve the subjects on narrow screens even with cover cropping. */
  .ssl-hero__background img:nth-child(1) { object-position: 68% center; }
  .ssl-hero__background img:nth-child(2) { object-position: 64% center; }
  .ssl-hero__background img:nth-child(3) { object-position: 69% center; }
  .ssl-hero__background img:nth-child(4) { object-position: 35% center; }
  .ssl-hero__background img:nth-child(5) { object-position: 52% center; }
  .ssl-hero__background img:nth-child(6) { object-position: 55% center; }
  .ssl-hero__background img:nth-child(7) { object-position: 54% center; }
  .ssl-hero__background::after {
    background: linear-gradient(180deg, rgba(5,15,28,.74), rgba(5,15,28,.60) 55%, rgba(5,15,28,.68));
  }
}
/* Respect motion preferences: keep a single static image rather than fading. */
@media (prefers-reduced-motion: reduce) {
  .ssl-hero__background img { animation: none; opacity: 0; }
  .ssl-hero__background img:first-child { opacity: .65; }
}
