/* =============================================
   Shoppable Image — Hotspot Component
   ============================================= */

.shoppable-image {
  position: relative;
  display: block;
  line-height: 0; /* eliminates gap below <img> */
}

.shoppable-image img {
  width: 100%;
  height: auto;
  display: block;
}

/* ------------------------------------------
   Dot button
   - Positioned via CSS custom properties
     --hs-x (left %) and --hs-y (top %)
   - transform centers the dot on those coords
   ------------------------------------------ */
.hotspot-dot {
  position: absolute;
  left: var(--hs-x);
  top: var(--hs-y);
  transform: translate(-50%, -50%);
  width: 32px;
  height: 32px;
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Solid inner circle */
.hotspot-dot__inner {
  position: absolute;
  width: 24px;
  height: 24px;
  border: 1px solid #fff;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.25);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35);
  font-size: 17px;
  font-weight: 300;
  line-height: 24px;
  text-align: center;
  color: #fff;
  transition: transform 0.18s ease;
  z-index: 2;
}

/* Pulsing ring — animates outward and fades */
.hotspot-dot__ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.85);
  animation: hs-pulse 2.2s ease-out infinite;
}

/* Stagger a second ring for a richer feel */
.hotspot-dot__ring:nth-child(2) {
  animation-delay: 1.1s;
}

.hotspot-dot:hover .hotspot-dot__inner,
.hotspot-dot:focus-visible .hotspot-dot__inner {
  transform: scale(1.25);
}

.hotspot-dot:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 2px;
  border-radius: 50%;
}

/* ------------------------------------------
   Active state — dot becomes X close button
   ------------------------------------------ */
.hotspot-dot.si-peek-active .hotspot-dot__ring {
  animation: none;
  opacity: 0;
}

.hotspot-dot.si-peek-active .hotspot-dot__inner {
  opacity: 0;
}

.hotspot-dot.si-peek-active::after {
  content: '\00D7'; /* × */
  position: absolute;
  width: 24px;
  height: 24px;
  background: #fff;
  border-radius: 50%;
  font-size: 17px;
  font-weight: 300;
  line-height: 24px;
  text-align: center;
  color: #333;
  z-index: 2;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.25);
}

/* ------------------------------------------
   Pulse keyframes
   ------------------------------------------ */
@keyframes hs-pulse {
  0% {
    transform: scale(1);
    opacity: 0.9;
  }
  70% {
    transform: scale(2.4);
    opacity: 0;
  }
  100% {
    transform: scale(2.4);
    opacity: 0;
  }
}
