/* Rendu des blocs Scormia — partagé éditeur/player. */
@import './tokens.css';
/* Thème hljs du bloc code (carte sombre #1e1e1e) — partagé éditeur + player :
   le ZIP SCORM autonome embarque la coloration. Surcharges : .sc-code__pre. */
@import 'highlight.js/styles/vs2015.css';

.sc-screen {
    background: #fff;
    color: var(--ink);
    font-family: var(--font-ui);
    line-height: 1.65;
}

/* ===== Pile verticale de blocs =====
   Chaque écran est une pile .sc-stack : blocs en colonne, séparés par 26px. */
.sc-stack { display: flex; flex-direction: column; gap: 26px; }

.sc-block { margin: 0; }

/* ===== Titre — 4 variantes POC ===== */
.sc-heading { margin: 0; }
.sc-heading__text { margin: 0; font-weight: 700; color: var(--ink); }
/* v0 Souligné accent : 28px + trait 54×4 accent sous le titre. */
.sc-heading--underline .sc-heading__text { font-size: 28px; letter-spacing: -.3px; }
.sc-heading__underline { display: block; width: 54px; height: 4px; border-radius: 99px; background: var(--acc); margin-top: 10px; }
/* v1 Barre latérale : barre verticale 6px en dégradé accent → accent-mid. */
.sc-heading--sidebar { display: flex; align-items: stretch; gap: 16px; }
.sc-heading__sidebar { width: 6px; border-radius: 99px; background: linear-gradient(var(--acc), var(--acc-mid)); flex: 0 0 auto; }
.sc-heading--sidebar .sc-heading__text { font-size: 26px; }
/* v2 Pastille numéro : carré arrondi 48px --acc-soft, glyphe « # » accent. */
.sc-heading--numbered { display: flex; align-items: center; gap: 16px; }
.sc-heading__badge { width: 48px; height: 48px; border-radius: 14px; background: var(--acc-soft); color: var(--acc); font-size: 20px; font-weight: 700; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.sc-heading--numbered .sc-heading__text { font-size: 25px; }
/* v3 Centré éditorial : sur-titre « Section » + Fraunces 32/600. */
.sc-heading--editorial { text-align: center; }
.sc-heading__kicker { display: block; font-size: 12px; font-weight: 600; letter-spacing: 2px; color: var(--acc); text-transform: uppercase; margin-bottom: 8px; }
.sc-heading--editorial .sc-heading__text { font-family: var(--font-display); font-size: 32px; font-weight: 600; }

/* ===== Sous-titre — 3 variantes POC ===== */
.sc-subtitle { margin: 0; }
/* v0 Simple : 22px/700 encre pleine. */
.sc-subtitle__text { margin: 0; font-size: 22px; font-weight: 700; color: var(--ink); }
/* v1 Barre d'accent : barre 5×24 accent + texte 21px. */
.sc-subtitle--bar { display: flex; align-items: center; gap: 12px; }
.sc-subtitle__bar { width: 5px; height: 24px; border-radius: 3px; background: var(--acc); flex: 0 0 auto; }
.sc-subtitle--bar .sc-subtitle__text { font-size: 21px; }
/* v2 Étiquette majuscules : 13px accent, espacement 1.5px. */
.sc-subtitle--label .sc-subtitle__text { font-size: 13px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--acc); }

/* ===== Texte — 2 variantes POC ===== */
.sc-richtext { font-size: 17px; line-height: 1.7; color: var(--ink-3); }
/* v1 Chapô large : 21px/1.5, encre pleine, medium. */
.sc-richtext--lead { font-size: 21px; line-height: 1.5; font-weight: 500; color: var(--ink); }
.sc-richtext p { margin: 0 0 .85rem; }
.sc-richtext p:last-child { margin-bottom: 0; }
.sc-richtext ul, .sc-richtext ol { margin: 0 0 .85rem; padding-left: 1.4rem; }
.sc-richtext a { color: var(--acc); text-decoration: underline; text-underline-offset: 3px; text-decoration-color: color-mix(in srgb, var(--acc) 45%, transparent); transition: text-decoration-color .15s; }
.sc-richtext a:hover { text-decoration-color: var(--acc); }
.sc-richtext strong { font-weight: 700; color: var(--acc); }
.sc-richtext code { font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace; font-size: .875em; padding: .1em .4em; border-radius: 4px; background: color-mix(in srgb, var(--ink) 8%, transparent); }

