/* VALDRAN interface — ornate gilded frames on dark enamel, clear Arabic typography (Cairo / El Messiri). */
@font-face { font-family: 'Cinzel'; font-weight: 700; src: url(../fonts/cinzel-latin-700-normal.woff2) format('woff2'); font-display: swap; }
@font-face { font-family: 'Cinzel'; font-weight: 800; src: url(../fonts/cinzel-latin-800-normal.woff2) format('woff2'); font-display: swap; }
@font-face { font-family: 'Cairo'; font-weight: 600; src: url(../fonts/cairo-arabic-600-normal.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF; font-display: swap; }
@font-face { font-family: 'Cairo'; font-weight: 700; src: url(../fonts/cairo-arabic-700-normal.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF; font-display: swap; }
@font-face { font-family: 'Cairo'; font-weight: 800; src: url(../fonts/cairo-arabic-800-normal.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF; font-display: swap; }
@font-face { font-family: 'Cairo'; font-weight: 600; src: url(../fonts/cairo-latin-600-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F; font-display: swap; }
@font-face { font-family: 'Cairo'; font-weight: 700; src: url(../fonts/cairo-latin-700-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F; font-display: swap; }
@font-face { font-family: 'Cairo'; font-weight: 800; src: url(../fonts/cairo-latin-800-normal.woff2) format('woff2'); unicode-range: U+0000-00FF, U+2000-206F; font-display: swap; }
@font-face { font-family: 'Messiri'; font-weight: 600; src: url(../fonts/el-messiri-arabic-600-normal.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF; font-display: swap; }
@font-face { font-family: 'Messiri'; font-weight: 700; src: url(../fonts/el-messiri-arabic-700-normal.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF; font-display: swap; }
@font-face { font-family: 'Messiri'; font-weight: 700; src: url(../fonts/el-messiri-latin-700-normal.woff2) format('woff2'); unicode-range: U+0000-00FF; font-display: swap; }
@font-face { font-family: 'Lalezar'; font-weight: 400; src: url(../fonts/lalezar-arabic-400-normal.woff2) format('woff2'); unicode-range: U+0600-06FF, U+0750-077F, U+FB50-FDFF, U+FE70-FEFF; font-display: swap; }
@font-face { font-family: 'Lalezar'; font-weight: 400; src: url(../fonts/lalezar-latin-400-normal.woff2) format('woff2'); unicode-range: U+0000-00FF; font-display: swap; }

:root {
  --gold: #f0cd78; --gold2: #c8963e; --gold3: #6a4a18; --text: #f6efe0; --dim: #b9b0a0; --hp: #e0402e; --mp: #3a82f6; --xp: #b07aff;
  --head: 'Messiri', 'Cairo', serif; --body: 'Cairo', system-ui, sans-serif; --latin: 'Cinzel', Georgia, serif; --num: 'Cairo', sans-serif; --display: 'Lalezar', 'Messiri', sans-serif;
  --shadow: 0 1px 0 #000, 0 0 3px rgba(0,0,0,.9);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; background: #05060a; color: var(--text); font: 600 15px/1.55 var(--body); user-select: none; -webkit-user-select: none; }
canvas#game { position: fixed; inset: 0; width: 100vw; height: 100vh; display: block; }
[hidden] { display: none !important; }
button { font: inherit; color: inherit; cursor: pointer; }
kbd { font: 800 11px/1 var(--num); background: #0b0d14; border: 1px solid #8a6a2c; color: #ffe39a; border-radius: 4px; padding: 3px 5px; box-shadow: 0 1px 0 #000; }
small { color: var(--dim); }

/* ── frames ── */
.ornate { position: relative; border: 34px solid transparent; border-image: url(../img/frame.svg) 40 fill / 34px stretch; padding: 0; filter: drop-shadow(0 10px 24px rgba(0,0,0,.6)); }
.panel { position: relative; background: linear-gradient(180deg, rgba(26,30,48,.92), rgba(12,14,24,.94)); border-radius: 10px; box-shadow: 0 0 0 1px #120c04, 0 0 0 2.5px #b4893e, 0 0 0 3.5px #2a1c08, inset 0 1px 0 rgba(255,230,170,.14), inset 0 0 26px rgba(0,0,0,.55), 0 10px 26px rgba(0,0,0,.5); }
.btn { background: linear-gradient(180deg, #424866, #23273c); border: 1px solid #8a6a2c; border-radius: 8px; padding: 8px 16px; box-shadow: inset 0 1px 0 rgba(255,255,255,.15), 0 2px 6px rgba(0,0,0,.45); font: 700 15px var(--body); text-shadow: var(--shadow); transition: filter .15s, transform .08s; }
.btn:hover:not(:disabled) { filter: brightness(1.22); } .btn:active:not(:disabled) { transform: translateY(1px); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn.gold { background: linear-gradient(180deg, #ffe6a0, #e2a640 45%, #a8701e 55%, #d89a38); color: #2a1604; border-color: #fff0c0; text-shadow: 0 1px 0 rgba(255,245,210,.6); box-shadow: inset 0 1px 0 rgba(255,255,255,.6), inset 0 -2px 0 rgba(90,50,10,.4), 0 0 0 1px #4a2e08, 0 4px 14px rgba(0,0,0,.5); }
.btn.big { font: 700 18px var(--head); padding: 11px 28px; }
.btn.huge { font: 700 24px var(--head); padding: 13px 40px; width: 100%; letter-spacing: .5px; animation: glowpulse 2.4s ease-in-out infinite; }
@keyframes glowpulse { 50% { box-shadow: inset 0 1px 0 rgba(255,255,255,.6), inset 0 -2px 0 rgba(90,50,10,.4), 0 0 0 1px #4a2e08, 0 0 28px rgba(255,200,90,.55); } }
.bad { color: #ff6a5a !important; } .done { color: #7dff9a !important; }
.upg { color: #ffd76a; font: 800 12px var(--num); }

/* ── loading ── */
#loading { position: fixed; inset: 0; z-index: 50; display: grid; place-content: center; justify-items: center; gap: 18px; background: radial-gradient(ellipse at 50% 40%, #1f2440, #05060a 72%); }
.logo { display: grid; justify-items: center; line-height: 1; }
.logo b, .mm-logo b { font: 800 72px var(--latin); letter-spacing: 12px; background: linear-gradient(180deg, #fff6d4 10%, #f0c060 45%, #9a6418 60%, #f3d48a 85%); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 3px 0 #2a1604) drop-shadow(0 0 22px rgba(255,190,90,.45)); }
.logo span { font: 700 24px var(--head); color: #f4e2b4; margin-top: 10px; }
.lbar { width: min(460px, 70vw); height: 12px; border-radius: 6px; background: #0a0b12; box-shadow: 0 0 0 1px #000, 0 0 0 2.5px #9a7432; overflow: hidden; }
.lbar i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, #9a6a1c, #ffe39a); transition: width .3s; box-shadow: 0 0 12px rgba(255,210,120,.7); }
#loadTxt { color: var(--dim); margin: 0; font-size: 15px; }

/* ── main menu ── */
#login { position: fixed; inset: 0; z-index: 50; }
.mm-vignette { position: absolute; inset: 0; pointer-events: none; background: radial-gradient(ellipse at 38% 55%, transparent 35%, rgba(4,5,10,.55) 75%, rgba(4,5,10,.85)), linear-gradient(270deg, rgba(4,5,10,.82) 0, rgba(4,5,10,.25) 520px, transparent 760px); }
.mm-logo { position: absolute; top: 26px; left: 38%; transform: translateX(-50%); display: grid; justify-items: center; line-height: 1; pointer-events: none; }
.mm-logo b { font-size: 84px; letter-spacing: 16px; }
.mm-logo img { width: 380px; margin: 6px 0; }
.mm-logo span { font: 700 22px var(--head); color: #f4e2b4; text-shadow: 0 2px 6px #000; }
.mm-classes { position: absolute; bottom: 70px; left: 38%; transform: translateX(-50%); display: flex; gap: 22px; direction: rtl; }
.medal { position: relative; width: 104px; display: grid; justify-items: center; gap: 6px; background: none; border: 0; padding: 0; }
.medal .ring { width: 86px; height: 86px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 35%, color-mix(in srgb, var(--c) 35%, #24283c), #0a0c16 72%); box-shadow: 0 0 0 3px #1a1206, 0 0 0 6px #b4893e, 0 0 0 7px #2a1c08, inset 0 2px 8px rgba(255,255,255,.12), 0 8px 18px rgba(0,0,0,.6); transition: transform .18s, box-shadow .18s; }
.medal b { font: 700 18px var(--head); text-shadow: var(--shadow); } .medal small { font: 700 10px var(--latin); letter-spacing: 2px; color: #c8b890; margin-top: -6px; }
.medal:hover .ring { transform: translateY(-3px); }
.medal.on .ring { transform: translateY(-6px) scale(1.08); box-shadow: 0 0 0 3px #1a1206, 0 0 0 6px #ffe39a, 0 0 0 7px #2a1c08, 0 0 32px color-mix(in srgb, var(--c) 75%, transparent), inset 0 2px 8px rgba(255,255,255,.18); }
.medal.on b { color: var(--c); }
.mm-panel { position: absolute; top: 50%; right: 40px; transform: translateY(-50%); width: 440px; display: grid; gap: 14px; }
#classInfo h3 { margin: 0; font: 700 34px var(--head); line-height: 1.2; text-shadow: 0 2px 8px rgba(0,0,0,.7); }
#classInfo em { color: #d8c8a0; font-style: normal; font-size: 15px; }
#classInfo p { margin: 8px 0 10px; color: #e8dfcc; font-size: 15px; font-weight: 600; }
.stats4 { display: grid; gap: 7px; margin: 6px 0 10px; }
.stats4 div { display: grid; grid-template-columns: 70px 1fr; gap: 10px; align-items: center; font-size: 14px; }
.stats4 i { display: flex; gap: 4px; } .stats4 i u { flex: 1; height: 9px; border-radius: 3px; background: #1a1c28; box-shadow: inset 0 1px 2px #000; text-decoration: none; }
.stats4 i u.on { background: linear-gradient(180deg, #ffe39a, #c8892e); box-shadow: 0 0 6px rgba(255,200,100,.45); }
.skrow { display: flex; gap: 8px; } .skrow span { width: 46px; height: 46px; border-radius: 10px; display: grid; place-items: center; background: radial-gradient(circle at 50% 35%, #2e3450, #0c0e18 75%); box-shadow: 0 0 0 1px #1a1206, 0 0 0 2.5px #a07a34; }
.fld { display: grid; gap: 6px; } .fld span { font: 700 15px var(--head); color: var(--gold); }
.fld input { background: #0a0c14; border: 1px solid #8a6a2c; color: var(--text); font: 700 19px var(--body); padding: 10px 14px; border-radius: 8px; outline: none; box-shadow: inset 0 2px 6px #000; }
.fld input:focus { border-color: var(--gold); box-shadow: inset 0 2px 6px #000, 0 0 0 3px rgba(240,205,120,.18); }
.fld input.bad { animation: shake .4s; border-color: #ff6a5a; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
#srvInfo { margin: 0; font-size: 13px; color: var(--dim); text-align: center; } #srvInfo .ok { color: #7dff9a; } #srvInfo .ai { color: #d0aaff; font-weight: 800; }
.mm-foot { position: absolute; bottom: 14px; left: 38%; transform: translateX(-50%); font-size: 12px; color: #8a8270; text-shadow: 0 1px 2px #000; white-space: nowrap; }

/* ── nameplates + floating numbers ── */
#plates, #floaters { position: fixed; inset: 0; pointer-events: none; z-index: 5; overflow: hidden; }
.plate { position: absolute; left: 0; top: 0; text-align: center; white-space: nowrap; will-change: transform; }
.plate b { display: block; font: 700 14px var(--body); color: #ffd6c8; -webkit-text-stroke: 3px rgba(0,0,0,.85); paint-order: stroke fill; }
.plate b small { color: #ffe9a8; font: 800 12px var(--num); -webkit-text-stroke: 3px rgba(0,0,0,.85); paint-order: stroke fill; }
.plate i { display: block; width: 82px; height: 7px; margin: 2px auto 0; background: #1a0808; border: 1px solid #000; border-radius: 3px; overflow: hidden; box-shadow: 0 0 0 1px rgba(255,220,150,.2); }
.plate u { display: block; height: 100%; background: linear-gradient(180deg, #ff7a6a, #b81e14); }
.plate.player b { color: #a8deff; } .plate.player u { background: linear-gradient(180deg, #8aff9a, #1e9a34); }
.plate.npc b { color: #ffe28a; font-size: 15px; }
.plate.tame b { color: #8affd8; } .plate.tame b::before { content: '✦ '; color: #8affd8; }
.plate.orange b { color: #ffa060; } .plate.red b { color: #ff4a3a; } .plate.grey b { color: #c8c0b8; }
.plate.sel b { color: #fff; } .plate.sel i { box-shadow: 0 0 0 1px #ffd76a, 0 0 8px rgba(255,210,100,.6); }
.float { position: absolute; left: 0; top: 0; direction: ltr; unicode-bidi: isolate; font: 800 24px var(--num); color: #fff; -webkit-text-stroke: 4px rgba(0,0,0,.85); paint-order: stroke fill; white-space: nowrap; will-change: transform, opacity; }
.float.crit { color: #ffd84a; font-size: 36px; -webkit-text-stroke: 5px #3a1a00; } .float.odmg { color: #d8d0c8; font-size: 17px; }
.float.healn { color: #7dff9a; } .float.hurt { color: #ff5a4a; font-size: 26px; } .float.miss { color: #b8e4ff; font: 700 19px var(--body); }
.float.xp { color: #d8b0ff; font-size: 19px; } .float.gold { color: #ffd76a; font-size: 18px; }
#hurtFlash, #screenFlash { position: fixed; inset: 0; pointer-events: none; z-index: 4; opacity: 0; }
#hurtFlash.on { animation: hurtf .45s ease-out; }
@keyframes hurtf { 0% { opacity: 1; box-shadow: inset 0 0 170px rgba(220,20,10,.7); } 100% { opacity: 0; box-shadow: inset 0 0 170px rgba(220,20,10,0); } }
#screenFlash.on { animation: sflash .35s ease-out; } @keyframes sflash { 0% { opacity: 1; } 100% { opacity: 0; } }

/* ── HUD ── */
#hud { position: fixed; inset: 0; pointer-events: none; z-index: 10; }
#hud > * { pointer-events: auto; }
#hero { position: absolute; top: 10px; right: 10px; display: flex; gap: 12px; align-items: center; min-width: 360px; }
#pring { --p: 0; width: 82px; height: 82px; border-radius: 50%; display: grid; place-items: center; background: conic-gradient(#c890ff calc(var(--p) * 1%), #1a1424 0); box-shadow: 0 0 0 2px #1a1206, 0 0 0 4px #c8963e, 0 0 14px rgba(180,120,255,.35); flex: none; }
#portrait { --c: #e0a84a; width: 70px; height: 70px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--c) 38%, #20243a), #0a0c16 75%); box-shadow: inset 0 0 0 2px #1a1206; }
#heroLvl { position: absolute; right: 60px; bottom: -2px; min-width: 30px; height: 30px; padding: 0 4px; border-radius: 15px; display: grid; place-items: center; font: 800 15px var(--num); background: radial-gradient(circle at 40% 35%, #fff2c0, #e0a840 55%, #8a5a18); color: #2a1604; box-shadow: 0 0 0 2px #1a1206, 0 2px 6px #000; }
.hinfo { flex: 1; display: grid; gap: 5px; }
.hname { display: flex; align-items: baseline; gap: 8px; } .hname b { font: 700 19px var(--head); color: #fff4d8; text-shadow: var(--shadow); } .hname small { font-size: 13px; color: #d8c8a0; }
.bar { position: relative; height: 18px; border-radius: 5px; background: #0a0a10; box-shadow: inset 0 1px 3px #000, 0 0 0 1px #4a3a1c; overflow: hidden; }
.bar i, .bar u { position: absolute; inset: 0 auto 0 0; display: block; width: 0; transition: width .18s ease-out; }
.bar.hp i { background: linear-gradient(180deg, #ff9a80, var(--hp) 45%, #7a120c); }
.bar.mp i { background: linear-gradient(180deg, #9ac4ff, var(--mp) 45%, #12306a); }
.bar u { background: linear-gradient(180deg, rgba(200,240,255,.85), rgba(120,190,255,.6)); mix-blend-mode: screen; }
.bar span { position: absolute; inset: 0; display: grid; place-items: center; font: 800 12px var(--num); -webkit-text-stroke: 3px rgba(0,0,0,.8); paint-order: stroke fill; direction: ltr; }
.bar.mp { height: 14px; } .bar.mp span { font-size: 11px; }
#buffs { display: flex; gap: 4px; min-height: 24px; } #buffs span { position: relative; width: 24px; height: 24px; border-radius: 5px; background: #0b0d16; box-shadow: inset 0 0 0 1px #8a6a2c; display: grid; place-items: center; }
#buffs i { position: absolute; bottom: -3px; left: -3px; font: 800 10px var(--num); font-style: normal; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }


#target { position: absolute; top: 26px; right: 440px; width: 270px; padding: 9px 14px; display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; align-items: center; }
#target b { font: 700 16px var(--head); color: #ffbcaa; } #target em { font: 800 13px var(--num); font-style: normal; color: #ffe08a; }
#target .bar { grid-column: 1 / -1; height: 14px; }

#bossbar { position: absolute; top: 16px; left: 50%; transform: translateX(-50%); width: min(600px, 46vw); text-align: center; pointer-events: none; }
.bhead { display: flex; justify-content: center; align-items: baseline; gap: 12px; }
.bhead b { font: 700 24px var(--head); color: #ffd2a0; -webkit-text-stroke: 4px rgba(20,4,0,.85); paint-order: stroke fill; text-shadow: 0 0 14px rgba(255,90,40,.6); }
#bEvo { color: #ff8a4a; font-size: 15px; letter-spacing: 2px; -webkit-text-stroke: 2px #000; paint-order: stroke fill; } #bEvo i { color: #5a3a30; font-style: normal; }
.bar.boss { height: 22px; border-radius: 4px; box-shadow: inset 0 1px 3px #000, 0 0 0 1px #000, 0 0 0 3px #a8341a, 0 0 0 4px #1a0602, 0 0 20px rgba(255,60,20,.4); }
.bar.boss i { background: linear-gradient(180deg, #ffa060, #d8341a 45%, #6a0c04); } .bar.boss span { font-size: 13px; }
#bossbar.enraged .bar.boss { animation: enr 0.6s infinite alternate; }
@keyframes enr { to { box-shadow: inset 0 1px 3px #000, 0 0 0 1px #000, 0 0 0 3px #ff4a1a, 0 0 0 4px #1a0602, 0 0 34px rgba(255,60,20,.85); } }
#bPlan { margin-top: 6px; font-size: 14px; color: #f0e2cc; -webkit-text-stroke: 3px rgba(0,0,0,.75); paint-order: stroke fill; min-height: 20px; } #bPlan b { color: #ffb070; }
#bPlan .ai { font: 800 10px var(--latin); font-style: normal; background: linear-gradient(90deg, #8a5aff, #c46bff); color: #fff; padding: 2px 6px; border-radius: 4px; margin-inline-end: 6px; vertical-align: 1px; -webkit-text-stroke: 0; }
#bossSay { position: absolute; top: 116px; left: 50%; transform: translate(-50%, -8px); max-width: min(680px, 60vw); text-align: center; font: 700 21px var(--head); color: #fff2e4; -webkit-text-stroke: 4px rgba(0,0,0,.8); paint-order: stroke fill; opacity: 0; transition: .35s; pointer-events: none; }
#bossSay b { display: block; font-size: 14px; color: #ff9a6a; } #bossSay.show { opacity: 1; transform: translate(-50%, 0); }
#raidWarn { position: fixed; z-index: 46; top: 28%; left: 50%; transform: translateX(-50%); font: 400 40px var(--display); color: #ff6a3a; -webkit-text-stroke: 5px #2a0600; paint-order: stroke fill; text-shadow: 0 0 18px rgba(255,60,20,.7); opacity: 0; pointer-events: none; }
#raidWarn.show { animation: rw 1.8s ease-out; }
@keyframes rw { 0% { opacity: 0; transform: translateX(-50%) scale(1.6); } 12% { opacity: 1; transform: translateX(-50%) scale(1); } 75% { opacity: 1; } 100% { opacity: 0; } }
#banner { position: fixed; z-index: 46; top: 20%; left: 50%; transform: translate(-50%, 10px); text-align: center; opacity: 0; transition: .5s; pointer-events: none; display: grid; gap: 6px; justify-items: center; }
#banner.show { opacity: 1; transform: translate(-50%, 0); }
#banner b { font: 400 54px var(--display); background: linear-gradient(180deg, #fff8dc, #f6cc66 50%, #b07418); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 3px 0 #2a1604) drop-shadow(0 0 22px rgba(255,190,80,.5)); padding: 0 24px; line-height: 1.25; }
#banner::after { content: ''; width: 360px; height: 24px; background: url(../img/divider.svg) center/contain no-repeat; order: 1; }
#banner span { font: 700 19px var(--head); color: #f6ead0; -webkit-text-stroke: 4px rgba(0,0,0,.7); paint-order: stroke fill; order: 2; }
#banner.boss b { background-image: linear-gradient(180deg, #ffe8d0, #ff7a3a 50%, #8a1a08); filter: drop-shadow(0 3px 0 #2a0600) drop-shadow(0 0 26px rgba(255,80,30,.65)); font-size: 64px; }
#banner.death b { background-image: linear-gradient(180deg, #ffd8d0, #d83a2a 60%, #5a0a04); }
#banner.r3 b { background-image: linear-gradient(180deg, #f8e6ff, #c86bff 50%, #5a1a8a); } #banner.r4 b { background-image: linear-gradient(180deg, #fff2dc, #ff9a2e 50%, #8a4a08); }
#banner.zone b { font-size: 44px; } #banner.lvl b { font-size: 70px; }

#mapbox { position: absolute; top: 14px; left: 14px; width: 190px; height: 190px; border-radius: 50%; pointer-events: auto; }
#minimap { position: absolute; inset: 5px; width: 180px; height: 180px; border-radius: 50%; background: #10131c; }
.mring { position: absolute; inset: -6px; border-radius: 50%; pointer-events: none; background: radial-gradient(circle, transparent 61%, #1a1206 62%, #e8c06a 64%, #8a5a18 67%, #f3d48a 69%, #2a1c08 71%, transparent 72%); filter: drop-shadow(0 6px 12px rgba(0,0,0,.6)); }
.mring::before { content: 'N'; position: absolute; top: -2px; left: 50%; transform: translateX(-50%); font: 800 12px var(--latin); color: #ffe39a; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }
#zone { position: absolute; bottom: -14px; left: 50%; transform: translateX(-50%); white-space: nowrap; font: 700 15px var(--head); color: #ffe8b0; background: linear-gradient(180deg, #2c2640, #14121e); padding: 2px 16px; border-radius: 12px; box-shadow: 0 0 0 1px #1a1206, 0 0 0 2.5px #b4893e; }
#ping { position: absolute; top: 8px; left: 50%; transform: translateX(-50%); font: 800 10px var(--num); color: #8ad08a; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }
#tracker { position: absolute; top: 226px; left: 14px; width: 250px; padding: 12px 16px; display: grid; gap: 4px; cursor: pointer; }
#tracker b { font: 700 16px var(--head); color: var(--gold); } #tracker small { font-size: 14px; color: #ece2cc; font-weight: 600; }
#tracker .auto { justify-self: start; margin-top: 4px; font: 700 12px var(--body); color: #2a1604; background: linear-gradient(180deg, #ffe6a0, #d89a38); border-radius: 10px; padding: 1px 10px; }
#tracker.walking .auto { background: linear-gradient(180deg, #a8ffc0, #2ea85a); }
.qbar { height: 7px; border-radius: 4px; background: #0a0a10; overflow: hidden; box-shadow: 0 0 0 1px #4a3a1c; } .qbar i { display: block; height: 100%; background: linear-gradient(90deg, #9a6a1c, #ffe39a); }

#chat { position: absolute; bottom: 16px; right: 16px; width: 360px; display: grid; gap: 4px; }
#chatLog { max-height: 160px; overflow-y: auto; padding: 6px 8px; font-size: 14px; background: linear-gradient(0deg, rgba(8,10,16,.65), rgba(8,10,16,0)); border-radius: 6px; scrollbar-width: none; }
#chatLog div { -webkit-text-stroke: 3px rgba(0,0,0,.7); paint-order: stroke fill; margin: 1px 0; } #chatLog .sys { color: #ffdc90; }
#chatIn { background: rgba(8,10,16,.8); border: 1px solid #6a5428; color: var(--text); padding: 8px 12px; border-radius: 8px; font: 600 14px var(--body); outline: none; }
#chatIn:focus { border-color: var(--gold); }
#toasts { position: fixed; z-index: 46; bottom: 178px; left: 50%; transform: translateX(-50%); display: grid; gap: 5px; justify-items: center; pointer-events: none; }
.toast { padding: 6px 18px; border-radius: 18px; background: rgba(10,12,20,.9); border: 1px solid #6a5428; font: 700 15px var(--body); transition: .5s; box-shadow: 0 4px 12px rgba(0,0,0,.5); }
.toast.out { opacity: 0; transform: translateY(-10px); }
.toast.warn { color: #ffb88a; border-color: #8a3a1c; } .toast.ore { color: #a8e2ff; } .toast.r1 { color: #7aea92; } .toast.r2 { color: #6ab8ff; } .toast.r3 { color: #d29aff; border-color: #6a2a9a; } .toast.r4 { color: #ffb05a; border-color: #9a5a10; } .toast.r0 { color: #ece6da; }
#hint { position: absolute; bottom: 186px; left: 50%; transform: translateX(-50%); padding: 7px 18px; border-radius: 18px; background: rgba(10,12,20,.9); border: 1px solid #a07a34; font: 700 16px var(--body); pointer-events: none; display: flex; gap: 8px; align-items: center; }
#hint:empty { display: none; }

#bottom { position: absolute; bottom: 12px; left: 50%; transform: translateX(-50%); display: grid; gap: 10px; justify-items: center; }
#xp { position: relative; width: 600px; height: 16px; border-radius: 8px; background: #0a0a12; box-shadow: inset 0 1px 3px #000, 0 0 0 1px #2a1c08, 0 0 0 3px #a07a34, 0 0 0 4px #2a1c08; overflow: hidden; }
#xp i { position: absolute; inset: 0 auto 0 0; width: 0; background: linear-gradient(180deg, #e2c4ff, var(--xp) 50%, #5a2a9a); transition: width .5s ease-out; box-shadow: 0 0 10px rgba(190,140,255,.7); }
#xp em { position: absolute; inset: 0 auto 0 0; width: 0; background: rgba(255,255,255,.6); transition: width .5s, opacity .8s; opacity: 0; }
#xp em.go { opacity: 1; transition: none; }
#xp u { position: absolute; inset: 0; background: repeating-linear-gradient(90deg, transparent 0 calc(10% - 2px), rgba(0,0,0,.55) calc(10% - 2px) 10%); text-decoration: none; pointer-events: none; }
#xp span { position: absolute; inset: 0; display: block; text-align: center; line-height: 16px; white-space: nowrap; font: 800 12px var(--num); -webkit-text-stroke: 3px rgba(0,0,0,.85); paint-order: stroke fill; direction: rtl; }
#skillbar { display: flex; gap: 12px; align-items: flex-end; direction: ltr; padding: 12px 20px; border-radius: 44px; background: linear-gradient(180deg, rgba(22,24,40,.88), rgba(8,10,18,.94)); box-shadow: 0 0 0 1px #120c04, 0 0 0 3px #b4893e, 0 0 0 4px #2a1c08, 0 10px 26px rgba(0,0,0,.55); }
.skill { position: relative; width: 60px; height: 60px; border-radius: 14px; border: 0; padding: 0; display: grid; place-items: center; background: radial-gradient(circle at 50% 35%, #333a58, #0c0e18 75%); box-shadow: 0 0 0 1px #1a1206, 0 0 0 3px #b4893e, 0 0 0 4px #2a1c08, inset 0 2px 6px rgba(255,255,255,.1); transition: transform .08s, filter .15s; }
.skill.basic { width: 76px; height: 76px; border-radius: 50%; }
.skill:hover { filter: brightness(1.25); } .skill:active { transform: scale(.94); }
.skill .cd { position: absolute; inset: 0; border-radius: inherit; pointer-events: none; }
.skill .cdt { position: absolute; inset: 0; display: grid; place-items: center; font: 800 21px var(--num); -webkit-text-stroke: 4px #000; paint-order: stroke fill; pointer-events: none; }
.skill kbd { position: absolute; top: -9px; left: -7px; }
.skill em { position: absolute; bottom: 2px; right: 5px; font: 800 10px var(--num); font-style: normal; color: #9ac4ff; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }
.skill.nomp svg { opacity: .35; filter: grayscale(1); }
.skill.auto { box-shadow: 0 0 0 1px #1a1206, 0 0 0 3px #ffe39a, 0 0 0 4px #2a1c08, 0 0 18px rgba(255,210,110,.6); }
.skill.potion { width: 52px; height: 52px; border-radius: 50%; margin-inline-start: 8px; }
.skill.mount { width: 52px; height: 52px; border-radius: 50%; }
.skill.mount.on { box-shadow: 0 0 0 1px #1a1206, 0 0 0 3px #8affd8, 0 0 0 4px #2a1c08, 0 0 16px rgba(120,255,210,.55); }
.skill.potion b { position: absolute; bottom: -5px; right: -5px; font: 800 12px var(--num); background: #1a0808; border: 1px solid #8a3a2c; border-radius: 8px; padding: 0 6px; }
#menuBtns { position: absolute; bottom: 18px; left: 16px; display: grid; grid-template-columns: repeat(4, 52px); gap: 12px 9px; direction: ltr; }
.mbtn { position: relative; width: 52px; height: 52px; border-radius: 12px; border: 0; display: grid; place-items: center; background: radial-gradient(circle at 50% 35%, #333a58, #0c0e18 75%); box-shadow: 0 0 0 1px #1a1206, 0 0 0 2.5px #a07a34, 0 0 0 3.5px #2a1c08; }
.mbtn:hover { filter: brightness(1.3); } .mbtn kbd { position: absolute; top: -8px; left: -6px; font-size: 10px; }
#death { position: fixed; inset: 0; display: grid; place-items: center; background: radial-gradient(ellipse, rgba(60,0,0,.25), rgba(0,0,0,.7)); z-index: 30; }
#death > div, #disc > div { padding: 18px 34px; text-align: center; display: grid; gap: 10px; justify-items: center; }
#death h2, #disc h2 { margin: 0; font: 400 40px var(--display); color: #ff8a6a; } #death p, #disc p { margin: 0 0 8px; color: var(--dim); }
#disc { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; background: rgba(0,0,0,.7); }

/* ── tooltip ── */
#tip { position: fixed; z-index: 80; max-width: 300px; padding: 10px 14px; border-radius: 8px; background: linear-gradient(180deg, #1e2236, #0c0e18); box-shadow: 0 0 0 1px #000, 0 0 0 2.5px #9a7432, 0 10px 24px rgba(0,0,0,.65); font-size: 14px; pointer-events: none; line-height: 1.6; }
#tip b { font: 700 17px var(--head); } #tip .sub { font-size: 12.5px; color: var(--dim); margin-bottom: 4px; }
#tip i.up { color: #7dff9a; font-style: normal; font-size: 12px; } #tip i.dn { color: #ff7a6a; font-style: normal; font-size: 12px; }
#tip .val { display: flex; gap: 4px; align-items: center; margin-top: 4px; }
#tip .ticon { float: left; margin: 0 0 4px 10px; width: 64px; height: 64px; border-radius: 8px; }

/* ── windows ── */
.win { position: fixed; z-index: 40; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 500px; max-height: 88vh; overflow: auto; scrollbar-width: thin; scrollbar-color: #6a5428 transparent; animation: win .18s ease-out; }
.win.wide { width: 780px; }
@keyframes win { from { opacity: 0; transform: translate(-50%, -48%) scale(.97); } }
.win header { position: sticky; top: -34px; z-index: 2; display: flex; justify-content: space-between; align-items: center; margin: -14px -8px 12px; padding: 4px 8px 10px; background: linear-gradient(180deg, rgba(20,22,36,1) 70%, rgba(20,22,36,0)); }
.win h2 { margin: 0; font: 700 26px var(--head); background: linear-gradient(180deg, #fff6d0, #e8b450); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 2px 0 #2a1604); }
.win .x { border: 0; background: radial-gradient(circle, #3a2a1a, #1a120a); width: 32px; height: 32px; border-radius: 50%; color: #f0d8a0; font-size: 16px; box-shadow: 0 0 0 1px #000, 0 0 0 2px #8a6a2c; } .win .x:hover { color: #fff; filter: brightness(1.3); }
.win h3 { margin: 6px 0; font: 700 20px var(--head); color: var(--gold); }
.cell { position: relative; width: 56px; height: 56px; border-radius: 8px; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--rc, #555) 26%, #161a28), #0a0c14 80%); box-shadow: inset 0 0 0 1.5px var(--rc, #2a2a36), 0 0 0 1px #000; cursor: pointer; overflow: hidden; }
.cell img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 2px 2px rgba(0,0,0,.6)); pointer-events: none; }
.cell.empty { --rc: #262a38; cursor: default; background: #0c0e16; }
.cell.r2, .cell.r3, .cell.r4 { box-shadow: inset 0 0 0 1.5px var(--rc), 0 0 0 1px #000, inset 0 0 14px color-mix(in srgb, var(--rc) 50%, transparent); }
.cell.r4 { animation: legend 2s infinite alternate; } @keyframes legend { to { box-shadow: inset 0 0 0 1.5px var(--rc), 0 0 0 1px #000, inset 0 0 22px color-mix(in srgb, var(--rc) 75%, transparent), 0 0 12px color-mix(in srgb, var(--rc) 55%, transparent); } }
.cell .upg { position: absolute; top: 1px; left: 4px; font-style: normal; font-size: 11px; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }
.cell .cnt { position: absolute; bottom: 0; right: 3px; font: 800 11px var(--num); font-style: normal; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }
.cell.sel { outline: 2px solid #ffe08a; outline-offset: 1px; }
#bagGrid { display: grid; grid-template-columns: repeat(6, 56px); gap: 9px; justify-content: center; direction: ltr; }
#bagInfo { display: flex; gap: 6px; align-items: center; justify-content: center; margin: 14px 0 8px; font: 800 14px var(--num); direction: ltr; }
#bagInfo span { color: var(--dim); }
#bagAct { display: flex; gap: 8px; justify-content: center; min-height: 38px; align-items: center; flex-wrap: wrap; }
.charwrap { display: grid; grid-template-columns: 360px 1fr; gap: 18px; }
#paper { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 190px; padding: 6px 0; direction: ltr; }
.pslot { display: grid; justify-items: center; gap: 1px; z-index: 1; } .pslot small { font-size: 12px; }
.pfig { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); pointer-events: none; width: 180px; height: 280px; border-radius: 50% 50% 12px 12px / 30% 30% 12px 12px; background: radial-gradient(ellipse at 50% 72%, rgba(240,205,120,.18), transparent 65%); }
.pfig canvas { width: 100%; height: 100%; display: block; }
#stats { display: grid; gap: 5px; align-content: start; }
#stats > div { display: flex; justify-content: space-between; padding: 6px 12px; background: rgba(0,0,0,.28); border-radius: 6px; font-size: 15px; }
#stats > div b { font: 800 15px var(--num); direction: ltr; } #stats .big { display: grid !important; background: none !important; padding: 0 0 6px !important; }
#stats .big b { font: 700 24px var(--head); color: #fff4d8; } #stats .big span { color: var(--dim); font-size: 14px; }
#stats .gs { background: linear-gradient(90deg, rgba(240,205,120,.2), rgba(240,205,120,.04)) !important; } #stats .gs b { color: var(--gold); }
#questList { display: grid; gap: 8px; }
.q { padding: 10px 14px; border-radius: 8px; background: rgba(0,0,0,.3); border-inline-start: 4px solid #4a4030; display: grid; gap: 3px; }
.q b { font: 700 17px var(--head); } .q span { font-size: 13px; color: var(--gold); } .q p { margin: 0; font-size: 14px; color: #e0d6c2; }
.q.a { border-color: var(--gold); } .q.c { border-color: #7dff9a; } .q.t { opacity: .55; border-color: #3a6a3a; } .q.locked { opacity: .4; } .q.avail { border-color: #ffd23a; }
#dlgBody .npc { display: grid; gap: 4px; padding: 12px 14px; background: rgba(0,0,0,.32); border-radius: 8px; margin-bottom: 8px; }
#dlgBody .npc b { font: 700 19px var(--head); color: var(--gold); } #dlgBody .npc p { margin: 0; font-size: 16px; color: #f0e4c8; }
#dlgBody p { margin: 4px 0; font-size: 15px; } #dlgAct { display: flex; gap: 8px; justify-content: flex-start; margin-top: 14px; }
.forgewrap { display: grid; grid-template-columns: 280px 1fr; gap: 16px; }
#forgeList { display: grid; gap: 5px; align-content: start; max-height: 58vh; overflow-y: auto; padding-inline-end: 4px; }
.frow { display: flex; align-items: center; gap: 8px; padding: 4px 8px 4px 4px; border-radius: 8px; cursor: pointer; background: rgba(0,0,0,.22); border: 1px solid transparent; }
.frow .cell { width: 44px; height: 44px; } .frow span { flex: 1; font-size: 14px; font-weight: 700; }
.frow:hover { background: rgba(255,255,255,.05); } .frow.sel { border-color: var(--gold2); background: rgba(240,205,120,.1); }
#forgePane { display: grid; gap: 9px; justify-items: center; align-content: start; text-align: center; padding: 8px; border-radius: 10px; background: radial-gradient(ellipse at 50% 20%, rgba(255,140,40,.14), transparent 60%); }
.fbig { --rc: #888; position: relative; width: 120px; height: 120px; border-radius: 16px; display: grid; place-items: center; background: radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--rc) 32%, #1a1e2c), #0a0c14 75%); box-shadow: inset 0 0 0 2px var(--rc), 0 0 0 1px #000, 0 0 26px color-mix(in srgb, var(--rc) 38%, transparent); overflow: hidden; }
.fbig img { width: 100%; height: 100%; object-fit: contain; }
.fbig .upg { position: absolute; top: 4px; left: 8px; font-size: 18px; }
.fbig.ok { animation: fok .9s ease-out; } .fbig.fail { animation: ffail .6s; }
@keyframes fok { 0% { box-shadow: inset 0 0 0 2px #fff, 0 0 0 1px #000, 0 0 80px #ffc040; transform: scale(1.12); } 100% { transform: scale(1); } }
@keyframes ffail { 20%, 60% { transform: translateX(-8px); filter: grayscale(1) brightness(.6); } 40%, 80% { transform: translateX(8px); } }
.fstats { width: 100%; display: grid; gap: 4px; } .fstats div { display: flex; gap: 8px; justify-content: space-between; padding: 4px 12px; background: rgba(0,0,0,.28); border-radius: 6px; font-size: 14px; }
.fstats b { font-family: var(--num); direction: ltr; } .fstats i { color: #7dff9a; font-style: normal; font-family: var(--num); direction: ltr; }
.fcost { display: flex; gap: 16px; align-items: center; font: 800 15px var(--num); } .fcost span { display: flex; gap: 4px; align-items: center; }
.fcost span:last-child { font: 700 14px var(--body); } .fcost b { color: #ffd76a; }
#shopBody { display: grid; gap: 9px; }
.shopRow { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 8px; background: rgba(0,0,0,.28); }
.shopRow div { flex: 1; display: grid; } .shopRow b { font: 700 16px var(--head); }
.gold-line { display: flex; gap: 6px; align-items: center; justify-content: center; font: 800 16px var(--num); margin: 6px 0 0; }
#bigmap { display: block; width: 100%; height: auto; border-radius: 8px; box-shadow: 0 0 0 1px #000, 0 0 0 2px #6a5428; cursor: crosshair; }
.hgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 18px; } .hgrid div { display: flex; gap: 4px; align-items: center; padding: 5px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
.hgrid span { margin-inline-start: 8px; font-size: 14px; }
#helpBody ul { margin: 4px 0; padding-inline-start: 18px; color: #e0d6c2; } #helpBody li { margin: 3px 0; }
.vol { display: flex; gap: 20px; margin-top: 12px; } .vol label { display: flex; gap: 8px; align-items: center; font-size: 14px; } .vol input { accent-color: #e0b050; }
/* stable */
.stabs { display: flex; gap: 8px; margin-bottom: 10px; } .stabs .btn.on { box-shadow: 0 0 0 2px #ffe39a, 0 0 14px rgba(255,220,140,.4); }
#stableList { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.beast { display: grid; grid-template-columns: 64px 1fr; gap: 4px 10px; padding: 9px; border-radius: 10px; background: rgba(0,0,0,.3); box-shadow: inset 0 0 0 1.5px var(--rc, #333); align-items: center; }
.beast img { width: 64px; height: 64px; grid-row: span 3; border-radius: 8px; background: radial-gradient(circle, color-mix(in srgb, var(--rc) 30%, #141826), #090b12); }
.beast b { font: 700 16px var(--head); } .beast small { font-size: 12.5px; } .beast .btn { padding: 3px 10px; font-size: 13px; justify-self: start; }
.beast.locked { opacity: .45; filter: grayscale(.6); } .beast.active { box-shadow: inset 0 0 0 2px #8affd8, 0 0 14px rgba(120,255,210,.3); }
#castbar { position: absolute; bottom: 214px; left: 50%; transform: translateX(-50%); width: 300px; display: grid; gap: 4px; text-align: center; font: 700 14px var(--body); }
#castbar .bar i { background: linear-gradient(180deg, #a8ffd8, #2ea88a); transition: none; }

@media (max-width: 1180px) { #target { right: 16px; top: 196px; } #xp { width: 440px; } .mm-panel { width: 380px; right: 16px; } .mm-logo b { font-size: 60px; } }


/* ════════ v3 ════════ */
/* wallet: resources sit above the menu buttons, bottom-left */
#wallet { position: absolute; bottom: 152px; left: 16px; display: flex; gap: 6px; direction: ltr; }
#wallet span { display: flex; gap: 6px; align-items: center; padding: 4px 12px 4px 6px; border-radius: 18px; background: linear-gradient(180deg, rgba(30,32,50,.92), rgba(10,12,20,.94)); box-shadow: 0 0 0 1px #120c04, 0 0 0 2px #9a7432, inset 0 1px 0 rgba(255,230,170,.15); }
#wallet b { font: 800 15px var(--num); color: #fff2cc; -webkit-text-stroke: 3px rgba(0,0,0,.6); paint-order: stroke fill; min-width: 18px; }
#aiBadge { position: absolute; top: 212px; left: 22px; font: 700 11.5px var(--body); color: #b8b0c8; padding: 2px 10px; border-radius: 10px; background: rgba(10,10,18,.75); box-shadow: 0 0 0 1px #3a2a50; display: flex; gap: 6px; align-items: center; white-space: nowrap; }
#aiBadge.on { color: #e6d8ff; box-shadow: 0 0 0 1px #7a4ad0, 0 0 10px rgba(150,100,255,.35); } #aiBadge b { color: #fff; }
#aiBadge i { width: 7px; height: 7px; border-radius: 50%; background: #9aff9a; box-shadow: 0 0 6px #6aff6a; } #aiBadge i.off { background: #6a6a6a; box-shadow: none; }
#tracker { top: 240px; width: 270px; padding: 10px 12px; gap: 7px; }
.tq { position: relative; display: grid; gap: 1px; padding: 4px 6px 5px; border-radius: 6px; opacity: .72; transition: opacity .2s, background .2s; }
.tq.top { opacity: 1; background: rgba(240,205,120,.08); box-shadow: inset 2px 0 0 var(--gold); }
.tq:hover { opacity: 1; background: rgba(255,255,255,.04); }
.tq b { font: 700 15px var(--head) !important; } .tq small { font-size: 13px !important; }
.tq.done b { color: #7dff9a !important; } .tq em { position: absolute; top: 4px; left: 6px; font: 800 11px var(--num); font-style: normal; color: #ffe39a; }
.tq .star { color: #ffd23a; font-style: normal; margin-inline-end: 4px; float: right; } .tq .star.ai { color: #c89aff; }
#tracker .more { font-size: 12px !important; color: var(--dim) !important; }
/* party frames */
#party { position: absolute; top: auto; bottom: 214px; left: 14px; width: 220px; padding: 8px 10px; display: grid; gap: 6px; }
#party header { display: flex; gap: 6px; align-items: center; font: 700 14px var(--head); color: #9fd0ff; justify-content: space-between; }
.btn.tiny { padding: 1px 8px; font-size: 11px; }
.pm { display: grid; grid-template-columns: 22px 1fr auto; gap: 2px 6px; align-items: center; cursor: pointer; }
.pm b { font: 700 13px var(--body); color: var(--c); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .pm em { font: 800 11px var(--num); font-style: normal; color: #ffe39a; }
.pm .bar { grid-column: 1 / -1; height: 9px; } .pm .lead { position: absolute; margin-top: -14px; font-style: normal; font-size: 11px; }
.pm.far { opacity: .45; } .pm.dead { filter: grayscale(1); opacity: .6; }
/* combo counter + finisher */
#combo { position: fixed; z-index: 45; top: 34%; right: 9%; display: grid; justify-items: center; opacity: 0; pointer-events: none; transform: scale(.8); transition: opacity .2s, transform .2s; }
#combo.show { opacity: 1; transform: scale(1); }
#combo b { font: 400 64px/1 var(--display); background: linear-gradient(180deg, #fffbe8, #ffd060 45%, #c46a10); -webkit-background-clip: text; background-clip: text; color: transparent; filter: drop-shadow(0 3px 0 #2a1004) drop-shadow(0 0 14px rgba(255,170,60,.6)); }
#combo span { font: 700 18px var(--head); color: #ffe6b8; -webkit-text-stroke: 3px rgba(0,0,0,.8); paint-order: stroke fill; margin-top: -6px; }
#combo i { width: 110px; height: 5px; border-radius: 3px; background: rgba(0,0,0,.6); overflow: hidden; margin-top: 4px; } #combo u { display: block; height: 100%; background: linear-gradient(90deg, #ffd060, #ff7a2a); transform-origin: right; }
#combo.pop b { animation: cpop .25s ease-out; } @keyframes cpop { from { transform: scale(1.5); } }
#combo.hot b { background-image: linear-gradient(180deg, #fff2e0, #ff8a3a 45%, #c4200a); } #combo.max b { background-image: linear-gradient(180deg, #fff, #d8a0ff 45%, #6a1ad0); animation: cpop .25s ease-out, hue 1.2s linear infinite; }
@keyframes hue { to { filter: drop-shadow(0 3px 0 #2a1004) drop-shadow(0 0 20px rgba(200,120,255,.9)) hue-rotate(360deg); } }
#finisher { --c: #ffc04a; position: fixed; z-index: 47; top: 38%; left: 50%; transform: translate(-50%, -50%) scale(.6); text-align: center; opacity: 0; pointer-events: none; display: grid; justify-items: center; }
#finisher.show { animation: fin 1.8s ease-out forwards; }
@keyframes fin { 0% { opacity: 0; transform: translate(-50%, -50%) scale(2.2); } 12% { opacity: 1; transform: translate(-50%, -50%) scale(1); } 75% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -60%) scale(1.05); } }
#finisher b { font: 400 76px/1.15 var(--display); color: #fff; -webkit-text-stroke: 6px color-mix(in srgb, var(--c) 40%, #000); paint-order: stroke fill; text-shadow: 0 0 30px var(--c), 0 0 60px var(--c); }
#finisher span { font: 700 22px var(--head); color: var(--c); -webkit-text-stroke: 4px #000; paint-order: stroke fill; }
#countdown { position: fixed; z-index: 47; top: 40%; left: 50%; transform: translate(-50%, -50%); font: 400 140px/1 var(--display); color: #ffd060; -webkit-text-stroke: 8px #2a0a00; paint-order: stroke fill; text-shadow: 0 0 40px rgba(255,120,40,.8); opacity: 0; pointer-events: none; }
#countdown.show { animation: cd 1s ease-out; } #countdown.go { color: #ff5a3a; font-size: 110px; }
@keyframes cd { 0% { opacity: 0; transform: translate(-50%, -50%) scale(2); } 20% { opacity: 1; transform: translate(-50%, -50%) scale(1); } 85% { opacity: 1; } 100% { opacity: 0; } }
/* invitations */
#prompts { position: fixed; z-index: 48; top: 120px; left: 50%; transform: translateX(-50%); display: grid; gap: 10px; }
.ask-pop { position: relative; width: 380px; padding: 14px 18px 18px; border-radius: 12px; background: linear-gradient(180deg, #24283e, #0e1018); box-shadow: 0 0 0 1px #000, 0 0 0 3px #b4893e, 0 14px 30px rgba(0,0,0,.6); text-align: center; animation: win .2s ease-out; overflow: hidden; }
.ask-pop.duel { box-shadow: 0 0 0 1px #000, 0 0 0 3px #d84a2a, 0 0 30px rgba(255,80,40,.4), 0 14px 30px rgba(0,0,0,.6); }
.ask-pop p { margin: 0 0 10px; font-size: 16px; } .ask-pop b { color: var(--gold); } .ask-pop div { display: flex; gap: 10px; justify-content: center; }
.ask-pop .tmr { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: #000; } .ask-pop .tmr u { display: block; height: 100%; background: var(--gold); animation: tmr linear forwards; transform-origin: right; }
@keyframes tmr { to { transform: scaleX(0); } }
/* player menu */
#ctx { position: fixed; z-index: 60; min-width: 190px; padding: 8px; border-radius: 10px; background: linear-gradient(180deg, #23273c, #0d0f18); box-shadow: 0 0 0 1px #000, 0 0 0 2.5px #9a7432, 0 12px 26px rgba(0,0,0,.6); display: grid; gap: 3px; }
#ctx b { font: 700 16px var(--head); color: #a8deff; padding: 2px 8px 6px; border-bottom: 1px solid rgba(255,255,255,.08); }
#ctx button { display: flex; gap: 8px; align-items: center; padding: 7px 10px; border: 0; border-radius: 6px; background: none; text-align: start; font: 700 14px var(--body); }
#ctx button:hover { background: rgba(240,205,120,.12); }
/* emote wheel */
#emotes { position: fixed; z-index: 55; top: 50%; left: 50%; width: 0; height: 0; }
#emotes button { position: absolute; left: -42px; top: -42px; width: 84px; height: 84px; border-radius: 50%; border: 0; display: grid; place-items: center; align-content: center; gap: 0; background: radial-gradient(circle at 50% 35%, #353b5a, #0d0f1a 75%); box-shadow: 0 0 0 1px #000, 0 0 0 2.5px #9a7432, 0 8px 18px rgba(0,0,0,.55); font: 700 12px var(--body); animation: win .2s ease-out; }
#emotes button span { font-size: 28px; line-height: 1.1; } #emotes button:hover { box-shadow: 0 0 0 1px #000, 0 0 0 3px #ffe39a, 0 0 18px rgba(255,220,140,.5); filter: brightness(1.2); }
#emotes > i { position: absolute; left: -50px; top: -14px; width: 100px; text-align: center; font: 700 16px var(--head); font-style: normal; color: var(--gold); -webkit-text-stroke: 3px #000; paint-order: stroke fill; }
.float.emote { font: 700 26px var(--body); color: #fff; -webkit-text-stroke: 4px rgba(0,0,0,.6); }
.float.qitem { font: 700 20px var(--head); color: #ffe08a; -webkit-text-stroke: 4px #2a1604; }
.plate.player.duel b { color: #ff7a5a; } .plate.player.duel b::before { content: '⚔ '; }
/* Word Magic overlay */
#wm { position: fixed; z-index: 44; left: 50%; bottom: 176px; transform: translateX(-50%); width: min(760px, 86vw); padding: 14px 22px 12px; border-radius: 18px; text-align: center; display: grid; gap: 6px; justify-items: center;
  background: radial-gradient(ellipse at 50% 120%, color-mix(in srgb, var(--wc) 30%, transparent), transparent 70%), linear-gradient(180deg, rgba(16,14,30,.86), rgba(6,6,14,.92)); box-shadow: 0 0 0 1px #000, 0 0 0 3px color-mix(in srgb, var(--wc) 70%, #6a4a18), 0 0 40px color-mix(in srgb, var(--wc) 40%, transparent), 0 14px 30px rgba(0,0,0,.6); animation: win .2s ease-out; --wc: #ff9a4a; }
#wm.c-warrior { --wc: #ffd060; } #wm.c-ranger { --wc: #6affb8; } #wm.c-healer { --wc: #fff0b0; } #wm.c-mage { --wc: #ff9a4a; }
.wmhead { display: flex; gap: 16px; align-items: baseline; justify-content: center; } .wmhead b { font: 400 30px var(--display); color: var(--wc); -webkit-text-stroke: 4px #000; paint-order: stroke fill; text-shadow: 0 0 18px var(--wc); }
#wmStats { font: 700 14px var(--body); color: #e8dcc8; } #wmStats b { font-family: var(--num); color: #fff; }
#wmWord { display: flex; gap: 0; direction: rtl; justify-content: center; min-height: 92px; align-items: end; }
#wmWord span { display: grid; justify-items: center; gap: 6px; } #wmWord span b { font: 400 68px/1 var(--display); color: #8a8070; -webkit-text-stroke: 5px rgba(0,0,0,.7); paint-order: stroke fill; transition: color .08s, transform .08s; }
#wmWord span.ok b { color: var(--wc); text-shadow: 0 0 22px var(--wc); transform: translateY(-4px); } #wmWord span.cur b { color: #fff; animation: curl 0.7s ease-in-out infinite alternate; }
@keyframes curl { to { text-shadow: 0 0 16px #fff; } }
#wmWord kbd { font-size: 14px; padding: 3px 7px; min-width: 24px; text-align: center; } #wmWord span.ok kbd { opacity: .35; } #wmWord span.cur kbd { border-color: #fff; color: #fff; box-shadow: 0 0 10px var(--wc); }
#wmWord.flash { animation: wflash .35s ease-out; } @keyframes wflash { 0% { filter: brightness(2.2); transform: scale(1.12); } }
#wmWord.shake { animation: shake .3s; }
#wmNext, #wmDone { display: flex; gap: 12px; justify-content: center; direction: rtl; min-height: 26px; } #wmNext span { font: 700 19px var(--head); color: #b8ae9c; }
#wmDone span { font: 700 15px var(--head); color: var(--wc); opacity: .8; }
.wmbars { width: 100%; display: grid; gap: 5px; }
#wmPower, #wmTimer { --p: 0; --k: 0; height: 8px; border-radius: 4px; background: rgba(0,0,0,.6); overflow: hidden; box-shadow: 0 0 0 1px #2a1c08; }
#wmPower i { display: block; height: 100%; width: calc(var(--p) * 100%); background: linear-gradient(90deg, var(--wc), #fff); box-shadow: 0 0 12px var(--wc); transition: width .15s; }
#wmTimer i { display: block; height: 100%; width: calc((1 - var(--k)) * 100%); background: linear-gradient(90deg, #ff5a3a, #ffd060); }
#wm > small { font-size: 12px; }
/* skill bar: gem sockets */
#skillbar { gap: 10px; padding: 12px 18px; }
.skill { background: radial-gradient(circle at 50% 30%, #3e4668, #10121f 70%); box-shadow: 0 0 0 1px #1a1206, 0 0 0 3px #c8963e, 0 0 0 4px #2a1c08, inset 0 3px 8px rgba(255,255,255,.16), inset 0 -6px 12px rgba(0,0,0,.55); }
.skill svg { filter: drop-shadow(0 0 6px rgba(255,220,150,.35)); }
.skill.basic { width: 78px; height: 78px; box-shadow: 0 0 0 1px #1a1206, 0 0 0 4px #e0b050, 0 0 0 5px #2a1c08, inset 0 3px 8px rgba(255,255,255,.18), 0 0 18px rgba(255,200,100,.25); }
.skill.ult { width: 66px; height: 66px; border-radius: 50%; background: radial-gradient(circle at 50% 30%, #5a3a7a, #120a1e 70%); box-shadow: 0 0 0 1px #1a0a26, 0 0 0 3px #c88aff, 0 0 0 4px #2a1040, 0 0 18px rgba(200,140,255,.45); animation: ultg 2.4s ease-in-out infinite; }
@keyframes ultg { 50% { box-shadow: 0 0 0 1px #1a0a26, 0 0 0 3px #e8c8ff, 0 0 0 4px #2a1040, 0 0 30px rgba(220,160,255,.75); } }
.skill.word { border-radius: 50%; width: 56px; height: 56px; margin-inline-start: 6px; background: radial-gradient(circle at 50% 30%, #5a4a2a, #160f06 70%); box-shadow: 0 0 0 1px #1a1206, 0 0 0 3px #ffd27a, 0 0 0 4px #2a1c08, 0 0 14px rgba(255,210,120,.35); }
.skill .lk { position: absolute; inset: 0; border-radius: inherit; display: none; place-items: center; align-content: center; background: rgba(5,6,12,.78); }
.skill .lk b { font: 800 12px var(--num); color: #e8d8b0; margin-top: -2px; }
.skill.locked .lk { display: grid; } .skill.locked svg { opacity: .3; } .skill.locked kbd { opacity: .4; }
.skill .pips { position: absolute; bottom: -7px; left: 50%; transform: translateX(-50%); font-style: normal; font-size: 8px; letter-spacing: 1px; color: #ffd27a; -webkit-text-stroke: 1.5px #000; paint-order: stroke fill; white-space: nowrap; }
.spdot { position: absolute; top: -6px; right: -6px; min-width: 18px; height: 18px; padding: 0 4px; border-radius: 9px; background: #c040ff; color: #fff; font: 800 11px/18px var(--num); font-style: normal; box-shadow: 0 0 0 2px #1a0a26, 0 0 10px #c040ff; animation: glowpulse 1.4s infinite; }
.spdot:empty { display: none; }
/* skills window */
.sphead { display: flex; gap: 10px; align-items: baseline; padding: 10px 14px; border-radius: 10px; background: linear-gradient(90deg, rgba(190,120,255,.18), rgba(190,120,255,.02)); margin-bottom: 10px; }
.sphead b { font: 400 40px/1 var(--display); color: #e0b8ff; } .sphead span { font: 700 17px var(--head); } .sphead small { margin-inline-start: auto; }
.sklist { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.skrow2 { display: grid; grid-template-columns: 56px 1fr auto; gap: 10px; align-items: center; padding: 8px 10px; border-radius: 10px; background: rgba(0,0,0,.3); box-shadow: inset 0 0 0 1px rgba(255,220,150,.08); }
.skrow2.ult { box-shadow: inset 0 0 0 1.5px #a070e0, 0 0 14px rgba(180,120,255,.15); } .skrow2.locked { opacity: .55; }
.skic { position: relative; width: 56px; height: 56px; border-radius: 12px; display: grid; place-items: center; background: radial-gradient(circle at 50% 35%, color-mix(in srgb, var(--c) 30%, #262c46), #0c0e18 75%); box-shadow: 0 0 0 2px #a07a34; }
.skic span { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(0,0,0,.55); border-radius: inherit; }
.skinfo { display: grid; gap: 2px; } .skinfo b { font: 700 16px var(--head); } .skinfo small { font-size: 12.5px; line-height: 1.45; }
.rank { display: flex; gap: 3px; align-items: center; } .rank i { width: 14px; height: 6px; border-radius: 2px; background: #22243a; } .rank i.on { background: linear-gradient(90deg, #e0b8ff, #a050ff); box-shadow: 0 0 5px rgba(190,120,255,.6); }
.rank span { font-size: 11.5px; color: var(--dim); margin-inline-start: 6px; }
.btn.up { width: 36px; height: 36px; padding: 0; font: 800 20px var(--num); border-radius: 50%; }
.ultTag { font: 700 10px var(--body); font-style: normal; background: linear-gradient(90deg, #8a5aff, #c46bff); color: #fff; padding: 1px 6px; border-radius: 4px; vertical-align: 2px; }
.muted { color: var(--dim); font-size: 14px; }
.combos { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; } .combo { padding: 8px 12px; border-radius: 10px; background: rgba(0,0,0,.3); display: grid; gap: 4px; }
.combo b { font: 700 16px var(--head); color: #ffd27a; } .seq { display: flex; gap: 4px; align-items: center; direction: rtl; } .seq span { width: 36px; height: 36px; border-radius: 8px; display: grid; place-items: center; background: #161a2a; box-shadow: 0 0 0 1px #6a5428; } .seq span.off { opacity: .35; } .seq i { color: var(--gold); font-style: normal; }
#tip .rk { color: #d8b8ff; font-size: 12.5px; }
/* quest dialog */
#win-quest { width: 620px; }
#dlgBody .npc { grid-template-columns: 64px 1fr; align-items: center; gap: 12px; }
.npcPic { width: 64px; height: 64px; border-radius: 50%; display: grid; place-items: center; background: radial-gradient(circle at 50% 35%, #4a3a20, #120c06 75%); box-shadow: 0 0 0 2px #1a1206, 0 0 0 4px #c8963e; }
#npcLine .you { color: #a8deff; font-style: normal; font-size: 14px; } #npcLine .thinking { animation: blink 1s infinite; color: var(--gold); } @keyframes blink { 50% { opacity: .2; } }
#npcLine .ai, .rw .ai { font: 800 9px var(--latin); font-style: normal; background: linear-gradient(90deg, #8a5aff, #c46bff); color: #fff; padding: 1px 5px; border-radius: 4px; vertical-align: 2px; }
.qlist { display: grid; gap: 5px; margin: 6px 0; }
.qrow { display: grid; grid-template-columns: auto 1fr auto; gap: 8px; align-items: center; padding: 8px 12px; border-radius: 8px; background: rgba(0,0,0,.28); cursor: pointer; border: 1px solid transparent; }
.qrow:hover { background: rgba(255,255,255,.05); } .qrow.sel { border-color: var(--gold2); background: rgba(240,205,120,.1); }
.qrow b { font: 700 16px var(--head); } .qrow small { font-size: 12.5px; } .qrow small.ok { color: #7dff9a; }
.qrow.ready { box-shadow: inset 3px 0 0 #7dff9a; } .qrow.offer.main { box-shadow: inset 3px 0 0 #ffd23a; } .qrow.offer.ai { box-shadow: inset 3px 0 0 #b07aff; } .qrow.soon { opacity: .45; cursor: default; }
.qtag { font: 700 10.5px var(--body); font-style: normal; padding: 1px 7px; border-radius: 4px; white-space: nowrap; } .qtag.main { background: #5a4010; color: #ffe08a; } .qtag.side { background: #2a3448; color: #c8d8ee; } .qtag.ai { background: linear-gradient(90deg, #5a2aa0, #8a3ac8); color: #fff; }
.qd { padding: 10px 14px; border-radius: 10px; background: rgba(0,0,0,.25); margin-top: 6px; display: grid; gap: 4px; justify-items: start; }
.qd h3 { margin: 2px 0 0; } .qd p { margin: 0; font-size: 15px; color: #f0e4c8; } .goal { font-size: 14px; color: #ffe39a; display: flex; gap: 6px; align-items: center; }
.rewards { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; } .rw { display: inline-flex; gap: 4px; align-items: center; padding: 2px 8px; border-radius: 10px; background: rgba(0,0,0,.35); font: 700 12.5px var(--num); }
.ask { display: flex; gap: 6px; margin-top: 10px; } .ask input { flex: 1; background: #0a0c14; border: 1px solid #4a3a1c; color: var(--text); padding: 8px 12px; border-radius: 8px; font: 600 14px var(--body); outline: none; }
.ask.on input { border-color: #7a4ad0; box-shadow: 0 0 10px rgba(150,100,255,.2); } .ask input:disabled { opacity: .5; }
/* quest log */
.q { grid-template-columns: auto 1fr; gap: 3px 8px; } .q b, .q > span, .q > p, .q .qbar, .q > small, .q .rewards, .q .qa { grid-column: 1 / -1; } .q .qtag { grid-column: 1; justify-self: start; }
.q.tracked { box-shadow: inset 0 0 0 1px var(--gold2); } .qa { display: flex; gap: 6px; margin-top: 4px; } .qa .btn { padding: 3px 12px; font-size: 13px; }
/* inspect */
.ihead { display: flex; gap: 12px; align-items: center; padding: 8px 12px; border-radius: 10px; background: radial-gradient(ellipse at 10% 50%, color-mix(in srgb, var(--c) 22%, transparent), transparent 70%); }
.ihead b { font: 700 22px var(--head); display: block; } .ihead span { font-size: 13px; color: var(--dim); }
.islots { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin: 10px 0; direction: ltr; } .islot { display: grid; justify-items: center; gap: 2px; } .islot small { font-size: 10px; }
.istats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; } .istats div { display: flex; justify-content: space-between; padding: 4px 10px; background: rgba(0,0,0,.28); border-radius: 6px; font-size: 13px; } .istats b { font-family: var(--num); }
/* bag cells: richer item display */
#win-bag { width: 560px; }
#bagGrid { grid-template-columns: repeat(6, 66px); gap: 10px; }
.cell { width: 66px; height: 66px; border-radius: 10px; background: radial-gradient(circle at 50% 38%, color-mix(in srgb, var(--rc, #555) 34%, #1a1e30), #080a12 78%), linear-gradient(135deg, rgba(255,255,255,.06), transparent 40%); box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--rc, #333) 80%, #000), inset 0 0 0 3px rgba(0,0,0,.6), 0 0 0 1px #000, inset 0 8px 14px rgba(255,255,255,.05); transition: transform .1s, filter .1s; }
.cell:not(.empty):hover { transform: translateY(-2px); filter: brightness(1.18); }
.cell img { padding: 3px; }
.cell.empty { background: radial-gradient(circle at 50% 40%, #141826, #080a10 80%); box-shadow: inset 0 0 0 1px #262a3a, inset 0 2px 6px rgba(0,0,0,.6); }
.cell::after { content: ''; position: absolute; top: 3px; right: 3px; width: 6px; height: 6px; transform: rotate(45deg); background: var(--rc, transparent); box-shadow: 0 0 6px var(--rc, transparent); opacity: .9; }
.cell.empty::after, .cell.r0::after { display: none; }
.cell .upg { top: auto; bottom: 2px; left: 4px; font-size: 12px; }
.cell .ilv { position: absolute; top: 2px; left: 4px; font: 800 10px var(--num); font-style: normal; color: #d8d0c0; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }
.cell .better { position: absolute; bottom: 2px; right: 4px; font-style: normal; font-size: 12px; color: #7dff9a; -webkit-text-stroke: 2px #000; paint-order: stroke fill; }
.cell.r3 { animation: epic 2.6s infinite alternate; } @keyframes epic { to { box-shadow: inset 0 0 0 2px var(--rc), inset 0 0 0 3px rgba(0,0,0,.6), 0 0 0 1px #000, inset 0 0 18px color-mix(in srgb, var(--rc) 55%, transparent); } }
.frow .cell { width: 48px; height: 48px; }

#bagInfo { gap: 14px; padding: 8px 14px; border-radius: 10px; background: linear-gradient(180deg, rgba(0,0,0,.35), rgba(0,0,0,.15)); box-shadow: inset 0 0 0 1px rgba(240,205,120,.15); }
#bagInfo svg { vertical-align: -4px; }
#bagAct .btn { min-width: 96px; }
.bagcap { flex: 1; max-width: 140px; height: 8px; border-radius: 4px; background: #0a0a10; overflow: hidden; box-shadow: 0 0 0 1px #4a3a1c; } .bagcap i { display: block; height: 100%; background: linear-gradient(90deg, #6a9a3a, #c8e080); }
.bagcap.full i { background: linear-gradient(90deg, #a8341a, #ff8a4a); }
