/* ===========================================
   FICHIER : style.css
   DESCRIPTION : Styles communs pour toutes les pages
   =========================================== */

/* 1. RESET & VARIABLES GLOBALES */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: "Poppins", sans-serif;
}

:root {
    --primary-color: #4a6fa5;
    --secondary-color: #166088;
    --accent-color: #ff6b6b;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --success-color: #2ed573;
    --error-color: #ff4757;
    --warning-color: #ffa502;
    --spacing-xs: 5px;
    --spacing-sm: 10px;
    --spacing-md: 20px;
    --spacing-lg: 30px;
    --spacing-xl: 50px;
    --border-radius-sm: 5px;
    --border-radius-md: 15px;
    --border-radius-lg: 25px;
    --shadow-light: 0 2px 10px rgba(0,0,0,0.1);
    --shadow-medium: 0 4px 20px rgba(0,0,0,0.15);
    --shadow-heavy: 0 8px 30px rgba(0,0,0,0.2);
}

/* 2. STYLES GÉNÉRAUX DU BODY */
body {
    height: 100vh;
    background-image: url('asset/bac8.jpg');
    display: flex;
    justify-content: center;
    align-items: center;
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    min-height: 100vh;
    overflow-x: hidden;
    padding: 20px;
}

/* 3. SECTION PRINCIPALE */
section {
    background-color: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(20px);
    padding: var(--spacing-lg);
    width: 100%;
    max-width: 450px;
    border-radius: var(--border-radius-lg);
    margin: var(--spacing-md);
}

section h1 {
    font-size: 30px;
    text-align: center;
    color: white;
    margin-bottom: var(--spacing-lg);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

/* 4. CHAMPS DE FORMULAIRE */
.input-box {
    width: 100%;
    position: relative;
    margin-bottom: var(--spacing-lg);
}

.input-box input, .input-box select {
    width: 100%;
    padding: 15px;
    border-radius: var(--border-radius-lg);
    outline: none;
    background-color: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding-right: 40px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.input-box input::placeholder, .input-box select option {
    color: rgba(255, 255, 255, 0.7);
}

.input-box input:focus, .input-box select:focus {
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

.input-box i {
    position: absolute;
    transform: translateY(-50%);
    right: 20px;
    top: 50%;
    color: white;
    pointer-events: none;
}

/* 5. CHECKBOX */
.remember-forgot {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: white;
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
}

.remember-forgot a {
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
}

.remember-forgot a:hover {
    text-decoration: underline;
    color: var(--accent-color);
}

.remember-forgot label {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    cursor: pointer;
}

.remember-forgot input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: var(--primary-color);
}

/* 6. BOUTONS */
.login-btn {
    width: 100%;
    padding: 15px;
    border-radius: var(--border-radius-lg);
    outline: none;
    border: 0;
    font-weight: bold;
    font-size: 16px;
    border: 2px solid transparent;
    transition: all 0.5s ease;
    cursor: pointer;
    background-color: white;
    color: #333;
    box-shadow: var(--shadow-light);
    text-decoration: none;
    display: block;
    text-align: center;
}

.login-btn:hover {
    background-color: transparent;
    border: 2px solid rgba(255, 255, 255, 0.2);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.back-btn {
    width: 100%;
    padding: 15px;
    border-radius: var(--border-radius-lg);
    outline: none;
    border: 2px solid rgba(255, 255, 255, 0.3);
    font-weight: bold;
    font-size: 16px;
    transition: all 0.3s ease;
    cursor: pointer;
    background-color: transparent;
    color: white;
    text-decoration: none;
    display: block;
    text-align: center;
    margin-top: 15px;
}

.back-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* 7. LIENS */
.register-link {
    text-align: center;
    margin-top: var(--spacing-lg);
    color: #fff;
    font-size: 14px;
}

.register-link a {
    color: white;
    text-decoration: none;
    transition: color 0.5s;
    font-weight: bold;
}

.register-link a:hover {
    text-decoration: underline;
    color: var(--accent-color);
}

/* 8. PROGRESSION */
.progress-container {
    margin-bottom: 25px;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.progress-step {
    flex: 1;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    position: relative;
}

.progress-step.active {
    color: white;
    font-weight: bold;
}

.progress-step.completed {
    color: var(--success-color);
}

.progress-bar {
    height: 4px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 5px;
}

.progress-fill {
    height: 100%;
    background-color: white;
    width: 33.33%;
    transition: width 0.3s ease;
}

/* 9. MESSAGES */
#message {
    display: none;
    position: fixed;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 15px 25px;
    border-radius: 10px;
    color: white;
    font-weight: bold;
    z-index: 1000;
    text-align: center;
    min-width: 300px;
    max-width: 90%;
}

.message-success {
    background-color: var(--success-color);
    border: 2px solid var(--success-color);
}

.message-error {
    background-color: var(--error-color);
    border: 2px solid var(--error-color);
}

/* 10. RESPONSIVE */
@media (max-width: 768px) {
    section {
        width: 90%;
        padding: var(--spacing-md);
    }
    
    section h1 {
        font-size: 26px;
    }
    
    .input-box input, .input-box select {
        padding: 12px;
    }
    
    .progress-step {
        font-size: 12px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
        align-items: flex-start;
        padding-top: 40px;
    }
    
    section {
        width: 100%;
        padding: 15px;
        border-radius: var(--border-radius-md);
        margin: 0;
    }
    
    section h1 {
        font-size: 22px;
        margin-bottom: var(--spacing-md);
    }
    
    .input-box {
        margin-bottom: var(--spacing-md);
    }
    
    .input-box input, .input-box select {
        padding: 12px;
        font-size: 14px;
    }
    
    .login-btn, .back-btn {
        padding: 12px;
        font-size: 14px;
    }
    
    .register-link {
        font-size: 12px;
    }
    
    #message {
        min-width: 90%;
        font-size: 14px;
        padding: 10px 15px;
    }
}