/* kpmg_survey — charte KPMG : bleu KPMG #00338D, bleus secondaires, gris froids, Arial.
   Aucun style en ligne (CSP) : tout est ici. */
:root {
  --encre: #0C233C;
  --bouton: #00338D;
  --bouton-actif: #005EB8;
  --accent: #005EB8;
  --accent-fonce: #00338D;
  --accent-doux: #E8F0FA;
  --fond: #F4F6F9;
  --carte: #FFFFFF;
  --trait: #DDE3EB;
  --trait-fort: #C3CCD8;
  --discret: #56606E;
  --texte2: #3B4554;
  --orange: #A04E00;
  --orange-doux: #FCEFDF;
  --rouge: #A3271B;
  --titres: Arial, "Helvetica Neue", Helvetica, sans-serif;
  --corps: Arial, "Helvetica Neue", Helvetica, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--fond); color: var(--encre); font-family: var(--corps); font-size: 16px; line-height: 1.5; }
a { color: var(--accent); }
a:hover { color: var(--accent-fonce); }
h1, h2, h3 { font-family: var(--titres); font-weight: 600; letter-spacing: 0; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.visuellement-cache { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ------------------------------------------------------------------ participant */
.page { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; max-width: 600px; margin: 0 auto; }
.entete { padding: 20px 24px; display: flex; align-items: center; gap: 10px; }
.organisation { font-weight: 700; font-size: 15px; letter-spacing: 0.01em; }
.contenu { flex-grow: 1; padding: 8px 24px 0; display: flex; flex-direction: column; gap: 22px; }
.pied { padding: 16px 24px 28px; display: flex; flex-direction: column; gap: 12px; }
.surtitre { font-size: 13px; font-weight: 600; color: var(--accent); text-transform: uppercase; letter-spacing: 0.08em; }
.grand-titre { margin: 0; font-size: 30px; line-height: 1.15; }
.chapo { margin: 0; font-size: 16px; line-height: 1.6; color: var(--texte2); white-space: pre-line; }
.petit { margin: 0; font-size: 13px; line-height: 1.5; color: var(--discret); }
.carte { background: var(--carte); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.point { display: flex; gap: 14px; align-items: flex-start; }
.pastille { flex-shrink: 0; width: 36px; height: 36px; border-radius: 10px; background: var(--accent-doux); color: var(--accent);
  display: flex; align-items: center; justify-content: center; }
.point strong { display: block; font-size: 15px; font-weight: 600; }
.point span { font-size: 14px; line-height: 1.45; color: var(--discret); }

.bouton { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 54px; padding: 0 20px;
  border-radius: 14px; border: 0; background: var(--bouton); color: #FFFFFF; font: 600 16px var(--corps);
  text-decoration: none; cursor: pointer; }
.bouton:hover { background: var(--bouton-actif); color: #FFFFFF; }
.bouton.plein { width: 100%; }
.bouton.secondaire { background: var(--carte); color: var(--encre); border: 1.5px solid var(--trait-fort); }
.bouton.secondaire:hover { background: var(--fond); }

/* Question */
.barre-question { background: var(--carte); border-bottom: 1px solid var(--trait); padding: 12px 20px; display: flex; flex-direction: column; gap: 10px; }
.barre-haut { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; }
.retour { width: 44px; height: 44px; margin-left: -10px; display: flex; align-items: center; justify-content: center; color: var(--encre); }
.partie { font-size: 13px; font-weight: 600; color: var(--discret); text-align: center; flex: 1; }
.enregistre { display: flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; color: var(--accent); min-width: 80px; justify-content: flex-end; }
.progression { width: 100%; height: 6px; border: 0; border-radius: 3px; background: var(--trait); overflow: hidden; appearance: none; -webkit-appearance: none; display: block; }
.progression::-webkit-progress-bar { background: var(--trait); border-radius: 3px; }
.progression::-webkit-progress-value { background: var(--accent); border-radius: 3px; }
.progression::-moz-progress-bar { background: var(--accent); border-radius: 3px; }
.compteur { font-size: 12px; color: var(--discret); }
.question { padding: 28px 20px 0; display: flex; flex-direction: column; gap: 22px; flex-grow: 1; }
.intitule { margin: 0; font-size: 23px; line-height: 1.3; }
.aide { margin: 6px 0 0; font-size: 14px; color: var(--discret); }
.options { border: 0; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.option { position: relative; display: flex; align-items: center; gap: 14px; min-height: 56px; padding: 12px 16px; border-radius: 14px;
  background: var(--carte); border: 1.5px solid var(--trait); font-size: 15px; font-weight: 500; cursor: pointer; }
.option input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.coche { flex-shrink: 0; width: 24px; height: 24px; border-radius: 12px; border: 2px solid #A3ACB8; background: var(--carte);
  display: flex; align-items: center; justify-content: center; }
.option.multiple .coche { border-radius: 6px; }
.coche svg { visibility: hidden; }
.option:has(input:checked) { border-color: var(--accent); background: var(--accent-doux); font-weight: 600; }
.option:has(input:checked) .coche { background: var(--accent); border-color: var(--accent); }
.option:has(input:checked) .coche svg { visibility: visible; }
.option:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }
.notes { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 8px; }
.note { position: relative; display: flex; align-items: center; justify-content: center; height: 52px; border-radius: 12px;
  background: var(--carte); border: 1.5px solid var(--trait); font-weight: 600; cursor: pointer; }
.note input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.note:has(input:checked) { background: var(--accent); border-color: var(--accent); color: #FFFFFF; }
.note:has(input:focus-visible) { outline: 3px solid var(--accent); outline-offset: 2px; }
.bornes { display: flex; justify-content: space-between; font-size: 13px; color: var(--discret); }
textarea.libre { width: 100%; min-height: 160px; padding: 14px 16px; border-radius: 14px; border: 1.5px solid var(--trait);
  font: 16px/1.5 var(--corps); color: var(--encre); background: var(--carte); resize: vertical; }
textarea.libre:focus { border-color: var(--accent); outline: none; }
.erreur { margin: 0; padding: 12px 14px; border-radius: 12px; background: #FBEAE8; color: var(--rouge); font-size: 14px; font-weight: 600; }
.navigation { padding: 16px 20px 28px; display: flex; gap: 12px; }
.navigation .suivant { order: 2; flex: 2 1 0; }
.navigation .precedent { order: 1; flex: 1 1 0; }
.facultatif { font-size: 13px; color: var(--discret); }

/* Reprise */
.avancement { display: flex; align-items: center; gap: 20px; }
.etapes { display: flex; flex-direction: column; gap: 12px; }
.etape { display: flex; align-items: center; gap: 12px; font-size: 15px; color: var(--discret); }
.etape.courante { color: var(--encre); font-weight: 600; }
.rond { flex-shrink: 0; width: 24px; height: 24px; border-radius: 12px; border: 2px solid #A3ACB8; display: flex; align-items: center; justify-content: center; }
.etape.faite .rond { background: var(--accent); border-color: var(--accent); }
.etape.courante .rond { border-color: var(--accent); }
.etape.courante .rond::after { content: ""; width: 10px; height: 10px; border-radius: 5px; background: var(--accent); }

/* Fin */
.centre { flex-grow: 1; padding: 0 24px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 24px; text-align: center; }
.medaille { width: 96px; height: 96px; border-radius: 48px; background: var(--accent-doux); display: flex; align-items: center; justify-content: center; }
.medaille span { width: 64px; height: 64px; border-radius: 32px; background: var(--accent); display: flex; align-items: center; justify-content: center; }
.liste-manquantes { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.liste-manquantes a { display: block; padding: 12px 14px; border-radius: 12px; background: var(--carte); border: 1.5px solid var(--trait); text-decoration: none; color: var(--encre); font-size: 14px; }

/* ------------------------------------------------------------------ admin */
.admin { display: flex; flex-wrap: wrap; min-height: 100vh; }
.menu { flex: 1 1 220px; max-width: 100%; background: var(--encre); color: #FFFFFF; padding: 24px 16px; display: flex; flex-direction: column; gap: 6px; }
.menu .marque { padding: 0 8px 20px; font-family: var(--titres); font-size: 20px; font-weight: 600; }
.menu a, .menu button { padding: 11px 12px; border-radius: 10px; color: #CDD4DE; font: 14px var(--corps); text-decoration: none; background: none; border: 0; text-align: left; cursor: pointer; }
.menu a.actif, .menu a:hover, .menu button:hover { background: rgba(255, 255, 255, 0.1); color: #FFFFFF; }
.menu form { margin-top: auto; display: flex; flex-direction: column; }
.principal { flex: 999 1 560px; min-width: 0; padding: 32px; display: flex; flex-direction: column; gap: 24px; }
.ligne-titre { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px; }
.ligne-titre h1 { margin: 0; font-size: 28px; }
.fil { font-size: 13px; color: var(--discret); }
.fil a { color: var(--discret); }
.actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 16px; border-radius: 10px;
  border: 0; background: var(--bouton); color: #FFFFFF; font: 600 14px var(--corps); text-decoration: none; cursor: pointer; }
.btn:hover { background: var(--bouton-actif); color: #FFFFFF; }
.btn.clair { background: var(--carte); color: var(--encre); border: 1.5px solid var(--trait-fort); }
.btn.clair:hover { background: var(--fond); color: var(--encre); }
.btn.danger { background: var(--carte); color: var(--rouge); border: 1.5px solid #E7B7B1; }
.btn.petit-btn { min-height: 34px; padding: 0 10px; font-size: 13px; }
.chiffres { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 16px; }
.chiffre { background: var(--carte); border-radius: 14px; padding: 18px 20px; display: flex; flex-direction: column; gap: 6px; }
.chiffre span { font-size: 13px; color: var(--discret); }
.chiffre strong { font-size: 30px; font-weight: 700; }
.chiffre.termine strong { color: var(--accent); }
.chiffre.en-cours strong { color: var(--orange); }
.chiffre.pas-commence strong { color: var(--discret); }
.bloc { background: var(--carte); border-radius: 14px; padding: 20px; display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.bloc h2 { margin: 0; font-size: 19px; }
.colonnes { display: flex; flex-wrap: wrap; gap: 24px; align-items: flex-start; }
.colonnes > .large { flex: 999 1 520px; min-width: 0; }
.colonnes > .etroit { flex: 1 1 280px; min-width: 0; display: flex; flex-direction: column; gap: 16px; }
.legende { display: flex; flex-wrap: wrap; gap: 18px; font-size: 13px; color: var(--discret); }
.legende i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.legende .l-termine { background: var(--accent); } .legende .l-en-cours { background: #E8A35C; } .legende .l-reste { background: var(--trait); }
.defile { overflow-x: auto; }
table.tableau { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 14px; }
.tableau th { text-align: left; color: var(--discret); font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; padding: 10px 8px; border-bottom: 1px solid var(--trait); }
.tableau td { padding: 10px 8px; border-bottom: 1px solid #EEF1F5; vertical-align: middle; }
.tableau td.discret { color: var(--discret); }
.tableau form { display: inline; }
.badge { display: inline-block; padding: 4px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; white-space: nowrap; }
.badge.termine { background: var(--accent-doux); color: var(--accent-fonce); }
.badge.en-cours { background: var(--orange-doux); color: #8A4300; }
.badge.pas-commence { background: #EEF1F5; color: var(--texte2); }
.badge.pas-invite { background: var(--carte); color: var(--discret); border: 1px dashed var(--trait-fort); }
.badge.brouillon { background: #EEF1F5; color: var(--texte2); }
.badge.lancee { background: var(--accent-doux); color: var(--accent-fonce); }
.badge.close { background: var(--encre); color: #FFFFFF; }
.badge.echec { background: #FBEAE8; color: var(--rouge); }
.reglage { display: flex; justify-content: space-between; gap: 12px; font-size: 14px; }
.reglage span { color: var(--discret); }
.messages-flash { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; }
.messages-flash li { padding: 12px 16px; border-radius: 12px; background: var(--accent-doux); color: var(--accent-fonce); font-size: 14px; font-weight: 500; }
.erreurs { margin: 0; padding: 12px 16px 12px 32px; border-radius: 12px; background: #FBEAE8; color: var(--rouge); font-size: 14px; }
form.formulaire { display: flex; flex-direction: column; gap: 18px; max-width: 720px; }
.champ { display: flex; flex-direction: column; gap: 6px; }
.champ label, .champ .libelle { font-size: 14px; font-weight: 600; }
.champ small { font-size: 13px; color: var(--discret); }
.champ input[type=text], .champ input[type=email], .champ input[type=password], .champ input[type=date], .champ input[type=number],
.champ select, .champ textarea { min-height: 44px; padding: 10px 12px; border-radius: 10px; border: 1.5px solid var(--trait-fort);
  font: 15px var(--corps); color: var(--encre); background: var(--carte); width: 100%; }
.champ textarea { min-height: 100px; resize: vertical; }
.case { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; }
.case input { width: 20px; height: 20px; margin-top: 1px; accent-color: var(--accent); }
.deux { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; }
.depot { border: 2px dashed var(--trait-fort); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.depot input[type=file] { font: 14px var(--corps); max-width: 100%; }
.connexion { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 16px; }
.connexion .bloc { width: 100%; max-width: 400px; }
.apercu-email { border: 0; width: 100%; height: 900px; background: var(--fond); border-radius: 12px; }
.question-apercu { padding: 14px 0; border-bottom: 1px solid #EEF1F5; display: flex; gap: 14px; }
.question-apercu .num { flex-shrink: 0; width: 36px; color: var(--discret); font-weight: 600; }
.question-apercu .meta { font-size: 12px; color: var(--discret); }
.bandeau-apercu { background: var(--encre); color: #FFFFFF; padding: 8px 16px; font-size: 13px; text-align: center; }
.bandeau-apercu a { color: #C9DAF0; }

@media (max-width: 480px) {
  .principal { padding: 20px 16px; }
  .grand-titre { font-size: 27px; }
  .intitule { font-size: 21px; }
}

/* ------------------------------------------------------------------ arabe (de droite à gauche) */
[dir=rtl] body, [dir=rtl] .bouton, [dir=rtl] textarea.libre { font-family: "IBM Plex Sans Arabic", Tahoma, sans-serif; }
[dir=rtl] h1, [dir=rtl] h2, [dir=rtl] h3 { font-family: "IBM Plex Sans Arabic", Tahoma, sans-serif; font-weight: 700; }
[dir=rtl] .surtitre { letter-spacing: 0; }
[dir=rtl] .retour { margin-left: 0; margin-right: -10px; }
[dir=rtl] .bouton svg, [dir=rtl] .retour svg { transform: scaleX(-1); }
[dir=rtl] .enregistre { justify-content: flex-start; }
[dir=rtl] .progression { direction: rtl; }
[dir=rtl] .intitule, [dir=rtl] .grand-titre { line-height: 1.5; }
.chiffre-ltr { direction: ltr; unicode-bidi: isolate; }
.langues { margin-inline-start: auto; }
.langues a { display: inline-flex; align-items: center; min-height: 36px; padding: 0 12px; border-radius: 999px;
  border: 1.5px solid var(--trait-fort); color: var(--encre); text-decoration: none; font-size: 14px; font-weight: 600;
  font-family: "IBM Plex Sans Arabic", var(--corps); }
.langues a:hover { background: var(--carte); }
.bilingue { display: flex; flex-direction: column; gap: 28px; }

/* Résultats */
.barre-etats { display: block; width: 100%; min-width: 120px; height: 14px; border-radius: 3px; background: var(--trait); }
.tableau .col-barre { width: 34%; min-width: 140px; }
.tableau tr.ligne-globale td { border-top: 2px solid var(--trait-fort); font-weight: 600; }
.pastille-etat { display: inline-block; width: 12px; height: 12px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.pastille-etat[data-etat=A] { background: #2E7D5B; } .pastille-etat[data-etat=B] { background: #4C78A8; }
.pastille-etat[data-etat=C] { background: #D9893A; } .pastille-etat[data-etat=D] { background: #B5473A; }
.pastille-etat[data-etat=E] { background: #5F6B7A; }
.reponse-libre { margin: 0; padding: 12px 16px; border-radius: 10px; background: var(--fond); font-size: 14px; white-space: pre-line; }
details.bloc summary { cursor: pointer; }
ol.meta { margin: 6px 0; padding-inline-start: 22px; }

/* Consentement (page d'accueil) */
.consentement { display: flex; flex-direction: column; gap: 12px; }
.case-consentement { align-items: flex-start; font-size: 14px; font-weight: 500; line-height: 1.5; }
.case-consentement .coche { margin-top: 1px; }
.introduction { display: flex; flex-direction: column; gap: 12px; }
