.single_add_to_cart_button,
.add_to_cart_button {
    border-radius: 12px;   /* Slightly rounded corners */
    padding: 12px 24px;    /* Bigger click area */
    background-color: #0073aa; /* WooCommerce default blue, change if you want */
    color: #fff;            /* Button text color */
    border: none;
    cursor: pointer;
    transition: all 0.2s ease; /* smooth hover */
}

.single_add_to_cart_button:hover,
.add_to_cart_button:hover {
    background-color: #005f8d; /* Darker on hover */
    transform: scale(1.03);    /* subtle pop effect */
}

/* =================================
   BW WAS / SAVE Badge
   Top Right - Matches Other Badges
================================= */

.bw-price-badge {
  position: absolute;
  top: 7px;
  right: 7px !important;
  left: auto !important;
  z-index: 30;
  border-radius: 7px;
  overflow: hidden;
  display: inline-block;
  font-family: inherit;
  box-shadow: 0 2px 4px rgba(0,0,0,0.25);
}

.bw-price-badge .bw-was,
.bw-price-badge .bw-now {
  background: var(
    --wd-primary-color,
    var(
      --e-global-color-primary,
      var(
        --wp--preset--color--primary,
        var(
          --ast-global-color-0,
          var(
            --kadence-color-palette1,
            var(
              --generatepress-primary-color,
              var(
                --fl-primary-color,
                var(
                  --porto-primary-color,
                  var(
                    --ocean-primary-color,
                    #000
                  )
                )
              )
            )
          )
        )
      )
    )
  );
  padding: 3px 7px;
  display: block;
  white-space: nowrap;
  line-height: 1.05;
}

.bw-price-badge .bw-label {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  margin-right: 4px;
  letter-spacing: .04em;
}

.bw-price-badge .bw-was .bw-amount {
  font-size: 11.5px;
  font-weight: 700;
}

.bw-price-badge .bw-now .bw-amount {
  font-size: 12px;
  font-weight: 800;
}

.bw-price-badge,
.bw-price-badge * {
  color: #fff !important;
}

/* =================================
   MOBILE - Slightly Smaller
   Desktop Unchanged
================================= */

@media (max-width: 768px) {

  .bw-price-badge {
    top: 5px;
    right: 5px !important;
    left: auto !important;
    border-radius: 6px;
  }

  .bw-price-badge .bw-was,
  .bw-price-badge .bw-now {
    padding: 2px 5px;
  }

  .bw-price-badge .bw-label {
    font-size: 9px;
    margin-right: 3px;
  }

  .bw-price-badge .bw-was .bw-amount {
    font-size: 10.5px;
  }

  .bw-price-badge .bw-now .bw-amount {
    font-size: 10.5px;
  }
}

/* Hide default WooCommerce sale badge */
.woocommerce span.onsale {
  display: none !important;
}

/* ==========================================
   MOBILE SINGLE PRODUCT PAGE ONLY
   MOVE WAS / SAVE BADGE LEFT
   Match IN STOCK Badge - 60px
========================================== */

@media (max-width: 767px) {

  body.single-product .bw-price-badge {
    right: 60px !important;
    left: auto !important;
  }

}

/* =================================
   BW PRE-ORDER Badge
   Top Left - Desktop & Mobile
   Matches FINANCE AVAILABLE
================================= */

.bw-preorder-badge {
  position: absolute !important;
  top: 7px !important;
  left: 7px !important;
  right: auto !important;
  bottom: auto !important;
  transform: none !important;

  background: #000;
  color: #fff !important;
  padding: 4.5px 7px;
  font-size: 11.5px !important;
  font-weight: 800;
  text-transform: uppercase;
  border-radius: 8px;
  line-height: 1;
  z-index: 31;
  box-shadow: 0 2px 4px rgba(0,0,0,0.25);
  white-space: nowrap;
  font-family: inherit;
  text-align: center;
  box-sizing: border-box;
}

/* Sale PRE-ORDER on individual product pages:
   Top left to avoid WAS/SAVE badge */

.single-product .bw-preorder-badge.bw-preorder-sale {
  top: 7px !important;
  left: 7px !important;
  right: auto !important;
  transform: none !important;
}

/* =================================
   MOBILE - Smaller Badge
   Desktop Unchanged
================================= */

