/* lot E-Q — mise en scène de l'écran de résultat des QCM (qcm-*) et du bilan des TP (tp-*).
   Tout est rangé sous des classes posées par lote-resultat.js (leq-…) : sans le script, aucune règle ne s'applique.
   Aucun texte, aucune note, aucun seuil n'est produit ici : seulement du dessin. */

/* ---------- couleurs communes (reprises des variables de chaque famille de pages) ---------- */
.leq{--leq-c:var(--bad,#c8323f);--leq-bg:var(--bad-bg,#fce6e8);--leq-piste:var(--line,#d3dde0);--leq-grad:var(--muted,#5a6b74);--leq-or:#9a6400;--leq-lueur:#ffd34d}
.leq.leq-ok{--leq-c:var(--good,var(--ok,#1a8a4f));--leq-bg:var(--good-bg,var(--ok-bg,#e0f4e8))}
:root[data-theme="dark"] .leq{--leq-or:#ffd34d}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]) .leq{--leq-or:#ffd34d}}

/* ---------- cadran ---------- */
.leq-cadran{display:block;width:232px;height:172px;grid-area:1/1;pointer-events:none}
.leq-cadran svg{display:block;width:100%;height:100%;overflow:visible}
.leq-piste{fill:none;stroke:var(--leq-piste);stroke-width:13;stroke-linecap:round}
.leq-rempli{fill:none;stroke:var(--leq-c);stroke-width:13;stroke-linecap:round;stroke-dasharray:var(--leq-p,0) 200}
.leq-nul .leq-rempli{visibility:hidden}
.leq-grad line{stroke:var(--leq-grad);stroke-width:1.3;stroke-linecap:round;opacity:.75}
.leq-grad line.leq-g5{stroke-width:2;opacity:1}
.leq-seuil{fill:var(--leq-or);stroke:none}
.leq-aig{transform-box:view-box;transform-origin:120px 112px;transform:rotate(var(--leq-a,0deg))}
.leq-aig line{stroke:var(--ink,#18232b);stroke-width:4.5;stroke-linecap:round}
.leq-aig circle{fill:var(--surface,#fff);stroke:var(--ink,#18232b);stroke-width:2.2}

/* la note du site, inchangée, vient se loger au centre du cadran */
.leq .leq-zone{display:grid!important;grid-template-columns:232px minmax(0,1fr);align-items:center;gap:6px 22px}
.leq .leq-zone>.leq-note{grid-area:1/1;justify-self:center;align-self:center;margin:26px 0 0;white-space:nowrap;text-align:center;line-height:1}
.leq .leq-zone>.big.leq-note{font-size:38px}
.leq .leq-zone>.bnote.leq-note{font-size:46px!important}
.leq .leq-zone>.big.leq-note.leq-court{font-size:46px}
.leq .leq-zone>.bnote.leq-note.leq-court{font-size:54px!important}
.leq .leq-zone>:not(.leq-cadran):not(.leq-note){grid-column:2}
@media (max-width:560px){
  .leq .leq-zone{grid-template-columns:minmax(0,1fr);justify-items:center;text-align:center}
  .leq .leq-zone>:not(.leq-cadran):not(.leq-note){grid-column:1}
  .leq .leq-zone>.tpv-who{align-items:center}
  .leq .leq-zone{gap:0}
  .leq .leq-zone>:not(.leq-cadran):not(.leq-note){margin-top:-10px}
}

/* ---------- verdict : petit dessin (ampoule éteinte / allumée / allumée et rayonnante) ---------- */
.leq .leq-verdict{position:relative;padding-left:70px!important;min-height:64px;display:block;box-sizing:border-box;border-left:5px solid var(--leq-c)}
.leq .leq-verdict::before,.leq .leq-verdict::after{content:"";position:absolute;left:9px;top:50%;width:50px;height:50px;margin-top:-25px;-webkit-mask:var(--leq-m) center/contain no-repeat;mask:var(--leq-m) center/contain no-repeat}
.leq .leq-verdict::before{background:currentColor;--leq-m:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19 33c0-4-6-6.500-6-13.500a11 11 0 0 1 22 0c0 7-6 9.500-6 13.500z'/%3E%3Cpath d='M19 33v5.500a2 2 0 0 0 2 2h6a2 2 0 0 0 2-2V33M19.500 36.700h9M22 43.500h4'/%3E%3Cpath d='M21.500 33l-1.300-9.500c2.500-2.600 2.500 2.600 3.800 0s1.300 2.600 3.800 0L26.500 33' stroke-width='1.500'/%3E%3C/svg%3E")}
.leq .leq-verdict::after{background:radial-gradient(circle at 50% 38%,#fff3bf 0,#ffd34d 55%,#f0b21c 100%);opacity:0;z-index:0;--leq-m:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M19 33c0-4-6-6.500-6-13.500a11 11 0 0 1 22 0c0 7-6 9.500-6 13.500z'/%3E%3C/svg%3E")}
.leq .leq-verdict::before{z-index:1}
.leq.leq-ok .leq-verdict::after{opacity:.9}
/* allumée : rayons autour du verre */
.leq.leq-ok .leq-verdict::before{--leq-m:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19.500 33c0-3.500-4.500-5.500-4.500-11.500a9 9 0 0 1 18 0c0 6-4.500 8-4.500 11.500z'/%3E%3Cpath d='M19.500 33v5.500a2 2 0 0 0 2 2h5a2 2 0 0 0 2-2V33M20 36.700h8M22 43.500h4'/%3E%3Cpath d='M21.800 33l-1-8c2.100-2.400 2.100 2.400 3.200 0s1.100 2.400 3.200 0l-1 8' stroke-width='1.500'/%3E%3Cpath d='M24 4.500v4M10.500 9.500l2.700 2.900M37.500 9.500l-2.700 2.900M4.500 21.500h4M39.500 21.500h4M8.500 33l3.200-2.200M39.500 33l-3.200-2.200' stroke-width='1.800'/%3E%3C/svg%3E")}
.leq.leq-ok .leq-verdict::after{--leq-m:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48'%3E%3Cpath d='M19.500 33c0-3.500-4.500-5.500-4.500-11.500a9 9 0 0 1 18 0c0 6-4.500 8-4.500 11.500z'/%3E%3C/svg%3E")}
/* très bonne note : rayons doublés et deux éclats */
.leq.leq-ok.leq-top .leq-verdict::before{--leq-m:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 48' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M19.500 33c0-3.500-4.500-5.500-4.500-11.500a9 9 0 0 1 18 0c0 6-4.500 8-4.500 11.500z'/%3E%3Cpath d='M19.500 33v5.500a2 2 0 0 0 2 2h5a2 2 0 0 0 2-2V33M20 36.700h8M22 43.500h4'/%3E%3Cpath d='M21.800 33l-1-8c2.100-2.400 2.100 2.400 3.200 0s1.100 2.400 3.200 0l-1 8' stroke-width='1.500'/%3E%3Cpath d='M24 3v5.500M17 5.500l1.500 4M31 5.500l-1.500 4M9.500 8.500l3.700 3.900M38.500 8.500l-3.700 3.900M6 15.500l4.500 1.800M42 15.500l-4.500 1.800M3.500 23h5M39.500 23h5M8 34l3.700-2.600M40 34l-3.700-2.600' stroke-width='1.800'/%3E%3Cpath d='M6 40.500c1.800-.400 2.600-1.200 3-3 .400 1.800 1.200 2.600 3 3-1.800.400-2.600 1.200-3 3-.400-1.800-1.200-2.600-3-3zM37 41.500c1.500-.300 2.200-1 2.500-2.500.300 1.500 1 2.200 2.500 2.500-1.500.300-2.200 1-2.500 2.500-.300-1.500-1-2.200-2.500-2.500z' stroke-width='1.300' fill='%23000'/%3E%3C/svg%3E")}

/* ---------- QCM : carte de résultat ---------- */
.leq-qcm{border-top:4px solid var(--leq-c)!important}
.leq-qcm .br .bar{height:10px;border-radius:5px}
.leq-qcm .br .bar i{border-radius:5px;transform-origin:left center}
/* « À relire » : une carte par partie de fiche (les séparateurs « · » restent dans la page, sans largeur) */
.leq-qcm .leq-relire{font-size:0;line-height:0;margin:16px 0 0!important}
.leq-qcm .leq-relire>b{display:inline-block;width:100%;font-size:19px;line-height:1.3;margin:0 0 6px}
.leq-qcm .leq-relire>a{display:inline-block;vertical-align:top;box-sizing:border-box;width:calc(50% - 5px);margin:0 10px 8px 0;font-size:17px;line-height:1.3;font-weight:700;text-decoration:none;position:relative;padding:11px 34px 11px 46px;border-radius:11px;border:1px solid var(--line);border-left:4px solid var(--leq-or);background:var(--surface);color:var(--ink);box-shadow:0 1px 2px rgba(15,29,41,.06);transition:transform .15s,box-shadow .15s,border-color .15s}
.leq-qcm .leq-relire>a:nth-of-type(2n){margin-right:0}
.leq-qcm .leq-relire>a::before{content:"";position:absolute;left:13px;top:50%;width:22px;height:22px;margin-top:-11px;background:var(--leq-or);-webkit-mask:var(--leq-m) center/contain no-repeat;mask:var(--leq-m) center/contain no-repeat;--leq-m:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.700' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 6.500C10 5 7 4.500 3.500 5v13c3.500-.500 6.500 0 8.500 1.500 2-1.500 5-2 8.500-1.500V5C17 4.500 14 5 12 6.500zM12 6.500v13'/%3E%3Cpath d='M6.500 9c1.200 0 2.200.200 3 .600M6.500 12.300c1.200 0 2.200.200 3 .600M14.500 9.600c.800-.400 1.800-.600 3-.600M14.500 12.900c.800-.400 1.800-.600 3-.600' stroke-width='1.300'/%3E%3C/svg%3E")}
.leq-qcm .leq-relire>a::after{content:"";position:absolute;right:13px;top:50%;width:9px;height:9px;margin-top:-5px;border-right:2px solid var(--leq-or);border-top:2px solid var(--leq-or);transform:rotate(45deg);transition:right .15s}
.leq-qcm .leq-relire>a:hover{transform:translateY(-1px);box-shadow:0 4px 12px rgba(15,29,41,.12);border-color:var(--leq-or)}
.leq-qcm .leq-relire>a:hover::after{right:9px}
.leq-qcm .leq-relire>a:focus-visible{outline:3px solid var(--leq-or);outline-offset:2px}
@media (max-width:640px){.leq-qcm .leq-relire>a{width:100%;margin-right:0}}
/* boutons : l'action principale d'abord, plus présente ; l'autre en retrait */
.leq-qcm .leq-boutons{margin-top:18px!important;padding-top:14px;border-top:1px solid var(--line);gap:10px 12px}
.leq-qcm .leq-boutons .btn{min-height:46px;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;padding:10px 22px;border-radius:12px}
.leq-qcm .leq-boutons .btn:not(.ghost){box-shadow:0 2px 0 rgba(15,29,41,.18),0 6px 14px rgba(15,29,41,.10);font-size:1.05em}
.leq-qcm .leq-boutons .btn.ghost{font-weight:600}
.leq-qcm .leq-boutons .btn:focus-visible{outline:3px solid var(--leq-or);outline-offset:2px}
@media (max-width:560px){.leq-qcm .leq-boutons .btn{width:100%;padding:10px 12px}}
/* historique des essais en pastilles */
.leq-qcm .hist .res{display:inline-block;padding:1px 9px;border-radius:999px;background:var(--bad-bg);line-height:1.5}
.leq-qcm .hist .res.okk{background:var(--good-bg);border:0}

/* ---------- TP : bilan ---------- */
.leq-tp .leq-zone>.tpv-who{font-size:18px}
.leq-tp .bmeta{line-height:1.5}
.leq-tp .bexit{position:relative;padding:7px 12px 7px 40px!important;border-radius:10px;background:var(--bad-bg);align-self:flex-start}
.leq-tp .bexit::before{content:"";position:absolute;left:11px;top:50%;width:20px;height:20px;margin-top:-10px;background:currentColor;-webkit-mask:var(--leq-m) center/contain no-repeat;mask:var(--leq-m) center/contain no-repeat;--leq-m:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='1.800' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3.500L2.500 20h19zM12 10v4.500M12 17.300v.200'/%3E%3C/svg%3E")}
/* détail par étape : une barre devant les points ; en-tête de poste (texte repris du récapitulatif du site) */
.leq-tp .btable{margin-top:12px!important;border-collapse:separate!important;border-spacing:0}
.leq-tp .btable tbody td{padding:7px 8px!important;vertical-align:middle}
.leq-tp .btable tbody td.num{white-space:nowrap;text-align:right;width:1%;position:relative}
.leq-tp .btable tbody tr.leq-l td.num{padding-left:136px!important}
.leq-tp .btable tbody tr.leq-l td.num::before{content:"";position:absolute;left:8px;top:50%;width:112px;height:9px;margin-top:-4.5px;border-radius:5px;background:linear-gradient(var(--leq-cb),var(--leq-cb)) left center/calc(var(--leq-r,0)*100%) 100% no-repeat var(--leq-piste)}
.leq-tp .btable tbody tr.leq-l{--leq-cb:var(--ok,#1a8a4f)}
.leq-tp .btable tbody tr.leq-l.leq-part{--leq-cb:#c98a00}
.leq-tp .btable tbody tr.leq-l.leq-zero td:first-child{color:var(--muted)}
.leq-tp .btable tbody tr.leq-l:hover td{background:var(--surface-2)}
.leq-tp .btable tbody tr.leq-poste td{padding-top:40px!important;position:relative}
.leq-tp .btable tbody tr.leq-poste td.num::before{top:calc(50% + 16.5px)}
.leq-tp .btable tbody tr.leq-poste:first-child td.num::before{top:calc(50% + 13.5px)}
.leq-tp .btable tbody tr.leq-poste:first-child td{padding-top:34px!important}
.leq-tp .btable tbody tr.leq-poste td:first-child::before{content:attr(data-leq-poste);position:absolute;left:8px;top:15px;white-space:nowrap;font-variant:small-caps;letter-spacing:.04em;font-weight:700;font-size:16px;color:var(--leq-or)}
.leq-tp .btable tbody tr.leq-poste:first-child td:first-child::before{top:9px}
.leq-tp .btable tbody tr.leq-poste td.num::after{content:"";position:absolute;left:8px;top:22px;width:112px;height:4px;border-radius:2px;background:linear-gradient(var(--leq-or),var(--leq-or)) left center/calc(var(--leq-rp,0)*100%) 100% no-repeat var(--leq-piste)}
.leq-tp .btable tbody tr.leq-poste:first-child td.num::after{top:16px}
.leq-tp .btable tfoot td{padding:10px 8px!important;font-weight:700;font-size:1.08em;border-top:2px solid var(--leq-c);border-bottom:0!important}
.leq-tp .btable tfoot td.num{color:var(--leq-c);white-space:nowrap}
@media (max-width:560px){
  .leq-tp .btable tbody tr.leq-l td.num{padding-left:62px!important}
  .leq-tp .btable tbody tr.leq-l td.num::before{width:46px}
  .leq-tp .btable tbody tr.leq-poste td.num::after{display:none}
  .leq-tp .btable tbody tr.leq-poste td:first-child::before{font-size:14px;letter-spacing:.01em;max-width:calc(100vw - 52px);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
}
/* envoi : le bouton d'envoi direct du site (bloc bleu nuit) reste l'action principale ; les messageries passent en second */
.tpv #tpvMain .leq-tp .mailbox:has(.bxw) .mailbtns a.btn.primary,.tpv #tpvMain .leq-tp .mailbox:has(.bxw) .mailbtns a.btn.primary:hover{background:var(--surface)!important;color:var(--acc,var(--accent))!important;border-color:var(--line)!important}
.leq-tp .mailbox .mailbtns .btn:focus-visible{outline:3px solid var(--leq-or);outline-offset:2px}

/* ---------- animations : une seule fois, à l'apparition ---------- */
@keyframes leq-monte{from{stroke-dasharray:0 200}}
@keyframes leq-tourne{from{transform:rotate(0deg)}}
@keyframes leq-pousse{from{transform:scaleX(0)}}
@keyframes leq-barre{from{background-size:0 100%}}
@keyframes leq-vient{from{opacity:0;transform:translateY(8px)}}
@keyframes leq-note{from{opacity:0;transform:scale(.8)}}
@keyframes leq-allume{0%{opacity:0}55%{opacity:0}70%{opacity:1}80%{opacity:.5}100%{opacity:.9}}
.leq-anime .leq-rempli{animation:leq-monte 1.25s cubic-bezier(.22,.8,.3,1) .15s both}
.leq-anime .leq-aig{animation:leq-tourne 1.25s cubic-bezier(.22,.8,.3,1) .15s both}
.leq-anime .leq-note{animation:leq-note .5s ease-out .95s both}
.leq-anime .leq-verdict{animation:leq-vient .45s ease-out 1.2s both}
.leq-anime.leq-ok .leq-verdict::after{animation:leq-allume 1.5s ease-out 1.2s both}
.leq-anime.leq-qcm .br .bar i{animation:leq-pousse .7s ease-out 1.45s both}
.leq-anime.leq-qcm .leq-relire>a{animation:leq-vient .4s ease-out 1.6s both}
.leq-anime.leq-tp .btable tbody tr.leq-l td.num::before{animation:leq-barre .7s ease-out 1.45s both}
.leq-anime.leq-tp .btable tbody tr.leq-poste td.num::after{animation:leq-barre .7s ease-out 1.45s both}
@media (prefers-reduced-motion:reduce){
  .leq-anime .leq-rempli,.leq-anime .leq-aig,.leq-anime .leq-note,.leq-anime .leq-verdict,.leq-anime.leq-ok .leq-verdict::after,.leq-anime.leq-qcm .br .bar i,.leq-anime.leq-qcm .leq-relire>a,.leq-anime.leq-tp .btable tbody tr.leq-l td.num::before,.leq-anime.leq-tp .btable tbody tr.leq-poste td.num::after{animation:none!important}
  .leq-qcm .leq-relire>a,.leq-qcm .leq-relire>a::after{transition:none}
}
@media print{.leq-cadran{display:none!important}.leq .leq-zone{display:flex!important}.leq .leq-zone>.leq-note{margin:0}.leq-anime *,.leq-anime *::before,.leq-anime *::after{animation:none!important}}
