/**
 * FMPUEH - Login Page Styles
 * Styles personnalisés pour la page de connexion
 * Couleur principale: Light Green (#1a5f3f)
 */

/* ==========================================================================
   Login Page Layout
   ========================================================================== */

.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #e8f5e9 0%, #c8e6c9 50%, #a5d6a7 100%);
    padding: 20px;
}

.login-container {
    display: flex;
    width: 100%;
    max-width: 1000px;
    background: #fff;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(26, 95, 63, 0.15);
    overflow: hidden;
    min-height: 600px;
}

/* ==========================================================================
   Branding Section (Left Side)
   ========================================================================== */

.login-branding {
    flex: 1;
    background: linear-gradient(135deg, #1a5f3f 0%, #2d8a5e 50%, #3da76d 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
    position: relative;
    overflow: hidden;
}

.login-branding::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
}

.branding-content {
    text-align: center;
    color: #fff;
    position: relative;
    z-index: 1;
}

.branding-logo {
    margin-bottom: 30px;
}

.branding-logo img {
    width: 120px;
    height: 120px;
    object-fit: contain;
    background: #fff;
    padding: 15px;
    border-radius: 50%;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.branding-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 15px;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.branding-subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    line-height: 1.6;
}

/* ==========================================================================
   Form Section (Right Side)
   ========================================================================== */

.login-form-section {
    flex: 1;
    padding: 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.form-header {
    text-align: center;
    margin-bottom: 30px;
}

.form-header h1 {
    font-size: 2rem;
    color: #1a5f3f;
    margin-bottom: 10px;
    font-weight: 700;
}

.form-header p {
    color: #666;
    font-size: 1rem;
}

/* ==========================================================================
   Form Elements
   ========================================================================== */

.login-form-group {
    margin-bottom: 25px;
}

.login-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
    font-size: 0.95rem;
}

.input-wrapper {
    position: relative;
}

.input-wrapper .input-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.1rem;
    z-index: 1;
}

.login-form-control {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #fafafa;
}

.login-form-control:focus {
    outline: none;
    border-color: #1a5f3f;
    background: #fff;
    box-shadow: 0 0 0 4px rgba(26, 95, 63, 0.1);
}

.login-form-control::placeholder {
    color: #999;
}

/* ==========================================================================
   Form Options
   ========================================================================== */

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 10px;
}

.checkbox-wrapper {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.9rem;
    color: #666;
}

.checkbox-wrapper input[type="checkbox"] {
    margin-right: 8px;
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #1a5f3f;
}

.forgot-link {
    color: #1a5f3f;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.3s ease;
}

.forgot-link:hover {
    color: #2d8a5e;
    text-decoration: underline;
}

/* ==========================================================================
   Login Button
   ========================================================================== */

.btn-login {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #1a5f3f 0%, #2d8a5e 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(26, 95, 63, 0.3);
}

.btn-login:active {
    transform: translateY(0);
}

.btn-login:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* ==========================================================================
   Alert Messages
   ========================================================================== */

.login-alert {
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
}

.login-alert-error {
    background: #ffebee;
    color: #c62828;
    border-left: 4px solid #c62828;
}

.login-alert-success {
    background: #e8f5e9;
    color: #2e7d32;
    border-left: 4px solid #2e7d32;
}

/* ==========================================================================
   Back Home Link
   ========================================================================== */

.back-home-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 25px;
    color: #1a5f3f;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.back-home-link:hover {
    color: #2d8a5e;
    transform: translateX(-5px);
}

/* ==========================================================================
   Footer Text
   ========================================================================== */

.footer-text {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.footer-text p {
    color: #999;
    font-size: 0.85rem;
    line-height: 1.6;
    margin: 0;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 768px) {
    .login-container {
        flex-direction: column;
        max-width: 400px;
    }
    
    .login-branding {
        padding: 30px;
        min-height: 200px;
    }
    
    .branding-logo img {
        width: 80px;
        height: 80px;
    }
    
    .branding-title {
        font-size: 1.5rem;
    }
    
    .branding-subtitle {
        font-size: 0.9rem;
    }
    
    .login-form-section {
        padding: 30px;
    }
    
    .form-header h1 {
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .login-wrapper {
        padding: 10px;
    }
    
    .login-container {
        border-radius: 15px;
    }
    
    .login-branding {
        padding: 20px;
    }
    
    .login-form-section {
        padding: 20px;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
    }
}
