
/* =========================================================
   UBD Modular Bonito 1.5.1
   Visor final de imagen: una sola imagen, sin textos y cierre
   en cualquier punto. Capa exclusivamente visual.
   ========================================================= */
html.ubd-product-ready body#product #product-modal {
  z-index:2147483000 !important;
  padding:0 !important;
  cursor:zoom-out !important;
}

html.ubd-product-ready body#product.modal-open .modal-backdrop,
html.ubd-product-ready body#product .modal-backdrop.show,
html.ubd-product-ready body#product .modal-backdrop.in {
  z-index:2147482000 !important;
  background:#18333a !important;
  opacity:.72 !important;
}

/* El encabezado antiguo contiene el botón que la cabecera podía cubrir.
   Ya no se necesita: toda la superficie cierra el visor. */
html.ubd-product-ready body#product #product-modal .modal-header,
html.ubd-product-ready body#product #product-modal .modal-title,
html.ubd-product-ready body#product #product-modal .image-caption,
html.ubd-product-ready body#product #product-modal figcaption,
html.ubd-product-ready body#product #product-modal #product-description-short,
html.ubd-product-ready body#product #product-modal #thumbnails,
html.ubd-product-ready body#product #product-modal .thumbnails,
html.ubd-product-ready body#product #product-modal .js-modal-arrows,
html.ubd-product-ready body#product #product-modal .modal-close,
html.ubd-product-ready body#product #product-modal .tvmodel-close,
html.ubd-product-ready body#product #product-modal .close {
  display:none !important;
}

html.ubd-product-ready body#product #product-modal .modal-dialog {
  width:min(92vw,1180px) !important;
  max-width:min(92vw,1180px) !important;
  min-height:100vh !important;
  margin:0 auto !important;
  display:grid !important;
  place-items:center !important;
  pointer-events:none !important;
}

html.ubd-product-ready body#product #product-modal .modal-content {
  width:auto !important;
  max-width:100% !important;
  max-height:92vh !important;
  margin:auto !important;
  overflow:hidden !important;
  border:0 !important;
  border-radius:26px !important;
  background:#fff !important;
  box-shadow:0 30px 90px rgba(0,0,0,.34) !important;
  pointer-events:auto !important;
  cursor:zoom-out !important;
}

html.ubd-product-ready body#product #product-modal .modal-body {
  display:grid !important;
  place-items:center !important;
  width:auto !important;
  max-width:100% !important;
  min-height:0 !important;
  margin:0 !important;
  padding:clamp(12px,2vw,24px) !important;
  background:#fff !important;
  cursor:zoom-out !important;
}

html.ubd-product-ready body#product #product-modal figure {
  display:grid !important;
  place-items:center !important;
  width:auto !important;
  max-width:100% !important;
  min-width:0 !important;
  margin:0 !important;
  padding:0 !important;
  background:#fff !important;
  cursor:zoom-out !important;
}

html.ubd-product-ready body#product #product-modal .product-cover-modal,
html.ubd-product-ready body#product #product-modal .js-modal-product-cover {
  display:block !important;
  width:auto !important;
  height:auto !important;
  max-width:min(86vw,1100px) !important;
  max-height:86vh !important;
  margin:auto !important;
  object-fit:contain !important;
  object-position:center center !important;
  background:#fff !important;
  cursor:zoom-out !important;
  user-select:none !important;
  -webkit-user-drag:none !important;
}

/* Mientras el visor está abierto, ninguna navegación puede quedar encima. */
html.ubd-product-ready body#product.modal-open .ubd-catalog-header,
html.ubd-product-ready body#product.modal-open .ubd-catalog-bottom-nav,
html.ubd-product-ready body#product.modal-open .ubd-catalog-mode-wrap,
html.ubd-product-ready body#product.modal-open .ubd-preview-live-badge,
html.ubd-product-ready body#product.modal-open #header,
html.ubd-product-ready body#product.modal-open .tvheader-top-wrapper {
  opacity:0 !important;
  visibility:hidden !important;
  pointer-events:none !important;
}

@media (max-width:699px) {
  html.ubd-product-ready body#product #product-modal .modal-dialog {
    width:100vw !important;
    max-width:100vw !important;
  }
  html.ubd-product-ready body#product #product-modal .modal-content {
    max-width:96vw !important;
    max-height:92vh !important;
    border-radius:20px !important;
  }
  html.ubd-product-ready body#product #product-modal .modal-body {
    padding:10px !important;
  }
  html.ubd-product-ready body#product #product-modal .product-cover-modal,
  html.ubd-product-ready body#product #product-modal .js-modal-product-cover {
    max-width:92vw !important;
    max-height:84vh !important;
  }
}
