.product-gallery.cdo-product-media-gallery {
  min-width: 0;
  gap: 10px;
}

.product-gallery > .cdo-product-media-stage {
  display: block;
  grid-template-columns: none;
  gap: 0;
}

.product-gallery > .cdo-product-media-strip {
  display: flex;
  grid-template-columns: none;
  gap: 8px;
}

.cdo-product-image-disclaimer {
  display: block;
  width: 100%;
  margin: -2px 0 0;
  color: #6b7280;
  font-size: .7rem;
  line-height: 1.35;
  text-align: center;
}

.cdo-product-image-disclaimer[hidden] {
  display: none;
}

.cdo-product-media-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: #fff;
  box-shadow: var(--shadow-soft);
  outline: none;
  touch-action: pan-y;
}

.cdo-product-media-stage:focus-visible {
  box-shadow: 0 0 0 3px rgba(29, 44, 140, .22), var(--shadow-soft);
}

.cdo-product-media-viewport,
.cdo-product-media-frame {
  width: 100%;
  height: 100%;
}

.cdo-product-media-frame {
  display: grid;
  place-items: center;
  background: #fff;
}

.cdo-product-media-frame > img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.cdo-product-media-frame > iframe {
  width: 100%;
  height: 100%;
  border: 0;
  background: #0b1020;
}

.cdo-product-media-frame.is-vertical > iframe {
  width: min(100%, 360px);
}

.cdo-product-media-frame.is-instagram {
  background: linear-gradient(145deg, #f6f7fb, #fff);
}

.cdo-product-media-counter {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 2;
  min-width: 52px;
  padding: 7px 10px;
  border-radius: 999px;
  color: #fff;
  background: rgba(11, 16, 32, .76);
  text-align: center;
  font-size: .78rem;
  font-weight: 900;
  line-height: 1;
  backdrop-filter: blur(8px);
}

.cdo-product-media-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  padding: 0 0 4px;
  transform: translateY(-50%);
  border: 1px solid rgba(29, 44, 140, .16);
  border-radius: 999px;
  color: var(--color-primary);
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 8px 24px rgba(29, 44, 140, .18);
  font-size: 2rem;
  line-height: 1;
}

.cdo-product-media-arrow.is-previous { left: 12px; }
.cdo-product-media-arrow.is-next { right: 12px; }

.cdo-product-media-strip {
  display: flex;
  gap: 8px;
  max-width: 100%;
  padding: 2px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.cdo-product-media-thumb {
  position: relative;
  flex: 0 0 74px;
  width: 74px;
  height: 74px;
  overflow: hidden;
  border: 2px solid transparent;
  border-radius: 10px;
  background: #eef2ff;
  padding: 0;
}

.cdo-product-media-thumb.is-active {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(29, 44, 140, .12);
}

.cdo-product-media-thumb > img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.cdo-product-media-thumb > span {
  position: absolute;
  inset: 50% auto auto 50%;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  transform: translate(-50%, -50%);
  border-radius: 999px;
  color: #fff;
  background: #e3062b;
  font-size: .9rem;
}

.cdo-product-media-thumb.is-instagram {
  display: grid;
  place-items: center;
  align-content: center;
  gap: 4px;
  color: #fff;
  background: linear-gradient(145deg, #833ab4, #fd1d1d 58%, #fcb045);
}

.cdo-product-media-thumb.is-instagram > span {
  position: static;
  width: auto;
  height: auto;
  transform: none;
  background: transparent;
  font-size: 1.55rem;
}

.cdo-product-media-thumb.is-instagram > small {
  font-size: .65rem;
  font-weight: 900;
  letter-spacing: .08em;
}

@media (max-width: 640px) {
  .cdo-product-media-arrow {
    width: 38px;
    height: 38px;
  }

  .cdo-product-media-thumb {
    flex-basis: 62px;
    width: 62px;
    height: 62px;
  }
}
