/*
 * Braids Goddess Core 2.0.26 — Editorial V2 product cards
 * Single visual system for Home, shop/archive and related products.
 */

body.bgc-enabled .bgc-product-grid,
body.bgc-enabled .woocommerce ul.products,
body.bgc-enabled.single-product .bgc-v3-related ul.products,
body.bgc-enabled.single-product section.related.products ul.products{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:16px!important;
  align-items:stretch!important;
  width:100%!important;
  margin-left:0!important;
  margin-right:0!important;
  padding:0!important;
}
body.bgc-enabled .woocommerce ul.products:before,
body.bgc-enabled .woocommerce ul.products:after{display:none!important;content:none!important}

/* CARD SHELL — image becomes the card, copy floats over it. */
body.bgc-enabled .bgc-product-card,
body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card{
  position:relative!important;
  display:block!important;
  width:100%!important;
  max-width:none!important;
  min-width:0!important;
  height:auto!important;
  aspect-ratio:4/5!important;
  float:none!important;
  clear:none!important;
  margin:0!important;
  padding:0!important;
  overflow:hidden!important;
  isolation:isolate!important;
  border:1px solid rgba(214,187,164,.58)!important;
  border-radius:22px!important;
  background:#2c180f!important;
  box-shadow:0 18px 42px rgba(58,28,13,.12)!important;
  transform:none!important;
  transition:transform .26s ease,box-shadow .26s ease!important;
}
body.bgc-enabled .bgc-product-card:hover,
body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card:hover{
  transform:translateY(-3px)!important;
  box-shadow:0 24px 48px rgba(58,28,13,.17)!important;
}

body.bgc-enabled .bgc-product-card__media{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  overflow:hidden!important;
  background:#d9c1ae!important;
  z-index:0!important;
}
body.bgc-enabled .bgc-product-card__image{
  display:block!important;
  width:100%!important;
  height:100%!important;
  margin:0!important;
}
body.bgc-enabled .bgc-product-card__image img,
body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card .bgc-product-card__image img{
  display:block!important;
  width:100%!important;
  height:100%!important;
  max-width:none!important;
  margin:0!important;
  padding:0!important;
  aspect-ratio:auto!important;
  object-fit:cover!important;
  object-position:center top!important;
  border:0!important;
  transform:scale(1.001)!important;
  transition:transform .4s ease!important;
}
body.bgc-enabled .bgc-product-card:hover .bgc-product-card__image img{transform:scale(1.025)!important}

/* Editorial fade: gives even white supplier photos a consistent premium footer. */
body.bgc-enabled .bgc-product-card:after{
  content:""!important;
  position:absolute!important;
  inset:28% 0 0!important;
  z-index:1!important;
  pointer-events:none!important;
  background:linear-gradient(180deg,rgba(26,12,5,0) 0%,rgba(26,12,5,.08) 19%,rgba(24,11,5,.72) 58%,rgba(18,8,4,.97) 100%)!important;
}

