* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    min-height: 100vh;
    padding: 20px;

    /* Ajout du fond */
    background-image: url("images/logo_1.jpg"); /* adapte le nom du fichier */
    background-size: 800px auto;        /* adapte l’image à toute la page */
    background-position: center top;   /* centre l’image */
    background-repeat: no-repeat;  /* évite la répétition */
    background-attachment: fixed;  /* optionnel : effet "parallax" */
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.8); /* blanc avec 80% d’opacité */
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.header {
    background: linear-gradient(135deg, 
        rgba(52, 152, 219, 0.65) 0%,   /* bleu clair avec transparence */
        rgba(41, 128, 185, 0.65) 100%  /* bleu foncé avec transparence */
    );
    color: white;
    padding: 30px;
    text-align: center;
}

.header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

.header p {
    font-size: 1.3em;
    opacity: 0.9;
}

.header .annee-academique {
    font-size: 1.5em;
    font-weight: 700;
    margin-bottom: 10px;
}

.form-container {
    padding: 30px;
}

.form-container h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.8em;
}

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

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
}

.liste-filieres {
    max-height: 260px;
    overflow-y: auto;
    border: 2px solid rgba(221, 221, 221, 0.6);
    border-radius: 8px;
    padding: 8px;
}

.liste-filieres .placeholder {
    margin: 8px;
    color: #777;
}

.form-group .filiere-option {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 8px;
    margin-bottom: 0;
    border-radius: 6px;
    cursor: pointer;
}

.form-group .filiere-option:hover {
    background-color: rgba(52, 152, 219, 0.08);
}

.form-group .filiere-option input {
    width: auto;
    margin: 0;
    flex: 0 0 auto;
    /* aligne la case sur la premiere ligne du texte (line-height 1.6 x 16px) */
    margin-top: 6px;
}

.form-group .filiere-option span {
    line-height: 1.6;
}

.filiere-carte {
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(41, 128, 185, 0.35);
    border-left: 4px solid #2980b9;
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 14px;
}

.filiere-carte:last-child {
    margin-bottom: 0;
}

.filiere-carte h4 {
    color: #1f5f8b;
    font-size: 16px;
    padding-bottom: 6px;
    margin-bottom: 4px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid rgba(221, 221, 221, 0.6); /* gris avec transparence */
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;

    background-color: rgba(255, 255, 255, 0.0); /* blanc semi-transparent */
    color: #333; /* texte lisible */
}

.form-group input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-group select {
    width: 100%;
    padding: 12px;
    border: 2px solid rgba(221, 221, 221, 0.6);
    border-radius: 8px;
    font-size: 16px;
    font-family: inherit;
    background-color: #fff;
    color: #333;
    transition: border-color 0.3s ease;
}

.form-group select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.form-group select:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.form-group small {
    color: #666;
    font-size: 0.9em;
}

.btn-primary, .btn-success {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2980b9 0%, #2471a3 100%);
    transform: translateY(-2px);
}

.btn-success {
    background: linear-gradient(135deg, #27ae60 0%, #229954 100%);
    color: white;
}

.btn-success:hover {
    background: linear-gradient(135deg, #229954 0%, #1e8449 100%);
    transform: translateY(-2px);
}

.student-info {
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    border-left: 4px solid #3498db;
}

.student-info h3 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.student-info p {
    margin-bottom: 8px;
    color: #555;
}

.filiere-infos {
    padding: 20px;
    border-radius: 8px;
    margin-top: 25px;
    background: rgba(232, 244, 252, 0.8);
    border-left: 4px solid #2980b9;
}

.filiere-infos h3 {
    color: #2c3e50;
    margin-bottom: 15px;
}

.filiere-infos dt {
    font-weight: 600;
    color: #2c3e50;
    margin-top: 10px;
}

.filiere-infos dd {
    margin-left: 0;
    margin-bottom: 5px;
    color: #555;
}

.lien-btn {
    display: block;
    text-align: center;
    text-decoration: none;
    margin-top: 25px;
}

/* Lien recu : le padding des boutons ne vaut que sur un element en flux,
   sinon la boite deborde de sa ligne et remonte sur le texte du dessus. */
.actions-recu {
    margin-top: 18px;
}

.actions-recu .btn-recu {
    display: block;
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    color: white;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    transition: all 0.3s ease;
}

.actions-recu .btn-recu:hover {
    background: linear-gradient(135deg, #2980b9 0%, #2471a3 100%);
    transform: translateY(-2px);
}

.btn-primary:disabled,
.btn-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

#btnRecap {
    margin-top: 18px;
}

.btn-secondary {
    width: 100%;
    padding: 15px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    background: linear-gradient(135deg, #f39c12 0%, #d58512 100%);
    color: white;
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #d58512 0%, #b9770e 100%);
    transform: translateY(-2px);
}

.actions-form {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.actions-form button {
    flex: 1;
}

.succes-container {
    margin-top: 25px;
    padding: 20px;
    border-radius: 8px;
    background: rgba(39, 174, 96, 0.12);
    border-left: 4px solid #27ae60;
}

.succes-container h3 {
    color: #1e8449;
    margin-bottom: 8px;
}

.succes-container p {
    color: #555;
}

.form-group small.alerte {
    display: block;
    margin-top: 8px;
    padding: 10px 12px;
    border-radius: 6px;
    background: rgba(243, 156, 18, 0.15);
    border-left: 4px solid #f39c12;
    color: #9a6408;
}

.suspendu-container {
    text-align: center;
    padding: 30px 20px;
}

.suspendu-container h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.6em;
}

.suspendu-container p {
    color: #555;
    margin-bottom: 12px;
}

.warning-bandeau {
    margin: 20px 0;
    padding: 14px 18px;
    border-radius: 8px;
    background: #fff3cd;
    border-left: 4px solid #f39c12;
    color: #7a4b00;
    font-weight: 600;
}

.info-bandeau {
    margin-top: 20px;
    padding: 14px 18px;
    border-radius: 8px;
    background: rgba(52, 152, 219, 0.12);
    border-left: 4px solid #3498db;
    color: #2c3e50;
}

.error-container {
    background: #ffe6e6;
    border: 1px solid #ffcccc;
    border-radius: 8px;
    padding: 20px;
    margin: 20px;
    color: #d63031;
}

.error-container h3 {
    margin-bottom: 10px;
}

.error-container ul {
    list-style: none;
}

.error-container li {
    padding: 5px 0;
}

.instructions {
    background: #e8f4fc;
    padding: 25px;
    border-top: 1px solid #ddd;
}

.instructions {
    background: rgba(232, 244, 252, 0.6); /* bleu très clair semi-transparent */
    padding: 25px;
    border-top: 1px solid rgba(0, 0, 0, 0.1); /* un peu de transparence aussi */
}

.instructions ol {
    margin-left: 20px;
}

.instructions li {
    margin-bottom: 8px;
    color: #555;
}

@media (max-width: 600px) {
    .container {
        margin: 10px;
        border-radius: 10px;
    }
    
    .header {
        padding: 20px;
    }
    
    .header h1 {
        font-size: 2em;
    }
    
    .form-container {
        padding: 20px;
    }
}
.actions-form .lien-btn {
    flex: 1;
    margin-top: 0;
}
