:root {
  --teal: #144161;
  --teal-clair: #1d5a85;
  --corail: #EC5A64;
  --ardoise: #617CA9;
  --fond: #f5f6f8;
  --carte: #ffffff;
  --texte: #1c2733;
  --texte-doux: #5b6773;
  --bord: #dde2e8;
  --vert: #1f7a4d;
  --vert-fond: #e3f3ea;
  --orange: #a35a00;
  --orange-fond: #fdf0dc;
  --rouge: #b42330;
  --rouge-fond: #fde8ea;
  --bleu-fond: #e7edf6;
  --gris-fond: #eef0f3;
  --rayon: 10px;
  --ombre: 0 1px 2px rgba(20, 65, 97, .06), 0 4px 16px rgba(20, 65, 97, .06);
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 15px;
  line-height: 1.5;
  color: var(--texte);
  background: var(--fond);
}
a { color: var(--teal-clair); }
h1, h2, h3 { line-height: 1.25; margin: 0 0 .6em; color: var(--teal); }
h1 { font-size: 1.6rem; }
h2 { font-size: 1.2rem; }
h3 { font-size: 1rem; }
p { margin: 0 0 .8em; }
.doux { color: var(--texte-doux); }
.petit { font-size: .87rem; }
.chargement { padding: 3rem; text-align: center; color: var(--texte-doux); }

