/* Wild Gaze – premium scroll reveal (fade + rise, hardware-accelerated)
   Progressive: content stays visible until JS enables .wg-reveal-on,
   so mobile never flashes blank while scripts load. */

.wg-sr,
.wg-reveal,
.wg-reveal-left,
.wg-reveal-right,
.wg-reveal-up,
.wg-reveal-scale {
  opacity: 1;
  transform: none;
  transition:
    opacity 0.55s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.55s cubic-bezier(0.16, 1, 0.3, 1);
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

/* Armed only after JS marks targets + reveals above-the-fold */
html.wg-reveal-on .wg-sr:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal-left:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal-right:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal-up:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal-scale:not(.is-visible):not(.is-revealed) {
  opacity: 0 !important;
  visibility: visible !important;
  transform: translate3d(0, 24px, 0);
  will-change: opacity, transform;
}

html.wg-reveal-on .wg-sr.from-left:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal-left:not(.is-visible):not(.is-revealed) {
  transform: translate3d(-40px, 30px, 0);
}

html.wg-reveal-on .wg-sr.from-right:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal-right:not(.is-visible):not(.is-revealed) {
  transform: translate3d(40px, 30px, 0);
}

html.wg-reveal-on .wg-sr.from-up:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-reveal-up:not(.is-visible):not(.is-revealed) {
  transform: translate3d(0, 30px, 0);
}

html.wg-reveal-on .wg-reveal-scale:not(.is-visible):not(.is-revealed) {
  transform: translate3d(0, 20px, 0) scale(0.96);
}

/* Legacy destination cards (inline opacity:0 + .reveal) */
html.wg-reveal-on .wg-zan-exp-card.wg-sr:not(.is-visible):not(.is-revealed),
html.wg-reveal-on .wg-pemba-exp-card.wg-sr:not(.is-visible):not(.is-revealed) {
  opacity: 0 !important;
  transform: translate3d(0, 32px, 0) !important;
}

.wg-zan-exp-card.wg-sr.is-visible,
.wg-zan-exp-card.wg-sr.is-revealed,
.wg-zan-exp-card.reveal,
.wg-pemba-exp-card.wg-sr.is-visible,
.wg-pemba-exp-card.wg-sr.is-revealed,
.wg-pemba-exp-card.reveal {
  opacity: 1 !important;
  transform: translate3d(0, 0, 0) !important;
}

.wg-sr.is-visible,
.wg-sr.is-revealed,
.wg-reveal.is-visible,
.wg-reveal.is-revealed,
.wg-reveal-left.is-visible,
.wg-reveal-left.is-revealed,
.wg-reveal-right.is-visible,
.wg-reveal-right.is-revealed,
.wg-reveal-up.is-visible,
.wg-reveal-up.is-revealed,
.wg-reveal-scale.is-visible,
.wg-reveal-scale.is-revealed {
  opacity: 1 !important;
  visibility: visible !important;
  transform: translate3d(0, 0, 0) scale(1) !important;
  will-change: auto;
}

/* Mobile: same reveal, lighter motion (fade-up only, shorter distance/duration) */
@media (max-width: 768px) {
  .wg-sr,
  .wg-reveal,
  .wg-reveal-left,
  .wg-reveal-right,
  .wg-reveal-up,
  .wg-reveal-scale {
    transition:
      opacity 0.4s cubic-bezier(0.16, 1, 0.3, 1),
      transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  }

  html.wg-reveal-on .wg-sr:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-left:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-right:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-up:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-scale:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-sr.from-left:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-sr.from-right:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-sr.from-up:not(.is-visible):not(.is-revealed) {
    opacity: 0 !important;
    transform: translate3d(0, 16px, 0);
  }
}

/* Card / section shells */
.wg-sr.wg-card,
.wg-sr.wg-cj-card,
.wg-sr.wg-pop-itin-card,
.wg-sr.wg-tz-card,
.wg-sr.wg-shortcut-card,
.wg-sr.wg-tier-card,
.wg-sr.wg-dest-gallery-item,
.wg-sr[class*="-section"],
.wg-sr[class*="-block"] {
  backface-visibility: hidden;
}

/* Never hide nav chrome, heroes, forms, or card interior labels */
.navbar-wrap,
.navbar-wrap *:not(.dropdown-panel):not(.dropdown-panel *):not(.mobile-drawer):not(.mobile-drawer *):not(.mobile-backdrop),
.wg-page-header,
.wg-page-header *,
.wg-home-hero,
.wg-home-hero *,
.wg-site-footer,
.wg-site-footer *,
.wg-search-overlay.open,
.wg-search-overlay.open *,
.wg-book-form,
.wg-book-form *,
#booking,
#booking *,
.wg-book-form-card,
.wg-book-side-card,
.wg-sr-skip,
.wg-sr-skip *,
.no-reveal,
.no-reveal *,
.no-reveal-children,
.no-reveal-children *,
.wg-card-nameplate,
.wg-card-nameplate *,
.wg-card-title,
.wg-card-meta,
.wg-wa-float {
  opacity: 1 !important;
  visibility: visible !important;
}

/* About photography – keep media sharp; scroll-reveal runs on the shell */
.wg-about-gallery-item img,
.wg-about-mosaic-item img,
.wg-about-team-card img,
.wg-about-bts-main img,
.wg-about-bts-stack-item img,
.wg-about-mosaic-cap,
.wg-about-gallery-cap {
  opacity: 1 !important;
  visibility: visible !important;
  transform: none !important;
}

@media (prefers-reduced-motion: reduce) {
  .wg-sr,
  .wg-reveal,
  .wg-reveal-left,
  .wg-reveal-right,
  .wg-reveal-up,
  .wg-reveal-scale,
  html.wg-reveal-on .wg-sr:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-left:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-right:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-up:not(.is-visible):not(.is-revealed),
  html.wg-reveal-on .wg-reveal-scale:not(.is-visible):not(.is-revealed) {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
    will-change: auto !important;
  }
}
