/**
 * Exit Intent Popup Styles
 * Theme color: #27ae60 (green)
 */

/* Overlay */
.exit-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    padding: 1rem;
    box-sizing: border-box;
}

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

/* Modal */
.exit-popup-modal {
    background: #ffffff;
    border-radius: 16px;
    max-width: 480px;
    width: 100%;
    position: relative;
    transform: translateY(-20px) scale(0.95);
    transition: transform 0.3s ease;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    overflow: hidden;
}

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

/* Close button */
.exit-popup-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border: none;
    background: #f1f5f9;
    border-radius: 50%;
    font-size: 24px;
    line-height: 1;
    color: #64748b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s ease, color 0.2s ease;
    z-index: 1;
}

.exit-popup-close:hover {
    background: #e2e8f0;
    color: #1e293b;
}

/* Content */
.exit-popup-content {
    padding: 2.5rem 2rem 2rem;
    text-align: center;
}

/* Icon */
.exit-popup-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: #ffffff;
}

/* Title */
.exit-popup-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #1e293b;
    margin: 0 0 0.5rem;
    line-height: 1.2;
}

/* Subtitle */
.exit-popup-subtitle {
    font-size: 1.125rem;
    font-weight: 600;
    color: #27ae60;
    margin: 0 0 1rem;
}

/* Description */
.exit-popup-description {
    font-size: 0.9375rem;
    color: #64748b;
    margin: 0 0 1.5rem;
    line-height: 1.6;
}

/* Form */
.exit-popup-form {
    margin-bottom: 1rem;
}

.exit-popup-input-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.exit-popup-input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 1rem;
    color: #1e293b;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-sizing: border-box;
}

.exit-popup-input:focus {
    outline: none;
    border-color: #27ae60;
    box-shadow: 0 0 0 3px rgba(39, 174, 96, 0.15);
}

.exit-popup-input::placeholder {
    color: #94a3b8;
}

.exit-popup-submit {
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.exit-popup-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(39, 174, 96, 0.4);
}

.exit-popup-submit:active {
    transform: translateY(0);
}

.exit-popup-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Dismiss button */
.exit-popup-dismiss {
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 0.875rem;
    cursor: pointer;
    padding: 0.5rem;
    transition: color 0.2s ease;
}

.exit-popup-dismiss:hover {
    color: #64748b;
}

/* Privacy text */
.exit-popup-privacy {
    font-size: 0.75rem;
    color: #94a3b8;
    margin: 0.75rem 0 0;
}

/* Success state */
.exit-popup-success {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 0;
    color: #27ae60;
}

.exit-popup-success svg {
    color: #27ae60;
}

.exit-popup-success p {
    font-size: 1rem;
    font-weight: 600;
    margin: 0;
}

/* Responsive adjustments */
@media (min-width: 480px) {
    .exit-popup-input-wrapper {
        flex-direction: row;
    }

    .exit-popup-input {
        flex: 1;
    }

    .exit-popup-submit {
        width: auto;
        white-space: nowrap;
    }
}

@media (max-width: 479px) {
    .exit-popup-content {
        padding: 2rem 1.25rem 1.5rem;
    }

    .exit-popup-title {
        font-size: 1.5rem;
    }

    .exit-popup-subtitle {
        font-size: 1rem;
    }

    .exit-popup-description {
        font-size: 0.875rem;
    }

    .exit-popup-icon {
        width: 64px;
        height: 64px;
    }

    .exit-popup-icon svg {
        width: 32px;
        height: 32px;
    }
}
