/* ============================================
   UPSELL MODAL - Last Credit Popup
   ============================================ */

.upsell-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.upsell-overlay.active {
    opacity: 1;
    visibility: visible;
}

.upsell-modal {
    background: var(--surface, #152238);
    border: 1px solid var(--border, #24324a);
    border-radius: 24px;
    max-width: 480px;
    width: 100%;
    position: relative;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    overflow: hidden;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.6);
}

.upsell-overlay.active .upsell-modal {
    transform: scale(1) translateY(0);
}

.upsell-header {
    background: linear-gradient(135deg, var(--primary, #0e7490) 0%, var(--primary-hover, #0b6077) 100%);
    padding: 32px 24px;
    text-align: center;
    position: relative;
}

.upsell-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
    padding: 6px 14px;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
}

.upsell-badge::before {
    content: '';
    width: 8px;
    height: 8px;
    background: #22c55e;
    border-radius: 50%;
    animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(0.8); }
}

.upsell-title {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 1.75rem;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
    line-height: 1.2;
}

.upsell-subtitle {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1rem;
}

.upsell-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border: none;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    transition: background 0.2s ease;
}

.upsell-close:hover {
    background: rgba(255, 255, 255, 0.25);
}

.upsell-body {
    padding: 28px 24px;
}

.upsell-design-preview {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    background: var(--bg-secondary, #10192b);
    border-radius: 16px;
    margin-bottom: 24px;
}

.upsell-design-img {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    object-fit: cover;
    border: 2px solid var(--border, #24324a);
}

.upsell-design-info h4 {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text, #fff);
}

.upsell-design-info p {
    font-size: 0.875rem;
    color: var(--text-secondary, #b3c1d9);
}

.upsell-offer {
    text-align: center;
    margin-bottom: 24px;
}

.upsell-discount-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
    color: #fff;
    padding: 10px 20px;
    border-radius: 9999px;
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.upsell-discount-badge::before {
    content: '🔥';
}

.upsell-pricing {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 8px;
}

.upsell-old-price {
    font-size: 1.5rem;
    color: var(--text-muted, #8fa4c4);
    text-decoration: line-through;
}

.upsell-new-price {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text, #fff);
}

.upsell-price-detail {
    font-size: 0.875rem;
    color: var(--text-secondary, #b3c1d9);
}

.upsell-countdown {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: rgba(249, 115, 22, 0.1);
    border: 1px solid rgba(249, 115, 22, 0.3);
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 20px;
}

.upsell-countdown-icon {
    font-size: 1.25rem;
}

.upsell-countdown-text {
    font-size: 0.875rem;
    font-weight: 600;
    color: #f97316;
}

.upsell-btn {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.upsell-btn-primary {
    background: linear-gradient(135deg, #22c55e 0%, #16a34a 100%);
    color: #fff;
    border: none;
    padding: 18px 32px;
    border-radius: 14px;
    font-size: 1.125rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.upsell-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(34, 197, 94, 0.4);
}

.upsell-btn-primary small {
    font-size: 0.75rem;
    font-weight: 500;
    opacity: 0.9;
}

.upsell-btn-secondary {
    background: transparent;
    color: var(--text-muted, #8fa4c4);
    border: none;
    padding: 12px;
    font-size: 0.875rem;
    cursor: pointer;
    text-decoration: underline;
    transition: color 0.2s ease;
}

.upsell-btn-secondary:hover {
    color: var(--text, #fff);
}

.upsell-trust {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border, #24324a);
}

.upsell-trust-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    color: var(--text-secondary, #b3c1d9);
}

.upsell-trust-item::before {
    content: '✓';
    color: #22c55e;
    font-weight: 700;
}

/* Responsive */
@media (max-width: 480px) {
    .upsell-modal {
        margin: 10px;
        border-radius: 20px;
    }
    
    .upsell-header {
        padding: 24px 20px;
    }
    
    .upsell-title {
        font-size: 1.5rem;
    }
    
    .upsell-body {
        padding: 20px;
    }
    
    .upsell-new-price {
        font-size: 2rem;
    }
}

/* ============================================
   EXIT INTENT POPUP
   ============================================ */

.exit-intent-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    z-index: 10001;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.exit-intent-overlay.active {
    opacity: 1;
    visibility: visible;
}

.exit-intent-modal {
    background: var(--surface, #152238);
    border: 2px solid var(--primary, #0e7490);
    border-radius: 24px;
    max-width: 440px;
    width: 100%;
    padding: 32px;
    text-align: center;
    position: relative;
    transform: scale(0.9);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 0 60px rgba(14, 116, 144, 0.3);
}

.exit-intent-overlay.active .exit-intent-modal {
    transform: scale(1);
}

.exit-intent-emoji {
    font-size: 4rem;
    margin-bottom: 16px;
}

.exit-intent-title {
    font-family: 'Space Grotesk', 'Inter', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text, #fff);
}

.exit-intent-text {
    color: var(--text-secondary, #b3c1d9);
    margin-bottom: 24px;
    line-height: 1.6;
}

.exit-intent-offer {
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.15) 0%, rgba(234, 88, 12, 0.1) 100%);
    border: 1px dashed rgba(249, 115, 22, 0.5);
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 24px;
}

.exit-intent-code {
    font-family: 'Space Mono', monospace;
    font-size: 1.75rem;
    font-weight: 800;
    color: #f97316;
    letter-spacing: 2px;
    margin-bottom: 8px;
}

.exit-intent-discount {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text, #fff);
}

.exit-intent-buttons {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.exit-intent-btn-primary {
    background: linear-gradient(135deg, var(--primary, #0e7490) 0%, var(--primary-hover, #0b6077) 100%);
    color: #fff;
    border: none;
    padding: 16px 32px;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.exit-intent-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(14, 116, 144, 0.4);
}

.exit-intent-btn-secondary {
    background: transparent;
    color: var(--text-muted, #8fa4c4);
    border: none;
    padding: 12px;
    font-size: 0.875rem;
    cursor: pointer;
    transition: color 0.2s ease;
}

.exit-intent-btn-secondary:hover {
    color: var(--text, #fff);
}
