/* Capri Blu Totem - v0.4.21
   Galleria prodotto fullscreen: immagine grande, descrizione, navigazione e aggiunta rapida. */

.cb-product-gallery-overlay {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(3, 18, 31, .88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.cb-product-gallery-overlay.is-open {
  display: flex;
}

.cb-product-gallery-dialog {
  position: relative;
  width: min(1120px, 94vw);
  max-height: 92vh;
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, .8fr);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.32);
  border-radius: 26px;
  background: linear-gradient(145deg, rgba(8,40,70,.98), rgba(11,55,91,.96));
  box-shadow: 0 28px 80px rgba(0,0,0,.55);
  color: #fff;
}

.cb-product-gallery-media {
  min-height: 520px;
  background: rgba(5,29,50,.9);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.cb-product-gallery-media img {
  width: 100%;
  height: 100%;
  min-height: 520px;
  max-height: 82vh;
  object-fit: contain;
  background: rgba(4,25,43,.9);
}

.cb-product-gallery-placeholder {
  font-size: 1.1rem;
  color: rgba(255,255,255,.72);
}

.cb-product-gallery-info {
  display: flex;
  flex-direction: column;
  padding: 42px 34px 30px;
  overflow-y: auto;
}

.cb-product-gallery-kicker {
  margin: 0 0 10px;
  color: #fff2c7;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.cb-product-gallery-title {
  margin: 0;
  color: #fff;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: clamp(2rem, 4vw, 3.35rem);
  line-height: 1;
}

.cb-product-gallery-price {
  margin-top: 14px;
  color: #fff2c7;
  font-size: 1.55rem;
  font-weight: 900;
}

.cb-product-gallery-description {
  margin: 24px 0 0;
  color: rgba(255,255,255,.9);
  font-size: 1rem;
  line-height: 1.58;
}

.cb-product-gallery-allergens {
  margin-top: 14px;
  color: rgba(255,255,255,.7);
  font-size: .88rem;
}

.cb-product-gallery-actions {
  margin-top: auto;
  padding-top: 28px;
  display: grid;
  gap: 10px;
}

.cb-product-gallery-add {
  min-height: 54px;
  border: 0;
  border-radius: 13px;
  background: #fff2c7;
  color: #0d3559;
  font-size: 1rem;
  font-weight: 900;
  cursor: pointer;
}

.cb-product-gallery-add[disabled] {
  opacity: .55;
  cursor: default;
}

.cb-product-gallery-counter {
  text-align: center;
  color: rgba(255,255,255,.68);
  font-size: .78rem;
}

.cb-product-gallery-close,
.cb-product-gallery-prev,
.cb-product-gallery-next {
  position: absolute;
  z-index: 3;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,.35);
  background: rgba(7,39,67,.82);
  color: #fff;
  box-shadow: 0 8px 24px rgba(0,0,0,.28);
  cursor: pointer;
}

.cb-product-gallery-close {
  top: 16px;
  right: 16px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  font-size: 1.35rem;
}

.cb-product-gallery-prev,
.cb-product-gallery-next {
  top: 50%;
  width: 52px;
  height: 70px;
  transform: translateY(-50%);
  border-radius: 16px;
  font-size: 2rem;
}

.cb-product-gallery-prev { left: 16px; }
.cb-product-gallery-next { right: 16px; }

.cb-product-gallery-prev[disabled],
.cb-product-gallery-next[disabled] {
  opacity: .28;
  cursor: default;
}

#screen-products .product-image,
#screen-products .product-image.has-photo {
  cursor: zoom-in !important;
}

#screen-products .product-image:hover {
  outline: 2px solid rgba(255,242,199,.7);
  outline-offset: -2px;
}

@media (max-width: 860px) {
  .cb-product-gallery-overlay { padding: 12px; }

  .cb-product-gallery-dialog {
    width: 96vw;
    max-height: 96vh;
    grid-template-columns: 1fr;
    grid-template-rows: minmax(280px, 55vh) auto;
    border-radius: 20px;
  }

  .cb-product-gallery-media,
  .cb-product-gallery-media img {
    min-height: 280px;
    max-height: 55vh;
  }

  .cb-product-gallery-info {
    padding: 22px 22px 20px;
  }

  .cb-product-gallery-title {
    font-size: 2rem;
  }

  .cb-product-gallery-prev,
  .cb-product-gallery-next {
    width: 46px;
    height: 62px;
  }
}

/* v0.4.22 - contrasto forte contro gli stili globali del menu */
.cb-product-gallery-overlay .cb-product-gallery-info,
.cb-product-gallery-overlay .cb-product-gallery-info * {
  text-shadow: none !important;
}

.cb-product-gallery-overlay .cb-product-gallery-title {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
  opacity: 1 !important;
  filter: none !important;
}

.cb-product-gallery-overlay .cb-product-gallery-price {
  color: #fff2c7 !important;
  -webkit-text-fill-color: #fff2c7 !important;
}

.cb-product-gallery-overlay .cb-product-gallery-description {
  color: rgba(255,255,255,.94) !important;
  -webkit-text-fill-color: rgba(255,255,255,.94) !important;
}

.cb-product-gallery-overlay .cb-product-gallery-allergens,
.cb-product-gallery-overlay .cb-product-gallery-counter {
  color: rgba(255,255,255,.76) !important;
  -webkit-text-fill-color: rgba(255,255,255,.76) !important;
}

.cb-product-gallery-placeholder {
  width: min(72%, 520px);
  min-height: 240px;
  display: grid;
  place-items: center;
  padding: 28px;
  border: 1px dashed rgba(255,242,199,.5);
  border-radius: 22px;
  background: rgba(255,255,255,.035);
  color: rgba(255,255,255,.78) !important;
  text-align: center;
  font-weight: 700;
}

.cb-product-gallery-add {
  color: #0d3559 !important;
  -webkit-text-fill-color: #0d3559 !important;
}
