*{box-sizing:border-box}body{font:15px/1.65 system-ui,Arial;margin:0;background:#eff5fa;color:#183b57}header{display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;padding:14px 5%;background:white;border-bottom:1px solid #c8d9e7}a{color:#12669e;font-weight:750}main{max-width:1060px;padding:20px 14px 60px;margin:auto}.hero{background:linear-gradient(110deg,#1b3e68,#277ba4);border-radius:14px;padding:25px;color:#fff}.hero span{font-size:11px;font-weight:900;letter-spacing:.1em}.hero h1{margin:8px 0}.toolbar{display:flex;justify-content:space-between;gap:13px;align-items:center;flex-wrap:wrap;padding:16px;background:white;border:1px solid #cbdfeb;border-radius:12px;margin:14px 0}.toolbar button{padding:10px 13px;background:#156a9f;color:white;border:0;border-radius:8px;margin-right:6px;cursor:pointer}.toolbar button:disabled{opacity:.5}.block{border:1px solid #c9ddec;border-radius:12px;padding:18px;margin:15px 0;background:white}.block h3{margin:4px 0}.block p{white-space:pre-wrap}.block label{display:block;padding:11px;margin:9px 0;border:1px solid #c7dbe8;border-radius:8px;cursor:pointer}.block label:has(input:checked){background:#eaf5fd;border-color:#2474a9}.block label input[type=radio]{margin-right:10px}.answer{width:100%;font:inherit;min-height:100px;border:1px solid #aac9db;border-radius:8px;padding:10px}.block table{border-collapse:collapse;width:100%}.block td{border:1px solid #c8dce9;padding:8px}.block table input{width:100%;padding:7px;border:1px solid #a8c7da;border-radius:5px}.block img,.block video{max-width:100%;height:auto}.sub{border-left:3px solid #d0e4f0;padding:10px 15px;margin:12px 0}#error{color:#a52626}@media(max-width:600px){main{padding:12px 8px}.block{padding:12px}.hero{padding:18px}}
/* R323.6.17 — préserver la transcription des annales dans le lecteur officiel. */
.r323617-transcription #questions .block p{white-space:pre-wrap;overflow-wrap:anywhere;line-height:1.6}.r323617-origin-notice{padding:12px;border:1px solid #d1e3f0;border-radius:10px;background:#f2f8fc;color:#345b70;font-size:13px}.r323617-source-pdf{font-weight:750;color:#146da0;text-decoration:underline}

/* R323.6.19 — sous-blocs à l’intérieur des ateliers TFE sur mobile. */
.r323619-subblocks{border-top:1px solid #c2dce8;margin-top:22px;padding-top:12px}.r323619-subblocks>h4{font-size:15px;color:#174a6b}.r323619-subblocks>.block{background:#f5fafd;margin:12px 0;border-left:3px solid #2d89b7;overflow-x:auto}.r323619-subblocks>.block table{min-width:480px}.r323619-subblocks>.block input,.r323619-subblocks>.block textarea{max-width:100%}.r323619-subblocks .answer{min-height:105px}


/* SEG R323.6.47 — Correction pédagogique immédiate des cahiers d'activités */
.r323647-feedback{margin:12px 0 16px;padding:13px 16px;border:1px solid #b9d5e6;border-left:4px solid #2e7b9b;background:#f1f9fc;border-radius:9px;white-space:normal}
.r323647-feedback.r323647-correct{border-color:#a8d6b8;border-left-color:#21844d;background:#f1faf4}
.r323647-feedback.r323647-incorrect{border-color:#e8c5ae;border-left-color:#c37328;background:#fff9f2}
.r323647-feedback>strong{display:block;font-weight:800;font-size:15px;margin-bottom:5px}
.r323647-feedback p{white-space:pre-wrap;overflow-wrap:anywhere}
.r323647-justification{margin-top:9px;padding:10px 12px;background:rgba(255,255,255,.75);border-radius:6px}
.r323647-justification>b{display:block;margin-bottom:4px}
.r323647-check{margin:10px 0 2px;padding:9px 14px;border:1px solid #196a9c;border-radius:8px;background:#196a9c;color:#fff;font:inherit;font-weight:700;cursor:pointer}
.r323647-check:focus-visible{outline:3px solid #f6c04a;outline-offset:2px}

/* R323.6.49 : first response locked and visibly confirmed */
.r323647-feedback.r323649-locked{border-left-width:5px}
.r323649-lock-note{font-size:12px;font-weight:650;color:#36566e;margin-top:8px}
#questions input[type=radio]:disabled,#questions input[type=checkbox]:disabled{cursor:not-allowed}
#questions input[type=radio]:disabled:checked,#questions input[type=checkbox]:disabled:checked{opacity:1;accent-color:#1d689e}

/* R323.6.51 — phrase à compléter */
.r323651-cloze-sentence{padding:12px 14px;margin:9px 0 10px;line-height:2.2;background:#f6faff;border:1px solid #c4dbec;border-radius:8px;overflow-wrap:anywhere}
.r323651-cloze-sentence select{max-width:100%;min-width:150px;padding:8px;border:1px solid #2b7cab;border-radius:6px;font:inherit;color:#12395b;background:white}
.r323651-cloze-sentence select:disabled{background:#ebf3f8;color:#174e75;opacity:1}
@media(max-width:600px){.r323651-cloze-sentence select{min-width:120px;width:auto}}

/* R323.6.52 — Multiple menus appear inline within the sentence, as in lesson CLOZE */
.r352-cloze-instruction{font-weight:700;margin:12px 0 6px;color:#163e5f}
.r352-cloze-inline{line-height:2.3;padding:10px 12px;border:1px solid #bfd9eb;border-radius:8px;background:#f8fbff;overflow-wrap:anywhere;white-space:pre-wrap}
.r352-cloze-blank{display:inline-block!important;min-width:128px;max-width:min(280px,95%);width:auto;padding:6px 8px;margin:0 4px;border:1px solid #3984ae;border-radius:6px;background:#fff;color:#124063;vertical-align:baseline;font:inherit}
.r352-cloze-blank:disabled{opacity:1;background:#e7f4e9;border-color:#6bb48a;color:#115232}
.r352-cloze-feedback{margin:9px 0}
.r352-cloze-feedback>small{font-weight:700;color:#315a79}
@media(max-width:600px){.r352-cloze-blank{min-width:105px;max-width:100%}}

/* R323.6.53 : rich formatting is preserved around in-sentence answer menus. */
.r352-cloze-inline span{vertical-align:baseline}
.r352-cloze-inline strong,.r352-cloze-inline b{font-weight:700}
.r352-cloze-feedback[hidden]{display:none!important}


/* SEG R323.6.55 — coherent answer and feedback colours (one state per question)
   Neutral before confirmation; green only when server says correct; amber if incorrect.
   Text labels and symbols communicate status in addition to colour. */
#questions .r323647-feedback.r323655-state-correct{
  border-color:#94d3a9;border-left-color:#23834f;background:#eef9f1;color:#163c28
}
#questions .r323647-feedback.r323655-state-incorrect{
  border-color:#e3b789;border-left-color:#c36d22;background:#fff6ea;color:#613813
}
#questions .r323647-feedback.r323655-state-correct>strong{color:#1d7043}
#questions .r323647-feedback.r323655-state-incorrect>strong{color:#a25418}
#questions .r352-cloze-feedback:has(.r323655-state-correct)>small{color:#1d7043}
#questions .r352-cloze-feedback:has(.r323655-state-incorrect)>small{color:#a25418}
#questions select.r323655-correct,
#questions .r352-cloze-blank.r323655-correct:disabled,
#questions .r323651-cloze-sentence select.r323655-correct:disabled{
  background:#e9f7ed!important;border:1.5px solid #23834f!important;color:#165b34!important;
  opacity:1
}
#questions select.r323655-incorrect,
#questions .r352-cloze-blank.r323655-incorrect:disabled,
#questions .r323651-cloze-sentence select.r323655-incorrect:disabled{
  background:#fff1df!important;border:1.5px solid #c36d22!important;color:#713e12!important;
  opacity:1
}
#questions label.r323655-correct{background:#e9f7ed!important;border-color:#23834f!important;color:#165b34}
#questions label.r323655-incorrect{background:#fff1df!important;border-color:#c36d22!important;color:#713e12}
#questions input.r323655-correct:disabled{accent-color:#23834f!important;opacity:1}
#questions input.r323655-incorrect:disabled{accent-color:#c36d22!important;opacity:1}
#questions .r323655-correct:focus-visible{outline:2px solid #23834f;outline-offset:2px}
#questions .r323655-incorrect:focus-visible{outline:2px solid #c36d22;outline-offset:2px}
