
/* =========================================================
   DEPLOYMENT ENGINE — v9.0
   Explicit module scoping
   ========================================================= */

/* CATEGORY EXPERIENCE */
body.ref-deploy-category.tax-product_cat .shop-container,
body.ref-deploy-category.post-type-archive-product .shop-container{
  max-width:1180px!important;
  margin:0 auto!important;
  padding:28px 20px 56px!important;
}

body.ref-deploy-category .products.row{
  display:grid!important;
  grid-template-columns:repeat(3,minmax(0,1fr))!important;
  gap:22px!important;
  margin:0!important;
}

body.ref-deploy-category .products.row > .product-small{
  width:auto!important;
  max-width:none!important;
  padding:0!important;
}

body.ref-deploy-category .product-small.box{
  height:100%!important;
  overflow:hidden!important;
  border:1px solid var(--ref-border)!important;
  border-radius:22px!important;
  background:#fff!important;
  box-shadow:0 14px 34px color-mix(in srgb,var(--ref-dark) 8%,transparent)!important;
}

body.ref-deploy-category .product-small .box-image{
  padding:18px!important;
  background:var(--ref-light)!important;
}

body.ref-deploy-category .product-small .box-text{
  padding:18px!important;
  text-align:center!important;
}

body.ref-deploy-category .product-small .button,
body.ref-deploy-category .product-small .add_to_cart_button{
  display:inline-flex!important;
  min-height:42px!important;
  align-items:center!important;
  justify-content:center!important;
  border:0!important;
  border-radius:999px!important;
  background:var(--ref-gradient)!important;
  color:#fff!important;
  padding:0 20px!important;
}

/* PRODUCT EXPERIENCE */
body.ref-deploy-product.single-product .product-main{
  padding:34px 0 50px!important;
}

body.ref-deploy-product.single-product .product-info{
  border:1px solid var(--ref-border)!important;
  border-radius:24px!important;
  background:#fff!important;
  box-shadow:0 16px 38px color-mix(in srgb,var(--ref-dark) 8%,transparent)!important;
  padding:28px!important;
}

/* CART EXPERIENCE */
body.ref-deploy-cart.woocommerce-cart .woocommerce-cart-form,
body.ref-deploy-cart.woocommerce-cart .cart_totals{
  border:1px solid var(--ref-border)!important;
  border-radius:24px!important;
  background:#fff!important;
  box-shadow:0 16px 38px color-mix(in srgb,var(--ref-dark) 8%,transparent)!important;
  padding:24px!important;
}

/* CHECKOUT EXPERIENCE */
body.ref-deploy-checkout.woocommerce-checkout #customer_details,
body.ref-deploy-checkout.woocommerce-checkout #order_review{
  border:1px solid var(--ref-border)!important;
  border-radius:24px!important;
  background:#fff!important;
  box-shadow:0 16px 38px color-mix(in srgb,var(--ref-dark) 8%,transparent)!important;
  padding:26px!important;
}

/* HEADER EXPERIENCE */
body.ref-deploy-header #header{
  box-shadow:0 10px 30px color-mix(in srgb,var(--ref-dark) 7%,transparent)!important;
}

/* FOOTER EXPERIENCE */
body.ref-deploy-footer #footer,
body.ref-deploy-footer .footer-wrapper{
  border-top:4px solid var(--ref-primary)!important;
}

/* MINI-CART EXPERIENCE */
body.ref-deploy-minicart .widget_shopping_cart{
  border-radius:18px!important;
}

@media(max-width:900px){
  body.ref-deploy-category .products.row{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }
}

@media(max-width:560px){
  body.ref-deploy-category .products.row{
    grid-template-columns:1fr!important;
  }
}


/* =========================================================
   STORE EXPERIENCE INSTALLER — v10
   Native Flatsome/WooCommerce structures, full presentation.
   ========================================================= */

/* PAGE WIDTH AND CART INTRO */
body.ref-deploy-cart.woocommerce-cart .page-wrapper,
body.ref-deploy-checkout.woocommerce-checkout .page-wrapper{
  max-width:1180px!important;
  margin:0 auto!important;
  padding:32px 20px 64px!important;
}

