/* Menus, pages et écrans de choix (chantier des menus, porteur, 15 nov. 2026 : « un truc pro, vraiment un vrai jeu
   vidéo ») : conception/menus.md. Même charte que style.css (ardoise, coins coupés, laiton clair pour l'appel), plus :
   - le fond animé de l'accueil (plans du jeu qui se succèdent en fondu, lente caméra, poussière dans la lumière) ;
   - les pages (en-tête : retour, titre, étapes en onglets ; corps ; pied avec l'action principale à droite) ;
   - les grandes cartes (image, emblème au trait, nom en capitales, une phrase, pied ; contour qui s'allume au choix). */

/* ---------- Fond animé ---------- */
#accueil .fond { background: var(--nuit); z-index: 0; pointer-events: none; }
#accueil > section { z-index: 1; }
#accueil .fond::after { z-index: 2; }
.plans { position: absolute; inset: 0; overflow: hidden; }
.plans .plan { position: absolute; inset: -4%; background: center / cover no-repeat; opacity: 0; transition: opacity 1.8s ease; will-change: opacity, transform; }
.plans .plan.on { opacity: 1; }
.plans .plan.anim { animation: camera var(--duree, 11s) linear both; }
@keyframes camera {
  from { transform: scale(1.04) translate3d(var(--x0, 0%), var(--y0, 0%), 0); }
  to { transform: scale(1.16) translate3d(var(--x1, -2%), var(--y1, -1%), 0); }
}
/* Un reflet de lumière qui passe lentement, comme une lueur dans la poussière. */
.plans::after { content: ''; position: absolute; inset: -20% -60%; z-index: 1; pointer-events: none; mix-blend-mode: screen;
  background: linear-gradient(105deg, transparent 38%, rgba(255, 228, 170, .07) 46%, rgba(255, 228, 170, .13) 50%, rgba(255, 228, 170, .07) 54%, transparent 62%);
  animation: lueur 14s ease-in-out infinite; }
@keyframes lueur { 0% { transform: translateX(-30%); } 50% { transform: translateX(30%); } 100% { transform: translateX(-30%); } }
.fond canvas.poussiere { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 3; pointer-events: none; }
/* Pages et choix : le fond se fait discret derrière (flou léger, plus sombre). */
#accueil[data-ecran]:not([data-ecran="ecran-titre"]):not([data-ecran="menu"]) .plans { filter: blur(5px) brightness(.55) saturate(.8); transform: scale(1.04); }
.plans { transition: filter .4s, transform .4s; }
@media (prefers-reduced-motion: reduce) { .plans .plan.anim, .plans::after { animation: none; } }
/* Fond en vraie 3D (15 nov. 2026, soir : « les images statiques comme un diaporama, ça fait cheap ») : la carte du jeu se
   voit à travers l'accueil (menu3d.js) ; les plans d'images ne servent plus. Fondu au noir court entre deux plans. */
#accueil.trois-d { background: transparent; }
#accueil.trois-d .fond { background: none; }
#accueil.trois-d .plans { display: none; }
#accueil .voile3d { position: absolute; inset: 0; z-index: 1; background: #07090c; opacity: 0; transition: opacity .5s ease; pointer-events: none; }
#accueil .voile3d.noir { opacity: 1; }
#accueil.trois-d[data-ecran]:not([data-ecran="ecran-titre"]):not([data-ecran="menu"]) .fond::after { background: rgba(8, 10, 13, .66); }

/* ---------- Lancement, rideau des transitions, mot de la fin ---------- */
#demarrage, #rideau { position: fixed; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  background: var(--nuit); }
#demarrage { z-index: 90; transition: opacity .45s ease; }
#demarrage.fini { opacity: 0; pointer-events: none; }
#demarrage img { width: min(56vw, 460px, 90vh); height: auto; }
#demarrage .barre, #rideau .barre { width: min(320px, 62vw); height: 4px; background: rgba(255, 255, 255, .12); }
#demarrage .barre i, #rideau .barre i { display: block; height: 100%; width: 0; background: var(--accent); transition: width .25s; }
#demarrage p { margin: 0; font: 700 15px var(--titre); letter-spacing: .3em; text-transform: uppercase; color: var(--pale); }
#demarrage small { min-height: 1.2em; font: 600 14px var(--titre); letter-spacing: .12em; color: var(--pale); }
#rideau { z-index: 80; opacity: 0; transition: opacity .25s ease; pointer-events: none; }
#rideau.plein { opacity: 1; pointer-events: auto; }
#rideau img { width: min(34vw, 260px, 60vh); height: auto; opacity: .35; }
#rideau .barre { visibility: hidden; }
#rideau.charge .barre { visibility: visible; }
#fin-mot { position: fixed; inset: 0; z-index: 45; display: grid; place-items: center; pointer-events: none;
  font: 900 clamp(46px, 10vw, 118px)/1 var(--titre); letter-spacing: .16em; text-transform: uppercase; color: var(--accent);
  text-shadow: 0 0 26px rgba(240, 212, 138, .45), 0 4px 18px #000c; }
#fin-mot[data-issue="defaite"], #fin-mot[data-issue="egalite"] { color: var(--ivoire); text-shadow: 0 0 22px rgba(255, 255, 255, .25), 0 4px 18px #000c; }
#fin-mot.on { animation: fin-mot 1.85s ease both; }
@keyframes fin-mot { 0% { opacity: 0; transform: scale(1.22); letter-spacing: .34em; } 18% { opacity: 1; transform: scale(1); letter-spacing: .16em; }
  78% { opacity: 1; transform: scale(.99); } 100% { opacity: 0; transform: scale(.97); } }
#pvp-fin, #fin { transition: opacity .5s ease; }
#pvp-fin.attend, #fin.attend { opacity: 0; pointer-events: none; }

/* ---------- Menu principal ---------- */
.m-item { position: relative; }
.m-item[disabled] { cursor: default; opacity: .55; }
.m-item[disabled]:hover { border-left-color: transparent; background: linear-gradient(90deg, rgba(13, 16, 21, .82), rgba(13, 16, 21, .4)); }
.m-item .bientot { position: absolute; right: 22px; top: 50%; transform: translateY(-50%); font: 700 12px/1 var(--titre); font-style: normal; letter-spacing: .18em;
  text-transform: uppercase; color: var(--accent); padding: 5px 8px; box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .5); }
.m-item .emb { width: 36px; height: 36px; flex: none; }
/* Une entrée choisie (survol ou clavier) : le trait laiton à gauche et l'emblème qui s'allume. */
.m-item:not([disabled]):hover .emb, .m-item:focus-visible .emb { color: var(--accent); }
.m-item small { max-width: 270px; }

/* Emblème au trait (planche Codex, img/emblemes/) teinté par la couleur du texte. */
.emb { display: inline-block; background: currentColor; -webkit-mask: var(--e) center / contain no-repeat; mask: var(--e) center / contain no-repeat; }

/* Coin haut droit : la bourse (pièces) et la boutique. */
.m-haut { position: absolute; z-index: 3; top: max(14px, env(safe-area-inset-top)); right: max(16px, env(safe-area-inset-right)); display: flex; gap: 8px; align-items: center; }

/* ---------- Pages ---------- */
#accueil > section.page { justify-content: flex-start; align-items: stretch; gap: clamp(8px, 2.4vh, 18px); }
.p-tete { display: flex; align-items: center; gap: 14px; min-height: 44px; flex: none; }
.p-tete h2 { margin: 0; font: 700 34px/1 var(--titre); letter-spacing: .14em; text-transform: uppercase; white-space: nowrap; }
.p-etapes { margin-left: auto; display: flex; gap: 2px; background: rgba(13, 16, 21, .7); clip-path: var(--coin-petit); }
.p-etapes span { display: flex; align-items: center; gap: 8px; padding: 10px 16px; font: 700 15px/1 var(--titre); letter-spacing: .12em;
  text-transform: uppercase; color: var(--pale); white-space: nowrap; }