/* SALE + HEART */
body.bgc-enabled .bgc-product-card__badge{
  position:absolute!important;
  top:14px!important;
  left:14px!important;
  z-index:5!important;
  display:inline-flex!important;
  align-items:center!important;
  justify-content:center!important;
  min-height:30px!important;
  padding:0 12px!important;
  border-radius:9px!important;
  background:#b96f43!important;
  color:#fff!important;
  box-shadow:0 8px 20px rgba(80,39,18,.16)!important;
  font:700 9px/1 var(--bg-sans,Manrope,sans-serif)!important;
  letter-spacing:.04em!important;
}
body.bgc-enabled .bgc-product-card__heart{
  position:absolute!important;
  top:14px!important;
  right:14px!important;
  z-index:5!important;
  display:grid!important;
  place-items:center!important;
  width:42px!important;
  height:42px!important;
  padding:0!important;
  border:1px solid rgba(255,247,238,.72)!important;
  border-radius:50%!important;
  background:rgba(255,249,242,.94)!important;
  color:#4c2718!important;
  box-shadow:0 10px 24px rgba(47,22,11,.13)!important;
  backdrop-filter:blur(8px)!important;
}
body.bgc-enabled .bgc-product-card__heart svg{width:19px!important;height:19px!important;fill:none!important;stroke:currentColor!important;stroke-width:1.55!important}
body.bgc-enabled .bgc-product-card__heart.is-active{background:#4a2516!important;color:#fff!important;border-color:#4a2516!important}

/* BODY OVERLAY */
body.bgc-enabled .bgc-product-card__body{
  position:absolute!important;
  left:0!important;
  right:0!important;
  bottom:0!important;
  z-index:3!important;
  display:flex!important;
  flex-direction:column!important;
  justify-content:flex-end!important;
  min-height:49%!important;
  padding:72px 17px 16px!important;
  background:linear-gradient(180deg,rgba(24,11,5,0) 0%,rgba(24,11,5,.60) 34%,rgba(18,8,4,.96) 100%)!important;
}
body.bgc-enabled .bgc-product-card__category{
  display:block!important;
  margin:0 0 8px!important;
  color:#f6d5b6!important;
  font:700 8px/1.1 var(--bg-sans,Manrope,sans-serif)!important;
  letter-spacing:.19em!important;
  text-transform:uppercase!important;
}
body.bgc-enabled .bgc-product-card__category:after{
  content:""!important;
  display:block!important;
  width:30px!important;
  height:1px!important;
  margin-top:7px!important;
  background:#d99d69!important;
}
body.bgc-enabled .bgc-product-card__title{
  display:block!important;
  margin:0!important;
  color:#fffaf3!important;
  text-decoration:none!important;
}
body.bgc-enabled .bgc-product-card__title h2,
body.bgc-enabled .bgc-product-card__title h3,
body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card .bgc-product-card__title h2{
  display:-webkit-box!important;
  -webkit-box-orient:vertical!important;
  -webkit-line-clamp:2!important;
  overflow:hidden!important;
  min-height:50px!important;
  margin:0!important;
  padding:0!important;
  color:#fffaf3!important;
  font:600 24px/1.01 var(--bg-serif,"Cormorant Garamond",serif)!important;
  letter-spacing:-.02em!important;
  text-transform:none!important;
  text-shadow:0 2px 14px rgba(0,0,0,.25)!important;
}
body.bgc-enabled .bgc-product-card__bottom{
  display:grid!important;
  grid-template-columns:1fr!important;
  gap:10px!important;
  margin-top:12px!important;
  padding-top:0!important;
}
body.bgc-enabled .bgc-product-card .price{
  display:flex!important;
  align-items:baseline!important;
  gap:8px!important;
  min-width:0!important;
  margin:0!important;
  padding:0!important;
  color:#f6c69c!important;
  font:700 17px/1.1 var(--bg-sans,Manrope,sans-serif)!important;
  white-space:normal!important;
}
body.bgc-enabled .bgc-product-card .price del{
  display:inline!important;
  margin:0!important;
  color:rgba(255,250,243,.52)!important;
  opacity:1!important;
  font-size:12px!important;
  font-weight:500!important;
}
body.bgc-enabled .bgc-product-card .price ins{color:#f6c69c!important;text-decoration:none!important}

/* V2 champagne CTA — full width. */
body.bgc-enabled .bgc-product-card .bgc-mini-add,
body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card .bgc-mini-add{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  width:100%!important;
  min-width:0!important;
  max-width:none!important;
  height:42px!important;
  min-height:42px!important;
  margin:0!important;
  padding:0 14px!important;
  border:1px solid rgba(255,226,197,.75)!important;
  border-radius:999px!important;
  background:linear-gradient(90deg,#efbd8c 0%,#f5d0a9 50%,#dca472 100%)!important;
  color:#2f170d!important;
  box-shadow:0 8px 20px rgba(15,7,3,.22)!important;
  font:700 9px/1 var(--bg-sans,Manrope,sans-serif)!important;
  letter-spacing:.23em!important;
  text-transform:uppercase!important;
  white-space:nowrap!important;
}
body.bgc-enabled .bgc-product-card .bgc-mini-add:after{content:"→"!important;margin-left:10px!important;font-size:14px!important;font-weight:400!important;letter-spacing:0!important}
body.bgc-enabled .bgc-product-card .bgc-mini-add:hover,
body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card .bgc-mini-add:hover{
  filter:brightness(.95)!important;
  color:#2f170d!important;
}
body.bgc-enabled .bgc-product-card .added_to_cart{display:none!important}

@media(max-width:900px){
  body.bgc-enabled .bgc-product-grid,
  body.bgc-enabled .woocommerce ul.products,
  body.bgc-enabled.single-product .bgc-v3-related ul.products,
  body.bgc-enabled.single-product section.related.products ul.products{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:12px!important;
  }
}

/* MOBILE: the editorial idea stays, but the card is compact enough for 2 columns. */
@media(max-width:767px){
  body.bgc-enabled .bgc-product-grid,
  body.bgc-enabled .woocommerce ul.products,
  body.bgc-enabled.single-product .bgc-v3-related ul.products,
  body.bgc-enabled.single-product section.related.products ul.products{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    gap:9px!important;
  }
  body.bgc-enabled .bgc-product-card,
  body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card{
    aspect-ratio:3/4!important;
    border-radius:16px!important;
    box-shadow:0 10px 24px rgba(58,28,13,.10)!important;
  }
  body.bgc-enabled .bgc-product-card:after{inset:30% 0 0!important}
  body.bgc-enabled .bgc-product-card__badge{
    top:8px!important;left:8px!important;
    min-height:23px!important;padding:0 8px!important;
    border-radius:7px!important;font-size:6.5px!important;
  }
  body.bgc-enabled .bgc-product-card__heart{
    top:8px!important;right:8px!important;
    width:32px!important;height:32px!important;
  }
  body.bgc-enabled .bgc-product-card__heart svg{width:15px!important;height:15px!important}
  body.bgc-enabled .bgc-product-card__body{
    min-height:55%!important;
    padding:54px 9px 9px!important;
  }
  body.bgc-enabled .bgc-product-card__category{
    margin-bottom:5px!important;
    font-size:6px!important;
    letter-spacing:.13em!important;
  }
  body.bgc-enabled .bgc-product-card__category:after{width:20px!important;margin-top:5px!important}
  body.bgc-enabled .bgc-product-card__title h2,
  body.bgc-enabled .bgc-product-card__title h3,
  body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card .bgc-product-card__title h2{
    min-height:31px!important;
    font-size:14px!important;
    line-height:1.02!important;
  }
  body.bgc-enabled .bgc-product-card__bottom{
    gap:7px!important;
    margin-top:7px!important;
  }
  body.bgc-enabled .bgc-product-card .price{
    gap:5px!important;
    font-size:10.5px!important;
  }
  body.bgc-enabled .bgc-product-card .price del{font-size:8px!important}
  body.bgc-enabled .bgc-product-card .bgc-mini-add,
  body.bgc-enabled .woocommerce ul.products li.product.bgc-product-card .bgc-mini-add{
    height:29px!important;
    min-height:29px!important;
    padding:0 8px!important;
    font-size:6px!important;
    letter-spacing:.14em!important;
  }
  body.bgc-enabled .bgc-product-card .bgc-mini-add:after{margin-left:5px!important;font-size:10px!important}
}

/* 2.0.34 — mobile/tablet listings are always two products per row. */
@media (max-width:900px){
  body.bgc-enabled .bgc-product-grid,
  body.bgc-enabled .woocommerce ul.products,
  body.bgc-enabled .elementor-widget-woocommerce-products ul.products,
  body.bgc-enabled .elementor-widget-wc-archive-products ul.products,
  body.bgc-enabled .wc-block-product-template,
  body.bgc-enabled .wc-block-grid__products{
    display:grid!important;
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
    grid-auto-flow:row!important;
    gap:10px!important;
    width:100%!important;
    max-width:100%!important;
  }
  body.bgc-enabled .bgc-product-grid>.bgc-product-card,
  body.bgc-enabled .woocommerce ul.products>li.product,
  body.bgc-enabled .wc-block-product-template>.wc-block-product,
  body.bgc-enabled .wc-block-grid__products>.wc-block-grid__product{
    width:100%!important;
    max-width:100%!important;
    min-width:0!important;
    float:none!important;
    clear:none!important;
    margin:0!important;
  }
}
