/* Closer Dojo : carte de progression (prototype A, perspective 2.5D légère), intégrée à l'app le 25 novembre 2026.
   Toutes les règles sont limitées à #carte : la carte garde sa propre palette (claire) sans toucher au reste de l'app.
   Fichier produit à partir de prototypes/progression/style.css et kit/tokens.css (le prototype garde l'original) ; les noms .btn, .stage et les animations sont préfixés (.cbtn, .cstage, c-...) pour ne pas heurter l'app. */
#carte {
  --dojo-fond: #FFF8EA;
  --dojo-texte: #16292B;
  --dojo-orange: #F68B24;
  --dojo-orange-clair: #FFC879;
  --dojo-sauge: #83BDA3;
  --dojo-herbe: #A9CE91;
  --dojo-herbe-foncee: #608A54;
  --dojo-route: #F4E7CA;
  --dojo-roche: #A7A89E;
  --dojo-ciel: #CBE6E9;
  --dojo-nuit: #344E69;
  --dojo-obsidienne: #28383C;
  --dojo-bois: #9D6643;
  --dojo-rose: #F2B6BD;
  --dojo-or: #F0B547;
  --dojo-font-titre: "Bricolage Grotesque", system-ui, sans-serif;
  --dojo-font-texte: "Instrument Sans", system-ui, sans-serif;
}
#carte {
  --bg: #F7F7F2; --ink: #16292B; --muted: #5B6B6D; --line: #DDE4DF; --surface: #FFFFFF; --surface-2: #E5EDE8;
  --orange: #F68B24; --orange-deep: #C96A0E; --orange-soft: #FFE3C4; --vert: #83BDA3; --vert-deep: #5E9C82; --focus: #1D6FB8;
  --sable: #EFE6D2; --sable-deep: #D7CBB0; --herbe-1: #B7D9A4; --herbe-2: #A4CD92; --herbe-3: #8DBB7F;
  --display: "Bricolage Grotesque", "Avenir Next", system-ui, sans-serif;
  --body: "Instrument Sans", "Helvetica Neue", system-ui, sans-serif;
  --ombre: 0 1px 2px rgba(22, 41, 43, .08), 0 10px 26px rgba(22, 41, 43, .10);
}
#carte * { box-sizing: border-box; }
#carte { background: var(--bg); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.4; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; overflow: hidden; overscroll-behavior: none; }
#carte button { font: inherit; color: inherit; cursor: pointer; }
#carte :focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; border-radius: 12px; }
#carte [hidden] { display: none !important; }
/* L'écran de la carte : plein écran, centré sur 480 px comme le reste de l'app. Il est affiché par la classe .screen.active de l'app. */
#carte.screen { position: fixed; inset: 0; z-index: 30; max-width: 480px; margin: 0 auto; padding: 0; flex-direction: column; background: var(--bg); }
#carte .entete { flex: none; display: flex; align-items: center; gap: 12px; padding: max(10px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-left)) 10px max(16px, env(safe-area-inset-left)); background: linear-gradient(to bottom, #FFF8EA, rgba(255, 248, 234, .92)); z-index: 30; position: relative; box-shadow: 0 1px 0 rgba(22, 41, 43, .06); }
#carte .famille-btn { display: flex; align-items: center; gap: 10px; min-width: 0; flex: 1; border: 0; background: none; padding: 4px; text-align: left; }
#carte .famille-icone { flex: none; width: 46px; height: 46px; border-radius: 14px; background: #FFE9B8; display: grid; place-items: center; box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .08); }
#carte .famille-txt { min-width: 0; }
#carte .famille-txt small { display: block; font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
#carte .famille-txt b { display: flex; align-items: center; gap: 6px; font-family: var(--display); font-weight: 800; font-size: 24px; line-height: 1.1; }
#carte .etoiles-total { flex: none; display: flex; align-items: center; gap: 6px; padding: 8px 14px; border-radius: 999px; background: #fff; border: 1.5px solid #F0E3C8; font-weight: 600; font-variant-numeric: tabular-nums; box-shadow: 0 2px 6px rgba(0, 0, 0, .05); }
#carte .etoiles-total.bump { animation: c-bump .6s ease; }
@keyframes c-bump { 40% { transform: scale(1.18); } }
#carte .centre { flex: 1; position: relative; min-height: 0; }
#carte .panneau { position: absolute; inset: 0; }
#carte .defileur { position: absolute; inset: 0; overflow-y: auto; overflow-x: hidden; overscroll-behavior: none; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
#carte .defileur::-webkit-scrollbar { display: none; }
#carte .cstage { position: sticky; top: 0; width: 100%; overflow: hidden; background: #DDEFE6; }
#carte .espaceur { width: 1px; }
#carte .cstage > * { position: absolute; left: 0; top: 0; }
#carte .ciel { width: 100%; height: 100%; background: linear-gradient(to bottom, #FFF1D6 0%, #FFE2BE 12%, #E4EFE0 34%, #CFE6D8 100%); }
#carte .cstage svg { overflow: visible; }
#carte #horizon, #carte #sol, #carte #route { width: 100%; height: 100%; pointer-events: none; }
#carte #horizon { z-index: 1; will-change: transform; }
#carte #sol { z-index: 50; }
#carte #route { z-index: 60; }
#carte .brume { width: 100%; pointer-events: none; z-index: 4000; background: linear-gradient(to bottom, rgba(255, 244, 222, 0), rgba(255, 244, 222, .8) 55%, rgba(255, 244, 222, 0)); }
#carte #objets { width: 100%; height: 100%; }
#carte .dec { position: absolute; left: 0; top: 0; pointer-events: none; will-change: transform; transform-origin: 50% 100%; }
#carte .dec svg { display: block; }
#carte .niv { position: absolute; left: 0; top: 0; padding: 0; border: 0; background: none; will-change: transform; transform-origin: 50% 50%; width: var(--lw); height: var(--lh); touch-action: manipulation; }
#carte .disque { position: absolute; inset: 0; border-radius: 50%; display: flex; align-items: center; justify-content: center; gap: 5px; font-family: var(--display); font-weight: 800; font-size: 28px; background: var(--c1); color: var(--ink); box-shadow: 0 0 0 4px rgba(255, 255, 255, .72), 0 9px 0 var(--c2), 0 17px 22px rgba(22, 41, 43, .20); transition: box-shadow .15s; }
#carte .niv:active .disque { transform: translateY(4px); box-shadow: 0 5px 0 var(--c2), 0 8px 14px rgba(22, 41, 43, .2); }
#carte .niv .num { display: block; line-height: 1; }
#carte .niv .ico { display: block; line-height: 0; }
#carte .niv.futur { --c1: #EBDDBE; --c2: #BCA97F; color: #5A4E36; }
#carte .niv.fini { --c1: #A9D4BF; --c2: #6FAE92; color: #14403A; }
#carte .niv.actuel { --c1: #FFA13F; --c2: #D26E0C; color: #3A1D00; }
#carte .niv.actuel .disque { box-shadow: 0 0 0 4px rgba(255, 255, 255, .8), 0 9px 0 var(--c2), 0 0 0 7px rgba(246, 139, 36, .22), 0 0 34px 12px rgba(246, 139, 36, .45), 0 17px 22px rgba(22, 41, 43, .2); }
#carte .pastille { display: none; position: absolute; left: 50%; bottom: -34px; transform: translateX(-50%); white-space: nowrap; padding: 3px 10px; border-radius: 999px; background: #fff; border: 1.5px solid #E8DDBF; font-size: 14px; font-weight: 700; color: #8A5A00; font-variant-numeric: tabular-nums; }
#carte .niv.fini .pastille { display: block; }
#carte .details { position: absolute; inset: 0; display: block; pointer-events: none; }
#carte .marq { display: none; position: absolute; width: 26px; height: 26px; border-radius: 50%; place-items: center; }
#carte .marq.on { display: grid; }
#carte .marq.hardcore { top: -8px; right: -6px; background: #2A1F3A; box-shadow: 0 2px 6px rgba(0, 0, 0, .3); }
#carte .marq.trophee { top: -8px; left: -6px; background: #fff; border: 1.5px solid #E8DDBF; }
#carte .pouls { position: absolute; inset: 0; z-index: 0; display: block; }
#carte .niv.actuel .pouls { animation: c-pouls var(--pouls-duree, 3.5s) ease-in-out infinite; will-change: transform; }
@keyframes c-pouls { 0%, 100% { transform: scale(var(--pouls-min, .9)); } 50% { transform: scale(var(--pouls-max, 1.3)); } }
#carte .niv .pop { animation: c-pop .75s cubic-bezier(.2, .9, .3, 1.3); }
@keyframes c-pop { 0% { transform: scale(.7); } 50% { transform: scale(1.22); } 100% { transform: scale(1); } }
#carte .bulle { position: absolute; left: 0; top: 0; z-index: 5000; pointer-events: none; padding: 7px 14px; border-radius: 14px; background: var(--orange); color: #3A1D00; font-weight: 700; font-size: 14px; white-space: nowrap; box-shadow: 0 6px 14px rgba(246, 139, 36, .35); will-change: transform; }
#carte .bulle.g::before { left: auto; right: -7px; border: 7px solid transparent; border-right: 0; border-left-color: var(--orange); }
#carte .bulle::before { content: ""; position: absolute; left: -7px; top: 50%; margin-top: -7px; border: 7px solid transparent; border-left: 0; border-right-color: var(--orange); }
#carte .retour { position: absolute; z-index: 40; left: 50%; bottom: 16px; transform: translate(-50%, 0); display: flex; align-items: center; gap: 8px; padding: 12px 20px; border: 0; border-radius: 999px; background: var(--orange); color: #3A1D00; font-weight: 700; box-shadow: 0 8px 20px rgba(246, 139, 36, .45); transition: opacity .25s, transform .25s; white-space: nowrap; }
#carte .retour[data-etat="cache"] { opacity: 0; pointer-events: none; transform: translate(-50%, 14px); }
#carte .voile { position: absolute; inset: 0; z-index: 90; background: rgba(22, 41, 43, .42); }
#carte .feuille { position: absolute; z-index: 100; left: 0; right: 0; bottom: 0; padding: 18px 18px max(22px, env(safe-area-inset-bottom)); border-radius: 26px 26px 0 0; background: #FFFDF8; box-shadow: 0 -10px 40px rgba(22, 41, 43, .25); max-height: 82%; overflow-y: auto; animation: c-monte .28s cubic-bezier(.2, .8, .2, 1); }
@keyframes c-monte { from { transform: translateY(40px); opacity: 0; } }
#carte .feuille .poignee { width: 44px; height: 5px; border-radius: 9px; background: #D9D3C3; margin: -6px auto 12px; }
#carte .feuille small.sur { font-weight: 600; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
#carte .feuille h3 { font-family: var(--display); font-weight: 800; font-size: 25px; line-height: 1.15; margin: 4px 0 8px; }
#carte .feuille p { margin: 0 0 12px; }
#carte .etat { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 14px; }
#carte .jeton { display: inline-flex; align-items: center; gap: 6px; padding: 5px 12px; border-radius: 999px; background: var(--surface-2); font-weight: 600; font-size: 14px; }
#carte .jeton.or { background: #FFF0CF; color: #8A5A00; }
#carte .jeton.sombre { background: #2A1F3A; color: #fff; }
#carte .actions { display: grid; gap: 10px; }
#carte .cbtn { padding: 14px 18px; border: 0; border-radius: 16px; font-weight: 700; font-size: 16px; }
#carte .cbtn.princ { background: var(--orange); color: #3A1D00; box-shadow: 0 5px 0 var(--orange-deep); }
#carte .cbtn.sec { background: var(--surface-2); color: var(--ink); }
#carte .cbtn.ghost { background: none; color: var(--muted); }
#carte .fam-choix { display: grid; gap: 10px; margin-top: 10px; }
#carte .fam-choix button { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 2px solid transparent; border-radius: 16px; background: #fff; box-shadow: var(--ombre); text-align: left; }
#carte .fam-choix button[aria-current="true"] { border-color: var(--orange); }
#carte .fam-choix .nom { font-weight: 700; }
#carte .fam-choix small { color: var(--muted); display: block; }
#carte .fam-choix .score { margin-left: auto; font-weight: 700; color: #8A5A00; white-space: nowrap; }
@media (prefers-reduced-motion: reduce) {
  #carte .niv .pop, #carte .niv.actuel .pouls, #carte .etoiles-total.bump, #carte .feuille { animation: none !important; }
  #carte .retour { transition: none !important; }
}
/* ---------- Kit graphique V2 (prototype A : classe .kit sur <html>) ---------- */
#carte .ciel.kit-ciel { background: url("../carte/fonds/fond-ciel-jour.svg") 72% top / cover no-repeat, #A9D7E5; }
#carte .dec img { display: block; pointer-events: none; user-select: none; -webkit-user-drag: none; }
#carte .dec::after { content: ""; position: absolute; z-index: -1; left: 10%; right: 10%; bottom: -2.5%; height: 9%; border-radius: 50%; background: radial-gradient(closest-side, rgba(38, 66, 40, .34), rgba(38, 66, 40, 0)); pointer-events: none; }
#carte .niv .plq { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; user-select: none; -webkit-user-drag: none; }
#carte .disque { background: none; box-shadow: none; border-radius: 0; transition: none; padding-bottom: 9%; font-size: 26px; z-index: 1; }
#carte .niv:active .disque { transform: translateY(2px); box-shadow: none; }
#carte .niv.actuel .disque { box-shadow: none; }
#carte .niv .pouls::before { content: ""; position: absolute; z-index: -1; left: 4%; right: 4%; bottom: -9%; height: 24%; border-radius: 50%; background: radial-gradient(closest-side, rgba(38, 66, 40, .38), rgba(38, 66, 40, 0)); pointer-events: none; }
#carte .niv.actuel .pouls::after { content: ""; position: absolute; z-index: -1; inset: -34% -26%; border-radius: 50%; background: radial-gradient(closest-side, rgba(255, 170, 70, .55), rgba(255, 170, 70, 0)); pointer-events: none; }
#carte .niv.futur { color: #5A4E36; }
#carte .niv.fini { color: #14403A; }
#carte .niv.actuel { color: #3A1D00; }
#carte .niv.tr { color: #FFF8EA; }
#carte .pastille { bottom: -31px; }
#carte .marq { width: 28px; height: 28px; background: #FFF8EA; border: 1.5px solid #E8DDBF; box-shadow: 0 2px 6px rgba(0, 0, 0, .25); z-index: 2; }
#carte .marq.hardcore { top: -10px; right: -8px; background: #FFF8EA; }
#carte .marq.trophee { top: -10px; left: -8px; background: #28383C; border-color: #28383C; }
#carte .marq.trophee svg { color: #F0B547 !important; }
#carte .niv.tr .disque { color: #FFF8EA; }
/* ---------- Entrée dans un monde : deux portes japonaises (voir entrer dans moteur.js) ---------- */
#carte .portes { position: absolute; inset: 0; z-index: 300; overflow: hidden; }
#carte .porte { position: absolute; top: 0; bottom: 0; width: calc(50% + 1px); background: #4A2F1E; will-change: transform; }
#carte .porte.g { left: 0; }
#carte .porte.d { right: 0; }
#carte .porte i { position: absolute; inset: 0; background: center / 100% 100% no-repeat; }
#carte .porte.d i { transform: scaleX(-1); }

