/* ===== VARIABLES ET RESET ===== */
:root {
    --primary-color: #0056b3;
    --primary-dark: #003d7a;
    --accent-color: #ffc107;
    --text-dark: #1a1a1a;
    --text-light: #ffffff;
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --radius-sm: 6px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
html, body {
   
    overflow-x: hidden;
    
}

body {
    font-family: 'Inter', sans-serif;
    min-height: 100vh;
    background: #d2dff1;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 24px;
    position: relative;
    overflow-x: hidden;
    overflow-y: hidden;
}

/* Effets de fond */
body::before {
    content: '';
    position: absolute;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(102, 126, 234, 0.15), transparent 70%);
    top: -300px;
    right: -300px;
    border-radius: 50%;
    animation: float 8s ease-in-out infinite;
}

body::after {
    content: '';
    position: absolute;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(118, 75, 162, 0.1), transparent 70%);
    bottom: -250px;
    left: -250px;
    border-radius: 50%;
    animation: float 12s ease-in-out infinite reverse;
}

@keyframes float {
    0%, 100% { transform: translateY(0) translateX(0) scale(1); }
    50% { transform: translateY(-20px) translateX(20px) scale(1.02); }
}

/* ===== CONTENEUR PRINCIPAL ===== */
.login-container {
    width: 100%;
    max-width: 1200px;
    display: flex;
    background: rgba(255, 255, 255, 0.08);
    backdrop-filter: blur(20px);
    border-radius: var(--radius-xl);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    border: 1px solid rgba(255, 255, 255, 0.12);
    position: relative;
    z-index: 1;
}

/* ===== PANEL GAUCHE ===== */
.login-left {
    flex: 1;
    background: linear-gradient(135deg, 
        rgba(0, 86, 179, 0.92) 0%, 
        rgba(156, 191, 226, 0.88) 100%),
        url('/static/images/docupilot_on_mac.webp');
    background-size: cover;
    background-position: center;
    background-blend-mode: multiply;
    padding: 64px 56px;
    color: var(--text-light);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: relative;
    min-height: 700px;
}

/* Logo Section */
.logo-section {
    margin-bottom: 64px;
    
}

.logo-wrapper {
    display: flex;
    align-items: center;
    
    
}

.logo-image {
    width: 90px;
    height: 90px;
    flex-shrink: 0;
    border-radius: 50%;
}

.logo-text h1 {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 4px;
    letter-spacing: -0.5px;
}

.logo-text p {
    font-size: 14px;
    opacity: 0.9;
    font-weight: 300;
    letter-spacing: 0.3px;
}

/* Features List */
.features-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 32px;
    margin-top: auto;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    background: rgba(255, 255, 255, 0.08);
    padding: 24px;
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    transition: var(--transition);
    cursor: pointer;
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.12);
    transform: translateX(8px);
    border-color: rgba(255, 255, 255, 0.2);
}

.feature-icon {
    width: 56px;
    height: 56px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    padding: 12px;
}

.feature-svg {
    width: 28px;
    height: 28px;
    color: var(--text-light);
}

.feature-content h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
    letter-spacing: -0.3px;
}

.feature-content p {
    font-size: 14px;
    opacity: 0.85;
    line-height: 1.6;
    font-weight: 300;
}

/* ===== PANEL DROIT ===== */
.login-right {
    flex: 1;
    padding: 64px 56px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
}

/* Login Header */
.login-header {
    text-align: center;
    margin-bottom: 48px;
}

.login-header h2 {
    font-size: 36px;
    color: var(--text-dark);
    margin-bottom: 12px;
    font-weight: 700;
    letter-spacing: -0.8px;
}

.subtitle {
    color: var(--gray-500);
    font-size: 16px;
    font-weight: 400;
    letter-spacing: 0.2px;
}

/* Messages */
.message {
    padding: 18px 20px;
    border-radius: var(--radius-md);
    margin-bottom: 32px;
    display: flex;
    align-items: center;
    gap: 14px;
    font-size: 15px;
    font-weight: 500;
    animation: slideIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1.5;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.success {
    background: #f0fdf4;
    color: #166534;
    border: 1px solid #bbf7d0;
}

.message.error {
    background: #fef2f2;
    color: #dc2626;
    border: 1px solid #fecaca;
}

.message.warning {
    background: #fffbeb;
    color: #92400e;
    border: 1px solid #fde68a;
}

.message-icon {
    width: 22px;
    height: 22px;
    flex-shrink: 0;
}

.close-message {
    margin-left: auto;
    background: none;
    border: none;
    color: inherit;
    cursor: pointer;
    opacity: 0.6;
    transition: var(--transition);
    padding: 6px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.close-message svg {
    width: 18px;
    height: 18px;
}

.close-message:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.05);
}

/* Formulaire */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
    flex: 1;
}

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

.form-group label {
    display: block;
    font-size: 14px;
    color: var(--gray-700);
    margin-bottom: 10px;
    font-weight: 500;
    letter-spacing: 0.2px;
}

.input-wrapper {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gray-400);
    width: 20px;
    height: 20px;
    pointer-events: none;
}

.form-group input {
    width: 100%;
    padding: 18px 20px 18px 52px;
    border: 1.5px solid var(--gray-200);
    border-radius: var(--radius-md);
    font-family: 'Inter', sans-serif;
    font-size: 15px;
    transition: var(--transition);
    background: white;
    color: var(--text-dark);
    letter-spacing: 0.2px;
}

