:root {
  --bg: #15110e; --panel: #211a15; --panel2: #2b221b; --line: #3d3128;
  --ink: #f3e9dc; --mute: #a8978a; --accent: #f2a541; --accent2: #e4572e;
  --me: #4fc3f7; --opp: #ff6b6b; --good: #7bd389; --bad: #ff5d5d;
  --radius: 14px;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.45 Inter, system-ui, sans-serif; }
body { background: radial-gradient(1200px 600px at 70% -10%, #3a2414 0%, transparent 60%), var(--bg); min-height: 100vh; }
.hidden { display: none !important; }
button { font: inherit; cursor: pointer; border: 1px solid var(--line); background: var(--panel2); color: var(--ink); padding: 8px 14px; border-radius: 10px; transition: .15s; }
button:hover:not(:disabled) { border-color: var(--accent); }
button:disabled { opacity: .4; cursor: not-allowed; }
button.primary { background: var(--accent); color: #1b120a; border-color: var(--accent); font-weight: 800; }
button.danger { background: transparent; border-color: #6b2b22; color: #ff8a73; }
button.ghost { background: transparent; border: none; color: var(--mute); }
input, select { font: inherit; background: #120e0b; border: 1px solid var(--line); color: var(--ink); padding: 9px 12px; border-radius: 10px; }
input:focus, select:focus { outline: none; border-color: var(--accent); }
input[type=color] { padding: 3px; width: 56px; min-width: 56px; height: 38px; cursor: pointer; }
input[type=color]::-webkit-color-swatch-wrapper { padding: 0; }
input[type=color]::-webkit-color-swatch { border: none; border-radius: 6px; }

.logo { font-family: 'Bowlby One', Impact, sans-serif; font-weight: 400; letter-spacing: 2px; font-size: 44px; margin: 0; color: var(--ink); }
.logo span { color: var(--accent); margin-left: 6px; }
.logo.small { font-size: 22px; }

/* Connexion */
#login { display: grid; place-items: center; min-height: 100vh; padding: 16px; }
.login-card { width: min(420px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: 20px; padding: 32px; display: flex; flex-direction: column; gap: 12px; box-shadow: 0 30px 80px #0008; }
.login-card .tag { color: var(--mute); margin: 0 0 8px; }
.row { display: flex; gap: 10px; flex-wrap: wrap; }
.row > * { flex: 1; }
.hint { color: var(--mute); font-size: 13px; margin: 4px 0 0; }

/* Hub */
.top { display: flex; align-items: center; gap: 20px; padding: 14px 24px; border-bottom: 1px solid var(--line); background: #1a1410cc; position: sticky; top: 0; backdrop-filter: blur(6px); z-index: 5; flex-wrap: wrap; }
.top { padding-right: 150px; }
.top nav { display: flex; gap: 6px; flex: 1; flex-wrap: wrap; }
.top nav button { background: transparent; border-color: transparent; color: var(--mute); }
.top nav button.active { color: var(--ink); border-color: var(--line); background: var(--panel2); }
.me { display: flex; align-items: center; gap: 12px; }
.credits { background: #2c2012; border: 1px solid #5a3f17; color: var(--accent); padding: 5px 12px; border-radius: 99px; }
main { padding: 24px; max-width: 1240px; margin: 0 auto; }
h2 { font-family: 'Bowlby One', sans-serif; font-weight: 400; letter-spacing: 1px; margin: 0 0 14px; font-size: 22px; }
h2 small, h3 small { font-family: Inter; color: var(--mute); font-size: 13px; letter-spacing: 0; font-weight: 400; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.card.dead { opacity: .55; filter: grayscale(.8); }
.card-head { display: flex; align-items: center; gap: 12px; }
.avatar { width: 46px; height: 46px; flex: none; }
.card-head h4 { margin: 0; font-size: 17px; }
.card-head .sub { color: var(--mute); font-size: 13px; }
.price { margin-left: auto; color: var(--accent); font-weight: 800; white-space: nowrap; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chip { font-size: 12px; padding: 2px 9px; border-radius: 99px; background: #33281f; border: 1px solid var(--line); color: #e8d6c2; }
.chip.size { background: #2c3440; border-color: #3e4c5e; color: #cfe3ff; }
.chip.trait { background: #3a2a1a; border-color: #6a4a22; color: #ffd9a3; }
.chip[title] { cursor: help; }
.stats { display: grid; grid-template-columns: 92px 1fr 34px; gap: 4px 8px; align-items: center; font-size: 13px; }
.stats .lbl { color: var(--mute); }
.bar { height: 7px; background: #120e0b; border-radius: 99px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.bar.t > i { background: #8fb8de; }
.bar.peur > i { background: #c77dff; }
.stats .v { text-align: right; font-variant-numeric: tabular-nums; }
.stats .tr { grid-column: 1 / -1; display: grid; grid-template-columns: 92px 1fr 34px auto; gap: 8px; align-items: center; }
.stats .tr button { padding: 2px 8px; font-size: 12px; }
.sep { grid-column: 1 / -1; border-top: 1px dashed var(--line); margin: 4px 0; }
.record { font-size: 13px; color: var(--mute); }
.record b { color: var(--ink); }
.actions { display: flex; gap: 8px; flex-wrap: wrap; }
.empty { color: var(--mute); padding: 30px; text-align: center; border: 1px dashed var(--line); border-radius: var(--radius); }

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin-bottom: 18px; }
.panel .row { align-items: end; }
.panel label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--mute); }
.challenge { display: flex; align-items: center; gap: 14px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel2); flex-wrap: wrap; }
.challenge + .challenge { margin-top: 8px; }
.challenge .stake { font-family: 'Bowlby One'; color: var(--accent); font-size: 18px; min-width: 90px; }
.challenge .stake.zero { color: #8fb8de; font-size: 14px; }
.challenge .who { flex: 1; min-width: 200px; }
.challenge .who .sub { color: var(--mute); font-size: 13px; }
.rules { max-width: 820px; }
.rules h3 { color: var(--accent); margin-top: 22px; }
.rules table { border-collapse: collapse; width: 100%; font-size: 14px; }
.rules td, .rules th { border-bottom: 1px solid var(--line); padding: 6px 8px; text-align: left; }

/* Combat */
#fight { min-height: 100vh; padding: 16px; }
.fight-wrap { display: flex; gap: 16px; max-width: 1640px; margin: 0 auto; flex-wrap: wrap; }
.canvas-wrap { position: relative; flex: 1 1 520px; max-width: min(100%, 86vh); }
canvas { width: 100%; height: auto; display: block; border-radius: 18px; background: #0f0c0a; border: 1px solid var(--line); }
.timer { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); font-family: 'Bowlby One'; font-size: 20px; background: #000a; padding: 2px 14px; border-radius: 99px; }
.banner { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; font-family: 'Bowlby One'; font-size: 54px; color: var(--accent); text-shadow: 0 4px 0 #000; opacity: 0; text-transform: uppercase; text-align: center; transition: opacity .3s; }
.banner.show { opacity: 1; }
.fight-side { flex: 0 1 340px; display: flex; flex-direction: column; gap: 12px; min-width: 280px; }
.fcard { background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--me); border-radius: 12px; padding: 10px 12px; }
.fcard.opp { border-left-color: var(--opp); }
.fcard .n { font-weight: 800; display: flex; justify-content: space-between; gap: 6px; }
.fcard .n small { color: var(--mute); font-weight: 400; }
.fcard .meter { display: grid; grid-template-columns: 56px 1fr 52px; gap: 6px; align-items: center; font-size: 12px; margin-top: 5px; color: var(--mute); }
.fcard .meter .bar { height: 9px; }
.fcard .meter .hp > i { background: var(--good); transition: width .1s; }
.fcard .meter .mo > i { background: #c77dff; transition: width .1s; }
.fcard .st { font-size: 12px; color: var(--mute); margin-top: 4px; min-height: 16px; }
.orders { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.orders h3 { margin: 0 0 8px; font-size: 15px; }
.order-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.order-grid button { font-weight: 800; padding: 12px 8px; display: flex; align-items: center; gap: 8px; justify-content: center; }
kbd { background: #120e0b; border: 1px solid var(--line); border-radius: 5px; padding: 0 6px; font-size: 12px; color: var(--mute); }
.cd { height: 4px; background: #120e0b; border-radius: 99px; margin-top: 8px; overflow: hidden; }
.cd > div { height: 100%; width: 0; background: var(--accent); }
.mods { font-size: 12px; color: var(--mute); background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 8px 12px; }
.mods b { color: var(--ink); }
.log { flex: 1; min-height: 140px; max-height: 240px; overflow-y: auto; font-size: 12.5px; background: #120e0b; border: 1px solid var(--line); border-radius: 12px; padding: 8px 10px; }
.log div { padding: 1px 0; }
.log .me { color: var(--me); } .log .opp { color: var(--opp); } .log .sys { color: var(--accent); }

.modal { position: fixed; inset: 0; background: #000b; display: grid; place-items: center; z-index: 20; padding: 16px; }
.modal-card { background: var(--panel); border: 1px solid var(--line); border-radius: 20px; padding: 28px; width: min(460px, 100%); text-align: center; }
.modal-card h2 { font-size: 34px; }
.modal-card .win { color: var(--good); } .modal-card .lose { color: var(--bad); }
.modal-card .money { font-family: 'Bowlby One'; font-size: 26px; margin: 8px 0; }
.modal-card ul { text-align: left; color: var(--mute); font-size: 14px; }
.rip { color: #ff8a73; font-weight: 800; }

#toasts { position: fixed; bottom: 18px; right: 18px; display: flex; flex-direction: column; gap: 8px; z-index: 50; }
.toast { background: var(--panel2); border: 1px solid var(--line); border-left: 4px solid var(--accent); padding: 10px 14px; border-radius: 10px; max-width: 360px; box-shadow: 0 10px 30px #0008; animation: tin .2s; }
.toast.err { border-left-color: var(--bad); }
@keyframes tin { from { transform: translateY(10px); opacity: 0; } }

/* --- v2 : niveau, boutique, objets, équipement --- */
.top nav a { color: #ffd166; text-decoration: none; padding: 8px 14px; border-radius: 10px; border: 1px dashed #5a4a1d; }
.lvl { display: flex; align-items: center; gap: 8px; }
.lvl b { font-family: 'Bowlby One'; font-weight: 400; background: var(--accent); color: #1b120a; border-radius: 8px; padding: 1px 8px; font-size: 15px; }
.lvl b::before { content: 'NIV '; font-size: 10px; }
html[lang="en"] .lvl b::before { content: 'LVL '; }
.lvl .xp { width: 80px; height: 6px; background: #120e0b; border-radius: 99px; overflow: hidden; border: 1px solid var(--line); }
.lvl .xp i { display: block; height: 100%; background: linear-gradient(90deg, #f2a541, #ffd166); }
.lvl small { color: var(--mute); font-size: 11px; white-space: nowrap; }
.code { font-family: 'JetBrains Mono', ui-monospace, monospace; font-size: 12px; color: #ffd9a3; background: #2c2012; padding: 0 5px; border-radius: 4px; }
.status { margin-left: auto; font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 99px; white-space: nowrap; }
.status.sale { background: #23331f; color: var(--good); } .status.busy { background: #1f2a33; color: #8fb8de; } .status.hurt { background: #3a1c1c; color: #ff8a73; }
.hpline { display: grid; grid-template-columns: 30px 1fr auto; gap: 8px; align-items: center; font-size: 13px; }
.hpline .lbl { color: var(--mute); }
.bar.hp > i { background: var(--good); } .bar.hp.low > i { background: var(--bad); }
.hpline .bar { height: 9px; }
.tr.nobtn { grid-template-columns: 92px 1fr 52px !important; }
.chip.armor { background: #253038; border-color: #4a5d6b; color: #d6e6f2; }
button.tiny { padding: 3px 9px; font-size: 12px; }
button.ghost.tiny { padding: 0 4px; }
button.heal { border-color: #2f5b37; } button.serum { border-color: #5b2f58; }
.equip { display: flex; flex-direction: column; gap: 6px; border-top: 1px dashed var(--line); padding-top: 8px; font-size: 13px; }
.eqrow { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.eqrow .lbl { color: var(--mute); width: 56px; }
.eqrow .eqv small { color: var(--mute); }
.eqrow select { flex: 1; min-width: 0; font-size: 12px; padding: 5px 8px; }
.sizehead { font-family: 'Bowlby One'; font-weight: 400; letter-spacing: 1px; color: var(--accent); margin: 22px 0 10px; display: flex; gap: 10px; align-items: center; }
.lockmsg { color: #ff8a73; font-size: 13px; font-family: Inter; letter-spacing: 0; }
.shopcard.locked { opacity: .6; }
.meta { font-size: 12px; color: var(--mute); }
.empty.small { padding: 14px; }
.card .icon { font-size: 28px; width: 46px; text-align: center; }
.item .effect { font-size: 13px; color: #ffd9a3; }
.item .row { align-items: center; }
.item .owned { color: var(--mute); font-size: 13px; flex: 1; }
.item .row select, .item .row button { flex: 0 0 auto; }
.item.serum { border-color: #4a2f48; } .item.armure { border-color: #34414c; }
.towel { background: var(--panel); border: 1px solid #5a2a22; border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.towel label { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 13px; color: var(--mute); }
.towel .hint { margin: 0; font-size: 12px; }
button.big { padding: 12px; font-weight: 800; font-size: 15px; }
button.danger.armed { background: #8a2a1d; color: #fff; border-color: #ff8a73; }
.xpgain { color: #ffd166; font-weight: 800; }
.lvlup { font-family: 'Bowlby One'; color: var(--accent); font-size: 20px; }

.shopgrid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.cstats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; }
.cstats span { background: #120e0b; border: 1px solid var(--line); border-radius: 8px; padding: 3px 6px; display: flex; justify-content: space-between; align-items: baseline; gap: 4px; font-size: 13px; }
.cstats small { color: var(--mute); font-size: 11px; }
.cstats .base b { color: var(--accent); } .cstats .training b { color: #8fb8de; } .cstats .peur b { color: #c77dff; } .cstats .hpcell b { color: var(--good); }
.shopcard .row input { min-width: 0; }

/* --- v3 : défis à règles --- */
.toast.sticky { border-left-color: #ffd166; cursor: pointer; }
.pow { color: #ffd166; font-weight: 600; }
.regen { font-size: 12px; color: var(--good); min-height: 0; margin-top: -6px; }
.regen:empty { display: none; }
.pubgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px 14px; }
.pubgrid label, label.inline { display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: var(--mute); }
.pubgrid label.wide { grid-column: span 2; }
.pubgrid label small { color: #ffd166; }
.pubgrid select, .pubgrid input { width: 100%; }
.panel label.inline, label.inline { flex-direction: row; align-items: center; gap: 8px; }
.panel label.ban { flex-direction: row; color: var(--ink); }
.banrow { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-top: 12px; }
.banrow .lbl { color: var(--mute); font-size: 13px; width: 110px; }
.banrow .hint { margin: 0; font-size: 12px; }
label.ban { display: flex; align-items: center; gap: 6px; background: var(--panel2); border: 1px solid var(--line); padding: 4px 10px; border-radius: 99px; font-size: 13px; cursor: pointer; }
label.ban input { accent-color: #ff6b6b; }
label.ban.locked { opacity: .45; cursor: not-allowed; text-decoration: line-through; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; align-items: center; }
.filters #fSearch { flex: 1; min-width: 200px; }
.challenge { flex-direction: column; align-items: stretch; gap: 8px; }
.challenge.mine { border-color: #4a5d6b; background: #1d2228; }
.challenge.noelig { opacity: .7; }
.chtitle { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.chtitle b { font-size: 16px; }
.chtitle .status { margin-left: 0; }
.chtitle .host { color: var(--mute); font-size: 13px; }
.chtitle .when { color: var(--mute); font-size: 12px; margin-left: auto; }
.chbody { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.challenge .stake { display: flex; flex-direction: column; }
.challenge .stake small { font-family: Inter; font-size: 11px; color: var(--mute); }
.chact { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.chact select { max-width: 280px; }
.chips.rules { margin-top: 6px; }
#arenaLive:not(:empty) { margin-bottom: 26px; }
#arenaList h2 { margin-top: 26px; }
.chip.rule { background: #1f2a33; border-color: #34414c; color: #cfe3ff; }
.chip.rule.lethal { background: #3a1c1c; border-color: #6b2b22; color: #ff8a73; }
.chip.rule.safe { background: #1f3322; border-color: #2f5b37; color: var(--good); }
.formula { background: #120e0b; border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; }
.rules-list { color: var(--ink); }

/* --- v4 : invitations, spectateurs, paris --- */
.toast.invite { border-left-color: var(--accent); max-width: 380px; display: flex; flex-direction: column; gap: 6px; box-shadow: 0 10px 40px #000c, 0 0 0 1px #f2a54155; }
.toast.invite .clock { font-family: 'JetBrains Mono', monospace; color: #ffd166; font-weight: 600; }
.toast.invite .row { gap: 8px; }
.toast.invite .row > * { flex: 0 0 auto; }
.phasebox { background: #2c2012; border: 1px solid #5a3f17; border-radius: 12px; padding: 12px; display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center; }
.phasebox .big { font-family: 'Bowlby One'; font-size: 34px; color: var(--accent); line-height: 1.2; }
.phasebox small { color: var(--mute); font-size: 12px; }
.bets { background: var(--panel); border: 1px solid #4a2f48; border-radius: 12px; padding: 10px 12px; display: flex; flex-direction: column; gap: 8px; }
.bets h3 { margin: 0; font-size: 15px; }
.bets h3 small { color: #ffd166; }
.betform { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.betform input { width: 90px; }
.betform span { color: var(--mute); font-size: 13px; }
.betform button { flex: 1; font-weight: 800; }
.betform .side0 { border-color: #4fc3f7; color: #9fdcfa; } .betform .side1 { border-color: #ff6b6b; color: #ffa3a3; }
.betlist { display: flex; flex-direction: column; gap: 6px; max-height: 260px; overflow-y: auto; }
.bet { display: flex; justify-content: space-between; align-items: center; gap: 8px; background: var(--panel2); border: 1px solid var(--line); border-radius: 10px; padding: 7px 10px; font-size: 13px; }
.bet.mine { border-color: #ffd16677; }
.bet.is-held { opacity: .8; }
.bet .held { color: var(--good); font-size: 12px; white-space: nowrap; }
.bet .hint { margin: 2px 0 0; font-size: 11px; }
.dog.side0 { color: #4fc3f7; font-weight: 700; } .dog.side1 { color: #ff6b6b; font-weight: 700; }
button.leave { align-self: flex-start; }
.fight-foot { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.fight-foot button.leave { align-self: auto; }
.challenge.live { border-color: #5a3f17; }
.challenge.live.phase-live { border-color: #6b2b22; }
.challenge .phase { font-size: 12px; font-weight: 800; padding: 2px 9px; border-radius: 99px; background: #2c2012; color: #ffd166; font-family: 'JetBrains Mono', monospace; }
.challenge.phase-live .phase { background: #3a1c1c; color: #ff8a73; }
.versus { display: flex; align-items: center; gap: 12px; flex: 1; flex-wrap: wrap; }
.vdog { display: flex; align-items: center; gap: 8px; }
.vs { font-family: 'Bowlby One'; color: var(--mute); }
.mods hr { border: none; border-top: 1px dashed var(--line); margin: 6px 0; }

/* --- v5 : tags négatifs, entraînement --- */
.chip.trait.neg { background: #3a1c22; border-color: #6b2b3a; color: #ffa3b5; }
.negtxt { color: #ffa3b5; }
.status.train { background: #2a2140; color: #c9b3ff; }
.session { display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; font-size: 12px; background: #1e1830; border: 1px solid #3d3160; border-radius: 10px; padding: 6px 10px; color: #d8ccff; }
.session .bar { grid-column: 1 / -1; height: 5px; }
.bar.sess > i { background: #a88bff; }

/* --- v6 : espèces, photos --- */
.avatar.photo { width: 46px; height: 46px; border-radius: 50%; object-fit: cover; border: 2px solid var(--line); }
.photobox { position: relative; flex: none; }
.photobtn { position: absolute; right: -6px; bottom: -6px; width: 22px; height: 22px; border-radius: 50%; background: var(--panel2); border: 1px solid var(--line); display: grid; place-items: center; font-size: 11px; cursor: pointer; }
.photobtn:hover { border-color: var(--accent); }
.chip.species { font-weight: 700; }
.chip.sp-chien { background: #3a2c1c; border-color: #6b4f2a; color: #f2c38b; }
.chip.sp-chat { background: #2a2f3a; border-color: #46506b; color: #c8d4ff; }
.chip.sp-lapin { background: #3a2f36; border-color: #6b4f60; color: #ffc8e4; }
.chip.sp-coq { background: #3a1f1c; border-color: #7a2f26; color: #ffb39e; }
.spfilter { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
.spfilter button.active { border-color: var(--accent); background: #2c2012; }
.spfilter small { color: var(--mute); }
.fcard .n { align-items: center; }
.fphoto { width: 34px; height: 34px; border-radius: 50%; object-fit: cover; border: 2px solid var(--line); margin-right: 8px; }

/* --- v7 : coins de l'arène, décompte central, mêlée --- */
.canvas-wrap { align-self: flex-start; }
#corners { position: absolute; inset: 0; pointer-events: none; }
.corner { position: absolute; width: 27%; min-width: 150px; max-width: 220px; background: #120e0bdd; border: 1px solid var(--line); border-left: 4px solid var(--team); border-radius: 12px; padding: 7px 9px; font-size: 11.5px; display: flex; flex-direction: column; gap: 4px; backdrop-filter: blur(3px); }
.corner.tl { top: 10px; left: 10px; } .corner.tr { top: 10px; right: 10px; }
.corner.bl { bottom: 10px; left: 10px; } .corner.br { bottom: 10px; right: 10px; }
.corner.tr, .corner.br { border-left: 1px solid var(--line); border-right: 4px solid var(--team); }
.corner.mine { box-shadow: 0 0 0 2px var(--team); }
.corner.out { opacity: .55; filter: grayscale(.7); }
.corner .ch { display: flex; align-items: center; gap: 7px; }
.corner .ch img, .corner .ch .avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex: none; border: 2px solid var(--team); }
.corner .cn { display: flex; flex-direction: column; min-width: 0; }
.corner .cn b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.corner .cn small { color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cbar { position: relative; height: 8px; background: #000a; border-radius: 99px; overflow: hidden; }
.cbar.mo { height: 4px; }
.cbar i { display: block; height: 100%; background: var(--good); transition: width .1s; }
.cbar.mo i { background: #c77dff; }
.cbar span { position: absolute; right: 4px; top: -3px; font-size: 10px; color: #fff; text-shadow: 0 1px 2px #000; }
.cstat { color: #d8c8b8; }
.cst { color: var(--mute); min-height: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.centerbox { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); text-align: center; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.centerbox .ctime { font-family: 'Bowlby One', sans-serif; font-size: 64px; line-height: 1; color: var(--accent); text-shadow: 0 4px 0 #000, 0 0 30px #000; }
.centerbox .ctime.wait { font-size: 40px; }
.centerbox .csub { background: #000b; padding: 4px 12px; border-radius: 99px; font-size: 13px; max-width: 320px; }
.centerbox .launch { pointer-events: auto; background: #d62828; color: #fff; border: 2px solid #ff8a73; font-weight: 800; font-size: 16px; padding: 12px 22px; border-radius: 99px; letter-spacing: .5px; box-shadow: 0 0 0 0 #d6282899; animation: breathe 1.8s ease-in-out infinite; }
@keyframes breathe { 0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 #d6282866; } 50% { transform: scale(1.07); box-shadow: 0 0 22px 6px #d6282855; } }
.betform button { border-color: var(--team); }
.challenge .slots { font-size: 12px; color: #ffd166; font-weight: 700; }
.vdog.empty .avatar { opacity: .25; }

@media (max-width: 600px) {
  main { padding: 16px; }
  .logo { font-size: 34px; }
  #langSwitch { top: 10px; right: 10px; }
}
/* onglets en liste déroulante (mobile) */
.tabselect { display: none; }
@media (max-width: 760px), (orientation: landscape) and (max-height: 520px) {
  #hub .top { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 6px 8px; padding: 8px 10px; padding-right: 118px; }
  #hub .top nav { display: none; }
  #hub .top .logo.small { font-size: 13px; letter-spacing: .06em; margin: 0; white-space: nowrap; }
  .tabselect { display: block; width: 100%; min-width: 0; max-width: 220px; padding: 6px 8px; font-size: 14px; font-weight: 700; border-radius: 10px; }
  #hub .top .me { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; font-size: 13px; margin-right: -108px; flex-wrap: nowrap; }
  #hub .top .me .lvl small { display: none; }
  #hub .top .me .lvl .xp { width: 60px; }
  #hub .top .me .credits { margin-left: auto; padding: 4px 10px; }
  #hub .top .me #btnLogout { padding: 4px 8px; }
}

/* sélecteur de langue (toutes les pages) */
#langSwitch { position: fixed; top: 8px; right: 8px; z-index: 300; display: flex; gap: 2px; padding: 3px; border-radius: 999px; background: #0009; backdrop-filter: blur(6px); border: 1px solid #fff2; }
#langSwitch button { all: unset; cursor: pointer; font: 800 11px/1 Inter, sans-serif; letter-spacing: .04em; color: #fffa; padding: 6px 8px; border-radius: 999px; }
#langSwitch button:hover { color: #fff; }
#langSwitch button.on { background: var(--accent, #ffb400); color: #111; }

/* son en combat : bouton couper/rétablir + barre de volume toujours visible à droite */
.soundctl { display: inline-flex; align-items: center; gap: 10px; }
.soundctl #btnSound { font-size: 18px; padding: 6px 12px; min-width: 46px; }
.soundctl #btnSound.off { opacity: .6; }
.soundctl #volRange { width: 140px; accent-color: var(--accent, #f2a541); }
.soundctl #volRange.muted { opacity: .45; }
.soundctl #volVal { font-size: 12px; min-width: 48px; color: var(--mute, #a99); }
.launch.ready { background: #2f8f4e; border-color: #2f8f4e; animation: none; font-size: 15px; }

/* chat du combat (à gauche de l'arène) */
.fight-chat { flex: 0 1 260px; min-width: 220px; display: flex; flex-direction: column; gap: 8px; background: var(--panel, #241c16); border: 1px solid var(--line, #3a2e24); border-radius: 14px; padding: 12px; height: min(86vh, 760px); align-self: flex-start; }
.fight-chat h3 { margin: 0; font-size: 15px; }
.chatlist { flex: 1; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; font-size: 13px; line-height: 1.35; padding-right: 4px; word-wrap: break-word; overflow-wrap: anywhere; }
.chatlist .cm b { font-weight: 800; margin-right: 4px; }
.chatlist .cm.spect b { color: #9a9a9a; }
.chatlist .cm time { color: #776; font-size: 10px; margin-right: 4px; }
.chatlist .empty { color: var(--mute, #a99); font-size: 12px; }
.chatform { display: flex; gap: 6px; }
.chatform input { flex: 1; min-width: 0; }
.chatform button { padding: 8px 10px; }
@media (max-width: 1100px) { .fight-chat { order: 3; flex: 1 1 100%; height: 280px; } }

/* espèces ajoutées */
.chip.sp-singe { background: #33291c; border-color: #6e5a35; color: #f0d29a; }
.chip.sp-serpent { background: #1e3322; border-color: #3f6b46; color: #b6f0b0; }

/* tournois */
.tournament { background: var(--panel, #241c16); border: 1px solid var(--line, #3a2e24); border-radius: 16px; padding: 14px 16px; margin-bottom: 14px; }
.tournament.status-open { border-color: #f2a54166; box-shadow: 0 0 0 1px #f2a54122 inset; }
.tournament.status-running { border-color: #7bd38966; }
.tournament .thead { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.tournament .thead h3 { margin: 0; font-size: 18px; }
.tournament .tstatus { font-size: 12px; padding: 3px 10px; border-radius: 99px; background: #0006; color: var(--accent, #f2a541); }
.tournament .tbody { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 10px; }
.tournament .treward { display: flex; gap: 12px; align-items: center; flex: 0 1 340px; background: #0003; border-radius: 12px; padding: 10px 12px; }
.tournament .treward .avatar { width: 64px; height: 64px; }
.tournament .tprize { font-family: 'Bowlby One', sans-serif; color: var(--good, #7bd389); font-size: 20px; margin-left: auto; }
.tournament .tinfo { flex: 1 1 360px; display: flex; flex-direction: column; gap: 8px; }
.tournament .entrants { display: flex; flex-wrap: wrap; gap: 6px; }
.tournament .entrant { font-size: 12px; padding: 3px 9px; border-radius: 99px; background: #0004; border: 1px solid var(--line, #3a2e24); }
.tournament .entrant.me { border-color: var(--accent, #f2a541); }
.tournament .tjoin select { max-width: 340px; }
.bracket { display: flex; gap: 14px; overflow-x: auto; margin-top: 12px; padding-bottom: 4px; }
.bracket .round { min-width: 190px; display: flex; flex-direction: column; gap: 8px; justify-content: space-around; }
.bracket h5 { margin: 0 0 2px; font-size: 12px; color: var(--mute, #a99); text-transform: uppercase; letter-spacing: .05em; }
.bracket .pair { background: #0004; border: 1px solid var(--line, #3a2e24); border-radius: 10px; padding: 6px 8px; display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.bracket .pair.live { border-color: #d62828; }
.bracket .pair .win { color: var(--good, #7bd389); font-weight: 700; }
.bracket .pair .lose { color: var(--mute, #a99); text-decoration: line-through; }
.bracket .pair .bye { color: var(--mute, #a99); font-style: italic; }
.bracket .pair button { align-self: flex-start; margin-top: 4px; }
details.tdone { margin: 6px 0 18px; }
details.tdone summary { cursor: pointer; color: var(--mute, #a99); margin-bottom: 10px; }
.mymatches .row button { flex: 0 1 auto; padding: 6px 12px; }
.confirmbox .modal-card h3 { font-size: 24px; margin: 0 0 8px; }
.confirmbox .modal-card p { font-size: 16px; margin: 0; }
.confirmbox { z-index: 60; }
/* paris : cagnotte par animal */
.pools { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 6px; margin: 6px 0; }
.pool { border: 1px solid var(--line); border-left: 4px solid var(--team, #888); border-radius: 10px; padding: 6px 8px; display: flex; flex-direction: column; gap: 2px; background: #0002; }
.pool .dog { font-size: 12px; color: var(--team, #fff); font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pool b { font-size: 15px; }
.pool small { color: var(--mute); font-size: 11px; }
/* ---------- panneau social (chat, joueurs, amis, chuchotements) ---------- */
.hubbody { display: flex; align-items: flex-start; }
.hubbody > main { flex: 1 1 auto; min-width: 0; }
.social { flex: 0 0 310px; width: 310px; position: sticky; top: calc(var(--toph, 72px) + 12px); height: calc(100vh - var(--toph, 72px) - 28px); margin: 16px 0 16px 16px; display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.stabs { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px; border-bottom: 1px solid var(--line); }
.stabs button { padding: 5px 9px; font-size: 12.5px; border-radius: 99px; background: #0003; border: 1px solid var(--line); display: inline-flex; align-items: center; gap: 4px; }
.stabs button.on { background: var(--accent); color: #1b130c; border-color: var(--accent); font-weight: 800; }
.stabs .badge { font-style: normal; background: #d62828; color: #fff; border-radius: 99px; padding: 0 6px; font-size: 11px; font-weight: 800; }
.stabs .wtab .x { margin-left: 2px; opacity: .6; font-weight: 800; padding: 0 2px; }
.stabs .wtab .x:hover { opacity: 1; }
.sbody { flex: 1 1 auto; overflow-y: auto; padding: 8px 10px; font-size: 13.5px; display: flex; flex-direction: column; gap: 4px; }
.sbody .cm { line-height: 1.35; word-wrap: break-word; }
.sbody .cm time { color: var(--mute); font-size: 11px; margin-right: 6px; }
.sbody .cm b.who { cursor: pointer; color: #8ec5ff; }
.sbody .cm b.who:hover { text-decoration: underline; }
.sbody .cm.mine b { color: var(--accent); }
.sbody .cm.sys { background: #f2a5411a; border-left: 3px solid var(--accent); padding: 5px 8px; border-radius: 8px; color: #f6d9a8; }
.sbody .whead { color: var(--mute); font-size: 12px; margin-bottom: 4px; }
.sbody h4 { margin: 10px 0 4px; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--accent); }
.srow { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.srow .grow { flex: 1 1 auto; }
.srow b.who { cursor: pointer; }
.srow b.who:hover { text-decoration: underline; }
.srow select { max-width: 150px; font-size: 12px; padding: 4px 6px; }
.srow input { font-size: 12px; padding: 5px 8px; }
.scard { border: 1px solid var(--line); border-radius: 10px; padding: 7px 8px; display: flex; flex-direction: column; gap: 6px; background: #0002; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: #666; display: inline-block; }
.dot.on { background: #4caf50; box-shadow: 0 0 6px #4caf50aa; }
.addf input { flex: 1 1 120px; }
.sinput { display: flex; gap: 6px; padding: 8px; border-top: 1px solid var(--line); }
.sinput input { flex: 1 1 auto; min-width: 0; }
@media (max-width: 1050px) {
  .hubbody { flex-direction: column-reverse; }
  .social { position: static; width: auto; flex: none; height: 380px; margin: 0 16px 16px; }
}
/* plus de 4 animaux (sandbox) : les fiches passent sous l'arène, en grille */
#corners.many { position: static; display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 6px; margin-top: 8px; }
#corners.many .corner { position: static; width: auto; min-width: 0; max-width: none; border-left: 4px solid var(--team); border-right: 1px solid var(--line); }
.winnername { font-size: 20px; margin: 6px 0 10px; color: var(--accent); }
.winnername b { color: #fff; font-size: 24px; }
/* formulaire sandbox */
.sandbox .sbnames { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px; margin: 8px 0; }
.sandbox .sbname { display: flex; gap: 6px; align-items: center; }
.sandbox .sbname input[type=text] { flex: 1 1 auto; min-width: 0; }
.sandbox .sbname input[type=color] { width: 36px; height: 32px; padding: 0; border: none; background: none; }
.sandbox .sbstats { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 6px; }
.sandbox .sbstats label { display: flex; flex-direction: column; font-size: 12px; color: var(--mute); gap: 3px; }
.sandbox fieldset { margin-top: 10px; }
.session [data-canceltrain] { grid-column: 1 / -1; justify-self: end; margin-top: 2px; }
/* bandeau défilant (jaune sur fond rouge) */
.ticker { background: #c1121f; color: #ffd60a; overflow: hidden; white-space: nowrap; font-weight: 800; font-size: 14px; letter-spacing: .02em; border-bottom: 2px solid #8d0e17; position: relative; z-index: 1; }
.ticker-track { display: inline-flex; animation: ticker 28s linear infinite; padding: 6px 0; }
.ticker-track span { padding-right: 120px; }
.ticker:hover .ticker-track { animation-play-state: paused; }
@keyframes ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .ticker-track { animation-duration: 80s; } }
#login .ticker { position: absolute; bottom: 0; left: 0; right: 0; border-bottom: 0; border-top: 2px solid #8d0e17; }
.resetzone { margin-top: 40px; padding-top: 16px; border-top: 1px dashed var(--line); text-align: right; }
.resetzone button { color: var(--bad, #ff7b7b); border-color: #6b2a2a; }
.soundctl #btnMusic { font-size: 16px; padding: 6px 10px; min-width: 44px; } .soundctl #btnMusic.off { opacity: .55; }

/* l'arène (canvas + chrono, bannière, compte à rebours) : les superpositions restent centrées sur le canvas même quand les fiches passent dessous */
.arena-box { position: relative; }

/* combat sur mobile : arène pleine largeur, fiches compactes côte à côte sous l'arène */
@media (max-width: 760px) {
  #fight { padding: 44px 8px 12px; }
  .fight-wrap { gap: 10px; }
  .canvas-wrap { flex: 1 1 100%; max-width: 100%; }
  canvas { border-radius: 12px; }
  .timer { top: 6px; font-size: 15px; padding: 1px 10px; }
  .banner { font-size: 34px; }
  .centerbox .ctime { font-size: 48px; }
  .centerbox .ctime.wait { font-size: 30px; }
  .centerbox .csub { font-size: 12px; max-width: 86%; }
  #corners, #corners.many { position: static; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px; margin-top: 6px; pointer-events: auto; }
  #corners .corner, #corners.many .corner { position: static; width: auto; min-width: 0; max-width: none; padding: 5px 7px; gap: 3px; font-size: 10.5px; border-radius: 10px; border-left: 4px solid var(--team); border-right: 1px solid var(--line); backdrop-filter: none; background: #120e0b; }
  .corner .ch { gap: 5px; }
  .corner .ch img, .corner .ch .avatar { width: 26px; height: 26px; border-width: 2px; }
  .corner .cn b { font-size: 12px; }
  .corner .cn small { font-size: 9.5px; }
  .cbar { height: 10px; }
  .cbar.mo { height: 3px; }
  .cbar span { top: 0; font-size: 9px; line-height: 10px; }
  .corner .cstat { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 10px; }
  .corner .cst { min-height: 12px; font-size: 10px; }
  .fight-side { flex: 1 1 100%; min-width: 0; gap: 8px; }
  .orders { padding: 8px 10px; }
  .orders h3 { font-size: 14px; margin-bottom: 6px; }
  .order-grid { gap: 6px; }
  .order-grid button { padding: 8px 6px; font-size: 14px; }
  .towel { padding: 8px 10px; gap: 6px; }
  .towel .big { padding: 8px; font-size: 15px; }
  .towel .hint { font-size: 11px; }
  .mods { font-size: 12px; }
  .log { min-height: 90px; max-height: 150px; font-size: 12px; }
  .soundctl #volRange { width: auto; flex: 1 1 auto; min-width: 80px; }
  .soundctl { display: flex; width: 100%; }
  .fight-chat { height: 240px; min-width: 0; }
}

/* combat sur mobile en paysage : arène à gauche (hauteur de l'écran) avec les fiches compactes dessous,
   commandes à droite (son en haut, ordres bien visibles) dans une colonne qui défile seule ; chat du combat en dessous */
@media (orientation: landscape) and (max-height: 520px) {
  body:has(#fight:not(.hidden)) #langSwitch { display: none; }
  #fight { padding: 6px 8px; min-height: 0; }
  .fight-wrap { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px; align-items: start; max-width: none; }
  .canvas-wrap { grid-column: 1; grid-row: 1; height: calc(100dvh - 12px); max-width: 58vw; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 4px; flex: none; }
  .arena-box { flex: 1 1 0; min-height: 0; aspect-ratio: 1 / 1; max-width: 100%; }
  .arena-box canvas { width: 100%; height: 100%; border-radius: 10px; }
  .timer { top: 4px; font-size: 13px; padding: 1px 8px; }
  .banner { font-size: 26px; }
  .centerbox { gap: 4px; }
  .centerbox .ctime { font-size: 32px; }
  .centerbox .ctime.wait { font-size: 24px; }
  .centerbox .csub { border-radius: 10px; font-size: 10px; line-height: 1.3; max-width: 86%; padding: 2px 8px; }
  .centerbox .launch { font-size: 13px; padding: 8px 14px; }
  #corners, #corners.many { position: static; flex: none; width: 100%; min-width: 260px; display: grid; grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); gap: 4px; margin: 0; pointer-events: auto; }
  #corners .corner, #corners.many .corner { position: static; width: auto; min-width: 0; max-width: none; padding: 3px 6px; gap: 2px; font-size: 10px; border-radius: 8px; border-left: 4px solid var(--team); border-right: 1px solid var(--line); backdrop-filter: none; background: #120e0b; }
  .corner .ch { gap: 5px; }
  .corner .ch img, .corner .ch .avatar { width: 22px; height: 22px; border-width: 2px; }
  .corner .cn b { font-size: 11px; }
  .corner .cn small { font-size: 9px; }
  .cbar { height: 9px; } .cbar.mo { height: 3px; }
  .cbar span { top: 0; font-size: 8.5px; line-height: 9px; }
  .corner .cstat { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 9.5px; }
  .corner .cst { display: none; }
  .fight-side { grid-column: 2; grid-row: 1; height: calc(100dvh - 12px); overflow-y: auto; min-width: 0; gap: 6px; flex: none; overscroll-behavior: contain; }
  .fight-foot { order: -1; gap: 4px 6px; flex-wrap: wrap; position: sticky; top: 0; z-index: 2; background: var(--bg, #17120e); padding-bottom: 4px; }
  .soundctl { display: flex; flex: 1 1 100%; gap: 6px; min-width: 0; }
  .soundctl #btnSound, .soundctl #btnMusic { font-size: 16px; padding: 4px 8px; min-width: 0; }
  .soundctl #volRange { width: auto; flex: 1 1 auto; min-width: 60px; }
  .soundctl #volVal { min-width: 36px; }
  .fight-foot button.leave, .fight-foot #btnSandboxStop { padding: 5px 8px; font-size: 12px; white-space: nowrap; }
  .orders { padding: 6px 8px; }
  .orders h3 { font-size: 13px; margin-bottom: 4px; }
  .order-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; }
  .order-grid button { padding: 9px 4px; font-size: 13px; gap: 5px; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .orders kbd, .towel kbd { display: none; }
  .towel { padding: 6px 8px; gap: 5px; }
  .towel .big { padding: 7px; font-size: 14px; }
  .towel .hint { display: none; }
  .mods { font-size: 11px; padding: 6px 10px; }
  .log { min-height: 70px; max-height: 120px; font-size: 11.5px; }
  .fight-chat { grid-column: 1 / -1; grid-row: 2; height: 220px; min-width: 0; }
}

/* fenêtres (fin de combat, confirmations) : jamais plus hautes que l'écran, défilement intérieur si besoin */
.modal-card { max-height: calc(100dvh - 32px); overflow-y: auto; overscroll-behavior: contain; }
@media (orientation: landscape) and (max-height: 520px) {
  .modal { padding: 8px; }
  .modal-card { max-height: calc(100dvh - 16px); padding: 12px 18px; width: min(560px, 100%); border-radius: 14px; }
  .modal-card h2 { font-size: 24px; margin: 0 0 2px; }
  .modal-card p { margin: 4px 0; }
  .modal-card .money { font-size: 20px; margin: 4px 0; }
  .modal-card ul { font-size: 12.5px; margin: 4px 0; columns: 2; column-gap: 18px; }
  .modal-card .winnername { font-size: 15px; margin: 2px 0 4px; }
  .modal-card .winnername b { font-size: 18px; }
  .modal-card .hint { font-size: 11.5px; }
  .modal-card button.primary { padding: 8px 18px; }
}
@media (max-height: 520px) and (orientation: portrait), (max-width: 760px) {
  .modal-card { padding: 18px 16px; }
  .modal-card h2 { font-size: 28px; }
}

/* tutoriel : anneau autour de l'élément montré + bulle (non bloquants) */
.tutobtn { width: 26px; height: 26px; padding: 0; border-radius: 50%; font-size: 13px; font-weight: 800; opacity: .55; line-height: 1; }
.tutobtn:hover { opacity: 1; }
#btnTutoRules { vertical-align: middle; margin-left: 8px; font-size: 12px; opacity: .7; }
.tuto-ring { position: fixed; z-index: 390; pointer-events: none; border: 3px solid var(--accent, #f2a541); border-radius: 14px; box-shadow: 0 0 0 4px #f2a54133, 0 0 24px 4px #f2a54166; transition: left .2s, top .2s, width .2s, height .2s; animation: tutoPulse 1.6s ease-in-out infinite; }
@keyframes tutoPulse { 50% { box-shadow: 0 0 0 7px #f2a54122, 0 0 30px 8px #f2a54155; } }
.tuto-ring.hidden, .tuto-bubble.hidden { display: none; }
.tuto-bubble { position: fixed; z-index: 400; width: min(340px, calc(100vw - 16px)); background: #2b2119; color: var(--ink, #f3e9dc); border: 2px solid var(--accent, #f2a541); border-radius: 16px; padding: 12px 14px 10px; box-shadow: 0 10px 40px #000c; font-size: 14px; line-height: 1.45; }
.tuto-bubble.center { left: 50% !important; top: 50% !important; transform: translate(-50%, -50%); }
.tuto-bubble h4 { margin: 0 0 6px; font-size: 16px; color: var(--accent, #f2a541); }
.tuto-bubble p { margin: 0 0 6px; }
.tuto-bubble ul { margin: 0 0 6px; padding-left: 18px; }
.tuto-count { float: right; font-size: 11px; color: var(--mute, #a99); }
.tuto-nav { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 8px; }
.tuto-quit { display: block; width: 100%; margin: 8px 0 0; padding: 6px; font-size: 12px; background: transparent; color: var(--mute, #a99); border: 1px solid var(--line, #3d3128); border-radius: 10px; cursor: pointer; }
.tuto-quit:hover { color: #fff; border-color: #fff5; }
/* téléphone : bulle en bas de l'écran */
.tuto-bubble.docked { left: 8px !important; right: 8px; top: auto !important; bottom: 8px; width: auto; max-height: 46vh; overflow-y: auto; transform: none; font-size: 13px; }
@media (orientation: landscape) and (max-height: 520px) {
  .tuto-bubble.docked { left: auto !important; right: 8px; width: min(330px, 44vw); max-height: calc(100dvh - 16px); font-size: 12.5px; padding: 10px 12px 8px; }
  .tuto-bubble.docked.dock-left { left: 8px !important; right: auto; }
  .tuto-bubble.docked h4 { font-size: 14px; }
}
