/* ===== arenarow.io — mise en page ; le thème visuel sobre est en fin de fichier ===== */
:root {
  --wood: #8a5a2b; --wood-l: #a86f3a; --wood-d: #5a3a1e; --bark: #2b1a10;
  --leather: #3b2a1e; --leather-l: #4e3a2a; --stitch: rgba(241, 227, 198, .35);
  --parch: #f1e3c6; --parch-d: #d9c39b; --ink: #2b1a10; --ink-l: #6b5236;
  --gold: #f2b134; --gold-d: #b07a1a; --green: #6cc04a; --red: #e5484d;
  --ft: 'Luckiest Guy', 'Impact', 'Arial Black', sans-serif;
  --fb: 'Nunito', 'Segoe UI', Arial, sans-serif;
  --Rouge: #ff5252; --Bleu: #40c4ff; --Vert: #69f0ae; --Jaune: #ffd740;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #1a2a1a; font-family: var(--fb); font-weight: 600; color: var(--parch); user-select: none; -webkit-user-select: none; touch-action: none; }
canvas#game { position: fixed; inset: 0; display: block; width: 100%; height: 100%; }
.hidden { display: none !important; }
button { font-family: var(--ft); cursor: pointer; border: none; }
input { font-family: var(--fb); font-weight: 700; }

/* ----- matières ----- */
.plank, .sign, .plank-title {
  background: linear-gradient(180deg, var(--wood-l) 0%, var(--wood) 45%, #7d4f24 100%);
  background-image: repeating-linear-gradient(90deg, rgba(0,0,0,.08) 0 2px, transparent 2px 11px), linear-gradient(180deg, var(--wood-l) 0%, var(--wood) 45%, #7d4f24 100%);
  border: 3px solid var(--bark); border-radius: 7px;
  box-shadow: inset 0 2px 0 rgba(255,255,255,.22), inset 0 -3px 0 rgba(0,0,0,.28), 0 4px 0 #1b0f08, 0 7px 14px rgba(0,0,0,.45);
  color: var(--parch); text-shadow: 0 2px 0 rgba(0,0,0,.5);
}
.leather {
  background: radial-gradient(circle at 25% 15%, var(--leather-l), var(--leather) 65%);
  background-image: repeating-linear-gradient(45deg, rgba(255,255,255,.025) 0 3px, transparent 3px 7px), radial-gradient(circle at 25% 15%, var(--leather-l), var(--leather) 65%);
  border: 3px solid #6b4a2f; border-radius: 12px; outline: 2px dashed var(--stitch); outline-offset: -9px;
  box-shadow: 0 6px 0 #1b0f08, 0 12px 24px rgba(0,0,0,.55), inset 0 0 40px rgba(0,0,0,.35);
}
.parch {
  background: linear-gradient(160deg, #f6ead2, var(--parch) 40%, #e6d3ad);
  border: 2px solid #b89b6a; border-radius: 4px; color: var(--ink);
  box-shadow: 0 3px 0 #a3875a, 0 6px 12px rgba(0,0,0,.45), inset 0 0 18px rgba(160,120,60,.25);
}
.parch b { color: var(--ink); }
.frame { background: var(--wood); border: 5px solid var(--bark); border-radius: 8px; padding: 4px; box-shadow: inset 0 0 0 3px var(--wood-l), 0 5px 0 #1b0f08, 0 10px 18px rgba(0,0,0,.5); }

/* ----- boutons « pancarte » ----- */
.sign { padding: 8px 16px; font-size: 17px; letter-spacing: .5px; transition: transform .08s, filter .08s; position: relative; }
.sign::before, .sign::after { content: ''; position: absolute; top: 5px; width: 6px; height: 6px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ddd, #555); box-shadow: 0 1px 1px rgba(0,0,0,.6); }
.sign::before { left: 6px; } .sign::after { right: 6px; }
.sign:hover { filter: brightness(1.12); transform: translateY(-1px) rotate(-.6deg); }
.sign:active { transform: translateY(3px); box-shadow: inset 0 2px 0 rgba(255,255,255,.2), 0 1px 0 #1b0f08; }
.sign:disabled { opacity: .55; cursor: default; filter: grayscale(.4); transform: none; }
.sign.big { font-size: 24px; padding: 12px 28px; background-image: repeating-linear-gradient(90deg, rgba(0,0,0,.08) 0 2px, transparent 2px 11px), linear-gradient(180deg, #8fd16d, #4f9a3a 55%, #3d7d2c); color: #fff; }
.sign.small { font-size: 14px; padding: 6px 12px; }
.sign.on { background-image: repeating-linear-gradient(90deg, rgba(0,0,0,.08) 0 2px, transparent 2px 11px), linear-gradient(180deg, #ffd766, var(--gold) 55%, var(--gold-d)); color: var(--ink); text-shadow: 0 1px 0 rgba(255,255,255,.4); }

/* ----- menu ----- */
.overlay { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; background: radial-gradient(ellipse at center, rgba(10,20,10,.55), rgba(5,10,6,.88)); z-index: 20; }
.board { position: relative; width: min(94vw, 640px); max-height: 96vh; overflow-y: auto; padding: 26px 30px 22px; text-align: center; border-radius: 14px;
  background: repeating-linear-gradient(180deg, rgba(0,0,0,.06) 0 2px, transparent 2px 14px), repeating-linear-gradient(90deg, rgba(0,0,0,.05) 0 1px, transparent 1px 90px), linear-gradient(180deg, #a06c3a, #8a5a2b 40%, #7a4d22);
  border: 5px solid var(--bark); box-shadow: inset 0 0 0 3px var(--wood-l), inset 0 0 60px rgba(0,0,0,.35), 0 10px 0 #1b0f08, 0 24px 50px rgba(0,0,0,.7); }
.rope { position: absolute; top: -120px; width: 6px; height: 128px; background: repeating-linear-gradient(180deg, #c9a46a 0 6px, #9a7a44 6px 12px); border-radius: 3px; box-shadow: 0 0 0 1px #5a3a1e; }
.rope-l { left: 60px; } .rope-r { right: 60px; }
.logo { margin: 0; font-family: var(--ft); font-size: 58px; line-height: 1; letter-spacing: 3px; color: var(--gold);
  text-shadow: 0 1px 0 #d99a2a, 0 2px 0 #c58a22, 0 3px 0 #b07a1a, 0 4px 0 #8a5e12, 0 5px 0 #5a3a1e, 0 8px 10px rgba(0,0,0,.6); -webkit-text-stroke: 1.5px var(--bark); }
.logo span { color: #7fe3f0; text-shadow: 0 1px 0 #4fb3c0, 0 2px 0 #3a9aa8, 0 3px 0 #2a7a86, 0 4px 0 #1e5a63, 0 5px 0 #5a3a1e, 0 8px 10px rgba(0,0,0,.6); }
.tagline { margin: 8px 0 14px; font-family: var(--ft); font-size: 16px; letter-spacing: 2px; color: var(--parch); opacity: .9; text-shadow: 0 2px 0 rgba(0,0,0,.5); }
.row { display: flex; gap: 10px; align-items: stretch; }
.joinrow input { flex: 1; padding: 10px 14px; font-size: 20px; border-radius: 6px; border: 3px solid var(--bark); background: var(--parch); color: var(--ink); outline: none; box-shadow: inset 0 3px 6px rgba(0,0,0,.25); }
.joinrow input::placeholder { color: #9a8160; }
.skins { display: flex; gap: 8px; justify-content: center; margin: 14px 0 10px; flex-wrap: wrap; }
.skin { width: 36px; height: 36px; border-radius: 50%; border: 3px solid var(--bark); cursor: pointer; box-shadow: inset 0 -4px 0 rgba(0,0,0,.25), 0 3px 0 #1b0f08; transition: transform .1s; }
.skin:hover { transform: scale(1.1); }
.skin.sel { border-color: var(--gold); box-shadow: 0 0 0 3px var(--bark), 0 0 14px var(--gold); transform: scale(1.15); }
.modes { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 10px; margin: 6px 0 10px; }
.mode { position: relative; text-align: left; padding: 10px 12px 10px; cursor: pointer; transition: transform .1s; background: linear-gradient(160deg, #f6ead2, var(--parch) 40%, #e6d3ad); border: 2px solid #b89b6a; border-radius: 4px; color: var(--ink); box-shadow: 0 3px 0 #a3875a, 0 6px 12px rgba(0,0,0,.4); }
.mode:nth-child(odd) { transform: rotate(-.8deg); } .mode:nth-child(even) { transform: rotate(.7deg); }
.mode:hover { transform: rotate(0) scale(1.03); }
.mode::before { content: ''; position: absolute; top: -6px; left: 50%; width: 12px; height: 12px; margin-left: -6px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ff8a80, #b71c1c); box-shadow: 0 2px 3px rgba(0,0,0,.6); }
.mode.sel { border-color: var(--gold-d); box-shadow: 0 0 0 3px var(--gold), 0 3px 0 #a3875a, 0 8px 16px rgba(0,0,0,.5); transform: rotate(0) scale(1.04); }
.mode .prev { display: block; width: 100%; height: 84px; border-radius: 4px; border: 2px solid #b89b6a; margin: 2px 0 6px; background: #4f8a3f; box-shadow: inset 0 0 0 1px rgba(255,255,255,.25); }
.mode b { font-family: var(--ft); font-size: 17px; letter-spacing: .5px; color: var(--ink); font-weight: normal; }
.mode small { display: block; color: var(--ink-l); font-size: 11.5px; margin-top: 3px; line-height: 1.3; }
.mode .cnt { float: right; font-size: 11px; color: #2e7d32; font-weight: 800; }
.privrow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 10px; }
.privrow input { width: 96px; padding: 6px 10px; font-size: 17px; letter-spacing: 3px; text-transform: uppercase; text-align: center; border-radius: 6px; border: 3px solid var(--bark); background: var(--parch); color: var(--ink); outline: none; font-family: var(--ft); }
.privrow input::placeholder { letter-spacing: 1px; color: #9a8160; }
#roomInfo { color: var(--gold); font-size: 13px; text-shadow: 0 1px 0 rgba(0,0,0,.6); display: flex; align-items: center; gap: 6px; }
#roomInfo code, .setroom code { background: rgba(0,0,0,.35); padding: 2px 8px; border-radius: 4px; letter-spacing: 3px; font-size: 15px; color: #fff; }
#roomInfo button, .setroom button { font-size: 11px; padding: 3px 8px; }
.setroom { display: flex; align-items: center; justify-content: center; gap: 8px; color: var(--parch); font-size: 13px; margin: -4px 0 10px; }
#hof { font-size: 12.5px; color: var(--parch); margin: 0 0 10px; min-height: 16px; text-shadow: 0 1px 0 rgba(0,0,0,.5); }
#hof b { color: var(--gold); } #hof span { margin-right: 10px; white-space: nowrap; }
.help { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 4px 10px; font-size: 12.5px; text-align: left; padding: 8px 12px; color: var(--ink); }
.help b { color: #8a4a12; font-family: var(--ft); font-weight: normal; letter-spacing: .5px; }
.tips { font-size: 12px; color: var(--parch); margin: 12px 0 0; line-height: 1.5; opacity: .9; text-shadow: 0 1px 0 rgba(0,0,0,.5); }

/* ----- écran de mort ----- */
.deathbox { width: min(92vw, 480px); padding: 26px 28px; text-align: center; }
.stamp { margin: 0 0 10px; font-family: var(--ft); font-size: 44px; color: #ff5a5a; letter-spacing: 2px; transform: rotate(-3deg); text-shadow: 0 3px 0 #7f1d1d, 0 6px 12px rgba(0,0,0,.6); }
.deathbox p { font-size: 15px; color: var(--parch); margin: 0 0 16px; }
.deathbox p b { color: var(--gold); }
.dstats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 12px 0 2px; }
.dstats div { background: rgba(0, 0, 0, .18); border: 1px solid rgba(0, 0, 0, .25); border-radius: 8px; padding: 7px 4px 5px; font-size: 11px; line-height: 1.25; color: var(--parch); }
.dstats b { display: block; font-size: 15px; color: var(--gold); margin-bottom: 1px; }
.dstats small { display: block; font-size: 10px; opacity: .75; min-height: 12px; }
@media (max-width: 520px) { .dstats { grid-template-columns: repeat(2, 1fr); } }
#specRow { display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 10px; font-family: var(--ft); font-size: 15px; }
#toMenu { margin-top: 10px; }

/* ----- HUD ----- */
#hud { position: fixed; inset: 0; pointer-events: none; z-index: 10; }
#hud > * { pointer-events: auto; }
#left { position: absolute; left: 14px; top: 12px; display: flex; flex-direction: column; gap: 6px; width: 210px; }
#stats { width: 180px; display: flex; flex-direction: column; gap: 5px; }
.bar { position: relative; height: 19px; margin-left: 12px; background: var(--bark); border: 2px solid var(--wood-d); border-radius: 12px; box-shadow: inset 0 3px 6px rgba(0,0,0,.6), 0 2px 0 #1b0f08; }
.bar .fill { position: absolute; left: 0; top: 0; bottom: 0; width: 100%; border-radius: 10px; transition: width .2s; box-shadow: inset 0 -5px 0 rgba(0,0,0,.25), inset 0 2px 0 rgba(255,255,255,.35); }
.bar span { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-family: var(--ft); font-size: 11.5px; letter-spacing: .5px; color: #fff; text-shadow: 0 2px 0 rgba(0,0,0,.6); }
.bar .bi { position: absolute; left: -14px; top: -4px; width: 24px; height: 24px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, var(--wood-l), var(--wood-d)); border: 2px solid var(--bark); display: flex; align-items: center; justify-content: center; font-style: normal; font-size: 12px; z-index: 1; box-shadow: 0 2px 0 #1b0f08; }
.bar.hp .fill { background: linear-gradient(180deg, #ff7b7b, #d32f2f); } .bar.hp .bi { color: #ff6b6b; }
.bar.food .fill { background: linear-gradient(180deg, #ffb74d, #e65100); }
.bar.cold .fill { background: linear-gradient(180deg, #90caf9, #1565c0); } .bar.cold .bi { color: #90caf9; }
.bar.heat .fill { background: linear-gradient(180deg, #ff8a65, #bf360c); }
.bar.poison .fill { background: linear-gradient(180deg, #aed581, #33691e); } .bar.poison .bi { color: #aed581; }
.bar.stamina .fill { background: linear-gradient(180deg, #fff176, #f9a825); } .bar.stamina .bi { color: #fff176; }
.bar.mana .fill { background: linear-gradient(180deg, #8ab4ff, #3d6bff); } .bar.mana .bi { color: #8ab4ff; }
.bar.fuel .fill { background: linear-gradient(180deg, #ffcc80, #ef6c00); } .bar.car .fill { background: linear-gradient(180deg, #b0bec5, #546e7a); } /* au volant (§ 7.13) */
.bar.xp { height: 15px; } .bar.xp .fill { background: linear-gradient(180deg, #d1a8ff, #6a1b9a); } .bar.xp span { font-size: 10px; } .bar.xp .bi { color: var(--gold); width: 22px; height: 22px; top: -4px; font-size: 11px; }
#inventory { display: flex; flex-direction: column; gap: 3px; }
.res { display: flex; align-items: center; gap: 5px; padding: 1px 9px 1px 3px; font-family: var(--ft); font-size: 12.5px; letter-spacing: .5px; width: max-content; background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); border: 2px solid #b89b6a; border-radius: 4px 14px 14px 4px; box-shadow: 0 2px 0 #a3875a, 0 4px 8px rgba(0,0,0,.4); }
.res i { width: 11px; height: 11px; border-radius: 3px; display: inline-block; } .res img { width: 17px; height: 17px; }
#topbar { position: absolute; top: 12px; left: 50%; transform: translateX(-50%); display: flex; gap: 10px; align-items: center; }
#topbar .plank { padding: 4px 11px; font-family: var(--ft); font-size: 13px; letter-spacing: .5px; }
#clock { color: var(--gold); }
#leaderboard { position: absolute; right: 14px; top: 14px; width: 165px; padding: 8px 10px 6px; font-size: 12px; transform: rotate(.6deg); }
.plank-title { display: inline-block; margin: -20px 0 5px; padding: 3px 12px; font-family: var(--ft); font-size: 14px; letter-spacing: 1px; font-weight: normal; transform: rotate(-1.5deg); }
#leaderboard ol { margin: 0; padding-left: 20px; color: var(--ink); } #leaderboard li { display: flex; justify-content: space-between; padding: 1px 0; } #leaderboard li.me { color: #1565c0; font-weight: 800; }
#leaderboard .tag { color: #8a4a12; font-size: 11px; }
#killfeed { position: absolute; right: 14px; top: 180px; width: 210px; display: flex; flex-direction: column; gap: 4px; align-items: flex-end; pointer-events: none; }
#killfeed div { background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); padding: 3px 10px; border: 2px solid #b89b6a; border-radius: 3px; font-size: 12px; box-shadow: 0 2px 0 #a3875a; transform: rotate(-.5deg); }
#killfeed .k { color: #1b5e20; font-weight: 800; } #killfeed .v { color: #b71c1c; font-weight: 800; }
.Rouge { color: var(--Rouge) !important; } .Bleu { color: var(--Bleu) !important; } .Vert { color: var(--Vert) !important; } .Jaune { color: var(--Jaune) !important; }
#killfeed .Rouge, #modeHud .pts .Rouge { color: #d32f2f !important; } #killfeed .Bleu { color: #0277bd !important; } #killfeed .Vert { color: #2e7d32 !important; } #killfeed .Jaune { color: #b07a1a !important; }
#killfeed .fk { margin-left: 4px; padding: 0 4px; border-radius: 2px; background: #8c1c12; color: #fff3e0; font-size: 9.5px; font-weight: 900; letter-spacing: .06em; } #killfeed .nt { filter: drop-shadow(0 0 3px #b388ff); } /* Forteresses : meurtre final, poussé dans le Néant (§ 7.109) */
#modeHud { position: absolute; top: 54px; left: 50%; transform: translateX(-50%); padding: 7px 16px; text-align: center; font-size: 13px; min-width: 280px; }
#modeHud b { color: var(--gold); } #modeHud .big { font-family: var(--ft); font-size: 19px; letter-spacing: .5px; }
#modeHud .teams { display: flex; align-items: center; gap: 10px; justify-content: center; font-family: var(--ft); font-size: 18px; }
#modeHud .bar { width: 240px; height: 10px; margin: 5px auto 0; display: flex; overflow: hidden; border-radius: 5px; border-width: 1px; }
#modeHud .bar i { display: block; height: 100%; }
#modeHud .pts { display: flex; gap: 6px; justify-content: center; margin-top: 5px; }
#modeHud .pt { width: 60px; height: 9px; border-radius: 5px; background: #777; position: relative; overflow: hidden; border: 1px solid var(--bark); }
#modeHud .pt i { position: absolute; left: 0; top: 0; bottom: 0; }
#modeHud .cores { display: flex; gap: 12px; justify-content: center; }
#modeHud .core { width: 110px; text-align: left; } #modeHud .core span { font-family: var(--ft); color: var(--tc); font-size: 14px; }
#modeHud .core .cb { height: 9px; background: var(--bark); border: 1px solid var(--wood-d); border-radius: 5px; overflow: hidden; margin: 2px 0; } #modeHud .core .cb i { display: block; height: 100%; background: var(--tc); }
#modeHud .core small { font-size: 10px; color: var(--parch); } #modeHud .core.dead { opacity: .55; }
#minimapWrap { position: absolute; right: 14px; bottom: 14px; }
#minimap { display: block; border-radius: 4px; background: #000; }
#hotbar { position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); display: flex; gap: 8px; }
.slot { width: 52px; height: 52px; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; font-family: var(--ft); font-size: 10px; letter-spacing: .3px; text-align: center; line-height: 1.1; color: var(--parch); text-shadow: 0 1px 0 rgba(0,0,0,.7);
  background: radial-gradient(circle at 50% 40%, #5a3a1e, #3b2410); border: 3px solid var(--wood); border-radius: 8px; box-shadow: inset 0 0 12px rgba(0,0,0,.7), 0 0 0 2px var(--bark), 0 4px 0 #1b0f08; transition: transform .08s; }
.slot:hover { transform: translateY(-2px); }
.slot.eq { border-color: var(--gold); box-shadow: inset 0 0 12px rgba(0,0,0,.6), 0 0 0 2px var(--bark), 0 0 16px var(--gold), 0 4px 0 #1b0f08; }
.slot .k { position: absolute; top: -8px; left: -6px; width: 18px; height: 18px; border-radius: 4px; background: var(--parch); color: var(--ink); font-size: 11px; display: flex; align-items: center; justify-content: center; border: 2px solid var(--bark); text-shadow: none; }
.slot .n { position: absolute; bottom: 2px; right: 5px; font-size: 12px; color: var(--gold); }
.slot .ico { width: 22px; height: 22px; border-radius: 5px; margin-bottom: 2px; }
.slot img { width: 28px; height: 28px; margin-bottom: 1px; filter: drop-shadow(0 2px 2px rgba(0,0,0,.6)); }
#actions { position: absolute; left: 14px; bottom: 14px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
#actions .sign { font-size: 13px; padding: 5px 13px; min-width: 100px; text-align: left; }
#panels { position: absolute; left: 140px; bottom: 14px; }
.side { width: 340px; max-height: 72vh; padding: 14px 14px 10px; overflow-y: auto; color: var(--parch); }
.side::-webkit-scrollbar { width: 8px; } .side::-webkit-scrollbar-thumb { background: var(--wood); border-radius: 4px; }
.side h3 small { font-size: 11px; opacity: .8; }
.tabs { display: flex; gap: 5px; flex-wrap: wrap; margin-bottom: 8px; }
.tabs div { padding: 4px 10px; border-radius: 4px; background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); cursor: pointer; font-family: var(--ft); font-size: 12px; letter-spacing: .5px; border: 2px solid #b89b6a; box-shadow: 0 2px 0 #a3875a; }
.tabs div.on { background: linear-gradient(180deg, #ffd766, var(--gold)); border-color: var(--gold-d); }
.item { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 6px; cursor: pointer; border: 2px solid transparent; margin-bottom: 3px; background: rgba(0,0,0,.18); }
.item:hover { background: rgba(255,255,255,.08); border-color: rgba(241,227,198,.25); }
.item.no { opacity: .45; }
.item.sel { border-color: var(--gold); box-shadow: 0 0 10px rgba(242,177,52,.5); }
.item .ico { width: 30px; height: 30px; border-radius: 6px; flex-shrink: 0; }
.item img.ico { width: 36px; height: 36px; border-radius: 0; background: none; filter: drop-shadow(0 2px 2px rgba(0,0,0,.6)); }
.item .t { flex: 1; font-size: 13.5px; font-weight: 800; }
.item .t small { display: block; color: #c9b08a; font-size: 11px; font-weight: 600; }
.item .cost { font-size: 11px; color: var(--parch); text-align: right; font-weight: 800; }
.item .cost .lack { color: #ff8a80; }
.item button.mini, #clanBody button.mini { font-family: var(--fb); font-weight: 800; font-size: 11px; padding: 3px 8px; border-radius: 4px; background: var(--parch); color: var(--ink); border: 2px solid var(--bark); }
#clanBody .row input { flex: 1; padding: 8px 10px; font-size: 14px; border-radius: 4px; border: 2px solid var(--bark); background: var(--parch); color: var(--ink); outline: none; }
#clanBody .row button, #clanLeave { font-family: var(--ft); padding: 6px 12px; font-size: 14px; border-radius: 6px; background: linear-gradient(180deg, #8fd16d, #4f9a3a); color: #fff; border: 2px solid var(--bark); letter-spacing: .5px; }
#clanLeave { background: linear-gradient(180deg, #ff6b6b, #b71c1c); margin-top: 8px; }
.chestrow { display: flex; align-items: center; gap: 6px; padding: 4px 0; font-size: 13px; border-bottom: 1px dashed var(--stitch); }
.chestrow .nm { flex: 1; font-weight: 800; } .chestrow img { width: 22px; height: 22px; }
.chestrow button { padding: 2px 8px; font-size: 11px; font-family: var(--fb); font-weight: 800; background: var(--parch); color: var(--ink); border: 2px solid var(--bark); border-radius: 4px; }
/* ----- échange entre joueurs ----- */
#tradePanel { width: 380px; }
.trcols { display: flex; gap: 10px; }
.trcol { flex: 1; min-width: 0; background: rgba(0,0,0,.18); border-radius: 6px; padding: 6px 8px; min-height: 70px; }
.trcol h4 { margin: 0 0 4px; font-family: var(--ft); font-weight: normal; font-size: 13px; letter-spacing: .5px; color: var(--gold); }
.trcol h4.ok { color: #9ccc65; }
.trrow { display: flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 800; padding: 2px 0; }
.trrow img, .trrow .icon { width: 20px; height: 20px; }
.trrow .nm { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.trrow button, .trinv button { padding: 1px 6px; font-size: 11px; font-family: var(--fb); font-weight: 800; background: var(--parch); color: var(--ink); border: 2px solid var(--bark); border-radius: 4px; }
.trinv { max-height: 180px; overflow-y: auto; margin-top: 6px; }
.trbtns { display: flex; gap: 8px; justify-content: center; margin-top: 8px; }
.trbtns .sign.ok { background-image: repeating-linear-gradient(90deg, rgba(0,0,0,.08) 0 2px, transparent 2px 11px), linear-gradient(180deg, #8fd16d, #4f9a3a 55%, #3d7d2c); color: #fff; }
.trwait { font-size: 11px; color: #c9b08a; text-align: center; margin-top: 4px; }
#tradeReq { position: absolute; top: 140px; left: 50%; transform: translateX(-50%); padding: 6px 16px; font-size: 13px; font-weight: 800; color: var(--parch); }
#tradeReq b { color: var(--gold); }
#meteorBar { position: absolute; top: 112px; left: 50%; transform: translateX(-50%); padding: 5px 14px; font-size: 12.5px; font-weight: 800; color: #ffab40; }
#shopGold { font-family: var(--ft); color: var(--gold); font-size: 14px; margin: 2px 0 6px; letter-spacing: .5px; }
.shoprow { display: flex; align-items: center; gap: 6px; padding: 3px 0; font-size: 12.5px; font-weight: 800; border-bottom: 1px dashed var(--stitch); }
.shoprow .nm { flex: 1; } .shoprow .pr { color: var(--gold); white-space: nowrap; } .shoprow img, .shoprow .icon { width: 22px; height: 22px; }
.shoprow button { padding: 2px 8px; font-size: 11px; font-family: var(--fb); font-weight: 800; background: var(--parch); color: var(--ink); border: 2px solid var(--bark); border-radius: 4px; }
.shoprow button:disabled { opacity: .4; }
.icon { width: 22px; height: 22px; vertical-align: middle; }
#levelup { position: absolute; top: 100px; left: 50%; transform: translateX(-50%); padding: 14px 18px 16px; text-align: center; }
#levelup h3 { margin: 0 0 10px; font-family: var(--ft); font-size: 22px; letter-spacing: 1px; color: var(--gold); text-shadow: 0 3px 0 rgba(0,0,0,.6); }
#upgList { display: flex; gap: 10px; }
#upgList div { background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); padding: 10px 12px; border-radius: 4px; cursor: pointer; width: 140px; font-size: 13px; border: 2px solid #b89b6a; box-shadow: 0 3px 0 #a3875a; transition: transform .1s; }
#upgList div:nth-child(1) { transform: rotate(-2deg); } #upgList div:nth-child(3) { transform: rotate(2deg); }
#upgList div:hover { transform: rotate(0) scale(1.06); border-color: var(--gold-d); box-shadow: 0 0 0 3px var(--gold), 0 3px 0 #a3875a; }
#upgList b { font-family: var(--ft); font-weight: normal; font-size: 15px; letter-spacing: .5px; }
#upgList small { display: block; color: var(--ink-l); margin-top: 4px; font-size: 11px; }
#quests { position: absolute; right: 14px; top: 262px; width: 170px; display: flex; flex-direction: column; gap: 5px; pointer-events: none; }
#quests div { position: relative; background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); padding: 4px 8px 5px; border: 2px solid #b89b6a; border-radius: 3px; font-size: 11px; font-weight: 800; box-shadow: 0 3px 0 #a3875a, 0 5px 10px rgba(0,0,0,.4); }
#quests div:nth-child(odd) { transform: rotate(-1deg); } #quests div:nth-child(even) { transform: rotate(1deg); }
#quests div::before { content: ''; position: absolute; top: -6px; left: 50%; width: 10px; height: 10px; margin-left: -5px; border-radius: 50%; background: radial-gradient(circle at 35% 35%, #ffe082, #b07a1a); box-shadow: 0 2px 3px rgba(0,0,0,.6); }
#quests small { color: #6a1b9a; float: right; font-family: var(--ft); font-weight: normal; }
#quests .pb { height: 5px; background: rgba(43,26,16,.2); margin-top: 4px; border-radius: 3px; overflow: hidden; } #quests .pb i { display: block; height: 100%; background: linear-gradient(90deg, #8e24aa, #ce93d8); }
#chat { position: absolute; left: 14px; bottom: 212px; width: 320px; } /* au-dessus des boutons Craft/Bâtir/Clan/Réglages */
#chatLog { max-height: min(250px, calc(100vh - 470px)); overflow: hidden; font-size: 13px; display: flex; flex-direction: column; align-items: flex-start; }
#chatLog > :first-child { margin-top: auto; } /* collé en bas (sans justify-content: flex-end, qui empêcherait de défiler) */
#chat.open #chatLog { max-height: 45vh; overflow-y: auto; overscroll-behavior: contain; } /* chat ouvert : tout l'historique récent, défilable */
#chatLog .sys { line-height: 1.45; } #chatLog div { overflow-wrap: anywhere; } /* les longues commandes reviennent à la ligne au lieu de dépasser */
#chatLog div { transition: opacity .6s; }
#chatLog div.fade { opacity: 0; }
#chatLog div { background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); padding: 2px 9px; border: 2px solid #b89b6a; border-radius: 3px; margin-top: 3px; max-width: 100%; box-shadow: 0 2px 0 #a3875a; }
#chatLog b { color: #8a4a12; } #chatLog .sys { color: #1565c0; font-weight: 800; }
#chatLog div.mp { border-color: #6a1b9a; background: linear-gradient(160deg, #f3e5f5, #e1bee7); } #chatLog div.mp b { color: #4a148c; }
#chatLog div.cc { border-color: #2e7d32; background: linear-gradient(160deg, #e8f5e9, #dcedc8); } #chatLog div.cc b { color: #1b5e20; }
#tuto { position: absolute; top: 54px; left: 50%; transform: translateX(-50%); max-width: 560px; padding: 6px 30px 6px 12px; font-size: 12.5px; color: var(--ink); font-weight: 700; line-height: 1.35; }
#tuto b { color: #8a4a12; font-family: var(--ft); font-weight: normal; }
#tuto button { position: absolute; right: 6px; top: 5px; width: 18px; height: 18px; border-radius: 50%; background: var(--bark); color: var(--parch); font-size: 10px; line-height: 18px; padding: 0; }
#chatInput { width: 100%; margin-top: 5px; font-size: 14px; padding: 8px 10px; border-radius: 4px; border: 3px solid var(--bark); background: var(--parch); color: var(--ink); outline: none; }
#toasts { position: absolute; top: 250px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 5px; pointer-events: none; }
#toasts .tn { color: #8d2a1a; margin-left: 4px; }
#toasts div { background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); padding: 5px 16px; border: 2px solid #b89b6a; border-radius: 14px; font-family: var(--ft); font-size: 14px; letter-spacing: .5px; box-shadow: 0 3px 0 #a3875a, 0 6px 12px rgba(0,0,0,.45); animation: fade 3s forwards; }
#toasts div.g { color: #8a4a12; border-color: var(--gold-d); box-shadow: 0 0 0 2px var(--gold), 0 3px 0 #a3875a; }
@keyframes fade { 0% { opacity: 0; transform: translateY(-8px) scale(.9);} 10% { opacity: 1; transform: none;} 80% { opacity: 1;} 100% { opacity: 0;} }
#bigmap { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; background: rgba(5,10,6,.6); gap: 10px; }
#bigmap canvas { display: block; max-width: 86vw; max-height: 78vh; border-radius: 4px; }
#bigmap .legend { padding: 5px 14px; font-size: 13px; font-weight: 800; }
#bigmap { z-index: 5; } #bigmap .frame { position: relative; } /* devant la barre d'outils (le ✕ ou M ferment) */
#bigmap canvas { touch-action: none; cursor: grab; } #bigmap canvas:active { cursor: grabbing; }
#bigmap .mapzoom { position: absolute; right: 12px; top: 12px; display: flex; flex-direction: column; align-items: center; gap: 6px; }
#bigmap .mapzoom button { width: 40px; height: 40px; border-radius: 8px; border: 2px solid rgba(255,255,255,.25); background: rgba(20,16,12,.78); color: #f3e6c8; font: 700 24px/1 Inter, sans-serif; cursor: pointer; display: grid; place-items: center; padding: 0; }
#bigmap .mapzoom button:hover { background: rgba(60,44,28,.9); border-color: #e0b85a; }
#bigmap #mapClose { font-size: 18px; margin-bottom: 8px; }
#bigmap .mapzoom span { font: 700 12px Inter, sans-serif; color: #f3e6c8; text-shadow: 0 1px 2px #000; }
#touch { position: absolute; inset: 0; pointer-events: none; }
#joy { position: absolute; left: 36px; bottom: 110px; width: 134px; height: 134px; border-radius: 50%; background: radial-gradient(circle, rgba(59,42,30,.55), rgba(43,26,16,.75)); border: 4px solid var(--wood); box-shadow: 0 0 0 3px var(--bark), inset 0 0 20px rgba(0,0,0,.6); pointer-events: auto; }
#joyKnob { position: absolute; left: 38px; top: 38px; width: 50px; height: 50px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, var(--wood-l), var(--wood-d)); border: 3px solid var(--bark); box-shadow: 0 3px 0 #1b0f08; }
#atkBtn { position: absolute; right: 40px; bottom: 220px; width: 92px; height: 92px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #ff8a80, #b71c1c); border: 4px solid var(--bark); box-shadow: 0 0 0 3px var(--wood), 0 5px 0 #1b0f08; display: flex; align-items: center; justify-content: center; font-size: 38px; pointer-events: auto; }
#atkBtn:active { transform: translateY(3px); }
#dashBtn, #blockBtn { position: absolute; right: 150px; width: 64px; height: 64px; border-radius: 50%; border: 4px solid var(--bark); display: flex; align-items: center; justify-content: center; font-size: 26px; pointer-events: auto; box-shadow: 0 0 0 3px var(--wood), 0 4px 0 #1b0f08; }
#dashBtn { bottom: 250px; background: radial-gradient(circle at 35% 30%, #80deea, #00838f); }
#useBtn, #tradeBtn, #horseBtn { position: absolute; right: 40px; width: 58px; height: 58px; border-radius: 50%; border: 4px solid var(--bark); display: flex; align-items: center; justify-content: center; font-family: var(--ft); font-size: 20px; color: #fff; pointer-events: auto; box-shadow: 0 0 0 3px var(--wood), 0 4px 0 #1b0f08; text-shadow: 0 2px 0 rgba(0,0,0,.5); }
#useBtn { bottom: 330px; background: radial-gradient(circle at 35% 30%, #ffe082, #b07a1a); }
#horseBtn { bottom: 470px; background: radial-gradient(circle at 35% 30%, #d7ccc8, #6d4c41); font-size: 24px; }
#tradeBtn { bottom: 400px; background: radial-gradient(circle at 35% 30%, #ce93d8, #6a1b9a); }
#blockBtn { bottom: 170px; background: radial-gradient(circle at 35% 30%, #a1887f, #4e342e); }
@media (max-height: 540px) { /* téléphone en paysage : tout tient à l'écran, F/T/cheval en colonne à gauche des boutons de combat */
  #joy { bottom: 50px; }
  #atkBtn { bottom: 16px; } #dashBtn { bottom: 96px; } #blockBtn { bottom: 16px; }
  #useBtn, #tradeBtn, #horseBtn { right: 250px; }
  #useBtn { bottom: 72px; } #tradeBtn { bottom: 142px; } #horseBtn { bottom: 212px; }
}

/* ----- mobile (écran étroit, ou téléphone en paysage : peu de hauteur) ----- */
@media (max-width: 800px), (max-height: 540px) {
  .board { padding: 16px 14px; } .logo { font-size: 46px; } .help { grid-template-columns: 1fr 1fr; } .modes { grid-template-columns: 1fr 1fr; gap: 6px; } .mode small { display: none; } .tips { display: none; }
  #leaderboard { display: none; } #stats { width: 160px; gap: 5px; } .bar { height: 20px; } .bar span { font-size: 11px; } #chatLog { display: none; } #chat { bottom: 100px; width: 240px; } #quests { display: none; }
  #topbar { left: 180px; transform: none; gap: 6px; } #topbar .plank { font-size: 11px; padding: 3px 8px; }
  .side { width: 270px; max-height: 55vh; padding: 10px; } #panels { left: 14px; bottom: 90px; }
  #actions { left: auto; right: 14px; top: 44px; bottom: auto; flex-direction: row; } #actions .sign { font-size: 12px; padding: 5px 9px; min-width: 0; }
  #levelup { top: 80px; } #upgList div { width: 100px; font-size: 11px; }
  #killfeed { top: 80px; width: 160px; } #killfeed div { font-size: 10px; }
  #modeHud { top: 40px; font-size: 11px; min-width: 200px; } #modeHud .cores { gap: 6px; } #modeHud .core { width: 70px; }
  #hotbar { bottom: 10px; } .slot { width: 46px; height: 46px; font-size: 8px; } .slot img { width: 26px; height: 26px; }
  .res { font-size: 12px; }
  #minimapWrap { bottom: 10px; right: 10px; } #minimap { width: 120px; height: 120px; }
  #tuto { top: 86px; left: 180px; transform: none; max-width: min(340px, 42vw); font-size: 11px; padding: 4px 26px 4px 8px; }
}
@media (max-width: 520px) { /* téléphone en portrait : boutons en grille sous les barres, tutoriel dessous, minimap en haut à droite */
  #actions { top: 108px; left: 14px; right: auto; flex-wrap: wrap; max-width: 62vw; gap: 4px; } #actions .sign { font-size: 11px; padding: 4px 7px; }
  #inventory { margin-top: 64px; } #tuto { top: auto; bottom: 70px; left: 14px; right: 14px; max-width: none; } #fx { max-width: 60vw; }
  #minimapWrap { top: 60px; bottom: auto; right: 8px; } #minimap { width: 90px; height: 90px; }
  #meteorBar { top: 170px; left: 180px; right: 14px; transform: none; font-size: 10px; max-width: none; }
}
@media (max-height: 540px) { /* en paysage, la minimap monte sous la rangée de boutons pour laisser la place aux commandes tactiles */
  #minimapWrap { top: 88px; bottom: auto; right: 10px; } #minimap { width: 100px; height: 100px; }
  #left { gap: 4px; } #stats { width: 150px; } #tuto { display: none; }
  #hotbar { bottom: 6px; } #meteorBar { top: 86px; left: 180px; transform: none; font-size: 10px; max-width: 230px; }
}

#fx { display: flex; flex-wrap: wrap; gap: 4px; max-width: 210px; } #fx:empty { display: none; }
#fx span { background: linear-gradient(160deg, #f6ead2, var(--parch)); color: var(--ink); border: 2px solid #b89b6a; border-radius: 12px; padding: 1px 8px; font-size: 11px; font-weight: 800; }
#fx span.bad { border-color: #c62828; color: #b71c1c; }

#bossBar { position: absolute; top: 150px; left: 50%; transform: translateX(-50%); width: 420px; text-align: center; pointer-events: none; }
#bossBar .nm { font-family: var(--ft); font-size: 18px; color: #ff8a80; letter-spacing: 1px; text-shadow: 0 2px 0 #4a0000, 0 4px 10px rgba(0,0,0,.6); }
#bossBar .hb { height: 16px; background: var(--bark); border: 2px solid #7f1d1d; border-radius: 9px; overflow: hidden; box-shadow: 0 2px 0 #1b0f08; }
#bossBar .hb i { display: block; height: 100%; background: linear-gradient(180deg, #ff5252, #b71c1c); transition: width .2s; }
#bossBar small { display: block; color: var(--parch); font-size: 12px; font-weight: 800; text-shadow: 0 1px 0 #000; margin-top: 2px; }
#bossBar .hb { position: relative; } #bossBar .hb b { position: absolute; top: 0; bottom: 0; width: 2px; margin-left: -1px; background: rgba(255,255,255,.7); } /* crans de phase (60 %, 30 %) */
#bossBar.p2 .hb i { background: linear-gradient(180deg, #ffab40, #e65100); } #bossBar.p3 .hb i { background: linear-gradient(180deg, #ff1744, #880e4f); } #bossBar.p3 .nm { color: #ff5252; }
#bossBanner { position: absolute; top: 60%; left: 50%; transform: translateX(-50%); text-align: center; pointer-events: none; z-index: 4; white-space: nowrap; }
#bossBanner .bt { font-family: var(--ft); font-size: 46px; letter-spacing: 4px; color: #ff5252; text-shadow: 0 3px 0 #2a0000, 0 0 24px rgba(255,40,40,.55), 0 6px 18px rgba(0,0,0,.85); }
#bossBanner .bs { font-size: 18px; font-weight: 800; color: #ffe0b2; text-shadow: 0 2px 0 #000, 0 0 10px rgba(0,0,0,.8); margin-top: 4px; letter-spacing: 1px; }
#bossBanner.show { animation: bossIn 2.7s ease-out forwards; }
@keyframes bossIn { 0% { opacity: 0; transform: translateX(-50%) scale(1.35); } 12% { opacity: 1; transform: translateX(-50%) scale(1); } 78% { opacity: 1; } 100% { opacity: 0; transform: translateX(-50%) scale(1); } }
@media (max-width: 800px), (max-height: 540px) { #bossBanner .bt { font-size: 26px; letter-spacing: 2px; } #bossBanner .bs { font-size: 13px; } #bossBanner { white-space: normal; width: 92vw; } }
.item .st { font-size: 10px; color: #ffb74d; font-weight: 800; }
.item .st.ok { color: #9ccc65; }
.item .st + .st { margin-left: 8px; } /* station puis âmes de titan (§ 7.32, lot 4) */
.item.locked { opacity: .55; }

/* ----- réglages (Échap) ----- */
#settings { z-index: 30; }
.setbox { width: min(92vw, 440px); padding: 26px 26px 20px; text-align: center; }
#newsBtn.blink { animation: newsblink 1.2s ease-in-out infinite; } @keyframes newsblink { 50% { box-shadow: 0 0 0 3px var(--gold), 0 3px 0 #5a3a1a; } }
.newsbox { width: min(94vw, 560px); max-height: 88vh; overflow: auto; }
.newslist { text-align: left; margin: 6px 0 14px; padding: 0 0 0 18px; color: var(--parch); font-size: 13.5px; line-height: 1.45; }
.newslist li { margin: 0 0 7px; } .newslist b { color: var(--gold); } .newslist code { background: rgba(0,0,0,.35); padding: 1px 6px; border-radius: 4px; }
/* Confidentialité (§ 7.131) : la ligne du menu et le panneau */
.privnote { font-size: 11.5px; color: var(--parch); opacity: .78; margin: 2px 0 6px; line-height: 1.4; text-shadow: 0 1px 0 rgba(0,0,0,.5); }
.privnote a { color: var(--gold); font-weight: 600; text-underline-offset: 2px; } .privnote a:hover { color: #fff; }
#privacy { z-index: 44; } /* au-dessus des Réglages (30) et de l'écran de mort (40), sous « Ton avis » (45) */
.privbox { width: min(94vw, 620px); }
.privbox h3 { font: 700 15px 'Cinzel', serif; color: var(--gold); margin: 12px 0 4px; text-align: left; letter-spacing: .03em; }
.privintro { color: var(--parch); font-size: 13.5px; margin: 4px 0 2px; text-align: left; line-height: 1.45; }
.privbox .newslist { margin-bottom: 6px; }
.privbtns { display: flex; justify-content: center; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 10px; }
.setbox .plank-title { margin: -40px 0 8px; font-size: 20px; }
.setmode { font-family: var(--ft); color: var(--gold); letter-spacing: 1px; margin-bottom: 10px; min-height: 18px; text-shadow: 0 2px 0 rgba(0,0,0,.5); }
.setrow { display: flex; align-items: center; gap: 10px; margin: 8px 0; font-size: 14px; font-weight: 800; color: var(--parch); }
.setrow span { width: 150px; text-align: left; }
.setrow select { flex: 1; padding: 4px 8px; border-radius: 6px; border: 2px solid var(--bark); background: var(--parch); color: var(--ink); font-family: inherit; font-size: 13px; }
.setrow input[type=range] { flex: 1; accent-color: var(--gold); cursor: pointer; }
.setrow input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--gold); cursor: pointer; }
.setbox .keys { grid-template-columns: 1fr 1fr; margin: 12px 0; }
.achwrap { margin: 10px 0 4px; text-align: left; }
.achtitle { font-size: 12px; color: var(--gold); font-weight: 800; margin-bottom: 4px; }
.achlist { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 5px; max-height: 150px; overflow-y: auto; }
.ach { background: rgba(0,0,0,.2); border-radius: 5px; padding: 4px 6px; font-size: 11px; color: #c9b08a; border: 2px solid transparent; }
.ach b { display: block; color: var(--parch); font-size: 11.5px; } .ach small { display: block; font-size: 10px; line-height: 1.2; }
.ach .pb { height: 4px; background: rgba(0,0,0,.4); border-radius: 2px; margin-top: 3px; overflow: hidden; } .ach .pb i { display: block; height: 100%; background: var(--gold); }
.ach.ok { border-color: var(--gold-d); cursor: pointer; } .ach.ok b { color: var(--gold); } .ach.cur { box-shadow: 0 0 0 2px var(--gold); }
.setbtns { justify-content: center; align-items: center; margin-top: 6px; }
.sign.danger { background-image: repeating-linear-gradient(90deg, rgba(0,0,0,.08) 0 2px, transparent 2px 11px), linear-gradient(180deg, #ff8a80, #c62828 55%, #8e0000); color: #fff; }

/* =====================================================================================
   Thème sobre (remplace le style « cartoon » : bois, parchemin, clous, police ronde).
   Panneaux sombres translucides, filets fins, titres à empattements, texte lisible.
   ===================================================================================== */
:root {
  --ui-bg: rgba(14, 16, 18, .84); --ui-bg2: rgba(22, 25, 28, .94); --ui-bg3: rgba(255, 255, 255, .04);
  --ui-line: rgba(255, 255, 255, .09); --ui-line2: rgba(255, 255, 255, .18);
  --ui-text: #e6e1d6; --ui-dim: #99938a; --ui-acc: #c9a55c; --ui-acc2: #8fb0c4; --ui-bad: #c45a54; --ui-ok: #82ad6e;
  --ft: 'Inter', 'Segoe UI', system-ui, sans-serif; --fb: 'Inter', 'Segoe UI', system-ui, sans-serif; --fh: 'Cinzel', Georgia, serif;
  --gold: #c9a55c; --parch: #e6e1d6;
}
html, body { background: #0d0f10; font-weight: 500; color: var(--ui-text); }
button { font-family: var(--fb); }
.plank, .sign, .plank-title, .leather, .parch, .frame, .board {
  background: var(--ui-bg); background-image: none; border: 1px solid var(--ui-line2); border-radius: 4px; outline: none;
  box-shadow: 0 4px 18px rgba(0, 0, 0, .45); color: var(--ui-text); text-shadow: none;
}
.leather, .board { background: var(--ui-bg2); border-radius: 6px; box-shadow: 0 18px 50px rgba(0, 0, 0, .6); backdrop-filter: blur(6px); }
.parch { background: rgba(20, 23, 26, .86); } .parch b, .help b, #tuto b { color: var(--ui-acc); font-family: var(--fb); font-weight: 700; }
.frame { padding: 3px; background: rgba(0, 0, 0, .6); }
.rope, .sign::before, .sign::after, .mode::before, #quests div::before { display: none !important; }
/* boutons */
.sign { font-family: var(--fb); font-weight: 600; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; padding: 8px 16px; transition: border-color .12s, background .12s, color .12s; }
.sign:hover { filter: none; transform: none; border-color: var(--ui-acc); color: #fff; background: rgba(30, 33, 37, .92); }
.sign:active { transform: translateY(1px); box-shadow: none; }
.sign.big { font-size: 15px; letter-spacing: .14em; padding: 12px 30px; background: linear-gradient(180deg, #d4b26a, #a8823b); background-image: linear-gradient(180deg, #d4b26a, #a8823b); color: #15120c; border-color: #e0c27d; }
.sign.big:hover { background: linear-gradient(180deg, #e0c27d, #b78f44); color: #000; }
.sign.small { font-size: 11px; padding: 6px 11px; }
.sign.on { background: rgba(201, 165, 92, .16); background-image: none; color: var(--ui-acc); border-color: var(--ui-acc); text-shadow: none; }
.sign.danger { background: rgba(140, 40, 36, .35); background-image: none; border-color: #8c3a35; color: #f0c9c5; }
.sign.danger:hover { background: rgba(170, 50, 45, .5); border-color: var(--ui-bad); }
/* titres de panneaux */
.plank-title { display: block; margin: 0 0 10px; padding: 0 0 8px; background: none; border: none; border-bottom: 1px solid var(--ui-line2); border-radius: 0; box-shadow: none; transform: none;
  font-family: var(--fh); font-size: 15px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--ui-text); text-align: left; }
.plank-title small { font-family: var(--fb); font-size: 11px; color: var(--ui-dim); letter-spacing: .05em; }
.setbox .plank-title { margin: 0 0 12px; font-size: 18px; text-align: center; }
/* menu */
.overlay { background: radial-gradient(ellipse at center, rgba(5, 7, 8, .55), rgba(3, 4, 5, .9)); }
.board { padding: 26px 30px 22px; }
.logo { font-family: var(--fh); font-weight: 700; font-size: 50px; letter-spacing: .14em; color: #ece6d9; text-shadow: 0 2px 18px rgba(0, 0, 0, .7); -webkit-text-stroke: 0; }
.logo span { color: var(--ui-acc); text-shadow: none; font-size: .55em; letter-spacing: .1em; }
.tagline { font-family: var(--fb); font-size: 11px; font-weight: 600; letter-spacing: .38em; text-transform: uppercase; color: var(--ui-dim); text-shadow: none; }
.joinrow input, .privrow input, #chatInput, #clanBody .row input, .setrow select { background: rgba(0, 0, 0, .45); border: 1px solid var(--ui-line2); border-radius: 4px; color: var(--ui-text); box-shadow: none; font-family: var(--fb); font-weight: 500; }
.joinrow input:focus, .privrow input:focus, #chatInput:focus, #clanBody .row input:focus { border-color: var(--ui-acc); }
.joinrow input::placeholder, .privrow input::placeholder { color: #6f6a62; }
.skin { border: 2px solid rgba(0, 0, 0, .6); box-shadow: 0 0 0 1px var(--ui-line2); }
.skin.sel { border-color: #111; box-shadow: 0 0 0 2px var(--ui-acc); transform: scale(1.1); }
.mode, .mode:nth-child(odd), .mode:nth-child(even) { background: var(--ui-bg3); border: 1px solid var(--ui-line); border-radius: 5px; box-shadow: none; transform: none; color: var(--ui-text); }
.mode:hover { transform: none; border-color: var(--ui-line2); background: rgba(255, 255, 255, .06); }
.mode.sel { transform: none; border-color: var(--ui-acc); box-shadow: 0 0 0 1px var(--ui-acc), 0 6px 20px rgba(0, 0, 0, .4); }
.mode .prev { border: none; border-radius: 3px; box-shadow: none; }
.mode b { font-family: var(--fh); font-weight: 700; font-size: 14px; letter-spacing: .06em; color: var(--ui-text); }
.mode small { color: var(--ui-dim); } .mode .cnt { color: var(--ui-ok); font-weight: 600; }
.help { color: var(--ui-text); } .tips, #hof { color: var(--ui-dim); text-shadow: none; } #hof b { color: var(--ui-acc); }
#roomInfo { color: var(--ui-acc); text-shadow: none; }
/* écran de mort */
.stamp { font-family: var(--fh); font-weight: 700; font-size: 38px; letter-spacing: .1em; color: #c9625c; transform: none; text-shadow: 0 2px 20px rgba(0, 0, 0, .8); text-transform: uppercase; }
.deathbox p { color: var(--ui-text); } .deathbox p b, .dstats b { color: var(--ui-acc); }
.dstats div { background: rgba(255, 255, 255, .04); border: 1px solid var(--ui-line); border-radius: 4px; color: var(--ui-text); }
.dnote { margin: 8px 0 0; padding: 6px 10px; font-size: 12.5px; text-align: left; color: var(--ui-text); background: rgba(255, 255, 255, .04); border-left: 2px solid var(--ui-acc); border-radius: 2px; }
#specRow { font-family: var(--fb); font-size: 13px; }
/* HUD : barres fines */
#stats { width: 200px; gap: 5px; }
.bar { height: 14px; margin-left: 20px; background: rgba(0, 0, 0, .6); border: 1px solid var(--ui-line2); border-radius: 2px; box-shadow: none; }
.bar .fill { border-radius: 1px; box-shadow: none; }
.bar span { font-family: var(--fb); font-size: 10px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; text-shadow: 0 1px 2px rgba(0, 0, 0, .9); }
.bar .bi { left: -20px; top: -2px; width: 16px; height: 16px; background: none; border: none; box-shadow: none; font-size: 11px; font-style: normal; opacity: .9; }
.bar.xp { height: 10px; } .bar.xp span { font-size: 9px; } .bar.xp .bi { width: 16px; height: 16px; top: -3px; font-size: 10px; }
.bar.hp .fill { background: linear-gradient(180deg, #c8504a, #9a2f2b); }
.bar.food .fill { background: linear-gradient(180deg, #c58a49, #94602b); }
.bar.stamina .fill { background: linear-gradient(180deg, #cdb35e, #9d853a); }
.bar.mana .fill { background: linear-gradient(180deg, #6a8fd8, #3b5aa8); }
.bar.fuel .fill { background: linear-gradient(180deg, #d39a52, #9a6526); } .bar.car .fill { background: linear-gradient(180deg, #8d9aa4, #57646e); }
.bar.cold .fill { background: linear-gradient(180deg, #6f9fc4, #3f6f95); }
.bar.heat .fill { background: linear-gradient(180deg, #cf7350, #9a4628); }
.bar.poison .fill { background: linear-gradient(180deg, #8bab5c, #5a7a33); }
.bar.xp .fill { background: linear-gradient(180deg, #8f7ac9, #5f4b9a); }
.res, #fx span, #killfeed div, #quests div, #chatLog div, #toasts div, #upgList div, .tabs div {
  background: var(--ui-bg); background-image: none; border: 1px solid var(--ui-line); border-radius: 3px; color: var(--ui-text); box-shadow: none; transform: none !important; text-shadow: none;
}
.res { font-family: var(--fb); font-size: 12px; font-weight: 600; letter-spacing: .02em; padding: 2px 9px 2px 4px; }
#topbar .plank { font-family: var(--fb); font-size: 11.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; padding: 5px 12px; }
#clock { color: var(--ui-acc); }
#leaderboard { transform: none; padding: 10px 12px 8px; }
#leaderboard .plank-title { font-size: 12px; margin-bottom: 6px; padding-bottom: 6px; }
#leaderboard ol { color: var(--ui-text); } #leaderboard li.me { color: var(--ui-acc); font-weight: 700; } #leaderboard .tag { color: var(--ui-dim); }
#killfeed div { font-size: 11.5px; } #killfeed .k { color: var(--ui-ok); } #killfeed .v { color: var(--ui-bad); }
#killfeed .Rouge { color: #e06b63 !important; } #killfeed .Bleu { color: #6fb6e0 !important; } #killfeed .Vert { color: #7fbf7a !important; } #killfeed .Jaune { color: #d9b85c !important; }
#modeHud b, #modeHud .core span { font-family: var(--fb); } #modeHud .big, #modeHud .teams { font-family: var(--fh); }
#modeHud .core .cb, #modeHud .pt { background: rgba(0, 0, 0, .6); border-color: var(--ui-line2); }
/* barre rapide */
#hotbar { gap: 4px; padding: 4px; background: rgba(10, 12, 14, .55); border: 1px solid var(--ui-line); border-radius: 4px; }
.slot { width: 50px; height: 50px; background: rgba(0, 0, 0, .55); border: 1px solid var(--ui-line2); border-radius: 3px; box-shadow: none; font-family: var(--fb); color: var(--ui-text); text-shadow: none; }
.slot:hover { transform: none; border-color: rgba(255, 255, 255, .35); }
.slot.eq { border-color: var(--ui-acc); box-shadow: inset 0 0 0 1px var(--ui-acc), 0 0 12px rgba(201, 165, 92, .35); }
.slot.empty { opacity: .45; cursor: default; }
.slot .k { top: 2px; left: 4px; width: auto; height: auto; background: none; border: none; color: var(--ui-dim); font-size: 10px; font-weight: 600; }
.slot .n { bottom: 1px; right: 4px; font-size: 11px; font-weight: 700; color: #fff; text-shadow: 0 1px 2px #000; }
.slot img { width: 30px; height: 30px; margin: 0; }
#actions .sign { min-width: 112px; font-size: 11px; padding: 7px 12px; }
/* panneaux latéraux */
.side { color: var(--ui-text); padding: 14px; }
.side::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .15); }
.tabs div { font-family: var(--fb); font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; padding: 5px 9px; cursor: pointer; }
.tabs div.on { background: rgba(201, 165, 92, .16); border-color: var(--ui-acc); color: var(--ui-acc); }
.item { background: rgba(255, 255, 255, .03); border: 1px solid transparent; border-radius: 3px; }
.item:hover { background: rgba(255, 255, 255, .07); border-color: var(--ui-line2); }
.item.sel { border-color: var(--ui-acc); box-shadow: none; background: rgba(201, 165, 92, .1); }
.item .t { font-weight: 600; font-size: 13px; } .item .t small { color: var(--ui-dim); font-weight: 500; }
.item .cost { color: var(--ui-text); font-weight: 600; } .item .cost .lack { color: #e07a72; }
.item button.mini, #clanBody button.mini, .chestrow button, .trrow button, .trinv button, .shoprow button { background: rgba(255, 255, 255, .06); color: var(--ui-text); border: 1px solid var(--ui-line2); border-radius: 3px; font-family: var(--fb); font-weight: 600; }
#clanBody .row button { background: rgba(130, 173, 110, .2); border: 1px solid var(--ui-ok); color: #d5e8cc; font-family: var(--fb); box-shadow: none; text-shadow: none; }
#clanLeave { background: rgba(196, 90, 84, .2); border: 1px solid var(--ui-bad); color: #f0c9c5; }
.chestrow, .shoprow { border-bottom: 1px solid var(--ui-line); }
.trcol { background: rgba(255, 255, 255, .03); } .trcol h4 { font-family: var(--fb); font-weight: 700; color: var(--ui-acc); }
.trbtns .sign.ok { background: rgba(130, 173, 110, .25); background-image: none; border-color: var(--ui-ok); color: #fff; }
#shopGold { font-family: var(--fb); font-weight: 700; color: var(--ui-acc); }
#levelup h3 { font-family: var(--fh); font-weight: 700; letter-spacing: .1em; color: var(--ui-acc); text-shadow: none; }
#upgList div { color: var(--ui-text); } #upgList div:hover { transform: none; border-color: var(--ui-acc); box-shadow: none; } #upgList b { font-family: var(--fb); font-weight: 700; } #upgList small { color: var(--ui-dim); }
/* quêtes, chat, toasts, tutoriel */
#quests div { color: var(--ui-text); font-weight: 500; } #quests small { color: var(--ui-acc); font-family: var(--fb); font-weight: 700; }
#quests .pb { background: rgba(0, 0, 0, .5); } #quests .pb i { background: var(--ui-acc); }
#chatLog div { background: rgba(10, 12, 14, .72); border-color: transparent; font-size: 12.5px; } #chatLog b { color: var(--ui-acc); } #chatLog .sys { color: var(--ui-acc2); font-weight: 600; }
#chatLog div.mp { background: rgba(80, 50, 110, .5); border-color: transparent; } #chatLog div.mp b { color: #c9a8e8; }
#chatLog div.cc { background: rgba(50, 90, 50, .5); border-color: transparent; } #chatLog div.cc b { color: #a9d39a; }
#toasts div { font-family: var(--fb); font-size: 13px; font-weight: 600; border-radius: 3px; background: rgba(12, 14, 16, .88); }
#toasts div.g { color: var(--ui-acc); border-color: var(--ui-acc); box-shadow: none; }
#chatLog div.red { background: rgba(110, 16, 16, .82); border-color: rgba(255, 82, 82, .6); } #chatLog div.red .sys { color: #ff8a80; font-weight: 700; } #toasts div.red { color: #ffcdd2; background: rgba(110, 16, 16, .92); border-color: #ff5252; } /* avertissements (/reset, /resetALL : § 7.43) */
#tuto { color: var(--ui-text); font-weight: 500; }
#tuto button { background: rgba(255, 255, 255, .1); color: var(--ui-text); }
#fx span { font-weight: 600; } #fx span.bad { border-color: var(--ui-bad); color: #e9a29c; }
#bossBar .nm { font-family: var(--fh); font-weight: 700; color: #e08a83; text-shadow: 0 2px 10px rgba(0, 0, 0, .8); }
#bossBar .hb { background: rgba(0, 0, 0, .6); border: 1px solid #6b2622; border-radius: 2px; box-shadow: none; } #bossBar .hb i { background: linear-gradient(180deg, #c8504a, #8f2a26); }
#bigmap .legend { font-weight: 600; }
/* réglages */
.setmode { font-family: var(--fh); font-weight: 700; color: var(--ui-acc); text-shadow: none; }
.setrow { font-weight: 600; color: var(--ui-text); }
.setrow input[type=range], .setrow input[type=checkbox] { accent-color: var(--ui-acc); }
.ach { background: rgba(255, 255, 255, .03); border: 1px solid var(--ui-line); color: var(--ui-dim); } .ach b { color: var(--ui-text); }
.ach.ok { border-color: rgba(201, 165, 92, .5); } .ach.ok b { color: var(--ui-acc); } .ach.cur { box-shadow: 0 0 0 1px var(--ui-acc); }
.ach .pb i { background: var(--ui-acc); }
.newslist { color: var(--ui-text); } .newslist b { color: var(--ui-acc); }
/* commandes tactiles : plates */
#joy { background: rgba(0, 0, 0, .35); border: 2px solid var(--ui-line2); } #joyKnob { background: rgba(255, 255, 255, .25); border: 2px solid rgba(255, 255, 255, .4); }
#atkBtn, #dashBtn, #blockBtn, #useBtn, #tradeBtn, #horseBtn { border: 2px solid rgba(0, 0, 0, .5); box-shadow: 0 3px 10px rgba(0, 0, 0, .4); font-family: var(--fb); font-weight: 700; }
/* ----- inventaire (E) ----- */
#invPanel { width: 360px; }
.inv-eq { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-bottom: 10px; }
.inv-eq .islot { width: auto; height: 62px; flex-direction: column; }
.inv-eq .islot small { position: absolute; bottom: 3px; left: 0; right: 0; font-size: 9.5px; letter-spacing: .08em; text-transform: uppercase; color: var(--ui-dim); text-align: center; }
.inv-arm { margin: -4px 0 10px; padding: 6px 8px; border: 1px solid var(--ui-line); border-radius: 3px; background: rgba(0, 0, 0, .25); font-size: 12px; font-weight: 600; color: var(--ui-text); }
.inv-arm small { display: block; margin-top: 3px; font-size: 11px; font-weight: 500; color: #9ccc65; }
.inv-jobs { margin: -4px 0 10px; padding: 5px 7px 6px; border: 1px solid var(--ui-line); border-radius: 3px; background: rgba(0, 0, 0, .25); display: grid; grid-template-columns: 1fr 1fr; gap: 4px 10px; } /* métiers (§ 7.74) */
.inv-jobs .ijh { grid-column: 1 / -1; font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: #ffd54f; }
.inv-jobs .ij { display: grid; grid-template-columns: 18px 1fr auto; align-items: center; column-gap: 5px; font-size: 12px; color: var(--ui-text); cursor: help; }
.inv-jobs .ij .iji { width: 18px; height: 18px; }
.inv-jobs .ij b { font-size: 12px; color: #fff; }
.inv-jobs .ijb { grid-column: 1 / -1; display: block; height: 4px; margin-top: 2px; border-radius: 2px; background: rgba(255, 255, 255, .12); overflow: hidden; }
.inv-jobs .ijb i { display: block; height: 100%; }
.inv-eq .islot img, .inv-eq .islot .ico { margin-bottom: 10px; }
.inv-eq .islot.none { opacity: .5; cursor: default; }
.inv-cat { margin: 8px 0 5px; font-size: 10.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ui-dim); }
.inv-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(50px, 1fr)); gap: 5px; }
.islot { position: relative; height: 50px; display: flex; align-items: center; justify-content: center; background: rgba(0, 0, 0, .45); border: 1px solid var(--ui-line); border-radius: 3px; cursor: pointer; }
.islot:hover { border-color: rgba(255, 255, 255, .3); background: rgba(255, 255, 255, .05); }
.islot.sel { border-color: var(--ui-acc); box-shadow: inset 0 0 0 1px var(--ui-acc); }
.islot.eq::after { content: ''; position: absolute; top: 4px; right: 4px; width: 6px; height: 6px; border-radius: 50%; background: var(--ui-acc); }
.islot img { width: 32px; height: 32px; filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .6)); } .islot .ico { width: 24px; height: 24px; border-radius: 4px; }
.islot .n { position: absolute; right: 4px; bottom: 2px; font-size: 11px; font-weight: 700; color: #fff; text-shadow: 0 1px 2px #000; }
.islot .k { position: absolute; left: 4px; top: 2px; font-size: 10px; font-weight: 700; color: var(--ui-acc); }
.inv-detail { margin-top: 12px; padding: 10px; background: rgba(255, 255, 255, .04); border: 1px solid var(--ui-line); border-radius: 4px; }
.inv-dh { display: flex; gap: 10px; align-items: center; } .inv-dh img { width: 36px; height: 36px; } .inv-dh b { font-weight: 700; }
.inv-dh small { display: block; color: var(--ui-dim); font-size: 11.5px; margin-top: 2px; line-height: 1.3; }
.inv-act { display: flex; gap: 6px; margin-top: 9px; flex-wrap: wrap; }
.inv-act button, .inv-pin button { padding: 6px 11px; font-size: 11.5px; font-weight: 600; letter-spacing: .04em; background: rgba(255, 255, 255, .06); color: var(--ui-text); border: 1px solid var(--ui-line2); border-radius: 3px; }
.inv-act button:hover, .inv-pin button:hover { border-color: var(--ui-acc); }
.inv-act button[data-a="use"] { background: rgba(201, 165, 92, .18); border-color: var(--ui-acc); color: #f1e3bf; }
.inv-act button[data-a^="drop"] { color: #e8b3ad; }
.inv-pin { display: flex; align-items: center; gap: 3px; margin-top: 9px; flex-wrap: wrap; font-size: 11px; color: var(--ui-dim); }
.inv-pin span { margin-right: 4px; } .inv-pin button { padding: 3px 7px; min-width: 24px; } .inv-pin button.on { border-color: var(--ui-acc); color: var(--ui-acc); }
.inv-hint, .inv-empty { margin-top: 8px; font-size: 11.5px; color: var(--ui-dim); }
@media (max-width: 800px), (max-height: 540px) { .inv-eq .islot { height: 54px; } }
/* Inventaire façon Minecraft : équipement et fiche de l'objet à gauche, sac (10 colonnes) et barre rapide à droite */
#invPanel { width: 620px; }
.inv-wrap { display: grid; grid-template-columns: 150px 1fr; gap: 12px; align-items: start; }
.inv-side .inv-eq { grid-template-columns: 1fr 1fr; }
.inv-side .inv-eq .islot { height: 58px; }
.inv-side .inv-detail { margin-top: 0; }
.inv-side .inv-hint { margin-top: 2px; line-height: 1.4; }
.inv-main .inv-cat { display: flex; align-items: center; justify-content: space-between; margin-top: 0; }
.inv-main .inv-cat + .inv-grid + .inv-cat { margin-top: 10px; }
.inv-grid { grid-template-columns: repeat(10, 1fr); gap: 4px; }
.inv-grid .islot { height: auto; aspect-ratio: 1; min-width: 0; }
.inv-grid .islot img { width: 70%; height: 70%; } .inv-grid .islot .ico { width: 55%; height: 55%; }
.inv-grid .islot.empty { cursor: default; background: rgba(0, 0, 0, .3); }
.inv-grid .islot.empty:hover { border-color: var(--ui-line); background: rgba(0, 0, 0, .3); }
.inv-hb .islot { background: rgba(0, 0, 0, .55); }
.inv-hb .islot.off { opacity: .45; }
.islot, .slot { touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
.islot img, .slot img { pointer-events: none; -webkit-user-drag: none; }
.islot.over, .slot.over { border-color: var(--ui-acc) !important; background: rgba(201, 165, 92, .22) !important; box-shadow: inset 0 0 0 1px var(--ui-acc); }
.islot.dragging, .slot.dragging { opacity: .35; }
.dragghost { position: fixed; left: 0; top: 0; z-index: 100; width: 48px; height: 48px; pointer-events: none; display: flex; align-items: center; justify-content: center; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .6)); }
.dragghost img { width: 40px; height: 40px; } .dragghost .ico { width: 30px; height: 30px; border-radius: 5px; }
.dragghost .n { position: absolute; right: 0; bottom: 0; font: 700 12px var(--fb); color: #fff; text-shadow: 0 1px 2px #000; }
.inv-sort { padding: 2px 8px; font: 600 10px var(--fb); letter-spacing: .06em; text-transform: uppercase; background: rgba(255, 255, 255, .06); color: var(--ui-dim); border: 1px solid var(--ui-line2); border-radius: 3px; cursor: pointer; }
.side h3 { position: relative; padding-right: 34px; }
.pclose { position: absolute; right: 0; top: 50%; transform: translateY(-50%); width: 28px; height: 28px; padding: 0; border-radius: 4px; background: rgba(255, 255, 255, .06); border: 1px solid var(--ui-line2); color: var(--ui-dim); font: 600 14px/1 var(--fb); cursor: pointer; }
.pclose:hover { color: var(--ui-text); border-color: var(--ui-acc); }
.durb { position: absolute; left: 5px; right: 5px; bottom: 3px; height: 3px; border-radius: 2px; background: rgba(0, 0, 0, .65); overflow: hidden; pointer-events: none; }
.durb i { display: block; height: 100%; border-radius: 2px; }
.lg-head { display: flex; flex-direction: column; gap: 2px; margin-bottom: 8px; } .lg-head small { color: var(--ui-dim); font-size: 11.5px; }
.lg-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin: 5px 0; font-size: 11.5px; } .lg-row > span:first-child { width: 78px; color: var(--ui-dim); font-weight: 700; letter-spacing: .06em; text-transform: uppercase; font-size: 10px; }
.lg-chip { display: inline-flex; align-items: center; gap: 3px; padding: 2px 6px 2px 3px; background: rgba(0, 0, 0, .4); border: 1px solid var(--ui-line); border-radius: 3px; } .lg-chip img { width: 20px; height: 20px; } .lg-chip .ico { width: 14px; height: 14px; }
.lg-none { color: var(--ui-dim); font-style: italic; }
.lg-slot { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 4px; min-width: 96px; min-height: 30px; padding: 3px 5px; border: 1px dashed var(--ui-line2); border-radius: 4px; background: rgba(0, 0, 0, .22); cursor: grab; touch-action: none; }
.lg-slot.empty { cursor: default; } .lg-slot.over { border-color: var(--ui-acc); border-style: solid; background: rgba(255, 213, 79, .12); } .lg-slot.dragging { opacity: .5; }
.lg-fuel { width: 70px; height: 7px; border-radius: 4px; background: rgba(0, 0, 0, .55); border: 1px solid var(--ui-line); overflow: hidden; } .lg-fuel i { display: block; height: 100%; background: linear-gradient(90deg, #ff6d00, #ffd54f); }
.lg-row button, .lg-puts button { padding: 4px 9px; font-size: 11.5px; font-weight: 600; border-radius: 3px; cursor: pointer; border: 1px solid var(--ui-line2); background: rgba(255, 255, 255, .06); color: var(--ui-text); display: inline-flex; align-items: center; gap: 4px; }
.lg-puts { display: flex; flex-wrap: wrap; gap: 5px; } .lg-puts img { width: 18px; height: 18px; } .lg-puts .ico { width: 12px; height: 12px; }
.lg-row button:hover, .lg-puts button:hover { border-color: var(--ui-acc); }
.lg-tip { margin-top: 8px; font-size: 11px; color: var(--ui-dim); line-height: 1.4; }
.lg-row select { flex: 1; min-width: 0; padding: 4px 6px; font-size: 11.5px; border-radius: 3px; border: 1px solid var(--ui-line2); background: rgba(0, 0, 0, .45); color: var(--ui-text); } /* assembleur, trieur (§ 7.75) */
.lg-row.lg-pw small, .lg-row small { color: var(--ui-dim); font-size: 10.5px; }
.lg-flt { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; flex: 1; } .lg-flt .lg-chip button { padding: 0 4px; font-size: 10px; line-height: 14px; }
#rotBtn { position: absolute; left: 50%; bottom: 90px; transform: translateX(-50%); z-index: 5; padding: 9px 16px; font: 700 14px var(--fb); color: #f3e6c8; background: rgba(20, 16, 12, .85); border: 2px solid #e0b85a; border-radius: 8px; cursor: pointer; }
#rotBtn.hidden { display: none; }
body:not(.touch) #rotBtn { display: none; } /* au clavier : R */
.rp-top { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.rslot { width: 64px; height: 64px; flex: none; }
.rslot.empty small { text-align: center; font-size: 10px; line-height: 1.3; color: var(--ui-dim); }
.rslot img { width: 44px; height: 44px; }
.rp-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.rp-info small { color: var(--ui-dim); font-size: 11.5px; line-height: 1.35; }
.rp-bar { height: 8px; border-radius: 4px; background: rgba(0, 0, 0, .55); border: 1px solid var(--ui-line); overflow: hidden; }
.rp-bar i { display: block; height: 100%; background: linear-gradient(90deg, #f9a825, #8bc34a); transition: width .4s; }
.rp-info button { align-self: flex-start; padding: 5px 12px; font-size: 11.5px; font-weight: 700; border-radius: 3px; cursor: pointer; border: 1px solid var(--ui-line2); background: rgba(255, 255, 255, .06); color: var(--ui-text); }
.rp-info button.done { background: rgba(139, 195, 74, .22); border-color: #8bc34a; color: #e6f5d0; }
.rp-h { margin: 6px 0 6px; font-size: 10.5px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--ui-dim); }
.inv-sort:hover { color: var(--ui-text); border-color: var(--ui-acc); }
.inv-sorts { display: inline-flex; gap: 4px; flex: none; } /* « Trier » (par catégorie) et « A → Z » (§ 7.112) */
/* encombrement (§ 7.84) : jauge de charge du sac */
.inv-load { position: relative; display: inline-block; width: 128px; height: 16px; margin: 0 8px 0 auto; vertical-align: middle; background: rgba(0, 0, 0, .35); border: 1px solid var(--ui-line2); border-radius: 3px; overflow: hidden; }
.inv-load i { position: absolute; left: 0; top: 0; bottom: 0; background: linear-gradient(#8bc34a, #558b2f); }
.inv-load.full i { background: linear-gradient(#ef5350, #b71c1c); }
.inv-load b { position: relative; display: block; text-align: center; font: 600 10px/14px var(--fb); letter-spacing: .04em; color: #fff; text-shadow: 0 1px 1px #000; text-transform: none; }
@media (max-width: 800px), (max-height: 540px) { /* téléphone en paysage : panneau large et bas */
  #invPanel { width: min(calc(100vw - 28px), 600px); max-height: calc(100vh - 90px); }
  .inv-wrap { grid-template-columns: 130px 1fr; gap: 8px; } .inv-side .inv-eq .islot { height: 46px; } .inv-side .inv-eq .islot small { font-size: 8px; }
  .inv-grid { gap: 3px; } .inv-hint { font-size: 10.5px; } .inv-dh img { width: 28px; height: 28px; } .inv-act button { padding: 5px 8px; }
}
@media (max-width: 520px) { /* portrait : tout en colonne */
  #invPanel { width: calc(100vw - 16px); max-width: none; max-height: 62vh; }
  .inv-wrap { grid-template-columns: 1fr; } .inv-side .inv-eq { grid-template-columns: repeat(5, 1fr); } .inv-side { order: 2; } .inv-main { order: 1; }
}
#panels { bottom: 84px; } /* au-dessus de la barre rapide */
.side { max-height: calc(100vh - 200px); }
@media (max-width: 800px), (max-height: 540px) { #panels { bottom: 76px; } .side { max-height: 55vh; } }

/* ----- personnalisation du personnage (menu) ----- */
.custom { display: flex; gap: 16px; align-items: center; margin: 14px 0 12px; padding: 10px 12px; background: rgba(255, 255, 255, .03); border: 1px solid var(--ui-line); border-radius: 5px; }
#lookPrev { width: 120px; height: 120px; flex-shrink: 0; border-radius: 4px; background: radial-gradient(circle at 50% 45%, rgba(255, 255, 255, .07), transparent 70%); }
.lookopts { flex: 1; display: flex; flex-direction: column; gap: 6px; text-align: left; }
.lrow { display: flex; align-items: center; gap: 10px; }
.lrow > span { width: 66px; font-size: 10.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--ui-dim); flex-shrink: 0; }
.lrow .sw { display: flex; gap: 5px; flex-wrap: wrap; }
.lrow .skin { width: 20px; height: 20px; border-width: 1px; }
.lrow .skin.sel { transform: scale(1.12); }
.cyc { display: flex; align-items: center; gap: 8px; }
.cyc button { width: 24px; height: 24px; padding: 0; font-size: 16px; line-height: 22px; background: rgba(255, 255, 255, .06); color: var(--ui-text); border: 1px solid var(--ui-line2); border-radius: 3px; }
.cyc button:hover { border-color: var(--ui-acc); }
.cyc b { min-width: 76px; text-align: center; font-size: 12.5px; font-weight: 600; }
#lkRand { align-self: flex-start; margin-top: 2px; }
@media (max-width: 520px) { .custom { flex-direction: column; } #lookPrev { width: 96px; height: 96px; } .lrow > span { width: 58px; } }
@media (max-height: 540px) { #lookPrev { width: 84px; height: 84px; } .custom { margin: 8px 0; padding: 6px 8px; } .lrow .skin { width: 16px; height: 16px; } }

/* ----- code de sauvegarde ----- */
.setsave .savebody { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; margin-top: 8px; }
.setsave summary { cursor: pointer; color: var(--ui-dim); font-size: 12px; font-weight: 600; list-style: none; } .setsave summary::-webkit-details-marker { display: none; } .setsave summary::before { content: '▸ '; } .setsave[open] summary::before { content: '▾ '; } .setsave summary:hover { color: var(--ui-acc); }
.setsave { display: block; gap: 6px 8px; margin: 4px 0 10px; padding: 8px 10px; text-align: left; background: rgba(255, 255, 255, .03); border: 1px solid var(--ui-line); border-radius: 4px; font-size: 13px; font-weight: 600; }
.setsave .savebody > span { flex: 1 0 auto; }
.setsave code { padding: 2px 8px; background: rgba(0, 0, 0, .45); border-radius: 3px; letter-spacing: .06em; font-size: 12px; user-select: all; -webkit-user-select: all; }
.setsave button { padding: 4px 9px; font-size: 11px; font-weight: 600; background: rgba(255, 255, 255, .06); color: var(--ui-text); border: 1px solid var(--ui-line2); border-radius: 3px; }
.setsave button:hover { border-color: var(--ui-acc); }
.setsave small { flex-basis: 100%; color: var(--ui-dim); font-size: 11px; font-weight: 500; line-height: 1.35; }
.saverow { margin: -4px 0 10px; font-size: 12px; } .saverow a { color: var(--ui-dim); text-decoration: none; border-bottom: 1px dotted var(--ui-dim); } .saverow a:hover { color: var(--ui-acc); border-color: var(--ui-acc); }

/* Rendu allégé (mobiles) : pas de flou d'arrière-plan (recalculé à chaque image du jeu derrière le panneau) */
body.fast .leather, body.fast .board { backdrop-filter: none; -webkit-backdrop-filter: none; }
/* Téléphone en paysage (tactile) : la barre rapide se cale entre le joystick et les boutons de combat (5 cases, 4 sur les plus petits écrans ;
   le sac donne accès à tout), la barre du haut ne recouvre plus les jauges */
@media (max-height: 540px) {
  body.touch #hotbar { left: 178px; transform: none; bottom: 6px; }
  body.touch #hotbar .slot:nth-child(n+6) { display: none; }
  body.touch #topbar, body.touch #meteorBar { left: 222px; }
}
@media (max-height: 540px) and (max-width: 720px) { body.touch #hotbar .slot:nth-child(n+5) { display: none; } }

/* ----- Barre d'outils : boutons carrés (icône, nom, touche) ; les panneaux s'ouvrent à sa droite ----- */
#actions { left: 14px; bottom: 14px; display: grid; grid-template-columns: repeat(2, 62px); gap: 6px; align-items: start; }
#chat { bottom: 226px; } /* au-dessus de la barre d'outils */
.act { position: relative; width: 62px; height: 62px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 0;
  background: rgba(14, 16, 18, .82); border: 1px solid var(--ui-line2); border-radius: 6px; color: var(--ui-text); cursor: pointer;
  font-family: var(--fb); box-shadow: 0 4px 14px rgba(0, 0, 0, .35); transition: border-color .12s, background .12s, transform .08s; -webkit-tap-highlight-color: transparent; }
.act svg { width: 24px; height: 24px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.act .lbl { font-size: 10px; font-weight: 600; letter-spacing: .4px; text-transform: uppercase; line-height: 1; }
.act kbd { position: absolute; top: 3px; right: 3px; min-width: 15px; height: 15px; padding: 0 3px; box-sizing: border-box; border-radius: 3px;
  background: rgba(201, 165, 92, .16); border: 1px solid rgba(201, 165, 92, .55); color: var(--ui-acc); font: 700 9px/13px var(--fb); text-align: center; }
.act:hover { border-color: rgba(255, 255, 255, .38); background: rgba(30, 33, 36, .9); }
.act:active { transform: translateY(1px); }
.act.on { border-color: var(--ui-acc); color: #f3e3bd; background: rgba(48, 40, 24, .9); box-shadow: inset 0 0 0 1px var(--ui-acc), 0 0 14px rgba(201, 165, 92, .3); }
.act.hidden { display: none; }
#panels { left: 158px; bottom: 84px; }
.side { max-height: calc(100vh - 110px); }
body.touch .act kbd { display: none; } /* pas de clavier sur téléphone */
/* petit écran / téléphone en paysage : rangée de boutons en haut à droite, un peu plus petits */
@media (max-width: 800px), (max-height: 540px) {
  #actions { left: auto; right: 10px; top: 42px; bottom: auto; display: flex; flex-direction: row; gap: 5px; }
  #chat { bottom: 100px; }
  .act { width: 50px; height: 46px; gap: 2px; } .act svg { width: 20px; height: 20px; } .act .lbl { font-size: 8.5px; letter-spacing: .2px; }
  #panels { left: 14px; bottom: 76px; }
  #minimapWrap { top: 96px; }
}
@media (max-width: 520px) { /* téléphone en portrait : jauges en haut à gauche, minicarte et infos en haut à droite,
                                outils en rangée au-dessus de la barre rapide (sous le joystick), barre rapide de 5 cases */
  #minimapWrap { top: 10px; right: 8px; bottom: auto; } #minimap { width: 96px; height: 96px; }
  #topbar { left: auto; right: 8px; top: 114px; transform: none; flex-direction: column; align-items: flex-end; gap: 4px; }
  #topbar .plank { font-size: 9.5px; padding: 3px 7px; white-space: nowrap; }
  #actions { top: auto; bottom: 66px; left: 8px; right: auto; display: flex; flex-direction: row; flex-wrap: nowrap; gap: 5px; max-width: none; }
  .act { width: 50px; height: 44px; }
  #inventory { margin-top: 0; }
  #panels { left: 8px; bottom: 118px; } .side { width: calc(100vw - 16px); max-width: 360px; max-height: 50vh; }
  #meteorBar { top: 200px; left: auto; right: 8px; }
  body.touch #hotbar .slot:nth-child(n+6) { display: none; }
  #bossBar { top: 210px; width: calc(100vw - 24px); } #bossBar .nm { font-size: 15px; } #bossBar small { font-size: 10.5px; }
}
body.touch #tuto { display: none; }
#panels { z-index: 6; } /* un panneau ouvert passe devant le joystick et les boutons tactiles */ /* les conseils parlent de clavier et de souris */

#bigmap .legend { max-width: min(86vw, 660px); text-align: center; line-height: 1.5; }
#bigmap { padding-bottom: 76px; box-sizing: border-box; } #bigmap canvas { max-height: calc(100vh - 190px); } /* la légende reste au-dessus de la barre rapide */
@media (max-width: 800px), (max-height: 540px) { #bigmap { padding-bottom: 60px; } #bigmap canvas { max-height: calc(100vh - 120px); } #bigmap .legend { font-size: 10px; padding: 3px 8px; } }
body.mapopen #touch { display: none; } /* carte ouverte : pas de boutons de combat par-dessus */
@media (max-height: 540px) { /* téléphone en paysage : bannière de boss compacte sous la rangée d'outils, plus sur le joueur */
  #bossBar { top: 92px; width: min(320px, 46vw); } #bossBar .nm { font-size: 12px; } #bossBar .hb { height: 9px; } #bossBar small { font-size: 9.5px; }
}
.item .cost .stock { color: #9ccc65; font-weight: 700; }

/* ----- corrections de l'audit (docs/CONCEPTION.md § 7.5) ----- */
.joinrow { flex-wrap: nowrap; } .joinrow input { min-width: 0; } #play { flex-shrink: 0; } /* le bouton JOUER reste à l'écran sur téléphone */
.logo { font-size: clamp(28px, 10.5vw, 50px); letter-spacing: clamp(.03em, 1vw, .14em); }
.setbox { max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); overflow-y: auto; } /* réglages : défilent sur un petit écran */
#death.spec { align-items: flex-start; padding-top: 64px; background: none; pointer-events: none; }
#death.spec .deathbox { pointer-events: auto; transform: scale(.85); transform-origin: top center; }

/* ----- table d'alchimie ----- */
.al-slots { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; } .al-slot { width: 44px; height: 44px; cursor: pointer; } .al-slot.empty small { color: var(--ui-dim); } .al-slot.out { cursor: default; position: relative; } .al-arrow { color: var(--ui-dim); font-size: 18px; padding: 0 2px; }
.al-prev { margin: 4px 0 8px; font-size: 12px; color: var(--ui-text); line-height: 1.6; } .al-prev small { color: var(--ui-dim); }
.al-fx { display: inline-block; margin: 1px 3px 1px 0; padding: 0 5px; border-radius: 3px; font-size: 10.5px; font-weight: 600; color: #111; background: var(--c); } .al-fx.unk { background: rgba(255, 255, 255, .12); color: var(--ui-dim); }
.al-act { display: flex; gap: 6px; margin-bottom: 4px; } .al-act button { padding: 6px 12px; font-weight: 700; border-radius: 3px; border: 1px solid var(--ui-line2); background: rgba(255, 255, 255, .06); color: var(--ui-text); cursor: pointer; } .al-act button[disabled] { opacity: .45; cursor: default; } .al-act button:not([disabled]):hover { border-color: var(--ui-acc); }
.al-list { display: flex; flex-direction: column; gap: 4px; max-height: 34vh; overflow-y: auto; }
.al-ing { display: flex; align-items: center; gap: 8px; padding: 4px 6px; border: 1px solid var(--ui-line); border-radius: 4px; cursor: pointer; } .al-ing.sel { border-color: var(--ui-acc); background: rgba(255, 213, 79, .08); } .al-ing img { width: 26px; height: 26px; }
.al-ing .al-n { flex: 1; font-size: 12px; } .al-ing button { padding: 3px 7px; border-radius: 3px; border: 1px solid var(--ui-line2); background: transparent; cursor: pointer; }
/* conseil de performance en jeu, avertissement d'accélération matérielle dans les réglages */
.perftip { position: absolute; left: 50%; top: 64px; transform: translateX(-50%); z-index: 30; max-width: 560px; padding: 10px 14px; background: rgba(20, 22, 25, .94); border: 1px solid #f9a825; border-radius: 4px; color: #eee; font-size: 13px; line-height: 1.45; pointer-events: auto; }
.perftip b { color: #ffd54f; } .perftip button { margin: 6px 6px 0 0; padding: 4px 10px; background: #2b2f34; color: #fff; border: 1px solid #f9a825; border-radius: 3px; cursor: pointer; font: inherit; }
.setwarn { margin: 4px 0 8px; padding: 6px 8px; border: 1px solid #f9a825; border-radius: 3px; background: rgba(249, 168, 37, .12); color: #ffe082; font-size: 12px; line-height: 1.4; }
/* =====================================================================================
   Kit « gk » (§ 7.18) : cadre de bois clouté, intérieur parchemin, lettrage de jeu.
   Écran de mort (puis fenêtre d'échange, § 7.19).
   ===================================================================================== */
.gk-frame { position: relative; width: min(94vw, 440px); padding: 9px; text-align: center; color: #3a2614; border: 2px solid #1d1108; border-radius: 7px;
  background: repeating-linear-gradient(90deg, rgba(0, 0, 0, .10) 0 2px, transparent 2px 9px, rgba(255, 255, 255, .04) 9px 10px, transparent 10px 17px), linear-gradient(180deg, #7d5029, #5c3818 60%, #4a2c12);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .2), inset 0 -2px 0 rgba(0, 0, 0, .35), 0 5px 0 #140b04, 0 20px 50px rgba(0, 0, 0, .7); }
.gk-frame::before { content: ''; position: absolute; inset: 0; pointer-events: none; border-radius: 6px;
  background: radial-gradient(circle at 9px 9px, #e2c993 0 1.6px, #8a6a3a 2.4px, #24150a 3.3px, transparent 3.9px), radial-gradient(circle at calc(100% - 9px) 9px, #e2c993 0 1.6px, #8a6a3a 2.4px, #24150a 3.3px, transparent 3.9px),
    radial-gradient(circle at 9px calc(100% - 9px), #e2c993 0 1.6px, #8a6a3a 2.4px, #24150a 3.3px, transparent 3.9px), radial-gradient(circle at calc(100% - 9px) calc(100% - 9px), #e2c993 0 1.6px, #8a6a3a 2.4px, #24150a 3.3px, transparent 3.9px); }
.gk-paper { max-height: calc(92vh - 22px); overflow-y: auto; padding: 10px 14px 12px; border: 2px solid #24150a; border-radius: 3px; font-family: 'Inter', 'Segoe UI', sans-serif;
  background: radial-gradient(ellipse at 50% 0%, rgba(255, 250, 230, .55), transparent 65%), radial-gradient(ellipse at 100% 100%, rgba(150, 100, 40, .22), transparent 55%), linear-gradient(180deg, #efe1bd, #dfca9c);
  box-shadow: inset 0 0 28px rgba(120, 75, 25, .35); scrollbar-width: thin; scrollbar-color: #8a6a44 transparent; }
.gk-title { margin: 6px 0 2px; font-family: 'Pirata One', 'Cinzel', Georgia, serif; font-weight: 400; font-size: 46px; line-height: 1; letter-spacing: .01em; color: #8c1c12; transform: rotate(-2deg);
  text-shadow: 0 2px 0 #f7ecd0, 0 3px 0 rgba(60, 25, 5, .35); }
#deathArt { display: block; width: 100%; height: auto; aspect-ratio: 12 / 5; border: 2px solid #24150a; border-radius: 3px; box-shadow: 0 2px 0 rgba(255, 255, 255, .5), inset 0 0 0 1px rgba(0, 0, 0, .4); background: #2a2016; }
#death.noart #deathArt { display: none; }
#deathInfo { margin: 0 0 10px; }
.gk-by { font-size: 17px; font-weight: 600; color: #3a2614; } .gk-by b { color: #8c1c12; font-weight: 800; }
.gk-surv { margin-top: 2px; font-size: 14px; color: #5c4128; } .gk-surv b { color: #2b1a0e; font-weight: 800; } .gk-surv small { color: #7a5c3c; font-size: 12px; }
.gk-stamp { display: inline-block; margin-left: 4px; padding: 0 6px; font-family: 'Pirata One', Georgia, serif; font-size: 17px; line-height: 1.2; color: #a0261a; border: 2px solid #a0261a; border-radius: 4px; transform: rotate(-6deg); opacity: .9; }
.gk-row { display: flex; margin: 10px 0 4px; padding: 7px 0 5px; border-top: 2px dotted rgba(70, 40, 15, .35); border-bottom: 2px dotted rgba(70, 40, 15, .35); }
.gk-row > div { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 1px; } .gk-row > div + div { border-left: 1px solid rgba(70, 40, 15, .22); }
.gk-row b { font-size: 19px; font-weight: 800; color: #2b1a0e; line-height: 1.05; } .gk-row small { font-size: 11px; font-weight: 600; color: #6e5134; }
.gk-ic { width: 30px; height: 30px; image-rendering: auto; filter: drop-shadow(0 1px 0 rgba(0, 0, 0, .35)); } .gk-ic.sm { width: 18px; height: 18px; vertical-align: -4px; margin-right: 4px; }
.gk-more { margin: 4px 0 0; font-size: 12.5px; text-align: left; } .gk-more summary { cursor: pointer; text-align: center; color: #6e5134; font-weight: 700; list-style: none; }
.gk-more summary::-webkit-details-marker { display: none; } .gk-more summary::after { content: ' ▾'; } .gk-more[open] summary::after { content: ' ▴'; }
.gk-more ul { margin: 6px 4px 0; padding: 0; list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 3px 16px; }
.gk-more li { display: flex; justify-content: space-between; border-bottom: 1px dotted rgba(70, 40, 15, .3); color: #5c4128; } .gk-more li b { color: #2b1a0e; }
.gk-notes { margin-top: 8px; display: flex; flex-direction: column; gap: 3px; font-size: 12px; color: #5c4128; } .gk-notes kbd { padding: 0 4px; border: 1px solid #6e5134; border-radius: 3px; font: 700 11px 'Inter', sans-serif; }
.gk-plank { display: block; width: 100%; margin: 4px 0 6px; padding: 7px 14px 8px; font-family: 'Pirata One', Georgia, serif; font-size: 27px; line-height: 1.1; letter-spacing: .02em; color: #fbeccb; cursor: pointer;
  border: 2px solid #1d1108; border-radius: 5px; text-shadow: 0 2px 0 rgba(0, 0, 0, .55);
  background: repeating-linear-gradient(90deg, rgba(0, 0, 0, .08) 0 2px, transparent 2px 13px), linear-gradient(180deg, #b27a40, #8a5626 55%, #6e4219);
  box-shadow: inset 0 2px 0 rgba(255, 235, 190, .35), inset 0 -3px 0 rgba(0, 0, 0, .3), 0 4px 0 #1d1108, 0 7px 12px rgba(0, 0, 0, .35); transition: filter .1s, transform .05s; }
#death .gk-plank { position: sticky; bottom: 2px; z-index: 1; } /* toujours visible, même quand la carte défile (paysage, petit écran) */
.gk-plank:hover { filter: brightness(1.12); } .gk-plank:active { transform: translateY(3px); box-shadow: inset 0 2px 0 rgba(255, 235, 190, .3), 0 1px 0 #1d1108; }
.gk-plank:disabled { cursor: default; filter: grayscale(.7) brightness(.85); font-size: 19px; transform: none; }
.gk-link { background: none; border: none; padding: 2px 6px; font: 600 13px 'Inter', sans-serif; color: #6e5134; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; } .gk-link:hover { color: #2b1a0e; }
#death #specRow { color: #3a2614; }
#death.gk-in .gk-frame { animation: gk-in .45s cubic-bezier(.2, .9, .3, 1.2) both; }
@keyframes gk-in { 0% { transform: translateY(18px) scale(.94); opacity: 0; } 55% { transform: translateY(0) scale(1.01) rotate(-.6deg); opacity: 1; } 75% { transform: rotate(.5deg); } 100% { transform: none; } }
#death.spec .gk-frame { width: min(94vw, 380px); } #death.spec #deathArt, #death.spec .gk-more, #death.spec .gk-row { display: none; }
@media (max-height: 540px) { .gk-title { font-size: 34px; } #deathArt { width: auto; max-width: 100%; height: 92px; aspect-ratio: auto; margin: 0 auto; } .gk-row { margin: 6px 0 2px; padding: 4px 0 3px; } .gk-plank { font-size: 22px; padding: 4px 10px 5px; } }
@media (max-width: 420px) { .gk-paper { padding: 8px 9px 10px; } .gk-row b { font-size: 16px; } .gk-row small { font-size: 10px; } .gk-more ul { grid-template-columns: 1fr; } }
#death.spec.gk-in .gk-frame { animation: none; }

/* Donjons vivants (§ 7.17) : bandeau du boss au réveil */
#dgBanner { position: absolute; top: 63%; left: 50%; transform: translateX(-50%); text-align: center; pointer-events: none; opacity: 0; z-index: 6; white-space: nowrap; }
#dgBanner b { display: block; font-family: var(--fh, Georgia, serif); font-size: 40px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--c, #ffd54f); text-shadow: 0 3px 0 #000, 0 0 28px rgba(0, 0, 0, .95); }
#dgBanner small { display: block; margin-top: 6px; font-size: 15px; font-weight: 700; letter-spacing: .08em; color: #f1e2bf; text-shadow: 0 2px 6px #000; }
#dgBanner.show { animation: dgBanner 4.4s ease-out forwards; }
@keyframes dgBanner { 0% { opacity: 0; transform: translateX(-50%) scale(1.3); } 9% { opacity: 1; transform: translateX(-50%) scale(1); } 75% { opacity: 1; } 100% { opacity: 0; transform: translateX(-50%) scale(1); } }
@media (max-width: 700px) { #dgBanner { white-space: normal; width: calc(100vw - 24px); } #dgBanner b { font-size: 22px; } #dgBanner small { font-size: 11px; } }
/* ----- Échange (§ 7.19) : grande fenêtre au centre, même kit bois et parchemin ----- */
#trade { position: fixed; inset: 0; z-index: 19; display: flex; align-items: center; justify-content: center; background: radial-gradient(ellipse at center, rgba(8, 5, 2, .25), rgba(8, 5, 2, .55)); pointer-events: none; }
#trade .trbox { width: min(94vw, 900px); pointer-events: auto; text-align: left; }
#trade .trpaper { max-height: calc(80vh - 22px); display: flex; flex-direction: column; gap: 8px; padding: 10px 16px 12px; }
.trhead { display: flex; align-items: center; gap: 12px; } .trhead .gk-title { font-size: 34px; margin: 0; transform: rotate(-1.5deg); }
#trWith { flex: 1; font-size: 15px; font-weight: 600; color: #5c4128; } #trWith b { color: #8c1c12; font-weight: 800; }
.trx { width: 32px; height: 32px; flex: none; border-radius: 4px; border: 2px solid #24150a; background: #8a5626; color: #fbeccb; font: 800 16px 'Inter', sans-serif; cursor: pointer; box-shadow: 0 2px 0 #1d1108; } .trx:hover { filter: brightness(1.15); }
.trwarn { padding: 5px 10px; border: 2px solid #a0261a; border-radius: 4px; color: #8c1c12; font-weight: 700; font-size: 13px; background: rgba(160, 38, 26, .08); }
.trboards { display: flex; gap: 10px; align-items: stretch; }
.trboard { flex: 1; min-width: 0; border: 2px solid #6e5134; border-radius: 5px; background: rgba(255, 250, 235, .45); padding: 6px 8px 8px; box-shadow: inset 0 0 12px rgba(120, 75, 25, .18); transition: border-color .15s, background .15s; }
.trboard.drop { border-color: #2e7d32; background: rgba(120, 200, 100, .2); }
.trboard.ready { border-color: #2e7d32; box-shadow: inset 0 0 0 1px #2e7d32, inset 0 0 14px rgba(46, 125, 50, .25); }
.trbh { display: flex; justify-content: space-between; align-items: center; margin-bottom: 6px; font-size: 14px; color: #3a2614; }
.trst { font-size: 12px; font-weight: 700; padding: 1px 9px; border-radius: 10px; background: rgba(70, 40, 15, .12); color: #6e5134; } .trst.ready { background: #2e7d32; color: #fff; }
.trarrow { align-self: center; font-size: 26px; font-weight: 800; color: #6e5134; }
.trgrid { display: grid; grid-template-columns: repeat(auto-fill, 54px); gap: 6px; min-height: 58px; align-content: start; }
.trinvg { flex: 1; min-height: 124px; overflow-y: auto; padding: 5px; border: 2px dashed rgba(70, 40, 15, .3); border-radius: 5px; scrollbar-width: thin; scrollbar-color: #8a6a44 transparent; }
.trs { position: relative; width: 54px; height: 54px; border: 2px solid #24150a; border-radius: 5px; background: linear-gradient(180deg, #6b4a2c, #4f341d); box-shadow: inset 0 0 10px rgba(0, 0, 0, .5), 0 2px 0 rgba(0, 0, 0, .35); display: flex; align-items: center; justify-content: center; cursor: pointer; user-select: none; -webkit-user-select: none; transition: transform .06s; }
.trs:hover { filter: brightness(1.15); transform: translateY(-1px); } .trs:active { transform: translateY(1px); }
.trs img, .trs .ico { width: 40px; height: 40px; pointer-events: none; }
.trs .n { position: absolute; right: 3px; bottom: 2px; font: 800 13px 'Inter', sans-serif; color: #ffe8a8; text-shadow: 0 1px 2px #000, 0 0 2px #000; pointer-events: none; }
.trs .eqm { position: absolute; left: 2px; top: 0; font: 800 10px 'Inter', sans-serif; color: #ffd54f; text-shadow: 0 1px 2px #000; }
.trs .wo { position: absolute; left: 2px; top: 1px; font: 800 10px 'Inter', sans-serif; color: #ffab91; text-shadow: 0 1px 2px #000; }
.trs.ro { cursor: default; } .trs.ro:hover { filter: none; transform: none; }
.trs.new { animation: trNew .6s ease-out; } @keyframes trNew { 0% { box-shadow: 0 0 0 3px #ffd54f; } 100% { box-shadow: inset 0 0 10px rgba(0, 0, 0, .5), 0 2px 0 rgba(0, 0, 0, .35); } }
.trempty { grid-column: 1 / -1; font-size: 12px; color: #7a5c3c; font-style: italic; padding: 16px 4px; }
.trbagh { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: 14px; color: #3a2614; }
.trtabs { display: flex; gap: 4px; flex-wrap: wrap; } .trtabs button { padding: 3px 10px; border: 2px solid #6e5134; border-radius: 12px; background: transparent; color: #5c4128; font: 700 12px 'Inter', sans-serif; cursor: pointer; } .trtabs button.on { background: #6e5134; color: #fbeccb; }
#trSearch { margin-left: auto; width: 170px; padding: 4px 9px; border: 2px solid #6e5134; border-radius: 4px; background: rgba(255, 250, 235, .75); color: #2b1a0e; font: 600 13px 'Inter', sans-serif; box-shadow: none; } #trSearch:focus { outline: none; border-color: #2b1a0e; }
.trhelp { font-size: 11.5px; color: #7a5c3c; }
.trnote { min-height: 18px; font-size: 13.5px; font-weight: 700; color: #5c4128; text-align: center; } .trnote.go { color: #2e7d32; } .trnote.bad { color: #a0261a; }
.trfoot { display: flex; align-items: center; gap: 14px; } #trade .trfoot .gk-plank { flex: 1; margin: 0; position: static; }
.gk-plank.okd { background: repeating-linear-gradient(90deg, rgba(0, 0, 0, .08) 0 2px, transparent 2px 13px), linear-gradient(180deg, #74b34c, #4b8a2f 55%, #3a6e22); }
@media (max-width: 700px), (max-height: 520px) {
  #trade .trbox { width: 100vw; height: 100vh; border-radius: 0; padding: 5px; } #trade .gk-frame::before { display: none; }
  #trade .trpaper { max-height: none; height: 100%; padding: 8px 10px; gap: 6px; } .trhead .gk-title { font-size: 26px; }
  .trboards { flex-direction: column; gap: 6px; } .trarrow { display: none; } .trgrid { grid-template-columns: repeat(auto-fill, 48px); gap: 5px; min-height: 50px; }
  .trs { width: 48px; height: 48px; } .trs img, .trs .ico { width: 34px; height: 34px; } #trSearch { width: 120px; } .trhelp { display: none; }
}
/* quêtes (§ 7.21) : compteur « 1 / 3 » et flash quand une quête avance */
#quests .qn { font-weight: 800; color: var(--ui-acc); font-variant-numeric: tabular-nums; white-space: nowrap; }
#quests .pb { height: 6px; } #quests .pb i { transition: width .35s ease-out; }
#quests div.qup { animation: qUp .9s ease-out; } @keyframes qUp { 0% { box-shadow: 0 0 0 2px #ffd54f, 0 0 16px rgba(255, 213, 79, .8); transform: scale(1.04); } 100% { box-shadow: none; transform: none; } }
/* états (§ 7.23) : halos sur les bords de l'écran, au-dessus du jeu, sous l'interface */
#statusFx { position: fixed; inset: 0; pointer-events: none; z-index: 1; opacity: 0; transition: opacity .4s; }
#statusFx.poison { opacity: 1; background: radial-gradient(ellipse at center, transparent 55%, rgba(90, 200, 60, .38) 100%); animation: fxPulse 1.6s ease-in-out infinite; }
#statusFx.starve { opacity: 1; background: radial-gradient(ellipse at center, transparent 50%, rgba(150, 10, 10, .5) 100%); animation: fxBeat 1.1s ease-in-out infinite; }
#statusFx.poison.starve { background: radial-gradient(ellipse at center, transparent 50%, rgba(150, 10, 10, .45) 88%, rgba(90, 200, 60, .45) 100%); }
@keyframes fxPulse { 0%, 100% { filter: brightness(.85); } 50% { filter: brightness(1.25); } }
@keyframes fxBeat { 0%, 60%, 100% { opacity: .65; } 15%, 35% { opacity: 1; } }
.bar.blink { animation: barBlink .8s steps(2, start) infinite; } @keyframes barBlink { to { filter: brightness(1.8) saturate(1.4); } }
/* jauges plus grandes (§ 7.23) : lisibles d'un coup d'œil, texte en 13 px sur ordinateur */
#stats { width: 260px; gap: 6px; }
.bar { height: 23px; margin-left: 28px; border-radius: 3px; }
.bar span { font-size: 12.5px; letter-spacing: .07em; }
.bar .bi { left: -28px; top: 0; width: 22px; height: 22px; font-size: 16px; }
.bar.xp { height: 16px; } .bar.xp span { font-size: 11px; } .bar.xp .bi { width: 20px; height: 20px; top: -2px; font-size: 14px; }
@media (max-width: 800px), (max-height: 540px) {
  #stats { width: 200px; gap: 4px; }
  .bar { height: 18px; margin-left: 22px; } .bar span { font-size: 10.5px; }
  .bar .bi { left: -22px; width: 18px; height: 18px; font-size: 13px; }
  .bar.xp { height: 13px; } .bar.xp span { font-size: 9.5px; } .bar.xp .bi { width: 16px; height: 16px; font-size: 11px; }
}
@media (max-width: 520px) { #stats { width: 170px; } }
/* fenêtre basse sans écran tactile (cadre de CrazyGames : 907 × 510, 821 × 462, § 7.125) : la barre du haut commençait à 180 px, sur la fin des
   jauges (200 px de large depuis 14 px) ; elle part après elles, comme sur téléphone */
@media (max-height: 540px) and (min-width: 521px) { #topbar, #meteorBar { left: 222px; } }
/* coffre (§ 7.25) : fenêtre au centre comme l'échange, deux grilles, glisser-déposer */
#chestWin { position: fixed; inset: 0; z-index: 18; display: flex; align-items: center; justify-content: center; pointer-events: none; }
#chestWin .trbox { width: min(94vw, 760px); pointer-events: auto; text-align: left; }
#chestWin .trpaper { max-height: calc(84vh - 22px); display: flex; flex-direction: column; gap: 8px; padding: 10px 16px 12px; }
.chgrid { min-height: 116px; max-height: 31vh; overflow-y: auto; scrollbar-width: thin; scrollbar-color: #8a6a44 transparent; }
.chcap { position: relative; flex: 1; max-width: 240px; height: 18px; margin-left: auto; border: 2px solid #6e5134; border-radius: 9px; background: rgba(70, 40, 15, .15); overflow: hidden; }
.chcap i { position: absolute; left: 0; top: 0; bottom: 0; background: linear-gradient(180deg, #d6b25a, #9a7426); transition: width .2s; }
.chcap.full i { background: linear-gradient(180deg, #d0574a, #8c1c12); }
.chcap b { position: relative; display: block; text-align: center; font: 700 11.5px/14px 'Inter', sans-serif; color: #2b1a0e; }
#chTakeAll { font-size: 13px; }
.trinvg.drop { border-color: #2e7d32; background: rgba(120, 200, 100, .2); }
#chSearch { margin-left: auto; width: 170px; padding: 4px 9px; border: 2px solid #6e5134; border-radius: 4px; background: rgba(255, 250, 235, .75); color: #2b1a0e; font: 600 13px 'Inter', sans-serif; box-shadow: none; } #chSearch:focus { outline: none; border-color: #2b1a0e; }
#chestWin .trfoot { justify-content: space-between; } #chestWin .trfoot .trhelp { flex: 1; } #chestWin .trfoot .gk-plank { flex: none; width: auto; margin: 0; position: static; padding: 6px 22px; font-size: 18px; }
/* enchantement (§ 7.27) : fenêtre au centre, objets à gauche, gemme et offres à droite */
#encWin { position: fixed; inset: 0; z-index: 18; display: flex; align-items: center; justify-content: center; pointer-events: none; }
#encWin .trbox { width: min(94vw, 820px); pointer-events: auto; text-align: left; }
#encWin .trpaper { max-height: calc(86vh - 22px); display: flex; flex-direction: column; gap: 8px; padding: 10px 16px 12px; }
.encsh { flex: 1; font-size: 14px; font-weight: 700; color: #5c4128; }
.encbody { display: flex; gap: 10px; min-height: 300px; }
.encleft { flex: 0 0 300px; overflow-y: auto; max-height: 52vh; }
.encright { flex: 1; display: flex; flex-direction: column; gap: 8px; }
#encItems .trs.sel { border-color: #7b3fbf; box-shadow: 0 0 0 2px #b388ff, inset 0 0 10px rgba(0, 0, 0, .5); }
.enccard { display: flex; gap: 10px; align-items: center; min-height: 58px; color: #3a2614; }
.enccard img, .enccard .ico { width: 48px; height: 48px; }
.enccard b { font-size: 15px; } .enccard small { display: block; color: #6e5134; font-size: 12px; margin-top: 2px; }
.encgems { display: flex; gap: 6px; }
.encgems button { flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 5px 6px; border: 2px solid #6e5134; border-radius: 5px; background: rgba(255, 250, 235, .55); color: #3a2614; font: 700 13px 'Inter', sans-serif; cursor: pointer; }
.encgems button img { width: 22px; height: 22px; } .encgems button.on { background: #6e5134; color: #fbeccb; } .encgems button.none { opacity: .5; }
.encoffers { display: flex; flex-direction: column; gap: 6px; }
.encoff { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border: 2px solid #6e5134; border-radius: 5px; background: rgba(255, 250, 235, .5); color: #3a2614; }
.encoff .lv { font: 800 18px 'Inter', sans-serif; width: 34px; text-align: center; color: #7b3fbf; }
.encoff .tx { flex: 1; } .encoff .tx b { font-size: 14px; } .encoff .tx small { display: block; font-size: 12px; color: #6e5134; }
.encoff .cost { display: flex; gap: 6px; font-size: 12px; font-weight: 700; } .encoff .cost span { display: flex; align-items: center; gap: 2px; } .encoff .cost img { width: 18px; height: 18px; } .encoff .cost .no { color: #b71c1c; }
.encoff button { padding: 5px 12px; border: 2px solid #24150a; border-radius: 4px; background: #7b3fbf; color: #fff; font: 800 13px 'Inter', sans-serif; cursor: pointer; } .encoff button:disabled { background: #9e9e9e; cursor: default; }
.encoff.locked { opacity: .55; } .encerr { padding: 10px; color: #8c1c12; font-weight: 700; font-size: 13px; }
.encfoot { display: flex; justify-content: flex-end; }
/* Sorts du bâton en main (§ 7.35, lots 1 et 4) : trois cases au-dessus de la barre rapide, G V X ou clic ; verrouillé : gris et cadenas */
#spellBar { position: absolute; bottom: 80px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; pointer-events: auto; user-select: none; }
#spellBar.hidden, #spellBar .sp.hidden { display: none; }
#spellBar .sp { position: relative; display: flex; align-items: center; gap: 7px; padding: 5px 9px 5px 7px; border-radius: 6px; overflow: hidden; max-width: 210px; cursor: pointer;
  background: linear-gradient(180deg, rgba(55, 30, 120, .92), rgba(22, 12, 58, .94)); border: 1px solid #b388ff; color: #ede7f6; font: 700 12.5px var(--fb);
  box-shadow: 0 0 12px rgba(124, 77, 255, .4), 0 3px 0 #0d0626; }
#spellBar .sk-ic { position: relative; min-width: 15px; text-align: center; font: 700 13px var(--fh); color: #e1bee7; text-shadow: 0 0 8px #b388ff, 0 0 2px #fff; }
#spellBar .t { position: relative; display: flex; flex-direction: column; line-height: 1.15; min-width: 0; }
#spellBar b { font-weight: 800; letter-spacing: .3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#spellBar small { font-size: 10.5px; color: #c5b3ec; font-weight: 600; white-space: nowrap; }
#spellBar kbd { position: relative; min-width: 18px; height: 18px; padding: 0 4px; box-sizing: border-box; border-radius: 3px; background: rgba(179, 136, 255, .18); border: 1px solid rgba(179, 136, 255, .7); color: #e1bee7; font: 800 11px/16px var(--fb); text-align: center; }
#spellBar .cdm { position: absolute; left: 0; top: 0; bottom: 0; width: 0; background: rgba(0, 0, 0, .5); transition: width .25s linear; }
#spellBar .sp.cd { border-color: #5e4b8b; box-shadow: 0 3px 0 #0d0626; } #spellBar .sp.cd .sk-ic { color: #7e6aa8; text-shadow: none; }
#spellBar .sp.nomana small { color: #ff8a80; }
#spellBar .sp.ready { border-color: #d1b3ff; }
#spellBar .sp.lock { background: rgba(22, 20, 30, .9); border-color: #4a4458; color: #8f8a99; box-shadow: 0 3px 0 #0b0a10; cursor: help; }
#spellBar .sp.lock .sk-ic { color: #6f6a79; text-shadow: none; } #spellBar .sp.lock small { color: #b0a8bd; } #spellBar .sp.lock kbd { border-color: #4a4458; color: #8f8a99; background: none; }
#spellBar .sp.fresh { animation: skPulse .9s ease-in-out 3; }
@keyframes skPulse { 50% { box-shadow: 0 0 22px rgba(179, 136, 255, .85), 0 3px 0 #0d0626; } }
body.touch #spellBar { bottom: 70px; } body.touch #spellBar .sp { font-size: 11px; padding: 4px 7px; } body.touch #spellBar kbd { display: none; }

/* Talents (K) : arbre radial dessiné sur un canvas, info-bulle HTML (docs/CONCEPTION.md § 7.26) */
#talPanel { width: auto; position: relative; }
#talCv { display: block; margin: 0 auto; }
#talHint, #talBody .hint { font-size: 11px; color: var(--ui-dim); margin: 8px auto 0; text-align: center; line-height: 1.4; max-width: 560px; }
#talHint b { color: #e9c77a; font-family: 'Cinzel', Georgia, serif; }
#talCv { filter: drop-shadow(0 10px 22px rgba(0, 0, 0, .55)); } /* astrolabe des talents (§ 7.53) */
.talTip { --tc: #d6ad5c; position: absolute; z-index: 5; width: 240px; pointer-events: none; background: linear-gradient(180deg, rgba(30, 24, 18, .98), rgba(14, 12, 10, .98)); border: 1px solid rgba(214, 173, 92, .55); border-top: 3px solid var(--tc); border-radius: 6px; padding: 8px 10px 9px; font-size: 12px; line-height: 1.4; box-shadow: 0 8px 24px rgba(0, 0, 0, .6), inset 0 1px 0 rgba(255, 235, 190, .08); }
.talTip b { color: #f3dfae; font-family: 'Cinzel', Georgia, serif; letter-spacing: .02em; } .talTip b .ei { width: 18px; height: 18px; vertical-align: -4px; margin-right: 4px; } .talTip .rk { color: var(--ui-dim); font-size: 11px; }
.talTip .st { display: block; margin-top: 4px; font-size: 11px; color: var(--ui-dim); } .talTip .st.ok { color: var(--ui-ok); } .talTip .st.no { color: var(--ui-bad); } .talTip .st.has { color: var(--gold); }

/* Intro animée (docs/CONCEPTION.md § 7.40) : au-dessus de tout avant le menu ; le logo du menu reste caché tant qu'elle joue (les lettres de l'intro viennent s'y poser) */
#intro { position: fixed; inset: 0; z-index: 200; background: #050607; cursor: pointer; transition: opacity .3s ease-out; }
#intro canvas { position: absolute; inset: 0; display: block; width: 100%; height: 100%; }
#intro .skip { position: absolute; right: 22px; bottom: 18px; font: 600 11px 'Inter', system-ui, sans-serif; letter-spacing: .3em; text-transform: uppercase; color: rgba(230, 225, 214, .55); opacity: 0; animation: introSkip .5s .9s forwards; pointer-events: none; }
#intro .skip b { color: #c9a55c; font-weight: 700; }
#intro.out .skip { animation: none; opacity: 0; transition: opacity .25s; }
#intro.bye { opacity: 0; pointer-events: none; }
@keyframes introSkip { to { opacity: 1; } }
body.intro-on #menu .logo { visibility: hidden; }

/* =====================================================================================
   HUD ergonomique (docs/CONCEPTION.md § 7.41) — ordinateur. Le HUD est un conteneur de requêtes (@container hud) qu'on agrandit
   avec Réglages → Taille de l'interface (zoom) : seuils et hauteurs (unités cq*) suivent la taille choisie. Sur téléphone, les
   conteneurs #topStack, #rightCol et #aboveBar s'effacent (display: contents) : la disposition tactile ne change pas.
   ===================================================================================== */
#hud { container: hud / size; zoom: var(--hudZ, 1); }
#topStack, #rightCol, #aboveBar { display: contents; }
#heldName, #netInfo, #lbMe { display: none; }
.bar .lag { position: absolute; left: 0; top: 0; bottom: 0; width: 100%; border-radius: inherit; background: rgba(255, 238, 205, .78); transition: width .45s ease-in .35s; } /* dégâts récents : la part perdue reste pâle puis fond */
.bar .lag.now { transition: none; }
#statusFx.lowhp { opacity: 1; background: radial-gradient(ellipse at center, transparent 56%, rgba(165, 0, 0, .46) 100%); animation: fxBeat .9s ease-in-out infinite; }
#statusFx.lowhp.poison, #statusFx.lowhp.starve { background: radial-gradient(ellipse at center, transparent 52%, rgba(165, 0, 0, .5) 100%); }
@container hud (min-width: 801px) and (min-height: 541px) {
  /* haut centre : une pile (mode, boss, échange, niveau, météore, tutoriel, messages) */
  #topStack { display: flex; flex-direction: column; align-items: center; gap: 6px; position: absolute; top: 12px; left: 50%; transform: translateX(-50%); width: min(600px, calc(100cqw - 640px)); min-width: 300px; pointer-events: none; z-index: 3; }
  #topStack > * { position: relative !important; inset: auto !important; transform: none !important; margin: 0 !important; max-width: 100%; box-sizing: border-box; pointer-events: auto; }
  #topStack > #bossBar { width: 420px; pointer-events: none; }
  #topStack > #toasts { pointer-events: none; }
  #topStack > #tuto { width: 100%; }
  /* haut droite : classement (+ « Toi »), fil des victimes, quêtes, empilés */
  #rightCol { display: flex; flex-direction: column; align-items: stretch; gap: 8px; position: absolute; right: 14px; top: 14px; width: 200px; max-height: calc(100cqh - 14px - 188px - 6px - 80px - 10px); overflow: hidden; pointer-events: none; } /* s'arrête au-dessus du bandeau de lieu (3 rangées au plus) */
  #rightCol > * { position: relative !important; inset: auto !important; transform: none !important; margin: 0 !important; width: auto !important; }
  #rightCol > #leaderboard { pointer-events: auto; }
  #rightCol > #killfeed, #rightCol > #quests { pointer-events: none; }
  #rightCol > #killfeed:empty, #rightCol > #quests:empty { display: none; }
  #rightCol > #leaderboard, #rightCol > #killfeed { flex: none; } #rightCol > #quests { flex: 0 1 auto; min-height: 0; overflow: hidden; } /* les quêtes cèdent la place (une carte qui ne tient pas entière se cache) */
  #lbMe { display: flex; justify-content: space-between; gap: 6px; margin-top: 6px; padding-top: 5px; border-top: 1px solid var(--ui-line); font-size: 11px; color: var(--ui-dim); }
  #lbMe b { color: var(--ui-acc); font-weight: 700; }
  /* bas droite : où et quand, collé au-dessus de la minicarte */
  #topbar { top: auto; left: auto; right: 14px; bottom: calc(14px + 188px + 6px); transform: none; width: 188px; flex-wrap: wrap; justify-content: center; gap: 4px; pointer-events: none; }
  #topbar .plank { padding: 3px 7px; font-size: 10.5px; letter-spacing: .05em; white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; box-sizing: border-box; }
  #topbar #score { display: none; }
  #topbar #netInfo { display: block; color: var(--ui-dim); font-variant-numeric: tabular-nums; } #topbar #netInfo.off { display: none; }
  /* bas centre : au-dessus de la barre rapide, le nom de l'objet en main puis la compétence du bâton */
  #aboveBar { display: flex; flex-direction: column; align-items: center; gap: 6px; position: absolute; left: 50%; bottom: 84px; transform: translateX(-50%); pointer-events: none; }
  #aboveBar > * { position: relative !important; inset: auto !important; transform: none !important; }
  #aboveBar > #spellBar { pointer-events: auto; }
  #heldName { display: block; padding: 3px 12px; border-radius: 3px; background: rgba(10, 12, 14, .72); border: 1px solid var(--ui-line); color: var(--ui-text); font: 600 12.5px var(--fb); letter-spacing: .03em; white-space: nowrap; opacity: 0; transition: opacity .4s; }
  #heldName.on { opacity: 1; transition: opacity .1s; }
  #heldName small { margin-left: 7px; color: var(--ui-dim); font-weight: 500; } #heldName small.low { color: #e9a29c; }
  /* bas gauche : dock de 2 rangées de 4 ; le chat juste au-dessus ; les fenêtres s'ouvrent au-dessus du dock */
  #actions { grid-template-columns: repeat(4, 52px); gap: 5px; }
  .act { width: 52px; height: 52px; gap: 3px; } .act svg { width: 21px; height: 21px; } .act .lbl { font-size: 8.5px; letter-spacing: .02em; } .act kbd { top: 2px; right: 2px; }
  #chat { bottom: 133px; }
  #chatLog { max-height: min(240px, calc(100cqh - 133px - 190px)); }
  #chat.open #chatLog { max-height: calc(100cqh - 133px - 190px); }
  #panels { left: 14px; bottom: 133px; }
  .side { max-height: calc(100cqh - 133px - 165px); }
  #hud:has(#panels > .side:not(.hidden):not(#talPanel)) #chat:not(.open) #chatLog { visibility: hidden; } /* une fenêtre ouverte : le chat s'efface (Entrée le rouvre) */
  /* talents (K) : au milieu de l'écran, à sa taille */
  #panels > #talPanel { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); max-height: calc(100cqh - 24px); z-index: 6; }
  /* grande carte : unités du conteneur, pour tenir avec une grande taille d'interface */
  #bigmap canvas { max-width: 86cqw; max-height: calc(100cqh - 190px); }
}
@container hud (min-width: 801px) and (max-width: 1039px) and (min-height: 541px) {
  /* écran étroit (ou grande taille d'interface) : le dock repasse en 2 colonnes, les fenêtres s'ouvrent à sa droite */
  #actions { grid-template-columns: repeat(2, 52px); }
  #chat { bottom: 247px; }
  #chatLog, #chat.open #chatLog { max-height: calc(100cqh - 247px - 190px); }
  #panels { left: 133px; bottom: 84px; }
  .side { max-height: calc(100cqh - 84px - 165px); }
}
/* Peaufinage de la Survie (§ 7.114) */
@container hud (min-width: 801px) and (min-height: 541px) {
  /* saison, météo et heure : sur deux lignes plutôt que « PRINTEMPS · PLUIE · JOU… » ; la colonne de droite laisse la place */
  #topbar #clock { white-space: normal; line-height: 1.3; text-align: center; }
  #rightCol { max-height: calc(100cqh - 14px - 188px - 6px - 96px - 10px); }
  #topStack > #toasts { width: auto; max-width: 100%; } /* (dans la pile du haut : sa largeur) */
}
#chatLog div.cut { display: none; } /* chat fermé : un vieux message coupé par le haut s'efface en entier (game.js, chatTrim) */
#hud #quests div:not(.chr) .qn, #hud #quests div.ctr small { color: #8a5a10; } /* avancée « 0 / 25 » et prime « +15 or » : de l'or foncé sur le parchemin (le jaune clair ne se lisait pas) */
#toasts { width: max-content; max-width: calc(100vw - 24px); } /* centré à 50 % : sans largeur propre, il n'avait que la moitié de l'écran (7 lignes sur téléphone) */
#toasts div { max-width: 100%; box-sizing: border-box; text-align: center; }
@media (max-width: 520px) { /* téléphone en portrait, en Survie : plus rien ne se chevauche en haut de l'écran */
  body.surv #topbar { top: 126px; max-width: 48vw; flex-direction: row; flex-wrap: wrap; justify-content: flex-end; } /* sous le cadre de la minicarte (10 + 110 + 6) ; lieu et position côte à côte */
  body.surv #topbar .plank { white-space: normal; text-align: right; line-height: 1.25; }
  body.surv #fx { max-width: calc(52vw - 30px); } /* les effets s'arrêtent avant la colonne de droite */
  /* bandeaux (boss, météore, échange, niveau, messages) : une pile sous les deux colonnes, l'un sous l'autre */
  body.surv #topStack { display: flex; flex-direction: column; align-items: center; gap: 5px; position: absolute; top: 236px; left: 10px; right: 10px; pointer-events: none; z-index: 3; }
  body.surv #topStack > * { position: relative !important; inset: auto !important; transform: none !important; margin: 0 !important; max-width: 100%; box-sizing: border-box; pointer-events: auto; }
  body.surv #topStack > #bossBar, body.surv #topStack > #toasts { pointer-events: none; }
  body.surv #topStack > #bossBar { width: 100%; }
  body.surv #toasts { max-width: 100%; gap: 4px; }
  body.surv #toasts div { font-size: 11.5px; padding: 3px 10px; letter-spacing: .02em; }
  body.surv #toasts div:nth-last-child(n+3) { display: none; } /* deux messages au plus : le joueur, au milieu de l'écran, reste visible */
  /* onglets de l'artisanat et de Bâtir : une seule rangée qui défile du doigt (13 onglets prenaient 4 rangées, il ne restait que 2 recettes à l'écran) ; le bord droit s'estompe : il y en a d'autres */
  .side .tabs { flex-wrap: nowrap; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; padding-right: 26px; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 30px), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 30px), transparent); }
  .side .tabs::-webkit-scrollbar { display: none; }
  .side .tabs div { flex: none; }
}
@media (max-height: 540px) and (min-width: 521px) { /* téléphone en paysage, en Survie */
  body.surv #topbar { right: 8px; flex-wrap: nowrap; justify-content: flex-start; } /* une seule rangée : elle passait sous les boutons (78 % et la position coupés) */
  body.surv #topbar .plank { white-space: nowrap; flex: none; font-size: 10px; }
  body.surv #topbar #score { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; } /* le score (images/s, ping) cède la place à l'heure et au lieu */
  body.surv #toasts { top: auto; bottom: 76px; left: 180px; transform: none; width: auto; max-width: min(360px, calc(100vw - 500px)); flex-direction: column; align-items: center; } /* au-dessus de la barre rapide, entre le joystick et les boutons : plus caché derrière */
  body.surv #toasts div { font-size: 11px; padding: 3px 9px; letter-spacing: .02em; }
  body.surv #toasts div:nth-last-child(n+3) { display: none; }
  body.surv #bossBar { left: 230px; transform: none; width: min(300px, calc(100vw - 540px)); } /* entre les effets (à gauche) et les boutons tactiles : le compte à rebours ne passe plus sous le fer à cheval */
}

/* Endurance vide : la barre clignote (§ 7.29) */
.bar.stamina.empty .fill { animation: stBlink .5s steps(2, start) infinite; }
@keyframes stBlink { to { opacity: .25; } }

/* Posture du boss (§ 7.29, lot 2) : fine barre dorée sous sa vie ; elle clignote quand il est brisé */
#bossBar .pst { width: 72%; height: 4px; margin: 3px auto 0; background: rgba(0, 0, 0, .55); border-radius: 2px; overflow: hidden; }
#bossBar .pst i { display: block; height: 100%; background: linear-gradient(90deg, #b8913f, #ffe082); transition: width .2s; }
#bossBar .pst.brk i { background: #fff3c4; animation: barBlink .5s steps(2, start) infinite; }

/* Mes gardes (§ 7.30) : une carte par garde, rang en étoiles, barre d'expérience, emplacements d'arme et d'armure */
#guardBody { display: flex; flex-direction: column; gap: 8px; max-height: min(62vh, 560px); overflow-y: auto; padding-right: 2px; }
#guardBody .gd-card { background: rgba(0, 0, 0, .22); border: 1px solid rgba(255, 224, 160, .18); border-radius: 8px; padding: 8px 9px; }
#guardBody .gd-top { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; }
#guardBody .gd-top b { font-size: 15px; color: #fff3d6; }
#guardBody .gd-top small { margin-left: auto; color: #d7c3a0; font-size: 11px; }
#guardBody .gd-stars { color: #ffd54f; letter-spacing: 1px; font-size: 13px; }
#guardBody .gd-stars i { font-style: normal; color: rgba(255, 255, 255, .18); }
#guardBody .gd-xp { position: relative; height: 13px; margin: 6px 0 5px; background: rgba(0, 0, 0, .45); border-radius: 7px; overflow: hidden; }
#guardBody .gd-xp i { display: block; height: 100%; background: linear-gradient(90deg, #b8913f, #ffd54f); }
#guardBody .gd-xp span { position: absolute; inset: 0; text-align: center; font-size: 10px; line-height: 13px; color: #fff; text-shadow: 0 1px 2px #000; }
#guardBody .gd-stats { display: flex; gap: 10px; font-size: 12px; color: #f1e4c8; margin-bottom: 6px; }
#guardBody .gd-slots { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
#guardBody .gd-slot { display: flex; align-items: center; gap: 6px; padding: 4px 6px; border-radius: 6px; background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .1); cursor: pointer; min-width: 0; }
#guardBody .gd-slot:hover, #guardBody .gd-slot.on { border-color: #ffd54f; background: rgba(255, 213, 79, .12); }
#guardBody .gd-slot.empty { border-style: dashed; }
#guardBody .gd-slot .ico, #guardBody .gd-pick .ico { width: 28px; height: 28px; flex: none; }
#guardBody .gd-no { width: 28px; height: 28px; flex: none; display: grid; place-items: center; opacity: .45; font-size: 16px; }
#guardBody .gd-slot .t { display: flex; flex-direction: column; min-width: 0; font-size: 12px; }
#guardBody .gd-slot .t b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#guardBody .gd-slot small, #guardBody .gd-pick small { color: #cdb894; font-size: 10.5px; }
#guardBody .gd-trait { margin-top: 5px; font-size: 11px; color: #b9a684; font-style: italic; }
#guardBody .gd-pick { margin-top: 6px; display: flex; flex-direction: column; gap: 3px; border-top: 1px solid rgba(255, 255, 255, .1); padding-top: 6px; }
#guardBody .gd-pick .item { display: flex; align-items: center; gap: 7px; padding: 3px 6px; border-radius: 5px; cursor: pointer; font-size: 12px; }
#guardBody .gd-pick .item:hover { background: rgba(255, 213, 79, .14); }
#guardBody .gd-pick .item .t { display: flex; flex-direction: column; }
#guardBody .gd-empty { font-size: 12px; color: #d7c3a0; }
#guardBody .gd-trait.on { font-style: normal; color: #ffe8a3; }
#guardBody .gd-trait.choose { font-style: normal; color: #ffd54f; display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
#guardBody .gd-trait.choose span { grid-column: 1 / -1; }
#guardBody .gd-trait.choose button { display: flex; flex-direction: column; gap: 2px; text-align: left; padding: 5px 7px; border-radius: 6px; border: 1px solid rgba(255, 213, 79, .5); background: rgba(255, 213, 79, .1); color: #fff3d6; cursor: pointer; font: inherit; }
#guardBody .gd-trait.choose button:hover { background: rgba(255, 213, 79, .22); }
#guardBody .gd-trait.choose small { color: #d7c3a0; font-size: 10.5px; }
#guardBody .gd-post { margin-top: 6px; display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 11px; color: #b9a684; } /* caserne (§ 7.30, lot 4) */
#guardBody .gd-post.on { color: #ffe8a3; }
#guardBody .gd-post button { padding: 3px 10px; border-radius: 6px; border: 1px solid rgba(255, 213, 79, .5); background: rgba(255, 213, 79, .1); color: #fff3d6; cursor: pointer; font: inherit; font-weight: 700; }
#guardBody .gd-post button:hover { background: rgba(255, 213, 79, .22); }

/* Meule (§ 7.27, lot 3) */
#grindBody .gr-item { display: flex; align-items: center; gap: 8px; padding: 5px 6px; border-radius: 6px; background: rgba(0, 0, 0, .2); margin-bottom: 5px; }
#grindBody .gr-item .t { flex: 1; min-width: 0; font-size: 12px; display: flex; flex-direction: column; }
#grindBody .gr-item .t small { color: #cdb894; font-size: 10.5px; }
#grindBody .gr-item .t small.curse { color: #ff8a80; }
#grindBody .gr-item button { flex: none; padding: 4px 9px; border-radius: 5px; border: 1px solid rgba(255, 213, 79, .5); background: rgba(255, 213, 79, .12); color: #fff3d6; cursor: pointer; font: inherit; font-size: 12px; }
#grindBody .gr-item button:hover { background: rgba(255, 213, 79, .25); }
#grindBody .gr-empty { font-size: 12px; color: #d7c3a0; }
/* Pseudo obligatoire : message sous le champ, champ en rouge qui tremble ; numéros des joueurs (#12) au classement et dans le chat */
.nameErr { margin: 6px 0 0; padding: 6px 10px; border-radius: 4px; background: rgba(183, 28, 28, .82); color: #fff; font-family: var(--fb); font-size: 13px; font-weight: 600; text-align: left; }
.joinrow input.bad, .joinrow input.bad:focus { border-color: #ef5350; box-shadow: 0 0 0 2px rgba(239, 83, 80, .45); }
.joinrow input.shake { animation: nameShake .35s ease-in-out; } @keyframes nameShake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }
.pno { margin-left: 3px; font-size: .78em; font-weight: 600; opacity: .62; }

/* =====================================================================================
   Thème forgé (§ 7.49) : l'interface prend la matière du jeu. Bois sombre veiné et clouté, laiton, parchemin ;
   titres en Pirata One, étiquettes en Cinzel ; icônes dessinées par art.js (ART.ui) à la place des pictogrammes
   génériques et des emojis. Ne touche qu'à l'aspect (couleurs, matières, polices), jamais aux positions du § 7.41.
   ===================================================================================== */
:root {
  --fw-wood: linear-gradient(180deg, #4a2d15, #35200e 60%, #2a180a);
  --fw-wood-l: linear-gradient(180deg, #8a5a2c, #6b4320 55%, #563417);
  --fw-grain: repeating-linear-gradient(90deg, rgba(0, 0, 0, .10) 0 2px, transparent 2px 9px, rgba(255, 255, 255, .035) 9px 10px, transparent 10px 17px);
  --fw-rv: #f0cf86 0 1.2px, #8a6a3a 1.9px, #170c04 2.7px, transparent 3.2px;
  --fw-rivets: radial-gradient(circle at 6px 6px, var(--fw-rv)), radial-gradient(circle at calc(100% - 6px) 6px, var(--fw-rv)), radial-gradient(circle at 6px calc(100% - 6px), var(--fw-rv)), radial-gradient(circle at calc(100% - 6px) calc(100% - 6px), var(--fw-rv));
  --fw-parch: radial-gradient(ellipse at 50% 0%, rgba(255, 250, 230, .5), transparent 65%), radial-gradient(ellipse at 100% 100%, rgba(150, 100, 40, .2), transparent 55%), linear-gradient(180deg, #efe1bd, #dfca9c);
  --fw-edge: #140b04; --fw-brass: #c99a4a; --fw-brass-l: #f0cf86; --fw-cream: #f6e7c4; --fw-ink: #3a2614; --fw-red: #8c1c12; --fw-dim: #b9a07a;
  --fw-fh: 'Pirata One', 'Cinzel', Georgia, serif; --fw-fl: 'Cinzel', Georgia, serif;
  --ui-acc: #e0b866; --ui-text: #f1e4c6; --ui-dim: #b9a07a;
}
img.ei { width: 1.3em; height: 1.3em; vertical-align: -.32em; margin-right: .28em; filter: drop-shadow(0 1px 0 rgba(0, 0, 0, .45)); pointer-events: none; }
.pno { color: inherit; }
/* bois clouté : panneaux, fenêtres latérales, bandeaux */
.leather, #levelup, #modeHud, #tradeReq, #meteorBar, #bossBar:not(:empty) {
  background: var(--fw-rivets), var(--fw-grain), var(--fw-wood); border: 2px solid var(--fw-edge); border-radius: 6px; color: var(--ui-text);
  box-shadow: inset 0 1px 0 rgba(255, 230, 180, .16), inset 0 -2px 0 rgba(0, 0, 0, .4), 0 4px 0 rgba(10, 5, 2, .85), 0 14px 34px rgba(0, 0, 0, .55); backdrop-filter: none;
}
.plank-title, .side h3.plank-title { font-family: var(--fw-fh); font-weight: 400; font-size: 24px; letter-spacing: .02em; text-transform: none; color: var(--fw-cream);
  border-bottom: 2px solid rgba(201, 154, 74, .45); text-shadow: 0 2px 0 rgba(0, 0, 0, .55); padding-bottom: 4px; }
.plank-title small { font-family: var(--fw-fl); font-size: 11px; color: var(--fw-dim); letter-spacing: .06em; }
/* boutons : planches */
.sign { font-family: var(--fw-fl); font-weight: 700; letter-spacing: .08em; color: var(--fw-cream); border: 2px solid var(--fw-edge); border-radius: 5px;
  background: var(--fw-grain), var(--fw-wood-l); box-shadow: inset 0 1px 0 rgba(255, 235, 190, .3), inset 0 -2px 0 rgba(0, 0, 0, .3), 0 3px 0 var(--fw-edge); text-shadow: 0 1px 0 rgba(0, 0, 0, .6); }
.sign:hover { background: var(--fw-grain), linear-gradient(180deg, #9a6834, #7a4c24 55%, #61391a); border-color: var(--fw-edge); color: #fff; filter: none; }
.sign.big { font-family: var(--fw-fh); font-weight: 400; font-size: 26px; letter-spacing: .04em; text-transform: none; color: #2a180a; text-shadow: 0 1px 0 rgba(255, 245, 210, .6);
  background: var(--fw-grain), linear-gradient(180deg, #f3d48a, #d4a24a 55%, #a87a2e); border-color: #3a2410; }
.sign.big:hover { background: var(--fw-grain), linear-gradient(180deg, #ffe3a0, #e0b058 55%, #b88634); color: #000; }
.sign.on { background: var(--fw-grain), linear-gradient(180deg, #6b4a1c, #4d3412); color: var(--fw-brass-l); border-color: var(--fw-brass); }
.sign i[data-ic] img.ei, a i[data-ic] img.ei { margin-right: .35em; }

/* ----- Dock : plaques de bois, icône dessinée, nom gravé, touche en laiton ----- */
.act { background: var(--fw-rivets), var(--fw-grain), var(--fw-wood-l); border: 2px solid var(--fw-edge); border-radius: 6px; color: var(--fw-cream);
  box-shadow: inset 0 1px 0 rgba(255, 235, 190, .32), inset 0 -3px 0 rgba(0, 0, 0, .32), 0 3px 0 var(--fw-edge), 0 8px 16px rgba(0, 0, 0, .4); }
.act .aic img.ei { width: 30px; height: 30px; margin: 0; vertical-align: 0; filter: drop-shadow(0 2px 0 rgba(0, 0, 0, .45)); transition: transform .12s; }
.act .lbl { font-family: var(--fw-fl); font-weight: 700; font-size: 9px; letter-spacing: .05em; color: var(--fw-cream); text-shadow: 0 1px 0 rgba(0, 0, 0, .7); }
.act kbd { background: linear-gradient(180deg, #f3d48a, #b98a3a); border: 1px solid #3a2410; color: #2a180a; font: 700 9px/13px var(--fw-fl); box-shadow: 0 1px 0 rgba(0, 0, 0, .45); }
.act:hover { background: var(--fw-rivets), var(--fw-grain), linear-gradient(180deg, #9a6834, #7a4c24 55%, #61391a); border-color: var(--fw-edge); }
.act:hover .aic img.ei { transform: translateY(-2px) scale(1.06); }
.act.on { background: var(--fw-rivets), var(--fw-grain), linear-gradient(180deg, #5e4216, #3e2b0e); border-color: var(--fw-brass); color: var(--fw-brass-l);
  box-shadow: inset 0 0 0 1px rgba(240, 207, 134, .55), 0 3px 0 var(--fw-edge), 0 0 16px rgba(224, 184, 102, .35); }
@container hud (min-width: 801px) and (min-height: 541px) { .act .aic img.ei { width: 26px; height: 26px; } .act .lbl { font-size: 8px; } }
@media (max-width: 800px), (max-height: 540px) { .act .aic img.ei { width: 22px; height: 22px; } .act .lbl { font-size: 7.5px; } }

/* ----- Jauges : cadre de fer sombre, médaillon de laiton avec l'icône dessinée ----- */
.bar { height: 16px; margin-left: 22px; background: linear-gradient(180deg, #1a100a, #2a1a10); border: 2px solid var(--fw-edge); border-radius: 4px;
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, .7), 0 1px 0 rgba(255, 220, 160, .12); }
.bar .fill { border-radius: 2px; box-shadow: inset 0 -3px 0 rgba(0, 0, 0, .22), inset 0 2px 0 rgba(255, 255, 255, .28); }
.bar span { font-family: 'Inter', 'Segoe UI', sans-serif; font-weight: 800; font-size: 10px; letter-spacing: .05em; color: #fff8e6; text-shadow: 0 1px 2px #000, 0 0 3px rgba(0, 0, 0, .8); }
.bar .bi { left: -25px; top: -6px; width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; opacity: 1;
  background: radial-gradient(circle at 35% 30%, #f3d48a, #b98a3a 60%, #7a5420); border: 2px solid var(--fw-edge); box-shadow: 0 2px 0 rgba(0, 0, 0, .5); }
.bar .bi img.ei { width: 18px; height: 18px; margin: 0; vertical-align: 0; }
.bar.xp { height: 11px; } .bar.xp .bi { width: 20px; height: 20px; top: -6px; left: -23px; } .bar.xp .bi img.ei { width: 14px; height: 14px; }
.bar.hp .fill { background: linear-gradient(180deg, #e8625b, #b02a24); } .bar.food .fill { background: linear-gradient(180deg, #e0a050, #a8661f); }
.bar.stamina .fill { background: linear-gradient(180deg, #f2d35e, #c09524); } .bar.mana .fill { background: linear-gradient(180deg, #7aa2ff, #3b5ad0); }
.bar.cold .fill { background: linear-gradient(180deg, #8cc4ea, #3f7fb3); } .bar.heat .fill { background: linear-gradient(180deg, #f08a4c, #b84a1c); }
.bar.poison .fill { background: linear-gradient(180deg, #a6cf62, #5e8a2a); } .bar.xp .fill { background: linear-gradient(180deg, #b49af0, #6e4fc0); }

/* ----- Bandeau du haut, effets, toasts : étiquettes de parchemin et de bois ----- */
#topbar .plank { background: var(--fw-grain), var(--fw-wood); border: 2px solid var(--fw-edge); border-radius: 4px; color: var(--fw-cream); font-family: var(--fw-fl); font-weight: 700; letter-spacing: .04em;
  box-shadow: inset 0 1px 0 rgba(255, 230, 180, .15), 0 2px 0 rgba(10, 5, 2, .8); }
#topbar .plank img.ei { width: 15px; height: 15px; vertical-align: -3px; }
#clock { color: var(--fw-brass-l); }
#fx span { background: var(--fw-parch); border: 2px solid #6e5134; border-radius: 4px; color: var(--fw-ink); font-family: var(--fw-fl); font-weight: 700; font-size: 10.5px; padding: 1px 7px 1px 4px; box-shadow: 0 2px 0 rgba(0, 0, 0, .35); }
#fx span img.ei { width: 16px; height: 16px; vertical-align: -4px; margin-right: 3px; }
#fx span.bad { border-color: #8c1c12; color: #8c1c12; }
#toasts div { background: var(--fw-parch); border: 2px solid #6e5134; border-radius: 4px; color: var(--fw-ink); font-family: var(--fw-fl); font-weight: 700; font-size: 13px; box-shadow: 0 3px 0 rgba(0, 0, 0, .4), 0 8px 18px rgba(0, 0, 0, .35); }
#toasts div.g { border-color: #8a5a10; color: #6a3a00; box-shadow: 0 0 0 2px #e0b866, 0 3px 0 rgba(0, 0, 0, .4); }
#toasts div.red { background: linear-gradient(180deg, #f3c9bf, #e3a99c); border-color: #8c1c12; color: #6a0f08; }
#toasts img.ei { width: 18px; height: 18px; vertical-align: -4px; }
/* classement et quêtes : parchemin cloué sur une planche */
#leaderboard { background: var(--fw-rivets), var(--fw-parch); border: 2px solid var(--fw-edge); border-radius: 4px; color: var(--fw-ink);
  box-shadow: inset 0 0 18px rgba(120, 75, 25, .3), 0 3px 0 rgba(10, 5, 2, .8), 0 10px 24px rgba(0, 0, 0, .4); }
#leaderboard .plank-title { font-size: 21px; color: var(--fw-red); text-shadow: 0 1px 0 #f7ecd0; border-bottom-color: rgba(70, 40, 15, .35); }
#leaderboard ol { color: var(--fw-ink); font-weight: 600; } #leaderboard li.me { color: var(--fw-red); font-weight: 800; } #leaderboard .tag { color: #7a5c3c; }
#lbMe { color: #6e5134 !important; border-top-color: rgba(70, 40, 15, .3) !important; } #lbMe b { color: var(--fw-red) !important; } #lbMe img.ei { width: 14px; height: 14px; vertical-align: -3px; margin: 0 0 0 3px; }
#quests div { background: var(--fw-parch); border: 2px solid #6e5134; border-radius: 3px; color: var(--fw-ink); font-weight: 600; box-shadow: 0 2px 0 rgba(0, 0, 0, .35); }
#quests small { color: #6a1b9a; font-family: var(--fw-fl); } #quests .pb { background: rgba(70, 40, 15, .2); } #quests .pb i { background: linear-gradient(90deg, #b98a3a, #e0b866); }
#killfeed div { background: rgba(42, 24, 10, .82); border: 1px solid rgba(0, 0, 0, .6); color: var(--ui-text); }
/* barre rapide : plateau de bois, cases creusées, celle en main cerclée de laiton */
#hotbar { background: var(--fw-grain), var(--fw-wood); border: 2px solid var(--fw-edge); border-radius: 6px; box-shadow: inset 0 1px 0 rgba(255, 230, 180, .14), 0 3px 0 rgba(10, 5, 2, .85), 0 10px 22px rgba(0, 0, 0, .4); }
.slot { background: radial-gradient(ellipse at 50% 35%, rgba(90, 60, 30, .55), rgba(16, 9, 4, .9)); border: 1px solid rgba(0, 0, 0, .8); border-radius: 4px; box-shadow: inset 0 2px 5px rgba(0, 0, 0, .7), 0 1px 0 rgba(255, 220, 160, .1); }
.slot:hover { border-color: rgba(240, 207, 134, .6); }
.slot.eq { border-color: var(--fw-brass-l); box-shadow: inset 0 0 0 1px var(--fw-brass), inset 0 2px 5px rgba(0, 0, 0, .6), 0 0 12px rgba(224, 184, 102, .45); }
.slot .k { color: #c9b08a; font-family: var(--fw-fl); font-weight: 700; } .slot .n { font-family: var(--fw-fl); font-weight: 700; color: #fff3d6; }
/* minicarte : cadre de bois clouté */
#minimapWrap.frame { background: var(--fw-rivets), var(--fw-grain), var(--fw-wood-l); border: 2px solid var(--fw-edge); border-radius: 6px; padding: 5px;
  box-shadow: inset 0 1px 0 rgba(255, 235, 190, .3), 0 3px 0 var(--fw-edge), 0 10px 24px rgba(0, 0, 0, .45); }
#minimapWrap canvas { border: 2px solid var(--fw-edge); border-radius: 3px; }
/* fenêtres latérales : intérieur de cuir sombre */
.side { color: var(--ui-text); }
.side .tabs div { font-family: var(--fw-fl); font-weight: 700; background: rgba(0, 0, 0, .28); border: 1px solid rgba(0, 0, 0, .55); color: #d9c39a; }
.side .tabs div.on { background: linear-gradient(180deg, #6b4a1c, #4d3412); border-color: var(--fw-brass); color: var(--fw-brass-l); }
.side .item { background: rgba(0, 0, 0, .18); } .side .item:hover { background: rgba(240, 207, 134, .08); border-color: rgba(240, 207, 134, .35); }
.side .item.sel { border-color: var(--fw-brass); background: rgba(240, 207, 134, .12); }
.side::-webkit-scrollbar-thumb { background: rgba(240, 207, 134, .3); }
#chatLog div { background: rgba(36, 21, 9, .78); } #chatLog b { color: var(--fw-brass-l); } #chatLog .sys { color: #f3d48a; }
#chatLog img.ei { width: 16px; height: 16px; vertical-align: -3px; }
#heldName { background: rgba(36, 21, 9, .82) !important; border-color: rgba(0, 0, 0, .6) !important; font-family: var(--fw-fl) !important; font-weight: 700 !important; }
#levelup h3 { font-family: var(--fw-fh); font-weight: 400; font-size: 26px; color: var(--fw-brass-l); }
#bigmap .legend img.ei { width: 15px; height: 15px; vertical-align: -3px; margin: 0 2px; }
/* commandes tactiles : médaillons de laiton */
#atkBtn, #dashBtn, #blockBtn, #horseBtn { display: grid; place-items: center; }
#atkBtn img.ei, #dashBtn img.ei, #blockBtn img.ei, #horseBtn img.ei { width: 58%; height: 58%; margin: 0; }

/* ----- Réglages (Échap) : grande fenêtre de bois, onglets à gauche, page de parchemin ----- */
#settings { display: grid; place-items: center; }
#settings.hidden { display: none; }
.setwin { width: min(96vw, 1060px); height: min(92vh, 760px); display: flex; flex-direction: column; gap: 8px; padding: 12px 14px 12px; box-sizing: border-box; text-align: left; color: var(--fw-cream); }
.sethead { display: flex; align-items: center; gap: 16px; padding: 0 4px; }
.sethead .gk-title { margin: 0; font-size: 46px; color: #f3d48a; text-shadow: 0 2px 0 rgba(0, 0, 0, .6), 0 4px 0 rgba(0, 0, 0, .3); transform: rotate(-1.5deg); }
.setwhere { flex: 1; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.sethead .setmode { margin: 0; font-family: var(--fw-fl); font-size: 15px; font-weight: 700; letter-spacing: .06em; color: var(--fw-cream); min-height: 0; }
.sethead .setmode img.ei { width: 22px; height: 22px; vertical-align: -5px; }
.sethead .setroom { margin: 0; justify-content: flex-start; color: var(--fw-cream); font-family: var(--fw-fl); font-weight: 700; }
.sethead .trx { flex: none; }
.setbody { flex: 1; min-height: 0; display: flex; gap: 10px; }
.settabs { flex: none; width: 168px; display: flex; flex-direction: column; gap: 7px; }
.settabs button { display: flex; align-items: center; gap: 10px; padding: 9px 12px; text-align: left; border: 2px solid var(--fw-edge); border-radius: 6px; cursor: pointer; color: var(--fw-cream);
  font: 400 21px var(--fw-fh); letter-spacing: .02em; text-shadow: 0 2px 0 rgba(0, 0, 0, .55);
  background: var(--fw-grain), var(--fw-wood-l); box-shadow: inset 0 1px 0 rgba(255, 235, 190, .3), inset 0 -3px 0 rgba(0, 0, 0, .3), 0 3px 0 var(--fw-edge); transition: transform .08s, filter .1s; }
.settabs button img.ei { width: 30px; height: 30px; margin: 0; vertical-align: 0; }
.settabs button:hover { filter: brightness(1.1); }
.settabs button.on { transform: translateX(8px); color: #2a180a; text-shadow: 0 1px 0 rgba(255, 245, 210, .6); background: var(--fw-grain), linear-gradient(180deg, #f3d48a, #d4a24a 55%, #a87a2e); }
.setpage { flex: 1; min-width: 0; max-height: none; padding: 16px 24px 18px; color: var(--fw-ink); }
.setsec { margin: 0 0 6px; font: 400 32px var(--fw-fh); color: var(--fw-red); text-shadow: 0 2px 0 #f7ecd0, 0 3px 0 rgba(60, 25, 5, .25); }
.setpage .setrow { display: grid; grid-template-columns: minmax(0, 1fr) minmax(170px, 300px) 54px; align-items: center; gap: 6px 16px; margin: 0; padding: 11px 2px;
  border-bottom: 2px dotted rgba(70, 40, 15, .3); color: var(--fw-ink); font-family: var(--fw-fl); font-size: 15px; font-weight: 700; }
.setpage .setrow span.sl { width: auto; display: flex; flex-direction: column; gap: 2px; }
.setpage .setrow span.sl small { font-family: 'Inter', 'Segoe UI', sans-serif; font-size: 12px; font-weight: 500; color: #6e5134; letter-spacing: 0; }
.setpage .setrow > input[type=checkbox]:only-of-type { grid-column: 3; }
.setpage .setrow > select, .setpage .setrow > input[type=range] { grid-column: 2; }
/* curseur : rainure de bois, bouton de laiton */
.setpage input[type=range] { -webkit-appearance: none; appearance: none; height: 22px; background: transparent; width: 100%; margin: 0; cursor: pointer; }
.setpage input[type=range]::-webkit-slider-runnable-track { height: 8px; border-radius: 4px; background: linear-gradient(180deg, #4a2d15, #6b4320); border: 2px solid var(--fw-edge); box-shadow: inset 0 2px 3px rgba(0, 0, 0, .5); }
.setpage input[type=range]::-moz-range-track { height: 8px; border-radius: 4px; background: linear-gradient(180deg, #4a2d15, #6b4320); border: 2px solid var(--fw-edge); }
.setpage input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; margin-top: -8px; border-radius: 50%; border: 2px solid var(--fw-edge); background: radial-gradient(circle at 35% 30%, #fff1c4, #d4a24a 55%, #8a5a1c); box-shadow: 0 2px 0 rgba(0, 0, 0, .45); }
.setpage input[type=range]::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--fw-edge); background: radial-gradient(circle at 35% 30%, #fff1c4, #d4a24a 55%, #8a5a1c); }
/* case à cocher : interrupteur de bois, sceau de cire quand c'est actif */
.setpage input[type=checkbox] { -webkit-appearance: none; appearance: none; position: relative; width: 50px; height: 26px; margin: 0; border-radius: 13px; cursor: pointer; flex: none;
  background: linear-gradient(180deg, #4a2d15, #6b4320); border: 2px solid var(--fw-edge); box-shadow: inset 0 2px 4px rgba(0, 0, 0, .55); transition: background .15s; }
.setpage input[type=checkbox]::after { content: ''; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--fw-edge);
  background: radial-gradient(circle at 35% 30%, #e8d9b8, #9a8a70 60%, #5c5040); transition: left .15s, background .15s; }
.setpage input[type=checkbox]:checked { background: linear-gradient(180deg, #6a8a2a, #8fb045); }
.setpage input[type=checkbox]:checked::after { left: 26px; background: radial-gradient(circle at 35% 30%, #fff1c4, #d4a24a 55%, #8a5a1c); }
.setpage input[type=checkbox]:focus-visible, .setpage input[type=range]:focus-visible, .setpage select:focus-visible { outline: 2px solid var(--fw-red); outline-offset: 2px; }
.setpage select { width: 100%; padding: 6px 10px; border-radius: 5px; border: 2px solid #6e5134; background: #f7ecd0; color: var(--fw-ink); font: 700 14px var(--fw-fl); cursor: pointer; box-shadow: inset 0 1px 3px rgba(0, 0, 0, .15); }
.setpage .setwarn { margin: 8px 0; background: #f6d8a8; border: 2px solid #b8761c; color: #5a3200; border-radius: 4px; }
/* touches : capuchons de bois */
.keygrid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 22px; margin-top: 6px; }
.keygrid > div { display: flex; align-items: center; gap: 5px; padding: 6px 2px; border-bottom: 2px dotted rgba(70, 40, 15, .25); font-size: 14px; font-weight: 600; color: var(--fw-ink); }
.keygrid > div > span { margin-left: 8px; }
.keygrid kbd { display: inline-block; min-width: 26px; padding: 3px 7px; box-sizing: border-box; text-align: center; border-radius: 5px; border: 2px solid var(--fw-edge); color: var(--fw-cream);
  font: 700 12px var(--fw-fl); background: var(--fw-grain), var(--fw-wood-l); box-shadow: inset 0 1px 0 rgba(255, 235, 190, .3), 0 3px 0 var(--fw-edge); }
/* succès : cartes de parchemin */
.setpage .achtitle { color: var(--fw-red); font-family: var(--fw-fl); font-size: 14px; margin-bottom: 10px; }
.setpage .achlist { grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 8px; max-height: none; overflow: visible; }
.setpage .ach { background: rgba(255, 250, 235, .55); border: 2px solid rgba(110, 81, 52, .45); border-radius: 5px; padding: 7px 9px; color: #6e5134; font-size: 12px; }
.setpage .ach b { color: var(--fw-ink); font-family: var(--fw-fl); font-size: 13px; } .setpage .ach small { font-size: 11.5px; }
.setpage .ach .pb { background: rgba(70, 40, 15, .2); } .setpage .ach .pb i { background: linear-gradient(90deg, #b98a3a, #e0b866); }
.setpage .ach.ok { border-color: #a87a2e; background: linear-gradient(180deg, #fff3cf, #f0d99a); } .setpage .ach.ok b { color: var(--fw-red); }
.setpage .ach.cur { box-shadow: 0 0 0 3px var(--fw-red); }
/* sauvegarde */
.setpage .setsave { margin: 4px 0; padding: 12px 14px; background: rgba(255, 250, 235, .5); border: 2px solid rgba(110, 81, 52, .45); border-radius: 5px; color: var(--fw-ink); font-size: 14px; }
.setpage .setsave code { background: #2a180a; color: #f3d48a; font-size: 14px; padding: 4px 10px; }
.setpage .setsave button { padding: 6px 12px; font: 700 12px var(--fw-fl); color: var(--fw-cream); border: 2px solid var(--fw-edge); background: var(--fw-grain), var(--fw-wood-l); border-radius: 4px; }
.setpage .setsave small { color: #6e5134; font-size: 12.5px; }
.setfoot { display: flex; align-items: center; justify-content: center; gap: 24px; }
.setfoot .gk-plank { width: auto; min-width: 280px; margin: 0; }
.setfoot .gk-link { color: #f3c2b6; font-size: 14px; } .setfoot .gk-link:hover { color: #fff; }
@media (max-width: 760px) {
  .setwin { width: 100vw; height: 100vh; border-radius: 0; padding: 8px; }
  .sethead .gk-title { font-size: 32px; }
  .setbody { flex-direction: column; }
  .settabs { width: auto; flex-direction: row; overflow-x: auto; gap: 5px; }
  .settabs button { padding: 6px 9px; font-size: 16px; gap: 6px; } .settabs button img.ei { width: 22px; height: 22px; } .settabs button.on { transform: translateY(3px); }
  .setpage { padding: 10px 12px; }
  .setpage .setrow { grid-template-columns: 1fr auto; } .setpage .setrow > select, .setpage .setrow > input[type=range] { grid-column: 1 / -1; } .setpage .setrow > input[type=checkbox]:only-of-type { grid-column: 2; grid-row: 1; }
  .setfoot { gap: 12px; } .setfoot .gk-plank { min-width: 0; flex: 1; } .setfoot .gk-link { white-space: nowrap; }
  .keygrid { grid-template-columns: 1fr; }
}
span.emo { display: inline; }
#tuto { background: var(--fw-rivets), var(--fw-parch) !important; border: 2px solid var(--fw-edge) !important; color: var(--fw-ink) !important; box-shadow: 0 3px 0 rgba(10, 5, 2, .8), 0 10px 22px rgba(0, 0, 0, .4) !important; }
#tuto b { color: var(--fw-red) !important; } #tuto button { color: var(--fw-ink); }
#settings .setsec img.ei { display: none; }
/* Menu principal (§ 7.49) : la même planche clouée, des cartes de mode en bois clair, l'aide sur parchemin */
#menu .board { background: var(--fw-rivets), var(--fw-grain), var(--fw-wood); border: 2px solid var(--fw-edge); border-radius: 8px; backdrop-filter: none;
  box-shadow: inset 0 1px 0 rgba(255, 230, 180, .16), inset 0 -2px 0 rgba(0, 0, 0, .4), 0 6px 0 rgba(10, 5, 2, .9), 0 24px 60px rgba(0, 0, 0, .7); }
#menu .logo { color: #f3d48a; text-shadow: 0 2px 0 #6b4320, 0 4px 0 #2a180a, 0 10px 24px rgba(0, 0, 0, .7); }
#menu .logo span { color: #9fe3ea; }
#menu .tagline { color: var(--fw-dim); }
#menu .joinrow input { background: var(--fw-parch); border: 2px solid var(--fw-edge); color: var(--fw-ink); font-family: var(--fw-fl); font-weight: 700; box-shadow: inset 0 2px 5px rgba(120, 75, 25, .35); }
#menu .joinrow input::placeholder { color: #8a6a44; }
#menu .joinrow input.bad { border-color: #b3261e; box-shadow: 0 0 0 2px rgba(179, 38, 30, .5), inset 0 2px 5px rgba(120, 75, 25, .35); }
#menu .nameErr { background: #8c1c12; border: 2px solid var(--fw-edge); font-family: var(--fw-fl); }
#menu .menunote { margin: 6px 0 0; padding: 6px 10px 6px 12px; border-radius: 4px; text-align: left; background: rgba(10, 5, 2, .55); border: 2px solid var(--fw-brass); border-left-width: 5px; color: var(--fw-cream); font-family: var(--fb); font-size: 13px; font-weight: 600; box-shadow: 0 0 14px rgba(224, 184, 102, .25); } /* un mot du serveur sur le menu (§ 7.118) */
#menu .menunote.hidden { display: none; } #menu .menunote.shake { animation: nameShake .35s ease-in-out; }
#menu .custom { background: rgba(10, 5, 2, .35); border: 2px solid rgba(0, 0, 0, .55); border-radius: 6px; box-shadow: inset 0 2px 8px rgba(0, 0, 0, .45); }
#menu .lrow > span { color: var(--fw-dim); font-family: var(--fw-fl); font-weight: 700; }
#menu .cyc b { color: var(--fw-cream); font-family: var(--fw-fl); }
#menu .cyc button { background: var(--fw-grain), var(--fw-wood-l); border: 2px solid var(--fw-edge); color: var(--fw-cream); border-radius: 4px; }
.mode, .mode:nth-child(odd), .mode:nth-child(even) { background: var(--fw-grain), var(--fw-wood-l); border: 2px solid var(--fw-edge); border-radius: 6px; color: var(--fw-cream);
  box-shadow: inset 0 1px 0 rgba(255, 235, 190, .3), inset 0 -3px 0 rgba(0, 0, 0, .3), 0 3px 0 var(--fw-edge); }
.mode:hover { background: var(--fw-grain), linear-gradient(180deg, #9a6834, #7a4c24 55%, #61391a); border-color: var(--fw-edge); }
.mode.sel { border-color: var(--fw-brass-l); box-shadow: inset 0 0 0 1px var(--fw-brass), 0 3px 0 var(--fw-edge), 0 0 18px rgba(224, 184, 102, .45); }
.mode .prev { border: 2px solid var(--fw-edge); border-radius: 4px; }
.mode b { font-family: var(--fw-fh); font-weight: 400; font-size: 22px; letter-spacing: .02em; text-transform: none; color: var(--fw-cream); text-shadow: 0 2px 0 rgba(0, 0, 0, .55); }
.mode b img.ei { width: 22px; height: 22px; vertical-align: -4px; }
.mode small { color: #ecd9b4; } .mode .cnt { color: #c5e1a5; font-family: var(--fw-fl); font-weight: 700; }
#menu .help { background: var(--fw-parch); border: 2px solid var(--fw-edge); border-radius: 5px; color: var(--fw-ink); box-shadow: inset 0 0 18px rgba(120, 75, 25, .3); }
#menu .help b { color: var(--fw-red); font-family: var(--fw-fl); }
#menu .tips, #menu #hof { color: #d9c39a; } #menu #hof b { color: var(--fw-brass-l); }
#menu .privrow input { background: var(--fw-parch); border: 2px solid var(--fw-edge); color: var(--fw-ink); font-family: var(--fw-fl); font-weight: 700; }
#menu .saverow a { color: var(--fw-brass-l); }
#menu .sign.small img.ei, #menu .saverow img.ei { width: 18px; height: 18px; vertical-align: -4px; }
/* Choix sous les cartes de mode (§ 7.118) : formats des Forteresses (pastilles aux couleurs des équipes, qui attend, qui joue), serveurs de la Survie (jauge de places) */
.modeopts { margin: -2px 0 12px; padding: 8px 10px 10px; text-align: left; background: rgba(10, 5, 2, .38); border: 2px solid rgba(0, 0, 0, .55); border-radius: 6px; box-shadow: inset 0 2px 8px rgba(0, 0, 0, .45); }
.modeopts.hidden { display: none; }
.mo-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin: 0 2px 7px; }
.mo-head b { font-family: var(--fw-fl); font-weight: 700; font-size: 13px; letter-spacing: .06em; text-transform: uppercase; color: var(--fw-brass-l); white-space: nowrap; }
.mo-head b img.ei { width: 18px; height: 18px; vertical-align: -4px; margin-right: 5px; }
.mo-head small { flex: 1 1 220px; color: var(--fw-dim); font-size: 11.5px; line-height: 1.3; }
.mo-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; }
.srvs .mo-list { grid-template-columns: repeat(auto-fit, minmax(118px, 1fr)); }
.mo-opt { position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; min-width: 0; padding: 7px 6px 6px; cursor: pointer; font: inherit; color: var(--fw-cream); text-align: center;
  background: var(--fw-grain), var(--fw-wood-l); border: 2px solid var(--fw-edge); border-radius: 6px; box-shadow: inset 0 1px 0 rgba(255, 235, 190, .3), inset 0 -3px 0 rgba(0, 0, 0, .3), 0 3px 0 var(--fw-edge); transition: transform .08s, filter .12s; }
.mo-opt:hover { filter: brightness(1.12); transform: translateY(-1px); }
.mo-opt:active { transform: translateY(2px); box-shadow: inset 0 1px 0 rgba(255, 235, 190, .3), 0 1px 0 var(--fw-edge); }
.mo-opt.sel { border-color: var(--fw-brass-l); box-shadow: inset 0 0 0 1px var(--fw-brass), 0 3px 0 var(--fw-edge), 0 0 16px rgba(224, 184, 102, .5); }
.mo-opt b { font-family: var(--fw-fh); font-weight: 400; font-size: 21px; line-height: 1; color: var(--fw-cream); text-shadow: 0 2px 0 rgba(0, 0, 0, .55); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.mo-vs { font-family: Inter, system-ui, sans-serif; font-weight: 700; font-size: 10.5px; letter-spacing: .03em; color: var(--fw-dim); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.mo-cnt { font-size: 11px; line-height: 1.25; color: #d8e8c0; min-height: 14px; }
.mo-cnt em { font-style: normal; font-weight: 800; color: #c5e1a5; }
.mo-pips { display: flex; flex-wrap: wrap; justify-content: center; align-content: center; gap: 3px 6px; min-height: 27px; align-items: center; padding: 2px 4px; border-radius: 10px; background: rgba(0, 0, 0, .28); box-shadow: inset 0 1px 2px rgba(0, 0, 0, .5); }
.mo-team { display: inline-flex; gap: 1px; }
.mo-br { flex-basis: 100%; height: 0; }
.mo-team i { width: 7px; height: 7px; border-radius: 50%; box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .35), 0 0 0 1px rgba(0, 0, 0, .55), 0 0 5px rgba(255, 255, 255, .18); }
.mo-opt.sel .mo-team i { box-shadow: inset 0 -1px 0 rgba(0, 0, 0, .35), 0 0 0 1px rgba(0, 0, 0, .55), 0 0 7px rgba(255, 240, 200, .5); }
.mo-bar { display: block; width: 86%; height: 7px; border-radius: 4px; background: rgba(0, 0, 0, .45); box-shadow: inset 0 1px 2px rgba(0, 0, 0, .6); overflow: hidden; }
.mo-bar i { display: block; height: 100%; background: linear-gradient(90deg, #7cb342, #c5e1a5); border-radius: 4px; }
.mo-srv.full .mo-bar i { background: linear-gradient(90deg, #c62828, #ff8a80); }
.mo-srv.full .mo-cnt { color: #ffab91; }
.mo-srv.wait { opacity: .6; cursor: progress; }
.mo-mine { font-style: normal; font-size: 13px; margin-left: 4px; color: var(--fw-brass-l); vertical-align: 3px; }
.mo-auto b { font-size: 19px; }
@media (max-width: 520px) { .mo-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } .srvs .mo-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } .mo-opt b { font-size: 19px; } }
@media (max-width: 520px), (max-height: 540px) { .mo-pips { gap: 3px 4px; padding: 2px 3px; } .mo-team i { width: 5px; height: 5px; } } /* Escouade (16 pastilles) sur une ligne */
@media (max-height: 540px) { .modeopts { padding: 6px 8px 7px; } .mo-head { margin-bottom: 5px; } .mo-opt { padding: 5px 4px 5px; gap: 2px; } .mo-opt b { font-size: 18px; } }

/* Boîte aux lettres du clan (§ 7.50, lot 2) */
#mailBody .mb-sec { margin-bottom: 10px; } #mailBody .mb-sec > b { display: block; font-size: 12px; color: #ffe8a3; margin-bottom: 5px; }
#mailBody .mb-to { display: flex; flex-wrap: wrap; gap: 5px; }
#mailBody .mb-to button { display: flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 6px; border: 1px solid rgba(255, 213, 79, .35); background: rgba(0, 0, 0, .2); color: #fff3d6; cursor: pointer; font: inherit; font-size: 12px; }
#mailBody .mb-to button.on { border-color: #ffd54f; background: rgba(255, 213, 79, .22); }
#mailBody .mb-to i { width: 7px; height: 7px; border-radius: 50%; background: #8d8170; } #mailBody .mb-to i.live { background: #9ccc65; }
#mailBody .mb-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 4px; max-height: 210px; overflow-y: auto; }
#mailBody .mb-grid .islot { width: auto; height: 46px; cursor: pointer; }
#mailBody .mb-send { display: flex; align-items: center; gap: 6px; font-size: 12px; color: #fff3d6; }
#mailBody .mb-send input { width: 64px; padding: 3px 5px; border-radius: 5px; border: 1px solid rgba(255, 213, 79, .4); background: rgba(0, 0, 0, .3); color: #fff; font: inherit; }
#mailBody .mb-send button { margin-left: auto; padding: 5px 10px; border-radius: 6px; border: 1px solid #ffd54f; background: rgba(255, 213, 79, .2); color: #fff3d6; cursor: pointer; font: inherit; font-weight: 700; }
#mailBody .mb-hint { font-size: 11px; color: #b9a684; font-style: italic; }

/* Clé de portail : choix du rang (§ 7.33, lot 3) */
#portalPick { position: fixed; left: 50%; top: 40%; transform: translate(-50%, -50%); z-index: 60; padding: 14px 18px; min-width: 300px; text-align: center; color: #f1e2bf; }
#portalPick.hidden { display: none; } #portalPick p { margin: 6px 0 10px; font-size: 13px; }
#portalPick .pk-ranks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-bottom: 10px; }
#portalPick .pk-ranks button { padding: 8px 0; border-radius: 7px; border: 2px solid; background: rgba(0, 0, 0, .35); font: inherit; font-weight: 800; font-size: 18px; cursor: pointer; }
#portalPick .pk-ranks button:hover { background: rgba(255, 255, 255, .08); }
#portalPick .pk-x { padding: 4px 14px; border-radius: 6px; border: 1px solid rgba(255, 213, 79, .4); background: rgba(0, 0, 0, .25); color: #f1e2bf; cursor: pointer; font: inherit; }
/* Contrats du jour (§ 7.61) : en tête de la colonne des quêtes, cartes dorées */
#quests div.cthd { background: none; border: 0; padding: 0 2px; font-size: 10px; font-weight: 700; color: #ffe082; text-shadow: 0 1px 2px #000; letter-spacing: .02em; }
#quests div.cthd::before { display: none; }
#quests div.ctr { border-color: #c9a227; box-shadow: inset 0 0 0 1px rgba(255, 202, 40, .25); }
#quests div.ctr small { color: #ffca28; }
#quests div.ctr .pb i { background: linear-gradient(90deg, #c9a227, #ffe082); }
#quests div.ctr.done { opacity: .55; }
.shophint { font-size: 11px; color: #c9b08a; margin: 2px 0 6px; }
#quests img.cti { width: 13px; height: 13px; vertical-align: -2px; }
/* Collections (§ 7.63) : onglet de la fenêtre Échap (parchemin, comme les succès) */
.colbody { padding-right: 4px; }
.colh { margin: 12px 0 4px; font: 400 20px var(--fw-fl, serif); color: var(--fw-ink, #3b2412); display: flex; align-items: baseline; gap: 10px; }
.colh span { color: var(--fw-red, #8b1e1e); font-variant-numeric: tabular-nums; font-size: 16px; } .colh small { margin-left: auto; font-size: 11.5px; color: #6e5134; font-family: inherit; }
.colnote { font-size: 11.5px; color: #6e5134; margin: 2px 0 6px; }
.colgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(80px, 1fr)); gap: 6px; }
.colc { text-align: center; background: rgba(255, 250, 235, .55); border: 2px solid rgba(110, 81, 52, .35); border-radius: 5px; padding: 3px 2px 4px; }
.colc canvas { display: block; margin: 0 auto; width: 56px; height: 52px; }
.colc b { display: block; font-size: 11px; color: var(--fw-ink, #3b2412); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .colc small { font-size: 10.5px; color: #6e5134; font-variant-numeric: tabular-nums; }
.colc.ok { border-color: #b8892b; background: rgba(255, 236, 179, .7); } .colc.ok small { color: #8a5a00; font-weight: 700; } .colc.unk b { color: #9c8466; }
.colrow { display: flex; flex-wrap: wrap; gap: 5px 12px; }
.coli { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; color: #9c8466; } .coli .icon { width: 26px; height: 26px; filter: grayscale(1) brightness(.3); opacity: .55; }
.coli.ok { color: var(--fw-ink, #3b2412); font-weight: 600; } .coli.ok .icon { filter: none; opacity: 1; }
/* Prix du moment chez le marchand (§ 7.64) */
#shopBody .pr.low { color: #ff8a65; }
/* Hôtel des ventes (§ 7.65) */
.ahrow .nm small { display: block; font-size: 10.5px; color: #c9b08a; font-weight: 500; }
.ahform { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(201, 176, 138, .25); font-size: 11.5px; color: #c9b08a; }
.ahform select { grid-column: 1 / -1; }
.ahform label { display: flex; flex-direction: column; gap: 2px; } .ahform input { width: 100%; }
.ahform button { grid-column: 1 / -1; }
/* Classements (§ 7.67) : six tableaux sur le parchemin */
.rkgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; }
.rkc { background: rgba(255, 250, 235, .55); border: 2px solid rgba(110, 81, 52, .35); border-radius: 5px; padding: 6px 10px 8px; }
.rkc h4 { margin: 0 0 4px; font: 400 18px var(--fw-fl, serif); color: var(--fw-red, #8b1e1e); }
.rkc ol { margin: 0; padding: 0 0 0 22px; font-size: 12px; color: var(--fw-ink, #3b2412); }
.rkc li { padding: 1px 0; } .rkc li span { display: inline-block; max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; vertical-align: bottom; } .rkc li b { float: right; font-variant-numeric: tabular-nums; color: #6e5134; font-weight: 600; }
.rkc li[data-p="1"] span { color: #b8892b; font-weight: 700; } .rkc li[data-p="2"] span { color: #7d8187; font-weight: 700; } .rkc li[data-p="3"] span { color: #a0643a; font-weight: 700; }
.rkc li.me { background: rgba(255, 213, 79, .35); border-radius: 3px; } .rkc li.none { list-style: none; margin-left: -22px; color: #9c8466; font-style: italic; }
.rkc small { display: block; margin-top: 5px; font-size: 11px; color: #6e5134; }
/* Défi de la semaine du clan (§ 7.68) */
.cwk { background: rgba(255, 213, 79, .08); border: 1px solid rgba(255, 213, 79, .35); border-radius: 4px; padding: 6px 8px; margin: 4px 0 8px; font-size: 12px; }
.cwk b { display: block; color: #ffd54f; font-size: 12.5px; } .cwk span { display: block; margin: 2px 0 4px; }
.cwk .pb { height: 6px; background: rgba(0, 0, 0, .4); border-radius: 3px; overflow: hidden; } .cwk .pb i { display: block; height: 100%; background: linear-gradient(90deg, #c9a227, #ffe082); }
.cwk small { display: block; margin-top: 3px; color: #c9b08a; font-size: 11px; } .cwk small.rw { color: #9fb09a; } .cwk.done { border-color: #66bb6a; } .cwk.done .pb i { background: #66bb6a; }
.coli .dots { font-style: normal; letter-spacing: 1px; color: #8a5a00; font-size: 10px; } /* journal d'alchimie : effets connus (§ 7.69) */
.cwk.crw { background: rgba(198, 40, 40, .08); border-color: rgba(239, 83, 80, .4); } .cwk.crw b { color: #ff8a65; } .cwk.crw em { color: #ff8a65; font-style: normal; font-weight: 700; } .cwk.crw select { width: 100%; margin-top: 4px; } /* fenêtre de raid (§ 7.71) */
/* Projets de clan (§ 7.72) */
.cwk.cpj { background: rgba(102, 187, 106, .07); border-color: rgba(129, 199, 132, .4); } .cwk.cpj b { color: #a5d6a7; }
.cpr { margin-top: 5px; } .cpr span { display: block; } .cpr span small { display: inline; color: #9fb09a; } .cpr.done span { color: #a5d6a7; }
.cpi { font-size: 11px; color: #c9b08a; margin: 2px 0; } .cpi img.cti { width: 13px; height: 13px; vertical-align: -2px; }
#clanBody .off { color: #ffd54f; } /* officier (§ 7.73) */

/* Hameaux (§ 7.78) : réputation, primes */
.hmrep { position: relative; margin: 2px 0 8px; padding: 6px 8px 9px; border: 1px solid var(--stitch); border-radius: 4px; background: rgba(0, 0, 0, .08); font-size: 12px; overflow: hidden; }
.hmrep small { display: block; font-size: 11px; opacity: .8; } .hmrep i { position: absolute; left: 0; bottom: 0; height: 4px; background: linear-gradient(90deg, #66bb6a, #ffd54f); }
.hmb { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-bottom: 1px dashed var(--stitch); font-size: 12px; }
.hmb > div { flex: 1; } .hmb small { display: block; font-size: 11px; color: var(--gold); }
.hmb button { padding: 3px 9px; font-size: 11px; font-weight: 800; border-radius: 4px; cursor: pointer; border: 1px solid var(--ui-line2); background: rgba(255, 255, 255, .06); color: var(--ui-text); } .hmb button.go { border-color: #66bb6a; color: #a5d6a7; }
.hmb .hmpr { font-weight: 800; } .hmb .hmok { color: #81c784; font-weight: 800; }
.shoprow .nm small { margin-left: 6px; font-size: 11px; font-weight: 600; opacity: .8; }
.shophint.hmsack { color: #ff8a65; font-weight: 800; } /* hameau pillé (§ 7.78, lot 2) */
/* La Chronique (§ 7.95) : la stèle lue (une plaque de pierre gravée, selon l'anneau), le bandeau d'un chapitre achevé, la carte de la colonne de droite, l'onglet de la Pause */
#stele { z-index: 40; }
#stele .stelebox { position: relative; width: min(92vw, 540px); padding: 30px 46px 24px; text-align: center; color: #2f2a22;
  background: radial-gradient(ellipse at 50% 12%, rgba(255, 255, 255, .4), transparent 58%), repeating-linear-gradient(117deg, rgba(0, 0, 0, .028) 0 3px, transparent 3px 12px), linear-gradient(176deg, #e6e0d0, #cbc4b2 55%, #aea692);
  border: 4px solid #5c564a; border-radius: 50% 50% 12px 12px / 20% 20% 12px 12px;
  box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .35), inset 0 0 0 10px rgba(92, 86, 74, .28), 0 20px 46px rgba(0, 0, 0, .65), 0 0 70px rgba(255, 213, 79, .22);
  animation: stelein .5s cubic-bezier(.2, 1.3, .4, 1); }
@keyframes stelein { from { transform: translateY(34px) scale(.93); opacity: 0; } }
#stele.first .stelebox { animation: stelein .5s cubic-bezier(.2, 1.3, .4, 1), steleglow 2.6s ease-in-out .5s infinite; }
@keyframes steleglow { 50% { box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .35), inset 0 0 0 10px rgba(92, 86, 74, .28), 0 20px 46px rgba(0, 0, 0, .65), 0 0 110px rgba(255, 213, 79, .55); } }
#stele .steleeye { width: 54px; height: 54px; margin: 0 auto 8px; border: 3px solid #8a6d2a; border-radius: 50%;
  background: radial-gradient(circle, #fffbea 0 12%, #8a6d2a 13% 21%, transparent 22%), radial-gradient(ellipse 72% 40% at 50% 50%, #fff1c2 0 52%, #8a6d2a 54% 60%, transparent 62%), repeating-conic-gradient(rgba(138, 109, 42, .75) 0 5deg, transparent 5deg 30deg);
  box-shadow: 0 0 0 6px rgba(138, 109, 42, .18), 0 0 26px rgba(255, 213, 79, .75); }
#stele .stelering { font: 700 11px Cinzel, serif; letter-spacing: .22em; text-transform: uppercase; color: #6b5d3c; }
#stele h2 { margin: 4px 0 10px; font: 700 27px Cinzel, serif; color: #3b3326; text-shadow: 0 1px 0 rgba(255, 255, 255, .65), 0 -1px 0 rgba(0, 0, 0, .3); }
#stele p { margin: 0 0 16px; font: 500 15.5px/1.62 Georgia, 'Times New Roman', serif; color: #35302a; text-shadow: 0 1px 0 rgba(255, 255, 255, .45); }
#stele .stelefoot { font: 600 11px Cinzel, serif; letter-spacing: .1em; color: #6b5d3c; margin-bottom: 12px; }
#stele.ring1 .stelebox { background: radial-gradient(ellipse at 50% 12%, rgba(255, 255, 255, .25), transparent 58%), repeating-linear-gradient(117deg, rgba(0, 0, 0, .04) 0 3px, transparent 3px 12px), linear-gradient(176deg, #b7b3a9, #9d998f 55%, #85817a); }
#stele.ring2 .stelebox, #stele.ring3 .stelebox { color: #ece6f6; border-color: #120e18; }
#stele.ring2 .stelebox { background: radial-gradient(ellipse at 50% 12%, rgba(209, 179, 255, .18), transparent 58%), repeating-linear-gradient(117deg, rgba(255, 255, 255, .03) 0 3px, transparent 3px 12px), linear-gradient(176deg, #5e5868, #46414f 55%, #34303b); box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .12), inset 0 0 0 10px rgba(0, 0, 0, .25), 0 20px 46px rgba(0, 0, 0, .65), 0 0 70px rgba(179, 136, 255, .3); }
#stele.ring3 .stelebox { background: radial-gradient(ellipse at 50% 30%, rgba(224, 64, 251, .2), transparent 62%), repeating-linear-gradient(117deg, rgba(255, 255, 255, .025) 0 3px, transparent 3px 12px), linear-gradient(176deg, #2f2640, #211a2e 55%, #150f1f); box-shadow: inset 0 0 0 3px rgba(224, 64, 251, .25), inset 0 0 0 10px rgba(0, 0, 0, .3), 0 20px 46px rgba(0, 0, 0, .7), 0 0 80px rgba(224, 64, 251, .35); }
#stele.ring2 h2, #stele.ring3 h2 { color: #f3ecff; text-shadow: 0 0 12px rgba(209, 179, 255, .55), 0 -1px 0 rgba(0, 0, 0, .6); }
#stele.ring2 p, #stele.ring3 p { color: #e2dbee; text-shadow: 0 1px 0 rgba(0, 0, 0, .55); }
#stele.ring2 .stelering, #stele.ring2 .stelefoot, #stele.ring3 .stelering, #stele.ring3 .stelefoot { color: #c7b4e8; }
#stele.ring3 .steleeye { border-color: #e040fb; background: radial-gradient(circle, #fff 0 12%, #4a148c 13% 21%, transparent 22%), radial-gradient(ellipse 72% 40% at 50% 50%, #f3d1ff 0 52%, #9c27b0 54% 60%, transparent 62%), repeating-conic-gradient(rgba(224, 64, 251, .7) 0 5deg, transparent 5deg 30deg); box-shadow: 0 0 0 6px rgba(224, 64, 251, .2), 0 0 30px rgba(224, 64, 251, .8); }
#chrBanner { position: fixed; top: 13%; left: 50%; transform: translateX(-50%); width: min(92vw, 580px); z-index: 4; /* sous la grande carte et les fenêtres */ text-align: center; padding: 14px 28px 16px; cursor: pointer;
  background: radial-gradient(ellipse at 50% 0%, rgba(255, 213, 79, .18), transparent 70%), linear-gradient(180deg, rgba(28, 20, 9, .94), rgba(42, 29, 12, .92)); border: 2px solid #c9a227; border-radius: 6px;
  box-shadow: 0 0 0 1px #3b2a0c, 0 0 46px rgba(255, 213, 79, .35), 0 14px 30px rgba(0, 0, 0, .6); color: #f5e6c8; }
#chrBanner.show { animation: chrban 9s ease forwards; }
@keyframes chrban { 0% { opacity: 0; transform: translateX(-50%) scale(.9); } 5% { opacity: 1; transform: translateX(-50%) scale(1.03); } 8% { transform: translateX(-50%) scale(1); } 90% { opacity: 1; } 100% { opacity: 0; } }
#chrBanner small { display: block; font: 700 11.5px Cinzel, serif; letter-spacing: .24em; text-transform: uppercase; color: #ffd54f; }
#chrBanner h2 { margin: 3px 0 6px; font: 700 30px Cinzel, serif; color: #ffe9a8; text-shadow: 0 0 18px rgba(255, 213, 79, .55), 0 2px 0 #000; }
#chrBanner p { margin: 0; font: italic 500 14.5px/1.55 Georgia, serif; color: #efe2c4; }
#quests div.chr { transform: none; background: radial-gradient(ellipse at 50% 0%, rgba(255, 213, 79, .16), transparent 70%), linear-gradient(160deg, #2c2240, #1b1430); border: 2px solid #c9a227; color: #f0e6cf; box-shadow: 0 0 12px rgba(255, 213, 79, .28), 0 3px 0 #0e0a16; padding: 5px 8px 6px; }
#quests div.chr .chrh { display: block; font: 700 9px Cinzel, serif; letter-spacing: .14em; text-transform: uppercase; color: #ffd54f; }
#quests div.chr .chrt { display: block; font: 700 12.5px Cinzel, serif; color: #fff3c4; margin: 1px 0 3px; }
#quests div.chr .chrg { display: block; font-size: 10.5px; font-weight: 600; color: #e6dcc6; line-height: 1.35; }
#quests div.chr .chrg.ok { color: #aed581; } #quests div.chr .qn { color: #ffd54f; }
.chrintro { font: italic 13px/1.55 Georgia, serif; color: #4e3a22; margin: 2px 0 6px; }
.chrlist { margin: 4px 0 8px; padding-left: 0; list-style: none; }
.chrlist li { margin: 0 0 7px; padding: 6px 10px; border-left: 3px solid #c9a227; background: rgba(255, 248, 225, .35); border-radius: 2px; }
.chrlist li b { font: 700 13.5px Cinzel, serif; color: #3b2412; }
.chrlist li p { margin: 3px 0 0; font: 13px/1.5 Georgia, serif; color: #4a3826; }
.chrlist li.cur { border-left-color: #8b1e1e; background: rgba(255, 213, 79, .22); } .chrlist li.cur p { font-family: inherit; font-weight: 600; color: #6a1b1b; }
.chrlist li.lock { border-left-color: #9e9584; background: none; opacity: .6; }
.chrsteles { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 7px; margin-bottom: 8px; }
.chrs { padding: 6px 9px; border: 1px solid rgba(110, 81, 52, .45); border-radius: 3px; background: rgba(0, 0, 0, .04); opacity: .65; }
.chrs.ok { opacity: 1; background: linear-gradient(176deg, rgba(230, 224, 208, .75), rgba(203, 196, 178, .6)); border-color: #8a7a55; }
.chrs b { display: block; font: 700 12.5px Cinzel, serif; color: #3b2412; } .chrs small { font-size: 10.5px; color: #6e5134; }
.chrs p { margin: 4px 0 0; font: 12px/1.45 Georgia, serif; color: #3e3328; }
/* Plaques des lieux remarquables (§ 7.95, lot 3) : menhir moussu, journal de bord gelé, tablette de bronze */
#stele.lm0 .stelebox { background: radial-gradient(ellipse at 50% 10%, rgba(255, 236, 160, .3), transparent 55%), radial-gradient(circle at 12% 88%, rgba(107, 143, 58, .55), transparent 28%), radial-gradient(circle at 90% 80%, rgba(79, 122, 42, .45), transparent 24%), repeating-linear-gradient(117deg, rgba(0, 0, 0, .03) 0 3px, transparent 3px 12px), linear-gradient(176deg, #c9cbb6, #a8a68f 55%, #85846c); border-color: #3c4a2a; box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .3), inset 0 0 0 10px rgba(60, 74, 42, .3), 0 20px 46px rgba(0, 0, 0, .65), 0 0 80px rgba(156, 204, 101, .35); }
#stele.lm0 .steleeye { border-color: #5d7a32; box-shadow: 0 0 0 6px rgba(93, 122, 50, .2), 0 0 30px rgba(255, 226, 138, .8); }
#stele.lm1 .stelebox { color: #2b2418; border-radius: 10px; background: radial-gradient(ellipse at 50% 0%, rgba(225, 245, 254, .75), transparent 45%), repeating-linear-gradient(0deg, rgba(93, 64, 55, .1) 0 1px, transparent 1px 26px), linear-gradient(176deg, #efe3c4, #e0cfa4 60%, #c9b383); border: 6px solid #5b4330; box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .5), inset 0 -18px 30px rgba(129, 212, 250, .25), 0 20px 46px rgba(0, 0, 0, .65), 0 0 80px rgba(129, 212, 250, .45); }
#stele.lm1 .steleeye { border-color: #4f86a3; background: radial-gradient(circle, #e1f5fe 0 18%, #4fc3f7 19% 26%, transparent 27%), repeating-conic-gradient(rgba(79, 134, 163, .8) 0 4deg, transparent 4deg 45deg); box-shadow: 0 0 0 6px rgba(79, 134, 163, .2), 0 0 26px rgba(129, 212, 250, .8); }
#stele.lm2 .stelebox { color: #2a1a0a; border-radius: 14px; background: radial-gradient(ellipse at 50% 8%, rgba(255, 224, 160, .55), transparent 55%), repeating-linear-gradient(90deg, rgba(58, 36, 16, .06) 0 2px, transparent 2px 9px), linear-gradient(176deg, #d9a66a, #b9834a 55%, #8a5a2c); border: 5px solid #3a2410; box-shadow: inset 0 0 0 3px rgba(255, 220, 160, .35), inset 0 0 0 10px rgba(58, 36, 16, .25), 0 20px 46px rgba(0, 0, 0, .7), 0 0 90px rgba(255, 143, 0, .45); }
#stele.lm2 h2 { color: #2a1a0a; text-shadow: 0 1px 0 rgba(255, 230, 180, .6); } #stele.lm2 .stelering, #stele.lm2 .stelefoot { color: #4a2c10; }
#stele.lm2 .steleeye { border-color: #7a4a14; background: radial-gradient(circle, #fff3c0 0 20%, #e8b66a 21% 30%, transparent 31%), repeating-conic-gradient(rgba(122, 74, 20, .85) 0 6deg, transparent 6deg 45deg); box-shadow: 0 0 0 6px rgba(122, 74, 20, .2), 0 0 30px rgba(255, 143, 0, .8); }
#stele.lm3 .stelebox { color: #e8efe0; border-radius: 16px; background: radial-gradient(ellipse at 50% 10%, rgba(156, 204, 101, .25), transparent 55%), repeating-linear-gradient(90deg, rgba(0, 0, 0, .08) 0 3px, transparent 3px 14px), linear-gradient(176deg, #4a5a3e, #3a4630 55%, #2a3222); border: 5px solid #1b1f14; box-shadow: inset 0 0 0 3px rgba(156, 204, 101, .2), 0 20px 46px rgba(0, 0, 0, .7), 0 0 90px rgba(118, 255, 3, .25); }
#stele.lm3 h2 { color: #e8f5e0; text-shadow: 0 0 12px rgba(156, 204, 101, .6); } #stele.lm3 p { color: #dfe8d6; text-shadow: 0 1px 0 rgba(0, 0, 0, .5); } #stele.lm3 .stelering, #stele.lm3 .stelefoot { color: #b5d48a; }
#stele.lm3 .steleeye { border-color: #76ff03; background: radial-gradient(circle, #f1f8e9 0 16%, #33691e 17% 26%, transparent 27%), repeating-conic-gradient(rgba(118, 255, 3, .5) 0 5deg, transparent 5deg 40deg); box-shadow: 0 0 26px rgba(118, 255, 3, .6); }
#stele.lm4 .stelebox { color: #10261c; border-radius: 10px; background: radial-gradient(ellipse at 50% 8%, rgba(29, 233, 182, .3), transparent 55%), repeating-linear-gradient(0deg, rgba(30, 42, 28, .08) 0 2px, transparent 2px 22px), linear-gradient(176deg, #9ab894, #7f9a7a 55%, #5f7a5a); border: 5px solid #1e2a1c; box-shadow: inset 0 0 0 3px rgba(197, 225, 165, .35), 0 20px 46px rgba(0, 0, 0, .7), 0 0 90px rgba(29, 233, 182, .4); }
#stele.lm4 h2 { color: #0e2a1c; text-shadow: 0 1px 0 rgba(220, 255, 230, .5); } #stele.lm4 .stelering, #stele.lm4 .stelefoot { color: #1e4a34; }
#stele.lm4 .steleeye { border-color: #0b4a35; background: radial-gradient(circle, #e0fff5 0 16%, #1de9b6 17% 28%, transparent 29%), repeating-conic-gradient(rgba(11, 74, 53, .7) 0 6deg, transparent 6deg 45deg); box-shadow: 0 0 30px rgba(29, 233, 182, .7); }
#stele.lm5 .stelebox { color: #3a2a10; border-radius: 50% 50% 12px 12px / 18% 18% 12px 12px; background: radial-gradient(ellipse at 50% 10%, rgba(255, 248, 225, .5), transparent 55%), repeating-linear-gradient(170deg, rgba(111, 90, 50, .08) 0 2px, transparent 2px 10px), linear-gradient(176deg, #ead39a, #d6b87a 55%, #b8975a); border: 4px solid #6f5a32; box-shadow: inset 0 0 0 3px rgba(255, 255, 255, .3), 0 20px 46px rgba(0, 0, 0, .65), 0 0 90px rgba(255, 224, 130, .45); }
#stele.lm5 h2 { color: #3a2a10; } #stele.lm5 .stelering, #stele.lm5 .stelefoot { color: #6f5a32; }
#stele.lm5 .steleeye { border-color: #6f5a32; background: radial-gradient(circle, #e1f5fe 0 18%, #3aa0c8 19% 30%, transparent 31%), repeating-conic-gradient(rgba(111, 90, 50, .7) 0 5deg, transparent 5deg 36deg); box-shadow: 0 0 26px rgba(79, 195, 247, .6); }
/* délai de soin (§ 7.99) : un cadran sombre sur les aliments et les potions de soin, qui se vide jusqu'à la prochaine prise */
.hcd { position: absolute; inset: 0; border-radius: inherit; background: conic-gradient(rgba(0, 0, 0, .62) calc(var(--cd) * 1turn), transparent 0); pointer-events: none; }
/* Chili de feu (§ 7.99) : la jauge de froid barrée d'un trait de braise, tant que le repas dure */
.bar.cold.barred .fill { opacity: .35; }
.bar.cold.barred span { text-decoration: line-through; text-decoration-color: #ff7043; text-decoration-thickness: 2px; }
.bar.cold.barred::after { content: ''; position: absolute; left: 6px; right: 6px; top: 50%; height: 2px; margin-top: -1px; background: linear-gradient(90deg, transparent, #ff7043 15%, #ffab40 50%, #ff7043 85%, transparent); box-shadow: 0 0 6px #ff5722; transform: rotate(-3deg); pointer-events: none; }
/* Forteresses (§ 7.102) : ni artisanat, ni menu Bâtir, ni faim ; bandeau des îles ; Marchand de guerre */
body.fort #actions [data-panel="craft"], body.fort #actions [data-panel="build"], body.fort #actions [data-panel="tal"], body.fort #stats .bar.food, body.fort #stats .bar.xp, body.fort #clock, body.fort #biome { display: none; } /* (talents et barre d'XP : § 7.109) */
body.fort #modeHud .core { width: 150px; }
#modeHud .core.me { outline: 2px solid var(--tc); outline-offset: 3px; border-radius: 4px; }
#modeHud .core.out { opacity: .3; filter: grayscale(.7); }
#modeHud .fev { margin-top: 6px; font-size: 12px; } #modeHud .fme { font-size: 11px; margin-top: 3px; }
.fcash { display: flex; gap: 14px; justify-content: center; margin-top: 5px; font-weight: 800; font-size: 13px; }
.fcash span { display: inline-flex; align-items: center; gap: 3px; } .fcash .ci, .fortrow .ci { width: 18px; height: 18px; }
#fortCash { justify-content: flex-start; margin: 0 0 8px; }
.fortrow kbd { min-width: 16px; text-align: center; font-size: 10px; opacity: .7; border: 1px solid var(--ui-line2); border-radius: 3px; padding: 0 3px; }
.fortrow .nm small { display: block; margin-left: 0 !important; font-weight: 600; opacity: .75; }
.fortrow .fp { display: inline-flex; align-items: center; gap: 2px; color: var(--c); white-space: nowrap; } .fortrow .fp.no { color: #ff6e6e; }
.fortrow.own { opacity: .55; } .fortrow .fok { color: #9ccc65; font-size: 11px; white-space: nowrap; }
/* Forteresses : l'interface en cinq secondes (§ 7.111) — bandeau des équipes, annonces, carte de la salle d'attente et de la fin de manche,
   Marchand de guerre mis à jour sur place, monnaies à gauche, classement par équipe, aide de pose, écran de mort ; la Survie cachée */
body.fort #coords, body.fort #quests, body.fort #tuto, body.fort #levelup, body.fort #stats .bar.xp, body.fort #actions [data-panel="tal"], body.fort #bigmap .legend:not(.fortlegend), body:not(.fort) #bigmap .fortlegend, body.fort #horseBtn { display: none !important; } /* (niveaux, bonus au niveau et talents : la progression de la Survie) */
#bigmap .fortlegend .fl-isle { color: #e0b866; font-weight: 800; } #bigmap .fortlegend .fl-core { color: #ff5252; } #bigmap .fortlegend .fl-sap { color: #3d6fd8; } #bigmap .fortlegend .fl-em { color: #1f9e5a; }
/* bandeau du haut : une pastille par équipe (la sienne d'abord), l'alerte, le prochain événement */
body.fort #modeHud { padding: 6px 10px 6px; min-width: 0; width: max-content; max-width: calc(100vw - 16px); box-sizing: border-box; } /* (left: 50% ne laisse que la moitié de l'écran au calcul de la largeur : sur téléphone en portrait, les pastilles passaient à la ligne à trois) */
#modeHud .fteams { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
#modeHud .ft { width: 104px; box-sizing: border-box; padding: 3px 7px 4px 9px; border-radius: 4px; text-align: left; background: rgba(0, 0, 0, .32); border: 1px solid rgba(0, 0, 0, .55); box-shadow: inset 3px 0 0 var(--tc); }
#modeHud .ft.me { background: rgba(255, 240, 210, .09); border-color: var(--tc); }
#modeHud .ft .ftn { display: flex; align-items: baseline; gap: 4px; line-height: 1.25; }
#modeHud .ft .ftn b { color: var(--tc); font: 700 12.5px var(--fw-fl); text-shadow: 0 1px 0 #000; }
#modeHud .ft em { font: 800 8.5px var(--fb); font-style: normal; text-transform: uppercase; letter-spacing: .08em; color: #1b1208; background: var(--tc); border-radius: 3px; padding: 0 3px; }
#modeHud .ft .fal { margin-left: auto; font-size: 11px; font-weight: 700; color: var(--ui-text); font-variant-numeric: tabular-nums; }
#modeHud .ft .cb { position: relative; height: 7px; margin-top: 3px; background: rgba(0, 0, 0, .6); border: 1px solid rgba(0, 0, 0, .7); border-radius: 4px; overflow: hidden; }
#modeHud .ft .cb i { display: block; height: 100%; background: linear-gradient(180deg, rgba(255, 255, 255, .45), rgba(255, 255, 255, 0) 60%), var(--tc); transition: width .35s; }
#modeHud .ft.nocore .cb { height: auto; background: none; border: 0; } #modeHud .ft.nocore .cb span { display: block; font-size: 10px; font-weight: 700; color: #ff8a80; }
#modeHud .ft.out { opacity: .38; filter: grayscale(.8); }
#modeHud .ft.hit { animation: fhit .45s ease-in-out infinite alternate; }
@keyframes fhit { to { background: rgba(255, 23, 68, .42); box-shadow: inset 3px 0 0 #ff1744, 0 0 14px rgba(255, 23, 68, .85); } }
#modeHud .falert.out { color: #d7ccc8; }
#modeHud .falert { margin-top: 5px; color: #ff8a80; font-weight: 800; font-size: 12.5px; display: flex; align-items: center; justify-content: center; text-shadow: 0 1px 0 #000; }
#modeHud .fev { margin-top: 4px; font-size: 12px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; color: var(--ui-text); }
#modeHud .fev b { margin-left: 4px; font-variant-numeric: tabular-nums; }
#modeHud .fev .ftier { display: inline-flex; align-items: center; gap: 2px; margin-left: 9px; padding-left: 9px; border-left: 1px solid rgba(255, 255, 255, .18); font: 700 11px var(--fw-fl); }
#modeHud .fev .ci { width: 15px; height: 15px; }
#modeHud .fev.fsd { margin-top: 5px; padding: 2px 10px; border-radius: 10px; color: #ffd1df; font-weight: 700; background: linear-gradient(90deg, rgba(110, 0, 30, 0), rgba(150, 10, 50, .62) 18%, rgba(150, 10, 50, .62) 82%, rgba(110, 0, 30, 0)); text-shadow: 0 0 8px rgba(255, 45, 111, .8); animation: fsdPulse 1.6s ease-in-out infinite; } /* la mort subite (§ 7.122) */
#modeHud .fev.fsd b { color: #fff; } #modeHud .fev.fsoon { color: #ffb3c4; } #modeHud .fev.fsoon b { color: #ff6f91; }
@keyframes fsdPulse { 50% { box-shadow: 0 0 14px rgba(255, 45, 111, .45); } }
/* annonces : un grand bandeau au milieu, aux couleurs de l'événement */
#fortBanner { position: fixed; top: 21%; left: 50%; transform: translateX(-50%); width: min(92vw, 560px); box-sizing: border-box; z-index: 4; pointer-events: none; text-align: center; padding: 12px 24px 14px; color: #f5e6c8;
  background: radial-gradient(ellipse at 50% 0%, color-mix(in srgb, var(--tc) 32%, transparent), transparent 72%), linear-gradient(180deg, rgba(24, 16, 8, .95), rgba(40, 27, 12, .93));
  border: 2px solid var(--tc); border-radius: 6px; box-shadow: 0 0 0 1px #140b04, 0 0 46px color-mix(in srgb, var(--tc) 50%, transparent), 0 14px 30px rgba(0, 0, 0, .6); }
#fortBanner.show { animation: fban 4.6s ease forwards; }
@keyframes fban { 0% { opacity: 0; transform: translateX(-50%) scale(.86); } 6% { opacity: 1; transform: translateX(-50%) scale(1.04); } 10% { transform: translateX(-50%) scale(1); } 86% { opacity: 1; } 100% { opacity: 0; transform: translateX(-50%) translateY(-10px); } }
#fortBanner small { display: block; font: 700 11px var(--fw-fl); letter-spacing: .22em; text-transform: uppercase; color: var(--tc); text-shadow: 0 1px 0 #000; }
#fortBanner h2 { margin: 2px 0 4px; font: 400 38px/1.1 var(--fw-fh); color: #fff3d0; text-shadow: 0 0 18px var(--tc), 0 3px 0 #000; }
#fortBanner p { margin: 0; font: 700 14px var(--fb); color: #efe2c4; }
#fortBanner p:empty { display: none; }
#fortBanner.big h2 { font-size: 48px; }
#fortBanner.red { animation: fban 4.6s ease forwards, fshake .5s .05s; }
@keyframes fshake { 20%, 60% { margin-left: -6px; } 40%, 80% { margin-left: 6px; } }
/* salle d'attente et fin de manche : la carte du milieu */
#fortCard { position: absolute; top: 58px; left: 50%; transform: translateX(-50%); width: min(94vw, 620px); box-sizing: border-box; z-index: 2; pointer-events: none; text-align: center; padding: 12px 20px 14px; }
/* (§ 7.125) carte des Forteresses (salle d'attente, fin de manche) : entre les jauges et la colonne de droite, plus sur les jauges (1077 × 606 : 36 px
   de la barre de vie cachés ; 821 × 462 : 39 px) ; jamais moins de 340 px */
#fortCard { width: max(340px, min(94vw, 620px, calc(100vw - 564px))); }
@media (max-width: 800px), (max-height: 540px) { #fortCard { width: max(340px, min(94vw, 620px, calc(100vw - 452px))); } }
#fortCard .fch { font: 400 36px/1 var(--fw-fh); color: var(--fw-cream); text-shadow: 0 3px 0 rgba(0, 0, 0, .6), 0 0 22px rgba(224, 184, 102, .35); }
#fortCard .fch.win { color: #ffe082; text-shadow: 0 3px 0 #000, 0 0 26px rgba(255, 213, 79, .8); }
#fortCard .fch.lose { color: #ff8a80; text-shadow: 0 3px 0 #000, 0 0 22px rgba(255, 82, 82, .55); }
#fortCard .fcc { margin: 4px 0 8px; font-size: 14px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: 4px; flex-wrap: wrap; }
#fortCard .fcc .fnum { font: 400 30px/1 var(--fw-fh); color: #ffd54f; margin: 0 2px; }
#fortCard .fgoals { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 2px 0 8px; }
#fortCard .fgoals > div { display: grid; grid-template-columns: 30px 1fr; grid-template-rows: auto auto; column-gap: 6px; align-items: center; text-align: left; padding: 5px 6px; border-radius: 5px; background: rgba(0, 0, 0, .28); border: 1px solid rgba(0, 0, 0, .5); }
#fortCard .fgoals .fgi { grid-row: 1 / 3; }
#fortCard .fgoals b { font: 700 12px/1.15 var(--fw-fl); color: #ffe9b0; } #fortCard .fgoals small { font-size: 10.5px; color: var(--ui-dim); line-height: 1.2; }
#fortCard .fgi { width: 30px; height: 30px; display: block; }
#fortCard .fvoid { border-radius: 50%; background: radial-gradient(circle at 50% 50%, #000 0 30%, #2a0d4a 46%, #7c3aed 62%, transparent 66%), radial-gradient(circle at 50% 50%, rgba(167, 139, 250, .5), transparent 70%); box-shadow: 0 0 10px rgba(124, 58, 237, .8); }
#fortCard .fsteps { list-style: none; margin: 0 0 10px; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; counter-reset: fs; }
#fortCard .fsteps li { counter-increment: fs; display: flex; align-items: center; gap: 4px; text-align: left; font-size: 10.5px; line-height: 1.2; color: var(--ui-text); }
#fortCard .fsteps li::before { content: counter(fs); flex: none; width: 14px; height: 14px; border-radius: 50%; background: var(--fw-brass); color: #1b1208; font: 800 9.5px/14px var(--fb); text-align: center; }
#fortCard .fsteps .ci { width: 20px; height: 20px; flex: none; } #fortCard .fsteps span { display: block; } #fortCard .fsteps b { display: block; color: #ffe9b0; font-size: 11px; }
#fortCard kbd { font: 700 10px var(--fb); border: 1px solid var(--ui-line2); border-radius: 3px; padding: 0 4px; background: rgba(0, 0, 0, .35); }
#fortCard .froster { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; }
#fortCard .froster > div { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 5px; padding: 4px 8px; border-radius: 4px; background: rgba(0, 0, 0, .3); border: 1px solid rgba(0, 0, 0, .55); box-shadow: inset 0 3px 0 var(--tc); max-width: 260px; }
#fortCard .froster > div.me { border-color: var(--tc); }
#fortCard .froster b { color: var(--tc); font: 700 12px var(--fw-fl); margin-right: 2px; } #fortCard .froster span { font-size: 12px; } #fortCard .froster span.me { color: #ffe082; font-weight: 800; }
#fortCard .fsb { width: 100%; border-collapse: collapse; font-size: 12.5px; margin: 2px 0 8px; }
#fortCard .fsb th { font: 700 10px var(--fw-fl); text-transform: uppercase; letter-spacing: .06em; color: var(--ui-dim); padding: 2px 4px; text-align: center; }
#fortCard .fsb td { padding: 2px 6px; text-align: center; font-variant-numeric: tabular-nums; border-bottom: 1px solid rgba(255, 255, 255, .06); }
#fortCard .fsb td:first-child { text-align: left; font-weight: 700; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#fortCard .fsb tr.fth td { text-align: left; font: 700 12px var(--fw-fl); color: var(--tc); padding-top: 6px; border-bottom: 2px solid var(--tc); }
#fortCard .fsb tr.me td { background: rgba(255, 224, 130, .12); color: #ffe082; }
#fortCard .fcn { font-size: 12px; color: var(--ui-dim); }
/* La fin de manche peaufinée (§ 7.122) : le vainqueur entre deux blasons à sa couleur, pourquoi, combien de temps, le meilleur joueur, la jauge du retour */
#fortCard .fwin { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 4px 0 2px; font-size: 14px; font-weight: 600; }
#fortCard .fwin span { display: inline-flex; align-items: center; gap: 4px; } #fortCard .fwin b { color: var(--tc); font: 700 16px var(--fw-fl); text-shadow: 0 1px 0 #000, 0 0 12px var(--tc); }
#fortCard .fcrest { flex: none; width: 22px; height: 27px; background: linear-gradient(160deg, rgba(255, 255, 255, .55), transparent 45%), var(--tc); clip-path: polygon(0 0, 100% 0, 100% 58%, 50% 100%, 0 58%); box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .35); filter: drop-shadow(0 0 6px var(--tc)); }
#fortCard .fwhy { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 2px 7px; margin: 2px 0 6px; font-size: 11.5px; color: var(--ui-dim); }
#fortCard .fwhy > span { display: inline-flex; align-items: center; gap: 3px; } #fortCard .fwhy em { font-style: normal; opacity: .5; } #fortCard .fwhy .ei { width: 14px; height: 14px; }
#fortCard .fwhy .fsdk { color: #ff8fb1; font-weight: 700; }
#fortCard .falv { display: inline-flex; gap: 5px; margin-left: 4px; } #fortCard .falv span { display: inline-flex; align-items: center; gap: 2px; font: 700 12px var(--fw-fl); color: #fff4dc; }
#fortCard .falv i { width: 8px; height: 8px; border-radius: 2px; transform: rotate(45deg); background: var(--tc); box-shadow: 0 0 5px var(--tc); }
#fortCard .fmvp { display: flex; align-items: center; justify-content: center; gap: 7px; margin: 0 auto 6px; padding: 4px 12px; max-width: 92%; border-radius: 16px; background: linear-gradient(90deg, transparent, rgba(0, 0, 0, .4) 15%, rgba(0, 0, 0, .4) 85%, transparent); box-shadow: inset 0 -2px 0 var(--tc); }
#fortCard .fmvp small { font: 700 10px var(--fw-fl); letter-spacing: .08em; text-transform: uppercase; color: #ffe082; } #fortCard .fmvp b { color: var(--tc); font: 700 15px var(--fw-fl); text-shadow: 0 1px 0 #000; }
#fortCard .fmvp span { font-size: 11.5px; color: #f3e6cc; } #fortCard .fmvp .fmvs { width: 18px; height: 18px; filter: drop-shadow(0 0 5px #ffd54f); animation: fmvGlow 1.8s ease-in-out infinite; }
@keyframes fmvGlow { 50% { transform: scale(1.18) rotate(12deg); } }
#fortCard .fsb .fmv { width: 13px; height: 13px; vertical-align: -2px; }
#fortCard .fsb td.z { color: rgba(255, 244, 220, .32); }
#fortCard .fsbg { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; align-items: start; } /* beaucoup de joueurs : deux colonnes (§ 7.122) */
#fortCard .fsbg .fsb { font-size: 11.5px; margin-bottom: 4px; } #fortCard .fsbg .fsb td { padding: 1px 4px; } #fortCard .fsbg .fsb th { padding: 1px 2px; font-size: 9px; letter-spacing: .02em; } #fortCard .fsbg .fsb td:first-child { max-width: 96px; }
#fortCard .fsbg .fsb tr.fth td { padding-top: 3px; font-size: 11px; }
#fortCard .fsbz { display: none; }
#fortCard .fsb tbody.fw tr.fth td { text-shadow: 0 0 10px var(--tc); }
#fortCard .fcn { display: flex; flex-direction: column; align-items: center; gap: 3px; }
#fortCard .fcbar { display: block; width: 46%; height: 4px; border-radius: 2px; background: rgba(0, 0, 0, .45); overflow: hidden; } #fortCard .fcbar i { display: block; height: 100%; background: linear-gradient(90deg, #b8862e, #ffe082); transition: width 1s linear; }
@media (max-height: 540px) { #fortCard.end .fch { font-size: 22px; } #fortCard .fwin { margin: 2px 0 0; } #fortCard .fsbg .fsb { font-size: 10.5px; } #fortCard .fsbg .fsb th { font-size: 8px; } #fortCard .fsbg .fsb td:first-child { max-width: 70px; } #fortCard .fmvp { padding: 2px 10px; margin-bottom: 3px; } #fortCard .fmvp span { display: none; } #fortCard .fwhy { margin-bottom: 3px; font-size: 10.5px; } #fortCard .fwin { font-size: 12.5px; } #fortCard .fwin b { font-size: 14px; } #fortCard .fcrest { width: 17px; height: 21px; } }
/* Marchand de guerre : onglets sur une ligne, lignes cliquables, l'état en clair */
#fortPanel .plank-title { display: flex; align-items: center; gap: 6px; } #fortPanel .plank-title small { margin-right: auto; }
#fortClose { width: 26px; height: 26px; font-size: 13px; }
#fortTabs { flex-wrap: nowrap; gap: 3px; } #fortTabs div { flex: 1 1 auto; min-width: 0; text-align: center; padding: 5px 3px; font-size: 9.5px; letter-spacing: 0; white-space: nowrap; }
#fortCash .zero { opacity: .45; }
.fortrow { display: flex; align-items: center; gap: 7px; padding: 5px 6px; margin: 0 -6px; border-radius: 4px; cursor: pointer; border-bottom: 1px solid var(--ui-line); font-size: 12.5px; font-weight: 800; user-select: none; }
.fortrow:hover { background: rgba(255, 220, 150, .09); } .fortrow.ok:active { background: rgba(255, 220, 150, .18); }
.fortrow .icon { width: 26px; height: 26px; flex: none; }
.fortrow .nm { flex: 1; min-width: 0; }
.fortrow .fbuy { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex: none; }
.fortrow .fpr { display: inline-flex; gap: 6px; font-size: 13px; }
.fortrow .fst { font-size: 10.5px; font-weight: 800; padding: 1px 7px; border-radius: 3px; white-space: nowrap; }
.fortrow.ok .fst { background: linear-gradient(180deg, #7aa332, #4f6e1b); color: #f6ffe4; border: 1px solid #2c3f0d; text-shadow: 0 1px 0 rgba(0, 0, 0, .4); }
.fortrow.poor .fst { color: #ff8a80; } .fortrow.poor { cursor: not-allowed; }
.fortrow.own .fst { color: #9ccc65; } .fortrow.lock .fst { color: #d9c39a; white-space: normal; text-align: right; max-width: 120px; }
.fortrow.own, .fortrow.lock { opacity: .55; cursor: default; } .fortrow.own .fpr, .fortrow.lock .fpr { display: none; }
.fortrow.nope { animation: fnope .35s; } @keyframes fnope { 20%, 60% { transform: translateX(-4px); } 40%, 80% { transform: translateX(4px); } }
.fhelp { margin-top: 8px; font-size: 10.5px; line-height: 1.4; color: var(--ui-dim); text-align: center; } .fhelp kbd { font: 700 9.5px var(--fb); border: 1px solid var(--ui-line2); border-radius: 3px; padding: 0 3px; }
body.touch .fhelp { display: none; }
/* monnaies : toujours les quatre, à gauche sous les jauges */
.res.fpurse { min-width: 96px; } .res.fpurse b { color: var(--c); font-variant-numeric: tabular-nums; min-width: 16px; text-align: right; } .res.fpurse .ci { width: 17px; height: 17px; }
.res.fpurse.zero { opacity: .5; }
/* classement : par équipe */
body.fort #leaderboard ol { padding-left: 0; list-style: none; }
body.fort #leaderboard li.flt { margin: 5px 0 1px; padding: 2px 6px; border-radius: 3px; background: linear-gradient(90deg, var(--tc), rgba(255, 255, 255, 0) 90%); color: #1b1208; font-weight: 800; }
body.fort #leaderboard li.flt:first-child { margin-top: 0; } body.fort #leaderboard li.flt.mine { box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .4); } body.fort #leaderboard li.flt.out { opacity: .45; text-decoration: line-through; }
body.fort #leaderboard li.flp { padding-left: 12px; } body.fort #leaderboard li.flp.me { color: var(--fw-red); font-weight: 800; }
.fcore { display: inline-block; width: 7px; height: 7px; margin-left: 3px; transform: rotate(45deg); background: #1b1208; border: 1px solid rgba(255, 255, 255, .9); vertical-align: 1px; } .fcore.off { background: none; border-color: rgba(0, 0, 0, .55); }
/* aide de pose au-dessus de la barre ; le bouton F tactile près du Marchand */
#fortHint { display: none; }
#fortHint:not(:empty) { display: block; padding: 3px 12px; border-radius: 3px; background: rgba(36, 21, 9, .82); border: 1px solid rgba(0, 0, 0, .6); color: #f1e4c6; font: 600 12px var(--fb); white-space: nowrap; pointer-events: none; }
body.fort #useBtn.hot { box-shadow: 0 0 0 3px rgba(255, 213, 79, .45), 0 0 20px rgba(255, 213, 79, .9); animation: fuse .8s ease-in-out infinite alternate; }
@keyframes fuse { to { transform: scale(1.08); } }
/* écran de mort du mode : perdu, gardé */
.fdl { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 6px; margin: 3px 0; font-size: 13px; }
body.fort #death.spec { align-items: flex-end; padding-top: 0; padding-bottom: 10px; } body.fort #death.spec .deathbox { transform-origin: bottom center; } /* éliminé : la fenêtre en bas (la barre ne sert plus), le bandeau des équipes et le joueur suivi restent visibles */
.fdl > b { font: 700 10.5px var(--fw-fl); text-transform: uppercase; letter-spacing: .12em; color: #6e5134; min-width: 52px; text-align: right; }
.fdl span { display: inline-flex; align-items: center; gap: 2px; font-weight: 800; color: #3a2614; } .fdl .ci { width: 22px; height: 22px; } .fdl small { color: #7a5c3c; font-size: 11px; font-weight: 600; }
@media (max-width: 800px), (max-height: 540px) {
  body.fort #modeHud { top: 40px; padding: 4px 6px; } #modeHud .ft { width: 82px; padding: 2px 5px 3px 7px; } #modeHud .ft .ftn b { font-size: 11px; } #modeHud .ft em { display: none; } #modeHud .fev { font-size: 10.5px; } #modeHud .fev .ftier { margin-left: 6px; padding-left: 6px; }
  #fortBanner { top: 30%; padding: 8px 14px 10px; } #fortBanner h2, #fortBanner.big h2 { font-size: 30px; } #fortBanner p { font-size: 12px; }
  #fortCard { top: 40px; padding: 8px 12px 10px; } #fortCard .fch { font-size: 30px; } #fortCard .fgoals small, #fortCard .fsteps { display: none; } #fortCard .fgi { width: 26px; height: 26px; }
  #fortCard .fsb { font-size: 11.5px; } #fortCard .fsb td:first-child { max-width: 110px; }
  #fortPanel .plank-title { font-size: 20px; } #fortPanel .plank-title small { display: none; }
  #fortHint:not(:empty) { position: absolute; left: 50%; bottom: 64px; transform: translateX(-50%); white-space: normal; max-width: 64vw; text-align: center; font-size: 11px; }
}
@media (max-width: 520px) { body.fort #modeHud { top: 162px; max-width: calc(100vw - 16px); } #fortCard { top: 150px; width: calc(100vw - 16px); } #fortBanner { top: 36%; } #fortHint:not(:empty) { bottom: 128px; max-width: 86vw; } }
@media (max-height: 540px) { .fortrow .nm small { display: none; } #fortCard .fgoals { margin: 0 0 4px; gap: 4px; } #fortCard .fgoals > div { grid-template-columns: 20px 1fr; padding: 2px 5px; } #fortCard .fgi { width: 20px; height: 20px; } #fortCard .fgoals b { font-size: 10.5px; } #fortCard { top: 6px; width: min(52vw, 420px); } #fortCard .fch { font-size: 24px; } #fortCard .fcc { margin: 2px 0 4px; font-size: 12px; } #fortCard .fcc .fnum { font-size: 22px; } #fortCard.end { top: 40px; width: min(60vw, 480px); max-height: calc(100vh - 110px); overflow: hidden; } }
/* Forteresses : la salle d'attente (§ 7.117) : un bandeau en haut (format, compte à rebours, places par équipe, son équipe prévue, les équipes) pour
   laisser voir la plateforme ; les buts et le chemin d'une partie en bas ; huit pastilles d'équipe compactes en partie */
:root { --Violet: #b388ff; --Rose: #ff7ad9; --Orange: #ff9a3d; --Blanc: #f2eee4; }
.Violet { color: var(--Violet) !important; } .Rose { color: var(--Rose) !important; } .Orange { color: var(--Orange) !important; } .Blanc { color: var(--Blanc) !important; }
#fortCard.wait { top: 10px; width: min(94vw, 600px); padding: 8px 14px 9px; }
#fortCard.wait .fwh { display: flex; align-items: center; justify-content: center; gap: 10px; }
#fortCard.wait .fch { font-size: 30px; }
#fortCard .ffmt { display: inline-flex; flex-direction: column; align-items: center; padding: 2px 9px 3px; border-radius: 4px; background: linear-gradient(180deg, #e9c46a, #b8862e); color: #1b1208; font: 800 13px/1.1 var(--fw-fl); letter-spacing: .06em; text-transform: uppercase; box-shadow: inset 0 1px 0 rgba(255, 255, 255, .55), 0 2px 0 rgba(0, 0, 0, .5); }
#fortCard .ffmt small { font: 700 9px/1.1 var(--fb); letter-spacing: .02em; opacity: .75; }
#fortCard .fwc { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 4px 0 5px; font-size: 14px; font-weight: 600; }
#fortCard .fwc .fnum { font: 400 34px/1 var(--fw-fh); color: #ffd54f; min-width: 30px; text-shadow: 0 2px 0 #000, 0 0 16px rgba(255, 179, 0, .6); }
#fortCard .fwc .fnum.hot { color: #fff8e1; animation: fwhot 1s ease-out infinite; }
@keyframes fwhot { 0% { transform: scale(1.35); text-shadow: 0 2px 0 #000, 0 0 30px #fff; } 100% { transform: scale(1); } }
#fortCard .fseats { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 5px; margin-bottom: 5px; }
#fortCard .fseats > span { display: inline-flex; gap: 2px; padding: 2px 3px; border-radius: 3px; background: rgba(0, 0, 0, .35); box-shadow: inset 0 -2px 0 var(--tc); }
#fortCard .fseats > span.me { outline: 1px solid var(--tc); }
#fortCard .fseats i { width: 9px; height: 9px; border-radius: 2px; transform: rotate(45deg); margin: 2px; background: rgba(255, 255, 255, .12); border: 1px solid rgba(0, 0, 0, .6); }
#fortCard .fseats i.on { background: var(--tc); border-color: rgba(255, 255, 255, .85); box-shadow: 0 0 6px var(--tc); }
#fortCard .fseats b { margin-left: 4px; font: 700 13px var(--fw-fl); color: #ffe9b0; font-variant-numeric: tabular-nums; } #fortCard .fseats small { color: var(--ui-dim); font-size: 11px; }
#fortCard .fmine { margin-bottom: 5px; font-size: 13px; } #fortCard .fmine b { color: var(--tc); font: 700 14px var(--fw-fl); text-shadow: 0 1px 0 #000; } #fortCard .fmine small { color: var(--ui-dim); }
#fortCard .fmine.out { color: #ffcc80; display: flex; align-items: center; justify-content: center; }
#fortCard.wait .froster > div { padding: 2px 7px; } #fortCard.wait .froster b { font-size: 11px; } #fortCard.wait .froster span { font-size: 11px; }
#fortTips { position: absolute; left: 50%; bottom: 84px; transform: translateX(-50%); width: min(94vw, 640px); box-sizing: border-box; z-index: 2; pointer-events: none; padding: 7px 10px 6px; border-radius: 6px; background: rgba(20, 13, 8, .72); border: 1px solid rgba(0, 0, 0, .6); box-shadow: 0 10px 30px rgba(0, 0, 0, .45); }
#fortTips .fgoals { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 0 0 6px; }
#fortTips .fgoals > div { display: grid; grid-template-columns: 28px 1fr; grid-template-rows: auto auto; column-gap: 6px; align-items: center; text-align: left; padding: 4px 6px; border-radius: 5px; background: rgba(0, 0, 0, .3); border: 1px solid rgba(0, 0, 0, .5); }
#fortTips .fgoals .fgi { grid-row: 1 / 3; width: 28px; height: 28px; display: block; }
#fortTips .fgoals b { font: 700 12px/1.15 var(--fw-fl); color: #ffe9b0; } #fortTips .fgoals small { font-size: 10.5px; color: var(--ui-dim); line-height: 1.2; }
#fortTips .fvoid { border-radius: 50%; background: radial-gradient(circle at 50% 50%, #000 0 30%, #2a0d4a 46%, #7c3aed 62%, transparent 66%), radial-gradient(circle at 50% 50%, rgba(167, 139, 250, .5), transparent 70%); box-shadow: 0 0 10px rgba(124, 58, 237, .8); }
#fortTips .fsteps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; counter-reset: fs; }
#fortTips .fsteps li { counter-increment: fs; display: flex; align-items: center; gap: 4px; text-align: left; font-size: 10.5px; line-height: 1.2; color: var(--ui-text); }
#fortTips .fsteps li::before { content: counter(fs); flex: none; width: 14px; height: 14px; border-radius: 50%; background: var(--fw-brass); color: #1b1208; font: 800 9.5px/14px var(--fb); text-align: center; }
#fortTips .fsteps .ci { width: 20px; height: 20px; flex: none; } #fortTips .fsteps span { display: block; } #fortTips .fsteps b { display: block; color: #ffe9b0; font-size: 11px; }
#fortTips kbd { font: 700 10px var(--fb); border: 1px solid var(--ui-line2); border-radius: 3px; padding: 0 4px; background: rgba(0, 0, 0, .35); }
#modeHud .fteams.many { gap: 4px; max-width: min(96vw, 820px); } #modeHud .fteams.many .ft { width: 92px; padding: 2px 5px 3px 7px; } #modeHud .fteams.many .ft .ftn b { font-size: 11.5px; }
@media (max-width: 800px), (max-height: 540px) {
  #modeHud .fteams.many { display: grid; grid-template-columns: repeat(4, 76px); justify-content: center; gap: 3px; } #modeHud .fteams.many .ft { width: auto; padding: 1px 3px 2px 5px; } /* (8 pastilles : deux rangées de quatre, sans toucher les boutons de droite à 821 × 462) */ #modeHud .fteams.many .ft .ftn b { font-size: 10px; } #modeHud .fteams.many .ft .fal { font-size: 9.5px; } #modeHud .fteams.many .ft .cb { height: 5px; margin-top: 2px; }
  #fortCard.wait { top: 6px; padding: 5px 10px 6px; width: min(60vw, 470px); } #fortCard.wait .fch { font-size: 22px; } #fortCard .ffmt { font-size: 11px; padding: 1px 7px 2px; } #fortCard .fwc { margin: 2px 0 3px; font-size: 12px; } #fortCard .fwc .fnum { font-size: 24px; }
  #fortCard .fseats { gap: 3px; margin-bottom: 3px; } #fortCard .fseats i { width: 7px; height: 7px; margin: 1.5px; } #fortCard .fmine { font-size: 11.5px; margin-bottom: 3px; } #fortCard.wait .froster { display: none; }
  #fortTips { bottom: 66px; width: min(80vw, 560px); padding: 4px 6px; } #fortTips .fgoals { margin: 0; gap: 4px; } #fortTips .fgoals > div { grid-template-columns: 20px 1fr; padding: 2px 5px; } #fortTips .fgoals .fgi { width: 20px; height: 20px; } #fortTips .fgoals b { font-size: 10.5px; } #fortTips .fgoals small, #fortTips .fsteps { display: none; }
}
body.fwait #hotbar, body.fwait #aboveBar { display: none; } body.fwait #fortTips { bottom: 14px; } /* (§ 7.117 : la salle d'attente, les mains vides) */
/* (§ 7.125) la salle d'attente entre les jauges et les boutons de droite (cadre de CrazyGames : 821 × 462, 907 × 510, 1077 × 606) ; la barre du
   haut, cachée dessous, s'efface le temps de l'attente sur petit écran */
#fortCard.wait { width: max(340px, min(94vw, 600px, calc(100vw - 564px))); }
@media (max-width: 800px), (max-height: 540px) { #fortCard.wait { width: max(320px, min(60vw, 470px, calc(100vw - 452px))); } body.fwait #topbar { visibility: hidden; } }
#fortCard .fsb tr.fsolo td:first-child { color: var(--tc); } #fortCard .fsb tr.fsolo td:first-child i { display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 2px; transform: rotate(45deg); background: var(--tc); box-shadow: 0 0 5px var(--tc); } /* (Solo : une ligne par joueur, § 7.117) */
#killfeed .Violet { color: #a98be0 !important; } #killfeed .Rose { color: #e083c4 !important; } #killfeed .Orange { color: #e39a5a !important; } #killfeed .Blanc { color: #e8e4da !important; } /* (les quatre équipes de plus, § 7.117) */
/* Forteresses : sept onglets au Marchand de guerre (Potions et Utilitaires, § 7.121) : deux rangées de cases égales plutôt qu'une ligne où les noms se chevauchent */
#fortTabs { flex-wrap: wrap; } #fortTabs div { flex: 1 0 22%; font-size: 10px; }
/* Maître de forteresse (§ 7.120) : le panneau du Marchand de guerre, aux couleurs du Maître ; paliers en pastilles, file des pièges ; une ligne dans le bandeau du haut */
#fmPanel { box-shadow: 0 0 0 1px rgba(179, 136, 255, .35), 0 0 28px rgba(124, 77, 255, .25), 0 10px 30px rgba(0, 0, 0, .5); }
#fmPanel .plank-title { display: flex; align-items: center; gap: 6px; } #fmPanel .plank-title small { margin-right: auto; }
#fmClose { width: 26px; height: 26px; font-size: 13px; }
#fmTabs { flex-wrap: nowrap; gap: 3px; } #fmTabs div { flex: 1 1 50%; text-align: center; padding: 5px 3px; font-size: 11px; }
#fmCash .zero { opacity: .45; }
.fmnote { font-size: 11px; color: var(--ui-dim); text-align: center; margin: 5px 0 3px; } .fmnote b { color: #d1b3ff; }
.fmrow .fmn { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; } .fmrow .fmtier { margin-bottom: 1px; }
.fmtier { display: inline-flex; gap: 2px; } .fmtier i { font: 800 9px var(--fb); font-style: normal; min-width: 18px; padding: 1px 3px; text-align: center; border-radius: 3px; border: 1px solid rgba(179, 136, 255, .45); color: rgba(209, 179, 255, .6); background: rgba(40, 20, 70, .35); }
.fmtier i.on { background: linear-gradient(180deg, #9c6bff, #5b32c9); color: #fff; border-color: #2e1470; box-shadow: 0 0 6px rgba(179, 136, 255, .7); }
.fmtier i.nx { color: #fff4dc; border-color: #ffd54f; animation: fmnx 1.4s ease-in-out infinite; } @keyframes fmnx { 50% { box-shadow: 0 0 8px rgba(255, 213, 79, .85); } }
.fmrow .fp em { font-style: normal; }
.fmq { text-align: center; margin: 6px 0 4px; padding: 7px 6px 6px; border-radius: 6px; background: rgba(40, 20, 70, .35); border: 1px solid rgba(179, 136, 255, .35); } .fmq > b { font-size: 11.5px; color: #d1b3ff; }
.fmslots { display: flex; justify-content: center; gap: 12px; margin: 6px 0 4px; }
.fmslot { display: inline-flex; flex-direction: column; align-items: center; gap: 1px; font-size: 10px; color: var(--ui-dim); } .fmslot .fmi { width: 34px; height: 34px; margin: 0; } .fmslot.on small { color: #e8dcff; font-weight: 800; }
.fmq small.fmqn { display: block; font-size: 10.5px; color: var(--ui-dim); line-height: 1.35; }
#modeHud .fmhud { display: flex; align-items: center; justify-content: center; gap: 7px; margin-top: 3px; font-size: 10.5px; }
#modeHud .fmhud > span { display: inline-flex; align-items: center; gap: 1px; } #modeHud .fmhud .fmi { width: 18px; height: 18px; margin: 0; } #modeHud .fmhud b { color: #d1b3ff; font-size: 10px; }
#modeHud .fmhq { padding-left: 7px; border-left: 1px solid rgba(255, 255, 255, .2); gap: 2px !important; } #modeHud .fmhq .fmslot .fmi { width: 16px; height: 16px; }
#fortBanner.fmb h2 { color: #f3eeff; } #fortBanner.fmb, #fortBanner.fmv { top: auto; bottom: 104px; } /* (en bas : en haut, le bandeau cachait l'intrus, et le trou de lumière de qui est aveuglé) */
@media (max-height: 540px) { .fmnote, .fmq small.fmqn { display: none; } .fmslot .fmi { width: 26px; height: 26px; } #fmPanel .plank-title { font-size: 20px; } #fmPanel .plank-title small { display: none; } #fortBanner.fmb, #fortBanner.fmv { bottom: 72px; } }
/* Publicités de CrazyGames (§ 7.129) : créés par client/game.js seulement si le paquet les active (ARENA_ADS). Écran de mort : « Réapparaître »
   et « Regarder une pub » côte à côte, même planche, même taille, même police, même couleur (exigence : le choix sans pub ne doit pas paraître
   moindre) ; le voile qui bloque le jeu pendant la demande et la vidéo ; la bannière du menu, dans la marge libre, sur un fond neutre. */
.rsrow { position: sticky; bottom: 2px; z-index: 1; }
#death .rsrow .gk-plank { position: static; }
.rsrow.two { display: flex; gap: 10px; align-items: stretch; margin: 4px 0 6px; }
.rsrow.two .gk-plank { flex: 1 1 0; min-width: 0; margin: 0; font-size: 19px; padding: 7px 10px 8px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; }
#respawnKit .adtag { display: inline-flex; align-items: center; gap: 4px; font: 800 11px 'Inter', sans-serif; letter-spacing: .08em; text-transform: uppercase; color: #ffe9b0; background: rgba(0, 0, 0, .28); border-radius: 3px; padding: 1px 6px 1px 3px; text-shadow: none; }
#respawnKit .adv { width: 18px; height: 18px; margin: 0; }
.kitnote { display: block; margin: 0 0 6px; font: 600 11.5px 'Inter', sans-serif; color: #6e5134; }
#adVeil { position: fixed; inset: 0; z-index: 9000; display: none; align-items: center; justify-content: center; background: radial-gradient(ellipse at center, rgba(8, 6, 4, .72), rgba(2, 2, 2, .9)); cursor: wait; }
#adVeil.on { display: flex; }
#adVeil .adbox { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 22px 34px; border-radius: 8px; border: 1px solid rgba(255, 213, 79, .35); background: rgba(20, 16, 10, .85); box-shadow: 0 0 40px rgba(255, 193, 7, .12), 0 18px 50px rgba(0, 0, 0, .6); color: #f3e6c8; }
#adVeil .adbox b { font: 700 18px 'Cinzel', Georgia, serif; letter-spacing: .12em; color: #ffe082; }
#adVeil .adbox small { font: 500 12.5px 'Inter', sans-serif; color: #cbb994; }
#adVeil .adspin { width: 38px; height: 38px; border-radius: 50%; border: 4px solid rgba(255, 224, 130, .18); border-top-color: #ffd54f; border-right-color: #ffb300; animation: adspin .9s linear infinite; box-shadow: 0 0 18px rgba(255, 193, 7, .35); }
#adVeil.play .adspin { animation-duration: 2.4s; }
@keyframes adspin { to { transform: rotate(360deg); } }
#adBanBox { position: fixed; z-index: 21; text-align: center; }
#adBanBox > small { display: block; height: 18px; line-height: 18px; font: 600 10.5px 'Inter', sans-serif; letter-spacing: .14em; text-transform: uppercase; color: rgba(230, 220, 200, .55); }
#adBanBox > div { background: rgba(10, 12, 12, .72); outline: 1px solid rgba(255, 255, 255, .12); box-shadow: 0 6px 22px rgba(0, 0, 0, .5); }

/* =====================================================================================
   Ton avis (§ 7.130) : le kit « gk » (bois clouté, parchemin), cinq visages dessinés, des catégories en étiquettes, le sceau de cire du merci.
   ===================================================================================== */
#avis { z-index: 45; } /* au-dessus des Réglages (30), de l'écran de mort et des stèles (40) */
#avis .avisbox { width: min(94vw, 540px); }
#avis.gk-in .gk-frame { animation: gk-in .45s cubic-bezier(.2, .9, .3, 1.2) both; }
#avis .avispaper { position: relative; max-height: calc(100vh - 34px); max-height: calc(100dvh - 34px); padding: 10px 18px 12px; }
#avisClose { position: absolute; top: 8px; right: 8px; z-index: 2; }
#avisTitle { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 2px 30px 2px; }
.avistitleic { width: 40px; height: 40px; transform: rotate(2deg); filter: drop-shadow(0 2px 0 rgba(60, 25, 5, .3)); }
.avissub { margin: 4px 6px 8px; font-size: 13.5px; line-height: 1.35; color: #5c4128; }
.avisq { margin: 8px 0 4px; font: 400 21px/1.1 'Pirata One', Georgia, serif; color: #6e2a12; letter-spacing: .02em; } .avisq small { font: 600 11px 'Inter', sans-serif; color: #8a6a44; margin-left: 4px; text-transform: lowercase; }
.avisnotes { display: flex; justify-content: center; gap: 6px; }
.avisnote { position: relative; width: 62px; height: 62px; padding: 0; border-radius: 50%; background: radial-gradient(circle at 50% 40%, rgba(255, 250, 230, .65), rgba(255, 250, 230, 0) 70%); border: 2px solid transparent; cursor: pointer;
  transition: transform .14s cubic-bezier(.2, 1.4, .4, 1), filter .14s, border-color .14s; }
.avisnote .avisface { width: 52px; height: 52px; display: block; margin: 3px auto 0; pointer-events: none; filter: drop-shadow(0 2px 1px rgba(60, 30, 10, .35)); }
.avisnote small { position: absolute; right: 2px; bottom: 0; min-width: 16px; height: 16px; border-radius: 8px; background: #3a2614; color: #f3e5c0; font: 800 10px/16px 'Inter', sans-serif; opacity: 0; transition: opacity .14s; }
.avisnote:hover { transform: translateY(-3px) scale(1.08); } .avisnote:hover small, .avisnote.on small { opacity: 1; }
.avisnote.on { transform: translateY(-3px) scale(1.16); border-color: #b07a1a; background: radial-gradient(circle at 50% 40%, #fff6d8, rgba(255, 213, 79, .35) 70%); box-shadow: 0 0 0 3px rgba(255, 213, 79, .35), 0 6px 14px rgba(120, 70, 10, .35); }
.avisnote.on .avisface { animation: avis-pop .35s cubic-bezier(.2, 1.6, .4, 1); }
.avisnote.dim { filter: grayscale(.75) opacity(.55); } .avisnote.dim:hover { filter: none; }
@keyframes avis-pop { 0% { transform: scale(.8) rotate(-8deg); } 60% { transform: scale(1.12) rotate(4deg); } 100% { transform: none; } }
.avisnotelbl { min-height: 20px; margin: 3px 0 0; font: 700 13px 'Inter', sans-serif; color: #8a6a44; font-style: italic; }
.avisnotelbl.n1 { color: #b3261e; font-style: normal; } .avisnotelbl.n2 { color: #c4561c; font-style: normal; } .avisnotelbl.n3 { color: #9a7410; font-style: normal; } .avisnotelbl.n4 { color: #4f8a1f; font-style: normal; } .avisnotelbl.n5 { color: #2e7d32; font-style: normal; }
.aviscats { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.aviscat { display: inline-flex; align-items: center; gap: 5px; padding: 4px 11px 4px 6px; border-radius: 16px; border: 2px solid #8a6a44; background: rgba(255, 248, 225, .55); color: #3a2614;
  font: 700 13px 'Inter', sans-serif; cursor: pointer; transition: transform .1s, background .12s, border-color .12s; box-shadow: 0 2px 0 rgba(60, 30, 10, .25); }
.aviscat .aviscatic { width: 26px; height: 26px; pointer-events: none; }
.aviscat:hover { transform: translateY(-1px); background: rgba(255, 248, 225, .9); }
.aviscat.on { border-color: #1d1108; color: #fbeccb; text-shadow: 0 1px 0 rgba(0, 0, 0, .5); background: repeating-linear-gradient(90deg, rgba(0, 0, 0, .08) 0 2px, transparent 2px 13px), linear-gradient(180deg, #b27a40, #8a5626 55%, #6e4219);
  box-shadow: inset 0 1px 0 rgba(255, 235, 190, .35), 0 2px 0 #1d1108, 0 0 0 3px rgba(255, 213, 79, .35); }
.avistxt { position: relative; margin: 10px 0 0; }
#avisTxt { display: block; width: 100%; min-height: 92px; max-height: 34vh; resize: vertical; padding: 8px 10px 20px; border: 2px solid #8a6a44; border-radius: 4px; outline: none;
  background: linear-gradient(180deg, rgba(255, 252, 240, .9), rgba(250, 240, 210, .9)); color: #2b1a0e; font: 500 14px/1.4 'Inter', 'Segoe UI', sans-serif; box-shadow: inset 0 2px 6px rgba(120, 75, 25, .25); user-select: text; -webkit-user-select: text; touch-action: auto; }
body.touch #avisTxt { font-size: 16px; } /* (téléphone : sous 16 px, Safari zoome sur le champ) */
#avisTxt:focus { border-color: #b07a1a; box-shadow: inset 0 2px 6px rgba(120, 75, 25, .25), 0 0 0 3px rgba(255, 213, 79, .35); }
#avisTxt::placeholder { color: #9a8160; font-style: italic; }
.aviscount { position: absolute; right: 8px; bottom: 5px; font: 700 11px 'Inter', sans-serif; color: #9a8160; pointer-events: none; } .aviscount.near { color: #b3261e; }
.avisperso { display: flex; align-items: center; justify-content: center; gap: 5px; margin: 6px 0 2px; font: 600 12px 'Inter', sans-serif; color: #8c1c12; }
.avisperso .ei { width: 18px; height: 18px; flex: none; }
.avisctx { margin: 2px 0 4px; font-size: 11.5px; color: #5c4128; } .avisctx summary { cursor: pointer; color: #6e5134; font-weight: 700; list-style: none; }
.avisctx summary::-webkit-details-marker { display: none; } .avisctx summary::after { content: ' ▾'; } .avisctx[open] summary::after { content: ' ▴'; }
.avisctx p { margin: 4px 4px 0; line-height: 1.35; text-align: left; } .avisctx .avisctxnow { font: 600 11px ui-monospace, Menlo, Consolas, monospace; color: #6e5134; }
.aviserr { margin: 6px 0 2px; padding: 6px 10px; border-radius: 4px; border: 2px solid #a0261a; background: rgba(229, 72, 77, .12); color: #8c1c12; font: 700 13px/1.3 'Inter', sans-serif; }
.aviserr.shake { animation: nameShake .35s ease-in-out; }
#avisSend { margin-top: 8px; }
.avisdone { padding: 4px 0 2px; }
.avisdone .gk-title { margin-top: -6px; }
.avisdone p { margin: 6px 8px 12px; font-size: 15px; color: #3a2614; }
.avisseal { position: relative; height: 150px; display: flex; align-items: center; justify-content: center; }
.avisseal canvas { position: absolute; left: 50%; top: 50%; width: 320px; height: 220px; transform: translate(-50%, -50%); pointer-events: none; }
.avissealimg { width: 120px; height: 120px; filter: drop-shadow(0 6px 6px rgba(60, 20, 5, .45)); }
.avisdone.on .avissealimg { animation: avis-stamp .6s cubic-bezier(.3, 1.5, .5, 1) both; }
@keyframes avis-stamp { 0% { transform: translateY(-40px) scale(2.3) rotate(-28deg); opacity: 0; } 45% { transform: translateY(0) scale(.92) rotate(-6deg); opacity: 1; } 70% { transform: scale(1.05) rotate(-9deg); } 100% { transform: scale(1) rotate(-8deg); } }
.avisdone.on .gk-title { animation: gk-in .5s .25s cubic-bezier(.2, .9, .3, 1.2) both; }
/* les portes d'entrée : le menu (une pancarte de plus), Réglages (un lien en bas), l'écran de mort en Survie (un lien discret), la fin de manche des Forteresses */
#menu .privrow { justify-content: center; } /* (la pancarte de plus passe parfois à la ligne : centrée, comme le reste du menu) */
#avisBtn .ei, #avisSet .ei { width: 18px; height: 18px; vertical-align: -4px; margin-right: 4px; }
.setfoot #avisSet { color: #ffe9b0; } .setfoot #avisSet:hover { color: #fff; }
#death .avislink { display: block; margin: 0 auto; font-size: 12px; color: #8a6a44; }
body:not(.surv) #avisDeath, #death.spec #avisDeath { display: none; }
#fortCard .favis { pointer-events: auto; display: inline-flex; align-items: center; gap: 4px; margin: 6px auto 0; padding: 2px 8px; background: none; border: none; cursor: pointer;
  font: 600 12px var(--fb); color: var(--ui-dim, #b9ae9c); text-decoration: underline; text-underline-offset: 3px; } #fortCard .favis:hover { color: #ffe9b0; }
#fortCard .favis .ei { width: 16px; height: 16px; }
#avisSend { position: sticky; bottom: 0; z-index: 1; } /* toujours visible, même quand le parchemin défile */
@media (max-height: 540px) { /* téléphone couché, petit portable : tout tient sans défiler (821 × 462) */
  #avis .avisbox { width: min(96vw, 600px); } #avis .avispaper { padding: 4px 12px 6px; }
  #avisTitle { font-size: 28px; margin: 0 30px; } .avistitleic { width: 26px; height: 26px; } .avissub { display: none; }
  .avisq { margin: 2px 0 1px; font-size: 16px; } .avisnotes { gap: 4px; } .avisnote { width: 44px; height: 44px; } .avisnote .avisface { width: 38px; height: 38px; margin-top: 2px; }
  .avisnote.on { transform: translateY(-1px) scale(1.1); } .avisnotelbl { min-height: 14px; margin: 1px 0 0; font-size: 11px; line-height: 14px; }
  .aviscats { gap: 4px; } .aviscat { padding: 2px 8px 2px 4px; font-size: 12px; } .aviscat .aviscatic { width: 20px; height: 20px; }
  .avistxt { margin-top: 6px; } #avisTxt { min-height: 54px; padding: 5px 8px 16px; font-size: 13px; } .aviscount { bottom: 3px; }
  .avisperso { margin: 3px 0 0; font-size: 11px; } .avisperso .ei { width: 14px; height: 14px; } .avisctx { margin: 1px 0 2px; font-size: 11px; }
  #avisSend { margin-top: 4px; font-size: 22px; padding: 3px 10px 4px; } #avisSend:disabled { font-size: 17px; }
  .avisseal { height: 100px; } .avissealimg { width: 84px; height: 84px; } .avisdone p { margin: 4px 8px 8px; font-size: 14px; }
}
@media (max-width: 420px) { .avisnotes { gap: 2px; } .avisnote { width: 52px; height: 52px; } .avisnote .avisface { width: 44px; height: 44px; } .aviscat { font-size: 12px; padding: 3px 9px 3px 5px; } }
/* ---------- Le guide du départ (§ 7.133) : le bandeau de l'étape (numéro en sceau, phrase, cadeau annoncé), l'éclat d'une étape réussie,
   ce qui brille dans l'interface (bouton du dock, onglet, ligne de recette), l'aide des touches, la protection du nouveau venu ---------- */
#tuto.gd-on { display: flex; align-items: center; gap: 10px; padding: 7px 30px 7px 8px; font-size: 13px; line-height: 1.3; border-color: #7a5a10 !important; box-shadow: 0 0 0 2px rgba(255, 213, 79, .55), 0 3px 0 rgba(10, 5, 2, .8), 0 10px 22px rgba(0, 0, 0, .45) !important; }
#tuto #tutoText { display: contents; }
#tuto .gd-no { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, #fff3c4, #f0c75a 55%, #b8860b); border: 2px solid #5d3a00; color: #3a2400 !important; font: 700 13px/1 var(--fw-fl, Georgia, serif); box-shadow: 0 2px 0 rgba(0, 0, 0, .35), inset 0 1px 0 rgba(255, 255, 255, .6); }
#tuto .gd-no img.ei { width: 20px; height: 20px; }
#tuto .gd-t { flex: 1 1 auto; min-width: 0; font-weight: 700; }
#tuto .gd-t .tp { margin-left: 4px; color: #8c1c12 !important; white-space: nowrap; }
#tuto .gd-x { display: block; margin-top: 1px; font-size: 11.5px; font-weight: 600; color: #6b4a1a; }
#tuto .gd-gifts { flex: none; display: flex; align-items: center; gap: 4px; padding: 3px 6px 3px 7px; border-radius: 8px; background: rgba(120, 80, 20, .14); border: 1px dashed rgba(90, 58, 10, .55); }
#tuto .gd-gifts small { font: 700 9px/1 var(--fw-fl, Georgia, serif); letter-spacing: .6px; text-transform: uppercase; color: #6b4a1a; writing-mode: vertical-rl; transform: rotate(180deg); }
#tuto .gd-g { display: inline-flex; align-items: center; gap: 1px; font: 800 12px/1 'Inter', sans-serif; color: #3a2614; white-space: nowrap; }
#tuto .gd-g img.gdi { width: 24px; height: 24px; filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .35)); }
#tuto .gd-xp { padding: 2px 4px; border-radius: 4px; background: #5e35b1; color: #f3e5ff; font-size: 10.5px; }
#tuto.gd-pop { animation: gdPop .9s ease-out; }
@keyframes gdPop { 0% { filter: brightness(1.9) saturate(1.3); transform: translateX(-50%) scale(1.06); } 45% { filter: brightness(1.25); } 100% { filter: none; } }
@container hud (min-width: 801px) and (min-height: 541px) { #topStack > #tuto.gd-pop { animation: gdPopS .9s ease-out; } }
@keyframes gdPopS { 0% { filter: brightness(1.9) saturate(1.3); transform: scale(1.06) !important; } 45% { filter: brightness(1.25); } 100% { filter: none; } }
.gd-hi { position: relative; z-index: 6; animation: gdHi 1.1s ease-in-out infinite; }
@keyframes gdHi { 0%, 100% { box-shadow: 0 0 0 2px #ffd54f, 0 0 10px 3px rgba(255, 213, 79, .55); } 50% { box-shadow: 0 0 0 3px #fff3c4, 0 0 22px 8px rgba(255, 213, 79, .85); } }
.act.gd-hi::after { content: ''; position: absolute; left: 50%; top: -34px; width: 26px; height: 24px; margin-left: -13px; background: linear-gradient(180deg, #fff3c4, #ffca28 60%, #c79100); clip-path: polygon(0 0, 50% 55%, 100% 0, 100% 35%, 50% 100%, 0 35%); filter: drop-shadow(0 2px 2px rgba(0, 0, 0, .5)); animation: gdBob .55s ease-in-out infinite alternate; pointer-events: none; }
@keyframes gdBob { from { transform: translateY(-5px); } to { transform: translateY(2px); } }
.side .item.gd-hi, .tabs div.gd-hi { outline: 2px solid #ffd54f; outline-offset: -2px; background-color: rgba(255, 213, 79, .18) !important; }
#keyHelp { position: absolute; left: 50%; bottom: 96px; transform: translateX(-50%); display: flex; gap: 12px; pointer-events: none; z-index: 4; }
#keyHelp.hidden { display: none; }
#keyHelp > div { display: flex; align-items: center; gap: 9px; padding: 8px 14px 8px 10px; background: var(--fw-rivets), var(--fw-parch); border: 2px solid var(--fw-edge, #140b04); border-radius: 6px; box-shadow: 0 0 0 2px rgba(255, 213, 79, .5), 0 3px 0 rgba(10, 5, 2, .8), 0 10px 22px rgba(0, 0, 0, .45); color: var(--fw-ink, #3a2614); transition: opacity .5s, filter .5s; animation: gdIn .5s ease-out; }
#keyHelp > div.ok { opacity: .45; filter: grayscale(.8); }
#keyHelp > div.ok::before { content: '✔'; font: 900 18px/1 sans-serif; color: #2e7d32; margin-right: -2px; }
#keyHelp small { display: flex; flex-direction: column; font: 700 13px/1.2 var(--fw-fl, Georgia, serif); }
#keyHelp small em { font: 600 11px/1.2 'Inter', sans-serif; font-style: normal; color: #6b4a1a; }
#keyHelp .kh-keys { display: grid; grid-template-columns: repeat(3, 24px); grid-template-rows: 24px 24px; gap: 2px; }
#keyHelp .kh-keys kbd { display: grid; place-items: center; border-radius: 4px; background: linear-gradient(180deg, #fffaf0, #e3d2a8); border: 1px solid #5d4225; border-bottom-width: 3px; font: 800 12px/1 'Inter', sans-serif; color: #3a2614; }
#keyHelp .kh-keys .kh-up { grid-column: 2; grid-row: 1; } #keyHelp .kh-keys kbd:nth-child(2) { grid-column: 1; grid-row: 2; } #keyHelp .kh-keys kbd:nth-child(3) { grid-column: 2; grid-row: 2; } #keyHelp .kh-keys kbd:nth-child(4) { grid-column: 3; grid-row: 2; }
#keyHelp .kh-mouse img.ei { width: 40px; height: 40px; }
@keyframes gdIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
#quests .gd-later { display: flex; align-items: center; gap: 6px; font-size: 11px; opacity: .85; }
#quests .gd-later img.ei { width: 18px; height: 18px; }
#fx span.gd-wardc { border-color: #b8860b; background: linear-gradient(160deg, #fff8dc, #f3dd9c); color: #4a3200; box-shadow: 0 0 0 1px rgba(255, 213, 79, .6), 0 2px 0 rgba(0, 0, 0, .35); }
.gd-fg { display: flex; align-items: center; gap: 8px; margin: 8px auto 0; max-width: 460px; padding: 6px 10px; border-radius: 6px; background: linear-gradient(160deg, #fff8dc, #f3dd9c); border: 2px solid #b8860b; color: #3a2614; text-align: left; font-size: 12.5px; box-shadow: 0 0 14px rgba(255, 213, 79, .45); }
.gd-fg img.ei { width: 34px; height: 34px; flex: none; }
.gd-fg b { display: block; font-family: var(--fw-fl, Georgia, serif); font-size: 14px; color: #6d4c00; }
@media (max-height: 540px) { /* le cadre de CrazyGames (821 × 462, 907 × 510) : le bandeau du guide reste, en bas au-dessus de la barre rapide ; l'aide des touches au-dessus de lui (§ 7.133) */
  body:not(.touch) #tuto.gd-on, body:not(.touch) #tuto:not(.hidden) { display: flex; top: auto; bottom: 70px; left: 50%; transform: translateX(-50%); max-width: min(560px, 74vw); width: max-content; font-size: 11.5px; padding: 4px 26px 4px 6px; gap: 7px; }
  #tuto .gd-no { width: 26px; height: 26px; font-size: 11px; } #tuto .gd-g img.gdi { width: 18px; height: 18px; } #tuto .gd-x { font-size: 10.5px; }
  body.surv:not(.touch) #toasts { top: auto; bottom: 138px; } /* les messages au-dessus du bandeau du guide, plus sur lui */ #tuto .gd-gifts small { display: none; } #tuto .gd-gifts { padding: 2px 5px; }
  #keyHelp { bottom: auto; top: 102px; gap: 8px; } #keyHelp > div { padding: 5px 10px 5px 7px; } #keyHelp small { font-size: 11.5px; } #keyHelp .kh-keys { grid-template-columns: repeat(3, 20px); grid-template-rows: 20px 20px; } #keyHelp .kh-mouse img.ei { width: 30px; height: 30px; }
}
body.touch #keyHelp, body.fort #keyHelp { display: none; }
