.hbr-motion-hero {
  isolation: isolate;
  overflow: hidden;
  position: relative;
}

.hbr-motion-backdrop,
.hbr-motion-overlay {
  height: 100%;
  inset: 0;
  pointer-events: none;
  position: absolute;
  width: 100%;
}

.hbr-motion-backdrop {
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  transform-origin: center;
  z-index: 10;
  /* 6px drift plus 6px pointer = 12px; scale 1.02 and tilt 3deg are hard caps. */
  animation: hbr-hero-drift 14s ease-in-out infinite alternate;
}

.hbr-motion-overlay {
  background:
    linear-gradient(118deg, rgba(5, 24, 47, 0.54), rgba(5, 24, 47, 0.08) 55%, rgba(5, 24, 47, 0.36)),
    linear-gradient(105deg, transparent 42%, rgba(149, 209, 255, 0.13) 50%, transparent 58%);
  z-index: 11;
}

.hbr-motion-hero .container {
  position: relative;
  z-index: 12;
}

@keyframes hbr-hero-drift {
  from {
    transform: translate3d(calc(-6px + var(--hbr-pointer-x, 0px)), calc(-6px + var(--hbr-pointer-y, 0px)), 0) rotateX(var(--hbr-tilt-y, 0deg)) rotateY(var(--hbr-tilt-x, 0deg)) scale(1.02);
  }

  to {
    transform: translate3d(calc(6px + var(--hbr-pointer-x, 0px)), calc(6px + var(--hbr-pointer-y, 0px)), 0) rotateX(var(--hbr-tilt-y, 0deg)) rotateY(var(--hbr-tilt-x, 0deg)) scale(1.02);
  }
}

.hbr-motion-ready .hbr-motion-reveal,
.hbr-motion-ready .hbr-motion-media {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 600ms ease, transform 600ms ease;
}

.hbr-motion-ready .hbr-motion-reveal.is-hbr-visible,
.hbr-motion-ready .hbr-motion-media.is-hbr-visible {
  opacity: 1;
  transform: none;
}

@media (min-width: 768px) and (hover: hover) and (pointer: fine) {
  .hbr-motion-ready .hbr-motion-media.is-hbr-visible:hover {
    transform: scale(1.015);
  }
}

@media (max-width: 767px) {
  .hbr-motion-backdrop {
    animation: none;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hbr-motion-backdrop,
  .hbr-motion-overlay,
  .hbr-motion-ready .hbr-motion-reveal,
  .hbr-motion-ready .hbr-motion-media {
    animation: none !important;
    transition: none !important;
  }

  .hbr-motion-backdrop,
  .hbr-motion-ready .hbr-motion-reveal,
  .hbr-motion-ready .hbr-motion-media {
    opacity: 1 !important;
    transform: none !important;
  }
}
