/* Motors Dealer Membership - Frontend Styles */

/* Existing pricing table styles... (keeping original) */
.mdm-membership-plans-wrapper {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

/* ... (keeping all original CSS) ... */

/* ==========================================
   CHECKOUT MODAL STYLES - PROFESSIONAL DESIGN
   ========================================== */

/* Modal Overlay */
.mdm-checkout-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    z-index: 999999;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: mdmFadeIn 0.3s ease;
}

@keyframes mdmFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Modal Container */
.mdm-checkout-modal {
    background: #fff;
    width: 90%;
    max-width: 1100px;
    max-height: 90vh;
    border-radius: 8px;
    position: relative;
    overflow: hidden;
    animation: mdmSlideUp 0.3s ease;
}

@keyframes mdmSlideUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

body.mdm-modal-open {
    overflow: hidden;
}

/* Close Button */
.mdm-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: transparent;
    border: none;
    font-size: 36px;
    line-height: 1;
    cursor: pointer;
    color: #6c757d;
    z-index: 10;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
}

.mdm-modal-close:hover {
    color: #000;
    transform: rotate(90deg);
}

/* Checkout Container - Two Columns */
.mdm-checkout-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    min-height: 500px;
    max-height: 90vh;
    overflow-y: auto;
}

/* Left Side - Membership Summary */
.mdm-checkout-left {
    padding: 50px 40px;
    background: #f8f9fa;
    border-right: 1px solid #e9ecef;
}

.mdm-checkout-left h2 {
    font-size: 28px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 30px 0;
}

.mdm-summary-box {
    background: #fff;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
}

.mdm-summary-box h3 {
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 15px 0;
}

.dealer-info {
    color: #495057;
    font-size: 15px;
    line-height: 1.6;
    margin: 0;
}

.dealer-info strong {
    color: #2c3e50;
}

.pricing-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid #e9ecef;
    font-size: 16px;
    color: #495057;
}

.pricing-row .price {
    font-weight: 700;
    color: #2c3e50;
}

.pricing-detail {
    font-size: 13px;
    color: #6c757d;
    margin: 8px 0 0 0;
}

/* Total Box - Dark Background */
.total-box {
    background: #2c3e50;
    color: #fff;
    padding: 20px 25px;
    margin: 30px -30px -30px -30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.total-label {
    font-size: 18px;
    font-weight: 600;
}

.total-amount {
    font-size: 28px;
    font-weight: 700;
    color: #5a9fd4;
}

/* Right Side - Payment Method */
.mdm-checkout-right {
    padding: 50px 40px;
    background: #fff;
}

.mdm-checkout-right h2 {
    font-size: 28px;
    font-weight: 700;
    color: #2c3e50;
    margin: 0 0 15px 0;
}

.payment-subtitle {
    color: #6c757d;
    font-size: 15px;
    margin: 0 0 30px 0;
}

/* Payment Methods */
.payment-methods {
    margin-bottom: 30px;
}

.gateway-wrapper {
    margin-bottom: 0;
}

.payment-method-option {
    display: flex;
    align-items: flex-start;
    padding: 18px 20px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    background: #fff;
    margin-bottom: 12px;
    position: relative;
}

.payment-method-option:hover {
    border-color: #5a9fd4;
    background: #f8f9fa;
}

.payment-method-option input[type="radio"] {
    margin: 3px 15px 0 0;
    width: 18px;
    height: 18px;
    cursor: pointer;
    flex-shrink: 0;
}

.payment-method-option input[type="radio"]:checked + .gateway-title {
    color: #5a9fd4;
    font-weight: 600;
}

.payment-method-option .gateway-title {
    font-size: 16px;
    font-weight: 500;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1;
}

.payment-method-option .gateway-title img {
    max-height: 24px;
    width: auto;
}

.payment-method-option .gateway-description {
    display: block;
    font-size: 13px;
    color: #6c757d;
    margin-top: 5px;
    font-weight: normal;
}

/* Stripe Card Form */
.stripe-card-form {
    border: 2px solid #e9ecef;
    border-radius: 8px;
}

.stripe-card-form label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #495057;
    margin-bottom: 8px;
}

.stripe-element {
    padding: 12px 14px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    background: #fff;
    transition: border-color 0.15s ease-in-out;
}

.stripe-element:focus-within {
    border-color: #5a9fd4;
    box-shadow: 0 0 0 0.2rem rgba(90, 159, 212, 0.25);
}

.stripe-errors {
    font-size: 13px;
    font-weight: 500;
}

/* Payment Notice */
.payment-notice {
    background: #fff9e6;
    border-left: 4px solid #ffc107;
    padding: 15px 20px;
    margin-bottom: 30px;
    border-radius: 4px;
}

.payment-notice p {
    margin: 0;
    color: #856404;
    font-size: 14px;
}

/* Proceed Button */
.mdm-proceed-payment-btn {
    width: 100%;
    padding: 18px 30px;
    background: #5a9fd4;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mdm-proceed-payment-btn:hover {
    background: #4a8fc4;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(90, 159, 212, 0.3);
}

.mdm-proceed-payment-btn:disabled {
    background: #6c757d;
    cursor: not-allowed;
    transform: none;
}

/* Responsive Design */
@media (max-width: 968px) {
    .mdm-checkout-container {
        grid-template-columns: 1fr;
    }
    
    .mdm-checkout-left {
        border-right: none;
        border-bottom: 1px solid #e9ecef;
    }
    
    .mdm-checkout-left,
    .mdm-checkout-right {
        padding: 30px 25px;
    }
    
    .mdm-checkout-modal {
        width: 95%;
        max-height: 95vh;
    }
}

@media (max-width: 576px) {
    .mdm-checkout-left h2,
    .mdm-checkout-right h2 {
        font-size: 22px;
    }
    
    .total-amount {
        font-size: 24px;
    }
    
    .mdm-summary-box {
        padding: 20px;
    }
    
    .total-box {
        margin: 20px -20px -20px -20px;
    }
}

/* Loading Spinner */
.mdm-spinner {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: #fff;
    animation: mdmSpin 0.6s linear infinite;
    vertical-align: middle;
    margin-right: 8px;
}

@keyframes mdmSpin {
    to { transform: rotate(360deg); }
}

.mdm-select-plan-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}
