/* DMCTN Gloss Hover – TẠO BỞI BÙI VĂN TĨNH */
:root{ --dmctn-gloss-speed:.6s; --dmctn-gloss-strength:.55; }

/* Chuẩn bị wrapper */
.woocommerce ul.products li.product .woocommerce-LoopProduct-link,
.products li.product .woocommerce-LoopProduct-link,
.woocommerce ul.products li.product a.woocommerce-LoopProduct__link,
.products li.product a.woocommerce-LoopProduct__link,
.products li.product .product-thumb,
.products li.product .product-thumb a,
.woocommerce ul.products li.product .product-thumb,
.woocommerce ul.products li.product .product-thumb a,
.products li.product .thumb,
.products li.product .image,
.woocommerce ul.products li.product .image,
.woocommerce ul.products li.product .thumbnail,
.products li.product .thumbnail {
  position: relative;
  display: block;
  overflow: hidden;
}

/* Lớp shine */
.woocommerce ul.products li.product .woocommerce-LoopProduct-link::before,
.products li.product .woocommerce-LoopProduct-link::before,
.woocommerce ul.products li.product a.woocommerce-LoopProduct__link::before,
.products li.product a.woocommerce-LoopProduct__link::before,
.products li.product .product-thumb::before,
.products li.product .product-thumb a::before,
.woocommerce ul.products li.product .product-thumb::before,
.woocommerce ul.products li.product .product-thumb a::before,
.products li.product .thumb::before,
.products li.product .image::before,
.woocommerce ul.products li.product .image::before,
.woocommerce ul.products li.product .thumbnail::before,
.products li.product .thumbnail::before {
  content:"";
  position:absolute;
  top:-20%;
  left:-160%;
  width:60%;
  height:140%;
  pointer-events:none;
  z-index:5;
  background:linear-gradient(120deg, rgba(255,255,255,0) 35%, rgba(255,255,255,var(--dmctn-gloss-strength)) 50%, rgba(255,255,255,0) 65%);
  transform:skewX(-20deg);
  transition:left var(--dmctn-gloss-speed) ease;
  mix-blend-mode: screen;
}

/* Hover kích hoạt */
.woocommerce ul.products li.product:hover .woocommerce-LoopProduct-link::before,
.products li.product:hover .woocommerce-LoopProduct-link::before,
.woocommerce ul.products li.product:hover a.woocommerce-LoopProduct__link::before,
.products li.product:hover a.woocommerce-LoopProduct__link::before,
.products li.product:hover .product-thumb::before,
.products li.product:hover .product-thumb a::before,
.woocommerce ul.products li.product:hover .product-thumb::before,
.woocommerce ul.products li.product:hover .product-thumb a::before,
.products li.product:hover .thumb::before,
.products li.product:hover .image::before,
.woocommerce ul.products li.product:hover .image::before,
.woocommerce ul.products li.product:hover .thumbnail::before,
.products li.product:hover .thumbnail::before {
  left:160%;
}


/* ===== Single Product Gallery – Gloss (TẠO BỞI BÙI VĂN TĨNH) ===== */
.woocommerce div.product div.images .woocommerce-product-gallery__image,
.woocommerce div.product div.images .woocommerce-product-gallery__image a,
.woocommerce div.product div.images .woocommerce-product-gallery__wrapper,
.woocommerce div.product div.images .flex-viewport,
.woocommerce div.product div.images .flex-control-thumbs li,
.woocommerce div.product div.images .flex-control-thumbs li a {
  position: relative;
  display: block;
  overflow: hidden;
}

.woocommerce div.product div.images .woocommerce-product-gallery__image::before,
.woocommerce div.product div.images .woocommerce-product-gallery__image a::before,
.woocommerce div.product div.images .woocommerce-product-gallery__wrapper::before,
.woocommerce div.product div.images .flex-viewport::before,
.woocommerce div.product div.images .flex-control-thumbs li::before,
.woocommerce div.product div.images .flex-control-thumbs li a::before {
  content:"";
  position:absolute;
  top:-20%;
  left:-160%;
  width:60%;
  height:140%;
  pointer-events:none;
  z-index:5;
  background:linear-gradient(120deg, rgba(255,255,255,0) 35%, rgba(255,255,255,var(--dmctn-gloss-strength)) 50%, rgba(255,255,255,0) 65%);
  transform:skewX(-20deg);
  transition:left var(--dmctn-gloss-speed) ease;
  mix-blend-mode: screen;
}

