/* MEHFARO QUICK VIEW FINAL V1
   Targeted only: visible Quick View on small screens + no inner modal scroll. */

#productModal .modal-close{
  z-index:80!important;
  pointer-events:auto!important;
  cursor:pointer!important;
  display:grid!important;
  place-items:center!important;
}

#productModal.product-modal{
  padding:14px!important;
  overflow:hidden!important;
}

#productModal .modal-content{
  width:min(1000px,calc(100vw - 28px))!important;
  height:min(680px,calc(100dvh - 28px))!important;
  max-height:calc(100dvh - 28px)!important;
  margin:0!important;
  padding:14px!important;
  overflow:hidden!important;
  border-radius:26px!important;
}

#productModal .modal-product{
  height:100%!important;
  min-height:0!important;
  display:grid!important;
  grid-template-columns:minmax(0,1.04fr) minmax(0,.96fr)!important;
  gap:18px!important;
  align-items:stretch!important;
}

#productModal .modal-product>img{
  width:100%!important;
  height:100%!important;
  min-height:0!important;
  max-height:none!important;
  object-fit:contain!important;
  object-position:center center!important;
  border-radius:19px!important;
  background:#fff!important;
}

#productModal .modal-details{
  min-width:0!important;
  min-height:0!important;
  height:100%!important;
  padding:34px 10px 8px 0!important;
  display:flex!important;
  flex-direction:column!important;
  justify-content:flex-start!important;
  gap:0!important;
  overflow:hidden!important;
}

#productModal .modal-details h2{
  margin:6px 0 10px!important;
  font-size:clamp(23px,3.2vw,34px)!important;
  line-height:1.02!important;
}

#productModal .modal-details .modal-price{
  margin-bottom:10px!important;
  font-size:clamp(20px,2.5vw,27px)!important;
}

#productModal .modal-details>p{
  margin:0 0 10px!important;
  font-size:12px!important;
  line-height:1.35!important;
}

#productModal .modal-meta-grid{
  grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:7px!important;
  margin:0 0 9px!important;
}

#productModal .modal-meta-item{
  min-width:0!important;
  padding:8px 10px!important;
  border-radius:11px!important;
}

#productModal .modal-meta-item small{
  margin-bottom:2px!important;
  font-size:8px!important;
}

#productModal .modal-meta-item strong{
  display:block!important;
  overflow-wrap:anywhere!important;
  font-size:11px!important;
  line-height:1.2!important;
}

#productModal .option-group{
  margin:0 0 8px!important;
}

#productModal .option-group label{
  margin-bottom:4px!important;
  font-size:9px!important;
}

#productModal .option-group select{
  min-height:38px!important;
  height:38px!important;
  padding:0 10px!important;
  border-radius:10px!important;
  font-size:11px!important;
}

#productModal .product-note{
  margin:0 0 8px!important;
  padding:8px 10px!important;
  font-size:10px!important;
}

#productModal .modal-details .add-cart-btn{
  min-height:40px!important;
  height:40px!important;
  margin-top:auto!important;
  flex:0 0 40px!important;
}

@media(max-width:780px){
  .product-image-wrap .quick-view{
    display:flex!important;
    align-items:center!important;
    justify-content:center!important;
    left:7px!important;
    right:7px!important;
    bottom:7px!important;
    height:32px!important;
    min-height:32px!important;
    padding:0 8px!important;
    opacity:1!important;
    transform:none!important;
    border:1px solid rgba(197,138,33,.55)!important;
    border-radius:999px!important;
    background:rgba(255,255,255,.94)!important;
    color:#18211f!important;
    font-size:9px!important;
    font-weight:900!important;
    backdrop-filter:blur(7px)!important;
    -webkit-backdrop-filter:blur(7px)!important;
  }

  #productModal.product-modal{
    padding:8px!important;
  }

  #productModal .modal-content{
    width:calc(100vw - 16px)!important;
    height:calc(100dvh - 16px)!important;
    max-height:calc(100dvh - 16px)!important;
    padding:10px!important;
    border-radius:20px!important;
  }

  #productModal .modal-product{
    grid-template-columns:minmax(0,.9fr) minmax(0,1.1fr)!important;
    gap:10px!important;
  }

  #productModal .modal-details{
    padding:30px 4px 5px 0!important;
  }

  #productModal .modal-details h2{
    margin:4px 0 7px!important;
    font-size:clamp(17px,4.3vw,24px)!important;
  }

  #productModal .modal-details .modal-price{
    margin-bottom:7px!important;
    font-size:18px!important;
  }

  #productModal .modal-details>p{
    margin-bottom:7px!important;
    font-size:9px!important;
    line-height:1.25!important;
  }

  #productModal .modal-meta-grid{
    gap:5px!important;
    margin-bottom:6px!important;
  }

  #productModal .modal-meta-item{
    padding:6px 7px!important;
  }

  #productModal .modal-meta-item small{font-size:7px!important}
  #productModal .modal-meta-item strong{font-size:9px!important}

  #productModal .option-group{
    margin-bottom:6px!important;
  }

  #productModal .option-group select{
    min-height:34px!important;
    height:34px!important;
    font-size:10px!important;
  }

  #productModal .modal-details .add-cart-btn{
    min-height:36px!important;
    height:36px!important;
    flex-basis:36px!important;
    font-size:10px!important;
  }

  #productModal .modal-close{
    top:14px!important;
    right:14px!important;
    width:36px!important;
    height:36px!important;
  }
}

