/**
 * Trailex Custom Add to Cart Styles
 *
 * @package Trailex
 * @version 1.0.0
 */

/* Main wrapper */
.trailex-product-add-to-cart {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin: 10px 0;
}

/* Quantity selector wrapper */
.trailex-quantity-wrapper {
    display: inline-flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 3px;
    overflow: hidden;
}

/* Minus and Plus buttons */
.trailex-qty-minus,
.trailex-qty-plus {
    background: #f5f5f5;
    border: none;
    width: 20px;
    height: 36px;
    cursor: pointer;
    font-size: 11px;
    font-weight: bold;
    color: #333;
    transition: background 0.2s;
    user-select: none;
}

.trailex-qty-minus:hover,
.trailex-qty-plus:hover {
    background: #e0e0e0;
}

.trailex-qty-minus:active,
.trailex-qty-plus:active {
    background: #d0d0d0;
}

/* Quantity input field */
.trailex-qty-input,
input.trailex-qty-input,
.trailex-quantity-wrapper input.trailex-qty-input {
    width: 50px;
    height: 36px;
    text-align: center;
    border: none;
    border-left: 1px solid #ddd;
    border-right: 1px solid #ddd;
    font-size: 16px !important;
    font-weight: 700 !important;
    padding: 0;
    color: #000 !important;
    background-color: #ffffff !important;
    background: #ffffff !important;
    opacity: 1 !important;
    -webkit-text-fill-color: #000 !important;
    -moz-appearance: textfield; /* Remove spinner in Firefox */
    appearance: textfield; /* Standard property */
}

/* Remove spinner in Chrome/Safari */
.trailex-qty-input::-webkit-outer-spin-button,
.trailex-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Add to cart button */
.trailex-add-to-cart-button {
    background: #bb3524;
    color: white;
    padding: 5px 5px !important;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    transition: background 0.3s;
    font-size: 14px !important;
    font-weight: 600;
    height: 25px;
    min-width: 100px;
    width: 80%;
    max-width: 150px;
}

.trailex-add-to-cart-button:hover {
    background: #991f1a;
}

.trailex-add-to-cart-button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    .trailex-product-add-to-cart {
        gap: 8px;
    }

    .trailex-add-to-cart-button {
        max-width: 100%;
    }
}
