/* ============================================
   HERO SLIDER — stories-style segment progress
   variant-11/css/hero-slider.css
   ============================================ */

.v8-slide {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  opacity: 0;
  transition: opacity 1.1s ease;
  will-change: opacity, transform;
}

.v8-slide.is-active {
  opacity: 1;
  animation: v8-kenburns 7s ease-out forwards;
}

@keyframes v8-kenburns {
  from { transform: scale(1); }
  to   { transform: scale(1.07); }
}

/* Slide images */
.v8-slide:nth-child(1) { background-image: url(../img/g11.jpg); }
.v8-slide:nth-child(2) { background-image: url(../img/tennis-court.jpg); }
.v8-slide:nth-child(3) { background-image: url(../img/CrossFit.jpg); }
.v8-slide:nth-child(4) { background-image: url(../img/gym.jpg); }
.v8-slide:nth-child(5) { background-image: url(../img/padel.jpg); }
.v8-slide:nth-child(6) { background-image: url(../img/beach-volleyball.jpg); }
.v8-slide:nth-child(7) { background-image: url(../img/fitness.jpg); }
.v8-slide:nth-child(8) { background-image: url(../img/mini-running-track.jpg); }

/* ── Segment progress bars ── */
.v8-segs {
  position: absolute;
  top: var(--s-3);
  left: 0; right: 0;
  z-index: 2;
  display: flex;
  gap: var(--s-2);
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

.v8-seg-group {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
  border-radius: 4px;
  padding-bottom: 4px;
}

.v8-seg {
  position: relative;
  width: 100%;
  height: 18px;
  background: transparent;
  border: none;
  padding: 0;
  cursor: pointer;
}

.v8-seg::before {
  content: '';
  position: absolute;
  left: 0; right: 0;
  top: 50%;
  height: 3px;
  margin-top: -1.5px;
  background: rgba(255,255,255,0.3);
  border-radius: 2px;
}

.v8-seg__fill {
  position: absolute;
  left: 0;
  top: 50%;
  height: 3px;
  margin-top: -1.5px;
  width: 0%;
  background: var(--c-white);
  border-radius: 2px;
  box-shadow: 0 0 6px rgba(255,255,255,0.45);
}

.v8-seg.is-active .v8-seg__fill {
  animation: v8-seg-fill 5s linear forwards;
}

.v8-seg.is-done .v8-seg__fill { width: 100%; }

@keyframes v8-seg-fill {
  from { width: 0%; }
  to   { width: 100%; }
}

/* ── Facility name ── */
.v8-fac {
  font-size: 10px;
  font-weight: 500;
  color: rgba(255,255,255,0.35);
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  letter-spacing: 0.02em;
  transition: color 0.3s ease;
  pointer-events: none;
}

.v8-seg-group.is-active .v8-fac {
  color: rgba(255,255,255,0.9);
  font-weight: 600;
}

.v8-seg-group:hover .v8-seg::before { background: rgba(255,255,255,0.55); }
.v8-seg-group:hover .v8-fac         { color: rgba(255,255,255,0.85); }

/* ── Click zones prev/next ── */
.v8-hero-zone {
  position: absolute;
  top: 0; bottom: 0;
  width: 22%;
  z-index: 2;
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background 0.25s ease;
  -webkit-tap-highlight-color: transparent;
}

.v8-hero-zone--prev { left: 0; }
.v8-hero-zone--next { right: 0; }
.v8-hero-zone:hover { background: rgba(0,0,0,0.12); }

@media (max-width: 767px) { .v8-hero-zone { display: none; } }

/* ── Hero content ── */
.v8-hero .hero__content {
  z-index: 3;
  padding-bottom: var(--s-16);
  padding-left: 16px;
  padding-right: 16px;
  pointer-events: none;
}

.v8-hero .hero__content a,
.v8-hero .hero__content button { pointer-events: auto; }

@media (min-width: 768px) {
  .v8-segs { top: var(--s-4); padding: 0 var(--container-pad-lg); }
}

@media (prefers-reduced-motion: reduce) {
  .v8-slide { transition: none; animation: none; }
  .v8-seg.is-active .v8-seg__fill { animation: none; width: 100%; }
}
