
/* 1. HIDE DEFAULT BUTTONS (Global) */
.add-links-wrap, .links-on-image, .product-image .viewcart, 
.porto-add-to-cart-product, .overlay-container .add-links, 
.product-content .add-links, 
.add_to_cart_button:not(.ezq-add-cart) { 
    display: none !important; 
}

/* 2. WRAPPER STYLES */
.ezq-wrapper {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch !important;
    gap: 0 !important;
    margin-top: 15px !important;
    width: 100% !important;
    box-sizing: border-box;
    /* Ensure it works inside sliders */
    position: relative; 
    z-index: 2; 
}

/* 3. QUANTITY GROUP (Left) */
.ezq-qty-group {
    display: flex !important;
    flex: 0 0 auto !important;
    width: 90px !important;
    border: 1px solid #dcdcdc;
    border-radius: 4px 0 0 4px;
    border-right: none;
    height: 36px !important;
    overflow: hidden;
    background: #fff;
}

.ezq-btn {
    width: 25px !important;
    background: #f4f4f4 !important;
    border: none !important;
    font-size: 14px !important;
    font-weight: 900 !important;
    color: #555 !important;
    padding: 0 !important;
    cursor: pointer !important;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100% !important;
}
.ezq-btn:hover { background: #e0e0e0 !important; }

.ezq-input {
    width: 40px !important;
    text-align: center !important;
    border: none !important;
    background: #fff !important;
    font-weight: 600 !important;
    font-size: 13px !important;
    color: #333 !important;
    padding: 0 !important;
    height: 100% !important;
    -moz-appearance: textfield;
}
.ezq-input::-webkit-outer-spin-button, .ezq-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* 4. ADD BUTTON (Right) */
a.ezq-add-cart.button {
    flex: 1 1 auto !important;
    background-color: #003d7a !important; /* CWFD Navy Blue */
    color: white !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    border: 1px solid #003d7a !important;
    border-radius: 0 4px 4px 0 !important;
    height: 36px !important;
    line-height: 34px !important;
    padding: 0 5px !important;
    text-align: center !important;
    display: block !important;
    margin: 0 !important;
    float: none !important; /* Fix floats inside Porto */
}

a.ezq-add-cart.button:hover { background-color: #002a54 !important; border-color: #002a54 !important; opacity: 1 !important; }

/* 5. SUCCESS STATE */
a.ezq-add-cart.added { background-color: #22c55e !important; border-color: #22c55e !important; content: "Done" !important; }
a.ezq-add-cart.added::after { display: none !important; }

/* 6. SLIDER & CAROUSEL SPECIFIC FIXES (Porto) */
.owl-item .ezq-wrapper, .product-slide .ezq-wrapper {
    margin-top: 10px !important;
    padding-bottom: 5px; /* Prevent cutout */
}
/* Ensure the button wrapper stays below price */
ul.products li.product .product-inner { padding-bottom: 5px !important; }
