/* ---------- Sprite container ---------- */
.thumb {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 15px;
}

/* Only remove bg when THIS thumb actually has a sprite */
.thumb:has(.video-splash.is-sprite):hover {
  background-image: none !important;
}

/* ---------- Sprite sheet element ---------- */
.video-splash.is-sprite {
  position: absolute;
  inset: 0;
  display: block;
  z-index: 2;
  will-change: background-position;

  background-repeat: no-repeat;

  /* sensible defaults to prevent 0px flash */
  background-size: cover;
  background-position: 0 0;

  /* JS will override these */
  --bgW: 0px;
  --bgH: 0px;
  --posX: 0px;
  --posY: 0px;

  background-size: var(--bgW) var(--bgH);
  background-position: var(--posX) var(--posY);

  user-select: none;
  pointer-events: none;
}