@media (max-width: 767px) {

  .bw-preorder-badge {
    top: 5px !important;
    left: 5px !important;
    right: auto !important;
    bottom: auto !important;
    transform: none !important;

    font-size: 10.5px !important;
    padding: 3px 5px;
    border-radius: 6px;
  }

  /* Sale PRE-ORDER - Top Left */
  .single-product .bw-preorder-badge.bw-preorder-sale {
    top: 5px !important;
    left: 5px !important;
    right: auto !important;
    transform: none !important;
  }

  /* =====================================
     SINGLE PRODUCT PAGE - MOBILE ONLY
     Match FINANCE AVAILABLE Position
     60px From Left
  ===================================== */

  body.single-product .bw-preorder-badge,
  body.single-product .bw-preorder-badge.bw-preorder-sale {
    top: 5px !important;
    left: 60px !important;
    right: auto !important;
    bottom: auto !important;
    transform: none !important;
  }

}

/* ==========================================
   BW IN STOCK BADGE
   Bottom Right - Beside Cart Buttons
   WoodMart Desktop & Mobile
========================================== */

.wd-products .product-grid-item .bw-image-stock-badge,
.woocommerce ul.products li.product .bw-image-stock-badge {
  position: absolute !important;

  top: auto !important;
  bottom: 13px !important;
  right: 2px !important;
  left: auto !important;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 3px;

  width: max-content !important;
  max-width: calc(100% - 16px);

  background: #555b60 !important;
  color: #fff !important;
  border-radius: 20px;
  padding: 4px 7px !important;

  font-size: 10px !important;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  font-family: inherit;

  z-index: 28;
  box-sizing: border-box;
  box-shadow: 0 2px 4px rgba(0,0,0,0.18);
}

/* Green tick */
.bw-image-stock-badge .bw-stock-tick {
  color: #72d68b !important;
  font-size: 12px !important;
  font-weight: 800;
  line-height: 1;
}

/* ==========================================
   PRODUCT TITLE AND PRICE
========================================== */

.wd-products .product-grid-item,
.woocommerce ul.products li.product {
  text-align: left !important;
}

.wd-products .product-grid-item .wd-entities-title,
.woocommerce ul.products li.product
.woocommerce-loop-product__title {
  text-align: left !important;
  min-height: 0 !important;
}

.wd-products .product-grid-item .price,
.woocommerce ul.products li.product .price {
  text-align: left !important;
}

/* Hide crossed-out regular price */
.wd-products .product-grid-item .price del,
.woocommerce ul.products li.product .price del {
  display: none !important;
}

/* Keep current sale price */
.wd-products .product-grid-item .price ins,
.woocommerce ul.products li.product .price ins {
  text-decoration: none !important;
}

/* ==========================================
   MOBILE - ORIGINAL PRODUCT CARDS
========================================== */

@media (max-width: 767px) {

  .wd-products .product-grid-item .bw-image-stock-badge,
  .woocommerce ul.products li.product .bw-image-stock-badge {
    bottom: 11px !important;
    right: 0px !important;

    font-size: 9px !important;
    padding: 3px 6px !important;
  }

  .bw-image-stock-badge .bw-stock-tick {
    font-size: 11px !important;
  }
}

/* ==========================================
   SINGLE PRODUCT PAGE ONLY
   IN STOCK BADGE ON PRODUCT IMAGE
========================================== */

body.single-product .woocommerce-product-gallery,
body.single-product .wd-product-gallery,
body.single-product .product-images {
  position: relative;
}

body.single-product .woocommerce-product-gallery .bw-image-stock-badge,
body.single-product .wd-product-gallery .bw-image-stock-badge,
body.single-product .product-images .bw-image-stock-badge {

  position: absolute !important;

  top: auto !important;
  bottom: 13px !important;
  right: 2px !important;
  left: auto !important;

  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 3px;

  width: max-content !important;
  max-width: calc(100% - 16px);

  background: #555b60 !important;
  color: #fff !important;

  border-radius: 20px;
  padding: 4px 7px !important;

  font-size: 10px !important;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  font-family: inherit;

  z-index: 30 !important;
  box-sizing: border-box;
  box-shadow: 0 2px 4px rgba(0,0,0,0.18);

  pointer-events: none;
}

/* Green tick - single product page */

body.single-product .bw-image-stock-badge .bw-stock-tick {
  color: #72d68b !important;
  font-size: 12px !important;
  font-weight: 800;
  line-height: 1;
}

/* ==========================================
   MOBILE SINGLE PRODUCT PAGE ONLY
   KEEP EXISTING MOBILE POSITION
========================================== */