body.ref-deploy-cart .ref-commerce-header,
body.ref-deploy-checkout .ref-commerce-header{
  margin:0 0 24px!important;
  padding:34px 36px!important;
  border:1px solid var(--ref-border)!important;
  border-radius:26px!important;
  background:
    linear-gradient(
      135deg,
      color-mix(in srgb,var(--ref-primary) 8%,#fff),
      color-mix(in srgb,var(--ref-secondary) 5%,#fff)
    )!important;
  box-shadow:0 18px 44px color-mix(in srgb,var(--ref-dark) 8%,transparent)!important;
}

body.ref-deploy-cart .ref-commerce-header h1,
body.ref-deploy-checkout .ref-commerce-header h1{
  margin:7px 0 8px!important;
  color:var(--ref-dark)!important;
  font-size:clamp(30px,4vw,48px)!important;
  line-height:1.05!important;
}

body.ref-deploy-cart .ref-eyebrow,
body.ref-deploy-checkout .ref-eyebrow{
  display:inline-flex!important;
  padding:6px 10px!important;
  border-radius:999px!important;
  background:color-mix(in srgb,var(--ref-primary) 10%,#fff)!important;
  color:var(--ref-primary)!important;
  font-size:11px!important;
  font-weight:800!important;
  letter-spacing:.06em!important;
  text-transform:uppercase!important;
}

/* CART TWO-COLUMN SHELL */
body.ref-deploy-cart .woocommerce-cart-form{
  overflow:hidden!important;
}

body.ref-deploy-cart .woocommerce-cart-form table.shop_table{
  margin:0!important;
  border:0!important;
  background:transparent!important;
}

body.ref-deploy-cart .woocommerce-cart-form table.shop_table th{
  padding:12px 14px!important;
  border-bottom:1px solid var(--ref-border)!important;
  color:var(--ref-dark)!important;
  font-size:11px!important;
  letter-spacing:.05em!important;
  text-transform:uppercase!important;
}

body.ref-deploy-cart .woocommerce-cart-form table.shop_table td{
  padding:18px 14px!important;
  border-bottom:1px solid var(--ref-border)!important;
  vertical-align:middle!important;
}

body.ref-deploy-cart .woocommerce-cart-form img{
  width:72px!important;
  height:72px!important;
  object-fit:contain!important;
  border:1px solid var(--ref-border)!important;
  border-radius:14px!important;
  background:#fff!important;
}

body.ref-deploy-cart .ref-cart-product-name,
body.ref-deploy-cart .product-name a{
  color:var(--ref-dark)!important;
  font-weight:700!important;
  line-height:1.35!important;
}

body.ref-deploy-cart .quantity{
  display:inline-flex!important;
  align-items:center!important;
  overflow:hidden!important;
  border:1px solid var(--ref-border)!important;
  border-radius:999px!important;
  background:#fff!important;
}

body.ref-deploy-cart .quantity .button,
body.ref-deploy-cart .quantity input{
  min-width:38px!important;
  height:38px!important;
  margin:0!important;
  padding:0!important;
  border:0!important;
  box-shadow:none!important;
  text-align:center!important;
}

body.ref-deploy-cart .quantity .button{
  background:var(--ref-gradient)!important;
  color:#fff!important;
}

body.ref-deploy-cart .cart_totals{
  position:relative!important;
  padding:28px!important;
}

body.ref-deploy-cart .cart_totals h2{
  margin:0 0 20px!important;
  color:var(--ref-dark)!important;
  font-size:24px!important;
}

body.ref-deploy-cart .wc-proceed-to-checkout .checkout-button,
body.ref-deploy-cart .button[name="update_cart"],
body.ref-deploy-cart .coupon .button,
body.ref-deploy-checkout #place_order{
  display:flex!important;
  min-height:50px!important;
  align-items:center!important;
  justify-content:center!important;
  border:0!important;
  border-radius:999px!important;
  background:var(--ref-gradient)!important;
  color:#fff!important;
  box-shadow:0 12px 26px color-mix(in srgb,var(--ref-primary) 24%,transparent)!important;
  font-weight:800!important;
}

/* TRUST STRIP */
body.ref-deploy-cart .ref-cart-trust{
  display:grid!important;
  grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:10px!important;
  margin:24px 0!important;
  padding:14px!important;
  border-radius:22px!important;
  background:var(--ref-dark)!important;
}

body.ref-deploy-cart .ref-cart-trust span{
  min-width:0!important;
  padding:14px!important;
  border-radius:14px!important;
  background:color-mix(in srgb,var(--ref-primary) 17%,var(--ref-dark))!important;
  color:#fff!important;
}

body.ref-deploy-cart .ref-cart-trust b,
body.ref-deploy-cart .ref-cart-trust small{
  display:block!important;
}

body.ref-deploy-cart .ref-cart-trust small{
  margin-top:4px!important;
  opacity:.76!important;
  line-height:1.35!important;
}

/* PAYMENT PROVIDERS MUST KEEP THEIR OWN BRANDING */
body.ref-deploy-cart [id*="amazon"],
body.ref-deploy-cart [class*="amazon"],
body.ref-deploy-cart [id*="apple"],
body.ref-deploy-cart [class*="apple"],
body.ref-deploy-cart [id*="google"],
body.ref-deploy-cart [class*="google"],
body.ref-deploy-cart [id*="onelink"],
body.ref-deploy-cart [class*="onelink"]{
  filter:none!important;
}

/* CATEGORY HERO + SIDEBAR */
body.ref-deploy-category .ref-collection-hero{
  margin:0 0 28px!important;
  padding:32px 34px!important;
  border:1px solid var(--ref-border)!important;
  border-radius:26px!important;
  background:
    linear-gradient(
      135deg,
      color-mix(in srgb,var(--ref-primary) 8%,#fff),
      color-mix(in srgb,var(--ref-secondary) 5%,#fff)
    )!important;
  box-shadow:0 18px 44px color-mix(in srgb,var(--ref-dark) 8%,transparent)!important;
}

body.ref-deploy-category .shop-sidebar .widget{
  margin-bottom:18px!important;
  padding:18px!important;
  border:1px solid var(--ref-border)!important;
  border-radius:20px!important;
  background:#fff!important;
  box-shadow:0 12px 30px color-mix(in srgb,var(--ref-dark) 6%,transparent)!important;
}

body.ref-deploy-category .shop-sidebar .widget-title{
  color:var(--ref-dark)!important;
  font-size:16px!important;
  font-weight:800!important;
}

/* CHECKOUT */
body.ref-deploy-checkout form.checkout{
  display:grid!important;
  grid-template-columns:minmax(0,1.35fr) minmax(340px,.8fr)!important;
  gap:26px!important;
  align-items:start!important;
}

body.ref-deploy-checkout #customer_details,
body.ref-deploy-checkout #order_review{
  width:100%!important;
  margin:0!important;
}

body.ref-deploy-checkout #order_review{
  position:sticky!important;
  top:24px!important;
}

body.ref-deploy-checkout .form-row input,
body.ref-deploy-checkout .form-row select,
body.ref-deploy-checkout .form-row textarea{
  min-height:48px!important;
  border:1px solid var(--ref-border)!important;
  border-radius:13px!important;
  background:#fff!important;
  box-shadow:none!important;
}

@media(max-width:850px){
  body.ref-deploy-cart .ref-cart-trust{
    grid-template-columns:repeat(2,minmax(0,1fr))!important;
  }

  body.ref-deploy-checkout form.checkout{
    grid-template-columns:1fr!important;
  }

  body.ref-deploy-checkout #order_review{
    position:static!important;
  }
}

@media(max-width:560px){
  body.ref-deploy-cart .ref-commerce-header,
  body.ref-deploy-checkout .ref-commerce-header{
    padding:24px 20px!important;
  }

  body.ref-deploy-cart .ref-cart-trust{
    grid-template-columns:1fr!important;
  }
}


/* =========================================================
   FLATSOME CLASSIC CHECKOUT WIDTH FIX — v10.2
   Flatsome places both checkout columns inside form > .row.
   The form itself must not be a two-column grid.
   ========================================================= */
body.ref-deploy-checkout.woocommerce-checkout form.checkout,
body.ref-checkout-active.woocommerce-checkout form.checkout{
  display:block!important;
  width:100%!important;
  max-width:1180px!important;
  margin-right:auto!important;
  margin-left:auto!important;
}

body.ref-deploy-checkout.woocommerce-checkout form.checkout > .row,
body.ref-checkout-active.woocommerce-checkout form.checkout > .row{
  display:grid!important;
  grid-template-columns:minmax(0,1.45fr) minmax(390px,.85fr)!important;
  gap:28px!important;
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  align-items:start!important;
}

body.ref-deploy-checkout.woocommerce-checkout form.checkout > .row > .large-7,
body.ref-deploy-checkout.woocommerce-checkout form.checkout > .row > .large-5,
body.ref-checkout-active.woocommerce-checkout form.checkout > .row > .large-7,
body.ref-checkout-active.woocommerce-checkout form.checkout > .row > .large-5{
  width:100%!important;
  max-width:100%!important;
  flex-basis:auto!important;
  margin:0!important;
  padding:0!important;
  float:none!important;
}

body.ref-deploy-checkout.woocommerce-checkout form.checkout > .row > .large-5,
body.ref-checkout-active.woocommerce-checkout form.checkout > .row > .large-5{
  min-width:0!important;
}

body.ref-deploy-checkout.woocommerce-checkout #customer_details,
body.ref-checkout-active.woocommerce-checkout #customer_details{
  width:100%!important;
  max-width:none!important;
  margin:0!important;
  float:none!important;
}

