.noselect {
  -webkit-touch-callout: none; /* iOS Safari */
  -webkit-user-select: none; /* Safari */ /* Konqueror HTML */
  -moz-user-select: none; /* Old versions of Firefox */ /* Internet Explorer/Edge */
  user-select: none; /* Non-prefixed version, currently
supported by Chrome, Edge, Opera and Firefox */
}

.bpag-gallery {
  --thumbnail-height: 100px;
  position: relative;
  border: 1px solid #ccc;
  max-height: 1280px;
  height: 100%;
  /* The main image wrapper */
  /* The thumbnails wrapper */
}
.bpag-gallery:hover .bpag-gallery__foreground {
  opacity: 1;
}
.bpag-gallery__foreground {
  opacity: 0;
  z-index: 10;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: var(--thumbnail-height);
  pointer-events: none;
}
@media (max-width: 768px) {
  .bpag-gallery__foreground {
    opacity: 1;
  }
}
.bpag-gallery__foreground .prev {
  display: flex;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  pointer-events: all;
  background: rgba(0, 0, 0, 0.3);
  position: absolute;
  left: 0;
  top: 50%;
  width: 40px;
  height: 40px;
  transform: translateY(-50%);
  transition: background 0.3s ease-in-out;
  border-radius: 50%;
}
.bpag-gallery__foreground .prev:hover {
  background: rgba(0, 0, 0, 0.5);
}
.bpag-gallery__foreground .prev > svg {
  transform: rotate(180deg);
}
.bpag-gallery__foreground .next {
  display: flex;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  pointer-events: all;
  background: rgba(0, 0, 0, 0.3);
  transition: background 0.3s ease-in-out;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border-radius: 50%;
  right: 0;
  height: 40px;
  width: 40px;
}
.bpag-gallery__foreground .next:hover {
  background: rgba(0, 0, 0, 0.5);
}
.bpag-gallery__content {
  z-index: 5;
  overflow: hidden;
  height: 100%;
  position: relative;
  /*
      position: absolute;
      top: 0;
      left: 0;
      right: 0;
      bottom: 0;
  */
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: 1fr 100px;
  max-height: 98vh;
}
.bpag-gallery__background {
  z-index: 1;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
}
.bpag-gallery__main {
  position: relative;
  overflow: hidden;
  height: 100%;
}
.bpag-gallery__main > * {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  z-index: 5;
  opacity: 0;
  transition: opacity 0.3s ease-in-out;
}
.bpag-gallery__main > .active.full img {
  width: 100%;
  height: 100%;
  -o-object-fit: contain;
     object-fit: contain;
}
.bpag-gallery__main > .active {
  position: absolute;
  pointer-events: all;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 6;
  opacity: 1;
  -o-object-fit: contain;
     object-fit: contain;
}
.bpag-gallery__main img {
  -o-object-fit: contain;
     object-fit: contain;
  height: 100%;
  width: auto;
  margin: 0 auto;
  display: block;
}
.bpag-gallery__thumbnails {
  position: relative;
  overflow: hidden;
  display: flex;
}
.bpag-gallery__thumbnails img {
  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  user-select: none;
  max-width: none;
  width: 100px;
  -o-object-fit: cover;
     object-fit: cover;
  height: 100px;
}

dialog#pdp-modal {
  transition: all 300ms ease-in-out;
  pointer-events: none;
  background-color: rgba(0, 0, 0, 0.3) !important;
  border: none;
  outline: none;
  opacity: 0;
  max-width: 100vw;
  max-height: 100vh;
  margin: 0px;
}
dialog#pdp-modal::backdrop {
  background: rgba(0, 0, 0, 0.3) !important;
}
dialog#pdp-modal #pdp-modal-content {
  width: 100vw;
  max-width: 1280px;
  height: 100%;
  max-height: 600px;
  background-color: white;
}
@media screen and (min-height: 933px) {
  dialog#pdp-modal #pdp-modal-content {
    max-height: clamp(600px, 80vh, 1200px);
    min-height: 600px;
  }
}
dialog#pdp-modal #pdp-modal-content [bx-trigger=close-modal] {
  border: none;
  cursor: pointer;
  background-color: white;
}
dialog#pdp-modal #pdp-modal-content [bx-trigger=close-modal]:hover {
  background-color: var(--color-primary);
}
dialog#pdp-modal[open] {
  pointer-events: all;
  opacity: 1;
}