/* ---------- Ajouts propres à l'app ---------- */
/* Bouton « retour à l'accueil » à gauche de l'en-tête. */
#carte .retour-accueil { flex: none; width: 44px; height: 44px; margin-left: -4px; border: 0; border-radius: 50%; background: #fff; border: 1.5px solid #F0E3C8; display: grid; place-items: center; color: var(--ink); }
#carte .retour-accueil:active { transform: scale(.94); }
/* Le nom de la famille peut être long (« Fausses objections ») : il se réduit puis se coupe avant les étoiles. */
#carte .famille-txt b { font-size: clamp(17px, 5.2vw, 24px); }
#carte .famille-btn { gap: 8px; }
#carte .famille-icone { width: 40px; height: 40px; }
/* Écran étroit (téléphone) : la pièce décorative disparaît pour laisser la place au nom de la famille. */
@media (max-width: 440px) { #carte .famille-icone { display: none; } #carte .famille-txt b { font-size: clamp(17px, 5vw, 22px); } }
/* Famille pas encore découverte dans le sélecteur. */
#carte .fam-choix button:disabled { opacity: .55; cursor: default; box-shadow: none; }
/* « Revenir à mon niveau » : un peu plus haut, pour ne pas passer sous le badge Netlify en bas de page. */
#carte .retour { bottom: 56px; }

/* ---------- Tuiles de la carte (choix de Jules du 28 novembre 2026, atelier prototypes/tuiles/) ----------
   Les images des plaques sont dessinées par build/plaques_carte.js. Ici : chiffre, lueur, et plus d'icône sur les tuiles. */
#carte .niv .ico { display: none; }
#carte .disque { padding-bottom: 11.5%; }
#carte .niv .num { font-family: "Unbounded", var(--display); font-size: 25px; font-weight: 900; line-height: 1;
  transform: perspective(90px) rotateX(38deg) rotate(-7deg); transform-origin: 50% 60%;
  -webkit-text-stroke: 3.3px #FFFFFF; paint-order: stroke fill; }
#carte .niv.fini .num { color: #34983b; }
#carte .niv.actuel .num { color: #e07800; }
#carte .niv.futur .num { color: #dfdce5; }
#carte .niv.tr .num { color: #3c1a4d; }
/* Lueur diffuse : blanche sur le cas en cours, rose violet sur le boss (cas réussi en Hardcore), aucune ailleurs. */
#carte .niv.actuel .plq { filter: drop-shadow(0 0 4px #FFFFFF) drop-shadow(0 0 2.4px rgba(255, 255, 255, .3)); }
#carte .niv.tr .plq { filter: drop-shadow(0 0 9.5px rgb(225, 86, 200)) drop-shadow(0 0 5.7px rgba(225, 86, 200, .75)); }

/* ---------- Fiche du cas F3 « appel entrant » (28 novembre 2026, prototype prototypes/fiche/) ---------- */
/* Ouverture en ease-in, fermeture : la carte dézoome en ease-out (la fiche, elle, descend en ease-in, réglé dans carte.js). */
#carte.f3-ouvre .entete { transition: margin-top .5s cubic-bezier(.42,0,1,1); }
#carte.f3-ouvre .centre { transform-origin: 0 0; transition: transform .5s cubic-bezier(.42,0,1,1), filter .5s cubic-bezier(.42,0,1,1); will-change: transform, filter; }
#carte.f3-sortie .entete { transition: margin-top .5s cubic-bezier(0,0,.58,1); }
#carte.f3-sortie .centre { transform-origin: 0 0; transition: transform .5s cubic-bezier(0,0,.58,1), filter .5s cubic-bezier(0,0,.58,1); will-change: transform, filter; }
#carte .f3 { position: absolute; inset: 0; z-index: 95; display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 30px 20px max(22px, env(safe-area-inset-bottom)); overflow-y: auto; scrollbar-width: none;
  background: linear-gradient(to bottom, rgba(255, 248, 234, .35), rgba(255, 248, 234, .96) 34%); opacity: 0; transition: opacity .45s cubic-bezier(.42,0,1,1), background .4s, color .4s; }