/* En-tête */
.entete {
  background: var(--teal);
  color: #fff;
  position: sticky; top: 0; z-index: 10;
}
.entete-interieur {
  max-width: 1180px; margin: 0 auto; padding: .7rem 16px;
  display: flex; align-items: center; gap: 1rem; flex-wrap: wrap;
}
.marque { display: flex; align-items: center; gap: .6rem; color: #fff; text-decoration: none; font-weight: 700; }
.marque-pastille { width: 26px; height: 26px; border-radius: 7px; background: #fff; display: grid; place-items: center; }
.marque-pastille::after { content: ""; width: 12px; height: 12px; border-radius: 50%; background: var(--corail); }
.marque small { display: block; font-weight: 400; opacity: .75; font-size: .75rem; }
.nav { display: flex; gap: .25rem; flex-wrap: wrap; margin-left: auto; align-items: center; }
.nav a, .nav button {
  color: #fff; text-decoration: none; padding: .4rem .7rem; border-radius: 7px;
  background: none; border: 0; font: inherit; cursor: pointer; opacity: .88;
}
.nav a:hover, .nav button:hover { background: rgba(255,255,255,.1); opacity: 1; }
.nav a.actif { background: rgba(255,255,255,.16); opacity: 1; }
.nav a.cloche { position: relative; padding-right: 1.4rem; }
.cloche .compte {
  position: absolute; top: 0; right: 0; background: var(--corail); color: #fff;
  border-radius: 999px; font-size: .7rem; min-width: 17px; height: 17px; line-height: 17px; text-align: center; padding: 0 4px;
}

.contenu { max-width: 1180px; margin: 0 auto; padding: 1.5rem 16px 4rem; }

/* Cartes et grilles */
.carte { background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); padding: 1.25rem; box-shadow: var(--ombre); margin-bottom: 1.25rem; }
.grille { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.titre-page { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1rem; }
.titre-page h1 { margin: 0; }

/* Page de connexion */
.auth { max-width: 440px; margin: 3rem auto; }
.auth .carte { padding: 2rem; }
.auth-logo { display: flex; align-items: center; gap: .7rem; margin-bottom: 1.5rem; }
.auth-logo .marque-pastille { background: var(--teal); width: 38px; height: 38px; border-radius: 10px; }
.auth-logo .marque-pastille::after { width: 16px; height: 16px; }
.auth-logo strong { display: block; color: var(--teal); font-size: 1.1rem; }
.liens-auth { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-top: 1rem; font-size: .9rem; }

/* Formulaires */
label { display: block; font-weight: 600; margin-bottom: .3rem; font-size: .92rem; }
.champ { margin-bottom: 1rem; }
.aide { font-size: .84rem; color: var(--texte-doux); margin-top: .3rem; }
input[type=text], input[type=email], input[type=password], input[type=date], input[type=number], select, textarea {
  width: 100%; padding: .6rem .7rem; font: inherit; color: inherit;
  border: 1px solid var(--bord); border-radius: 8px; background: #fff;
}
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible {
  outline: 2px solid var(--ardoise); outline-offset: 1px; border-color: var(--ardoise);
}
textarea { min-height: 96px; resize: vertical; }
.ligne { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.choix { display: flex; gap: .6rem; flex-wrap: wrap; }
.choix label {
  font-weight: 500; display: flex; align-items: center; gap: .5rem; margin: 0;
  border: 1px solid var(--bord); border-radius: 8px; padding: .55rem .8rem; cursor: pointer; background: #fff;
}
.choix label:has(input:checked) { border-color: var(--teal); background: var(--bleu-fond); }
.choix input { accent-color: var(--teal); }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem;
  padding: .6rem 1.1rem; border-radius: 8px; border: 1px solid transparent;
  font: inherit; font-weight: 600; cursor: pointer; text-decoration: none;
  background: var(--teal); color: #fff;
}
.btn:hover { background: var(--teal-clair); }
.btn:disabled { opacity: .55; cursor: wait; }
.btn.secondaire { background: #fff; color: var(--teal); border-color: var(--bord); }
.btn.secondaire:hover { border-color: var(--teal); }
.btn.corail { background: var(--corail); }
.btn.vert { background: var(--vert); }
.btn.rouge { background: var(--rouge); }
.btn.petit { padding: .35rem .7rem; font-size: .85rem; }
.btn.bloc { width: 100%; }
.actions { display: flex; gap: .6rem; flex-wrap: wrap; align-items: center; }

/* Messages */
.alerte { border-radius: 8px; padding: .8rem 1rem; margin-bottom: 1rem; border: 1px solid; }
.alerte.info { background: var(--bleu-fond); border-color: #c9d6ea; }
.alerte.ok { background: var(--vert-fond); border-color: #b9dfca; color: #134b30; }
.alerte.attention { background: var(--orange-fond); border-color: #f2d3a3; color: #6b3c00; }
.alerte.erreur { background: var(--rouge-fond); border-color: #f4bcc2; color: #7d1720; }
.alerte > strong:first-child { display: block; margin-bottom: .15rem; }

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%) translateY(20px);
  background: var(--texte); color: #fff; padding: .7rem 1.1rem; border-radius: 8px;
  opacity: 0; pointer-events: none; transition: .25s; max-width: calc(100% - 32px); z-index: 50;
}
.toast.visible { opacity: 1; transform: translateX(-50%); }
.toast.erreur { background: var(--rouge); }

/* Compteur de jokers */
.compteur { display: flex; gap: 1.5rem; align-items: center; flex-wrap: wrap; }
.jauge { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; width: 100%; max-width: 360px; }
.jauge span { height: 22px; border-radius: 4px; background: var(--gris-fond); border: 1px solid var(--bord); }
.jauge span.entreprise { background: var(--ardoise); border-color: var(--ardoise); }
.jauge span.personnel { background: var(--teal); border-color: var(--teal); }
.jauge span.attente { background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.35) 0 4px, transparent 4px 8px); }
.chiffre { font-size: 2.2rem; font-weight: 700; color: var(--teal); line-height: 1; }
.chiffre small { font-size: 1rem; color: var(--texte-doux); font-weight: 500; }
.legende { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .85rem; color: var(--texte-doux); margin-top: .6rem; }
.legende i { display: inline-block; width: 11px; height: 11px; border-radius: 3px; margin-right: .3rem; vertical-align: -1px; }
.stat { background: var(--fond); border-radius: 8px; padding: .7rem .9rem; }
.stat b { display: block; font-size: 1.3rem; color: var(--teal); }

/* Badges */
.badge { display: inline-block; padding: .15rem .55rem; border-radius: 999px; font-size: .78rem; font-weight: 600; white-space: nowrap; }
.badge.en_attente { background: var(--orange-fond); color: var(--orange); }
.badge.info_demandee { background: #fbe4f0; color: #8a1f5c; }
.badge.validee { background: var(--vert-fond); color: var(--vert); }
.badge.refusee { background: var(--rouge-fond); color: var(--rouge); }
.badge.annulee { background: var(--gris-fond); color: var(--texte-doux); }
.badge.personnel { background: #ece5fa; color: #5a3d99; }   /* lavande */
.badge.entreprise { background: #dcecfb; color: #1f5a8f; }   /* bleu ciel */
.badge.depasse { background: var(--rouge-fond); color: var(--rouge); }
.badge.proche { background: var(--orange-fond); color: var(--orange); }

/* Tableaux */
.tableau-conteneur { overflow-x: auto; border: 1px solid var(--bord); border-radius: var(--rayon); background: #fff; }
table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th, td { text-align: left; padding: .6rem .75rem; border-bottom: 1px solid var(--bord); vertical-align: top; }
th { background: #f8f9fb; font-weight: 600; color: var(--texte-doux); font-size: .82rem; text-transform: uppercase; letter-spacing: .03em; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
tbody tr.cliquable { cursor: pointer; }
tbody tr.cliquable:hover { background: #f8fafc; }
td.nombre, th.nombre { text-align: right; font-variant-numeric: tabular-nums; }
.vide { padding: 2rem; text-align: center; color: var(--texte-doux); }

/* Filtres */
.filtres { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); align-items: end; margin-bottom: 1rem; }
.filtres label { font-size: .82rem; }
.onglets { display: flex; gap: .3rem; border-bottom: 1px solid var(--bord); margin-bottom: 1rem; flex-wrap: wrap; }
.onglets a { padding: .55rem .9rem; text-decoration: none; color: var(--texte-doux); border-bottom: 2px solid transparent; margin-bottom: -1px; font-weight: 600; }
.onglets a.actif { color: var(--teal); border-bottom-color: var(--corail); }

/* Détail d'une demande */
.dl { display: grid; grid-template-columns: max-content 1fr; gap: .45rem 1.2rem; margin: 0; }
.dl dt { color: var(--texte-doux); font-size: .9rem; }
.dl dd { margin: 0; white-space: pre-wrap; }
.fil { list-style: none; padding: 0; margin: 0 0 1rem; display: grid; gap: .7rem; }
.fil li { background: var(--fond); border-radius: 8px; padding: .7rem .9rem; }
.fil li.equipe { background: var(--bleu-fond); }
.fil .auteur { font-size: .82rem; color: var(--texte-doux); margin-bottom: .2rem; }
.fichiers { list-style: none; padding: 0; margin: 0 0 1rem; }
.fichiers li { padding: .35rem 0; border-bottom: 1px dashed var(--bord); }
.fichiers button { background: none; border: 0; color: var(--teal-clair); text-decoration: underline; cursor: pointer; font: inherit; padding: 0; }

.notif { display: block; padding: .8rem 1rem; border-bottom: 1px solid var(--bord); text-decoration: none; color: inherit; }
.notif.nonlue { background: #fbfcfe; border-left: 3px solid var(--corail); }
.notif p { margin: .2rem 0 0; white-space: pre-wrap; color: var(--texte-doux); font-size: .9rem; }

@media (max-width: 640px) {
  h1 { font-size: 1.35rem; }
  .carte { padding: 1rem; }
  .auth { margin: 1rem auto; }
  .auth .carte { padding: 1.25rem; }
  .dl { grid-template-columns: 1fr; gap: .1rem; }
  .dl dd { margin-bottom: .5rem; }
  .nav { margin-left: 0; width: 100%; }
}

/* Connexion avec Google */
.btn-google { display: flex; align-items: center; justify-content: center; gap: .6rem; }
.separateur { display: flex; align-items: center; gap: .8rem; margin: 1.1rem 0; color: var(--texte-doux); font-size: .85rem; }
.separateur::before, .separateur::after { content: ""; flex: 1; border-top: 1px solid var(--bord); }

/* Absences non justifiées : signalées comme graves */
.badge.non_justifiee { background: var(--rouge); color: #fff; }
tr.grave td { background: var(--rouge-fond); }
tr.grave td:first-child { box-shadow: inset 4px 0 0 var(--rouge); }
.alerte.grave { background: var(--rouge); border-color: var(--rouge); color: #fff; }
.alerte.grave strong { color: #fff; }
.stat.grave { border: 2px solid var(--rouge); background: var(--rouge-fond); }
.stat.grave b { color: var(--rouge); }
.nombre.grave { color: var(--rouge); font-weight: 700; }

/* Actions de l'équipe sur les absences */
th.col-actions, td.col-actions { text-align: right; white-space: nowrap; }
.actions-ligne { display: inline-flex; gap: .4rem; }
.btn.danger { color: var(--rouge); border-color: #f1b8bd; }
.btn.danger:hover { background: var(--rouge-fond); border-color: var(--rouge); }
.barre-gestion { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .8rem 1.2rem;
  background: var(--bleu-fond, #eef3f8); border: 1px solid var(--bord); border-radius: 10px; padding: .8rem 1rem; margin: 0 0 1.2rem; }
.barre-gestion > span { flex: 1 1 320px; font-size: .92rem; }
.aide-gestion { display: flex; flex-direction: column; gap: .3rem; }
@media (max-width: 720px) { td.col-actions { white-space: normal; } .actions-ligne { flex-direction: column; } }

/* Pied de page : version */
.pied { max-width: 1180px; margin: 0 auto; padding: 1rem 16px 2rem; display: flex; flex-wrap: wrap; gap: .4rem 1.2rem;
  justify-content: space-between; font-size: .82rem; color: var(--texte-doux); border-top: 1px solid var(--bord); }
.pied a { color: inherit; }
.pied-alerte { color: var(--orange); font-weight: 600; }
.version-actuelle { border-color: var(--teal); }

/* Lien de menu sur deux lignes */
.lien-double { display: inline-flex; flex-direction: column; line-height: 1.1; }
.lien-double small { font-size: .7rem; opacity: .8; }

/* Fenêtre de validation */
dialog.dialogue { border: none; border-radius: 12px; padding: 1.25rem 1.5rem; max-width: 32rem; width: calc(100% - 2rem); box-shadow: 0 10px 40px rgba(0,0,0,.25); }
dialog.dialogue::backdrop { background: rgba(20,65,97,.35); }
dialog.dialogue h2 { margin-top: 0; }
dialog.dialogue textarea { width: 100%; }

/* Page Mode d'emploi */
.guide { max-width: 860px; line-height: 1.6; }
.guide h2 { margin: 1.8rem 0 .6rem; padding-top: .4rem; border-top: 1px solid var(--bord); }
.guide h2:first-child { border-top: none; margin-top: 0; }
.guide ol, .guide ul { padding-left: 1.4rem; }
.guide li p { margin: .25rem 0; }
.guide img { max-width: 100%; height: auto; border-radius: 8px; }
.guide .table-defile { overflow-x: auto; margin: .8rem 0; }
.guide table { border-collapse: collapse; width: 100%; font-size: .93rem; }
.guide th, .guide td { border: 1px solid var(--bord); padding: .45rem .6rem; text-align: left; vertical-align: top; }
.guide th { background: rgba(20,65,97,.06); }
.guide code { font-size: .9em; }

/* Bandeau de filtres : boutons côte à côte */
.filtres .boutons-filtre { display: flex; gap: .5rem; align-items: end; white-space: nowrap; }
.filtres .boutons-filtre .btn { flex: 1; justify-content: center; text-align: center; }

/* En-têtes de tableau triables */
th.triable { cursor: pointer; user-select: none; white-space: nowrap; }
th.triable:hover { color: var(--teal); }
th.triable .fleche { margin-left: .3rem; font-size: .7em; opacity: .35; }
th.triable.trie .fleche { opacity: 1; color: var(--corail); }

/* Colonne formation, badge sur deux lignes, bandeau de filtres repliable */
.col-formation { max-width: 9rem; min-width: 6rem; white-space: normal; line-height: 1.3; }
.badge.deux-lignes { white-space: normal; text-align: center; border-radius: 10px; line-height: 1.15; padding: .2rem .55rem; }
.bandeau-filtres { padding: 0; margin-bottom: 1rem; }
.bandeau-filtres > summary { cursor: pointer; padding: .8rem 1.1rem; font-weight: 600; color: var(--teal); list-style-position: inside; }
.bandeau-filtres[open] > summary { border-bottom: 1px solid var(--bord); }
.bandeau-filtres .filtres { padding: 1rem 1.1rem 1.1rem; margin: 0; }
.col-periode { white-space: nowrap; line-height: 1.35; }
.actions-ligne .btn[aria-label] { min-width: 2.2rem; padding-left: .5rem; padding-right: .5rem; font-size: .95rem; }

/* Liste des formations (Administration) */
.ligne-formation { display: flex; gap: .4rem; align-items: center; margin-bottom: .45rem; flex-wrap: wrap; }
.ligne-formation input { flex: 1 1 14rem; min-width: 10rem; }
.ligne-formation .nb { min-width: 6.5rem; text-align: right; }
.badge.arret_travail { background: #fdf3c2; color: #7a5b00; }   /* jaune */
.confirmation-ligne { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin: -.1rem 0 .6rem; padding: .55rem .75rem; border-radius: 8px; background: var(--orange-fond); font-size: .92rem; }
.confirmation-ligne span { flex: 1 1 16rem; }

/* Réglage des alertes */
.choix-radio { display: flex; gap: .6rem; align-items: flex-start; padding: .55rem .2rem; cursor: pointer; font-weight: 400; }
.choix-radio input { margin-top: .25rem; width: auto; }
.heures-alertes { display: flex; flex-wrap: wrap; gap: .5rem 1rem; margin: .3rem 0 1rem 1.7rem; }
.heures-alertes.inactif { opacity: .45; }
.heure-alerte { display: flex; gap: .4rem; align-items: center; font-weight: 400; }
.heure-alerte input[type=checkbox] { width: auto; }
.heure-alerte input[type=time] { width: auto; }

/* Page Notifications : sections et récapitulatifs repliables */
.bloc-notifs { margin-bottom: 1.6rem; }
.bloc-notifs h2 { margin: 0 0 .2rem; font-size: 1.1rem; }
.bloc-notifs > p { margin: 0 0 .6rem; }
details.recap { border-bottom: 1px solid var(--bord); }
details.recap:last-child { border-bottom: none; }
details.recap.nonlue { border-left: 3px solid var(--corail); background: #fbfcfe; }
details.recap > summary { cursor: pointer; padding: .75rem 1rem; display: flex; flex-direction: column; gap: .15rem; list-style: none; position: relative; padding-left: 2.1rem; }
details.recap > summary::-webkit-details-marker { display: none; }
details.recap > summary::before { content: "▸"; position: absolute; left: .9rem; top: .78rem; color: var(--teal); transition: transform .15s; }
details.recap[open] > summary::before { transform: rotate(90deg); }
.recap-titre { font-weight: 700; color: var(--teal); }
.recap-titre::first-letter { text-transform: uppercase; }
.recap-sous { font-size: .86rem; color: var(--texte-doux); }
.recap-lignes { list-style: none; margin: 0; padding: 0 1rem .8rem 2.1rem; }
.recap-lignes li { display: grid; grid-template-columns: 5.6rem 1fr auto; gap: .2rem .8rem; padding: .4rem 0; border-top: 1px dashed var(--bord); font-size: .92rem; align-items: baseline; }
.recap-lignes li.grave { color: var(--rouge); }
.recap-heure { color: var(--texte-doux); font-variant-numeric: tabular-nums; font-size: .85rem; }
.recap-auteur { color: var(--texte-doux); font-size: .82rem; white-space: nowrap; }
.recap-texte { white-space: pre-wrap; padding: 0 1rem .8rem 2.1rem; margin: 0; color: var(--texte-doux); }
@media (max-width: 640px) { .recap-lignes li { grid-template-columns: 1fr; } }
.suivi-notif { display: flex; gap: .5rem; margin-top: .45rem; padding: .45rem .7rem; background: var(--bleu-fond); border-radius: 8px; font-size: .88rem; color: var(--texte); }
.suivi-icone { color: var(--teal); font-weight: 700; }
.notif .badge { vertical-align: middle; margin-left: .3rem; }

/* Tableau de bord : étudiants à surveiller */
.vigilance h2 { margin-top: 0; }
.ligne-vigilance { display: grid; grid-template-columns: 12rem 1fr; gap: .4rem 1rem; padding: .6rem .5rem; border-top: 1px solid var(--bord); border-radius: 6px; }
.titre-vigilance { font-weight: 700; font-size: .92rem; padding-top: .3rem; }
.ligne-vigilance.rouge .titre-vigilance { color: var(--rouge); }
.ligne-vigilance.orange .titre-vigilance { color: var(--orange); }
.ligne-vigilance.grave .titre-vigilance { color: var(--rouge); }
.pastilles { display: flex; flex-wrap: wrap; gap: .4rem; }
.pastille-etudiant { display: inline-flex; align-items: center; border-radius: 999px; border: 1px solid var(--bord); background: #fff; font-size: .88rem; }
.pastille-etudiant > a { display: inline-flex; gap: .35rem; align-items: baseline; padding: .3rem .2rem .3rem .65rem; text-decoration: none; color: var(--texte); border-radius: 999px 0 0 999px; }
.pastille-etudiant > a:hover { background: var(--bleu-fond); }
.pastille-etudiant > a span { color: var(--texte-doux); font-size: .8rem; }
.pastille-action { border: none; background: none; color: var(--texte-doux); cursor: pointer; padding: .2rem .55rem .2rem .3rem; font-size: 1rem; line-height: 1; border-radius: 0 999px 999px 0; }
.pastille-action:hover { color: var(--rouge); }
.pastille-etudiant.retiree { opacity: .55; border-style: dashed; }
.pastille-etudiant.retiree .pastille-action:hover { color: var(--teal); }
.retires { display: contents; }
.retires[hidden] { display: none; }
details.vigilance > summary { cursor: pointer; list-style: none; }
details.vigilance > summary::-webkit-details-marker { display: none; }
details.vigilance > summary h2 { display: inline-block; margin: 0 0 .3rem; }
details.vigilance > summary::after { content: " ▾"; color: var(--teal); }
details.vigilance:not([open]) > summary::after { content: " ▸"; }
.lien-bouton { border: none; background: none; color: var(--teal); text-decoration: underline; cursor: pointer; padding: 0; font: inherit; margin-left: .3rem; }
.ligne-vigilance.rouge .pastille-etudiant { border-color: #f1b7bd; }
.ligne-vigilance.orange .pastille-etudiant { border-color: #f3d29b; }
.ligne-vigilance.grave .pastille-etudiant { border-color: #f1b7bd; background: var(--rouge-fond); }
.ligne-vigilance.eclair { animation: eclair 1.4s ease; }
@keyframes eclair { 0%, 40% { background: #fff5cc; } 100% { background: transparent; } }
a.stat[href] { cursor: pointer; }
@media (max-width: 640px) { .ligne-vigilance { grid-template-columns: 1fr; } }
.recap-lignes li.recap-section { display: block; border-top: none; padding: .7rem 0 .2rem; font-weight: 700; color: var(--teal); font-size: .88rem; }
.initiales { display: inline-block; margin-left: .3rem; padding: .05rem .35rem; border-radius: 4px; background: var(--gris-fond); color: var(--texte-doux); font-size: .72rem; font-weight: 700; letter-spacing: .03em; vertical-align: middle; cursor: help; }
/* Colonnes chiffrées compactes dans les tableaux de demandes */
.table-demandes th.nombre, .table-demandes td.nombre { width: 1%; padding-left: .45rem; padding-right: .45rem; white-space: nowrap; }
.table-demandes th, .table-demandes td { padding-left: .55rem; padding-right: .55rem; }
.table-demandes .col-formation { max-width: 7.5rem; min-width: 5.5rem; }
.table-demandes td:last-child { padding-right: .7rem; }
.table-demandes .badge.non_justifiee { white-space: normal; max-width: 8.5rem; border-radius: 10px; line-height: 1.2; }
.table-demandes th { font-size: .72rem; }
.barre-progression { height: 10px; border-radius: 999px; background: var(--gris-fond); overflow: hidden; }
.barre-progression span { display: block; height: 100%; width: 0; background: var(--teal); transition: width .3s; }

/* ---------- Portail : inscription, administration, classes et maquette ---------- */
.etiquette { display: block; font-weight: 600; margin-bottom: .35rem; }
.choix-profil { display: flex; flex-wrap: wrap; gap: .5rem 1.25rem; }
.choix-profil label { display: flex; gap: .4rem; align-items: center; font-weight: 500; }
.enseigne-aussi { display: flex; gap: .35rem; align-items: center; margin-top: .3rem; font-weight: 500; color: var(--texte-doux); }
.grille-modules td:not(:first-child), .grille-modules th:not(:first-child) { text-align: center; }
.tableau-compact th, .tableau-compact td { padding: .45rem .55rem; vertical-align: top; }
.tableau-compact td input[type=number] { padding: .25rem .4rem; }
.maquette td:nth-child(7), .maquette td:nth-child(8) { min-width: 180px; }
.petit-select { width: auto; max-width: 180px; padding: .15rem .35rem; font-size: .82rem; border-radius: 999px; }
.segments { display: inline-flex; border: 1px solid var(--bord); border-radius: 999px; overflow: hidden; }
.segments a { padding: .35rem .9rem; text-decoration: none; color: var(--texte-doux); font-weight: 600; font-size: .9rem; }
.segments a.actif { background: var(--teal); color: #fff; }
details.replie > summary { cursor: pointer; padding: .2rem 0; }
details.replie[open] > summary { margin-bottom: .75rem; }
details.replie h3 { margin: 1rem 0 .4rem; font-size: 1rem; }

/* Bandeau sur l'ancienne adresse (absences.ecole-edm.org) */
.bandeau-portail { display: flex; flex-wrap: wrap; gap: .4rem 1rem; align-items: center; justify-content: center;
  padding: .55rem 1rem; background: var(--bleu-fond); color: var(--teal); font-size: .9rem; border-bottom: 1px solid var(--bord); text-align: center; }
.bandeau-portail a { font-weight: 700; color: var(--teal); white-space: nowrap; }

/* ---------- Portail : accueil en pavés ---------- */
.accueil-portail { max-width: 1080px; margin: 0 auto; }
.accueil-entete { margin: .5rem 0 1.6rem; }
.accueil-entete h1 { font-size: 2.1rem; margin: .1rem 0 .2rem; }
.accueil-entete .doux::first-letter { text-transform: uppercase; }
.accueil-sur-titre { margin: 0; font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--corail); }
.accueil-section { font-size: .85rem; letter-spacing: .06em; text-transform: uppercase; color: var(--texte-doux); margin: 2rem 0 .8rem; }
.paves { display: grid; gap: 1.1rem; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
.pave { --c: var(--teal); --f: var(--bleu-fond);
  position: relative; display: flex; flex-direction: column; gap: .35rem; min-height: 190px; padding: 1.3rem 1.3rem 1.1rem;
  background: var(--carte); border: 1px solid var(--bord); border-radius: 16px; box-shadow: var(--ombre);
  text-decoration: none; color: var(--texte); overflow: hidden; transition: transform .15s, box-shadow .15s, border-color .15s; }
.pave::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--c); }
a.pave:hover, a.pave:focus-visible { transform: translateY(-3px); border-color: var(--c); box-shadow: 0 10px 28px rgba(20, 65, 97, .14); }
.pave-icone { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: var(--f); color: var(--c); margin-bottom: .5rem; }
.pave-icone svg { width: 26px; height: 26px; }
.pave-titre { font-size: 1.2rem; font-weight: 700; color: var(--teal); }
.pave-texte { font-size: .92rem; color: var(--texte-doux); line-height: 1.4; }
.pave-detail { margin-top: auto; padding-top: .6rem; min-height: 1.6rem; }
.pave-fleche { position: absolute; right: 1.1rem; bottom: 1rem; font-size: 1.3rem; color: var(--c); transition: transform .15s; }
a.pave:hover .pave-fleche { transform: translateX(4px); }
.pave.corail { --c: var(--corail); --f: #fde9ea; }
.pave.teal { --c: var(--teal); --f: var(--bleu-fond); }
.pave.ardoise { --c: var(--ardoise); --f: #eef1f8; }
.pave.vert { --c: var(--vert); --f: var(--vert-fond); }
.pave.neutre { --c: var(--texte-doux); --f: var(--gris-fond); min-height: 150px; }
.pave.en-preparation { opacity: .72; }
.pave.en-preparation::before { background: var(--bord); }
.paves-outils .pave-titre { font-size: 1.05rem; }

/* Sous-menu d'un module (Absences) */
.sous-nav { background: #fff; border-bottom: 1px solid var(--bord); }
.sous-nav-interieur { max-width: 1200px; margin: 0 auto; padding: 0 1.25rem; display: flex; gap: .2rem; align-items: center; flex-wrap: wrap; }
.sous-nav-titre { font-weight: 700; color: var(--corail); margin-right: .8rem; font-size: .85rem; text-transform: uppercase; letter-spacing: .05em; }
.sous-nav a { padding: .65rem .8rem; text-decoration: none; color: var(--texte-doux); font-weight: 600; font-size: .92rem; border-bottom: 2px solid transparent; }
.sous-nav a.actif { color: var(--teal); border-bottom-color: var(--corail); }

/* ---------- Dépôt des dossiers ---------- */
h2.annee-etude { margin: 1.6rem 0 .7rem; }
.module-depots h2 { font-size: 1.1rem; }
.form-ressource-carte { border-top: 1px dashed var(--bord); margin-top: 1rem; padding-top: 1rem; }
.form-ressource-carte h3 { margin: 0 0 .8rem; }
.choix-classes, .choix-options { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; margin: .2rem 0 .6rem; }
.choix-classes label, .choix-options label { display: flex; gap: .35rem; align-items: center; font-weight: 500; }
.grille-chiffres { display: grid; gap: .8rem; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); margin: 1rem 0; }
.indicateur { background: var(--carte); border: 1px solid var(--bord); border-radius: var(--rayon); padding: .8rem 1rem; }
.indicateur strong { display: block; font-size: 1.8rem; color: var(--teal); line-height: 1.1; }
.indicateur span { color: var(--texte-doux); font-size: .88rem; }
button.lien { background: none; border: none; padding: 0; color: var(--teal-clair); text-decoration: underline; cursor: pointer; font: inherit; text-align: left; }
.consignes { white-space: pre-line; background: var(--gris-fond); border-radius: 8px; padding: .6rem .8rem; margin: .6rem 0; }
.ressource-etudiant h3 { font-size: 1.05rem; }
.ressource-etudiant .versions { margin: .5rem 0; display: grid; gap: .2rem; }
.correction { margin-top: .8rem; border-left: 3px solid var(--vert); background: var(--vert-fond); padding: .6rem .9rem; border-radius: 0 8px 8px 0; }
.correction p { margin: .3rem 0 .5rem; white-space: pre-line; }
.zone-envoi { margin-top: .6rem; }
.zone-envoi .envoi-progression { margin-top: .5rem; max-width: 520px; }
.zone-envoi.compact { margin-top: .3rem; }
.suivi-depots textarea { min-width: 180px; font-size: .88rem; padding: .3rem .45rem; }
.suivi-depots td { min-width: 110px; }
.zone-envoi [hidden], .envoi-progression[hidden] { display: none !important; }
