/* Checkout Modal Styles */

.checkout-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(5px);
    z-index: 3000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.checkout-overlay.open {
    opacity: 1;
    pointer-events: auto;
}

.checkout-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    background: var(--color-bg);
    border-radius: 8px;
    z-index: 3001;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.checkout-modal.open {
    opacity: 1;
    pointer-events: auto;
    transform: translate(-50%, -50%) scale(1);
}

.checkout-header {
    padding: 1.5rem var(--spacing-md);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--color-border);
}

.checkout-header h2 {
    margin: 0;
    font-size: 1rem;
    letter-spacing: 0.1em;
}

.checkout-body {
    flex: 1;
    overflow-y: auto;
    padding: var(--spacing-md);
}

/* Form styles */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
    color: var(--color-text);
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    font-size: 0.9rem;
    font-family: inherit;
    transition: border-color 0.2s ease;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--color-primary);
}

.form-group select {
    cursor: pointer;
    background-color: var(--color-bg);
}

/* Total section */
.checkout-total-section {
    background: #F9F9F9;
    padding: 1rem;
    border-radius: 4px;
    margin: 1.5rem 0;
}

.checkout-subtotal,
.checkout-discount,
.checkout-total {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.checkout-total {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0;
    padding-top: 0.75rem;
    border-top: 1px solid var(--color-border);
}

.discount-amount {
    color: var(--color-green);
    font-weight: 600;
}

.total-amount {
    font-size: 1.2rem;
}

.shipping-note {
    font-size: 0.7rem;
    color: #777;
    margin-top: 0.5rem;
    font-style: italic;
}

.total-asterisk {
    font-size: 0.7rem;
    color: #888;
    margin-left: 2px;
}

.checkout-combo-discount {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    color: #7FC3A3;
    /* Verde Agua */
}

.checkout-combo-discount .discount-amount {
    font-weight: 600;
}

/* Button */
#checkoutForm button[type="submit"] {
    width: 100%;
    margin-top: 1rem;
    transition: opacity 0.2s ease, background-color 0.2s ease;
}

#checkoutForm button[type="submit"]:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #999;
}

/* Responsive */
@media (max-width: 450px) {
    .checkout-modal {
        width: 95%;
        max-height: 95vh;
    }

    .checkout-header {
        padding: 1rem;
    }

    .checkout-body {
        padding: 1rem;
    }
}