.wipe-image,
.wipe-media {
  position: relative;
  width: 100%;
  overflow: hidden;
  line-height: 0;
}

.wipe-media video{
  opacity: 0;
}

.wipe-bg {
  position: absolute;
  inset: 0;
  background: #e5e5e5;
  transform: scaleX(0);
  transform-origin: left;
  opacity: 1;
  z-index: 2;
}

.wipe-img,
.wipe-video {
  position: absolute;
  inset: 0;
  width: 99%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  z-index: 1;
  display: block;
}

.js-inview.is-active .wipe-bg {
  animation: wipe-bg 1.4s cubic-bezier(0, 0.55, 0.45, 1) forwards;
}

.js-inview.is-active .wipe-img,
.js-inview.is-active .wipe-video {
  animation: media-fade 0.8s ease 0.7s forwards;
}

@keyframes wipe-bg {
  0% { transform: scaleX(0); opacity: 1; }
  60% { transform: scaleX(1.02); opacity: 1; }
  100% { transform: scaleX(1.02); opacity: 0; }
}

@keyframes media-fade {
  to { opacity: 1; }
}