#carte .f3::-webkit-scrollbar { display: none; }
#carte .f3.ouvert { opacity: 1; }
#carte .f3.hc { background: linear-gradient(to bottom, rgba(20, 30, 34, .5), #1C282B 34%); color: #EEF2F1; }
#carte .f3-cas { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; background: rgba(255, 255, 255, .88); border-radius: 99px; padding: 4px 12px 4px 5px; font-size: 13px; font-weight: 600; color: var(--ink);
  transform: translateY(-10px); opacity: 0; transition: transform .4s cubic-bezier(.42,0,1,1) .15s, opacity .4s cubic-bezier(.42,0,1,1) .15s; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#carte .f3-cas i { font-style: normal; font-family: var(--display); font-weight: 800; background: var(--orange); border-radius: 99px; padding: 1px 8px; flex: none; }
#carte .f3.ouvert .f3-cas { transform: none; opacity: 1; }
#carte .f3-avwrap { position: relative; width: 116px; height: 116px; margin-top: 18px; flex: none; border-radius: 50%; }
#carte .f3-avwrap[role="button"] { cursor: pointer; }
#carte .f3-av { position: relative; z-index: 1; display: block; width: 116px; height: 116px; border-radius: 50%; overflow: hidden; box-shadow: 0 8px 24px rgba(22, 41, 43, .18); }
#carte .f3-av svg { width: 100%; height: 100%; display: block; }
#carte .f3-av.sk { box-shadow: none; }
#carte .f3-avwrap .onde { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--onde, #3FA66B); opacity: 0; pointer-events: none; }
#carte .f3-avwrap.sonne .onde { animation: f3-onde 2s ease-out infinite; }
#carte .f3-avwrap.sonne .onde:nth-child(2) { animation-delay: .66s; }
#carte .f3-avwrap.sonne .onde:nth-child(3) { animation-delay: 1.33s; }
@keyframes f3-onde { from { transform: scale(1); opacity: .55; } to { transform: scale(1.5); opacity: 0; } }
#carte .f3-avwrap.sonne .f3-av { animation: f3-vibre 2s ease-in-out infinite; }
@keyframes f3-vibre { 0%, 70%, 100% { transform: rotate(0); } 74% { transform: rotate(-4deg); } 78% { transform: rotate(4deg); } 82% { transform: rotate(-3deg); } 86% { transform: rotate(3deg); } 90% { transform: rotate(0); } }
#carte .f3-nom { font-family: var(--display); font-weight: 800; font-size: 28px; line-height: 1.05; margin-top: 10px; text-align: center; min-height: 30px; width: 100%; }
#carte .f3-sknom { display: block; height: 26px; width: 60%; margin: 0 auto; }
#carte .f3-etat { font-size: 13px; color: var(--muted); display: flex; align-items: center; gap: 6px; }
#carte .f3-etat i { width: 7px; height: 7px; border-radius: 50%; background: #3FA66B; animation: f3-clign 1s infinite; }
@keyframes f3-clign { 50% { opacity: .2; } }
#carte .f3-info { width: 100%; display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
#carte .f3-info .jetons { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
#carte .f3-info .jeton { font-size: 12.5px; padding: 4px 10px; color: var(--ink); }
#carte .f3-info .jeton.sombre { color: #fff; }
#carte .f3-info .jeton svg { width: 14px; height: 14px; }
#carte .f3-ouv { margin: 0; text-align: center; font-style: italic; }
#carte .f3-bloc { background: #FAF5EA; border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 9px; font-size: 15px; }
#carte .f3-bloc .l, #carte .f3-conseil .l { display: block; font-size: 10.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 1px; }
#carte .f3-bloc q { font-style: italic; quotes: "« " " »"; }
#carte .f3-conseil { background: var(--orange-soft); color: var(--ink); border-radius: 16px; padding: 11px 14px; display: flex; flex-direction: column; gap: 2px; }
#carte .f3-conseil .l { color: #8A4B00; }
#carte .f3-conseil .l + * { margin-top: 0; }
#carte .f3-conseil p { margin: 0 0 6px; }
#carte .f3-conseil .was { color: #6B5A45; text-decoration: line-through; text-decoration-color: rgba(138, 75, 0, .4); font-size: 13px; margin-bottom: 2px; }
#carte .f3-conseil .now { font-weight: 600; }
#carte .f3 .note-hard { margin: 0; font-size: 13px; color: var(--muted); text-align: center; }
#carte .f3 .sk { display: block; height: 11px; border-radius: 6px; background: linear-gradient(90deg, #EFE8D8 0%, #F9F4EA 50%, #EFE8D8 100%); background-size: 200% 100%; animation: f3-brille 1.2s linear infinite; }
#carte .f3 .sk.m { width: 62%; } #carte .f3 .sk.p { width: 40%; }
#carte .f3-av.sk { height: 116px; }
@keyframes f3-brille { to { background-position: -200% 0; } }
#carte .f3.hc .f3-bloc { background: #26363A; }
#carte .f3.hc .f3-bloc .l, #carte .f3.hc .f3-etat, #carte .f3.hc .note-hard { color: #A9B7B9; }
#carte .f3-boutons { width: 100%; display: flex; justify-content: space-around; margin-top: auto; padding-top: 14px; }
#carte .f3 .rond { width: 76px; height: 76px; border-radius: 50%; border: 0; display: grid; place-items: center; color: #fff; transition: transform .15s, opacity .3s; }
#carte .f3 .rond svg { width: 32px; height: 32px; }
#carte .f3 .rond:active { transform: scale(.94); }
#carte .f3 .rond[disabled] { opacity: .45; cursor: default; }
#carte .f3 .rond.vert { background: #3FA66B; box-shadow: inset 0 -4px 0 #2C7F50; }
#carte .f3 .rond.vert.pret { animation: f3-pulse 1.6s ease-out infinite; }
@keyframes f3-pulse { 0% { box-shadow: inset 0 -4px 0 #2C7F50, 0 0 0 0 rgba(63, 166, 107, .45); } 100% { box-shadow: inset 0 -4px 0 #2C7F50, 0 0 0 18px rgba(63, 166, 107, 0); } }
#carte .f3 .rond.rouge { background: #D9544D; box-shadow: inset 0 -4px 0 #A83A34; }
#carte .f3 .rond.rouge svg { transform: rotate(135deg); }
#carte .f3.hc .rond.vert { background: var(--obsidienne, #28383C); box-shadow: inset 0 -4px 0 #0F181A, 0 0 0 3px #F0B547; animation: none; }
#carte .f3 .rlab { text-align: center; font-weight: 600; font-size: 13.5px; margin-top: 6px; }
#carte .f3-liens { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; }
#carte .f3 .lien { border: 0; background: none; color: var(--muted); font-size: 13.5px; text-decoration: underline; text-underline-offset: 2px; padding: 6px; }
#carte .f3.hc .lien { color: #A9B7B9; }
/* La plaque « gobe » l'avatar : elle s'ouvre en s'aplatissant, l'avale avec un petit saut, puis retombe (et une onde). */
#carte .niv .pouls.f3-ouvre-plq { animation: none; transition: transform .3s cubic-bezier(.3,.7,.4,1); transform: scale(1.1, .9); }
#carte .niv .pouls.f3-gobe { animation: f3-gobe .56s cubic-bezier(.3,.7,.4,1); }
@keyframes f3-gobe { 0% { transform: scale(1.1, .9); } 22% { transform: scale(.9, 1.12); } 45% { transform: translateY(-12%) scale(1, 1.02); } 70% { transform: translateY(2%) scale(1.06, .94); } 100% { transform: none; } }
#carte .f3-onde-plq { position: absolute; left: 50%; top: 40%; width: 92%; height: 66%; border: 3px solid; border-radius: 50%; transform: translate(-50%, -50%) scale(.6); opacity: .9; animation: f3-ondeplq .52s ease-out forwards; pointer-events: none; z-index: 2; }
@keyframes f3-ondeplq { to { transform: translate(-50%, -50%) scale(1.7); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  #carte .f3, #carte .f3-cas, #carte.f3-ouvre .centre, #carte.f3-ouvre .entete, #carte.f3-sortie .centre, #carte.f3-sortie .entete { transition: none !important; }
  #carte .f3-avwrap .onde, #carte .f3-av, #carte .f3 .rond.vert.pret, #carte .f3 .sk, #carte .f3-etat i { animation: none !important; }
}
/* Calques des animations de la fiche : posés sur la page entière, car l'avatar passe de la carte à l'écran du call. */
.f3-vol { position: fixed; inset: 0; z-index: 200; pointer-events: none; overflow: hidden; }
.f3-vol-av { position: absolute; left: 0; top: 0; display: block; border-radius: 50%; overflow: hidden; will-change: transform; box-shadow: 0 6px 16px rgba(22, 41, 43, .2); }
.f3-vol-av svg { width: 100%; height: 100%; display: block; }
.f3-saut { position: absolute; left: 0; top: 0; width: 0; height: 0; display: block; }
.f3-saut .f3-vol-av { transform-origin: 50% 50%; }
.f3-halo { position: fixed; z-index: 199; border-radius: 50%; pointer-events: none; }

/* ---------- Barre du bas (choix « Texte détouré » de Jules, aperçu prototypes/chemin-carte) : Techniques, Salle des trophées, Arène ----------
   Seulement sur le chemin (body[data-ecran=carte], posé par show() dans socle.js). Cachée quand une fiche ou un panneau couvre la carte. */
.barre-bas { display: none; position: fixed; z-index: 35; left: 0; right: 0; bottom: max(8px, env(safe-area-inset-bottom)); max-width: 480px; margin: 0 auto; align-items: flex-end; pointer-events: none; transition: opacity .25s; }
body[data-ecran="carte"] .barre-bas { display: flex; }
.barre-bas button { pointer-events: auto; flex: 1; min-width: 0; border: 0; background: none; padding: 0; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px; cursor: pointer; -webkit-tap-highlight-color: transparent; }
.barre-bas img { display: block; width: 58px; height: 58px; object-fit: contain; filter: drop-shadow(0 5px 5px rgba(22, 41, 43, .38)); transition: transform .25s cubic-bezier(.34, 1.56, .64, 1); }
.barre-bas .centre img { width: 70px; height: 70px; }
.barre-bas span { font: 800 11.5px/1.1 "Bricolage Grotesque", system-ui, sans-serif; color: #FFFFFF; -webkit-text-stroke: 3.2px #16292B; paint-order: stroke fill; letter-spacing: .01em; text-align: center; padding: 0 2px; }
.barre-bas button:active img { transform: scale(.9); }
body[data-ecran="carte"]:has(#carte.f3-ouvre, #carte.f3-sortie, #carte .feuille, #portes) .barre-bas { opacity: 0; }
body[data-ecran="carte"]:has(#carte.f3-ouvre, #carte.f3-sortie, #carte .feuille, #portes) .barre-bas button { pointer-events: none; }
/* Le bouton « Revenir à mon niveau » passe au-dessus de la barre. */
body[data-ecran="carte"] #carte .retour { bottom: calc(96px + env(safe-area-inset-bottom)); }
@media (prefers-reduced-motion: reduce) { .barre-bas, .barre-bas img { transition: none; } }
