/* © 2026 Antoine Angelini, tous droits réservés */
/* Vitasimo : style commun des pages de démonstration (accueil, entrée élève, espace enseignant). Même charte que mission.html. */
@font-face {
  font-family: 'Baloo 2';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('polices/baloo2-latin.woff2') format('woff2');
}
:root {
  --encre: #2b1460; --violet: #7b3cff; --violet-fonce: #5a22d6; --rose: #ff4f9a; --rose-fonce: #d12a73;
  --orange: #ff9a1f; --orange-fonce: #d9700a; --turquoise: #18c8b5; --turquoise-fonce: #0e9a8b;
  --jaune: #ffd60a; --jaune-fonce: #d9a800; --lilas: #eee6ff; --lilas-fonce: #d8ccf5;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { min-height: 100%; background: linear-gradient(#37c2ff, #8df0e2) fixed; }
body { font-family: 'Baloo 2', system-ui, sans-serif; color: var(--encre); font-size: 17px; line-height: 1.4; padding: 16px clamp(14px, 3vw, 40px) 30px; }
button, input { font: inherit; color: var(--encre); }
button { cursor: pointer; touch-action: manipulation; }
a { color: var(--encre); }

header { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
header .espace { flex: 1; }
header .qui { font-weight: 700; background: #fff; border-radius: 999px; padding: 6px 18px; }
.marque { font-weight: 800; font-size: 26px; line-height: 1; }
.marque small { display: block; font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; margin-top: 3px; }
.grande { font-size: clamp(44px, 7vw, 84px); }
.grande small { font-size: clamp(14px, 1.6vw, 20px); margin-top: 8px; }

.carte { background: #fff; border-radius: 26px; padding: 20px 24px; box-shadow: 0 8px 0 var(--lilas-fonce); border-top: 12px solid var(--violet); }
.carte.rose { border-top-color: var(--rose); } .carte.turquoise { border-top-color: var(--turquoise); } .carte.orange { border-top-color: var(--orange); }
.sur { font-size: 13px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--violet-fonce); }
h1 { font-size: 32px; font-weight: 800; line-height: 1.15; margin-bottom: 6px; }
h2 { font-size: 22px; font-weight: 800; line-height: 1.2; margin-bottom: 10px; }
h3 { font-size: 17px; font-weight: 800; margin: 12px 0 4px; }
.encadre { background: var(--lilas); border-radius: 16px; padding: 10px 14px; margin: 12px 0; font-weight: 500; }
.encadre b { font-weight: 800; }
ul, ol { margin-left: 22px; }

.deux { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px; align-items: start; }
.pile > * + * { margin-top: 20px; }
label { display: block; font-weight: 800; margin-top: 12px; }
.champ { display: block; margin-top: 4px; padding: 7px 16px; border-radius: 999px; border: 2px solid var(--violet); background: #fff; min-height: 46px; width: min(360px, 100%); font-weight: 600; }
.champ.code { text-transform: uppercase; letter-spacing: .12em; font-weight: 800; }
.erreur { background: #ffe0ee; border-radius: 14px; padding: 8px 14px; margin-top: 12px; font-weight: 700; }
.bouton {
  display: inline-block; text-decoration: none; text-align: center; font-size: 17px; font-weight: 800; border: 0; border-radius: 999px;
  padding: 7px 22px; min-height: 40px; background: var(--jaune); box-shadow: 0 5px 0 var(--jaune-fonce);
}
.bouton.blanc { background: #fff; box-shadow: 0 4px 0 var(--lilas-fonce); font-weight: 700; border: 2px solid var(--lilas-fonce); }
.bouton.rouge { background: #e5263d; color: #fff; box-shadow: 0 5px 0 #a8162a; }
.bouton:active { transform: translateY(3px); }
.ligne { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 14px; }

.rang { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-top: 2px solid var(--lilas); }
.rang:first-of-type { border-top: 0; }
.rang .num { flex: none; min-width: 58px; height: 46px; padding: 0 10px; border-radius: 999px; background: var(--jaune); display: grid; place-items: center; font-weight: 800; font-size: 20px; }
.rang .quoi { flex: 1; min-width: 0; }
.rang .quoi b { font-weight: 800; font-size: 19px; }
.rang .quoi p { font-weight: 500; font-size: 16px; }
.rang .droite { flex: none; display: flex; flex-direction: column; align-items: flex-end; gap: 8px; }
.etat { border-radius: 999px; padding: 1px 14px; font-weight: 800; font-size: 14px; white-space: nowrap; }
.etat.faite { background: var(--turquoise); } .etat.encours { background: var(--jaune); }
.etat.ajouer { background: var(--violet); color: #fff; } .etat.fermee { background: var(--lilas); }
.niv { display: inline-block; border-radius: 999px; padding: 2px 16px; font-weight: 800; font-size: 16px; white-space: nowrap; }
.niv.a { background: var(--turquoise); } .niv.ec { background: var(--jaune); } .niv.na { background: var(--orange); }

/* Onglets de classeur : une couleur par onglet */
.onglets { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: -4px; padding-left: 14px; position: relative; z-index: 1; }
.onglet { border: 0; border-radius: 18px 18px 0 0; padding: 8px 26px 12px; font-weight: 800; font-size: 18px; color: #fff; opacity: .78; }
.onglet[aria-selected=true] { opacity: 1; padding-top: 12px; margin-top: -4px; }
.onglet.classes { background: var(--violet); } .onglet.missions { background: var(--rose-fonce); } .onglet.suivi { background: var(--turquoise-fonce); }
.panneau { background: #fff; border-radius: 26px; padding: 20px 24px; box-shadow: 0 8px 0 var(--lilas-fonce); border-top: 12px solid var(--violet); }
.panneau.missions { border-top-color: var(--rose-fonce); } .panneau.suivi { border-top-color: var(--turquoise-fonce); }

.code-session { display: inline-block; font-size: 34px; font-weight: 800; letter-spacing: .14em; background: var(--lilas); border-radius: 16px; padding: 2px 18px; }
table { border-collapse: collapse; width: 100%; margin: 8px 0; }
th, td { text-align: left; padding: 8px 12px 8px 0; vertical-align: top; border-top: 2px solid var(--lilas); }
th { font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--violet-fonce); border-top: 0; }
.defile { overflow-x: auto; }
footer { margin-top: 26px; text-align: center; font-size: 14px; font-weight: 600; }
#toast { position: fixed; top: 14px; left: 50%; transform: translateX(-50%); background: var(--encre); color: #fff; font-weight: 700; border-radius: 999px; padding: 8px 22px; z-index: 5; }

@media (max-width: 520px) {
  .rang { flex-wrap: wrap; }
  .rang .droite { flex-direction: row; align-items: center; width: 100%; justify-content: space-between; }
  .carte, .panneau { padding: 16px; border-radius: 22px; }
  h1 { font-size: 26px; }
}
