/* Variations Wrapper */
.ice-variations-wrapper {
    margin-bottom: 20px;
}

/* Hide WooCommerce's default add to cart button and quantity input inside our variations wrapper */
.ice-variations-wrapper .single_add_to_cart_button,
.ice-variations-wrapper .quantity {
    display: none !important;
}

/* Style the variations form */
.ice-variations-wrapper .variations {
    margin-bottom: 15px;
}

.ice-variations-wrapper .variations td,
.ice-variations-wrapper .variations th {
    padding: 8px 0;
}

.ice-variations-wrapper .variations select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
}

.ice-variations-wrapper .reset_variations {
    margin-top: 10px;
    font-size: 13px;
}

/* Instant Checkout Wrapper */
.ice-wrapper {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

/* Quantity Input */
.ice-qty {
    width: 70px;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    text-align: center;
    appearance: textfield;
    -moz-appearance: textfield;
}

.ice-qty::-webkit-outer-spin-button,
.ice-qty::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.ice-qty:focus {
    outline: none;
    border-color: #7c3aed;
    box-shadow: 0 0 0 2px rgba(124, 58, 237, 0.2);
}

/* Add to Cart Button */
.ice-cart-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: 1px solid #333;
    border-radius: 5px;
    background-color: #ffffff;
    color: #333;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
}

.ice-cart-btn:hover {
    background-color: #333;
    color: #ffffff;
}

.ice-cart-btn:active {
    opacity: 0.9;
}

.ice-cart-btn.ice-loading {
    pointer-events: none;
    opacity: 0.8;
}

/* Buy Now Button */
.ice-btn,
.ice-buy-now-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border: none;
    border-radius: 5px;
    background-color: #7c3aed;
    color: #ffffff;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 120px;
}

.ice-btn:hover,
.ice-buy-now-btn:hover {
    background-color: #6d28d9;
}

.ice-btn:active,
.ice-buy-now-btn:active {
    opacity: 0.9;
}

.ice-btn.ice-loading,
.ice-buy-now-btn.ice-loading {
    pointer-events: none;
    opacity: 0.8;
}

/* Disabled state for both buttons when no variation selected */
.ice-buy-now-btn.ice-disabled,
.ice-buy-now-btn:disabled,
.ice-cart-btn.ice-disabled,
.ice-cart-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
    filter: blur(1px);
}

.ice-btn-text {
    display: inline-block;
}

.ice-btn-loading {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.ice-spinner {
    animation: ice-spin 1s linear infinite;
}

@keyframes ice-spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Notice Messages */
.ice-notice {
    padding: 12px 16px;
    margin-bottom: 15px;
    border-radius: 5px;
    font-size: 14px;
    line-height: 1.5;
}

.ice-notice-error {
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    color: #dc2626;
}

.ice-notice-success {
    background-color: #f0fdf4;
    border: 1px solid #bbf7d0;
    color: #16a34a;
}

.ice-notice-info {
    background-color: #eff6ff;
    border: 1px solid #bfdbfe;
    color: #2563eb;
}

/* Error Message */
.ice-error {
    color: #dc2626;
    font-size: 14px;
    padding: 10px;
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 5px;
}

/* Responsive */
@media (max-width: 480px) {
    .ice-wrapper {
        flex-direction: column;
        align-items: stretch;
    }
    
    .ice-qty {
        width: 100%;
    }
    
    .ice-btn,
    .ice-buy-now-btn,
    .ice-cart-btn {
        width: 100%;
    }
}