@media (max-width: 767px) {

  body.single-product .woocommerce-product-gallery .bw-image-stock-badge,
  body.single-product .wd-product-gallery .bw-image-stock-badge,
  body.single-product .product-images .bw-image-stock-badge {

    top: auto !important;
    bottom: 13px !important;
    right: 60px !important;
    left: auto !important;

    font-size: 9px !important;
    padding: 3px 6px !important;
  }

  body.single-product .bw-image-stock-badge .bw-stock-tick {
    font-size: 11px !important;
  }
}

/* ==========================================
   DESKTOP SINGLE PRODUCT PAGE ONLY
   MOVE IN STOCK BADGE LEFT
   MATCH WAS / SAVE RIGHT EDGE SPACING
========================================== */

@media (min-width: 768px) {

  body.single-product .woocommerce-product-gallery .bw-image-stock-badge,
  body.single-product .wd-product-gallery .bw-image-stock-badge,
  body.single-product .product-images .bw-image-stock-badge {

    right: 7px !important;
    left: auto !important;

  }

}

/* ==========================================
   BW COMING SOON BADGE
   Desktop & Mobile
========================================== */

/* Badge appearance and positioning */
.bw-available-soon-badge {
    position: absolute !important;

    top: auto !important;
    bottom: 13px !important;
    right: 0px !important;
    left: auto !important;

    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    background: #555b60 !important;
    color: #fff !important;

    font-size: 10px !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;

    padding: 4px 7px !important;
    border-radius: 20px !important;

    white-space: nowrap !important;
    width: max-content !important;
    max-width: calc(100% - 16px);

    visibility: visible !important;
    opacity: 1 !important;

    z-index: 28 !important;

    box-shadow: 0 2px 4px rgba(0,0,0,0.18);
    box-sizing: border-box;
}

/* ==========================================
   DESKTOP VISIBILITY
========================================== */

@media (min-width: 768px) {

    .wd-products .product-grid-item
    .bw-available-soon-badge,

    .woocommerce ul.products li.product
    .bw-available-soon-badge {
        display: inline-flex !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
}

/* ==========================================
   MOBILE
========================================== */

@media (max-width: 767px) {

    .bw-available-soon-badge {
        bottom: 11px !important;
        right: -2px !important;

        font-size: 9px !important;
        padding: 3px 6px !important;
    }
}

/* ==========================================
   MOBILE SINGLE PRODUCT PAGE ONLY
   KEEP EXISTING MOBILE POSITION
========================================== */

@media (max-width: 767px) {

    body.single-product .bw-available-soon-badge {
        top: auto !important;
        bottom: 13px !important;
        right: 60px !important;
        left: auto !important;
    }
}

/* ==========================================
   DESKTOP SINGLE PRODUCT PAGE ONLY
   MATCH IN STOCK BADGE POSITION
========================================== */

@media (min-width: 768px) {

    body.single-product .woocommerce-product-gallery .bw-available-soon-badge,
    body.single-product .wd-product-gallery .bw-available-soon-badge,
    body.single-product .product-images .bw-available-soon-badge {

        position: absolute !important;

        top: auto !important;
        bottom: 13px !important;
        right: 7px !important;
        left: auto !important;

        z-index: 30 !important;
    }
}

/* ==========================================
   BW SOLD OUT BADGE
   Top Left - Desktop & Mobile
   Matches PRE-ORDER Badge
========================================== */

.bw-sold-out-badge {
  position: absolute !important;
  top: 7px !important;
  left: 7px !important;
  right: auto !important;
  bottom: auto !important;
  transform: none !important;

  background: #000;
  color: #fff !important;
  padding: 4.5px 7px;
  font-size: 11.5px !important;
  font-weight: 800;
  text-transform: uppercase;
  border-radius: 8px;
  line-height: 1;
  z-index: 31;
  box-shadow: 0 2px 4px rgba(0,0,0,0.25);
  white-space: nowrap;
  font-family: inherit;
  text-align: center;
  box-sizing: border-box;
}

/* ==========================================
   MOBILE - Matches PRE-ORDER
   Desktop Unchanged
========================================== */

@media (max-width: 767px) {

  .bw-sold-out-badge {
    top: 5px !important;
    left: 5px !important;
    right: auto !important;
    bottom: auto !important;
    transform: none !important;

    font-size: 10.5px !important;
    padding: 3px 5px;
    border-radius: 6px;
  }

  /* Individual product page - mobile only */
  body.single-product .bw-sold-out-badge {
    top: 5px !important;
    left: 60px !important;
    right: auto !important;
    bottom: auto !important;
    transform: none !important;
  }
}
