/* modules.css — modules HTML de contenu (…/contenu/*.html). À charger après charte.css et jeux.css.
   Remplace le CSS inline commun des modules ; les composants propres à un module restent dans son <style>. */
:root {
  --c-blue: #1D6FA5; --c-blue-light: #E5EFF6; --c-blue-dark: #0B2E45;
  --c-teal: #1D9E75; --c-teal-light: #E1F5EE; --c-teal-dark: #04342C;
  --c-red: #E24B4A; --c-red-light: #FCEBEB; --c-red-dark: #501313;
  --c-amber: #BA7517; --c-amber-light: #FAEEDA; --c-amber-dark: #412402;
  --c-gray-bg: #F8F7F4; --c-gray-border: #D3D1C7; --c-gray-text: #5F5E5A;
  --c-text: #1a1a18; --c-text-muted: #888780;
  --radius: 14px; --radius-sm: 8px;
}
#screen-main { display: flex; flex-direction: column; min-height: 100vh; }

/* En-tête : hero de la charte + barre de progression sous le titre */
.hero-text, .hero-banner-img, .hero-title, .hero-sub { }
.hero-in .hero-logo.hero-banner-img { height: 84px; width: auto; }
.hero .progress-block { order: 4; flex: 0 0 100%; text-align: left; min-width: 0; max-width: 420px; margin-top: 0.25rem; }
.progress-label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 0.5rem; margin-bottom: 0.25rem; }
.progress-caption { font-size: 0.62rem; text-transform: uppercase; letter-spacing: 0.06em; color: #BFD0E3; font-weight: 600; }
.progress-pct { font-size: 0.85rem; font-weight: 700; color: #fff; font-variant-numeric: tabular-nums; }
.progress-track { width: 100%; height: 8px; border-radius: 999px; background: rgba(255,255,255,0.16); overflow: hidden; box-shadow: inset 0 2px 3px rgba(0,0,0,0.3); }
.progress-fill { height: 100%; border-radius: 999px; background: linear-gradient(180deg, #F2C98A, var(--blason-gold)); transition: width 0.4s ease; }

/* Onglets */
.tabs { display: flex; gap: 0.25rem; overflow-x: auto; padding: 0 1.25rem; background: #fff; box-shadow: 0 3px 0 #C3CEDB; position: relative; z-index: 1; }
.tab { padding: 0.7rem 1.05rem; font-size: 0.86rem; cursor: pointer; border-bottom: 3px solid transparent; white-space: nowrap; color: var(--ink-soft); font-weight: 600; transition: color 0.15s, border-color 0.15s; }
.tab:hover { color: var(--ink); }
.tab.active { color: var(--deep); border-bottom-color: var(--deep); }

/* Sections */
.section { display: none; padding: 1.5rem 1.25rem 2.5rem; max-width: 760px; margin: 0 auto; width: 100%; }
.section.active { display: block; }
.section-header { margin-bottom: 1.3rem; }
.section-eyebrow { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--deep); font-weight: 700; margin-bottom: 0.3rem; }
.section .section-title { display: block; margin: 0; font-family: var(--f-title); font-size: 1.75rem; font-weight: 700; line-height: 1.1; }
.section .section-sub { font-size: 0.88rem; color: var(--ink-soft); margin-top: 0.35rem; }

/* Cartes de contenu */
.content-card, .cas-card { background: linear-gradient(180deg, #FFFFFF, #F4F7FB); border-radius: 16px; padding: 1.15rem 1.25rem; margin-bottom: 0.9rem; box-shadow: inset 0 2px 0 #FFFFFF, 0 3px 0 #C3CEDB, var(--shadow-soft); }
.content-card h3 { font-family: var(--f-title); font-size: 1.2rem; font-weight: 700; line-height: 1.15; margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.5rem; }
.content-card h3 .i { color: var(--deep); font-size: 1.15em; }
.content-card p, .content-card li { font-size: 0.9rem; color: #2A3B4D; line-height: 1.6; }
.content-card ul { padding-left: 1.15rem; }
.content-card li { margin-bottom: 0.2rem; }
.content-card .i, .cas-card .i, .tip-box .i, .warn-box .i, .callout-tip .i, .callout-warn .i, .quote-box .i, .data-table .i, .compare-table .i { vertical-align: -0.14em; }

/* Encadrés */
.callout-warn, .warn-box { background: var(--c-red-light); border-radius: 12px; padding: 0.85rem 1rem; font-size: 0.84rem; color: var(--c-red-dark); margin-bottom: 0.75rem; line-height: 1.5; box-shadow: inset 4px 0 0 var(--c-red), 0 2px 0 #E8B4B0; }
.callout-warn { font-weight: 600; }
.callout-tip { background: var(--c-teal-light); border-radius: 12px; padding: 0.85rem 1rem; font-size: 0.84rem; color: var(--c-teal-dark); margin-bottom: 0.75rem; line-height: 1.5; box-shadow: inset 4px 0 0 var(--c-teal), 0 2px 0 #A9D9C7; }
.tip-box { background: #EDF2FB; border-radius: 12px; padding: 0.7rem 1rem; font-size: 0.82rem; color: #0C447C; margin-top: 0.75rem; line-height: 1.5; box-shadow: inset 4px 0 0 #185FA5, 0 2px 0 #B5C7E3; }
.quote-box { background: #FAEDC8; border-radius: 12px; padding: 0.7rem 0.9rem; font-size: 0.88rem; font-style: italic; color: #4A3008; font-weight: 600; text-align: center; margin: 0.6rem 0; box-shadow: 0 2px 0 #D2B063; }

/* Listes à puces numérotées, tableaux */
.checklist { list-style: none; padding: 0; }
.checklist li { background: #fff; border-radius: 12px; padding: 0.7rem 1rem; margin-bottom: 0.5rem; font-size: 0.88rem; display: flex; gap: 0.6rem; align-items: flex-start; box-shadow: inset 0 0 0 1px #D5DDE8, 0 2px 0 #C3CEDB; }
.checklist li .num { flex-shrink: 0; width: 24px; height: 24px; border-radius: 50%; background: var(--bg); color: var(--deep); font-size: 0.74rem; font-weight: 700; display: flex; align-items: center; justify-content: center; }
.data-table, .compare-table { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 0.82rem; margin-top: 0.5rem; border-radius: 12px; overflow: hidden; box-shadow: 0 2px 0 #C3CEDB, inset 0 0 0 1px #D5DDE8; }
.data-table th, .compare-table th { background: var(--navy); color: #fff; padding: 0.55rem 0.65rem; text-align: left; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.04em; }
.data-table td, .compare-table td { padding: 0.55rem 0.65rem; border-bottom: 1px solid #E1E7EF; color: #2A3B4D; line-height: 1.5; vertical-align: top; }
.data-table tr:nth-child(even) td, .compare-table tr:nth-child(even) td { background: #F4F7FB; }

/* Pastilles */
.tag { display: inline-block; font-size: 0.68rem; font-weight: 700; padding: 2px 9px; border-radius: 999px; margin-right: 4px; margin-bottom: 4px; text-transform: uppercase; letter-spacing: 0.04em; }
.tag-ok { background: var(--c-teal-light); color: var(--c-teal-dark); }
.tag-warning { background: var(--c-amber-light); color: var(--c-amber-dark); }
.tag-danger { background: var(--c-red-light); color: var(--c-red-dark); }
.badge { font-size: 0.7rem; font-weight: 700; padding: 3px 10px; border-radius: 999px; letter-spacing: 0.04em; text-transform: uppercase; }

/* Cas pratiques : scénario / question / réponse masquée */
.cas-scenario { font-size: 0.9rem; line-height: 1.6; background: #EEF2F7; border-radius: 12px; padding: 0.75rem 1rem; margin-bottom: 1rem; box-shadow: inset 4px 0 0 var(--deep); }
.cas-question { font-size: 0.9rem; font-weight: 600; margin-bottom: 0.75rem; }
.cas-reveal { display: none; margin-top: 0.75rem; padding: 0.75rem 1rem; background: var(--c-teal-light); border-radius: 12px; font-size: 0.84rem; color: var(--c-teal-dark); line-height: 1.5; box-shadow: inset 4px 0 0 var(--c-teal); }
.cas-reveal.show { display: block; }
.cas-reveal strong { font-weight: 700; }

/* Boutons du module (même rendu que les jeux) */
.btn-row { margin-top: 1.25rem; }
.btn-primary { background: linear-gradient(180deg, var(--navy-hi), var(--navy)); color: #fff; }

/* Écran de score (modules avec QCM) */
#screen-score { align-items: center; justify-content: center; min-height: 100vh; padding: 2rem 1.25rem; text-align: center; }
#screen-score .score-detail { max-width: 380px; line-height: 1.6; }
#screen-score .score-grid { max-width: 440px; width: 100%; margin: 1.5rem auto; }
.back-index:hover { color: var(--deep); }
@media (max-width: 640px) { .section { padding: 1.2rem 1rem 2rem; } .tabs { padding: 0 0.6rem; } }