body.ref-deploy-checkout.woocommerce-checkout #order_review_heading,
body.ref-deploy-checkout.woocommerce-checkout #order_review,
body.ref-checkout-active.woocommerce-checkout #order_review_heading,
body.ref-checkout-active.woocommerce-checkout #order_review{
  width:100%!important;
  max-width:none!important;
  margin-right:0!important;
  margin-left:0!important;
  float:none!important;
  clear:none!important;
}

body.ref-deploy-checkout.woocommerce-checkout #order_review,
body.ref-checkout-active.woocommerce-checkout #order_review{
  position:static!important;
  min-width:0!important;
  overflow:visible!important;
}

body.ref-deploy-checkout.woocommerce-checkout #order_review table,
body.ref-checkout-active.woocommerce-checkout #order_review table,
body.ref-deploy-checkout.woocommerce-checkout #payment,
body.ref-checkout-active.woocommerce-checkout #payment{
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  table-layout:auto!important;
}

body.ref-deploy-checkout.woocommerce-checkout #order_review .product-name,
body.ref-checkout-active.woocommerce-checkout #order_review .product-name{
  width:auto!important;
  max-width:none!important;
  white-space:normal!important;
  overflow-wrap:anywhere!important;
}

@media(max-width:980px){
  body.ref-deploy-checkout.woocommerce-checkout form.checkout > .row,
  body.ref-checkout-active.woocommerce-checkout form.checkout > .row{
    grid-template-columns:1fr!important;
  }
}
