/* Braids Goddess Core 2.0.42 — Shop desktop root width + Editorial V2 cards.
   Desktop only. Mobile/tablet rules remain owned by the existing mobile locks. */
@media (min-width:1100px){
  body.bgc-enabled.post-type-archive-product,
  body.bgc-enabled.tax-product_cat{
    overflow-x:hidden!important;
  }

  /* Unlock only ancestors that wrap the Woo shop/category canvas. */
  body.bgc-enabled.post-type-archive-product .bgc-shop-wide-ancestor,
  body.bgc-enabled.tax-product_cat .bgc-shop-wide-ancestor{
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:0!important;
    padding-right:0!important;
    overflow:visible!important;
  }

  /* Use the real desktop canvas instead of the theme's 1360px shell. */
  body.bgc-enabled.post-type-archive-product .bg-woocommerce-shell,
  body.bgc-enabled.tax-product_cat .bg-woocommerce-shell{
    position:relative!important;
    left:50%!important;
    transform:translateX(-50%)!important;
    width:min(1810px,calc(100vw - 64px))!important;
    max-width:none!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:0!important;
    padding-right:0!important;
  }

  body.bgc-enabled.post-type-archive-product .bg-entry,
  body.bgc-enabled.post-type-archive-product .bg-entry__content,
  body.bgc-enabled.tax-product_cat .bg-entry,
  body.bgc-enabled.tax-product_cat .bg-entry__content{
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:0!important;
    padding-right:0!important;
  }

  /* Hero gets the same generous rail as the products. */
  body.bgc-enabled.post-type-archive-product .bgc-collection-hero,
  body.bgc-enabled.tax-product_cat .bgc-collection-hero{
    width:100%!important;
    max-width:none!important;
    min-height:335px!important;
    grid-template-columns:minmax(480px,1.12fr) minmax(560px,.88fr)!important;
    border-radius:18px!important;
    overflow:hidden!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-collection-hero__image,
  body.bgc-enabled.tax-product_cat .bgc-collection-hero__image{
    min-height:335px!important;
    background-size:cover!important;
    background-position:center 24%!important;
  }

  /* Sidebar + main content: more useful width, less empty whitespace. */
  body.bgc-enabled.post-type-archive-product .bgc-shop-layout,
  body.bgc-enabled.tax-product_cat .bgc-shop-layout{
    grid-template-columns:270px minmax(0,1fr)!important;
    gap:34px!important;
    width:100%!important;
    max-width:none!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-filter,
  body.bgc-enabled.tax-product_cat .bgc-filter{
    width:270px!important;
    max-width:270px!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main,
  body.bgc-enabled.tax-product_cat .bgc-shop-main{
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
  }

  /* 2.0.42 — compact Editorial V2 desktop cards.
     Keep the visual language, but stop giant 2-up/3-up cards on desktop. */
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products{
    display:grid!important;
    grid-template-columns:repeat(3,minmax(0,1fr))!important;
    gap:18px!important;
    width:100%!important;
    max-width:none!important;
    margin:0!important;
    padding:0!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products > li.product,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products > li.product{
    width:100%!important;
    max-width:none!important;
    min-width:0!important;
    margin:0!important;
    float:none!important;
    clear:none!important;
  }

  body.bgc-enabled.post-type-archive-product .bgc-shop-main .bgc-product-card,
  body.bgc-enabled.tax-product_cat .bgc-shop-main .bgc-product-card{
    aspect-ratio:4/4.85!important;
    border-radius:16px!important;
    box-shadow:0 12px 28px rgba(58,28,13,.09)!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main .bgc-product-card__body,
  body.bgc-enabled.tax-product_cat .bgc-shop-main .bgc-product-card__body{
    min-height:48%!important;
    padding:62px 15px 14px!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main .bgc-product-card__title h2,
  body.bgc-enabled.tax-product_cat .bgc-shop-main .bgc-product-card__title h2{
    min-height:44px!important;
    font-size:22px!important;
    line-height:1!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main .bgc-product-card .price,
  body.bgc-enabled.tax-product_cat .bgc-shop-main .bgc-product-card .price{
    font-size:17px!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main .bgc-product-card .price del,
  body.bgc-enabled.tax-product_cat .bgc-shop-main .bgc-product-card .price del{
    font-size:11px!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main .bgc-mini-add,
  body.bgc-enabled.tax-product_cat .bgc-shop-main .bgc-mini-add{
    min-height:36px!important;
    height:36px!important;
    font-size:7.5px!important;
  }

  /* Keep toolbar aligned across the new wide rail. */
  body.bgc-enabled.post-type-archive-product .bgc-shop-main__intro,
  body.bgc-enabled.tax-product_cat .bgc-shop-main__intro{
    max-width:880px!important;
  }
}

@media (min-width:1400px){
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products{
    grid-template-columns:repeat(4,minmax(0,1fr))!important;
  }
}

@media (min-width:1800px){
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products{
    grid-template-columns:repeat(5,minmax(0,1fr))!important;
    gap:16px!important;
  }
}

@media (min-width:1750px){
  body.bgc-enabled.post-type-archive-product .bg-woocommerce-shell,
  body.bgc-enabled.tax-product_cat .bg-woocommerce-shell{
    width:min(1880px,calc(100vw - 80px))!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-layout,
  body.bgc-enabled.tax-product_cat .bgc-shop-layout{
    grid-template-columns:285px minmax(0,1fr)!important;
    gap:38px!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-filter,
  body.bgc-enabled.tax-product_cat .bgc-filter{
    width:285px!important;
    max-width:285px!important;
  }
}

/* 2.0.43 — desktop shop first-cell/gap reset.
   Woo/theme float-era .first/.last placement can leave an empty grid column.
   Own grid placement explicitly on desktop, while leaving <=1099px untouched. */
@media (min-width:1100px){
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products{
    grid-auto-flow:row!important;
    justify-content:stretch!important;
    justify-items:stretch!important;
    align-content:start!important;
    direction:ltr!important;
    margin-left:0!important;
    margin-right:0!important;
    padding-left:0!important;
    padding-right:0!important;
  }

  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products > li.product,
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products > li.product.first,
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products > li.product.last,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products > li.product,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products > li.product.first,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products > li.product.last{
    grid-column:auto!important;
    grid-row:auto!important;
    justify-self:stretch!important;
    align-self:stretch!important;
    margin-left:0!important;
    margin-right:0!important;
    left:auto!important;
    right:auto!important;
  }

  /* The product rail must begin immediately after the sidebar. */
  body.bgc-enabled.post-type-archive-product .bgc-shop-main,
  body.bgc-enabled.tax-product_cat .bgc-shop-main,
  body.bgc-enabled.post-type-archive-product .bgc-shop-main > .woocommerce,
  body.bgc-enabled.tax-product_cat .bgc-shop-main > .woocommerce{
    margin-left:0!important;
    padding-left:0!important;
    justify-self:stretch!important;
  }
}

/* 2.0.44 — hard grid ownership on desktop.
   Some shop/theme CSS was still leaving the first product in column 2 on row 1.
   Dense placement + an explicit first cell prevents any phantom opening. */
@media (min-width:1100px){
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products{
    grid-auto-flow:row dense!important;
  }
  body.bgc-enabled.post-type-archive-product .bgc-shop-main ul.products > li.product:first-of-type,
  body.bgc-enabled.tax-product_cat .bgc-shop-main ul.products > li.product:first-of-type{
    grid-column-start:1!important;
    grid-row-start:1!important;
  }
}