.form-group input::placeholder {
    color: var(--gray-400);
}

.form-group input:hover {
    border-color: var(--gray-300);
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(0, 86, 179, 0.1);
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 8px;
}

.forgot-password {
    color: var(--primary-color);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.key-icon {
    width: 16px;
    height: 16px;
}

.forgot-password:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Login Button */
.btn-login {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    margin-top: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    letter-spacing: 0.2px;
}

.btn-icon {
    width: 20px;
    height: 20px;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 86, 179, 0.25);
}

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

/* Divider */
.divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 32px 0;
    color: var(--gray-400);
    font-size: 14px;
    font-weight: 400;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid var(--gray-200);
}

.divider span {
    padding: 0 20px;
    background: white;
}

/* Google Button */
.btn-google {
    width: 100%;
    padding: 18px;
    background: white;
    border: 1.5px solid var(--gray-200);
    border-radius: var(--radius-md);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    color: var(--text-dark);
    text-decoration: none;
    letter-spacing: 0.2px;
}

.google-icon {
    width: 22px;
    height: 22px;
}

.btn-google:hover {
    background: var(--gray-50);
    border-color: var(--gray-300);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* Signup Section */
.signup-section {
    text-align: center;
    margin-top: auto;
    padding-top: 32px;
    border-top: 1px solid var(--gray-200);
    color: var(--gray-600);
    font-size: 14px;
    line-height: 1.5;
}

.signup-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
}

.signup-link:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Footer Note */
.footer-note {
    margin-top: 48px;
    text-align: center;
    color: var(--gray-500);
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding-top: 24px;
    border-top: 1px solid var(--gray-200);
}

.shield-icon {
    width: 16px;
    height: 16px;
    color: var(--gray-400);
}

/* ===== MODAL ===== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    padding: 24px;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: white;
    border-radius: var(--radius-lg);
    max-width: 480px;
    width: 100%;
    position: relative;
    animation: modalSlide 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

@keyframes modalSlide {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.close-btn {
    position: absolute;
    right: 10px;
    top: 47px;
    background: var(--gray-100);
    border: none;
    width: auto;
    height: auto;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.close-btn svg {
    width: 20px;
    height: 20px;
    color: var(--gray-600);
}

.close-btn:hover {
    background: var(--gray-200);
}

.modal-header {
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    padding: 40px 40px 24px;
    color: white;
    display: flex;
    align-items: center;
    gap: 16px;
}

.modal-icon {
    width: 32px;
    height: 32px;
    flex-shrink: 0;
}

.modal-header h3 {
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -0.4px;
}

.modal-body {
    padding: 40px;
}

.modal-body p {
    color: var(--gray-600);
    margin-bottom: 32px;
    line-height: 1.6;
    font-size: 15px;
}

.btn-submit {
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, var(--primary-color), var(--primary-dark));
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 8px;
}

.send-icon {
    width: 20px;
    height: 20px;
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 86, 179, 0.25);
}

/* ===== ANIMATIONS SUPPLÉMENTAIRES ===== */
@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.feature-item:hover .feature-svg {
    animation: pulse 1s ease-in-out;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    html, body {
   
    overflow-x: hidden;
    
}

    .login-left{
        display: none;
    }
    .login-container {
        max-width: 900px;
    }
    
    .login-left,
    .login-right {
        padding: 48px 40px;
    }
    
    .logo-text h1 {
        font-size: 28px;
    }
    
    .login-header h2 {
        font-size: 32px;
    }
}

@media (max-width: 900px) {
    .login-container {
        flex-direction: column;
        max-width: 500px;
    }

    .login-left {
        padding: 40px 32px;
        min-height: 400px;
    }

    .logo-text h1 {
        font-size: 24px;
    }

    .features-list {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 20px;
        margin-top: 40px;
    }
    
    .feature-item {
        flex: 1;
        min-width: 200px;
    }
    
    .feature-item:hover {
        transform: translateY(-4px);
    }

    .login-right {
        padding: 40px 32px;
    }
    
    .footer-note {
        margin-top: 32px;
    }
}

@media (max-width: 576px) {
    body {
        padding: 16px;
    }

    .login-container {
        border-radius: var(--radius-lg);
    }

    .login-left {
        padding: 32px 24px;
        min-height: 360px;
    }

    .logo-wrapper {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }
    
    .logo-text h1 {
        font-size: 24px;
    }
    
    .logo-text p {
        font-size: 13px;
    }

    .feature-item {
        padding: 20px;
        gap: 16px;
    }
    
    .features-list {
        flex-direction: column;
    }

    .feature-icon {
        width: 48px;
        height: 48px;
    }

    .login-right {
        padding: 32px 24px;
    }

    .login-header h2 {
        font-size: 28px;
    }
    
    .subtitle {
        font-size: 15px;
    }

    .modal {
        padding: 16px;
    }
    
    .modal-content {
        max-width: 100%;
    }
    
    .modal-header {
        padding: 32px 24px 20px;
    }
    
    .modal-body {
        padding: 32px 24px;
    }
    
    .btn-google span {
        display: none;
    }
    
    .btn-google {
        padding: 18px;
        justify-content: center;
    }
    
    .google-icon {
        margin-right: 0;
    }
}