.p-etapes span i { font-style: normal; display: grid; place-items: center; width: 20px; height: 20px; font-size: 13px; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .3); }
.p-etapes span.on { color: #15120c; background: var(--accent); }
.p-etapes span.on i { box-shadow: inset 0 0 0 1px rgba(21, 18, 12, .5); }
.p-etapes span.fait { color: var(--ivoire); }
.p-corps { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; gap: 14px; }
.p-pied { flex: none; display: flex; align-items: center; justify-content: flex-end; gap: 12px; min-height: 48px; }
.p-pied .p-note { margin-right: auto; font: 500 16px/1.2 var(--texte); color: var(--pale); }

/* ---------- Grandes cartes (modes, cartes, niveaux) ---------- */
.gcs { display: flex; gap: 14px; justify-content: center; align-items: stretch; height: 100%; max-height: 520px; width: 100%; }
.gc { position: relative; flex: 1 1 0; max-width: 340px; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
  gap: 8px; padding: 18px 16px 14px; text-align: center; overflow: hidden; clip-path: var(--coin); color: var(--ivoire);
  background: #11151b var(--img, none) center / cover no-repeat; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); transition: box-shadow .15s, transform .12s; }
.gc::before { content: ''; position: absolute; inset: 0; z-index: 0; transition: background .2s;
  background: linear-gradient(180deg, rgba(9, 11, 15, .55) 0%, rgba(9, 11, 15, .35) 35%, rgba(9, 11, 15, .82) 70%, rgba(9, 11, 15, .96) 100%); }
.gc > * { position: relative; z-index: 1; }
.gc .emb { width: clamp(56px, 16vh, 108px); height: clamp(56px, 16vh, 108px); margin: auto 0 4px; color: var(--ivoire); filter: drop-shadow(0 2px 6px #000c); transition: color .15s; }
.gc b { font: 700 30px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; text-shadow: var(--ombre); }
.gc small { font: 500 16px/1.2 var(--texte); color: rgba(243, 239, 230, .78); max-width: 280px; }
.gc .gc-pied { width: 100%; margin-top: 4px; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, .18); font: 700 13px/1 var(--titre);
  letter-spacing: .18em; text-transform: uppercase; color: var(--pale); display: flex; justify-content: center; gap: 12px; }
.gc:hover { box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .6); }
.gc:active { transform: translateY(1px); }
/* Choisie : le contour s'allume (laiton), l'emblème et le nom aussi, un trait épais en bas. */
.gc.on { box-shadow: inset 0 0 0 2px var(--accent), inset 0 -5px 0 var(--accent), inset 0 0 40px rgba(240, 212, 138, .22); }
.gc.on::before { background: linear-gradient(180deg, rgba(60, 42, 10, .35) 0%, rgba(9, 11, 15, .25) 35%, rgba(20, 16, 8, .8) 70%, rgba(14, 11, 6, .95) 100%); }
.gc.on .emb, .gc.on b { color: var(--accent); }
.gc[disabled] { cursor: default; filter: grayscale(.8) brightness(.6); }

@media (max-height: 430px) {
  .p-tete { min-height: 40px; gap: 10px; } .p-tete h2 { font-size: 24px; }
  .p-etapes span { padding: 8px 10px; font-size: 13px; gap: 6px; } .p-etapes span i { width: 17px; height: 17px; font-size: 11px; }
  .p-pied { min-height: 40px; } .p-pied .p-note { font-size: 14px; }
  .gcs { gap: 10px; } .gc { padding: 10px 10px 9px; gap: 4px; } .gc b { font-size: 22px; } .gc small { font-size: 13px; }
  .gc .gc-pied { font-size: 11px; padding-top: 5px; margin-top: 2px; }
  .m-item .emb { width: 28px; height: 28px; } .m-item small { max-width: 220px; } .m-item .bientot { right: 16px; font-size: 10px; padding: 4px 6px; }
}
@media (orientation: portrait) {
  .gcs { flex-direction: column; max-height: none; } .gc { max-width: none; }
  .p-etapes span { padding: 8px 9px; } .p-etapes span:not(.on) b { display: none; }
}

/* ---------- L'équipement : trois blocs (personnage, atouts, classe) ---------- */
#eq-blocs { width: 100%; height: 100%; max-height: 540px; }
.blocs { display: flex; gap: 14px; justify-content: center; }
.blocs.ligne { height: 100%; align-items: stretch; }
.bloc { position: relative; flex: 1 1 0; max-width: 360px; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 12px 14px 14px; clip-path: var(--coin); background: linear-gradient(180deg, rgba(20, 25, 32, .92), rgba(11, 13, 17, .94));
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); text-align: center; overflow: hidden; transition: box-shadow .15s; }
.bloc:hover, .bloc:focus-visible { box-shadow: inset 0 0 0 2px var(--accent), inset 0 0 40px rgba(240, 212, 138, .14); outline: none; }
.bloc:hover .bl-tete, .bloc:focus-visible .bl-tete { color: var(--accent); }
.bloc:active { transform: translateY(1px); }
.bl-tete { align-self: stretch; display: flex; align-items: center; gap: 8px; padding-bottom: 8px; border-bottom: 1px solid var(--filet); color: var(--pale); transition: color .15s; }
.bl-tete .emb { width: 22px; height: 22px; }
.bl-tete small { font: 700 15px/1 var(--titre); letter-spacing: .2em; text-transform: uppercase; }
.bloc::after { content: ''; position: absolute; right: 12px; top: 12px; width: 9px; height: 9px; border-right: 2px solid var(--pale); border-bottom: 2px solid var(--pale); transform: rotate(-45deg); opacity: .7; }
.bloc > b { font: 700 26px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; }
.bl-perso { flex: 1; min-height: 0; width: 100%; object-fit: contain; filter: drop-shadow(0 8px 14px #000b); }
.bl-atouts { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 14px; align-self: stretch; }
.bl-at { display: flex; align-items: center; gap: 12px; text-align: left; }
.bl-at .emb { width: 54px; height: 54px; flex: none; color: var(--accent); }
.bl-at > span { display: flex; flex-direction: column; min-width: 0; }
.bl-at b { font: 700 21px/1.05 var(--titre); letter-spacing: .06em; text-transform: uppercase; }
.bl-at small { font: 500 15px/1.15 var(--texte); color: var(--pale); }
.bl-classe { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.bl-classe img { width: 30px; height: 30px; }
.bl-classe b { font: 700 26px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.bl-arme { flex: 1; min-height: 0; width: 92%; object-fit: contain; }
.bl-ligne { font: 700 18px/1 var(--titre); letter-spacing: .06em; text-transform: uppercase; }
.bl-sous { align-self: stretch; display: flex; justify-content: space-between; gap: 8px; padding-top: 8px; border-top: 1px solid var(--filet);
  font: 600 14px/1.1 var(--texte); color: var(--pale); }
.bl-sous > span { display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.bl-sous img { height: 20px; width: 20px; object-fit: contain; }
.bl-sous img.bl-sec { width: 46px; }
/* En colonne (disposition gardée, plus utilisée depuis la fin de la campagne) : trois blocs couchés, l'un sous l'autre. */
.blocs.colonne { flex-direction: column; gap: 8px; }
.blocs.colonne .bloc { max-width: none; flex: 1 1 0; display: grid; grid-template-columns: 76px 1fr; grid-template-rows: auto 1fr; align-items: center; text-align: left; padding: 8px 12px; gap: 2px 12px; }
.blocs.colonne .bl-tete { grid-column: 1 / 3; padding-bottom: 4px; }
.blocs.colonne .bl-perso { grid-row: 2; height: 100%; max-height: 90px; }
.blocs.colonne .bloc > b { font-size: 22px; }
.blocs.colonne .bl-atouts { grid-column: 1 / 3; flex-direction: row; gap: 10px; }
.blocs.colonne .bl-at { flex: 1; gap: 8px; } .blocs.colonne .bl-at .emb { width: 36px; height: 36px; }
.blocs.colonne .bl-at b { font-size: 16px; } .blocs.colonne .bl-at small { font-size: 12.5px; }
.blocs.colonne [data-b="equipement"] { grid-template-columns: 1fr 1fr; }
.blocs.colonne .bl-classe { margin: 0; } .blocs.colonne .bl-classe b { font-size: 20px; } .blocs.colonne .bl-classe img { width: 24px; height: 24px; }
.blocs.colonne .bl-arme { width: 100%; height: 38px; grid-row: 2; grid-column: 2; }
.blocs.colonne .bl-ligne, .blocs.colonne .bl-sous { display: none; }

/* ---------- Fenêtres (personnage, atouts, équipement) : au-dessus de tout ---------- */
.fenetre { position: fixed; inset: 0; z-index: 40; display: flex; align-items: center; justify-content: center;
  padding: max(14px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(14px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  background: radial-gradient(ellipse at 50% 40%, #12161d, #06080b); }
.fe-boite { width: min(1120px, 100%); max-height: 100%; height: 100%; display: flex; flex-direction: column; gap: 12px; }
.fe-tete { display: flex; align-items: center; gap: 14px; min-height: 44px; flex: none; }
.fe-tete h2 { margin: 0; font: 700 32px/1 var(--titre); letter-spacing: .14em; text-transform: uppercase; }
.fe-bourse { margin-left: auto; display: flex; align-items: center; gap: 8px; font: 700 22px/1 var(--texte); color: var(--accent); }
.fe-bourse .emb { width: 26px; height: 26px; }
.fe-bourse:empty { display: none; }
.fe-pied { flex: none; display: flex; justify-content: flex-end; gap: 12px; }
.fe-aide { margin: -4px 0 0; font: 500 17px var(--texte); color: var(--pale); }
.fe-prix { display: flex; align-items: center; gap: 5px; font: 700 15px/1 var(--texte); color: var(--accent); }
.fe-prix .emb { width: 16px; height: 16px; }
.ferme { opacity: .72; } .ferme img, .ferme .emb { filter: brightness(.55); }
.refus { animation: refus .35s; }
@keyframes refus { 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
.fe-blocs { flex: 1; min-height: 0; } .fe-blocs .blocs { height: 100%; }

.fe-persos { flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.fe-perso, .fe-atout, .fe-arme, .fe-cl { clip-path: var(--coin-petit); background: rgba(16, 20, 26, .94); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); transition: box-shadow .12s; }
.fe-perso:hover, .fe-atout:hover, .fe-arme:not([disabled]):hover, .fe-cl:hover { box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .7); }
.fe-perso.on, .fe-atout.on, .fe-arme.on, .fe-cl.on { box-shadow: inset 0 0 0 2px var(--accent), inset 0 -4px 0 var(--accent); background: linear-gradient(180deg, rgba(240, 212, 138, .2), rgba(240, 212, 138, .06)); }
.fe-perso { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 12px 8px; min-height: 0; }
.fe-perso img { flex: 1; min-height: 0; width: 100%; object-fit: contain; filter: drop-shadow(0 6px 10px #000a); }
.fe-perso b { font: 700 24px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; }
.fe-atouts { flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 1fr; gap: 10px; }
.fe-atout { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 10px 8px; text-align: center; }
.fe-atout .emb { width: 58px; height: 58px; color: var(--ivoire); }
.fe-atout.on .emb { color: var(--accent); }
.fe-atout b { font: 700 20px/1.05 var(--titre); letter-spacing: .06em; text-transform: uppercase; }
.fe-atout small { font: 500 15px/1.1 var(--texte); color: var(--pale); }
.fe-n { position: absolute; left: 10px; top: 8px; display: grid; place-items: center; width: 24px; height: 24px; background: var(--accent); color: #15120c; font: 700 15px/1 var(--texte); }
.fe-atout .fe-prix { position: absolute; right: 10px; top: 9px; }

.fe-equip { flex: 1; min-height: 0; display: grid; grid-template-columns: 200px 1fr; gap: 14px; }
.fe-classes { display: flex; flex-direction: column; gap: 6px; min-height: 0; }
.fe-cl { display: flex; align-items: center; gap: 10px; padding: 9px 12px; text-align: left; min-height: 0; flex: 0 1 46px; }
.fe-cl img { width: 26px; height: 26px; flex: none; }
.fe-cl b { font: 700 18px/1 var(--titre); letter-spacing: .06em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fe-cl.prise::after { content: ''; margin-left: auto; width: 8px; height: 8px; flex: none; background: var(--accent); transform: rotate(45deg); }
.fe-nouvelle { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22); background: transparent; color: var(--pale); }
.fe-nouvelle span { width: 26px; text-align: center; font: 700 26px/1 var(--texte); }
.fe-detail { min-height: 0; display: flex; flex-direction: column; gap: 10px; }
.fe-detail h3 { margin: 0 0 6px; font: 700 13px/1 var(--titre); letter-spacing: .22em; text-transform: uppercase; color: var(--pale); }
.fe-nom { display: flex; align-items: baseline; gap: 12px; min-height: 40px; }
.fe-nom > b { font: 700 30px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.fe-nom > small { font: 500 17px var(--texte); color: var(--pale); }
.fe-nom input { flex: 1; min-width: 0; max-width: 340px; height: 40px; padding: 0 12px; font: 700 24px/1 var(--titre); letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent); background: rgba(13, 16, 21, .9); border: 0; box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .45); outline: none; clip-path: var(--coin-petit); }
.fe-nom input:focus { box-shadow: inset 0 0 0 2px var(--accent); }
.fe-nom .filet { min-width: 0; padding: 10px 16px; font-size: 15px; margin-left: auto; }
.fe-rang { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.fe-deux { display: grid; grid-template-columns: 2fr 3fr; gap: 14px; }
.fe-deux section:first-child .fe-rang { grid-template-columns: repeat(2, 1fr); }
.fe-deux section:last-child .fe-rang { grid-template-columns: repeat(3, 1fr); }
.fe-arme { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 8px 6px 7px; min-width: 0; }
.fe-arme img { height: 34px; width: 100%; object-fit: contain; }
.fe-arme.fe-eq img { width: 30px; }
.fe-arme b { font: 700 15px/1.05 var(--titre); letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.fe-arme small { font: 500 13px/1 var(--texte); color: var(--pale); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.fe-arme[disabled] { cursor: default; }
.fe-arme .fe-prix { font-size: 13px; }

/* Réapparition : jusqu'à 8 classes (les quatre toutes faites et les siennes). */
.cl-cartes { grid-template-columns: repeat(var(--n, 4), 1fr) !important; }

@media (max-height: 430px) {
  .bloc { padding: 8px 10px 9px; gap: 4px; } .bl-tete { padding-bottom: 5px; } .bl-tete small { font-size: 12px; } .bl-tete .emb { width: 18px; height: 18px; }
  .bloc > b { font-size: 20px; } .bl-at .emb { width: 38px; height: 38px; } .bl-at b { font-size: 16px; } .bl-at small { font-size: 12.5px; } .bl-atouts { gap: 8px; }
  .bl-classe b { font-size: 20px; } .bl-classe img { width: 22px; height: 22px; } .bl-ligne { font-size: 14px; }
  .bl-sous { font-size: 12px; padding-top: 5px; } .bl-sous img { height: 16px; width: 16px; } .bl-sous img.bl-sec { width: 34px; }
  .fe-boite { gap: 7px; } .fe-tete { min-height: 38px; } .fe-tete h2 { font-size: 22px; } .fe-bourse { font-size: 17px; } .fe-bourse .emb { width: 20px; height: 20px; }
  .fe-aide { font-size: 14px; margin: -2px 0 0; }
  .fe-perso b { font-size: 18px; } .fe-atout .emb { width: 34px; height: 34px; } .fe-atout b { font-size: 15px; } .fe-atout small { font-size: 12px; } .fe-atout { gap: 3px; padding: 5px 6px; }
  .fe-atouts { gap: 6px; } .fe-n { width: 18px; height: 18px; font-size: 12px; left: 6px; top: 5px; }
  .fe-equip { grid-template-columns: 138px 1fr; gap: 9px; } .fe-cl { padding: 5px 8px; gap: 6px; flex-basis: 30px; } .fe-cl b { font-size: 14px; } .fe-cl img { width: 18px; height: 18px; }
  .fe-classes { gap: 4px; } .fe-detail { gap: 5px; } .fe-detail h3 { font-size: 10.5px; margin-bottom: 3px; }
  .fe-nom { min-height: 30px; } .fe-nom > b { font-size: 21px; } .fe-nom > small { font-size: 14px; } .fe-nom input { height: 30px; font-size: 17px; } .fe-nom .filet { padding: 7px 10px; font-size: 12px; }
  .fe-rang { gap: 5px; } .fe-arme { padding: 4px 4px 4px; gap: 1px; } .fe-arme img { height: 20px; } .fe-arme b { font-size: 12px; } .fe-arme small { font-size: 10.5px; }
  .fe-deux { gap: 9px; }
}

/* ---------- Bataille, page 1 : mode et carte côte à côte, puis les options ---------- */
.b-corps { gap: 0; align-items: stretch; }
.b-corps .gcs { flex: 1 1 0; width: auto; max-height: 440px; }
.b-corps .gcs + .gcs { margin-left: 14px; padding-left: 14px; border-left: 1px solid var(--filet); }
.b-corps .gc { max-width: 290px; }
.b-corps .gc b { font-size: 26px; }
.b-options { flex: none; display: flex; justify-content: center; flex-wrap: wrap; gap: 10px 22px; }
.b-opt { display: flex; align-items: center; gap: 10px; }
.b-opt .emb { width: 26px; height: 26px; color: var(--pale); }
.b-opt-nom { font: 700 14px/1 var(--titre); letter-spacing: .16em; text-transform: uppercase; color: var(--pale); }
/* Salon : le rappel du match (l'hôte le touche pour le changer). */
.pvp-regle .emb { width: 28px; height: 28px; margin: 0 4px; color: var(--accent); }
.pvp-regle[disabled] { cursor: default; } .pvp-regle[disabled]:hover { box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .4); }
/* Tableau des scores : un ordinateur porte un petit rouage. */
.pvp-table i.bot { display: inline-block; width: 14px; height: 14px; margin-left: 6px; vertical-align: -1px; background: var(--pale);
  -webkit-mask: url(img/emblemes/bot.png) center / contain no-repeat; mask: url(img/emblemes/bot.png) center / contain no-repeat; }
.pvp-table table.melee th:first-child { min-width: 140px; }
@media (max-height: 430px) {
  .b-corps .gcs + .gcs { margin-left: 8px; padding-left: 8px; } .b-corps .gc b { font-size: 17px; } .b-corps .gc small { display: none; }
  .b-corps .gc .emb { width: 46px; height: 46px; }
  .b-options { gap: 6px 12px; } .b-opt { gap: 6px; } .b-opt-nom { display: none; } .b-opt .emb { width: 20px; height: 20px; }
  .b-opt .cartes-choix button { padding: 7px 9px; font-size: 13px; }
  .pvp-regle .emb { width: 22px; height: 22px; }
}

/* Ce que rapporte la partie, sur l'écran de fin (pièces). */
.pvp-gain { display: flex; align-items: center; gap: 12px; }
.pvp-gain small { font: 700 13px/1 var(--titre); letter-spacing: .16em; text-transform: uppercase; color: var(--accent); }
/* En colonne, les atouts : l'emblème et le nom seulement (l'effet se lit dans leur fenêtre). */
.blocs.colonne .bl-at small { display: none; }
.blocs.colonne .bl-at b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.blocs.colonne .bl-at > span { min-width: 0; }
@media (max-height: 430px) {
  .blocs.colonne .bloc { padding: 5px 9px; gap: 0 8px; grid-template-columns: 48px 1fr; }
  .blocs.colonne .bl-tete { padding-bottom: 2px; }
  .blocs.colonne .bl-perso { max-height: 44px; }
  .blocs.colonne .bloc > b { font-size: 17px; }
  .blocs.colonne .bl-at { gap: 5px; } .blocs.colonne .bl-at .emb { width: 24px; height: 24px; } .blocs.colonne .bl-at b { font-size: 13px; }
  .blocs.colonne .bl-classe b { font-size: 16px; } .blocs.colonne .bl-arme { height: 26px; }
}

/* ---------- Pièces et boutique ---------- */
.m-bourse { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 14px 0 12px; clip-path: var(--coin-petit); background: rgba(13, 16, 21, .82);
  box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .45); }
.m-bourse .emb { width: 24px; height: 24px; color: var(--accent); }
.m-bourse b { font: 700 22px/1 var(--texte); color: var(--accent); font-variant-numeric: tabular-nums; }
.m-bourse span { margin-left: 6px; padding-left: 10px; border-left: 1px solid var(--filet); font: 700 15px/1 var(--titre); letter-spacing: .16em; text-transform: uppercase; }
.m-bourse:hover { box-shadow: inset 0 0 0 1px var(--accent); }
.bourse { display: flex; align-items: center; gap: 8px; margin-left: 12px; font: 700 22px/1 var(--texte); color: var(--accent); }
.bourse .emb { width: 24px; height: 24px; }
.p-onglets { margin-left: auto; display: flex; gap: 2px; background: rgba(13, 16, 21, .7); clip-path: var(--coin-petit); }
.p-onglets button { padding: 10px 22px; font: 700 16px/1 var(--titre); letter-spacing: .14em; text-transform: uppercase; color: var(--pale); }
.p-onglets button.on { background: var(--accent); color: #15120c; }
.bq-grille { width: 100%; height: 100%; max-height: 520px; display: grid; grid-template-columns: repeat(5, 1fr); grid-auto-rows: 1fr; gap: 10px; }
.bq-carte { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 10px 8px; min-height: 0;
  clip-path: var(--coin); background: linear-gradient(180deg, rgba(20, 25, 32, .92), rgba(11, 13, 17, .94)); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); text-align: center; }
.bq-carte img { width: 88%; height: 46px; object-fit: contain; }
.bq-carte .emb { width: 54px; height: 54px; }
.bq-carte b { font: 700 18px/1.05 var(--titre); letter-spacing: .05em; text-transform: uppercase; }
.bq-carte small { font: 500 14px/1.1 var(--texte); color: var(--pale); }
.bq-prix { display: flex; align-items: center; gap: 5px; font: 700 16px/1 var(--texte); color: var(--accent); }
.bq-prix .emb { width: 17px; height: 17px; }
.bq-carte:not(.a-soi) img, .bq-carte:not(.a-soi) > .emb { filter: brightness(.6); }
.bq-carte.a-soi .bq-prix { color: var(--pale); font: 700 13px/1 var(--titre); letter-spacing: .16em; text-transform: uppercase; }
.bq-carte:hover { box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .7); }
.bq-carte.on { box-shadow: inset 0 0 0 2px var(--accent), inset 0 -4px 0 var(--accent), inset 0 0 30px rgba(240, 212, 138, .16); }
.bq-carte.on b { color: var(--accent); }
.bq-carte.neuf { animation: neuf .6s ease-out; }
@keyframes neuf { 0% { transform: scale(.94); filter: brightness(1.8); } 100% { transform: none; filter: none; } }
.fe-arme.confirme, .fe-atout.confirme { box-shadow: inset 0 0 0 2px var(--accent); } .confirme .fe-prix { font-size: 13px; text-transform: uppercase; letter-spacing: .1em; }
.pvp-pieces .emb { width: 26px; height: 26px; color: var(--accent); }
.pvp-pieces b { font: 700 26px/1 var(--texte); color: var(--accent); }
.pvp-pieces small { font: 600 14px/1 var(--texte); color: var(--pale); letter-spacing: 0; text-transform: none; }
@media (max-height: 430px) {
  .m-bourse { height: 36px; padding: 0 10px; } .m-bourse b { font-size: 17px; } .m-bourse .emb { width: 19px; height: 19px; } .m-bourse span { font-size: 12px; padding-left: 8px; }
  .bourse { font-size: 17px; } .bourse .emb { width: 19px; height: 19px; }
  .p-onglets button { padding: 8px 14px; font-size: 13px; }
  .bq-grille { gap: 6px; } .bq-carte { gap: 2px; padding: 4px; } .bq-carte img { height: 26px; } .bq-carte .emb { width: 30px; height: 30px; }
  .bq-carte b { font-size: 13px; } .bq-carte small { font-size: 11px; } .bq-prix { font-size: 13px; } .bq-prix .emb { width: 13px; height: 13px; }
  .pvp-pieces b { font-size: 20px; } .pvp-pieces .emb { width: 20px; height: 20px; }
}

/* ---------- Tutoriel (niveau 1) : la commande à utiliser clignote (porteur, 15 nov. 2026 : « c'est pas bien indiqué les
   boutons à sélectionner ») ; ni flèche ni cadre. La consigne : une ligne en haut, fond léger ; les touches du PC dedans. */
#consigne { position: fixed; left: 50%; top: max(64px, calc(env(safe-area-inset-top) + 56px)); transform: translateX(-50%); z-index: 12;
  display: flex; align-items: center; gap: 10px; padding: 8px 18px; clip-path: var(--coin-petit); background: rgba(13, 16, 21, .62);
  font: 700 22px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; color: var(--ivoire); pointer-events: none; white-space: nowrap; }
#consigne kbd { display: inline-grid; place-items: center; min-width: 30px; height: 30px; padding: 0 7px; font: 700 16px/1 var(--titre);
  color: #15120c; background: var(--accent); clip-path: var(--coin-petit); animation: guide 1.1s ease-in-out infinite; }
#consigne.bravo { color: var(--accent); }
.guide { animation: guide 1.1s ease-in-out infinite !important; }
@keyframes guide { 0%, 100% { opacity: 1; filter: brightness(1.55) drop-shadow(0 0 10px rgba(240, 212, 138, .85)); } 50% { opacity: .35; filter: none; } }
#zone-regard { position: absolute; right: 0; top: 10%; width: 46%; height: 62%; pointer-events: none;
  background: radial-gradient(ellipse 50% 50% at 50% 50%, rgba(240, 212, 138, .26), rgba(240, 212, 138, 0) 70%); }

/* ---------- Bataille en trois pages (porteur, 19 nov. 2026) ----------
   Page 1 : le mode seul (trois grandes cartes) et, dessous, ses réglages en clair (« Gagner à 25 éliminations » ‹ ›).
   Page 2 : deux colonnes pleine hauteur, la carte à gauche (étroite), les joueurs à droite (le salon commun).
   Page 3 : l'écran d'équipement en mode « préparation » : compte à rebours, qui est prêt, « Prêt ». */
.b-modes .gc { max-width: 300px; }
.b-reglages { flex: none; display: flex; justify-content: center; flex-wrap: wrap; gap: 10px; }
.rgl { display: flex; align-items: stretch; min-width: 0; clip-path: var(--coin-petit); background: rgba(13, 16, 21, .86); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
.rgl button { flex: none; width: 46px; display: grid; place-items: center; font: 700 30px/1 var(--texte); color: var(--accent); }
.rgl button:disabled { color: rgba(243, 239, 230, .2); cursor: default; }
.rgl button:not(:disabled):active { background: rgba(240, 212, 138, .18); }
.rgl span { flex: 1; min-width: 150px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 7px 4px; text-align: center; }
.rgl small { font: 700 12px/1 var(--titre); letter-spacing: .2em; text-transform: uppercase; color: var(--pale); }
.rgl b { font: 700 21px/1 var(--titre); letter-spacing: .04em; color: var(--ivoire); white-space: nowrap; }

#salon { padding-bottom: max(12px, env(safe-area-inset-bottom)); }
.sl-recap { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font: 500 15px/1 var(--texte); color: var(--pale); letter-spacing: .02em; }
.sl-corps { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(200px, 34fr) 66fr; gap: clamp(10px, 2vw, 22px); width: min(1200px, 100%); margin: 0 auto; }
.sl-carte { position: relative; min-height: 0; display: flex; flex-direction: column; justify-content: flex-end; overflow: hidden; clip-path: var(--coin);
  background: #11151b; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
.sl-img { position: absolute; inset: 0; background: center / cover no-repeat; transition: opacity .25s; }
.sl-img::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(9, 11, 15, .05) 30%, rgba(9, 11, 15, .7) 72%, rgba(9, 11, 15, .95) 100%); }
.sl-choix { position: relative; display: flex; align-items: center; gap: 4px; padding: 0 6px; }
.sl-choix span { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.sl-choix small { font: 700 12px/1 var(--titre); letter-spacing: .22em; text-transform: uppercase; color: var(--pale); }
.sl-choix b { font: 700 30px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; color: var(--ivoire); text-shadow: var(--ombre); }
.sl-fl { width: 46px; height: 52px; font: 700 34px/1 var(--texte); color: var(--accent); }
.sl-carte.lecture .sl-fl { visibility: hidden; }
.sl-phrase { position: relative; margin: 6px 14px 14px; text-align: center; font: 500 15px/1.25 var(--texte); color: rgba(243, 239, 230, .78); }
.sl-joueurs { position: relative; min-height: 0; clip-path: var(--coin); background: rgba(10, 12, 16, .62); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1); }
#salon-commun { position: absolute; inset: 0; }
/* Le salon commun dans sa colonne : son en-tête (titre, modes) vient de la page ; le reste tel quel. */
#salon-commun .usal-haut, #salon-commun .usal-phrase { display: none; }
#salon-commun .usal { padding: 12px; gap: 10px; }
#salon-commun .usal-equipe { width: auto; flex: 1 1 0; max-width: 330px; }
#salon-commun .usal-scene { gap: 10px; }
#salon-commun .usal-nom b { font-size: .95em; }
/* « Compléter avec des ordinateurs » sur la ligne de « Lancer », à gauche. */
#salon-commun .usal-jeu { position: absolute; left: 12px; bottom: 12px; z-index: 2; }
#salon-commun .usal-bas { justify-content: flex-end; }
#salon-commun .usal-scene { align-items: center; }
#salon-commun[data-places="6"] .usal-place, #salon-commun[data-places="8"] .usal-place { min-height: 40px; padding-block: 3px; }
#salon-commun[data-places="10"] .usal-place { min-height: 32px; padding-block: 2px; }
.sl-lien { position: relative; margin: 0 14px 12px; padding: 8px 10px; font: 700 13px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; color: var(--accent);
  box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .4); clip-path: var(--coin-petit); background: rgba(13, 16, 21, .7); }
.sl-lien[hidden] { display: none; }
#salon-commun[data-places="10"] .usal-equipe { gap: 4px; padding: 6px; }
#salon-commun[data-places="10"] .usal-av { width: 30px; }
.sl-plus { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px 0 10px; clip-path: var(--coin-petit); background: rgba(13, 16, 21, .86);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .2); font: 700 15px/1 var(--titre); letter-spacing: .08em; text-transform: uppercase; color: var(--ivoire); }
.sl-plus .emb { width: 22px; height: 22px; color: var(--accent); }
.sl-plus[hidden] { display: none; }
/* Le niveau d'un ordinateur : trois choix, chacun dit ce qu'il change. */
#sl-niveau { position: absolute; inset: 0; z-index: 6; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(6, 8, 11, .82); }
.sln-boite { width: min(760px, 100%); display: flex; flex-direction: column; gap: 12px; }
.sln-boite header { display: flex; align-items: center; gap: 12px; }
.sln-boite h3 { margin: 0; font: 700 28px/1 var(--titre); letter-spacing: .14em; text-transform: uppercase; }
.sln-choix { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.sln-choix button { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 16px 12px 14px; clip-path: var(--coin); text-align: center;
  background: rgba(16, 20, 26, .95); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
.sln-choix button:hover { box-shadow: inset 0 0 0 2px var(--accent); }
.sln-choix .barres { display: flex; gap: 4px; align-items: flex-end; height: 26px; }
.sln-choix .barres i { width: 9px; background: rgba(243, 239, 230, .2); }
.sln-choix .barres i:nth-child(1) { height: 40%; } .sln-choix .barres i:nth-child(2) { height: 70%; } .sln-choix .barres i:nth-child(3) { height: 100%; }
.sln-choix .barres i.on { background: var(--accent); }
.sln-choix b { font: 700 24px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; }
.sln-choix small { font: 500 16px/1.2 var(--texte); color: rgba(243, 239, 230, .8); }

/* Page 3 : la préparation. */
.pp-compte { margin: 0 0 0 10px; display: flex; flex-direction: column; align-items: center; line-height: 1; }
.pp-compte small { font: 700 11px/1 var(--titre); letter-spacing: .2em; text-transform: uppercase; color: var(--pale); }
.pp-compte b { font: 700 34px/1 var(--texte); font-variant-numeric: tabular-nums; color: var(--accent); }
.pp-compte.vite b { color: #ff6b5c; }
.pp-prets { margin-right: auto; display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.pp-prets span { display: flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; clip-path: var(--coin-petit); background: rgba(13, 16, 21, .8);
  font: 700 14px/1 var(--titre); letter-spacing: .06em; color: var(--pale); }
.pp-prets span.pret { color: var(--ivoire); box-shadow: inset 0 -3px 0 #5fd18a; }
.pp-prets span i { font-style: normal; font-size: 12px; letter-spacing: .14em; text-transform: uppercase; }
.pp-prets span.pret i { color: #5fd18a; }
#p-equipement.prepa .p-note { display: none; }
#eq-action.fait { filter: grayscale(.6) brightness(.8); }

@media (max-height: 430px) {
  .rgl button { width: 38px; font-size: 26px; } .rgl span { min-width: 128px; padding: 5px 2px; } .rgl b { font-size: 17px; } .rgl small { font-size: 10px; }
  .b-reglages { gap: 6px; }
  /* Quatre réglages (avec la taille de la carte, 28 nov. 2026) : deux par ligne plutôt que 3 + 1. */
  .b-reglages:has(> .rgl:nth-child(4)) { display: grid; grid-template-columns: repeat(2, 230px); justify-content: center; }
  .sl-recap { font-size: 13px; }
  .sl-choix b { font-size: 22px; } .sl-fl { width: 38px; height: 44px; } .sl-phrase { font-size: 13px; margin: 2px 10px 10px; }
  #salon-commun .usal { padding: 8px; gap: 6px; }
  #salon-commun .usal-jeu { left: 8px; bottom: 8px; }
  #salon-commun .usal-lancer { min-width: 8em; }
  #salon-commun .usal-equipe { gap: 5px; padding: 6px; }
  #salon-commun[data-places="10"] .usal-equipe { gap: 3px; padding: 4px 6px; }
  #salon-commun[data-places="10"] .usal-av { width: 26px; }
  #salon-commun[data-places="10"] .usal-place { min-height: 30px; font-size: 13px; }
  .sl-carte .sl-lien { margin: 0 10px 8px; padding: 6px 8px; font-size: 11px; }
  .sln-choix button { padding: 10px 8px; gap: 5px; } .sln-choix b { font-size: 19px; } .sln-choix small { font-size: 13px; }
  .pp-compte b { font-size: 26px; }
  .pp-prets span { height: 26px; font-size: 13px; padding: 0 8px; }
}

/* Page Équipement lisible d'un coup d'œil (26 nov. 2026) : « Changer » en bas de chaque bloc, la vie en PV, la classe en
   petite étiquette ; le personnage respire (il monte et s'élargit à peine, lentement). */
.bl-changer { align-self: stretch; margin-top: 2px; padding: 7px 0 6px; border: 1px solid var(--accent); color: var(--accent);
  font: 700 15px/1 var(--titre); letter-spacing: .16em; text-transform: uppercase; text-align: center; }
.bloc:hover .bl-changer, .bloc:focus-visible .bl-changer { background: var(--accent); color: #14161c; }
.bl-pv { font: 700 17px/1 var(--titre); letter-spacing: .08em; color: var(--pale); }
.bl-classe-pied { display: flex; align-items: center; gap: 6px; font: 600 14px/1 var(--texte); color: var(--pale); }
.bl-classe-pied img { width: 18px; height: 18px; }
.bl-respire { flex: 1; min-height: 0; width: 100%; display: flex; justify-content: center; }
.bl-respire .bl-perso { height: 100%; }   /* la respiration est dans l'image (Mixamo « Breathing Idle », 26 nov.) */
@keyframes respire { 0%, 100% { transform: scale(1, 1); } 45% { transform: scale(1.012, 1.022) translateY(-1px); } }
.fe-classes-titre { margin: 0 0 4px; font: 700 13px/1 var(--titre); letter-spacing: .2em; text-transform: uppercase; color: var(--pale); }
.blocs.colonne .bl-changer, .blocs.colonne .bl-pv, .blocs.colonne .bl-classe-pied { display: none; }
.blocs.ligne .bloc::after { display: none; }   /* la flèche fait doublon avec « Changer » (26 nov.) */

/* Survie : le personnage seul (26 nov. 2026 ; ni armes ni atouts : le pistolet de départ, puis ce qu'on trouve). */
#p-equipement.seul-perso .bloc[data-b="equipements"] { display: none; }
#p-equipement.seul-perso .bloc[data-b="perso"] { max-width: 420px; }

/* Bloc « Équipements » (28 nov. 2026) : deux zones à toucher, les armes puis l'atout. */
.bloc-equip { flex: 2 1 0 !important; max-width: 560px !important; cursor: default; }
.bloc-equip .bl-zone { all: unset; box-sizing: border-box; align-self: stretch; display: flex; flex-direction: column; align-items: center; gap: 6px; cursor: pointer; padding: 4px 6px; }
.bloc-equip .bl-zone-armes { flex: 1; min-height: 0; }
.bloc-equip .bl-zone-atout { flex-direction: row; justify-content: space-between; border-top: 1px solid var(--filet); padding-top: 8px; }
.bloc-equip .bl-zone-atout .bl-changer { align-self: center; padding: 7px 14px; }
.bloc-equip .bl-zone:hover .bl-changer { background: var(--accent); color: #14161c; }

/* Caractéristiques des armes en barres (28 nov. 2026). */
.fe-stats { display: grid; gap: 2px; width: 100%; padding: 2px 6px 0; }
.fe-stat { display: grid; grid-template-columns: 58px 1fr; align-items: center; gap: 6px; }
.fe-stat i { font: 600 10.5px/1 var(--texte); font-style: normal; color: var(--pale); text-align: left; }
.fe-barre { height: 5px; background: rgba(243, 239, 230, .14); }
.fe-barre > span { display: block; height: 100%; background: var(--accent); }

/* ---- 28 nov. 2026 (porteur : « un bloc pour chaque, on clique sur le bloc et ça ouvre une petite fenêtre » ; « tu me
   saoules avec tes boutons partout, on est sur un jeu ») : blocs encadrés à toucher, petite fenêtre qui défile. ---- */
.fe-places { flex: 1; min-height: 0; display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 10px; }
.fe-place { all: unset; box-sizing: border-box; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  padding: 12px 10px; cursor: pointer; clip-path: var(--coin-petit); background: rgba(16, 20, 26, .94); box-shadow: inset 0 0 0 1px rgba(240, 212, 138, .45); text-align: center; min-width: 0; }
.fe-place:hover { box-shadow: inset 0 0 0 2px var(--accent); }
.fe-place.fixe { cursor: default; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); }
.fe-place > .fe-titre { font-style: normal; position: absolute; left: 10px; top: 8px; font: 700 12px/1 var(--titre); letter-spacing: .2em; text-transform: uppercase; color: var(--pale); }
.fe-place img { width: 86%; height: 30%; max-height: 90px; object-fit: contain; margin-top: 14px; }
.fe-place b { font: 700 19px/1.05 var(--titre); letter-spacing: .04em; text-transform: uppercase; }
.fe-place .fe-effet { font: 500 13px/1.2 var(--texte); color: var(--pale); }
.fe-place .fe-stats { max-width: 240px; }
#f-choix .fe-boite { width: min(640px, 100%); height: auto; max-height: 100%; }
.fe-choix { min-height: 0; overflow-y: auto; display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; padding: 2px; overscroll-behavior: contain; }
.fe-choix .fe-arme { padding: 10px 8px; }
.fe-choix .fe-arme img { height: 42px; }
.fe-series { flex: 1; min-height: 0; overflow-y: auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.fe-serie { all: unset; box-sizing: border-box; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; padding: 12px 8px; cursor: pointer; text-align: center;
  clip-path: var(--coin-petit); background: rgba(16, 20, 26, .94); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); }
.fe-serie img { width: 76px; height: 76px; object-fit: contain; }
.fe-serie b { font: 700 17px/1 var(--titre); letter-spacing: .05em; text-transform: uppercase; }
.fe-serie small { font: 500 13px/1.2 var(--texte); color: var(--pale); }
.fe-serie .fe-n { position: absolute; left: 8px; top: 7px; }
.fe-serie.on { box-shadow: inset 0 0 0 2px var(--accent), inset 0 -4px 0 var(--accent); background: linear-gradient(180deg, rgba(240, 212, 138, .2), rgba(240, 212, 138, .06)); }
/* Le bloc Équipements : chaque zone encadrée se touche (plus de « Changer… »). */
.bloc-equip .bl-zone { border: 1px solid rgba(240, 212, 138, .35); border-radius: 3px; padding: 6px 8px; }
.bloc-equip .bl-zone:hover { border-color: var(--accent); background: rgba(240, 212, 138, .07); }
.bloc-equip .bl-zone-atout { border-top: 1px solid rgba(240, 212, 138, .35); padding-top: 6px; }
.bloc-equip .bl-zone-series { flex-direction: row; justify-content: space-around; gap: 8px; }
.bl-serie { display: flex; align-items: center; gap: 6px; min-width: 0; }
.bl-serie img { width: 30px; height: 30px; object-fit: contain; }
.bl-serie b { font: 700 14px/1 var(--titre); letter-spacing: .04em; text-transform: uppercase; white-space: nowrap; }
.bl-serie small { font: 700 12px/1 var(--texte); color: var(--accent); }
.bloc .bl-changer { display: none; }
@media (max-height: 500px) {
  .fe-place b { font-size: 14px; } .fe-place > .fe-titre { font-size: 10px; } .fe-place img { margin-top: 10px; }
  .fe-choix .fe-arme img { height: 26px; } .fe-serie img { width: 34px; height: 34px; } .fe-serie b { font-size: 13px; } .fe-serie small { font-size: 11px; }
  .bl-serie img { width: 22px; height: 22px; } .bl-serie b { font-size: 11px; }
}

/* ---- 28 nov. 2026, après-midi (porteur : « des chevrons directement sur le personnage » ; « chaque bloc doit avoir un
   titre : armes, atouts, séries » ; « c'est super mal agencé… un effort ») : trois zones titrées, des cases égales,
   tout centré de la même façon. ---- */
.bloc[data-b="perso"] { cursor: default; }
.bl-respire { position: relative; align-items: center; }
.bl-chev { all: unset; box-sizing: border-box; position: absolute; top: 50%; left: 0; width: 44px; height: 64px; margin-top: -32px; cursor: pointer; z-index: 1;
  display: grid; place-items: center; }
.bl-chev.droite { left: auto; right: 0; }
.bl-chev::before { content: ''; width: 18px; height: 18px; border-left: 4px solid var(--accent); border-bottom: 4px solid var(--accent); transform: rotate(45deg); margin-left: 8px;
  filter: drop-shadow(0 2px 3px #000a); }
.bl-chev.droite::before { transform: rotate(-135deg); margin-left: -8px; }
.bl-chev:hover::before, .bl-chev:active::before { border-color: #fff; }
.bloc-equip { gap: 8px !important; }
.bloc-equip .bl-zone { all: unset; box-sizing: border-box; align-self: stretch; display: flex; flex-direction: column; gap: 4px; cursor: pointer;
  padding: 6px 8px 8px; border: 1px solid rgba(240, 212, 138, .35); border-radius: 3px; min-height: 0; }
.bloc-equip .bl-zone:hover, .bloc-equip .bl-zone:active { border-color: var(--accent); background: rgba(240, 212, 138, .07); }
.bloc-equip .bl-zone-armes { flex: 1 1 auto; }
.bl-zone-armes .bl-case.arme img { height: clamp(26px, 10vh, 84px); }
.bl-zone-armes .bl-case.objet img { height: clamp(22px, 7vh, 56px); }
.bloc-equip .bl-zone:not(.bl-zone-armes) { flex: 0 0 auto; }
.bl-zt { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.bl-zt b { font: 700 13px/1 var(--titre); letter-spacing: .22em; text-transform: uppercase; color: var(--accent); }
.bl-zt i { display: flex; align-items: center; gap: 5px; font: 600 12px/1 var(--texte); font-style: normal; color: var(--pale); }
.bl-zt i img { width: 16px; height: 16px; }
.bl-cases { flex: 1; min-height: 0; display: grid; grid-template-columns: 1fr; gap: 6px; align-items: center; }
.bl-cases.deux { grid-template-columns: 1fr 1fr; }
.bl-cases.trois { grid-template-columns: 1.4fr 1fr 1fr; }
.bl-case { min-width: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; text-align: center; }
.bl-case img { width: 100%; height: 34px; object-fit: contain; }
.bl-case.objet img { height: 30px; }
.bl-case.emb-case img { height: 30px; }
.bl-case b { max-width: 100%; font: 700 14px/1.05 var(--titre); letter-spacing: .04em; text-transform: uppercase; color: var(--ivoire); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bl-case small { font: 500 12px/1.15 var(--texte); color: var(--pale); }
@media (max-height: 430px) {
  .bloc-equip { gap: 5px !important; }
  .bloc-equip .bl-zone { padding: 4px 6px 5px; gap: 2px; }
  .bl-zt b { font-size: 11px; } .bl-zt i { font-size: 10.5px; } .bl-zt i img { width: 13px; height: 13px; }
  .bl-case img { height: 24px; } .bl-case.objet img, .bl-case.emb-case img { height: 20px; }
  .bl-case b { font-size: 11.5px; } .bl-case small { font-size: 10px; }
  .bl-chev { width: 34px; height: 50px; margin-top: -25px; } .bl-chev::before { width: 13px; height: 13px; border-width: 3px; }
}
/* Téléphone couché : Armes sur toute la largeur, Atout et Séries côte à côte dessous (sinon tout s'écrase). */
.bloc-equip .bl-zone { min-height: auto; }
@media (max-height: 500px) {
  .bloc-equip { display: grid !important; grid-template-columns: 1fr 1.5fr; grid-template-rows: auto minmax(0, 1fr) auto; align-items: stretch; }
  .bloc-equip > .bl-tete, .bloc-equip > .bl-zone-armes { grid-column: 1 / 3; }
  .bloc-equip .bl-zone-armes .bl-case.arme img { height: clamp(22px, 9vh, 44px); }
  .bloc-equip .bl-case small { display: none; }
  .bloc-equip .bl-zone-armes .bl-case.objet small { display: block; }
}

/* ---------- L'accueil façon COD Mobile (porteur, 28 nov. 2026 ; maquette conception/maquettes/accueil-cod.html) ----------
   Téléphone d'abord (S9 en paysage, 740 × 360, et plus court) : rien de collé ; le PC agrandit. */
#accueil > #menu { display: block; padding: 0; --m-pad: max(14px, env(safe-area-inset-left)); --m-haut: 62px; }
#menu::before { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgba(8, 10, 14, .82) 0%, rgba(8, 10, 14, .15) 34%, rgba(8, 10, 14, .15) 62%, rgba(8, 10, 14, .78) 100%); }
#menu .m-gauche { position: absolute; z-index: 2; left: var(--m-pad); top: var(--m-haut); width: clamp(196px, 27vw, 360px); padding: 0; gap: 10px; }
#menu .m-liste { gap: 4px; }
#menu .m-item { width: 100%; height: 52px; padding: 0 12px; gap: 10px; background: rgba(13, 16, 21, .55); clip-path: var(--coin-petit); border-left: 0; }
#menu .m-item .emb { width: 26px; height: 26px; opacity: .75; }
#menu .m-item b { font-size: 19px; letter-spacing: .06em; color: var(--pale); }
#menu .m-item small { font-size: 12.5px; color: rgba(243, 239, 230, .45); margin-top: 3px; }
#menu .m-item:hover { background: rgba(240, 212, 138, .1); }
#menu .m-item.on { background: rgba(240, 212, 138, .14); box-shadow: inset 3px 0 0 var(--accent); }
#menu .m-item.on b { color: var(--ivoire); } #menu .m-item.on .emb { opacity: 1; color: var(--accent); }
.m-confort { width: 44px; height: 44px; display: grid; place-items: center; clip-path: var(--coin-petit); background: rgba(13, 16, 21, .82); }
.m-confort img { width: 22px; height: 22px; }
.m-confort:hover { box-shadow: inset 0 0 0 1px var(--accent); }
/* Au milieu : le personnage, son ombre, son équipement à ses pieds. Centré dans l'espace entre les deux colonnes. */
#menu .m-centre { position: absolute; z-index: 1; top: 8px; bottom: 12px;
  left: calc(var(--m-pad) + clamp(196px, 27vw, 360px)); right: calc(var(--m-pad) + clamp(226px, 30vw, 400px));
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end; pointer-events: none; }
#m-heros { flex: 1; min-height: 0; width: 100%; display: block; }
.m-sol { position: absolute; bottom: 46px; left: 50%; width: min(80%, 260px); height: 26px; transform: translateX(-50%); border-radius: 50%;
  background: radial-gradient(closest-side, rgba(240, 212, 138, .28), transparent); }
.m-equip { pointer-events: auto; flex: none; position: relative; margin-top: -10px; width: 170px; height: 52px; display: flex; flex-direction: column; align-items: center;
  justify-content: center; gap: 2px; clip-path: var(--coin-petit); background: var(--ardoise); box-shadow: inset 0 0 0 1px var(--filet); }
.m-equip small { font: 700 10px/1 var(--titre); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.m-equip b { font: 700 15px/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; }
.m-equip span { font-size: 12.5px; color: var(--pale); }
.m-equip:hover { box-shadow: inset 0 0 0 1px var(--accent); }
/* À droite : ce qu'on va jouer, puis JOUER (le seul bouton vif de l'écran). */
#menu .m-droite { position: absolute; z-index: 2; right: max(14px, env(safe-area-inset-right)); top: var(--m-haut); bottom: 14px; width: clamp(226px, 30vw, 400px);
  display: flex; flex-direction: column; gap: 12px; }
.m-mode { position: relative; flex: 1; min-height: 0; overflow: hidden; text-align: left; clip-path: var(--coin-petit); background: var(--ardoise); box-shadow: inset 0 0 0 1px var(--filet); }
.m-mode .mm-img { position: absolute; inset: 0; background: center / cover no-repeat; filter: brightness(.6); transition: filter .15s; }
.m-mode:hover .mm-img { filter: brightness(.72); }
.m-mode .mm-txt { position: absolute; left: 0; right: 0; bottom: 0; display: block; padding: 26px 14px 12px; background: linear-gradient(transparent, rgba(8, 10, 14, .94) 34%); }
.m-mode .mm-txt small { display: block; font: 700 13px/1 var(--titre); letter-spacing: .14em; text-transform: uppercase; color: var(--accent); }
.m-mode .mm-txt b { display: block; margin-top: 5px; font: 700 23px/1 var(--titre); letter-spacing: .04em; text-transform: uppercase; }
.m-mode .mm-det { display: block; margin-top: 6px; font-size: 13.5px; line-height: 1.25; color: var(--pale); }
.m-mode .mm-chev { position: absolute; right: 12px; top: 10px; font: 700 28px/1 var(--titre); color: var(--accent); }
.m-mode.fixe { cursor: default; } .m-mode.fixe .mm-chev { display: none; } .m-mode.fixe:hover .mm-img { filter: brightness(.6); }
.m-jouer { flex: none; width: 100%; min-width: 0; padding: 0; height: 58px; display: grid; place-items: center; font-size: 27px; }
@media (min-height: 560px) {
  #accueil > #menu { --m-haut: 92px; }
  #menu .m-item { height: 72px; padding: 0 18px; gap: 14px; } #menu .m-item b { font-size: 25px; } #menu .m-item small { font-size: 15px; }
  #menu .m-item .emb { width: 34px; height: 34px; }
  .m-equip { width: 230px; height: 68px; } .m-equip b { font-size: 19px; } .m-equip span { font-size: 15px; } .m-equip small { font-size: 12px; }
  .m-mode .mm-txt b { font-size: 32px; } .m-mode .mm-det { font-size: 16px; } .m-mode .mm-txt small { font-size: 15px; }
  .m-jouer { height: 76px; font-size: 34px; }
  .m-confort { width: 52px; height: 52px; }
  #menu .m-droite { bottom: 24px; } #menu .m-centre { bottom: 24px; }
}

/* ---------- La page du mode : modes à gauche, cartes, réglages et Confirmer à droite (colonne souple) ---------- */
#p-mode .pm-corps { flex: 1; min-height: 0; display: flex; gap: 14px; }
.pm-modes { flex: none; width: clamp(200px, 29vw, 380px); display: flex; flex-direction: column; gap: 6px; }
.pm-mode { height: 60px; flex: none; display: flex; align-items: center; gap: 10px; padding: 0 12px; text-align: left; clip-path: var(--coin-petit);
  background: var(--ardoise); box-shadow: inset 0 0 0 1px var(--filet); }
.pm-mode .emb { width: 30px; height: 30px; flex: none; }
.pm-mode b { display: block; font: 700 19px/1 var(--titre); letter-spacing: .05em; text-transform: uppercase; }
.pm-mode small { display: block; margin-top: 4px; font-size: 12.5px; line-height: 1.15; color: var(--pale); }
.pm-mode.on { box-shadow: inset 0 0 0 2px var(--accent); background: rgba(240, 212, 138, .12); }
.pm-niveau { margin-top: auto; }
.pm-niveau .rgl { width: 100%; }
.pm-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.pm-cartes { flex: 1; min-height: 64px; display: flex; gap: 8px; }
.pm-carte { position: relative; flex: 1; overflow: hidden; clip-path: var(--coin-petit); background: var(--ardoise); box-shadow: inset 0 0 0 1px var(--filet); text-align: left; }
.pm-carte .pmc-img { position: absolute; inset: 0; background: center / cover no-repeat; filter: brightness(.6); }
.pm-carte b { position: absolute; left: 12px; bottom: 10px; font: 700 20px/1 var(--titre); letter-spacing: .06em; text-transform: uppercase; }
.pm-carte.on { box-shadow: inset 0 0 0 2px var(--accent); } .pm-carte.on .pmc-img { filter: brightness(.82); }
#p-mode .b-reglages { flex: none; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
#p-mode .b-reglages[hidden] { display: none; }
#p-mode .rgl { min-width: 0; }
#p-mode .rgl span { min-width: 0; }
.pm-bas { flex: none; display: flex; justify-content: flex-end; margin-top: 8px; }
#pm-confirmer { min-width: 0; width: 200px; padding: 0; height: 48px; display: grid; place-items: center; }
/* Bataille : à la place des cartes (elles se choisissent à l'étape 2, avec les joueurs), l'image du mode choisi. */
.pm-apercu { position: relative; flex: 1; overflow: hidden; clip-path: var(--coin-petit); background: var(--ardoise) center / cover no-repeat; box-shadow: inset 0 0 0 1px var(--filet); }
.pm-apercu::before { content: ''; position: absolute; inset: 0; background: linear-gradient(transparent 35%, rgba(8, 10, 13, .82)); }
.pm-apercu span { position: absolute; left: 12px; right: 12px; bottom: 10px; }
.pm-apercu b { display: block; font: 700 22px/1 var(--titre); letter-spacing: .06em; text-transform: uppercase; }
.pm-apercu small { display: block; margin-top: 4px; font-size: 13px; color: var(--pale); }
/* Survie : seulement la carte (et pas d'étapes). */
#p-mode.survie .pm-modes, #p-mode.survie #pm-etapes { display: none; }
#m-jouer.long { font-size: 21px; }
@media (max-height: 430px) {
  #p-mode .rgl { height: 44px; } #p-mode .rgl button { width: 34px; }
}
@media (min-height: 560px) {
  .pm-mode { height: 78px; } .pm-mode b { font-size: 24px; } .pm-mode small { font-size: 15px; }
  .pm-carte b { font-size: 26px; } #pm-confirmer { width: 260px; height: 60px; }
}

/* ---------- 29 nov. 2026 (porteur) ---------- */
/* L'accueil : un seul bouton, « Commencer », en bas à droite (plus de carte du mode ni de bloc Équipement). */
#menu .m-droite { justify-content: flex-end; }
/* Paramètres : trois onglets (Graphismes, Son, Sensibilité), des réglages qui disent ce qu'ils changent. */
#reglages .rg { display: flex !important; flex-direction: column; gap: 10px; width: min(860px, 96vw); max-height: calc(100vh - 16px); padding-top: 14px; padding-bottom: 14px; }
#reglages .rg header { display: flex; align-items: center; gap: 14px; }
.rg-onglets { margin-left: auto; display: flex; gap: 2px; clip-path: var(--coin-petit); background: rgba(13, 16, 21, .7); }
.rg-onglets button { padding: 10px 16px; font: 700 15px/1 var(--titre); letter-spacing: .12em; text-transform: uppercase; color: var(--pale); }
.rg-onglets button.on { background: var(--accent); color: #15120c; }
.rg-page { display: flex; flex-direction: column; min-height: 0; }
.rg-page[hidden] { display: none !important; }
#reglages .rg-ligne { grid-template-columns: minmax(180px, 38%) 1fr 52px; }
#reglages .rg-ligne > span { display: flex; flex-direction: column; gap: 4px; line-height: 1.1; }
#reglages .rg-ligne > span small { font: 500 12.5px/1.2 var(--texte); letter-spacing: 0; text-transform: none; color: rgba(243, 239, 230, .6); }
.rg-sons { display: grid !important; grid-template-columns: 1fr 1fr; column-gap: 24px; }
.rg-sons[hidden] { display: none !important; }
.rg-vol { display: grid; grid-template-columns: 1fr 1.2fr 48px; align-items: center; gap: 10px; padding: 8px 4px; border-top: 1px solid var(--filet); }
.rg-vol span { font: 700 14px/1.1 var(--titre); letter-spacing: .08em; text-transform: uppercase; color: var(--pale); }
.rg-vol input[type="range"] { width: 100%; accent-color: var(--accent); touch-action: pan-x; height: 28px; cursor: pointer; }
.rg-vol output { font: 700 15px/1 var(--texte); font-variant-numeric: tabular-nums; text-align: right; }
.rg-vol:first-child { grid-column: 1 / -1; }
@media (max-height: 430px) {
  .rg-onglets button { padding: 8px 11px; font-size: 13px; }
  #reglages .rg-ligne { padding: 6px 4px; } #reglages .rg-ligne > span small { font-size: 11.5px; }
  .rg-vol { padding: 6px 4px; }
}
/* Entraînement : le tutoriel ou le terrain, deux blocs qu'on touche. */
#p-entrainement .pe-choix { flex: 1; min-height: 0; display: flex; gap: 14px; }
.pe-bloc { position: relative; flex: 1; overflow: hidden; text-align: left; clip-path: var(--coin-petit); background: var(--ardoise); box-shadow: inset 0 0 0 1px var(--filet); }
.pe-bloc .pe-img { position: absolute; inset: 0; background: center / cover no-repeat; filter: brightness(.55); transition: filter .15s; }
.pe-bloc:hover .pe-img { filter: brightness(.7); }
.pe-bloc .pe-txt { position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 16px 14px; background: linear-gradient(transparent, rgba(8, 10, 14, .94) 34%); }
.pe-bloc b { display: block; font: 700 26px/1 var(--titre); letter-spacing: .06em; text-transform: uppercase; }
.pe-bloc small { display: block; margin-top: 6px; font-size: 14px; line-height: 1.25; color: var(--pale); }
/* Étape 2 : le niveau des bots, sous la carte. */
.sl-bots { position: relative; margin: 0 12px 12px; }
.sl-bots[hidden] { display: none; }
.sl-bots .rgl { width: 100%; }
.sl-bots p { margin: 5px 2px 0; text-align: center; font: 500 12.5px/1.2 var(--texte); color: rgba(243, 239, 230, .6); }
/* Le tutoriel : un titre court et une vraie phrase dessous. */
#consigne { flex-direction: column; gap: 6px; max-width: min(620px, 80vw); white-space: normal; text-align: center; padding: 10px 20px; }
#consigne span { font: 500 15px/1.3 var(--texte); letter-spacing: 0; text-transform: none; color: rgba(243, 239, 230, .9); }
#consigne span kbd { margin: 0 2px; vertical-align: middle; }

/* La page du mode (porteur, 29 nov. 2026) : deux blocs bien distincts et de la même hauteur, les modes à gauche (centrés en
   hauteur, plus grands, alignés à gauche) et les règles à droite, séparés par un large espace et un trait semi-opaque. */
#p-mode .pm-corps { gap: 0; align-items: stretch; }
#p-mode .pm-modes { width: clamp(250px, 37vw, 460px); justify-content: center; gap: 10px; padding-right: 22px; margin-right: 22px; border-right: 1px solid rgba(243, 239, 230, .22); }
#p-mode .pm-mode { height: auto; min-height: 66px; padding: 10px 16px; gap: 14px; }
#p-mode .pm-mode .emb { width: 34px; height: 34px; }
#p-mode .pm-mode b { font-size: 22px; } #p-mode .pm-mode small { font-size: 13.5px; }
#p-mode.survie .pm-modes { border: 0; margin: 0; padding: 0; }
@media (max-height: 380px) { #p-mode .pm-mode { min-height: 60px; padding: 8px 14px; } #p-mode .pm-mode b { font-size: 20px; } #p-mode .pm-mode small { font-size: 12.5px; } }
@media (min-height: 560px) { #p-mode .pm-mode { min-height: 90px; } #p-mode .pm-mode b { font-size: 26px; } #p-mode .pm-mode small { font-size: 16px; } }

/* ---------- L'accueil en grandes cartes (porteur, 29 nov. 2026 au soir : « vire le perso », « un truc joli dans ce genre ») ----------
   Quatre cartes verticales côte à côte (Classé, Bataille, Survie, Entraînement) : l'image d'une carte du jeu assombrie et
   teintée (--teinte, r,g,b), le titre et le format en haut, un grand emblème au trait au milieu, un filet et une phrase en
   bas ; au survol (et sur la dernière jouée), l'image s'éclaire, la teinte monte, « Jouer » apparaît au-dessus du filet.
   Tient au S9 (740 × 360) sans défilement ; le PC agrandit. Le fond 3D de la carte se voit autour. */
#menu::before { background: radial-gradient(ellipse at 50% 55%, rgba(8, 10, 14, .3), rgba(8, 10, 14, .82)); }
#menu .m-titre { position: absolute; z-index: 2; left: var(--m-pad); top: max(12px, env(safe-area-inset-top)); height: 40px; pointer-events: none; }
#menu .m-titre img { height: 100%; width: auto; filter: drop-shadow(0 2px 8px rgba(0, 0, 0, .6)); }
.m-cartes { position: absolute; z-index: 2; left: var(--m-pad); right: max(14px, env(safe-area-inset-right)); top: var(--m-haut); bottom: clamp(12px, 4.5vh, 40px);
  display: flex; justify-content: center; gap: clamp(8px, 1.6vw, 22px); }
.acc-carte { position: relative; flex: 1 1 0; min-width: 0; max-width: 300px; padding: 0; overflow: hidden; display: flex; flex-direction: column; align-items: center;
  text-align: center; color: var(--ivoire); background: #0d1015; clip-path: var(--coin-petit);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); transition: box-shadow .25s ease, transform .25s ease; }
.mc-fond { position: absolute; inset: -2%; background: var(--img) center / cover no-repeat; filter: brightness(.42) saturate(.65); transition: filter .3s ease, transform 1.2s ease; }
.mc-fond::after { content: ''; position: absolute; inset: 0; transition: opacity .3s ease;
  background: linear-gradient(180deg, rgba(8, 10, 14, .55) 0%, rgba(var(--teinte), .18) 38%, rgba(var(--teinte), .34) 66%, rgba(8, 10, 14, .9) 100%); }
.mc-fond::before { content: ''; position: absolute; inset: 0; z-index: 1; opacity: 0; transition: opacity .3s ease;
  background: linear-gradient(180deg, rgba(var(--teinte), .25), rgba(var(--teinte), .62) 70%, rgba(8, 10, 14, .85)); }
.mc-tete, .mc-emb, .mc-bas { position: relative; z-index: 2; }
.mc-tete { margin-top: clamp(10px, 3.6vh, 30px); display: flex; flex-direction: column; gap: 5px; padding: 0 8px; }
.mc-tete b { font: 700 clamp(19px, 2.6vw, 31px)/1 var(--titre); letter-spacing: .1em; text-transform: uppercase; text-shadow: 0 2px 10px rgba(0, 0, 0, .6); }
.mc-tete small { font: 700 clamp(11px, 1.3vw, 16px)/1 var(--titre); letter-spacing: .14em; text-transform: uppercase; color: rgba(243, 239, 230, .78); }
.mc-emb { flex: 1 1 0; min-height: 0; width: 64%; max-width: 160px; margin: clamp(6px, 2vh, 18px) 0; color: rgba(255, 255, 255, .9);
  filter: drop-shadow(0 3px 10px rgba(0, 0, 0, .55)); transition: transform .3s ease, color .3s ease; }
.mc-bas { width: 100%; padding: 0 clamp(8px, 1.2vw, 16px) clamp(10px, 3vh, 22px); display: flex; flex-direction: column; align-items: center; }
.mc-jouer { font: 700 clamp(19px, 2.7vw, 34px)/1 var(--titre); letter-spacing: .18em; text-transform: uppercase; margin-bottom: 7px;
  opacity: 0; transform: translateY(8px); transition: opacity .25s ease, transform .25s ease; text-shadow: 0 2px 12px rgba(0, 0, 0, .7); }
.mc-phrase { width: 100%; padding-top: 8px; border-top: 1px solid rgba(255, 255, 255, .42); font-size: clamp(11px, 1.25vw, 15px); line-height: 1.3;
  color: rgba(243, 239, 230, .88); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.mc-grade { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 8px; padding: 4px 10px; background: rgba(8, 10, 14, .55);
  clip-path: var(--coin-petit); font: 700 13px/1 var(--titre); letter-spacing: .08em; text-transform: uppercase; }
.mc-grade small { font-weight: 600; color: var(--pale); letter-spacing: .04em; }
.mc-grade[hidden] { display: none; }
/* Choisie (survol, clavier) ou dernière jouée : l'image s'éclaire, la teinte monte, « Jouer » apparaît. */
.acc-carte:hover, .acc-carte:focus-visible, .acc-carte.on { box-shadow: inset 0 0 0 2px rgb(var(--teinte)); }
.acc-carte:hover .mc-fond, .acc-carte:focus-visible .mc-fond, .acc-carte.on .mc-fond { filter: brightness(.62) saturate(.95); transform: scale(1.04); }
.acc-carte:hover .mc-fond::before, .acc-carte:focus-visible .mc-fond::before, .acc-carte.on .mc-fond::before { opacity: 1; }
.acc-carte:hover .mc-jouer, .acc-carte:focus-visible .mc-jouer, .acc-carte.on .mc-jouer { opacity: 1; transform: none; }
.acc-carte:hover .mc-emb, .acc-carte:focus-visible .mc-emb { transform: scale(1.05); color: #fff; }
.acc-carte:active { transform: scale(.985); }
@media (hover: hover) { .m-cartes:hover .acc-carte.on:not(:hover) { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
  .m-cartes:hover .acc-carte.on:not(:hover) .mc-fond { filter: brightness(.42) saturate(.65); transform: none; }
  .m-cartes:hover .acc-carte.on:not(:hover) .mc-fond::before { opacity: 0; }
  .m-cartes:hover .acc-carte.on:not(:hover) .mc-jouer { opacity: 0; transform: translateY(8px); } }
#menu .m-bac { position: absolute; z-index: 3; left: var(--m-pad); bottom: 6px; }
@media (max-height: 430px) {
  #accueil > #menu { --m-haut: 56px; }
  #menu .m-titre { height: 32px; top: max(10px, env(safe-area-inset-top)); }
  .m-cartes { bottom: 10px; gap: 8px; }
  .mc-tete { gap: 3px; } .mc-jouer { margin-bottom: 4px; } .mc-phrase { padding-top: 5px; line-height: 1.25; }
  .mc-grade { margin-top: 5px; padding: 3px 7px; font-size: 11px; } .mc-grade svg { width: 20px; height: 20px; }
}
@media (prefers-reduced-motion: reduce) { .mc-fond, .mc-emb, .mc-jouer, .acc-carte { transition: none; } }

/* ---------- Le fond des menus : abstrait, façon FPS (porteur, 29 nov. 2026 au soir : « un fond abstrait mais stylisé
   style FPS, un peu dynamique : grille, cibles, trucs abstraits mais stylés ») ----------
   Remplace la carte en 3D derrière les menus (menu3d.js ne dessine plus : ?fond3d pour la revoir). Tout en CSS et SVG,
   animé seulement par des transformations (le processeur graphique s'en charge : rien à recalculer sur le S9) :
   une grille en perspective qui défile vers soi, trois réticules qui tournent lentement, des traits de visée qui passent,
   un balayage, des rayures et des repères d'angle. Laiton clair (--accent) et acier, très sombre. */
#accueil.abstrait, #accueil.abstrait.trois-d { background: #05070a; }
#accueil.abstrait .fond, #accueil.abstrait.trois-d .fond { background: radial-gradient(ellipse 90% 80% at 55% 45%, #121820 0%, #0a0e13 55%, #05070a 100%); }
#accueil.abstrait .plans, #accueil.abstrait .voile3d { display: none; }
#accueil.abstrait[data-ecran]:not([data-ecran="ecran-titre"]):not([data-ecran="menu"]) .fond::after { background: rgba(5, 7, 10, .45); }
.fond-fps { display: none; }
#accueil.abstrait .fond-fps { display: block; position: absolute; inset: 0; overflow: hidden; --ff: 240, 212, 138; --acier: 140, 170, 200; }
/* La grille au sol, en perspective, qui avance vers soi (une case par cycle : la boucle ne se voit pas). */
.ff-sol { position: absolute; left: -50%; right: -50%; bottom: 0; height: 58%; perspective: 420px; perspective-origin: 50% 0%;
  -webkit-mask: linear-gradient(to top, #000 10%, transparent 92%); mask: linear-gradient(to top, #000 10%, transparent 92%); }
.ff-sol i { position: absolute; left: 0; right: 0; top: 0; height: 260%; transform-origin: 50% 0; transform: rotateX(66deg) translateY(0);
  background-image: linear-gradient(rgba(var(--ff), .2) 1px, transparent 1px), linear-gradient(90deg, rgba(var(--ff), .14) 1px, transparent 1px);
  background-size: 64px 64px; animation: ff-sol 3.2s linear infinite; will-change: transform; }
@keyframes ff-sol { to { transform: rotateX(66deg) translateY(64px); } }
/* En haut : une trame de points d'acier, très discrète. */
.ff-ciel { position: absolute; inset: 0 0 45% 0; background-image: radial-gradient(rgba(var(--acier), .16) 1px, transparent 1.4px); background-size: 26px 26px;
  -webkit-mask: linear-gradient(to bottom, #000, transparent); mask: linear-gradient(to bottom, #000, transparent); opacity: .7; }
.ff-rayures { position: absolute; right: -4%; top: -6%; width: 34%; height: 30%; opacity: .5;
  background: repeating-linear-gradient(135deg, rgba(var(--ff), .1) 0 2px, transparent 2px 14px);
  -webkit-mask: linear-gradient(225deg, #000 20%, transparent 75%); mask: linear-gradient(225deg, #000 20%, transparent 75%); }
/* Les réticules : anneaux, graduations, arcs en pointillés ; chacun tourne à son rythme. */
.ff-reticule { position: absolute; pointer-events: none; }
.ff-reticule svg { width: 100%; height: 100%; overflow: visible; }
.ff-reticule circle, .ff-reticule path { stroke: rgba(var(--ff), .5); }
.ff-reticule .ff-pt { fill: rgba(var(--ff), .7); stroke: none; }
.ff-a1 { transform-origin: 0 0; animation: ff-tourne 46s linear infinite; }
.ff-a2 { transform-origin: 0 0; animation: ff-tourne 30s linear infinite reverse; }
@keyframes ff-tourne { to { transform: rotate(360deg); } }
.ff-r1 { width: 74vh; height: 74vh; right: -14vh; top: 50%; margin-top: -37vh; opacity: .55; }
.ff-r2 { width: 30vh; height: 30vh; left: 6%; top: 10%; opacity: .32; }
.ff-r2 .ff-a1 { animation-duration: 24s; } .ff-r2 .ff-a2 { animation-duration: 16s; }
.ff-r3 { width: 18vh; height: 18vh; left: 40%; bottom: 14%; opacity: .26; animation: ff-derive 18s ease-in-out infinite alternate; }
@keyframes ff-derive { to { transform: translate(14vw, -8vh); } }
.ff-r3 circle, .ff-r3 path { stroke: rgba(var(--acier), .7); }
/* Traits de visée qui traversent l'écran de temps en temps. */
.ff-traits i { position: absolute; left: 0; height: 1px; width: 38%; opacity: 0;
  background: linear-gradient(90deg, transparent, rgba(var(--ff), .8), transparent); animation: ff-trait 7s ease-in infinite; }
.ff-traits i:nth-child(1) { top: 28%; animation-delay: .5s; }
.ff-traits i:nth-child(2) { top: 61%; animation-delay: 3.1s; animation-duration: 9s; }
.ff-traits i:nth-child(3) { top: 44%; animation-delay: 5.6s; animation-duration: 11s; background: linear-gradient(90deg, transparent, rgba(var(--acier), .8), transparent); }
@keyframes ff-trait { 0% { transform: translateX(-110%); opacity: 0; } 8% { opacity: 1; } 22% { transform: translateX(290%); opacity: 0; } 100% { transform: translateX(290%); opacity: 0; } }
/* Le balayage : une bande de lumière qui descend lentement. */
.ff-balayage { position: absolute; left: 0; right: 0; top: 0; height: 22%; opacity: .5;
  background: linear-gradient(to bottom, transparent, rgba(var(--ff), .05) 70%, rgba(var(--ff), .14) 98%, transparent);
  animation: ff-balaye 9s linear infinite; will-change: transform; }
@keyframes ff-balaye { from { transform: translateY(-100%); } to { transform: translateY(520%); } }
/* Repères d'angle, comme un viseur posé sur tout l'écran. */
.ff-coins i { position: absolute; width: 34px; height: 34px; border: 0 solid rgba(var(--ff), .35); }
.ff-coins i:nth-child(1) { left: 10px; top: 10px; border-left-width: 2px; border-top-width: 2px; }
.ff-coins i:nth-child(2) { right: 10px; top: 10px; border-right-width: 2px; border-top-width: 2px; }
.ff-coins i:nth-child(3) { left: 10px; bottom: 10px; border-left-width: 2px; border-bottom-width: 2px; }
.ff-coins i:nth-child(4) { right: 10px; bottom: 10px; border-right-width: 2px; border-bottom-width: 2px; }
@media (prefers-reduced-motion: reduce) { .ff-sol i, .ff-a1, .ff-a2, .ff-r3, .ff-traits i, .ff-balayage { animation: none; } }
.mc-phrase.vide { min-height: 0; padding-top: 0; }
/* Les emblèmes des modes : dessinés par Codex (métal gravé, images-sources/accueil/icones-modes.png, 29 nov. 2026). */
img.mc-emb { display: block; object-fit: contain; width: 70%; max-width: 190px; color: inherit; }
.acc-carte:hover img.mc-emb, .acc-carte:focus-visible img.mc-emb { filter: drop-shadow(0 4px 14px rgba(0, 0, 0, .6)) brightness(1.12); }
/* Au téléphone, pas de survol : un doigt resté là (après « Commencer ») n'allume pas une carte ; seule la dernière jouée. */
@media (hover: none) {
  .acc-carte:hover:not(.on) { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
  .acc-carte:hover:not(.on) .mc-fond { filter: brightness(.42) saturate(.65); transform: none; }
  .acc-carte:hover:not(.on) .mc-fond::before { opacity: 0; }
  .acc-carte:hover:not(.on) .mc-jouer { opacity: 0; transform: translateY(8px); }
  .acc-carte:hover:not(.on) .mc-emb { transform: none; }
}
.mc-phrase { font-size: clamp(12px, 1.55vw, 18px); }
/* Réglage du fond abstrait (29 nov. 2026, soir) : visible, sans écraser les menus. Les voiles d'avant (faits pour la
   carte 3D) sont allégés ; un horizon de lumière laiton derrière la grille, une lueur acier en haut à gauche. */
#accueil.abstrait .fond::after { background: radial-gradient(ellipse 85% 75% at 50% 50%, transparent 40%, rgba(4, 6, 9, .55) 100%); }
#accueil.abstrait[data-ecran]:not([data-ecran="ecran-titre"]):not([data-ecran="menu"]) .fond::after { background: rgba(5, 7, 10, .3); }
#accueil.abstrait #menu::before { background: radial-gradient(ellipse 90% 85% at 50% 50%, transparent 45%, rgba(5, 7, 10, .6)); }
#accueil.abstrait .fond-fps::before { content: ''; position: absolute; inset: 0;
  background: radial-gradient(ellipse 70% 30% at 50% 44%, rgba(var(--ff), .13), transparent 70%),
              radial-gradient(ellipse 45% 40% at 12% 8%, rgba(var(--acier), .1), transparent 70%); }
.ff-sol { height: 56%; }
.ff-sol::before { content: ''; position: absolute; left: 0; right: 0; top: 0; height: 2px; z-index: 1;
  background: linear-gradient(90deg, transparent 8%, rgba(var(--ff), .55) 35%, rgba(var(--ff), .75) 50%, rgba(var(--ff), .55) 65%, transparent 92%);
  box-shadow: 0 0 18px 2px rgba(var(--ff), .35); }
.ff-sol i { background-image: linear-gradient(rgba(var(--ff), .38) 1px, transparent 1px), linear-gradient(90deg, rgba(var(--ff), .28) 1px, transparent 1px);
  background-size: 48px 48px; animation-name: ff-sol48; }
@keyframes ff-sol48 { to { transform: rotateX(66deg) translateY(48px); } }
.ff-ciel { opacity: 1; background-image: radial-gradient(rgba(var(--acier), .28) 1px, transparent 1.5px); }
.ff-reticule circle, .ff-reticule path { stroke: rgba(var(--ff), .7); }
.ff-r1 { opacity: .75; } .ff-r2 { opacity: .5; } .ff-r3 { opacity: .45; }
.ff-rayures { opacity: .8; }
.ff-coins i { border-color: rgba(var(--ff), .55); }
.ff-balayage { opacity: .9; }
/* Le fond, en plus sobre (porteur, 29 nov. 2026, nuit : « trop forcé, pas assez subtil, FPS haut de gamme ») : plus de
   grille en perspective, d'horizon doré, de traits de visée ni de petits réticules. Reste : un fond charbon, une lueur
   froide, une trame fine presque invisible, UN grand réticule très pâle qui tourne lentement, un léger grain, une lumière
   qui passe doucement. Tout ce qui est retiré n'est plus dessiné (display: none : rien ne tourne pour rien). */
#accueil.abstrait .fond, #accueil.abstrait.trois-d .fond { background: radial-gradient(ellipse 120% 95% at 68% 40%, #161b21 0%, #0c0f13 55%, #06080a 100%); }
#accueil.abstrait .fond-fps::before { background: radial-gradient(ellipse 50% 45% at 72% 42%, rgba(var(--acier), .07), transparent 70%); }
.ff-sol, .ff-traits, .ff-r2, .ff-r3, .ff-rayures { display: none; }
.ff-ciel { inset: 0; opacity: 1; background-image: linear-gradient(rgba(255, 255, 255, .022) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .022) 1px, transparent 1px);
  background-size: 96px 96px; -webkit-mask: radial-gradient(ellipse 70% 70% at 62% 45%, #000 15%, transparent 80%); mask: radial-gradient(ellipse 70% 70% at 62% 45%, #000 15%, transparent 80%); }
.ff-r1 { width: 118vh; height: 118vh; right: -34vh; margin-top: -59vh; opacity: .13; }
.ff-r1 circle, .ff-r1 path { stroke: rgba(var(--acier), 1); }
.ff-r1 .ff-pt { fill: rgba(var(--acier), 1); }
.ff-r1 .ff-a1 { animation-duration: 140s; } .ff-r1 .ff-a2 { animation-duration: 100s; }
.ff-balayage { opacity: 1; height: 35%; background: linear-gradient(to bottom, transparent, rgba(255, 255, 255, .018) 75%, rgba(255, 255, 255, .03) 97%, transparent); animation-duration: 16s; }
.ff-coins i { width: 20px; height: 20px; border-color: rgba(255, 255, 255, .1); }
#accueil.abstrait .fond-fps::after { content: ''; position: absolute; inset: 0; opacity: .07; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"); }
#accueil.abstrait canvas.poussiere { opacity: .45; }
