/* Alvport 0.24.23: zoom and enlarged gallery, isolated to product single. */
body.single-product .woocommerce-product-gallery { position: relative; }
body.single-product .woocommerce-product-gallery__image img { cursor: zoom-in; }
body.single-product .woocommerce-product-gallery .zoomImg { display: none !important; }
.alv-explorer-lens { position: absolute; z-index: 20; pointer-events: none; border: 1px solid rgba(0,130,0,.45); border-radius: 10px; background: rgba(0,130,0,.09); opacity: 0; transition: opacity .1s ease; }
.alv-explorer-lens.is-visible { opacity: 1; }
.alv-explorer-zoom { position: fixed; z-index: 99990; pointer-events: none; opacity: 0; border: 1px solid rgba(0,130,0,.22); border-radius: 16px; background-color: #fff; background-repeat: no-repeat; box-shadow: 0 20px 55px rgba(22,43,76,.25); transition: opacity .1s ease; }
.alv-explorer-zoom.is-visible { opacity: 1; }
.alv-explorer { position: fixed; inset: 0; z-index: 2147483000; background: rgba(13,21,34,.68); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: grid; place-items: center; padding: 24px; box-sizing: border-box; }
.alv-explorer__shell { width: min(1160px, 100%); height: min(750px, 92vh); position: relative; display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, .85fr); background: #fff; border-radius: 20px; overflow: hidden; box-shadow: 0 25px 80px rgba(0,0,0,.32); }
.alv-explorer__stage { min-width: 0; min-height: 0; position: relative; display: grid; place-items: center; padding: clamp(16px, 3vw, 38px); background: #f9fbfa; }
.alv-explorer__large { max-width: 100%; max-height: 100%; width: 100%; height: 100%; object-fit: contain; opacity: 0; transition: opacity .16s ease; }
.alv-explorer__large.is-loaded { opacity: 1; }
.alv-explorer__loading { position: absolute; color: #64748b; font-size: 14px; }
.alv-explorer__loading[hidden] { display: none; }
.alv-explorer__aside { padding: 58px 25px 26px; overflow-y: auto; min-width: 0; display: flex; flex-direction: column; gap: 12px; color: #243247; }
.alv-explorer__meta { margin: 0; color: #008200; font-weight: 800; text-transform: uppercase; font-size: 12px; letter-spacing: .03em; }
.alv-explorer__title { margin: 0; color: #162b4c; line-height: 1.18; font-size: clamp(22px, 2.2vw, 32px); font-weight: 850; }
.alv-explorer__description { margin: 0; color: #53657a; font-size: 14px; line-height: 1.6; }
.alv-explorer__count { margin: 5px 0 0; font-size: 12px; color: #64748b; }
.alv-explorer__thumbs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.alv-explorer__thumb { display: grid; place-items: center; aspect-ratio: 1; background: #fff; border: 1px solid #e0e7e5; border-radius: 11px; padding: 5px; cursor: pointer; overflow: hidden; }
.alv-explorer__thumb.is-active, .alv-explorer__thumb:hover { border-color: #008200; box-shadow: 0 0 0 2px rgba(0,130,0,.12); }
.alv-explorer__thumb img { width: 100%; height: 100%; object-fit: contain; }
.alv-explorer__detail { margin-top: auto; text-align: center; padding: 12px 15px; border-radius: 999px; background: #008200; color: #fff !important; text-decoration: none !important; font-weight: 800; }
.alv-explorer__detail:hover, .alv-explorer__detail:focus-visible { background: #006b00; color: #fff !important; }
.alv-explorer__close { position: absolute; right: 15px; top: 15px; z-index: 3; background: #edf3ef; border: 0; border-radius: 50%; width: 38px; height: 38px; cursor: pointer; color: #243247; font-size: 26px; line-height: 1; }
.alv-explorer__close:hover { background: #dceee2; }
.alv-explorer__arrow { position: absolute; z-index: 2; top: 50%; transform: translateY(-50%); display: grid; place-items: center; width: 40px; height: 48px; border: 1px solid #dde6e1; border-radius: 12px; background: rgba(255,255,255,.89); font-size: 32px; color: #162b4c; cursor: pointer; }
.alv-explorer__arrow--prev { left: 8px; }.alv-explorer__arrow--next { right: 8px; }
@media (max-width: 800px) { .alv-explorer-lens,.alv-explorer-zoom { display: none !important; } .alv-explorer { padding: 0; } .alv-explorer__shell { width: 100%; height: 100dvh; border-radius: 0; grid-template-columns: 1fr; grid-template-rows: minmax(0, 1.4fr) minmax(220px, .85fr); } .alv-explorer__stage { padding: 36px 28px 15px; } .alv-explorer__aside { padding: 14px 20px 26px; gap: 9px; } .alv-explorer__title { font-size: 22px; } .alv-explorer__thumbs { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
@media (max-width: 420px) { .alv-explorer__thumbs { grid-template-columns: repeat(5, minmax(0, 1fr)); } .alv-explorer__stage { padding: 42px 24px 8px; } }
@media (prefers-reduced-motion: reduce) { .alv-explorer__large,.alv-explorer-lens,.alv-explorer-zoom { transition: none; } }

/* 0.24.23 — Fix: the image must fit inside the *visible* stage, not size
   the grid track from its natural dimensions. This prevents tall product
   photos from extending below the modal. No crop or distortion. */
.alv-explorer__stage {
  --alv-explorer-image-gap: clamp(16px, 3vw, 38px);
  overflow: hidden;
}
.alv-explorer__stage > img.alv-explorer__large {
  position: absolute !important;
  top: var(--alv-explorer-image-gap) !important;
  left: var(--alv-explorer-image-gap) !important;
  width: calc(100% - var(--alv-explorer-image-gap) - var(--alv-explorer-image-gap)) !important;
  height: calc(100% - var(--alv-explorer-image-gap) - var(--alv-explorer-image-gap)) !important;
  max-width: none !important;
  max-height: none !important;
  min-width: 0 !important;
  min-height: 0 !important;
  object-fit: contain !important;
  object-position: center center !important;
}
@media (max-width: 800px) {
  .alv-explorer__stage { --alv-explorer-image-gap: 20px; }
}
