/* Débandade ! — thème et composants (GDD §11). Portrait iPhone 430×932, safe-area, au pouce. */
:root {
  --bg: #0b0d12; --panel: #141633; --panel2: #1b1e42; --line: #ffffff14; --text: #f2f4f8; --mut: #9aa3b8; --ink: #1b1433;
  --p0: #2f7bff; --p1: #ff3cac; --p2: #34d399; --p3: #fcc419; --gold: #fcc419; --bad: #ff4d6d; --ok: #34d399;
  --font: Inter, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --st: env(safe-area-inset-top, 0px); --sb: env(safe-area-inset-bottom, 0px);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; overflow: hidden; overscroll-behavior: none; }
body { background: radial-gradient(120% 70% at 50% 0%, #1a1440 0%, #0b0d12 60%); background-color: var(--bg); color: var(--text); font-family: var(--font);
  -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; touch-action: manipulation; }
button { font: inherit; color: inherit; cursor: pointer; }
input { font: inherit; }
.av { position: relative; flex: none; } .av > svg { position: absolute; width: 193% !important; height: 221% !important; left: -46.4%; top: -89.3%; pointer-events: none; }

/* ---------- écrans ---------- */
.screen { position: fixed; inset: 0; display: none; flex-direction: column; overflow: hidden; }
.screen.on { display: flex; animation: slideIn .24s ease-out; }
.screen.back.on { animation: slideBack .24s ease-out; }
@keyframes slideIn { from { transform: translateX(30px); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes slideBack { from { transform: translateX(-30px); opacity: 0; } to { transform: none; opacity: 1; } }
.scroll { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding: calc(var(--st) + 14px) 16px calc(var(--sb) + 24px); display: flex; flex-direction: column; gap: 12px; }
.scroll > * { flex: none; }

/* ---------- boutons ---------- */
.btn { display: flex; align-items: center; justify-content: center; gap: 8px; min-height: 56px; padding: 0 18px; border: 0; border-radius: 20px;
  font: 900 17px var(--font); color: #fff; letter-spacing: .02em; background: #2f7bff; box-shadow: 0 5px 0 var(--ink); transition: transform .08s, box-shadow .08s; position: relative; }
.btn:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.btn:disabled { opacity: .45; }
.btn small { display: block; font: 700 12px var(--font); opacity: .85; letter-spacing: 0; }
.btn.sm { min-height: 40px; padding: 0 14px; font-size: 14px; border-radius: 14px; box-shadow: 0 4px 0 var(--ink); }
.btn.ghost { background: #ffffff12; border: 1px solid #ffffff22; box-shadow: 0 4px 0 #05060a; }
.btn.ok { background: var(--ok); color: #06281c; box-shadow: 0 5px 0 #0b5a40; }
.btn.pink { background: linear-gradient(180deg, #ff5cbc, #ff3cac 50%, #d61f8c); }
.btn.gold { background: linear-gradient(180deg, #ffe066, #fcc419 50%, #e8a200); color: #3d2c06; box-shadow: 0 5px 0 #7a5600; }
.btn.go { background: linear-gradient(180deg, #5ef0b3, #34d399 50%, #12a575); color: #06281c; box-shadow: 0 6px 0 #0b5a40, 0 0 40px #34d39955; }
.btn.shine::after { content: ''; position: absolute; left: 14px; right: 14px; top: 6px; height: 16px; border-radius: 12px; background: #ffffff33; pointer-events: none; }

/* ---------- accueil ---------- */
.top { display: flex; align-items: center; gap: 10px; }
.top .me { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; }
.top .me .av { width: 40px; height: 40px; margin: 0 4px; }
.top .me b { display: block; font: 800 16px var(--font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.top .me small { display: block; font: 700 12px var(--font); color: #9cc0ff; }
.lvl { height: 6px; width: 120px; border-radius: 3px; background: #ffffff18; margin-top: 4px; overflow: hidden; } .lvl i { display: block; height: 100%; background: linear-gradient(90deg, #2f7bff, #2bd2ff); }
.pill { display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 12px; border-radius: 99px; background: #ffffff0f; border: 1px solid #ffffff1c; font: 800 14px var(--font); white-space: nowrap; }
.pill .bb { width: 12px; height: 12px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #fff 0 15%, #ff8fc7 20%, #ff3cac); }
.hero { position: relative; height: 214px; flex: none; border-radius: 28px; overflow: hidden; background: linear-gradient(180deg, #1e1f52, #141633); border: 1px solid #ffffff14; }
.hero canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.logo { position: absolute; left: 0; right: 0; top: 16px; text-align: center; pointer-events: none; }
.logo h1 { margin: 0; font: 900 44px/1 var(--font); letter-spacing: -.01em; color: #fff3bf; transform: rotate(-3deg);
  background: linear-gradient(180deg, #fff6c2, #fcc419 60%, #ff9f1c); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 4px 0 #1b1433) drop-shadow(0 0 18px #ff3cac88); }
.logo small { display: block; margin-top: 6px; font: 800 11px var(--font); letter-spacing: .3em; color: #c9b8ff; text-transform: uppercase; }
.quick { min-height: 76px; font-size: 22px; flex-direction: column; gap: 0; border-radius: 24px; }
.modes { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.mode { position: relative; height: 112px; border-radius: 22px; padding: 12px 10px; display: flex; flex-direction: column; justify-content: flex-end; text-align: left; overflow: hidden;
  border: 1px solid #ffffff1a; box-shadow: 0 5px 0 var(--ink); color: #fff; }
.mode:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.mode b { font: 900 15px var(--font); } .mode small { font: 700 11px var(--font); opacity: .8; }
.mode.vs { background: linear-gradient(160deg, #2f7bff, #1d3fa8); } .mode.co { background: linear-gradient(160deg, #20c997, #0c7c5c); } .mode.pz { background: linear-gradient(160deg, #a64dff, #5b21b6); }
.mode .ic { position: absolute; top: 8px; left: 6px; line-height: 0; filter: drop-shadow(0 2px 0 #1b1433); transition: transform .2s; } .mode .ic svg { width: 54px; height: 40px; }
.mode:active .ic { transform: scale(1.12) rotate(-4deg); }
.mode::after { content: ''; position: absolute; inset: 0; background: radial-gradient(120% 60% at 80% 0%, #ffffff30, #fff0 60%); pointer-events: none; }
.mode .tag { position: absolute; top: 8px; right: 8px; padding: 2px 7px; border-radius: 8px; background: #0006; font: 800 10px var(--font); }
.mode.soon { filter: saturate(.55); }
.joinrow { display: flex; gap: 8px; }
.joinrow input { flex: 1; min-width: 0; height: 52px; border-radius: 16px; border: 2px solid #ffffff22; background: #0e1030; color: #fff; padding: 0 14px;
  font: 900 22px var(--font); letter-spacing: .3em; text-transform: uppercase; text-align: center; }
.joinrow input::placeholder { letter-spacing: .05em; font-size: 15px; font-weight: 700; color: var(--mut); }
.sec { display: flex; justify-content: space-between; align-items: baseline; font: 900 13px var(--font); letter-spacing: .1em; text-transform: uppercase; color: #c9c3ee; margin-top: 4px; }
.sec span { color: var(--mut); letter-spacing: 0; font-weight: 700; text-transform: none; }
.list { display: flex; flex-direction: column; gap: 8px; }
.fr { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: 18px; background: var(--panel); border: 1px solid #ffffff10; min-height: 58px; }
.fr .av { width: 34px; height: 34px; margin: 0 2px; }
.fr .t { flex: 1; min-width: 0; } .fr .t b { font: 800 15px var(--font); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fr .t small { font: 700 12px var(--font); color: var(--mut); } .fr .t small.on { color: var(--ok); }
.dot { position: absolute; right: -6px; bottom: -6px; width: 12px; height: 12px; border-radius: 50%; background: var(--ok); border: 2.5px solid var(--panel); z-index: 2; }
.empty { padding: 14px; border-radius: 18px; background: #ffffff08; border: 1px dashed #ffffff22; color: var(--mut); font: 700 13px var(--font); text-align: center; }
.card { padding: 14px; border-radius: 20px; background: var(--panel); border: 1px solid #ffffff14; }
.card.warn { background: linear-gradient(90deg, #3b2c86, #2a1f66); border-color: #b197fc44; display: flex; align-items: center; gap: 12px; }
.card.warn p { margin: 0; flex: 1; font: 700 13px/1.35 var(--font); color: #e5ddff; } .card.warn b { color: #fff; }

/* ---------- feuille (pseudo invité, aide) ---------- */
.sheet { position: fixed; inset: 0; z-index: 40; display: none; align-items: flex-end; background: #05061acc; backdrop-filter: blur(6px); }
.sheet.on { display: flex; }
.sheet .in { width: 100%; padding: 22px 18px calc(var(--sb) + 22px); border-radius: 28px 28px 0 0; background: linear-gradient(180deg, #1e1f52, #141633); border-top: 1px solid #ffffff22;
  display: flex; flex-direction: column; gap: 12px; animation: up .26s ease-out; }
@keyframes up { from { transform: translateY(60%); } to { transform: none; } }
.sheet h2 { margin: 0; font: 900 24px var(--font); } .sheet p { margin: 0; color: #cfd3e6; font: 600 14px/1.4 var(--font); }
.sheet input { height: 56px; border-radius: 16px; border: 2px solid #ffffff22; background: #0e1030; color: #fff; padding: 0 16px; font: 800 19px var(--font); }
.sheet .err { color: var(--bad); font: 800 13px var(--font); min-height: 16px; }
.or { text-align: center; color: var(--mut); font: 800 12px var(--font); letter-spacing: .12em; }

/* ---------- salon ---------- */
.lhead { display: flex; align-items: center; gap: 12px; }
.backb { width: 46px; height: 46px; border-radius: 14px; background: #ffffff12; border: 1px solid #ffffff20; display: grid; place-items: center; font: 900 20px var(--font); flex: none; }
.lhead .t { flex: 1; } .lhead .t small { display: block; font: 800 11px var(--font); color: #c9b8ff; letter-spacing: .14em; text-transform: uppercase; } .lhead .t b { font: 900 21px var(--font); }
.codebox { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 22px; background: linear-gradient(90deg, #3b2c86, #2a1f66); border: 1px solid #b197fc55; }
.codebox .code { flex: 1; } .codebox .code small { display: block; font: 800 11px var(--font); letter-spacing: .14em; color: #c9b8ff; text-transform: uppercase; }
.codebox .code b { font: 900 38px var(--font); letter-spacing: .22em; color: #fff3bf; text-shadow: 0 3px 0 var(--ink); }
.seats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.seat { position: relative; height: 112px; border-radius: 22px; background: #12142c; border: 2px solid var(--c); box-shadow: 0 5px 0 var(--ink), inset 0 0 24px color-mix(in srgb, var(--c) 25%, transparent);
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding: 10px 8px; gap: 2px; }
.seat .av { width: 40px; height: 40px; margin-bottom: 8px; }
.seat b { font: 900 14px var(--font); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.seat small { font: 800 11px var(--font); color: var(--mut); } .seat small.rdy { color: var(--ok); }
.seat .hostb { position: absolute; top: 6px; left: 8px; font-size: 14px; }
.seat .you { position: absolute; top: 6px; right: 8px; padding: 1px 7px; border-radius: 8px; background: var(--c); color: #fff; font: 900 10px var(--font); }
.seat.botseat { opacity: .75; border-style: dashed; }
.seat.emptyseat { border-style: dashed; opacity: .5; }
.seat.off { opacity: .45; }
.seg { display: flex; gap: 6px; padding: 4px; border-radius: 16px; background: #0e1030; border: 1px solid #ffffff14; }
.seg button { flex: 1; min-height: 42px; border: 0; border-radius: 12px; background: transparent; color: var(--mut); font: 800 14px var(--font); }
.seg button.on { background: #2f7bff; color: #fff; box-shadow: 0 3px 0 var(--ink); }
.seg button:disabled { opacity: .4; }
.opt { display: flex; flex-direction: column; gap: 6px; } .opt > small { font: 800 11px var(--font); letter-spacing: .12em; text-transform: uppercase; color: var(--mut); }
.lfoot { padding: 10px 16px calc(var(--sb) + 14px); display: flex; gap: 10px; background: linear-gradient(0deg, #0b0d12, #0b0d12ee 70%, #0b0d1200); }
.lfoot .btn { flex: 1; }

/* ---------- partie ---------- */
#game { background: radial-gradient(80% 50% at 50% 50%, #1e1a4a, #0b0d12 80%); touch-action: none; }
#game canvas { position: absolute; left: 0; top: 0; width: 100%; height: 100%; touch-action: none; }
.hud { position: absolute; left: 10px; right: 10px; top: calc(var(--st) + 8px); display: flex; gap: 6px; align-items: center; z-index: 5; pointer-events: none; }
.hud .clock { flex: 0 0 66px; order: 2; text-align: center; } .clock b { display: block; font: 900 26px var(--font); letter-spacing: -.02em; } .clock small { font: 800 9px var(--font); color: var(--mut); letter-spacing: .14em; }
.clock.hot b { color: var(--bad); animation: pulse .5s infinite alternate; }
@keyframes pulse { to { transform: scale(1.12); } }
.sc { flex: 1; min-width: 0; position: relative; height: 52px; border-radius: 16px; padding: 6px 6px 6px 38px; background: #12142c; border: 2px solid var(--c);
  box-shadow: 0 4px 0 var(--ink), inset 0 0 18px color-mix(in srgb, var(--c) 30%, transparent); transition: transform .15s; }
.sc .av { position: absolute; left: 6px; top: 12px; width: 25px; height: 25px; }
.sc b { display: block; font: 900 19px var(--font); line-height: 1; margin-top: 4px; }
.sc small { display: block; font: 800 10px var(--font); color: var(--c); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sc.me { background: color-mix(in srgb, var(--c) 30%, #12142c); }
.sc.bump { transform: scale(1.08); }
.sc .wifi { position: absolute; right: 4px; top: 3px; font-size: 10px; }
.sc.off { filter: grayscale(.8); }
.sc .lost { position: absolute; right: 4px; top: -16px; font: 900 15px var(--font); color: var(--bad); text-shadow: 0 2px 0 var(--ink); animation: fadeUp 1.4s forwards; }
@keyframes fadeUp { from { transform: translateY(6px); opacity: 1; } to { transform: translateY(-14px); opacity: 0; } }
.gbot { position: absolute; left: 14px; right: 14px; bottom: calc(var(--sb) + 10px); height: 88px; display: flex; align-items: center; justify-content: space-between; z-index: 5; pointer-events: none; }
.gbot > * { pointer-events: auto; }
.ammo { display: flex; flex-direction: column; gap: 4px; }
.ammo .row { display: flex; gap: 8px; }
.ammo i { width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; background: var(--c, #2f7bff); box-shadow: 0 4px 0 var(--ink); font-style: normal; font-size: 22px; color: #fff; transition: transform .15s; }
.ammo i.off { background: conic-gradient(var(--c) 0 var(--w, 0%), #ffffff14 0); box-shadow: inset 0 0 0 2px #ffffff22; color: #ffffff55; }
.ammo small { font: 800 10px var(--font); color: var(--mut); letter-spacing: .08em; }
.superb { position: relative; width: 80px; height: 80px; border-radius: 50%; border: 0; display: grid; place-items: center; background: conic-gradient(#fcc419 0 var(--g, 0%), #ffffff18 0);
  box-shadow: 0 6px 0 var(--ink), 0 0 30px #fcc41933; }
.superb div { width: 64px; height: 64px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #4d3db5, #241a6b); display: grid; place-items: center; text-align: center; font: 900 10px/1.2 var(--font); letter-spacing: .06em; color: #fff; }
.superb.full { animation: pulse .6s infinite alternate; }
.emo { width: 56px; height: 56px; border-radius: 18px; background: #ffffff12; border: 1px solid #ffffff22; display: grid; place-items: center; font-size: 26px; }
.emopick { position: absolute; right: 14px; bottom: calc(var(--sb) + 104px); display: none; gap: 8px; z-index: 8; padding: 8px; border-radius: 20px; background: #141633; border: 1px solid #ffffff22; }
.emopick.on { display: flex; } .emopick button { width: 48px; height: 48px; border-radius: 14px; border: 0; background: #ffffff10; font-size: 24px; }
.emopick button.quit { width: auto; padding: 0 12px; font: 800 13px var(--font); color: #ffb3c1; background: #ff4d6d22; } .emopick button.quit.sure { background: #ff4d6d; color: #fff; }
.banner { position: absolute; left: 26px; right: 26px; top: calc(var(--st) + 80px); min-height: 50px; border-radius: 18px; z-index: 6; display: flex; align-items: center; justify-content: center; gap: 10px;
  background: linear-gradient(90deg, #ff3cac, #a64dff, #2bd2ff); box-shadow: 0 5px 0 var(--ink), 0 10px 30px #a64dff88; transform: rotate(-2deg); font: 900 18px var(--font); letter-spacing: .06em;
  text-shadow: 0 2px 0 #1b143366; text-transform: uppercase; pointer-events: none; animation: drop .35s cubic-bezier(.3, 1.6, .5, 1); }
.banner small { font: 800 11px var(--font); padding: 3px 8px; background: #0005; border-radius: 8px; letter-spacing: .04em; text-transform: none; }
.banner.gold { background: linear-gradient(90deg, #fff1a8, #fcc419, #e8a200); color: #3d2c06; text-shadow: none; }
.banner.final { background: linear-gradient(90deg, #ff4d6d, #ff3cac, #fcc419); }
@keyframes drop { from { transform: translateY(-60px) rotate(-8deg); opacity: 0; } to { transform: rotate(-2deg); opacity: 1; } }
.count { position: absolute; inset: 0; display: grid; place-items: center; z-index: 9; pointer-events: none; }
.count b { font: 900 120px var(--font); color: #fff3bf; text-shadow: 0 8px 0 var(--ink), 0 0 40px #ff3cac; animation: pop .9s ease-out; }
.count b.go { font-size: 54px; text-align: center; line-height: 1; }
@keyframes pop { 0% { transform: scale(2.2); opacity: 0; } 30% { transform: scale(.9); opacity: 1; } 50% { transform: scale(1.05); } 100% { transform: scale(1); } }
.finalb { position: absolute; inset: 0; pointer-events: none; z-index: 4; box-shadow: inset 0 0 0 4px #ff3cac, inset 0 0 40px #ff3cacaa; animation: blink .5s infinite alternate; display: none; }
.finalb.on { display: block; }
@keyframes blink { to { box-shadow: inset 0 0 0 4px #fcc419, inset 0 0 50px #fcc419aa; } }
.netwarn { position: absolute; left: 50%; top: calc(var(--st) + 70px); transform: translateX(-50%); z-index: 9; padding: 6px 12px; border-radius: 12px; background: #ff4d6dcc; font: 800 12px var(--font); display: none; }
.netwarn.on { display: block; }

/* ---------- résultats ---------- */
.podium { display: flex; flex-direction: column; gap: 8px; }
.rk { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-radius: 20px; background: #12142c; border: 2px solid var(--c); box-shadow: 0 4px 0 var(--ink); animation: slideIn .4s backwards; }
.rk .n { font: 900 26px var(--font); width: 30px; text-align: center; color: var(--c); }
.rk .av { width: 38px; height: 38px; margin: 0 4px; }
.rk .t { flex: 1; min-width: 0; } .rk .t b { display: block; font: 900 16px var(--font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .rk .t small { font: 700 12px var(--font); color: var(--mut); }
.rk .s { font: 900 26px var(--font); }
.rk.me { background: color-mix(in srgb, var(--c) 28%, #12142c); }
.rk.first { transform-origin: center; animation: winner .6s backwards; }
@keyframes winner { 0% { transform: scale(.6); opacity: 0; } 70% { transform: scale(1.05); } 100% { transform: none; opacity: 1; } }
.gains { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.gain { padding: 12px 8px; border-radius: 18px; background: var(--panel); border: 1px solid #ffffff14; text-align: center; }
.gain b { display: block; font: 900 22px var(--font); } .gain small { font: 800 11px var(--font); color: var(--mut); letter-spacing: .06em; }
.gain.dim { opacity: .5; }
.title { text-align: center; font: 900 34px var(--font); color: #fff3bf; text-shadow: 0 4px 0 var(--ink), 0 0 24px #ff3cac88; margin: 6px 0 0; }
.subtitle { text-align: center; font: 800 13px var(--font); color: var(--mut); margin-top: -6px; }

/* ---------- toasts, invitation ---------- */
.toasts { position: fixed; left: 12px; right: 12px; top: calc(var(--st) + 10px); z-index: 60; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
.toast { align-self: center; padding: 10px 16px; border-radius: 16px; background: #141633f2; border: 1px solid #ffffff22; box-shadow: 0 8px 24px #000a; font: 800 14px var(--font); animation: up .25s ease-out; }
.toast.bad { border-color: #ff4d6d88; }
.invite { pointer-events: auto; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 20px; background: linear-gradient(90deg, #3b2c86, #2a1f66); border: 1px solid #b197fc66; box-shadow: 0 10px 30px #000c; animation: drop .35s; }
.invite .av { width: 34px; height: 34px; margin: 0 4px; } .invite .t { flex: 1; font: 700 13px var(--font); } .invite .t b { display: block; font: 900 15px var(--font); }
.spin { width: 44px; height: 44px; border-radius: 50%; border: 4px solid #ffffff22; border-top-color: #ff3cac; animation: rot 1s linear infinite; margin: 0 auto; }
@keyframes rot { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .screen.on, .banner, .count b, .rk, .clock.hot b { animation: none !important; } }

/* =====================================================================================
   Étape Contenu : barre d'onglets, Puzzle, éditeur, collection, Atelier, classements, coop
   ===================================================================================== */
.screen.tabbed .scroll { padding-bottom: calc(var(--sb) + 92px); }
.tabbar { position: fixed; left: 10px; right: 10px; bottom: calc(var(--sb) + 8px); z-index: 30; display: none; gap: 4px; padding: 6px; border-radius: 24px;
  background: #141633f0; border: 1px solid #ffffff1c; box-shadow: 0 10px 30px #000a; backdrop-filter: blur(10px); }
.tabbar.on { display: flex; }
.tabbar button { flex: 1; min-height: 56px; border: 0; border-radius: 18px; background: transparent; color: var(--mut); font: 800 11px var(--font); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.tabbar button span { font-size: 21px; filter: grayscale(.6); }
.tabbar button.on { background: #2f7bff26; color: #fff; } .tabbar button.on span { filter: none; }
.top .me b.h { font: 900 24px var(--font); }
.fr .t b em { font-style: normal; font: 700 11px var(--font); color: var(--mut); }
.card.ctr { text-align: center; font: 800 14px var(--font); }
.card.small { font: 700 12px/1.4 var(--font); color: var(--mut); }
.card.gold { background: linear-gradient(90deg, #5c4400, #3d2c06); border-color: #fcc41966; font: 700 13px var(--font); }
.card.howto { font: 600 14px/1.45 var(--font); color: #d7dbee; }
.card.lvup { font: 900 16px var(--font); color: #fff3bf; } .card.lvup small { color: #c9b8ff; font-weight: 700; }
.card.quest-done { border-color: #34d39955; } .card.quest-done small { display: block; color: var(--mut); font-weight: 700; margin-top: 2px; }
.card.resume { display: flex; align-items: center; gap: 12px; background: linear-gradient(90deg, #0c7c5c, #0d3a2e); border-color: #34d39955; }
.card.resume div { flex: 1; } .card.resume b { display: block; font: 900 15px var(--font); } .card.resume small { font: 700 12px var(--font); color: #a7f3d0; }
.lvrow { display: flex; justify-content: space-between; font: 800 13px var(--font); } .lvl.wide { width: 100%; height: 8px; margin-top: 8px; }
.weekb { display: flex; flex-direction: column; padding: 10px 14px; border-radius: 18px; background: linear-gradient(90deg, #ff3cac33, #a64dff33, #2bd2ff33); border: 1px solid #ffffff22; }
.weekb b { font: 900 14px var(--font); letter-spacing: .04em; } .weekb small { font: 700 12px var(--font); color: #d7dbee; } .weekb.sm { padding: 8px 12px; }
.daily { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 22px; border: 1px solid #fcc41955; background: linear-gradient(90deg, #3d2c06, #241a05); color: #fff; text-align: left; box-shadow: 0 5px 0 var(--ink); min-height: 64px; }
.daily:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.daily .dic { font-size: 28px; } .daily .t { flex: 1; min-width: 0; } .daily b { display: block; font: 900 16px var(--font); } .daily small { font: 700 12px var(--font); color: #ffe8a3; }
.daily .go { padding: 8px 12px; border-radius: 12px; background: var(--gold); color: #3d2c06; font: 900 13px var(--font); }
.daily.done { border-color: #34d39966; background: linear-gradient(90deg, #0c3d2e, #0b2620); } .daily.done .go { background: var(--ok); color: #06281c; }
.quests { display: flex; flex-direction: column; gap: 6px; }
.quest { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 16px; background: var(--panel); border: 1px solid #ffffff10; }
.quest .t { flex: 1; min-width: 0; } .quest b { font: 800 13px var(--font); display: block; } .quest > span { font: 900 14px var(--font); text-align: right; } .quest > span small { display: block; font: 700 11px var(--font); color: var(--mut); }
.quest.done { opacity: .65; } .quest.done > span { color: var(--ok); }
.qbar { height: 6px; border-radius: 3px; background: #ffffff14; margin-top: 6px; overflow: hidden; } .qbar i { display: block; height: 100%; background: linear-gradient(90deg, #34d399, #2bd2ff); }
.feed { display: flex; flex-direction: column; gap: 6px; }
.fi { display: flex; align-items: center; gap: 10px; padding: 8px 12px; border-radius: 16px; background: #ffffff08; }
.fi .av { width: 28px; height: 28px; margin: 0 3px; } .fi p { margin: 0; flex: 1; font: 600 13px/1.35 var(--font); color: #d7dbee; } .fi p b { color: #fff; } .fi small { display: block; color: var(--mut); font: 700 11px var(--font); }

/* ---------- salon : cartes, supers ---------- */
.maps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.mapc { position: relative; border: 2px solid #ffffff18; border-radius: 16px; background: #0e1030; color: #fff; padding: 6px 4px 8px; display: flex; flex-direction: column; align-items: center; gap: 4px; }
.mapc b { font: 800 11px var(--font); text-align: center; } .mapc.on { border-color: var(--gold); box-shadow: 0 0 18px #fcc41944; }
.mapc.lock { opacity: .45; } .mapc i { position: absolute; top: 6px; left: 6px; right: 6px; font: 800 10px var(--font); font-style: normal; background: #000a; border-radius: 8px; padding: 2px 4px; }
.mapc canvas { border-radius: 8px; }
.supers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.supers button { border: 2px solid #ffffff18; border-radius: 16px; background: #0e1030; color: #fff; padding: 8px 6px; display: flex; flex-direction: column; align-items: center; gap: 2px; min-height: 96px; }
.supers button span { font-size: 24px; } .supers button b { font: 900 13px var(--font); } .supers button small { font: 600 10px/1.25 var(--font); color: var(--mut); text-align: center; }
.supers button.on { border-color: var(--gold); background: #3d2c06; } .supers button.lock { opacity: .4; }
.seat .sup { position: absolute; bottom: 6px; right: 8px; font-size: 14px; }

/* ---------- partie : coop, surcouches, bannières ---------- */
.hud { flex-wrap: wrap; }
.coophud { display: flex; align-items: center; gap: 8px; width: 100%; }
.hearts { display: flex; flex-wrap: wrap; gap: 2px; width: 132px; }
.hearts i { width: 11px; height: 11px; display: block; background: no-repeat center/contain; }
.hearts i.f { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-8-5.3-8-11a4.5 4.5 0 0 1 8-2.8A4.5 4.5 0 0 1 20 10c0 5.7-8 11-8 11z' fill='%23ff4d6d' stroke='%231b1433' stroke-width='2'/%3E%3C/svg%3E"); }
.hearts i.h { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-8-5.3-8-11a4.5 4.5 0 0 1 8-2.8z' fill='%23ff4d6d'/%3E%3Cpath d='M12 21s-8-5.3-8-11a4.5 4.5 0 0 1 8-2.8A4.5 4.5 0 0 1 20 10c0 5.7-8 11-8 11z' fill='none' stroke='%231b1433' stroke-width='2'/%3E%3C/svg%3E"); }
.hearts i.e { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 21s-8-5.3-8-11a4.5 4.5 0 0 1 8-2.8A4.5 4.5 0 0 1 20 10c0 5.7-8 11-8 11z' fill='%23ffffff18' stroke='%23ffffff44' stroke-width='2'/%3E%3C/svg%3E"); }
.wavebox { flex: 1; min-width: 0; text-align: center; } .wavebox b { display: block; font: 900 19px var(--font); color: #fff3bf; text-shadow: 0 2px 0 var(--ink); } .wavebox small { font: 700 10px var(--font); color: var(--mut); }
.coophud .clock { flex: 0 0 62px; }
.team { display: flex; gap: 6px; width: 100%; justify-content: center; margin-top: 4px; }
.tm { position: relative; display: flex; align-items: center; gap: 4px; height: 26px; padding: 0 8px 0 30px; border-radius: 13px; background: #12142c; border: 2px solid var(--c); }
.tm .av { position: absolute; left: 4px; top: 2px; width: 18px; height: 18px; } .tm b { font: 900 13px var(--font); } .tm.me { background: color-mix(in srgb, var(--c) 30%, #12142c); }
.tm.off { filter: grayscale(.8); } .tm .wifi { font-size: 9px; } .tm.bump { transform: scale(1.1); }
.ammo .row.many i { width: 30px; height: 34px; font-size: 15px; border-radius: 10px; }
.superb div span { display: block; font-size: 18px; line-height: 1; }
.overlay { position: absolute; inset: 0; z-index: 12; display: none; align-items: center; justify-content: center; padding: 20px; background: #05061a99; }
.overlay.on { display: flex; } .overlay.vote { background: #05061a66; align-items: flex-end; padding-bottom: calc(var(--sb) + 120px); }
.cards { width: 100%; max-width: 400px; padding: 16px; border-radius: 24px; background: linear-gradient(180deg, #2a1f66, #141633); border: 1px solid #b197fc66; box-shadow: 0 20px 50px #000c; animation: up .25s ease-out; }
.cards h3 { margin: 0 0 12px; text-align: center; font: 900 16px var(--font); color: #fff3bf; }
.cards .row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; } .cards .col { display: flex; flex-direction: column; gap: 8px; }
.ecard { min-height: 130px; border: 2px solid #ffffff33; border-radius: 20px; background: linear-gradient(160deg, #ff3cac, #a64dff 55%, #2bd2ff); color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; box-shadow: 0 5px 0 var(--ink); }
.ecard span { font-size: 40px; } .ecard b { font: 900 14px var(--font); text-align: center; }
.cards .bar { height: 6px; border-radius: 3px; background: #ffffff22; margin-top: 12px; overflow: hidden; } .cards .bar i { display: block; height: 100%; background: var(--gold); animation: drain 4s linear forwards; }
@keyframes drain { from { width: 100%; } to { width: 0; } }
.bcard { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 0 14px; border: 2px solid #ffffff22; border-radius: 18px; background: #0e1030; color: #fff; text-align: left; }
.bcard span { font-size: 26px; } .bcard b { flex: 1; font: 900 15px var(--font); } .bcard i { font-style: normal; color: var(--gold); letter-spacing: 2px; }
.bcard.on { border-color: var(--ok); background: #0c3d2e; }
.banner.roul .ric { font-size: 28px; display: inline-block; min-width: 36px; text-align: center; }
.banner.roul.stamp { animation: stamp .3s cubic-bezier(.3, 1.8, .5, 1); }
@keyframes stamp { from { transform: rotate(-2deg) scale(1.4); } to { transform: rotate(-2deg) scale(1); } }
.banner.super { background: linear-gradient(90deg, #fcc419, #ff9f1c); color: #3d2c06; text-shadow: none; }
.banner.boss { background: linear-gradient(90deg, #ff4d6d, #7b2ff7); flex-direction: column; gap: 2px; padding: 8px 10px; }
.banner.wave { background: linear-gradient(90deg, #20c997, #2bd2ff); }
.banner.myst { background: linear-gradient(90deg, #c77dff, #7b2ff7); }

/* ---------- Puzzle ---------- */
.worlds { display: flex; flex-direction: column; gap: 8px; }
.world { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: 22px; border: 2px solid var(--c); background: linear-gradient(90deg, color-mix(in srgb, var(--c) 28%, #12142c), #12142c); color: #fff; text-align: left; box-shadow: 0 5px 0 var(--ink); min-height: 72px; }
.world:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--ink); }
.world .wic { font-size: 32px; } .world .t { flex: 1; min-width: 0; } .world small { font: 800 11px var(--font); color: #c9c3ee; letter-spacing: .08em; text-transform: uppercase; } .world b { display: block; font: 900 17px var(--font); }
.world .wst { font: 900 14px var(--font); white-space: nowrap; } .world.lock { opacity: .5; filter: saturate(.4); }
.lvgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.lvc { position: relative; min-height: 112px; border-radius: 20px; border: 2px solid var(--c); background: #12142c; color: #fff; padding: 10px; display: flex; flex-direction: column; justify-content: flex-end; text-align: left; box-shadow: 0 5px 0 var(--ink); }
.lvc .n { position: absolute; top: 8px; left: 10px; font: 900 24px var(--font); color: var(--c); } .lvc b { font: 900 14px var(--font); } .lvc small { font: 700 11px var(--font); color: var(--mut); }
.lvc .st { position: absolute; top: 10px; right: 10px; } .lvc .st i, .pzstars i { font-style: normal; color: #ffffff30; font-size: 16px; } .lvc .st i.on, .pzstars i.on { color: var(--gold); text-shadow: 0 0 8px #fcc41999; }
.lvc.done { background: color-mix(in srgb, var(--c) 18%, #12142c); } .lvc.lock { opacity: .4; }
#pz, #ed { background: radial-gradient(80% 50% at 50% 50%, #1e1a4a, #0b0d12 80%); touch-action: none; }
#pzBoard, #edBoard { position: absolute; left: 0; top: 0; width: 100%; height: 100%; touch-action: none; }
.pztop { position: absolute; left: 12px; right: 12px; top: calc(var(--st) + 10px); z-index: 5; display: flex; align-items: center; gap: 10px; }
.pztop .t { flex: 1; min-width: 0; } .pztop .t small { display: block; font: 800 11px var(--font); color: #c9b8ff; letter-spacing: .1em; text-transform: uppercase; } .pztop .t b { display: block; font: 900 19px var(--font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pzstars { text-align: right; } .pzstars i { font-size: 20px; } .pzstars small { display: block; font: 800 11px var(--font); color: var(--mut); }
.pzfoot { position: absolute; left: 12px; right: 12px; bottom: calc(var(--sb) + 10px); z-index: 5; display: flex; flex-direction: column; gap: 8px; }
.pzammo { display: flex; align-items: center; gap: 10px; } .pzammo .row { display: flex; gap: 5px; flex-wrap: wrap; }
.pzammo i { width: 30px; height: 30px; border-radius: 10px; display: grid; place-items: center; background: #2f7bff; box-shadow: 0 3px 0 var(--ink); font-style: normal; font-size: 15px; color: #fff; }
.pzammo i.off { background: #ffffff14; color: #ffffff44; box-shadow: none; } .pzammo small { font: 800 11px var(--font); color: var(--mut); letter-spacing: .06em; }
.pzbtns { display: flex; gap: 8px; } .pzbtns .btn.sm { min-height: 60px; min-width: 60px; font-size: 16px; } .pzbtns .pzgo { flex: 1; min-height: 64px; font-size: 24px; }
.btn.hot { box-shadow: 0 4px 0 #7a5600, 0 0 18px #fcc41988; border-color: #fcc419; }
.pzover { position: absolute; inset: 0; z-index: 9; display: none; align-items: flex-end; justify-content: center; background: #05061a88; padding: 16px 12px calc(var(--sb) + 16px); }
.pzover.on { display: flex; }
.pzcard { width: 100%; max-width: 420px; padding: 18px; border-radius: 26px; background: linear-gradient(180deg, #1e1f52, #141633); border: 1px solid #ffffff22; box-shadow: 0 20px 50px #000c; text-align: center; animation: up .26s ease-out; }
.pzcard h3 { margin: 0 0 4px; font: 900 26px var(--font); color: #fff3bf; } .pzcard p { margin: 4px 0; font: 700 14px/1.4 var(--font); color: #d7dbee; } .pzcard .tip { color: var(--gold); }
.pzcard .row { display: flex; gap: 10px; margin-top: 12px; } .pzcard .row .btn { flex: 1; }
.gainline { margin-top: 8px; padding: 8px 10px; border-radius: 12px; background: #ffffff0c; font: 800 13px var(--font); color: #a7f3d0; }
.bigstars { display: flex; justify-content: center; gap: 6px; margin-bottom: 6px; } .bigstars i { font-style: normal; font-size: 46px; color: #ffffff22; }
.bigstars i.on { color: var(--gold); text-shadow: 0 4px 0 #7a5600, 0 0 22px #fcc419aa; animation: pop .5s backwards; }

/* ---------- éditeur ---------- */
.seg.mini { padding: 3px; gap: 2px; } .seg.mini button { min-height: 34px; padding: 0 6px; font-size: 11px; }
.edtools { position: absolute; left: 0; right: 0; bottom: calc(var(--sb) + 112px); z-index: 5; padding: 0 10px; }
.tools { display: flex; gap: 6px; overflow-x: auto; padding: 4px 2px 6px; scrollbar-width: none; } .tools::-webkit-scrollbar { display: none; }
.tools button { flex: none; width: 62px; height: 58px; border-radius: 14px; border: 2px solid #ffffff18; background: #12142c; color: #fff; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; }
.tools button span { font-size: 20px; } .tools button small { font: 800 9px var(--font); color: var(--mut); } .tools button.on { border-color: var(--gold); background: #3d2c06; }
.cols { display: flex; align-items: center; gap: 8px; } .cols button { width: 34px; height: 34px; border-radius: 50%; border: 3px solid #ffffff33; background: var(--c); } .cols button.on { border-color: #fff; box-shadow: 0 0 12px var(--c); }
.cols small, .edtools .hint { font: 700 11px/1.3 var(--font); color: var(--mut); }
.edfoot { position: absolute; left: 10px; right: 10px; bottom: calc(var(--sb) + 8px); z-index: 5; display: flex; flex-direction: column; gap: 6px; }
.edopts { display: flex; gap: 6px; align-items: stretch; }
.stp { display: flex; flex-direction: column; align-items: center; padding: 4px 6px; border-radius: 12px; background: #12142c; border: 1px solid #ffffff18; }
.stp small { font: 800 9px var(--font); color: var(--mut); } .stp div { display: flex; align-items: center; gap: 4px; } .stp b { font: 900 15px var(--font); min-width: 20px; text-align: center; }
.stp button { width: 30px; height: 30px; border-radius: 9px; border: 0; background: #ffffff14; color: #fff; font: 900 16px var(--font); }
.edopts input { flex: 1; min-width: 0; border-radius: 12px; border: 2px solid #ffffff22; background: #0e1030; color: #fff; padding: 0 10px; font: 800 14px var(--font); }
.edbtns { display: flex; gap: 6px; } .edbtns .btn { flex: 1; min-height: 48px; } .edbtns .btn:first-child { flex: 0 0 52px; }

/* ---------- collection ---------- */
.ctabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 2px; scrollbar-width: none; } .ctabs::-webkit-scrollbar { display: none; }
.ctabs button { flex: none; min-height: 40px; padding: 0 14px; border-radius: 14px; border: 1px solid #ffffff1c; background: #ffffff0a; color: var(--mut); font: 800 13px var(--font); }
.ctabs button.on { background: #2f7bff; color: #fff; border-color: #2f7bff; box-shadow: 0 3px 0 var(--ink); }
.items { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.item { border: 2px solid #ffffff14; border-radius: 18px; background: #12142c; color: #fff; padding: 6px 4px 8px; display: flex; flex-direction: column; align-items: center; gap: 2px; min-height: 150px; }
.item b { font: 800 12px var(--font); text-align: center; } .item small { font: 800 11px var(--font); color: var(--gold); text-align: center; } .item small em { color: var(--mut); font-style: normal; font-weight: 700; }
.item.own small { color: var(--ok); } .item.on { border-color: var(--ok); background: #0c3d2e; box-shadow: 0 0 16px #34d39933; }
.titles { display: flex; flex-direction: column; gap: 6px; }
.titlec { position: relative; display: flex; flex-direction: column; text-align: left; padding: 10px 14px; border-radius: 16px; border: 2px solid #ffffff14; background: #12142c; color: #fff; }
.titlec b { font: 900 15px var(--font); } .titlec small { font: 700 12px var(--font); color: var(--mut); } .titlec i { position: absolute; right: 12px; top: 12px; font-style: normal; font: 800 12px var(--font); color: var(--ok); }
.titlec.on { border-color: var(--ok); } .titlec.lock { opacity: .5; }

/* ---------- Atelier ---------- */
.card.atel { display: flex; align-items: center; gap: 12px; background: linear-gradient(90deg, #5b21b6, #2a1f66); border-color: #b197fc55; }
.card.atel div { flex: 1; } .card.atel b { display: block; font: 900 16px var(--font); } .card.atel small { font: 700 12px/1.35 var(--font); color: #e5ddff; }
.clv { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 18px; background: var(--panel); border: 1px solid #ffffff10; color: #fff; text-align: left; min-height: 60px; }
.clv .av { width: 30px; height: 30px; margin: 0 3px; } .clv .t { flex: 1; min-width: 0; } .clv b { display: block; font: 900 15px var(--font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .clv small { font: 700 11px var(--font); color: var(--mut); }
.clv .lk { text-align: right; color: var(--gold); font: 900 13px var(--font); } .clv .lk small { display: block; color: #ff8fc7; }
.clv .new { font-style: normal; font: 800 10px var(--font); padding: 2px 6px; border-radius: 8px; background: #2f7bff; color: #fff; white-space: nowrap; }

/* ---------- classements ---------- */
.ranks { display: flex; flex-direction: column; gap: 6px; }
.rrow { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 18px; background: var(--panel); border: 1px solid #ffffff10; }
.rrow .n { width: 26px; font: 900 20px var(--font); color: var(--mut); text-align: center; } .rrow:nth-child(1) .n { color: var(--gold); } .rrow:nth-child(2) .n { color: #dee2e6; } .rrow:nth-child(3) .n { color: #e8a87c; }
.rrow .av { width: 32px; height: 32px; margin: 0 3px; } .rrow .t { flex: 1; min-width: 0; } .rrow b { display: block; font: 900 15px var(--font); } .rrow small { font: 700 11px var(--font); color: var(--mut); }
.rrow .v { font: 900 18px var(--font); text-align: right; } .rrow .v small { display: block; }
.rrow.me { border-color: #2f7bff; background: #1a2a5c; }

/* ---------- résultats coop ---------- */
.roles { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.role { padding: 10px; border-radius: 18px; background: var(--panel); border: 1px solid #ffffff14; display: flex; flex-direction: column; align-items: center; text-align: center; }
.role span { font-size: 24px; } .role b { font: 900 14px var(--font); color: #fff3bf; } .role small { font: 800 13px var(--font); } .role i { font-style: normal; font: 600 10px var(--font); color: var(--mut); }
.role.me { border-color: var(--gold); background: #3d2c06; }
.unl { display: flex; flex-direction: column; gap: 4px; max-height: 50vh; overflow-y: auto; } .unl div { display: flex; gap: 10px; font: 700 13px var(--font); color: var(--mut); } .unl div b { width: 26px; color: #fff; } .unl div.ok { color: var(--ok); }
.sheet .maps { margin: 4px 0; }

/* ---------- étape Graphismes : accueil vivant, icônes, réglages ---------- */
.hero { background: radial-gradient(90% 80% at 50% 10%, #3a2a8a 0%, #1e1f52 45%, #120f33 100%); box-shadow: 0 10px 30px #0008, inset 0 1px 0 #ffffff22; }
.hero::before { content: ''; position: absolute; inset: -40%; background: conic-gradient(from 0deg, #ff3cac22, #2bd2ff22, #a64dff22, #fcc41922, #ff3cac22); animation: rot 18s linear infinite; filter: blur(30px); }
.logo h1 { animation: logoBob 3.2s ease-in-out infinite; }
@keyframes logoBob { 0%, 100% { transform: rotate(-3deg) translateY(0); } 50% { transform: rotate(-2deg) translateY(-3px) scale(1.02); } }
.heroMe { position: absolute; left: 22px; bottom: 26px; width: 46px; height: 46px; pointer-events: none; animation: meHop 1.1s cubic-bezier(.3,.7,.4,1) infinite; transform-origin: 50% 100%; }
.heroMe > svg { position: absolute; width: 193%; height: 221%; left: -46.4%; top: -89.3%; overflow: visible; }
@keyframes meHop { 0%, 100% { transform: translateY(0) scale(1.08, .92); } 12% { transform: translateY(0) scale(.94, 1.06); } 45% { transform: translateY(-14px) scale(.98, 1.02); } 80% { transform: translateY(0) scale(1.04, .96); } }
.pill.ic { width: 40px; padding: 0; justify-content: center; color: #cfd3e6; }
.pill.ic { position: relative; } .pill.ic::after { content: ''; position: absolute; inset: -6px -2px; } /* zone tactile ≥ 44 px sans changer le dessin */
.pill.ic:active { transform: scale(.92); }
.tabbar button span { line-height: 0; filter: none !important; transition: transform .2s cubic-bezier(.3,1.6,.5,1); }
.tabbar button.on span { transform: translateY(-2px) scale(1.12); color: #9cc0ff; }
.optrow { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 10px 14px; border-radius: 18px; border: 1px solid #ffffff18; background: #0e103088; text-align: left; color: #fff; }
.optrow span { flex: 1; display: flex; flex-direction: column; gap: 2px; } .optrow b { font: 900 16px var(--font); } .optrow small { font: 600 12px/1.3 var(--font); color: var(--mut); }
.optrow .sw { flex: none; width: 52px; height: 30px; border-radius: 15px; background: #ffffff22; position: relative; transition: background .2s; }
.optrow .sw::after { content: ''; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%; background: #fff; box-shadow: 0 2px 0 #1b1433; transition: transform .22s cubic-bezier(.3,1.5,.5,1); }
.optrow.on .sw { background: var(--ok); } .optrow.on .sw::after { transform: translateX(22px); }
.lowfx .hero::before, .lowfx .logo h1, .lowfx .heroMe { animation: none !important; }
#game { background: #07080f; }
.podcv { display: block; width: 100%; height: 190px; flex: none; margin: -6px 0 -4px; }
/* revanche demandée par un autre joueur */
.btn.pulse { animation: rmPulse 0.9s ease-in-out infinite; } @keyframes rmPulse { 50% { box-shadow: 0 0 0 6px #ff3cac55, 0 0 24px #ff3cac; filter: brightness(1.25); } }
@media (prefers-reduced-motion: reduce) { .btn.pulse { animation: none; } }
/* téléphone en paysage : la grille deviendrait minuscule, on demande de le tourner (jeu pensé en portrait) */
@media (orientation: landscape) and (max-height: 500px) {
  body::after { content: '📱 Tourne ton téléphone\A pour jouer à Débandade !'; white-space: pre; position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; text-align: center;
    background: radial-gradient(circle at 50% 40%, #2a1f5c, #0b0d12 70%); color: #fff; font: 900 22px/1.5 var(--font, system-ui); }
}

/* écrans étroits (375 px) : bandeau des scores plus compact pour que les noms tiennent */
@media (max-width: 400px) {
  .hud { left: 6px; right: 6px; gap: 4px; } .hud .clock { flex-basis: 56px; } .clock b { font-size: 22px; }
  .sc { padding: 4px 4px 4px 5px; border-radius: 14px; } .sc .av { left: 4px; top: auto; bottom: 5px; width: 20px; height: 20px; }
  .sc small { font-size: 10px; letter-spacing: -.02em; } .sc b { font-size: 18px; margin: 5px 0 0 23px; }
}

/* ---------- tutoriel intégré (js/tuto.js) ---------- */
.tuto { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: calc(var(--st) + 16px) 16px calc(var(--sb) + 16px);
  background: #07081acc; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); opacity: 0; transition: opacity .25s; }
.tuto.on { opacity: 1; }
.tcard { width: min(100%, 360px); display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 18px 18px 16px; border-radius: 28px;
  background: linear-gradient(180deg, #24195c, #141236); border: 2px solid #b197fc55; box-shadow: 0 8px 0 var(--ink), 0 0 60px #7c5cff44; transform: translateY(30px) scale(.96); transition: transform .35s cubic-bezier(.2,1.4,.4,1); }
.tuto.on .tcard { transform: none; }
.tcv { touch-action: none; border-radius: 18px; }
.tcard h3 { margin: 4px 0 0; font: 900 24px var(--font); letter-spacing: -.01em; color: #fff3bf; text-shadow: 0 3px 0 var(--ink); }
.tcard p { margin: 0; text-align: center; font: 600 14.5px/1.4 var(--font); color: #e5dbff; min-height: 62px; } .tcard p b { color: #fff; }
.tdots { display: flex; gap: 6px; } .tdots i { width: 8px; height: 8px; border-radius: 4px; background: #ffffff30; transition: width .25s, background .25s; }
.tdots i.on { width: 24px; background: var(--gold, #fcc419); } .tdots i.ok { background: var(--ok); }
.tbtns { display: flex; gap: 10px; width: 100%; } .tbtns .btn.ok { flex: 1; } .tbtns .btn.dim { opacity: .45; filter: grayscale(.6); }
@media (max-height: 700px) { .tcard { gap: 6px; padding: 12px 14px; } .tcard p { font-size: 13.5px; min-height: 0; } }
.hero.disco { animation: disco 1.2s linear infinite; }
@keyframes disco { 0% { filter: hue-rotate(0); } 100% { filter: hue-rotate(360deg); } }
.howto .btn { margin-top: 10px; }
