/**
 * ============================================
 * NEWSLETTER GATE V2 - Styles
 * Design moderne et responsive
 * ============================================
 */

/* Modale principale */
.newsletter-modal-v2 {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.newsletter-modal-v2.active {
    opacity: 1;
}

/* Overlay (fond sombre) */
.newsletter-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(5px);
}

/* Contenu de la modale */
.newsletter-modal-content {
    position: relative;
    background: white;
    border-radius: 20px;
    max-width: 550px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.newsletter-modal-v2.active .newsletter-modal-content {
    transform: translateY(0);
}

/* Header */
.newsletter-modal-header {
    background: linear-gradient(135deg, #7c3aed 0%, #3b82f6 100%);
    color: white;
    padding: 35px 30px;
    border-radius: 20px 20px 0 0;
    text-align: center;
    position: relative;
}

.newsletter-modal-close {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    color: white;
}

.newsletter-modal-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.newsletter-modal-icon {
    font-size: 48px;
    margin-bottom: 15px;
    animation: bounce 2s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.newsletter-modal-header h2 {
    margin: 0 0 10px 0;
    font-size: 24px;
    font-weight: 700;
    color: white;
}

.newsletter-modal-header p {
    margin: 0;
    font-size: 15px;
    opacity: 0.95;
    color: white;
}

/* Body */
.newsletter-modal-body {
    padding: 30px;
}

/* Bénéfices */
.newsletter-benefits {
    margin-bottom: 25px;
}

.newsletter-benefits h3 {
    font-size: 18px;
    color: #1e293b;
    margin: 0 0 15px 0;
    font-weight: 600;
}

.newsletter-benefits ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.newsletter-benefits li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 12px;
    font-size: 14px;
    color: #475569;
    line-height: 1.5;
}

.newsletter-benefits li svg {
    flex-shrink: 0;
    margin-top: 2px;
}

/* Formulaire */
.newsletter-form {
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 8px;
}

.form-group input[type="text"],
.form-group input[type="email"] {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 15px;
    font-family: inherit;
    transition: all 0.2s ease;
    background: #f8fafc;
}

.form-group input[type="text"]:focus,
.form-group input[type="email"]:focus {
    outline: none;
    border-color: #7c3aed;
    background: white;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.1);
}

.checkbox-group {
    margin-bottom: 20px;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    color: #475569;
    cursor: pointer;
    line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
    margin-top: 3px;
    cursor: pointer;
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.checkbox-label a {
    color: #7c3aed;
    text-decoration: underline;
}

.checkbox-label a:hover {
    color: #6d28d9;
}

/* Bouton de soumission */
.newsletter-submit-btn {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, #7c3aed 0%, #3b82f6 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.3);
}

.newsletter-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(124, 58, 237, 0.4);
}

.newsletter-submit-btn:active {
    transform: translateY(0);
}

/* Message d'erreur */
.newsletter-error {
    display: none;
    padding: 12px 16px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    color: #dc2626;
    font-size: 14px;
    margin-bottom: 15px;
}

/* Message de succès */
.newsletter-success {
    text-align: center;
    padding: 20px;
}

.success-icon {
    font-size: 64px;
    margin-bottom: 20px;
    animation: scaleIn 0.5s ease;
}

@keyframes scaleIn {
    0% { transform: scale(0); }
    50% { transform: scale(1.2); }
    100% { transform: scale(1); }
}

.newsletter-success h3 {
    font-size: 22px;
    color: #10b981;
    margin: 0 0 10px 0;
    font-weight: 700;
}

.newsletter-success p {
    font-size: 15px;
    color: #475569;
    margin: 0 0 10px 0;
}

.success-note {
    font-size: 14px !important;
    color: #64748b !important;
}

/* Réassurance */
.newsletter-reassurance {
    text-align: center;
    padding: 15px 20px;
    background: #f8fafc;
    border-radius: 10px;
    margin-top: 20px;
}

.newsletter-reassurance p {
    font-size: 12px;
    color: #64748b;
    margin: 0;
    line-height: 1.6;
}

/* Badge "Accès déverrouillé" */
.unlocked-badge {
    position: fixed;
    top: 100px;
    right: 20px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 12px 20px;
    border-radius: 25px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
    z-index: 99998;
    animation: slideInRight 0.5s ease;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.unlocked-badge.hiding {
    animation: slideOutRight 0.3s ease forwards;
}

@keyframes slideOutRight {
    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Responsive Mobile */
@media (max-width: 768px) {
    .newsletter-modal-content {
        width: 95%;
        max-height: 95vh;
    }

    .newsletter-modal-header {
        padding: 25px 20px;
    }

    .newsletter-modal-header h2 {
        font-size: 20px;
    }

    .newsletter-modal-header p {
        font-size: 14px;
    }

    .newsletter-modal-body {
        padding: 20px;
    }

    .newsletter-benefits h3 {
        font-size: 16px;
    }

    .newsletter-benefits li {
        font-size: 13px;
    }

    .newsletter-submit-btn {
        font-size: 15px;
        padding: 12px 20px;
    }

    .unlocked-badge {
        top: 70px;
        right: 10px;
        font-size: 13px;
        padding: 10px 16px;
    }
}

/* Smooth scrollbar pour le contenu modal */
.newsletter-modal-content::-webkit-scrollbar {
    width: 8px;
}

.newsletter-modal-content::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 10px;
}

.newsletter-modal-content::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 10px;
}

.newsletter-modal-content::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}
