/* Sticky Bar Container */
#sbcb-sticky-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #ffffff;
    border-top: 1px solid #ddd;
    padding: 15px 5px 0px 10px;
    z-index: 9999;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.2);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

/* Hidden State */
.sbcb-hidden {
    opacity: 0;
    transform: translateY(100%);
    pointer-events: none;
}

/* Price Wrapper */
#sbcb-price-wrapper {
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: bold;
    font-size: 14px;
    color: #333;
    white-space: nowrap;
    flex-shrink: 0;
    padding-bottom: 10px;
}

/*Price Inherit Font Size */
/* Increased specificity to override theme styles for price amount */
#sbcb-sticky-bar #sbcb-price-wrapper #sbcb-price-container .woocommerce-Price-amount.amount,
#sbcb-sticky-bar #sbcb-price-wrapper #sbcb-price-container .amount { /* Fallback if .woocommerce-Price-amount is not present */
    font-size: inherit;
    color: #0c0bff;
    font-weight: bold;
    white-space: nowrap;
}

/* Label Styling */
/* Increased specificity for price label */
#sbcb-sticky-bar #sbcb-price-wrapper #sbcb-price-label {
    font-size: inherit;
    color: #000;
    font-weight: bold;
    white-space: nowrap;
}

/* Button Container */
#sbcb-buttons {
    display: flex;
    gap: 5px;
    flex-grow: 1;
    justify-content: flex-end;
}

/* Buttons */
#sbcb-sticky-bar button {
    padding: 4px 16px;
    font-size: 12px;
    font-weight: bold;
    border: none;
    border-radius: 5px;
    background-color: #FB3134;
    color: white;
    cursor: pointer;
    transition: background 0.3s ease;
    display: flex;
    align-items: center;
    text-align: center;
    justify-content: center;
    position: relative;
}

/* Button Hover */
#sbcb-sticky-bar button:hover {
    opacity: 0.9;
}

/* Loader */
.sbcb-loader {
    display: none;
    width: 18px;
    height: 18px;
    border: 3px solid #fff;
    border-top: 3px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 16px;
    margin-right: 16px;
}

/* Spin Animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Medium Screens (Tablets) */
@media (min-width: 768px) {
    #sbcb-sticky-bar button {
        font-size: 14px;
        padding-left: 24px;
        padding-right: 24px;
    }

    #sbcb-price-wrapper {
        font-size: 16px;
    }
}

/* Large Screens (Desktops) */
@media (min-width: 1024px) {
    #sbcb-sticky-bar button {
        font-size: 16px;
        padding-left: 34px;
        padding-right: 34px;
    }

    #sbcb-price-wrapper {
        font-size: 18px;
    }
}


/* Hide only default Add to Cart & Buy Now buttons inside form.cart */
/* Increased specificity to hide original theme buttons */
body.single-product div.product form.cart button.single_add_to_cart_button,
body.single-product div.product form.cart .button.alt, /* Common alternative for add to cart */
body.single-product div.product form.cart input[type="submit"].button, /* Another common pattern */
body.single-product div.product form.cart .buy-now-button { /* For buy now buttons if present */
    display: none;
}

/* Hide entire quantity input section */
/* Increased specificity to hide original quantity input */
body.single-product div.product form.cart .quantity,
body.single-product div.product form.cart div.quantity { /* Targeting div wrapper if present */
    display: none;
}