:is(body.product-detail-page, body.review-detail-page) .review-media a img {
  border: 0;
}

@media (max-width: 767px) {
  body.product-detail-page .c-item .review-media,
  body.review-detail-page .c-item .c-body .review-media {
    grid-template-columns: repeat(auto-fill, minmax(0, 76px));
    gap: 6px;
  }
  :is(body.product-detail-page, body.review-detail-page) .c-item .review-media a img {
    aspect-ratio: 1;
  }
}

html:has(.review-image-preview[open]) { overflow: hidden; }

.review-image-preview {
  position: fixed;
  inset: 0;
  width: fit-content;
  max-width: min(94vw, 1000px);
  max-height: 94dvh;
  margin: auto;
  padding: 40px 0 0;
  border: 0;
  background: transparent;
  overflow: hidden;
}
.review-image-preview::backdrop { background: rgb(12 14 18 / 82%); }
.review-image-preview img {
  display: block;
  max-width: 100%;
  max-height: calc(94dvh - 40px);
  margin: auto;
  object-fit: contain;
}
.review-image-preview button {
  position: absolute;
  top: 0;
  right: 0;
  width: 40px;
  height: 40px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #fff;
  font: 28px/1 Arial, sans-serif;
  cursor: pointer;
}
