/* Login page styles - Theme sombre épuré */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #0a0a0a;
    color: #ffffff;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    justify-content: center;
}

/* Header */
.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.logo {
    width: auto;
    height: 80px;
    margin-bottom: 10px;
    filter: drop-shadow(0 4px 8px rgba(255, 255, 255, 0.1));
}

.login-header h1 {
    font-size: 2.5em;
    font-weight: 300;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #ffffff, #cccccc);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.tagline {
    font-size: 0.9em;
    color: #888;
    font-weight: 300;
}

/* Auth Container */
.auth-container {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 32px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.auth-form {
    width: 100%;
}

.auth-form h2 {
    font-size: 1.5em;
    font-weight: 400;
    margin-bottom: 8px;
    text-align: center;
    color: #ffffff;
}

.form-description {
    color: #aaa;
    font-size: 0.9em;
    text-align: center;
    margin-bottom: 24px;
    font-weight: 300;
}

/* Input Groups */
.input-group {
    margin-bottom: 20px;
}

.auth-input {
    width: 100%;
    padding: 16px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: #ffffff;
    font-size: 16px;
    transition: all 0.3s ease;
    font-weight: 300;
}

.auth-input:focus {
    outline: none;
    border-color: rgba(255, 87, 51, 0.5);
    background: rgba(255, 255, 255, 0.05);
    box-shadow: 0 0 0 2px rgba(255, 87, 51, 0.2);
}

.auth-input::placeholder {
    color: #666;
    font-weight: 300;
}

/* Buttons */
.auth-button {
    width: 100%;
    padding: 16px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 16px;
}

.auth-button.primary {
    background: linear-gradient(135deg, #333, #555);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.auth-button.primary:hover {
    background: linear-gradient(135deg, #444, #666);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

.auth-button.primary:active {
    transform: translateY(0);
}

.auth-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* Error Messages */
.error-message {
    color: #ff6b6b;
    font-size: 0.9em;
    margin-bottom: 16px;
    padding: 8px 0;
    display: none;
    text-align: center;
    font-weight: 300;
}

/* Form Switch */
.form-switch {
    text-align: center;
    color: #aaa;
    font-size: 0.9em;
    margin-top: 16px;
    font-weight: 300;
}

.switch-link {
    color: #ffffff;
    text-decoration: none;
    font-weight: 400;
    transition: color 0.3s ease;
}

.switch-link:hover {
    color: #ccc;
    text-decoration: underline;
}

/* Footer */
.login-footer {
    text-align: center;
    margin-top: 40px;
    color: #666;
    font-size: 0.8em;
    font-weight: 300;
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.footer-link {
    color: #666;
    text-decoration: none;
    font-size: 0.85em;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.footer-link:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.05);
}

/* Success Message */
.success-message {
    position: fixed;
    top: 20px;
    right: 20px;
    background: linear-gradient(135deg, #51cf66, #37b24d);
    color: white;
    padding: 12px 20px;
    border-radius: 8px;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive Design */
@media (max-width: 480px) {
    .login-container {
        padding: 16px;
    }
    
    .auth-container {
        padding: 24px;
    }
    
    .login-header h1 {
        font-size: 2em;
    }
    
    .auth-input,
    .auth-button {
        padding: 14px;
        font-size: 16px;
    }
}

/* Animation pour les transitions de formulaires */
.auth-form {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading state */
.auth-button.loading {
    position: relative;
    color: transparent;
}

.auth-button.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top: 2px solid #ffffff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Focus states pour les boutons uniquement */
.auth-button:focus {
    outline: 2px solid rgba(255, 87, 51, 0.3);
    outline-offset: 2px;
}

/* Hover states pour les inputs */
.auth-input:hover {
    border-color: rgba(255, 87, 51, 0.3);
    transition: border-color 0.2s ease;
}

/* Amélioration des gradients */
.auth-button.primary {
    background: linear-gradient(135deg, #2a2a2a, #404040);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.auth-button.primary:hover {
    background: linear-gradient(135deg, #333, #4a4a4a);
    border-color: rgba(255, 255, 255, 0.25);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}