/* Hover quét sáng cho gallery chính */
.woocommerce div.product div.images:hover .woocommerce-product-gallery__image::before,
.woocommerce div.product div.images:hover .woocommerce-product-gallery__wrapper::before,
.woocommerce div.product div.images:hover .flex-viewport::before {
  left:160%;
}

/* Hover quét sáng từng thumbnail */
.woocommerce div.product div.images .flex-control-thumbs li:hover::before,
.woocommerce div.product div.images .flex-control-thumbs li a:hover::before {
  left:160%;
}

/* Kích hoạt bằng class cho mobile */
.dmctn-tap .woocommerce div.product div.images .woocommerce-product-gallery__image::before,
.dmctn-tap .woocommerce div.product div.images .woocommerce-product-gallery__wrapper::before,
.dmctn-tap .woocommerce div.product div.images .flex-viewport::before,
.dmctn-tap .woocommerce div.product div.images .flex-control-thumbs li::before,
.dmctn-tap .woocommerce div.product div.images .flex-control-thumbs li a::before {
  left:160%;
}
/* ===== /Single Product Gallery – Gloss ===== */



/* ===== FORCE Single Product Gloss – high z-index + ::after (TẠO BỞI BÙI VĂN TĨNH) ===== */
.single-product .woocommerce div.product div.images .woocommerce-product-gallery__image,
.single-product .woocommerce div.product div.images .woocommerce-product-gallery__image a,
.single-product .woocommerce div.product div.images .woocommerce-product-gallery__wrapper,
.single-product .woocommerce div.product div.images .flex-viewport {
  position: relative !important;
  overflow: hidden !important;
}

.single-product .woocommerce div.product div.images .woocommerce-product-gallery__image::after,
.single-product .woocommerce div.product div.images .woocommerce-product-gallery__image a::after,
.single-product .woocommerce div.product div.images .woocommerce-product-gallery__wrapper::after,
.single-product .woocommerce div.product div.images .flex-viewport::after {
  content: "";
  position: absolute;
  top: -20%;
  left: -160%;
  width: 60%;
  height: 140%;
  pointer-events: none;
  z-index: 99999;
  background: linear-gradient(120deg, rgba(255,255,255,0) 35%, rgba(255,255,255,.65) 50%, rgba(255,255,255,0) 65%);
  transform: skewX(-20deg);
  transition: left .6s ease;
  mix-blend-mode: screen;
}

/* Hover kích hoạt */
.single-product .woocommerce div.product div.images:hover .woocommerce-product-gallery__image::after,
.single-product .woocommerce div.product div.images:hover .woocommerce-product-gallery__wrapper::after,
.single-product .woocommerce div.product div.images:hover .flex-viewport::after {
  left: 160%;
}

/* Thumbnails force */
.single-product .woocommerce div.product div.images .flex-control-thumbs li,
.single-product .woocommerce div.product div.images .flex-control-thumbs li a {
  position: relative !important;
  overflow: hidden !important;
}
.single-product .woocommerce div.product div.images .flex-control-thumbs li::after,
.single-product .woocommerce div.product div.images .flex-control-thumbs li a::after {
  content: "";
  position: absolute;
  top: -20%;
  left: -160%;
  width: 60%;
  height: 140%;
  pointer-events: none;
  z-index: 99999;
  background: linear-gradient(120deg, rgba(255,255,255,0) 35%, rgba(255,255,255,.65) 50%, rgba(255,255,255,0) 65%);
  transform: skewX(-20deg);
  transition: left .6s ease;
  mix-blend-mode: screen;
}
.single-product .woocommerce div.product div.images .flex-control-thumbs li:hover::after,
.single-product .woocommerce div.product div.images .flex-control-thumbs li a:hover::after {
  left: 160%;
}
/* ===== /FORCE Single Product Gloss ===== */



/* ===== v2 gloss safety: không ẩn tràn trên link bao toàn card ===== */
.products li.product .woocommerce-LoopProduct-link{ overflow:visible !important; }
/* Chỉ ẩn tràn trong khung ảnh */
.products li.product .product-thumb,
.products li.product .product-thumb a{ overflow:hidden; }
