/* Identité Mila : bleu nuit, dégradé bleu → turquoise, violet et corail en touches. */
:root {
  --navy: #16263f; --blue: #1a7aa3; --teal: #3fbfae; --violet: #7b65e6; --coral: #f4847a;
  --bg: #f6f8fb; --surface: #fff; --text: var(--navy); --muted: #5b6678; --line: #e3e8ef;
  --primary: #1a7aa3; --primary-dark: #146283; --accent-bg: #e4f6f3;
  --ok-bg: #dff5f0; --ok: #0f6b5c; --wip-bg: #fdebe8; --wip: #a8443a;
  --err-bg: #fde4e4; --err: #9b1c1c; --radius: 10px;
  --gradient: linear-gradient(90deg, var(--blue), var(--teal));
}
* { box-sizing: border-box; }
body { margin: 0; font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; color: var(--text); background: var(--bg); }
a { color: var(--primary); }
h1 { font-size: 24px; margin: 24px 0 16px; }
h2 { font-size: 17px; margin: 28px 0 12px; }
.panel h2, .card h2 { margin-top: 0; }
small { display: block; color: var(--muted); font-size: 12px; }
code { background: #eef1f5; padding: 1px 5px; border-radius: 4px; }
.muted { color: var(--muted); }
.wrap { max-width: 1200px; margin: 0 auto; padding: 0 16px 48px; }

.top { background: var(--surface); border-bottom: 1px solid var(--line); position: relative; }
.top::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: linear-gradient(90deg, var(--blue), var(--teal) 60%, var(--violet) 85%, var(--coral)); }
.top-in { display: flex; align-items: center; gap: 24px; min-height: 64px; padding-bottom: 0; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--muted); font-size: 12px; }
.brand img { height: 40px; width: auto; display: block; }
.top nav { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.top nav a { color: var(--navy); text-decoration: none; padding: 7px 12px; border-radius: 8px; font-weight: 500; }
.top nav a:hover { background: #f0f3f7; }
.top nav a[aria-current] { background: var(--accent-bg); color: var(--ok); }
.me { display: flex; align-items: center; gap: 14px; font-size: 14px; }
.me form { margin: 0; }
button.link, label.link { background: none; border: 0; color: var(--primary); padding: 0; cursor: pointer; font: inherit; text-decoration: underline; }
.actions label.link { color: var(--primary); }

button, .btn { background: var(--primary); color: #fff; border: 0; border-radius: 8px; padding: 8px 16px; font: inherit; font-size: 14px; cursor: pointer; text-decoration: none; display: inline-block; }
button:hover, .btn:hover { background: var(--primary-dark); }
button.secondary { background: #fff; color: var(--text); border: 1px solid var(--line); }
button.secondary:hover { background: #f0f3f7; }
input, select { font: inherit; font-size: 14px; padding: 7px 10px; border: 1px solid #c8cfd9; border-radius: 6px; background: #fff; max-width: 100%; }
label { display: block; margin-bottom: 12px; font-size: 14px; }
label input:not([type=checkbox]):not([type=radio]), label select { display: block; width: 100%; margin-top: 4px; }
label.check { display: flex; gap: 8px; align-items: center; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 16px; }
.filters label { margin: 0; display: flex; gap: 6px; align-items: center; }
.filters label input { margin: 0; width: auto; }
form.inline { display: inline; }

.flash { background: var(--ok-bg); color: var(--ok); padding: 10px 14px; border-radius: var(--radius); margin-top: 16px; }
.flash-err { background: var(--err-bg); color: var(--err); }
.panel, .card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; margin-bottom: 16px; }
.panel.narrow { max-width: 480px; }
.demo { background: var(--wip-bg); padding: 10px; border-radius: 6px; }
.grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 16px; }
.list { padding-left: 18px; }
.list small { display: inline; }

.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin-bottom: 12px; }
.kpi { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.kpi b { display: block; font-size: 26px; line-height: 1.2; }
.kpi span { color: var(--muted); font-size: 13px; }

.table-wrap { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
table { border-collapse: collapse; width: 100%; font-size: 14px; }
th, td { padding: 9px 12px; text-align: left; border-bottom: 1px solid #edf0f4; vertical-align: top; }
th { background: #f8fafc; color: var(--muted); font-weight: 600; white-space: nowrap; }
tr:last-child td { border-bottom: 0; }
tr.inactive td { color: var(--muted); }
td.actions { white-space: nowrap; }
td.actions > * + * { margin-left: 12px; }
.empty { background: var(--surface); border: 1px dashed var(--line); border-radius: var(--radius); padding: 24px; text-align: center; color: var(--muted); }

.badge { display: inline-block; padding: 2px 9px; border-radius: 10px; font-size: 12px; background: #edf0f4; white-space: nowrap; }
.badge-done { background: var(--ok-bg); color: var(--ok); }
.badge-wip { background: var(--wip-bg); color: var(--wip); }
.bar { display: inline-block; width: 70px; height: 6px; background: #e7ebf0; border-radius: 3px; vertical-align: middle; overflow: hidden; }
.bar span { display: block; height: 100%; background: var(--primary); }

.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.card h2 { font-size: 17px; }

.chart { display: flex; align-items: flex-end; gap: 8px; height: 180px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 16px 8px; }
.chart .col { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; height: 100%; }
.chart .b { width: 100%; max-width: 36px; background: var(--primary); border-radius: 4px 4px 0 0; min-height: 2px; }
.chart .val { font-size: 12px; color: var(--muted); }
.chart .lbl { font-size: 12px; color: var(--muted); margin-top: 4px; }

body.player { background: #000; height: 100vh; margin: 0; display: flex; flex-direction: column; }
.player-bar { height: 42px; flex: none; display: flex; align-items: center; gap: 16px; padding: 0 16px; background: #102a43; color: #fff; font-size: 14px; }
.player-bar a { color: #9cc8ff; }
.player-bar .muted { color: #f5c26b; }
body.player iframe { flex: 1; border: 0; width: 100%; }

input[hidden] { display: none !important; }

/* Formulaires de compte */
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px 4px; margin: 0 0 16px; }
legend { font-weight: 600; font-size: 14px; padding: 0 6px; }
.grid2.tight { gap: 0 16px; }
.small { font-size: 13px; }
p.small, p.muted.small { margin: 4px 0 12px; }
.acces .pw-field { margin-left: 26px; max-width: 360px; }
.acces:not(:has(input[value=manuel]:checked)) .pw-field { display: none; }
a.link { color: var(--primary); }
button.link-dark { background: none; border: 0; padding: 0; color: var(--primary); text-decoration: underline; font-size: 13px; cursor: pointer; margin-right: 10px; }
.btn.secondary-btn { background: #fff; color: var(--text); border: 1px solid var(--line); }
.btn.secondary-btn:hover { background: #f0f3f7; }
.credentials code { font-size: 15px; }
.demo-inline { font-size: 13px; }
.flash ul { margin: 6px 0 0; padding-left: 20px; }

@media print {
  .top, .noprint, .flash, h1, main > p, .grid2, form { display: none !important; }
  .credentials { border: 0; padding: 0; }
  .credentials p { display: block; }
}

textarea { font: inherit; font-size: 14px; padding: 7px 10px; border: 1px solid #c8cfd9; border-radius: 6px; display: block; width: 100%; margin-top: 4px; resize: vertical; }
.card .desc { color: var(--muted); font-size: 14px; margin: -4px 0 8px; }

/* Touches Mila */
h1 { letter-spacing: -0.01em; }
.kpi { border-top: 3px solid var(--teal); }
.kpis .kpi:nth-child(2) { border-top-color: var(--blue); }
.kpis .kpi:nth-child(3) { border-top-color: var(--violet); }
.kpis .kpi:nth-child(4) { border-top-color: var(--coral); }
.kpis .kpi:nth-child(5) { border-top-color: var(--navy); }
.bar span { background: var(--gradient); }
.chart .b { background: linear-gradient(180deg, var(--teal), var(--blue)); }
.card { border-top: 3px solid var(--teal); }
.player-bar { background: var(--navy); }
.player-bar a { color: #8fe0d3; }

/* Page de connexion */
.login-brand { text-align: center; margin: 40px 0 8px; }
.login-brand img { width: 280px; max-width: 80%; height: auto; }
body.login h1 { text-align: center; font-size: 20px; }
body.login .panel.narrow { margin: 0 auto; }

/* Couvertures */
.card { padding: 0; overflow: hidden; display: flex; flex-direction: column; }
.card > :not(.cover) { margin-left: 20px; margin-right: 20px; }
.card > h2 { margin-top: 16px; }
.card > .btn { align-self: flex-start; margin-bottom: 20px; margin-top: auto; }
.cover { display: block; aspect-ratio: 16 / 9; background: var(--gradient); overflow: hidden; }
.cover img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s; }
.card:hover .cover img { transform: scale(1.03); }
.cover-ph { display: flex; align-items: center; justify-content: center; height: 100%; color: #fff; font-size: 56px; font-weight: 700; opacity: .9; }
.cover-preview { width: 100%; height: auto; border-radius: 8px; display: block; margin-bottom: 8px; border: 1px solid var(--line); }
td.with-thumb { display: flex; gap: 12px; align-items: center; }
.thumb { width: 96px; height: 54px; object-fit: cover; border-radius: 6px; flex: none; background: var(--gradient); display: block; }
@media (prefers-reduced-motion: reduce) { .cover img { transition: none; } }
.cards .card { border-top: 1px solid var(--line); }

/* Parcours : liste des étapes (apprenant) */
.steps, .admin-steps { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 10px; }
.step { display: flex; align-items: center; gap: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.step.next { border-color: var(--teal); box-shadow: 0 0 0 3px var(--accent-bg); }
.step-num { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; font-weight: 700; font-size: 14px; background: #eef2f6; color: var(--navy); }
.step.done .step-num { background: var(--ok-bg); color: var(--ok); }
.step.next .step-num { background: var(--gradient); color: #fff; }
.step-body { flex: 1; min-width: 0; }
.step-body b { display: block; }
.step-status { flex: none; }
.step .btn { flex: none; }
@media (max-width: 640px) { .step { flex-wrap: wrap; } .step-status { order: 3; } .step .btn { order: 4; margin-left: 46px; } }

.parcours-head { display: grid; grid-template-columns: minmax(0, 360px) 1fr; gap: 24px; align-items: center; margin-bottom: 24px; }
.parcours-cover { width: 100%; height: auto; border-radius: var(--radius); display: block; }
@media (max-width: 720px) { .parcours-head { grid-template-columns: 1fr; } }

/* Parcours : édition (admin) */
.admin-step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; }
.admin-step-head { display: flex; align-items: center; gap: 12px; }
.admin-step-head form { margin: 0; display: flex; gap: 4px; }
.admin-step details { margin-top: 8px; }
.admin-step summary { cursor: pointer; color: var(--primary); font-size: 14px; }
.admin-step details[open] { border-top: 1px solid var(--line); padding-top: 12px; }
.admin-step details > .grid2 { margin-top: 12px; }
.icon-btn { padding: 4px 10px; background: #fff; color: var(--navy); border: 1px solid var(--line); font-size: 14px; line-height: 1.2; }
.icon-btn:hover { background: #f0f3f7; }
.icon-btn:disabled { opacity: .35; cursor: default; background: #fff; }
button.danger { background: #fff; color: var(--err); border: 1px solid #f1c4c4; }
button.danger:hover { background: var(--err-bg); }
.danger-zone { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); }
h3 { font-size: 15px; margin: 0 0 8px; }

/* Lecteurs PDF et vidéo */
.player-note { flex: none; background: #22344f; color: #dfe7f1; font-size: 13px; padding: 6px 16px; }
.player-note a { color: #8fe0d3; }
.video-wrap { flex: 1; display: flex; align-items: center; justify-content: center; background: #000; min-height: 0; }
.video-wrap video { max-width: 100%; max-height: 100%; }

/* Tableau de bord : jusqu'à 6 encadrés sur une ligne, noms d'espace lisibles */
.kpis { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.kpis .kpi:nth-child(6) { border-top-color: var(--teal); }
td.nom-espace { white-space: nowrap; }
.wrap { max-width: 1320px; }
table.wrap-head th { white-space: normal; vertical-align: bottom; }

/* Boutons Tous / Aucun */
.check-all { display: inline-flex; gap: 4px; margin-left: 10px; vertical-align: middle; }
.check-all button { background: #fff; color: var(--primary); border: 1px solid var(--line); padding: 2px 10px; font-size: 12px; font-weight: 500; }
.check-all button:hover { background: var(--accent-bg); }

/* Vue Logipren d'un espace (lecture seule) */
.view-as { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; background: var(--accent-bg); border: 1px solid #bfe9e1; border-radius: var(--radius); padding: 10px 16px; margin-bottom: 16px; font-size: 14px; }
.view-as label { margin: 0; display: flex; align-items: center; gap: 8px; }
.view-as select { min-width: 220px; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 20px; }
.tabs a { padding: 8px 14px; text-decoration: none; color: var(--muted); border-bottom: 3px solid transparent; margin-bottom: -1px; font-weight: 500; }
.tabs a[aria-current] { color: var(--navy); border-bottom-color: var(--teal); }
td.nowrap { white-space: nowrap; }

/* Pagination */
.pager { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin: 12px 0 24px; font-size: 14px; }
.pages { display: flex; align-items: center; gap: 4px; }
.pages a, .pages span { min-width: 34px; height: 34px; display: inline-grid; place-items: center; border-radius: 8px; padding: 0 8px; text-decoration: none; }
.pages a { border: 1px solid var(--line); background: var(--surface); color: var(--navy); }
.pages a:hover { background: var(--accent-bg); border-color: #bfe9e1; }
.pages .current { background: var(--gradient); color: #fff; font-weight: 600; }
.pages .off { color: #c3cad4; border: 1px solid var(--line); }
.pages .gap { min-width: 20px; color: var(--muted); }
.pager label { margin: 0; display: flex; align-items: center; gap: 6px; }
.pager label select { width: auto; display: inline-block; margin: 0; }
.pager label { white-space: nowrap; }

/* Encadré d'espace : deux lignes */
.view-as { display: block; }
.view-as p { margin: 0 0 8px; }
.view-as .sep { color: #9fb8b2; margin: 0 10px; }
.view-as label { display: inline-flex; white-space: nowrap; }
.view-as label select { width: auto; display: inline-block; margin: 0; }

.tag { display: inline-block; background: var(--accent-bg); color: var(--ok); border-radius: 6px; padding: 0 6px; font-size: 11px; font-weight: 600; }
.sep-v { width: 1px; align-self: stretch; background: var(--line); margin: 0 4px; }
form.inline-edit { display: flex; gap: 6px; margin: 0; }
form.inline-edit input { max-width: 260px; }
form.panel.filters input[name=nom] { min-width: 280px; }

/* Graphiques : entonnoir et décrochage par étape (une teinte, du clair au foncé) */
:root { --seq-1: #9fd3e0; --seq-2: #3a9fbf; --seq-3: #145f80; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 16px; font-size: 13px; color: var(--muted); margin: 0 0 10px; }
.chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
.sw { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
.sw-1 { background: var(--seq-1); } .sw-2 { background: var(--seq-2); } .sw-3 { background: var(--seq-3); }
.funnel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 16px; margin-bottom: 24px; }
.funnel-row, .step-stat { display: grid; grid-template-columns: minmax(160px, 1.2fr) minmax(200px, 2fr) minmax(220px, 1.6fr); gap: 16px; align-items: center; padding: 10px 0; border-bottom: 1px solid #f0f2f5; }
.funnel > :last-child { border-bottom: 0; }
.funnel-label { font-weight: 600; font-size: 14px; }
.funnel-label small { font-weight: 400; }
.funnel-values { font-size: 13px; color: var(--muted); }
.funnel-values b { color: var(--navy); }
.funnel-track { position: relative; height: 18px; background: #f3f5f8; border-radius: 4px; }
.fb { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 0 4px 4px 0; box-shadow: 2px 0 0 var(--surface); }
.fb-1 { background: var(--seq-1); } .fb-2 { background: var(--seq-2); } .fb-3 { background: var(--seq-3); }
.step-stat.optional .funnel-label { color: var(--muted); }
.small-num { width: 22px; height: 22px; font-size: 12px; display: inline-grid; margin-right: 8px; vertical-align: middle; }
.loss { display: block; color: var(--err); font-weight: 600; margin-top: 2px; }
/* Infobulle au survol (le texte est aussi visible à côté de la barre) */
[data-tip]:hover::after { content: attr(data-tip); position: absolute; left: 0; bottom: calc(100% + 6px); background: var(--navy); color: #fff; font-size: 12px; padding: 6px 10px; border-radius: 6px; white-space: nowrap; z-index: 5; pointer-events: none; }
@media (max-width: 760px) { .funnel-row, .step-stat { grid-template-columns: 1fr; gap: 6px; } }

/* Bouton Déconnexion */
.me form button.logout { background: var(--gradient); color: #fff; border: 0; border-radius: 999px; padding: 6px 14px; font-size: 13px; font-weight: 600; text-decoration: none; }
.me form button.logout:hover { filter: brightness(1.08); }

/* Attestation de suivi : page A4 imprimable */
body.attestation-page { background: #e9edf2; }
.att-toolbar { max-width: 210mm; margin: 20px auto 12px; display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 0 8px; }
.att-sheet { background: #fff; width: 210mm; min-height: 297mm; margin: 0 auto 40px; padding: 16mm 16mm 14mm; box-shadow: 0 6px 30px rgba(22, 38, 63, .12); position: relative; display: flex; flex-direction: column; color: var(--navy); }
.att-sheet::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px; background: linear-gradient(90deg, var(--blue), var(--teal) 60%, var(--violet) 85%, var(--coral)); }
.att-head { display: flex; justify-content: space-between; align-items: flex-start; border-bottom: 1px solid var(--line); padding-bottom: 8mm; }
.att-head img { width: 44mm; height: auto; }
.att-head-right { text-align: right; display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: var(--muted); }
.att-head-right b { font-size: 17px; color: var(--navy); letter-spacing: .01em; }
.att-who { text-align: center; margin: 10mm 0 8mm; font-size: 14px; }
.att-who p { margin: 4px 0; }
.att-name { font-size: 26px; font-weight: 700; margin: 8px 0 2px !important; background: linear-gradient(90deg, var(--blue), var(--teal)); -webkit-background-clip: text; background-clip: text; color: transparent; }
.att-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5mm; margin-bottom: 8mm; }
.att-kpis div { border: 1px solid var(--line); border-top: 3px solid var(--teal); border-radius: 8px; padding: 10px 12px; text-align: center; }
.att-kpis div:nth-child(2) { border-top-color: var(--blue); }
.att-kpis div:nth-child(3) { border-top-color: var(--violet); }
.att-kpis b { display: block; font-size: 22px; }
.att-kpis span { font-size: 12px; color: var(--muted); }
.att-table { width: 100%; border-collapse: collapse; font-size: 12px; }
.att-table th { text-align: left; color: var(--muted); font-weight: 600; border-bottom: 2px solid var(--navy); padding: 6px 6px; background: none; white-space: normal; }
.att-table td { border-bottom: 1px solid var(--line); padding: 8px 6px; vertical-align: top; }
.att-table .num { text-align: right; white-space: nowrap; }
.att-table td small { display: block; margin-top: 3px; font-size: 11px; }
.att-badge { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 11px; background: var(--wip-bg); color: var(--wip); white-space: nowrap; }
.att-badge.done { background: var(--ok-bg); color: var(--ok); }
.att-note { font-size: 11px; color: var(--muted); margin-top: 6mm; }
.att-foot { margin-top: auto; padding-top: 10mm; display: grid; grid-template-columns: 2fr 1fr; gap: 8mm; }
.att-visa { border: 1px dashed #b9c3cf; border-radius: 8px; height: 26mm; padding: 6px 10px; font-size: 11px; color: var(--muted); }
@media (max-width: 820px) { .att-sheet { width: auto; min-height: 0; margin: 0 8px 24px; padding: 20px; } .att-kpis { grid-template-columns: 1fr; } }
@media print {
  @page { size: A4; margin: 0; }
  body.attestation-page { background: #fff; }
  .att-toolbar { display: none; }
  .att-sheet { box-shadow: none; margin: 0; width: 210mm; min-height: 297mm; }
  .att-sheet, .att-name, .att-kpis div, .att-badge { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

th.th-check .check-all { margin-left: 0; }
th.th-check .check-all button { padding: 1px 6px; }
.attest-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 24px; padding-top: 16px; border-top: 1px solid var(--line); }

/* Groupes métiers : cartes avec leurs formations */
.group-list { display: grid; gap: 12px; margin-bottom: 16px; }
.group-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.group-head { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.group-head .push-right { margin-left: auto; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 0 4px; }
.chip { background: #eef6fb; color: var(--primary-dark); border: 1px solid #d5e8f2; border-radius: 999px; padding: 2px 10px; font-size: 12px; }
.origin { font-size: 11px; font-weight: 600; border-radius: 6px; padding: 2px 8px; }
.origin.logipren { background: var(--accent-bg); color: var(--ok); }
.origin.custom { background: var(--wip-bg); color: var(--wip); }
.origin.own { background: #eef0f3; color: var(--muted); }
.group-edit summary { cursor: pointer; color: var(--primary); font-size: 13px; margin-top: 6px; }
.group-edit form { margin-top: 10px; }

/* Logo + slogan en texte */
.lockup { display: inline-flex; flex-direction: column; align-items: center; gap: 6px; }
.lockup img { width: 100%; height: auto; }
.slogan { font-size: 15px; letter-spacing: .08em; color: var(--navy); white-space: nowrap; }
.slogan i { font-style: normal; margin: 0 .35em; }
.slogan .d1 { color: var(--teal); } .slogan .d2 { color: var(--coral); }
.login-brand .lockup { width: 260px; max-width: 80%; }
.att-head .lockup { width: 48mm; align-items: flex-start; }
.att-head .lockup img { width: 44mm; }
.att-head .slogan { font-size: 9.5px; }

/* Multi-organisations : nom de l'organisation à la connexion, adresse en sous-domaine */
.login-org { text-align: center; font-size: 18px; font-weight: 600; margin: 0 0 12px; }
body.login h2.login-sub { text-align: center; font-size: 15px; color: var(--muted); margin: 24px 0 8px; }
body.login p.center { text-align: center; margin-top: 18px; }
.slug-field { display: flex; align-items: center; gap: 4px; }
.slug-field input { flex: 1; min-width: 0; }
.slug-field span { color: var(--muted); white-space: nowrap; }
ul.plain { list-style: none; padding: 0; margin: 0 0 12px; }
ul.plain li { padding: 4px 0; border-bottom: 1px solid var(--line); }

/* Mode support Mila : bandeau toujours visible */
.support-banner { background: #fdecea; color: #7a1f16; border-bottom: 1px solid #f4847a; padding: 8px 16px; font-size: 14px;
  display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: center; position: sticky; top: 0; z-index: 10; }
.support-banner form { margin: 0; }
.support-banner button { background: #7a1f16; color: #fff; padding: 4px 12px; font-size: 13px; }
.support-cta { display: flex; flex-wrap: wrap; gap: 12px 24px; align-items: center; justify-content: space-between; }
.support-cta > div { flex: 1 1 320px; }
.support-cta h2 { margin-top: 0; }

/* Offres : encadré « Votre offre » et jauges de consommation */
.offre-box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin-bottom: 16px; }
.panel .offre-box { border: 0; padding: 0; margin-bottom: 8px; }
.offre-name { margin: 0 0 10px; }
.gauges { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px 24px; }
.gauge > span:first-child { display: block; font-size: 12px; color: var(--muted); }
.gauge b { font-size: 15px; }
.gauge small { display: inline; margin-left: 6px; }
.gauge-bar { display: block; height: 6px; background: #eef2f6; border-radius: 3px; margin-top: 6px; overflow: hidden; }
.gauge-bar span { display: block; height: 100%; background: var(--primary); }
.gauge.warn .gauge-bar span { background: #e9a23b; }
.gauge.full .gauge-bar span { background: #d9534f; }
.gauge.full b { color: #b52b27; }
.over { color: #b52b27; font-weight: 600; }
.panel.watch { border-left: 4px solid #e9a23b; }
.panel.watch h2 { margin-top: 0; }

/* Quiz */
form.quiz { max-width: 760px; }
.quiz-q { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; margin: 0 0 14px; }
.quiz-q legend { font-weight: 700; padding: 0 6px; }
.quiz-enonce { font-weight: 600; margin: 0 0 8px; white-space: pre-line; }
.quiz-choice { padding: 6px 0; }
.quiz-trous { line-height: 2.4; white-space: pre-line; }
.quiz-blank { width: 11em; max-width: 100%; display: inline-block; padding: 4px 8px; margin: 0 2px; }
.quiz-assoc label { display: grid; grid-template-columns: 1fr minmax(160px, 1fr); gap: 12px; align-items: center; padding: 6px 0; border-bottom: 1px solid var(--line); }
@media (max-width: 560px) { .quiz-assoc label { grid-template-columns: 1fr; gap: 4px; } }
.quiz-score { display: flex; align-items: center; gap: 16px; border-radius: var(--radius); padding: 16px 20px; margin: 8px 0 16px; }
.quiz-score b { font-size: 34px; }
.quiz-score.ok { background: var(--ok-bg); color: var(--ok); }
.quiz-score.ko { background: var(--wip-bg); color: var(--wip); }
.quiz-ok { color: var(--ok); font-weight: 600; }
.quiz-mid { color: #9a6700; font-weight: 600; }
.quiz-ko { color: var(--err); font-weight: 600; }
.quiz-corr { list-style: none; padding: 0; margin: 0; }
.quiz-corr li { padding: 3px 0; }
.quiz-corr .good, .quiz-trous .good { color: var(--ok); }
.quiz-corr .bad, .quiz-trous .bad { color: var(--err); }
.quiz-expl { background: #f5f8fb; border-left: 3px solid var(--primary); padding: 8px 12px; margin: 10px 0 0; font-size: 14px; }
.quiz-card .step-body b { white-space: pre-line; }

/* Quiz : écran de résultat « à la Genially » */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.qr { position: relative; display: grid; grid-template-columns: auto 1fr; gap: 28px; align-items: center; margin: 8px 0 28px; padding: 28px 32px;
  border-radius: 20px; overflow: hidden; background: linear-gradient(135deg, #eafaf7 0%, #eef5fb 55%, #f2effd 100%); box-shadow: 0 18px 40px -24px rgba(22, 38, 63, .45); }
.qr::before { content: ""; position: absolute; inset: auto -60px -80px auto; width: 240px; height: 240px; border-radius: 50%;
  background: radial-gradient(circle, rgba(123, 101, 230, .18), transparent 70%); pointer-events: none; }
.qr-presque, .qr-courage { background: linear-gradient(135deg, #fff4ef 0%, #fdf7ec 60%, #f3f0fb 100%); }
.qr-ring { position: relative; width: 168px; height: 168px; }
.qr-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.qr-track { fill: none; stroke: rgba(22, 38, 63, .08); stroke-width: 12; }
.qr-bar { fill: none; stroke: url(#qr-grad); stroke-width: 12; stroke-linecap: round; stroke-dasharray: 326.73;
  stroke-dashoffset: calc(326.73 * (1 - var(--pct) / 100)); transition: stroke-dashoffset 1.2s cubic-bezier(.22, 1, .36, 1); }
.qr-presque .qr-bar, .qr-courage .qr-bar { stroke: #f4847a; }
.qr-num { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: var(--navy); }
.qr-num b { font-size: 52px; font-weight: 800; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.qr-num span { font-size: 22px; font-weight: 700; margin: 14px 0 0 2px; opacity: .6; }
.qr-text { position: relative; z-index: 1; }
.qr-emoji { font-size: 44px; line-height: 1; margin: 0 0 6px; transform: scale(0); transform-origin: 30% 80%; }
.qr-done .qr-emoji { animation: qr-pop .6s cubic-bezier(.34, 1.56, .64, 1) forwards; }
.qr-title { font-size: 34px; margin: 0 0 6px; letter-spacing: -.02em;
  background: linear-gradient(90deg, #1a7aa3, #7b65e6); -webkit-background-clip: text; background-clip: text; color: transparent; }
.qr-presque .qr-title, .qr-courage .qr-title { background: linear-gradient(90deg, #d4644f, #b5552e); -webkit-background-clip: text; background-clip: text; }
.qr-text > p { margin: 0 0 10px; font-size: 16px; }
.qr-stats { display: flex; flex-wrap: wrap; gap: 8px; }
.qr-stats span { background: rgba(255, 255, 255, .75); border: 1px solid rgba(22, 38, 63, .08); border-radius: 999px; padding: 4px 12px; font-size: 13px; color: var(--muted); }
.qr-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px !important; }
.qr-actions .btn { padding: 12px 22px; font-size: 15px; border-radius: 999px; }
.qr-actions .btn:not(.secondary-btn) { background: linear-gradient(90deg, #1a7aa3, #7b65e6); border: 0; box-shadow: 0 8px 18px -8px rgba(123, 101, 230, .7); }
.qr-presque .qr-actions .btn:not(.secondary-btn), .qr-courage .qr-actions .btn:not(.secondary-btn) { background: linear-gradient(90deg, #f4847a, #e9a23b); box-shadow: 0 8px 18px -8px rgba(244, 132, 122, .8); }
.qr-actions .btn:hover { transform: translateY(-1px); }
.qr-sound { position: absolute; top: 12px; right: 12px; z-index: 2; width: 38px; height: 38px; border-radius: 50%; padding: 0;
  background: rgba(255, 255, 255, .85); border: 1px solid rgba(22, 38, 63, .1); font-size: 17px; cursor: pointer; }
.qr-confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 50; }
@keyframes qr-pop { 0% { transform: scale(0) rotate(-20deg); } 100% { transform: scale(1) rotate(0); } }
@media (max-width: 640px) {
  .qr { grid-template-columns: 1fr; justify-items: center; text-align: center; padding: 24px 18px; gap: 16px; }
  .qr-stats, .qr-actions { justify-content: center; }
  .qr-emoji { transform-origin: 50% 80%; }
  .qr-title { font-size: 28px; }
}
@media (prefers-reduced-motion: reduce) { .qr-bar { transition: none; } .qr-emoji { transform: none; } .qr-done .qr-emoji { animation: none; } }

/* Correction en cartes */
.qr-corr-title { margin-top: 8px; }
.qr-corr { display: grid; gap: 12px; max-width: 820px; }
.qc { background: var(--surface); border: 1px solid var(--line); border-left: 5px solid var(--line); border-radius: 14px; padding: 14px 18px; }
.qc-ok { border-left-color: #3fbfae; }
.qc-mid { border-left-color: #e9a23b; }
.qc-ko { border-left-color: #f4847a; }
.qc-head { display: flex; gap: 12px; align-items: flex-start; }
.qc-icon { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; color: #fff; }
.qc-ok .qc-icon { background: #3fbfae; }
.qc-mid .qc-icon { background: #e9a23b; }
.qc-ko .qc-icon { background: #f4847a; }
.qc-num { font-size: 13px; color: var(--muted); }
.qc-ok .qc-num b { color: var(--ok); }
.qc-ko .qc-num b { color: #b5452f; }
.qc-mid .qc-num b { color: #9a6700; }
.qc-enonce { margin: 2px 0 0; font-weight: 600; white-space: pre-line; }
.qc .quiz-corr, .qc .quiz-trous { margin: 10px 0 0 42px; }
.qc .quiz-corr li { display: flex; align-items: center; gap: 8px; padding: 4px 0; color: var(--text); }
.qc-box { flex: none; width: 20px; height: 20px; border-radius: 6px; border: 2px solid #cfd8e3; display: grid; place-items: center; font-size: 12px; font-weight: 800; }
.quiz-corr li.good .qc-box { border-color: #3fbfae; color: #0f6b5c; }
.quiz-corr li.bad .qc-box { border-color: #f4847a; color: #b5452f; }
.qc-tag { font-size: 12px; background: #dff5f0; color: #0f6b5c; border-radius: 999px; padding: 1px 8px; }
.quiz-corr li.bad .qc-tag { background: #fde8e2; color: #b5452f; }
.qc .quiz-expl { margin: 12px 0 0 42px; border-radius: 0 8px 8px 0; }
@media (max-width: 560px) { .qc .quiz-corr, .qc .quiz-trous, .qc .quiz-expl { margin-left: 0; } }
.qc .quiz-trous { line-height: 1.7; }

/* Quiz : passage une question à la fois (public/quiz-jeu.js) */
form.qz { max-width: 760px; }
/* Sans JavaScript : toutes les questions, un seul bouton « Valider » */
.qz-intro, .qz-top, .qz-prev, .qz-next { display: none; }
.qz-nav { display: flex; gap: 10px; justify-content: flex-end; margin-top: 8px; }
/* Avec JavaScript */
.qz-step .qz-intro { display: block; }
.qz-step .qz-intro[hidden], .qz-step .quiz-q[hidden], .qz-step .qz-nav [hidden] { display: none !important; }
.qz-step:not(.qz-started) .qz-nav { display: none; }
.qz-step.qz-started .qz-top { display: grid; }
.qz-step .qz-prev, .qz-step .qz-next { display: inline-flex; }
.qz-step .qz-prev { margin-right: auto; }

.qz-intro { text-align: center; padding: 40px 28px; border-radius: 20px; background: linear-gradient(135deg, #eafaf7 0%, #eef5fb 55%, #f2effd 100%);
  box-shadow: 0 18px 40px -24px rgba(22, 38, 63, .45); }
.qz-intro h2 { font-size: 30px; margin: 0 0 12px; background: linear-gradient(90deg, #1a7aa3, #7b65e6); -webkit-background-clip: text; background-clip: text; color: transparent; }
.qz-intro .qr-stats { justify-content: center; margin-bottom: 12px; }
.qz-intro-emoji { font-size: 52px; margin: 0 0 8px; animation: qz-float 3s ease-in-out infinite; }
@keyframes qz-float { 50% { transform: translateY(-6px) rotate(-4deg); } }
.qz-start, .qz-next, .qz-submit { border: 0; border-radius: 999px; padding: 12px 26px; font-size: 16px; font-weight: 700; color: #fff; cursor: pointer;
  background: linear-gradient(90deg, #1a7aa3, #7b65e6); box-shadow: 0 8px 18px -8px rgba(123, 101, 230, .7); transition: transform .15s, opacity .15s; }
.qz-start { font-size: 18px; padding: 14px 34px; margin-top: 8px; }
.qz-start:hover, .qz-next:not(:disabled):hover, .qz-submit:not(:disabled):hover { transform: translateY(-2px); }
.qz-next:disabled, .qz-submit:disabled { opacity: .4; cursor: not-allowed; box-shadow: none; }
.qz-submit { background: linear-gradient(90deg, #3fbfae, #1a7aa3); }
.qz-prev { border-radius: 999px; padding: 12px 20px; }

.qz-top { grid-template-columns: 1fr auto; align-items: center; gap: 8px 12px; margin-bottom: 14px; }
.qz-count { font-size: 14px; color: var(--muted); }
.qz-count b { color: var(--navy); font-size: 16px; }
.qz-top .qz-sound { position: static; }
.qz-progress { grid-column: 1 / -1; height: 8px; border-radius: 999px; background: rgba(22, 38, 63, .08); overflow: hidden; }
.qz-progress span { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, #3fbfae, #1a7aa3, #7b65e6); transition: width .45s cubic-bezier(.22, 1, .36, 1); }

.qz .quiz-q { border: 0; border-radius: 20px; padding: 26px 28px; margin: 0 0 16px; background: var(--surface); box-shadow: 0 14px 34px -22px rgba(22, 38, 63, .5); }
.qz-legend { font-size: 13px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: #7b65e6; padding: 0; margin-bottom: 6px; float: left; width: 100%; }
.qz .quiz-enonce { clear: both; font-size: 21px; line-height: 1.35; margin: 0 0 4px; color: var(--navy); }
.qz-consigne { clear: both; font-size: 13px; color: var(--muted); margin: 0 0 16px; }
.qz-step .qz-legend { display: none; }
.qz-choices { display: grid; gap: 10px; }
.qz .quiz-choice { position: relative; display: flex; align-items: center; gap: 14px; padding: 14px 16px; border: 2px solid var(--line); border-radius: 14px;
  background: #fff; cursor: pointer; font-size: 16px; transition: border-color .15s, background .15s, transform .1s; }
.qz .quiz-choice:hover { border-color: #b7c9e2; transform: translateY(-1px); }
.qz .quiz-choice input { position: absolute; opacity: 0; pointer-events: none; }
.qz-letter { flex: none; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; font-weight: 800;
  background: #eef2f8; color: var(--navy); transition: background .15s, color .15s; }
.qz .quiz-choice:has(input:checked) { border-color: #7b65e6; background: linear-gradient(135deg, #f5f3ff, #eef7fb); }
.qz .quiz-choice:has(input:checked) .qz-letter { background: linear-gradient(135deg, #1a7aa3, #7b65e6); color: #fff; }
.qz .quiz-choice:has(input:focus-visible) { outline: 3px solid rgba(123, 101, 230, .45); outline-offset: 2px; }
.qz[data-type="qcm"] .qz-letter, .qz .quiz-q[data-type="qcm"] .qz-letter { border-radius: 8px; }
.qz .quiz-trous { font-size: 19px; line-height: 2.3; }
.qz .quiz-blank { border: 0; border-bottom: 3px solid #b7c9e2; border-radius: 6px 6px 0 0; background: #f3f6fb; font-size: 18px; text-align: center; width: 9em; }
.qz .quiz-blank:focus { outline: none; border-bottom-color: #7b65e6; background: #f5f3ff; }
.qz .quiz-assoc label { grid-template-columns: 1fr minmax(180px, 1fr); border: 0; padding: 8px 0; }
.qz-gauche { font-weight: 600; background: #f3f6fb; border-radius: 12px; padding: 12px 14px; }
.qz .quiz-assoc select { padding: 12px; border-radius: 12px; border: 2px solid var(--line); font-size: 15px; }
.qz .quiz-assoc select:focus { border-color: #7b65e6; outline: none; }

.qz-in { animation: qz-in .35s cubic-bezier(.22, 1, .36, 1); }
.qz-in-back { animation: qz-in-back .35s cubic-bezier(.22, 1, .36, 1); }
@keyframes qz-in { from { opacity: 0; transform: translateX(40px); } }
@keyframes qz-in-back { from { opacity: 0; transform: translateX(-40px); } }
@media (max-width: 560px) {
  .qz .quiz-q { padding: 20px 16px; }
  .qz .quiz-enonce { font-size: 18px; }
  .qz-nav { position: sticky; bottom: 0; background: linear-gradient(transparent, var(--bg) 30%); padding: 14px 0 10px; }
  .qz .quiz-assoc label { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { .qz-intro-emoji { animation: none; } }

/* Parcours guidé : étapes verrouillées, ressources complémentaires */
.step.locked { opacity: .6; background: #f7f9fb; }
.step.locked .step-num { background: #eef2f6; }
.ressources-title { margin-top: 28px; }
.steps.ressources { list-style: none; padding: 0; }

/* Signalements */
.pill { display: inline-block; min-width: 20px; padding: 1px 7px; border-radius: 999px; background: #f4847a; color: #fff; font-size: 12px; font-weight: 700; text-align: center; }
.signal-list { display: grid; gap: 12px; }
.signal.nouveau { border-left: 4px solid #f4847a; }
.signal.traite { opacity: .75; }
.signal-meta { margin: 0 0 6px; font-size: 14px; }
.signal-msg { white-space: pre-line; margin: 0 0 8px; font-size: 15px; }

/* Quiz : image cliquable (apprenant, correction, éditeur) et pictogrammes */
.qz-zones { position: relative; width: 100%; max-width: 900px; border-radius: 12px; overflow: hidden; background: #eef2f6; user-select: none; }
.qz-zones img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; pointer-events: none; }
.qz-zone { position: absolute; display: block; border: 3px solid #7b65e6; border-radius: 8px; background: rgba(123, 101, 230, .08); cursor: pointer;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .8); transition: background .15s, transform .1s; }
.qz-zone:hover { background: rgba(123, 101, 230, .18); }
.qz-zone input { position: absolute; opacity: 0; pointer-events: none; }
.qz-zone-num { position: absolute; top: -12px; left: -12px; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: #7b65e6; color: #fff; font-size: 13px; font-weight: 800; box-shadow: 0 2px 6px rgba(22, 38, 63, .3); }
.qz-zone:has(input:checked) { background: rgba(26, 122, 163, .28); border-color: #1a7aa3; }
.qz-zone:has(input:checked) .qz-zone-num { background: linear-gradient(135deg, #1a7aa3, #7b65e6); transform: scale(1.15); }
.qz-zone:has(input:focus-visible) { outline: 3px solid rgba(123, 101, 230, .55); outline-offset: 3px; }
.qc-zones .qz-zones { max-width: 640px; }
.qc .qc-zones { margin: 10px 0 0 42px; }
.qz-zone.good { border-color: #3fbfae; background: rgba(63, 191, 174, .22); cursor: default; }
.qz-zone.good .qz-zone-num { background: #3fbfae; }
.qz-zone.bad { border-color: #f4847a; background: rgba(244, 132, 122, .22); cursor: default; }
.qz-zone.bad .qz-zone-num { background: #f4847a; }
.qc-zones .qz-zone:not(.good):not(.bad) { opacity: .5; cursor: default; }
@media (max-width: 560px) { .qc .qc-zones { margin-left: 0; } }

.ze-wrap { margin: 12px 0; }
.ze { cursor: crosshair; margin: 8px 0; touch-action: none; }
.ze-zone { position: absolute; border: 3px dashed #7b65e6; border-radius: 8px; background: rgba(123, 101, 230, .1); cursor: pointer; }
.ze-zone.good { border: 3px solid #3fbfae; background: rgba(63, 191, 174, .25); }
.ze-zone.good .qz-zone-num { background: #3fbfae; }
.ze-zone.ghost { border-style: dotted; pointer-events: none; }
.ze-del { position: absolute; top: -12px; right: -12px; width: 24px; height: 24px; border-radius: 50%; padding: 0; border: 0;
  background: #f4847a; color: #fff; font-weight: 800; line-height: 1; cursor: pointer; }

.qz-picto { width: 64px; height: 64px; object-fit: contain; display: block; }
.qz-gauche.has-img { display: flex; justify-content: center; padding: 8px; background: #fff; border: 2px solid var(--line); }
.qc-picto .qz-picto { width: 36px; height: 36px; display: inline-block; vertical-align: middle; }
.pictos { margin: 6px 0 14px; }
.picto-row { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.picto-row .qz-picto { width: 40px; height: 40px; }
.picto-vide { width: 40px; height: 40px; display: grid; place-items: center; background: #f3f6fb; border-radius: 8px; opacity: .6; }
.picto-row input[type=file] { max-width: 220px; font-size: 13px; }

/* Lecteur Mila : barre commune à toutes les étapes (public/lecteur.js) */
.player-bar { height: auto; min-height: 56px; gap: 12px; padding: 8px 16px; background: var(--navy); position: relative; z-index: 5;
  box-shadow: 0 2px 0 0 transparent; border-bottom: 3px solid transparent;
  border-image: linear-gradient(90deg, #3fbfae, #1a7aa3, #7b65e6, #f4847a) 1; }
.pb-quit { flex: none; color: #8fe0d3 !important; text-decoration: none; font-size: 14px; white-space: nowrap; }
.pb-title { flex: 1; min-width: 0; display: flex; flex-direction: column; line-height: 1.25; }
.pb-title small { display: block; color: #9fb3c8; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pb-title b { color: #fff; font-size: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pb-nav { flex: none; display: flex; gap: 8px; align-items: center; }
.pb-btn { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; padding: 8px 16px; font-size: 14px; font-weight: 600;
  text-decoration: none; color: #fff !important; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .18); cursor: pointer; white-space: nowrap; }
.pb-btn:hover { background: rgba(255, 255, 255, .18); }
.pb-next { background: linear-gradient(90deg, #3fbfae, #1a7aa3); border: 0; }
.pb-next.locked { background: rgba(255, 255, 255, .08); color: #9fb3c8 !important; border: 1px dashed rgba(255, 255, 255, .25); cursor: not-allowed; }
.pb-next.locked::before { content: "🔒"; font-size: 12px; }
.pb-next.pulse { animation: pb-pulse 1.6s ease-in-out 3; }
.pb-full { padding: 8px 12px; font-size: 16px; line-height: 1; }
.shake { animation: pb-shake .4s; }
@keyframes pb-pulse { 50% { box-shadow: 0 0 0 6px rgba(63, 191, 174, .35); } }
@keyframes pb-shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }
.pb-toast { position: fixed; top: 70px; right: 16px; z-index: 20; display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
  background: #fff; color: var(--navy); border-radius: 14px; padding: 12px 16px; box-shadow: 0 16px 40px -12px rgba(22, 38, 63, .5);
  transform: translateY(-12px); opacity: 0; transition: transform .35s, opacity .35s; max-width: calc(100vw - 32px); }
.pb-toast.show { transform: none; opacity: 1; }
.pb-toast a { font-weight: 700; color: #1a7aa3; }
@media (max-width: 640px) {
  .pb-quit span, .pb-btn span, .pb-title small { display: none; }
  .pb-btn { padding: 8px 12px; }
}

/* Étapes qui défilent dans le lecteur (quiz, lien, document) : contenu centré, fond clair */
body.player-page { background: var(--bg); }
.player-scroll { flex: 1; overflow-y: auto; }
.player-inner { max-width: 860px; margin: 0 auto; padding: 28px 20px 48px; }
.player-inner form.qz { margin: 0 auto; }
.player-inner .qr, .player-inner .qr-corr { margin-left: auto; margin-right: auto; }
.player-inner .qr-corr-title { max-width: 820px; margin-left: auto; margin-right: auto; }
.pb-ouvrir { text-align: center; padding: 48px 24px; border-radius: 20px; background: linear-gradient(135deg, #eafaf7 0%, #eef5fb 55%, #f2effd 100%); }
.pb-ouvrir-ic { font-size: 48px; margin: 0; }
.pb-ouvrir h1 { margin: 8px 0 10px; }
.pb-ouvrir-btn { border-radius: 999px; padding: 12px 26px; font-size: 16px; background: linear-gradient(90deg, #1a7aa3, #7b65e6); border: 0; }
.modele-existants { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }

/* Quiz dans le lecteur : tout voir sans faire défiler */
.player-page .player-inner:has(.qz-started) { padding-top: 14px; padding-bottom: 0; }
.qz-started .qz-top { margin-bottom: 10px; }
.qz-started .quiz-q { padding: 20px 24px; margin-bottom: 0; }
.qz-started .quiz-enonce { font-size: 20px; }
.qz-started .qz-consigne { margin-bottom: 12px; }
.qz-started .qz-choices { gap: 8px; }
.qz-started .quiz-choice { padding: 11px 14px; }
.qz-started .qz-zones { margin: 0 auto; }
/* Boutons Précédent / Suivant / Valider toujours visibles en bas */
.qz-step.qz-started .qz-nav { position: sticky; bottom: 0; z-index: 3; margin: 0; padding: 14px 0 16px;
  background: linear-gradient(rgba(246, 248, 251, 0), var(--bg) 35%); }