/* ===== Image — 3 variantes POC ===== */
.sc-image { margin: 0; }
.sc-image img { display: block; width: 100%; }
.sc-caption { margin: 0; font-size: 13px; color: var(--mut-2); }
/* v0 Bord arrondi : image nue radius 16, légende italique centrée dessous. */
.sc-image--v0 img { border-radius: 16px; }
.sc-image--v0 .sc-caption { margin-top: 10px; font-style: italic; text-align: center; }
/* v1 Carte légende : carte bordée radius 16, légende 14px en pied. */
.sc-image--v1 { border: 1px solid #eef1f6; border-radius: 16px; overflow: hidden; }
.sc-image__body { padding: 14px 16px; }
.sc-image--v1 .sc-caption { font-size: 14px; color: var(--ink-3); }
/* v2 Polaroïd : carte blanche 74 % pivotée -1.5°, ombre portée, légende Fraunces. */
.sc-image--v2 { display: flex; justify-content: center; }
.sc-image__polaroid { box-sizing: border-box; width: 74%; padding: 12px; border-radius: 6px; background: #fff; border: 1px solid #eef1f6; box-shadow: 0 12px 32px -16px rgba(27, 36, 64, .45); transform: rotate(-1.5deg); }
.sc-image--v2 .sc-caption { padding: 14px 6px 4px; font-family: var(--font-display); font-size: 15px; text-align: center; color: var(--ink-3); }

/* ===== Audio — 3 variantes POC (lecteur natif <audio controls> habillé) ===== */
.sc-audio { margin: 0; }
.sc-audio audio { display: block; width: 100%; height: 42px; }
.sc-audio__row { display: flex; align-items: center; gap: 15px; }
.sc-audio__row audio { flex: 1; width: auto; min-width: 0; }
/* v0 Barre compacte : carte claire radius 16 sur léger dégradé, badge rond
   accent 46px avec halo doux ; légende en pied, alignée sous le lecteur. */
.sc-audio--v0 {
    padding: 15px 18px;
    border-radius: 16px;
    background: linear-gradient(180deg, #fbfcff, #f4f6fc);
    border: 1px solid #e6ebf5;
    box-shadow: 0 6px 22px -18px rgba(27, 36, 64, .5);
}
.sc-audio--v0 .sc-audio__row { gap: 14px; }
.sc-audio__badge {
    display: flex; align-items: center; justify-content: center; flex: 0 0 auto;
    width: 46px; height: 46px; border-radius: 50%;
    background: linear-gradient(135deg, var(--acc), var(--acc-mid)); color: #fff;
    box-shadow: 0 6px 16px -6px color-mix(in srgb, var(--acc) 55%, transparent);
}
/* Légende alignée sous le lecteur (décalée de la largeur du badge + gap). */
.sc-audio--v0 .sc-caption { margin: 12px 0 0 60px; font-size: 13px; color: var(--ink-3); }
/* v1 Carte podcast : tuile dégradé accent, titre en tête, lecteur pleine largeur dessous. */
.sc-audio--v1 {
    padding: 18px;
    border-radius: 18px;
    background: linear-gradient(180deg, #fbfcff, #f5f7fc);
    border: 1px solid #e9edf5;
    box-shadow: 0 10px 30px -20px rgba(27, 36, 64, .35);
}
.sc-audio--v1 .sc-audio__row { gap: 15px; align-items: center; }
.sc-audio__tile {
    display: flex; align-items: center; justify-content: center; flex: 0 0 auto;
    width: 56px; height: 56px; border-radius: 15px;
    background: linear-gradient(135deg, var(--acc), var(--acc-mid)); color: #fff;
    box-shadow: 0 8px 20px -8px color-mix(in srgb, var(--acc) 60%, transparent);
}
.sc-audio__body { flex: 1; min-width: 0; }
/* Petit surtitre « Piste audio » au-dessus du titre, façon podcast. */
.sc-audio__body::before {
    content: "Piste audio";
    display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .08em;
    text-transform: uppercase; color: var(--acc); margin-bottom: 2px;
}
.sc-audio--v1 .sc-caption { font-size: 16px; font-weight: 700; color: var(--ink); }
.sc-audio--v1 audio { margin-top: 14px; }
/* v2 Ligne minimale : lecteur nu souligné d'un mince liseré accent ; légende
   discrète en pied, précédée d'une pastille accent. Sobre mais soigné. */
.sc-audio--v2 { padding: 4px 2px 2px; border-left: 3px solid var(--acc-line); padding-left: 14px; }
.sc-audio--v2 audio { border-bottom: 1px solid var(--line-2); padding-bottom: 10px; }
.sc-audio--v2 .sc-caption {
    display: flex; align-items: center; gap: 8px;
    margin-top: 10px; font-size: 13px; color: var(--ink-3);
}
.sc-audio--v2 .sc-caption::before {
    content: ''; flex: 0 0 auto; width: 6px; height: 6px; border-radius: 50%; background: var(--acc);
}

/* ===== Vidéo — 3 variantes POC (embed toEmbedUrl OU <video controls>) ===== */
.sc-video { margin: 0; }
.sc-video__media { position: relative; }
.sc-video__media--embed { aspect-ratio: 16 / 9; }
.sc-video__media--embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.sc-video__media video { display: block; width: 100%; }
/* v0 Sombre : cadre radius 16 sur dégradé nuit (letterbox élégant). */
.sc-video--v0 { border-radius: 16px; overflow: hidden; background: linear-gradient(135deg, #2a3352, #3a4668); }
/* v1 Vignette titre : carte bordée, média en tête, titre 15/600 en pied. */
.sc-video--v1 { border: 1px solid #eef1f6; border-radius: 16px; overflow: hidden; }
.sc-video--v1 .sc-video__media { background: linear-gradient(135deg, #2a3352, #3a4668); }
.sc-video__title { padding: 13px 16px; font-size: 15px; font-weight: 600; color: var(--ink); }
/* v2 Clair minimal : cadre clair bordé 1.5, média sur marge 10px radius 10. */
.sc-video--v2 { padding: 10px; border: 1.5px solid var(--line-2); border-radius: 16px; background: #f7f9fc; }
.sc-video--v2 .sc-video__media { border-radius: 10px; overflow: hidden; }

/* ===== Intégration — 3 variantes POC (iframe sandboxée intouchée) ===== */
.sc-embed { margin: 0; }
.sc-embed__frame { position: relative; }
.sc-embed__frame iframe { display: block; width: 100%; height: 100%; border: 0; }
/* v0 Navigateur : chrome à pastilles macOS au-dessus du contenu. */
.sc-embed--v0 { border: 1px solid var(--line-2); border-radius: 14px; overflow: hidden; }
.sc-embed__chrome { display: flex; gap: 7px; padding: 11px 14px; background: #f5f7fc; border-bottom: 1px solid var(--line-2); }
.sc-embed__chrome span { width: 9px; height: 9px; border-radius: 50%; }
.sc-embed__chrome span:nth-child(1) { background: #ff5f57; }
.sc-embed__chrome span:nth-child(2) { background: #febc2e; }
.sc-embed__chrome span:nth-child(3) { background: #28c840; }
/* v1 Cadre simple : liseré pointillé discret. */
.sc-embed--v1 { border: 1.5px dashed #cdd5e2; border-radius: 14px; overflow: hidden; }
/* v2 Vignette lien : grande carte-lien cliquable — vignette/preview en tête,
   titre + domaine en pied. SANS iframe (ouvre le contenu dans un nouvel onglet). */
.sc-embed__card { display: block; overflow: hidden; border: 1px solid var(--line-2); border-radius: 16px; background: #fff; text-decoration: none; transition: border-color .15s, box-shadow .15s, transform .15s; }
a.sc-embed__card:hover { border-color: var(--acc-border); box-shadow: 0 8px 22px -12px var(--acc-mid); transform: translateY(-1px); }
a.sc-embed__card:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }
/* Zone vignette : ratio 16/9, image de couverture OU glyphe (initiale du domaine). */
.sc-embed__thumb { position: relative; display: flex; align-items: center; justify-content: center; aspect-ratio: 16 / 9; background: var(--acc-bg); }
.sc-embed__thumbimg { width: 100%; height: 100%; object-fit: cover; display: block; }
.sc-embed__thumb--glyph { background: linear-gradient(135deg, var(--acc-soft), var(--acc-bg)); }
.sc-embed__thumbglyph { font-family: var(--font-display, inherit); font-size: 64px; font-weight: 700; line-height: 1; color: var(--acc-mid); text-transform: uppercase; }
/* Pastille « lien externe » en surimpression, coin haut-droit de la vignette. */
.sc-embed__thumbbadge { position: absolute; top: 12px; right: 12px; display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: 10px; background: rgba(255, 255, 255, .92); color: var(--acc); box-shadow: 0 2px 8px -2px rgba(27, 36, 64, .28); }
/* Pied : titre + domaine. */
.sc-embed__cap { display: flex; flex-direction: column; gap: 3px; padding: 13px 16px; }
.sc-embed__captitle { font-size: 15px; font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc-embed__capurl { font-size: 13px; color: var(--mut); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ===== État vide des médias (url absente/invalide) — carte dégradé doux +
   pictogramme. Le bouton « Ajouter … » n'existe visuellement qu'en éditeur
   (editor.css le révèle sous .sc-ed-card) : le player montre une carte
   inerte discrète, sans bouton. ===== */
.sc-media-ph { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; border-radius: 16px; background: linear-gradient(135deg, #e2e9fb, #eef1f6); color: #b7c3e6; }
.sc-media-ph--image { min-height: 200px; }
.sc-media-ph--video { min-height: 210px; }
.sc-media-ph--audio { flex-direction: row; gap: 14px; min-height: 72px; border-radius: 14px; }
.sc-media-ph--embed { min-height: 160px; border-radius: 14px; }
.sc-media-ph__note { font-size: 12px; font-weight: 600; color: #5566a6; }
.sc-media-ph__btn { display: none; }

/* ===== Liste — 3 variantes POC =====
   Pastilles/numéros dessinés en CSS (::before/::after + compteur) : les <li>
   ne contiennent que le texte — l'édition en place reste du texte pur. */
/* Sélecteurs qualifiés (spécificité 0,1,1) : le style natif UA (puce/numéro,
   padding-inline-start 40px) doit être neutralisé PARTOUT — player sans
   preflight compris — et survivre aux règles `revert` de la carte éditeur
   (.sc-ed-card :where(ul, ol), editor.css, 0,1,0, plus tard dans la cascade)
   qui retombent sur l'UA et réintroduiraient les marqueurs natifs. */
ul.sc-list, ol.sc-list { list-style: none; margin: 0; padding: 0; }
.sc-list li { font-size: 16px; color: #33405c; list-style: none; }
/* v0 Puces à icône : pastille 26px --acc-soft + coche --acc (masque SVG). */
.sc-list--check { --sc-check-ico: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 13l4 4L19 7'/%3E%3C/svg%3E"); }
.sc-list--check li { position: relative; padding: 2px 4px 2px 43px; min-height: 26px; border-radius: 6px; }
.sc-list--check li + li { margin-top: 12px; }
.sc-list--check li::before { content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 26px; height: 26px; border-radius: 8px; background: var(--acc-soft); }
.sc-list--check li::after { content: ''; position: absolute; left: 6px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; background: var(--acc); -webkit-mask: var(--sc-check-ico) center / contain no-repeat; mask: var(--sc-check-ico) center / contain no-repeat; }
/* v1 Numérotée : compteur cercle 28px plein --acc. */
.sc-list--numbered { counter-reset: sc-list; }
.sc-list--numbered li { position: relative; padding: 2px 4px 2px 46px; min-height: 28px; border-radius: 6px; counter-increment: sc-list; }
.sc-list--numbered li + li { margin-top: 13px; }
.sc-list--numbered li::before { content: counter(sc-list); position: absolute; left: 0; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; border-radius: 50%; background: var(--acc); color: #fff; font-size: 14px; font-weight: 700; display: flex; align-items: center; justify-content: center; }
/* v2 Cartes en grille : 2 colonnes, cartes bordées radius 14, numéro carré arrondi. */
.sc-list--cards { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; counter-reset: sc-list; }
.sc-list--cards li { counter-increment: sc-list; border: 1.5px solid #edf0f5; border-radius: 14px; padding: 14px 16px; background: #fafbfd; font-size: 15px; font-weight: 600; color: var(--ink); }
.sc-list--cards li::before { content: counter(sc-list); display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 9px; background: var(--acc-soft); color: var(--acc); font-weight: 700; margin-bottom: 8px; }

/* ===== Encadré — 4 variantes POC (calloutStyles) ===== */
.sc-callout { display: flex; gap: 16px; border: 1px solid transparent; border-radius: 16px; padding: 20px 22px; margin: 0; }
.sc-callout__icon { display: flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 34px; height: 34px; border-radius: 10px; color: #fff; font-size: 16px; line-height: 1; }
.sc-callout__content { flex: 1; min-width: 0; }
.sc-callout__title { font-size: 15px; font-weight: 700; margin-bottom: 3px; }
.sc-callout__body { font-size: 15px; line-height: 1.5; color: var(--ink-2); }
.sc-callout__body > p:first-child { margin-top: 0; }
.sc-callout__body > p:last-child { margin-bottom: 0; }
/* v0 Information « Bon à savoir » : fond --acc-soft, icône pleine accent. */
.sc-callout--info { background: var(--acc-soft); border-color: var(--acc-soft); }
.sc-callout--info .sc-callout__icon { background: var(--acc); }
.sc-callout--info .sc-callout__title { color: var(--ink); }
/* v1 Astuce : verts --ok. */
.sc-callout--tip { background: var(--ok-bg); border-color: #cdeede; }
.sc-callout--tip .sc-callout__icon { background: var(--ok); }
.sc-callout--tip .sc-callout__title { color: #0b6e4c; }
/* v2 Attention : oranges. */
.sc-callout--warning { background: #fef5e9; border-color: #f6e0bd; }
.sc-callout--warning .sc-callout__icon { background: #e08a1e; }
.sc-callout--warning .sc-callout__title { color: #a4630f; }
/* v3 À retenir : barre latérale accent 5px, sans icône. */
.sc-callout--note { display: block; border: 0; border-left: 5px solid var(--acc); border-radius: 0 16px 16px 0; padding: 18px 22px; background: #fafbff; }
.sc-callout--note .sc-callout__title { color: var(--acc); }
/* v4 Exemple : ardoise neutre, glyphe « ✎ » — met en scène un cas concret. */
.sc-callout--example { background: #f3f5fb; border-color: #e2e7f3; }
.sc-callout--example .sc-callout__icon { background: #64748b; }
.sc-callout--example .sc-callout__title { color: #334155; }

/* ===== Citation — 3 variantes POC ===== */
/* Qualifié (0,1,1) : bat le `margin: revert` (UA 1em 40px) posé par la carte
   éditeur sur :where(blockquote) — même logique que ul./ol..sc-list. */
blockquote.sc-quote { margin: 0; }
.sc-quote__body p { margin: 0 0 8px; }
.sc-quote__body p:last-child { margin-bottom: 0; }
/* v0 Barre latérale : 4px accent, italique 19px, auteur « — Nom » gris. */
.sc-quote--bar { border-left: 4px solid var(--acc); padding: 4px 0 4px 20px; }
.sc-quote--bar .sc-quote__body { font-style: italic; font-size: 19px; line-height: 1.5; color: var(--ink); }
.sc-quote--bar .sc-quote__author { display: block; margin-top: 8px; font-size: 14px; font-weight: 600; color: var(--mut); }
.sc-quote--bar .sc-quote__author::before { content: '— '; }
/* v1 Grande centrée : Fraunces 23px, guillemet décoratif, auteur accent capitales. */
.sc-quote--center { text-align: center; padding: 6px 12px; }
.sc-quote--center::before { content: '“'; display: block; font-family: var(--font-display); font-size: 52px; line-height: .5; color: var(--acc-line); }
.sc-quote--center .sc-quote__body { font-family: var(--font-display); font-size: 23px; line-height: 1.45; font-weight: 500; color: var(--ink); }
.sc-quote--center .sc-quote__author { display: block; margin-top: 12px; font-size: 14px; font-weight: 600; letter-spacing: .4px; color: var(--acc); text-transform: uppercase; }
/* v2 Carte pull-quote : fond très légèrement teinté --acc-soft, barre accent à
   gauche, gros guillemet Fraunces --acc-line, texte encre. Pas d'aplat plein :
   contraste texte fort et cohérence avec les barres/guillemets des v0 et v1. */
.sc-quote--card { position: relative; background: var(--acc-soft); border-left: 4px solid var(--acc); border-radius: 0 14px 14px 0; padding: 22px 26px 22px 30px; color: var(--ink); overflow: hidden; }
.sc-quote--card::before { content: '“'; position: absolute; top: 6px; right: 20px; font-family: var(--font-display); font-size: 68px; line-height: 1; color: var(--acc-line); pointer-events: none; }
.sc-quote--card .sc-quote__body { position: relative; font-size: 18px; line-height: 1.55; font-weight: 500; }
.sc-quote--card .sc-quote__author { display: flex; align-items: center; gap: 12px; margin-top: 16px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.sc-quote__initials { display: flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 38px; height: 38px; border-radius: 50%; background: var(--acc); color: #fff; font-weight: 700; font-size: 14px; }

/* ===== Séparateur — 3 variantes POC ===== */
.sc-divider { border: 0; margin: 12px 0; }
/* v0 Trait fin : 2px plein --line-2, radius 99. */
.sc-divider--line { height: 2px; border-radius: 99px; background: var(--line-2); }
/* v1 Point central : deux traits + point accent 9px. */
.sc-divider--dot { display: flex; align-items: center; gap: 14px; }
.sc-divider__line { flex: 1; height: 2px; background: var(--line-2); }
.sc-divider__point { width: 9px; height: 9px; border-radius: 50%; background: var(--acc); flex: 0 0 auto; }
/* v2 Pointillé. */
.sc-divider--dashed { border-top: 2px dashed #cdd5e2; }

/* ===== Bouton / Lien — 3 variantes POC =====
   <a> quand l'URL http(s) est posée, <span> inerte sinon (rendu partagé). */
/* v0 Plein : fond accent, radius 11. */
.sc-button__btn { display: inline-block; padding: 12px 24px; border-radius: 11px; background: var(--acc); color: #fff; font-size: 15px; font-weight: 600; text-decoration: none; transition: filter .15s, background .15s; }
a.sc-button__btn:hover { filter: brightness(1.07); }
/* v1 Contour : bordure 1.5 accent, texte accent (padding -1px : même gabarit). */
.sc-button--outline .sc-button__btn { padding: 11px 23px; border: 1.5px solid var(--acc); background: transparent; color: var(--acc); }
.sc-button--outline a.sc-button__btn:hover { filter: none; background: var(--acc-soft); }
/* v2 Pilule fléchée : radius 99, flèche → alignée au libellé. */
.sc-button--pill .sc-button__btn { display: inline-flex; align-items: center; gap: 9px; padding: 12px 26px; border-radius: 99px; }

/* ===== Statistiques — 3 variantes POC ===== */
.sc-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 14px 0; }
.sc-stats__item { position: relative; text-align: center; padding: 6px 4px; border-radius: 14px; }
.sc-stats__value { font-size: 32px; font-weight: 800; line-height: 1.1; color: var(--ink); }
.sc-stats__label { font-size: 13px; color: var(--mut); margin-top: 5px; }
/* v0 Colonnes : chiffres alignés à gauche, sans habillage. */
.sc-stats--cols .sc-stats__item { text-align: left; }
/* v1 Cartes : fond gris clair bordé, padding généreux. */
.sc-stats--cards .sc-stats__item { padding: 20px 16px; background: #f7f9fc; border: 1px solid #eef1f6; }
/* v2 Accent : fond --acc-soft, chiffres accent, cartes hautes et aérées
   (padding vertical généreux — retour Andrew). */
.sc-stats--accent .sc-stats__item { padding: 30px 18px; background: var(--acc-soft); }
.sc-stats--accent .sc-stats__value { color: var(--acc); }

/* ===== Tableau — en-tête acc-soft, lignes alternées teintées thème, wrapper radius 14 =====
   table-layout:fixed : largeurs de colonnes stables — un texte long wrappe
   (break-word) et fait grandir la LIGNE, jamais la colonne. */
.sc-table-wrap { border-radius: 14px; overflow: hidden; border: 1px solid var(--line, #eef1f6); }
.sc-table { width: 100%; border-collapse: collapse; font-size: 13.5px; table-layout: fixed; }
.sc-table th, .sc-table td { word-break: break-word; }
.sc-table thead tr { background: var(--acc-soft); }
.sc-table thead th { padding: 10px 13px; font-weight: 700; color: var(--acc-deep); text-align: left; border-bottom: 1px solid var(--line, #eef1f6); }
.sc-table thead th + th { border-left: 1px solid var(--line, #eef1f6); }
/* Zébrage teinté par le thème (dérivé très léger de --acc, cohérent --acc-soft 13 %). */
.sc-table tbody tr:nth-child(even) { background: color-mix(in srgb, var(--acc) 4%, #fff); }
.sc-table tbody td { padding: 10px 13px; color: #41506e; border-top: 1px solid var(--line, #eef1f6); }
.sc-table tbody td + td { border-left: 1px solid var(--line, #eef1f6); }

/* ===== Bloc de code — carte sombre POC (#1e1e1e radius 14), thème vs2015 =====
   Barre de titre : 3 pastilles macOS + label du langage (remplacé par un
   <select> en éditeur — inlineEdit de code.js). Les métriques de fonte du
   <pre> (13.5px / lh 1.7 / var(--font-code)) sont PARTAGÉES avec le textarea
   superposé de l'éditeur (.sc-ed-code-ta, editor.css) : glyphes alignés. */
.sc-code { background: #1e1e1e; border: 1px solid #2a2a2a; border-radius: 14px; overflow: hidden; }
.sc-code__bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; background: #181818; border-bottom: 1px solid #2a2a2a; }
.sc-code__dots { display: flex; gap: 6px; }
.sc-code__dots span { width: 11px; height: 11px; border-radius: 50%; }
.sc-code__dots span:nth-child(1) { background: #ff5f57; }
.sc-code__dots span:nth-child(2) { background: #febc2e; }
.sc-code__dots span:nth-child(3) { background: #28c840; }
.sc-code__lang { color: #cdd8f5; font-size: 12px; font-weight: 600; }
.sc-code__body { position: relative; padding: 16px 18px; }
/* Qualifié (0,1,1) : bat le `margin: revert` (UA 1em 0) posé par la carte
   éditeur sur :where(pre) — même logique que blockquote.sc-quote. Sans ça, le
   <pre> descendait de 13.5px sous le textarea superposé (caret décalé). */
pre.sc-code__pre { margin: 0; font-family: var(--font-code); font-size: 13.5px; line-height: 1.7; white-space: pre-wrap; word-break: break-word; min-height: 22px; }
/* Surcharge du thème vs2015 (`pre code.hljs` : padding 1em, overflow-x) : le
   fond/espacement sont portés par la carte, le code hérite des métriques. */
.sc-code__pre code.hljs { display: block; padding: 0; margin: 0; background: transparent; color: #d4d4d4; font-family: inherit; font-size: inherit; line-height: inherit; white-space: inherit; word-break: inherit; overflow-x: visible; }

/* ===== Espacement : div vide de `px` de haut (style inline posé par le
   rendu). Liseré pointillé + étiquette : éditeur SEULEMENT (editor.css). ===== */
.sc-spacer { height: 24px; }

.sc-math--display { display: block; text-align: center; margin: 1rem 0; }

/* ===== Blocs interactifs — design POC ===== */

/* Bouton d'action partagé des interactifs (Vérifier, Réinitialiser…). */
.sc-btn { background: var(--acc); color: #fff; border: 0; padding: .55rem 1.2rem; border-radius: 14px; cursor: pointer; font: inherit; font-size: .95rem; box-shadow: 0 1px 3px rgba(0, 0, 0, .15); transition: filter .15s, opacity .15s; }
.sc-btn:hover:not(:disabled) { filter: brightness(1.08); }
.sc-btn:disabled { opacity: .55; cursor: not-allowed; }

/* ===== Cartes à retourner — 2 variantes POC =====
   0 Grille (3 colonnes, cartes 140px)  1 Large (2 colonnes, cartes 175px).
   Le flip est porté par le wrapper interne (.is-flipped sur la carte). */
.sc-flashcards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.sc-flashcards--large { grid-template-columns: repeat(2, 1fr); }
/* Responsive : la grille reste alignée sur des rangées pleines (3 en desktop,
   2 en tablette, 1 en mobile) pour que 3/6/9 cartes remplissent parfaitement
   les rangées — jamais de carte orpheline mal cadrée. La variante Large suit
   la même logique (2 → 1). Miroir éditeur / aperçu / export (CSS partagé). */
@media (max-width: 900px) {
    .sc-flashcards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 560px) {
    .sc-flashcards,
    .sc-flashcards--large { grid-template-columns: 1fr; }
}
/* En-tête d'affordance « cartes à retourner » — pleine largeur au-dessus de la grille. */
.sc-flashcards__instruction { grid-column: 1 / -1; margin: 0 0 2px; display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--ink-2); }
.sc-flashcards__instruction-icon { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 22px; height: 22px; border-radius: 999px; background: var(--acc-soft); color: var(--acc); font-size: 13px; font-weight: 700; }
.sc-flashcard { position: relative; height: 140px; border: 0; padding: 0; background: none; cursor: pointer; perspective: 1000px; font-family: inherit; text-align: center; }
.sc-flashcards--large .sc-flashcard { height: 175px; }
.sc-flashcard__inner { position: absolute; inset: 0; display: block; transition: transform .55s cubic-bezier(.4, 0, .2, 1); transform-style: preserve-3d; }
.sc-flashcard.is-flipped .sc-flashcard__inner { transform: rotateY(180deg); }
.sc-flashcard__face { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 16px; border-radius: 14px; backface-visibility: hidden; -webkit-backface-visibility: hidden; overflow-y: auto; overflow-x: hidden; }
.sc-flashcard__face--front { background: #fff; border: 1.5px solid var(--line-2); font-size: 16px; font-weight: 700; color: var(--ink); }
.sc-flashcard__face--back { transform: rotateY(180deg); background: var(--acc); color: #fff; font-size: 13px; line-height: 1.4; }

/* ===== Accordéon — 3 variantes POC =====
   0 Bordé (sections bordées, en-tête grisé ouvert)  1 Rempli (sections
   pleines, en-tête accent-soft ouvert)  2 Minimal accent (séparateurs
   border-bottom à la couleur du thème + fond teinté accent à l'ouverture). */
.sc-accordion { display: flex; flex-direction: column; gap: 13px; }
.sc-accordion--minimal { gap: 2px; }
.sc-accordion__item { overflow: hidden; }
.sc-accordion--bordered .sc-accordion__item { border: 1.5px solid var(--line); border-radius: 14px; }
.sc-accordion--filled .sc-accordion__item { border-radius: 14px; background: #f5f7fc; }
.sc-accordion--minimal .sc-accordion__item { border-bottom: 1.5px solid var(--acc-line); border-radius: 10px; transition: background .2s; }
.sc-accordion--minimal .sc-accordion__item.is-open { background: var(--acc-bg); }
.sc-accordion__header { display: flex; align-items: center; gap: 12px; width: 100%; padding: 17px 20px; border: 0; background: #fff; cursor: pointer; font: inherit; text-align: left; transition: background .2s; }
.sc-accordion--filled .sc-accordion__header { background: #f5f7fc; }
.sc-accordion--minimal .sc-accordion__header { padding: 18px 14px; background: transparent; }
.sc-accordion--bordered .sc-accordion__item.is-open .sc-accordion__header { background: #f5f7fc; }
.sc-accordion--filled .sc-accordion__item.is-open .sc-accordion__header { background: var(--acc-soft); }
.sc-accordion--minimal .sc-accordion__item.is-open .sc-accordion__header { background: var(--acc-soft); border-radius: 10px 10px 0 0; }
.sc-accordion--minimal .sc-accordion__item.is-open .sc-accordion__title { color: var(--acc-deep); }
.sc-accordion__title { flex: 1; min-width: 0; font-size: 15px; font-weight: 600; color: var(--ink); }
.sc-accordion__chevron { flex: 0 0 auto; color: var(--acc); font-size: 13px; transition: transform .2s ease; }
.sc-accordion__item.is-open .sc-accordion__chevron { transform: rotate(180deg); }
.sc-accordion__inner { padding: 16px 20px 20px; font-size: 14.5px; line-height: 1.7; color: var(--ink-3); }
.sc-accordion__inner > p:first-child { margin-top: 0; }
.sc-accordion__inner > p:last-child { margin-bottom: 0; }

/* ===== Frise chronologique — 3 variantes POC =====
   0 Frise horizontale (pastilles reliées + cartes, défilement)  1 Frise
   verticale alternée (ligne centrale)  2 Cartes numérotées (grille).
   Numéros en compteur CSS (sc-tl) et liaisons via :first/:last-child :
   l'édition ajoute/retire des <li> sans renumérotation. */
/* Sélecteur qualifié (spécificité 0,1,1) comme la liste : neutralise le style
   natif UA du <ol> (list-style, padding-inline-start 40px, margin 1em) PARTOUT,
   y compris face aux règles `revert` de la carte éditeur (.sc-ed-card
   :where(ul, ol), editor.css, 0,1,0, plus tard dans la cascade). Sans ça,
   l'<ol> reprenait en éditeur son padding gauche de 40px + ses marges UA : la
   frise verticale se décalait vers la droite (ligne centrale et cartes
   alternées désaxées) alors que l'aperçu (player sans preflight) restait
   correctement centré. */
ol.sc-timeline { list-style: none; margin: 0; padding: 0; counter-reset: sc-tl; }
.sc-timeline__item { list-style: none; counter-increment: sc-tl; }
.sc-timeline__num { display: flex; align-items: center; justify-content: center; flex: 0 0 auto; background: var(--acc); color: #fff; font-weight: 700; }
.sc-timeline__num::before { content: counter(sc-tl); }
.sc-timeline__label { color: var(--acc); font-weight: 700; }
/* h4.… (0,1,1) : bat le `margin: revert` (UA ~1.33em) que la carte éditeur
   (.sc-ed-card :where(h4), 0,1,0) pose sur les titres — sinon le titre gagnait
   une marge haute UA en éditeur, décalant l'espacement par rapport à l'aperçu. */
h4.sc-timeline__title { margin: 0; font-weight: 700; color: var(--ink); }
.sc-timeline__body { color: var(--mut); }
.sc-timeline__body p { margin: 0 0 .5em; }
.sc-timeline__body > p:last-child { margin-bottom: 0; }
.sc-timeline__card { position: relative; background: #f7f9fc; border: 1.5px solid #eef1f6; border-radius: 14px; }
/* v0 Frise horizontale. */
.sc-timeline--h { display: flex; gap: 14px; overflow-x: auto; max-width: 100%; padding: 8px 2px; }
.sc-timeline--h .sc-timeline__item { flex: 0 0 180px; display: flex; flex-direction: column; }
.sc-timeline--h .sc-timeline__rail { display: flex; align-items: center; }
.sc-timeline--h .sc-timeline__line { flex: 1; height: 3px; background: var(--acc-line); }
.sc-timeline--h .sc-timeline__line:first-child { margin-left: -7px; }
.sc-timeline--h .sc-timeline__line:last-child { margin-right: -7px; }
.sc-timeline--h .sc-timeline__item:first-child .sc-timeline__line:first-child,
.sc-timeline--h .sc-timeline__item:last-child .sc-timeline__line:last-child { background: transparent; }
.sc-timeline--h .sc-timeline__num { width: 34px; height: 34px; border-radius: 50%; font-size: 14px; box-shadow: 0 4px 10px -3px color-mix(in srgb, var(--acc) 50%, transparent); }
.sc-timeline--h .sc-timeline__link { width: 2px; height: 16px; background: var(--acc-line); margin: 0 auto; }
.sc-timeline--h .sc-timeline__card { flex: 1; padding: 16px 16px 18px; }
.sc-timeline--h .sc-timeline__label { display: block; font-size: 11px; letter-spacing: .5px; text-transform: uppercase; margin-bottom: 8px; }
.sc-timeline--h .sc-timeline__title { font-size: 15.5px; margin-bottom: 5px; }
.sc-timeline--h .sc-timeline__body { font-size: 13.5px; line-height: 1.55; }
/* v1 Frise verticale alternée : cartes à gauche/à droite de la ligne centrale. */
/* v1 Frise verticale ALTERNÉE : ligne centrale, cartes une fois à gauche une
   fois à droite (retour Andrew : c'est bien l'alternance qui est voulue). La
   pastille est alignée en HAUT de sa carte (près de la date), pas flottante au
   milieu → alternance nette et cohérente en éditeur comme au player. */
.sc-timeline--v { position: relative; padding: 4px 0; }
.sc-timeline--v::before { content: ''; position: absolute; left: 50%; top: 16px; bottom: 16px; width: 2px; background: var(--acc-line); transform: translateX(-50%); }
.sc-timeline--v .sc-timeline__item { position: relative; display: grid; grid-template-columns: 1fr 44px 1fr; align-items: start; margin-bottom: 14px; }
.sc-timeline--v .sc-timeline__item:last-child { margin-bottom: 0; }
.sc-timeline--v .sc-timeline__card { grid-row: 1; grid-column: 1; padding: 14px 16px; text-align: right; }
.sc-timeline--v .sc-timeline__item:nth-child(even) .sc-timeline__card { grid-column: 3; text-align: left; }
.sc-timeline--v .sc-timeline__num { grid-row: 1; grid-column: 2; justify-self: center; align-self: start; margin-top: 2px; z-index: 2; width: 36px; height: 36px; border-radius: 50%; font-size: 14px; border: 3px solid #fff; box-shadow: 0 4px 10px -3px color-mix(in srgb, var(--acc) 50%, transparent); }
.sc-timeline--v .sc-timeline__label { display: inline-block; font-size: 11.5px; background: var(--acc-soft); padding: 3px 10px; border-radius: 99px; margin-bottom: 6px; }
.sc-timeline--v .sc-timeline__title { font-size: 16px; font-weight: 600; margin-bottom: 4px; }
.sc-timeline--v .sc-timeline__body { font-size: 14px; line-height: 1.55; }
/* v2 Cartes numérotées : grille de cartes, pastille carrée en tête. */
.sc-timeline--cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.sc-timeline--cards .sc-timeline__item { position: relative; border: 1.5px solid #eef1f6; border-radius: 16px; padding: 18px 18px 16px; background: #fafbfd; }
.sc-timeline--cards .sc-timeline__num { width: 38px; height: 38px; border-radius: 11px; font-size: 16px; margin-bottom: 13px; }
.sc-timeline--cards .sc-timeline__label { display: inline-block; font-size: 11.5px; margin-bottom: 6px; }
.sc-timeline--cards .sc-timeline__title { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.sc-timeline--cards .sc-timeline__body { font-size: 13px; line-height: 1.5; }

/* ===== Zones cliquables — 3 variantes POC =====
   0 Image + points (scène 220px)  1 Points + liste (scène 160px + détails)
   2 Numéros seuls (scène 280px). La scène garde un dégradé doux sous l'image ;
   les numéros (points et cartes) sont des compteurs CSS. */
.sc-hotspot__stage { position: relative; border-radius: 16px; background: linear-gradient(135deg, #e2e9fb, #eef1f6); height: 220px; counter-reset: sc-spot; }
.sc-hotspot--list .sc-hotspot__stage { height: 160px; }
.sc-hotspot--numbers .sc-hotspot__stage { height: 280px; }
/* object-fit: contain → l'image ENTIÈRE est visible (retour Andrew), au lieu
   d'être recadrée. Le fond dégradé du stage habille les marges éventuelles. */
.sc-hotspot__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; border-radius: inherit; }
.sc-hotspot__empty { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; color: #b7c3e6; }
.sc-hotspot__spot { position: absolute; transform: translate(-50%, -50%); display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; border: 3px solid #fff; background: var(--acc); color: #fff; font-family: inherit; font-size: 13px; font-weight: 700; cursor: pointer; padding: 0; box-shadow: 0 3px 10px rgba(27, 36, 64, .3); z-index: 4; counter-increment: sc-spot; }
.sc-hotspot__spot::before { content: counter(sc-spot); }
.sc-hotspot__spot.is-active { background: var(--ink); }
.sc-hotspot__popover { position: absolute; transform: translate(-50%, calc(-100% - 20px)); width: 220px; max-width: 78%; background: #fff; border-radius: 13px; padding: 12px 14px; box-shadow: 0 16px 34px -12px rgba(27, 36, 64, .5); z-index: 6; }
.sc-hotspot__poptitle { font-size: 14px; font-weight: 700; color: var(--ink); margin-bottom: 3px; }
.sc-hotspot__poptext { font-size: 13px; line-height: 1.5; color: var(--ink-3); }
/* v1 Points + liste : cartes de détail sous l'image (2 colonnes). */
.sc-hotspot__list { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; margin-top: 14px; counter-reset: sc-spotcard; }
.sc-hotspot__spotcard { display: flex; align-items: flex-start; gap: 11px; border: 1.5px solid #eef1f6; border-radius: 12px; padding: 11px 13px; counter-increment: sc-spotcard; }
.sc-hotspot__spotnum { display: flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 24px; height: 24px; border-radius: 50%; background: var(--acc); color: #fff; font-size: 12px; font-weight: 700; }
.sc-hotspot__spotnum::before { content: counter(sc-spotcard); }
.sc-hotspot__spotbody { flex: 1; min-width: 0; }
.sc-hotspot__spottitle { display: block; font-size: 14px; font-weight: 600; color: var(--ink); }
.sc-hotspot__spottext { display: block; font-size: 13px; color: var(--mut); margin-top: 2px; }

/* ===== Glisser-déposer — 3 variantes POC =====
   0 Colonnes (zones pointillées, 2 colonnes)  1 Cartes (zones pleines
   bordées)  2 Compact (zones fines, 1 colonne). Étiquettes : pilules
   accent-soft à poignée. */
.sc-dragdrop__instruction { margin: 0 0 14px; font-weight: 600; color: var(--ink); }
.sc-dragdrop__pool { display: flex; flex-wrap: wrap; gap: 8px; padding: 12px 14px; border: 2px dashed #d7deea; border-radius: 16px; min-height: 58px; margin-bottom: 14px; background: #fafbfd; }
.sc-dragdrop__chip { display: inline-flex; align-items: center; gap: 8px; padding: 9px 12px; border: 0; border-radius: 10px; background: var(--acc-soft); color: var(--acc); font: inherit; font-size: 14px; font-weight: 600; cursor: grab; transition: transform .15s, box-shadow .15s; }
.sc-dragdrop__chip:hover { transform: translateY(-1px); box-shadow: 0 3px 8px rgba(27, 36, 64, .14); }
.sc-dragdrop__grip { display: flex; align-items: center; justify-content: center; flex: 0 0 auto; width: 22px; height: 22px; border-radius: 6px; background: #fff; color: var(--acc); }
.sc-dragdrop__chip.is-selected { outline: 3px solid var(--acc); outline-offset: 1px; }
.sc-dragdrop__chip.is-right { background: var(--ok-bg); color: var(--ok); box-shadow: inset 0 0 0 1.5px var(--ok-line); }
.sc-dragdrop__chip.is-right .sc-dragdrop__grip { color: var(--ok); }
.sc-dragdrop__chip.is-wrong { background: color-mix(in srgb, var(--danger) 8%, #fff); color: var(--danger); box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--danger) 45%, #fff); }
.sc-dragdrop__chip.is-wrong .sc-dragdrop__grip { color: var(--danger); }
.sc-dragdrop__zones { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.sc-dragdrop--compact .sc-dragdrop__zones { grid-template-columns: 1fr; }
.sc-dragdrop__zone { display: flex; flex-wrap: wrap; gap: 8px; align-content: flex-start; transition: border-color .15s; }
.sc-dragdrop--cols .sc-dragdrop__zone { border: 2px dashed #d7deea; border-radius: 16px; padding: 16px 18px; min-height: 120px; }
.sc-dragdrop--cards .sc-dragdrop__zone { border: 1.5px solid var(--line); background: #fafbfd; border-radius: 16px; padding: 16px 18px; }
.sc-dragdrop--compact .sc-dragdrop__zone { border: 1.5px solid #eef1f6; border-radius: 14px; padding: 15px 17px; }
.sc-dragdrop__zone:hover { border-color: var(--acc-border); }
.sc-dragdrop__zone-name { width: 100%; margin: 0 0 4px; font-size: 13px; font-weight: 700; color: var(--acc); text-transform: uppercase; letter-spacing: .5px; }
.sc-dragdrop__footer { display: flex; align-items: center; gap: 1rem; margin-top: 14px; }
.sc-dragdrop__result { font-weight: 600; }

/* ===== Quiz QCM ===== */
.sc-quiz__question { border: 1px solid color-mix(in srgb, var(--ink) 15%, transparent); border-radius: 14px; padding: 1.1rem 1.25rem .9rem; margin: 0 0 1rem; transition: border-color .2s, background .2s; }
.sc-quiz__text { font-weight: 600; font-size: .95rem; padding: .2rem .8rem; border-radius: 999px; background: color-mix(in srgb, var(--acc) 10%, #fff); }
.sc-quiz__option { display: flex; align-items: center; gap: .6rem; padding: .4rem .55rem; border-radius: 8px; cursor: pointer; transition: background .15s; }
.sc-quiz__option:hover { background: color-mix(in srgb, var(--acc) 7%, transparent); }
.sc-quiz__option input { accent-color: var(--acc); }
.sc-quiz__question.is-right { border-color: color-mix(in srgb, var(--ok) 55%, transparent); background: color-mix(in srgb, var(--ok) 5%, #fff); }
.sc-quiz__question.is-wrong { border-color: color-mix(in srgb, var(--danger) 45%, transparent); background: color-mix(in srgb, var(--danger) 4%, #fff); }
.sc-quiz__question.is-right .sc-quiz__text { background: color-mix(in srgb, var(--ok) 12%, #fff); }
.sc-quiz__question.is-wrong .sc-quiz__text { background: color-mix(in srgb, var(--danger) 10%, #fff); }
.sc-quiz__feedback { font-size: .9rem; font-weight: 600; margin: .5rem 0 0; }
.sc-quiz__question.is-right .sc-quiz__feedback { color: var(--ok); }
.sc-quiz__question.is-wrong .sc-quiz__feedback { color: var(--danger); }
.sc-quiz__footer { display: flex; align-items: center; gap: 1rem; }
.sc-quiz__score { font-weight: 700; }
.sc-quiz.is-locked .sc-quiz__option { cursor: default; opacity: .85; }
.sc-quiz.is-locked .sc-quiz__option:hover { background: none; }
/* Quiz VERROUILLÉ (posé par quiz.js — lockUntilCourseDone) : carte cadenas en tête,
   questions/footer grisés et inertes tant que le cours n'est pas terminé. */
.sc-quiz.is-locked .sc-quiz__question,
.sc-quiz.is-locked .sc-quiz__footer { opacity: .45; filter: grayscale(1); pointer-events: none; user-select: none; }
.sc-quiz__lock { display: flex; align-items: center; gap: 1rem; padding: 1.1rem 1.3rem; margin: 0 0 1.2rem; border: 1.5px solid var(--acc-line); border-radius: 14px; background: var(--acc-bg); }
.sc-quiz__lock-icon { width: 44px; height: 44px; flex: 0 0 auto; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: var(--acc-soft); color: var(--acc); }
.sc-quiz__lock-body { display: flex; flex-direction: column; gap: .15rem; }
.sc-quiz__lock-title { font-weight: 700; color: var(--ink); }
.sc-quiz__lock-text { font-size: .9rem; color: var(--mut); }
/* Message legacy (conservé, plus utilisé par le nouveau verrou). */
.sc-quiz__gate { margin: .25rem 0 0; font-size: .92rem; font-weight: 600; color: var(--acc-deep, var(--acc)); }

/* ── Mode séquentiel (player) : une question à la fois, posé par init() via
   sc-quiz--seq / is-current — le rendu partagé (éditeur, HTML statique) montre
   toutes les questions et n'est jamais concerné. ── */
/* Stepper « 1 2 … N » : pilule claire, pastille courante pleine accent.
   Beaucoup de questions → la pilule est bornée à la largeur de la carte et défile
   horizontalement (barre masquée) ; la pastille courante est auto-centrée en JS. */
.sc-quiz__progress { position: relative; display: flex; align-items: center; gap: 3px; margin: 0 0 1.1rem; padding: 5px; border-radius: 99px; background: #f4f6fb; max-width: 100%; width: max-content; overflow-x: auto; scroll-behavior: smooth; scrollbar-width: none; -ms-overflow-style: none; }
.sc-quiz__progress::-webkit-scrollbar { display: none; }
.sc-quiz__step { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; min-width: 30px; height: 30px; padding: 0 5px; border-radius: 99px; font-size: 13.5px; font-weight: 700; color: var(--mut); }
.sc-quiz__step.is-current { background: var(--acc); color: #fff; }
.sc-quiz__step.is-done { color: var(--acc); }
.sc-quiz--seq .sc-quiz__question { display: none; }
.sc-quiz--seq .sc-quiz__question.is-current { display: block; animation: sc-quiz-step .2s ease both; }
/* Récapitulatif du bloc : carte POC (mêmes rayons/bordures que les questions). */
.sc-quiz__recap { border: 1px solid color-mix(in srgb, var(--ink) 15%, transparent); border-radius: 14px; padding: 1.1rem 1.25rem; animation: sc-quiz-step .2s ease both; }
.sc-quiz__recap-score { margin: 0 0 .9rem; font-weight: 600; }
.sc-quiz__recap-num { font-size: 1.35rem; font-weight: 700; color: var(--acc); margin-right: .35rem; }
.sc-quiz__recap-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .5rem; }
.sc-quiz__recap-item { display: block; font-size: .95rem; }
/* En-tête cliquable : ✓/✗ · intitulé · chevron (déplie le détail). */
.sc-quiz__recap-head { display: flex; align-items: center; gap: .6rem; width: 100%; padding: 0; border: 0; background: none; font: inherit; text-align: left; color: inherit; cursor: pointer; }
.sc-quiz__recap-q { flex: 1; min-width: 0; }
.sc-quiz__recap-chevron { flex: 0 0 auto; color: var(--mut); transition: transform .18s ease; }
.sc-quiz__recap-item.is-open .sc-quiz__recap-chevron { transform: rotate(180deg); }
.sc-quiz__recap-mark { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }
.sc-quiz__recap-item.is-right .sc-quiz__recap-mark { background: var(--ok-bg); color: var(--ok); box-shadow: inset 0 0 0 1.5px var(--ok-line); }
.sc-quiz__recap-item.is-wrong .sc-quiz__recap-mark { background: color-mix(in srgb, var(--danger) 8%, #fff); color: var(--danger); box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--danger) 45%, #fff); }
/* Détail dépliable : réponse donnée + bonne réponse (si faux). */
.sc-quiz__recap-detail { display: none; margin: .5rem 0 .1rem 2rem; padding: .65rem .85rem; border-radius: 10px; background: #f7f9fc; }
.sc-quiz__recap-item.is-open .sc-quiz__recap-detail { display: block; }
.sc-quiz__recap-answer { margin: .15rem 0; font-size: .9rem; color: var(--ink-2); }
.sc-quiz__recap-answer--ko { color: var(--danger); }
.sc-quiz__recap-answer--good { color: var(--ok); }
.sc-quiz__recap-explain { margin: .55rem 0 0; padding-top: .5rem; border-top: 1px dashed color-mix(in srgb, var(--ink) 14%, #fff); font-size: .88rem; line-height: 1.5; color: var(--ink-3); }
@keyframes sc-quiz-step { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
    .sc-quiz--seq .sc-quiz__question.is-current, .sc-quiz__recap { animation: none; }
}

/* ===== Paires à associer — 3 variantes POC (formatif) =====
   0 Deux colonnes (chips bordées)  1 Cartes reliées (cartes ombrées)  2 Compact (lignes fines). */
.sc-match__instruction { margin: 0 0 1rem; font-weight: 600; }
.sc-match__board { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 22px; align-items: start; }
.sc-match__col { display: flex; flex-direction: column; gap: 11px; }
.sc-match__item { display: block; width: 100%; text-align: left; font: inherit; font-size: 15px; cursor: pointer; transition: border-color .15s, background .15s, box-shadow .15s, outline-color .15s; }
/* v0 Deux colonnes : terme rempli gris-bleu, définition blanche bordée (POC). */
.sc-match__term { padding: 12px 15px; font-weight: 600; border-radius: 12px; border: 1.5px solid color-mix(in srgb, var(--ink) 22%, #fff); background: color-mix(in srgb, var(--ink) 5%, #fff); color: var(--ink); }
.sc-match__def { padding: 12px 15px; font-weight: 600; border-radius: 12px; border: 1.5px solid color-mix(in srgb, var(--ink) 14%, #fff); background: #fff; color: var(--ink-3); }
/* v1 Cartes reliées : cartes ombrées, terme teinté accent (POC). */
.sc-match--cards .sc-match__item { border-radius: 14px; box-shadow: 0 1px 4px rgba(27, 36, 64, .10); }
.sc-match--cards .sc-match__term { background: var(--acc-soft); border-color: var(--acc-soft); font-weight: 700; }
/* v2 Compact : lignes fines séparées, sans habillage (POC). */
.sc-match--compact .sc-match__board { gap: 0 18px; }
.sc-match--compact .sc-match__col { gap: 0; }
.sc-match--compact .sc-match__item { padding: 10px 4px; border: 0; border-radius: 0; border-bottom: 1px solid color-mix(in srgb, var(--ink) 10%, #fff); background: none; font-size: 14px; }
.sc-match--compact .sc-match__def { color: var(--mut); font-weight: 500; }
/* États player : sélection, paire trouvée (verrouillée), tentative ratée. */
.sc-match__item.is-selected { outline: 3px solid var(--acc); outline-offset: -1px; background: var(--acc-soft); }
.sc-match__item.is-matched { border-color: var(--ok-line); background: var(--ok-bg); color: var(--ok); cursor: default; }
.sc-match--compact .sc-match__item.is-matched { border-bottom-color: var(--ok-line); }
.sc-match__item.is-wrong { outline: 3px solid var(--danger); outline-offset: -1px; background: color-mix(in srgb, var(--danger) 8%, #fff); }
.sc-match__footer { display: flex; align-items: center; gap: 1rem; margin-top: 1.1rem; }
.sc-match__result { font-weight: 600; }
.sc-match__result.is-ok { color: var(--ok); }

/* ===== Texte à trous (formatif, sans variantes) ===== */
.sc-fill__text { margin: 0; font-size: 17px; line-height: 2.1; color: var(--ink); white-space: pre-wrap; }
/* vertical-align: middle → le trou (police 15px + padding/bordure) reste centré sur
   la ligne de texte (17px) au lieu de retomber sur la baseline et de « remonter ». */
.sc-fill__gap { display: inline-block; vertical-align: middle; margin: 0 3px; }
.sc-fill__input { font: inherit; font-size: 15px; text-align: center; padding: 2px 10px; border: 1.5px dashed color-mix(in srgb, var(--acc) 55%, #fff); border-radius: 8px; background: var(--acc-soft); color: var(--ink); outline: none; transition: border-color .15s, background .15s; }
.sc-fill__input:focus { border-color: var(--acc); border-style: solid; }
.sc-fill__gap.is-right .sc-fill__input { border: 1.5px solid var(--ok-line); background: var(--ok-bg); color: var(--ok); font-weight: 700; }
.sc-fill__gap.is-wrong .sc-fill__input { border: 1.5px solid var(--danger); background: color-mix(in srgb, var(--danger) 8%, #fff); color: var(--danger); }
/* À la validation : le trou affiche le VRAI terme en vert (saisie remplacée). */
.sc-fill__gap.is-revealed .sc-fill__input { border: 1.5px solid var(--ok-line); background: var(--ok-bg); color: var(--ok); font-weight: 700; opacity: 1; }
/* Bonne réponse affichée sous un trou faux. */
.sc-fill__footer { display: flex; align-items: center; gap: 1rem; margin-top: 1.1rem; }
.sc-fill__result { font-weight: 700; }
.sc-fill__result.is-ok { color: var(--ok); }

/* ===== Remettre dans l'ordre — 3 variantes POC (formatif) =====
   0 Étapes (lignes bordées)  1 Cartes (fond gris, pastille accent pleine)  2 Compact (lignes fines). */
.sc-order__instruction { margin: 0 0 1rem; font-weight: 600; }
.sc-order__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 11px; }
.sc-order__item { display: flex; align-items: center; gap: 13px; padding: 12px 14px; border-radius: 13px; border: 1.5px solid color-mix(in srgb, var(--ink) 12%, #fff); transition: border-color .15s, background .15s; }
/* Glisser-déposer (PLAYER / aperçu / export uniquement) : affordance + état tiré + indicateur d'insertion (filet accent). */
.sc-order__item--drag { cursor: grab; }
.sc-order__item--drag:active { cursor: grabbing; }
.sc-order__item.is-dragging { opacity: .5; cursor: grabbing; }
.sc-order__item.is-drop-before { box-shadow: 0 -2px 0 0 var(--acc); }
.sc-order__item.is-drop-after { box-shadow: 0 2px 0 0 var(--acc); }
.sc-order__num { width: 28px; height: 28px; border-radius: 8px; background: var(--acc-soft); color: var(--acc); font-weight: 700; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; }
.sc-order__text { flex: 1; font-size: 15px; color: var(--ink); }
/* v1 Cartes : fond gris clair, pastille accent pleine 34px (POC). */
.sc-order--cards .sc-order__item { padding: 16px; border-radius: 14px; border-color: color-mix(in srgb, var(--ink) 8%, #fff); background: color-mix(in srgb, var(--ink) 3%, #fff); }
.sc-order--cards .sc-order__num { width: 34px; height: 34px; border-radius: 10px; background: var(--acc); color: #fff; font-size: 15px; }
/* v2 Compact : lignes fines, pastille 24px (POC). */
.sc-order--compact .sc-order__list { gap: 0; }
.sc-order--compact .sc-order__item { padding: 10px 2px; border: 0; border-radius: 0; border-bottom: 1px solid color-mix(in srgb, var(--ink) 10%, #fff); }
.sc-order--compact .sc-order__num { width: 24px; height: 24px; border-radius: 7px; font-size: 12px; }
/* Boutons ↑↓ du player. */
.sc-order__ctrl { display: flex; gap: 2px; flex: 0 0 auto; }
.sc-order__move { width: 26px; height: 26px; border-radius: 7px; border: 0; background: transparent; color: color-mix(in srgb, var(--ink) 55%, #fff); cursor: pointer; font: inherit; font-size: 13px; padding: 0; transition: background .15s, color .15s; }
.sc-order__move:hover { background: color-mix(in srgb, var(--ink) 7%, #fff); color: var(--acc); }
/* Feedback par position. */
.sc-order__item.is-right { border-color: var(--ok-line); background: var(--ok-bg); }
.sc-order__item.is-right .sc-order__num { background: var(--ok); color: #fff; }
.sc-order--compact .sc-order__item.is-right { border-bottom-color: var(--ok-line); }
.sc-order__item.is-wrong { border-color: color-mix(in srgb, var(--danger) 45%, #fff); background: color-mix(in srgb, var(--danger) 5%, #fff); }
.sc-order--compact .sc-order__item.is-wrong { border-bottom-color: color-mix(in srgb, var(--danger) 45%, #fff); }
.sc-order__footer { display: flex; align-items: center; gap: 1rem; margin-top: 1.1rem; }
.sc-order__result { font-weight: 600; }
.sc-order__result.is-ok { color: var(--ok); }
