.product-detail-view .main-image img {
  cursor: zoom-in;
}

.product-image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  background: rgba(0, 0, 0, 0.88);
  backdrop-filter: blur(3px);
}

.product-image-lightbox__image {
  display: block;
  width: auto;
  height: auto;
  max-width: min(94vw, 1600px);
  max-height: 92vh;
  object-fit: contain;
  background: #fff;
  box-shadow: 0 12px 48px rgba(0, 0, 0, 0.4);
  transition: opacity 160ms ease, transform 160ms ease;
}

.product-image-lightbox__image.is-changing {
  opacity: 0.72;
  transform: scale(0.995);
}

.product-image-lightbox__close {
  position: fixed;
  top: 18px;
  right: 24px;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 50%;
  color: #fff;
  background: rgba(0, 0, 0, 0.45);
  font: 38px/40px Arial, sans-serif;
  cursor: pointer;
}

.product-image-lightbox__close:hover,
.product-image-lightbox__close:focus-visible,
.product-image-lightbox__nav:hover,
.product-image-lightbox__nav:focus-visible {
  background: #009bb1;
  outline: 2px solid #fff;
  outline-offset: 2px;
}

.product-image-lightbox__nav {
  position: fixed;
  top: 50%;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 56px;
  height: 72px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 18px;
  color: #fff;
  background: rgba(0, 0, 0, 0.46);
  transform: translateY(-50%);
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.product-image-lightbox__nav:hover {
  border-color: #fff;
  transform: translateY(-50%) scale(1.04);
}

.product-image-lightbox__nav svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.product-image-lightbox__nav--prev {
  left: max(16px, 2vw);
}

.product-image-lightbox__nav--next {
  right: max(16px, 2vw);
}

.product-image-lightbox__counter {
  position: fixed;
  left: 50%;
  bottom: 18px;
  min-width: 66px;
  padding: 7px 14px;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 999px;
  color: #fff;
  background: rgba(0, 0, 0, 0.52);
  font: 500 14px/1.2 Arial, sans-serif;
  text-align: center;
  transform: translateX(-50%);
}

@media (max-width: 640px) {
  .product-image-lightbox {
    padding: 12px;
  }

  .product-image-lightbox__image {
    max-width: 96vw;
    max-height: 88vh;
  }

  .product-image-lightbox__close {
    top: 10px;
    right: 10px;
  }

  .product-image-lightbox__nav {
    width: 44px;
    height: 58px;
    border-radius: 14px;
  }

  .product-image-lightbox__nav--prev {
    left: 8px;
  }

  .product-image-lightbox__nav--next {
    right: 8px;
  }

  .product-image-lightbox__nav svg {
    width: 24px;
    height: 24px;
  }

  .product-image-lightbox__counter {
    bottom: 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .product-image-lightbox__image,
  .product-image-lightbox__nav {
    transition: none;
  }
}