@media(max-width:430px){
  #productModal .modal-product{
    grid-template-columns:minmax(0,.82fr) minmax(0,1.18fr)!important;
    gap:7px!important;
  }
  #productModal .modal-details{
    padding-top:29px!important;
  }
  #productModal .modal-details h2{
    font-size:15px!important;
    line-height:1.05!important;
  }
  #productModal .modal-details .modal-price{
    font-size:16px!important;
  }
}


/* =========================================================
   V2 PRODUCT CARD ACTION POLISH
   - View Details is compact and hidden until product image hover/focus
   - Same soft gold system as Shop Now
   - Product discount badge uses the same soft gold
========================================================= */
.product-image-wrap .quick-view {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  min-width: 104px !important;
  height: 28px !important;
  min-height: 28px !important;
  left: 50% !important;
  right: auto !important;
  bottom: 9px !important;
  padding: 0 14px !important;
  border: 1px solid rgba(177, 125, 36, .28) !important;
  border-radius: 999px !important;
  background: linear-gradient(135deg, #e4b65e, #efd08f) !important;
  color: #2b210c !important;
  font-size: 8px !important;
  font-weight: 900 !important;
  line-height: 1 !important;
  letter-spacing: .025em !important;
  white-space: nowrap !important;
  box-shadow: 0 5px 14px rgba(82, 55, 9, .14) !important;
  opacity: 0 !important;
  pointer-events: none !important;
  transform: translate(-50%, 8px) !important;
  transition: opacity .18s ease, transform .18s ease, box-shadow .18s ease !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
  z-index: 12 !important;
}

.product-card:hover .quick-view,
.product-card:focus-within .quick-view,
.product-image-wrap:hover .quick-view,
.product-image-wrap:focus-within .quick-view {
  opacity: 1 !important;
  pointer-events: auto !important;
  transform: translate(-50%, 0) !important;
}

.product-image-wrap .quick-view:hover,
.product-image-wrap .quick-view:focus-visible {
  background: linear-gradient(135deg, #e4b65e, #efd08f) !important;
  color: #2b210c !important;
  box-shadow: 0 6px 16px rgba(82, 55, 9, .18) !important;
}

.product-badge {
  background: linear-gradient(135deg, #e4b65e, #efd08f) !important;
  color: #2b210c !important;
  border: 1px solid rgba(177, 125, 36, .22) !important;
  box-shadow: 0 5px 14px rgba(82, 55, 9, .13) !important;
}

@media (max-width: 780px) {
  .product-image-wrap .quick-view {
    display: inline-flex !important;
    width: auto !important;
    min-width: 98px !important;
    height: 27px !important;
    min-height: 27px !important;
    left: 50% !important;
    right: auto !important;
    bottom: 7px !important;
    padding: 0 12px !important;
    font-size: 7.5px !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transform: translate(-50%, 7px) !important;
  }

  .product-card:hover .quick-view,
  .product-card:focus-within .quick-view,
  .product-card.mf-qv-reveal .quick-view,
  .product-image-wrap:hover .quick-view,
  .product-image-wrap:focus-within .quick-view {
    opacity: 1 !important;
    pointer-events: auto !important;
    transform: translate(-50%, 0) !important;
  }
}
