[hidden]{display:none!important}
html,body{margin:0;height:100%;overflow:hidden;background:#000;font-family:Tahoma,Verdana,sans-serif;color:#eee;user-select:none}
#view{position:fixed;inset:0;width:100%;height:100%;display:block}
#screens{position:fixed;inset:0;display:grid;place-items:center;background:radial-gradient(ellipse at center,#2a1a0acc,#000e 75%);z-index:10}
#screens.off{display:none}
.panel{width:min(400px,92vw);background:#0b0805ee;border:1px solid #6b4a1f;border-radius:8px;padding:24px;box-shadow:0 0 50px #000;grid-area:1/1}
.panel.wide{width:min(560px,94vw)}
.panel h1{margin:0 0 16px;text-align:center;color:#f0c060;letter-spacing:3px;font-family:Georgia,serif;font-size:24px}
.panel label{display:block;font-size:12px;margin:12px 0 4px;color:#c9b48a}
.panel input{width:100%;box-sizing:border-box;padding:9px;background:#000;border:1px solid #5a3e1a;color:#fff;border-radius:4px;font-size:14px}
.panel button{padding:10px 14px;background:#1c140c;border:1px solid #5a3e1a;color:#e8d9b5;border-radius:4px;cursor:pointer;font-size:13px}
.panel button:hover{border-color:#c98a2a}
.panel button.main{background:linear-gradient(#c98a2a,#7a4d12);border:0;color:#fff;font-weight:bold;width:100%;margin-top:16px;padding:11px}
.panel button.ghost{background:none}
.row{display:flex;gap:8px;margin-top:14px}.row>*{flex:1}.row .main{margin-top:0}
.tabs{display:flex;gap:6px}.tabs button{flex:1}.tabs button.sel,.classes button.sel{background:#5a3e1a;color:#fff}
.classes{display:flex;gap:6px}.classes button{flex:1;padding:10px 4px;font-size:12px}
.classes small{display:block;color:#a99;font-size:10px;margin-top:4px}
.msg{min-height:18px;margin-top:10px;font-size:13px;color:#f88;text-align:center}.msg.ok{color:#8f8}
#loadbar{height:10px;background:#221a10;border:1px solid #5a3e1a;border-radius:5px;overflow:hidden}
#loadfill{height:100%;width:0;background:linear-gradient(90deg,#a06010,#f0c060);transition:width .2s}
#loadtxt{font-size:12px;color:#a99;margin:6px 0 0;text-align:center}
#charlist{display:grid;gap:8px}
.ch{display:flex;align-items:center;gap:12px;padding:12px;border:1px solid #4a3418;border-radius:6px;background:#140e08;cursor:pointer}
.ch:hover{border-color:#c98a2a;background:#20160c}
.ch b{color:#f0c060;font-size:16px}.ch .c{color:#a99;font-size:12px}.ch .sp{flex:1}
.ch .del{background:none;border:0;color:#a55;font-size:12px;padding:4px}
.empty{color:#888;text-align:center;padding:18px;font-size:13px}
#hud{position:fixed;inset:0;pointer-events:none;z-index:5}
#hud .win,#bar .mbtn,#skills .sk,#labels .lbl{pointer-events:auto}
#bar{position:absolute;left:50%;bottom:0;width:640px;height:48px;transform-origin:50% 100%}
#bar img{position:absolute;top:0;height:48px}
#bar .b1{left:0;width:256px}#bar .b2{left:256px;width:128px}#bar .b3{left:384px;width:256px}
.orb{position:absolute;top:0;width:53px;height:48px;z-index:2;overflow:hidden}
.orb.hp{left:97px}.orb.mp{left:490px}
.orb .fill{position:absolute;left:0;right:0;bottom:0;height:100%;background-position:bottom;background-size:53px 48px;background-repeat:no-repeat}
.orb.hp .fill{background-image:url(../assets/ui/menu_red.jpg)}.orb.mp .fill{background-image:url(../assets/ui/menu_blue.jpg)}
.hot{position:absolute;top:21px;width:19px;height:19px;z-index:3;background-size:contain;background-repeat:no-repeat;background-position:center;font-size:9px;text-align:right;color:#fff;text-shadow:0 0 2px #000,0 0 2px #000;line-height:30px}
#hot-q{left:208px}#hot-w{left:240px}#hot-e{left:272px}
.mbtn{position:absolute;top:19px;width:22px;height:22px;z-index:3;cursor:pointer}
#lvbox{position:absolute;left:8px;top:27px;width:52px;height:15px;z-index:3;color:#ffd890;font:bold 11px/15px sans-serif;text-align:center;text-shadow:0 0 2px #000}
#mb-skill{left:582px!important;top:26px!important;width:50px!important;height:20px!important}
#mb-char{left:344px}#mb-inv{left:377px}#mb-menu{left:409px}
#hptxt,#mptxt{position:absolute;top:-15px;width:80px;text-align:center;font-size:10px;z-index:3;text-shadow:0 0 3px #000}
#hptxt{left:83px}#mptxt{left:476px}
#exp{position:absolute;left:160px;right:160px;top:-7px;height:5px;background:#000a;border:1px solid #432}
#expfill{height:100%;width:0;background:#e8c040}
#exptxt{position:absolute;top:-12px;font-size:8px;width:100%;text-align:center;font-size:9px;color:#dc9;text-shadow:0 0 2px #000}
#skills{position:absolute;bottom:118px;left:50%;transform:translateX(-50%);display:flex;gap:4px}
.sk{min-width:58px;padding:3px 6px;font-size:10px;text-align:center;background:#0b0805cc;border:1px solid #4a3418;border-radius:3px;cursor:pointer;color:#cba}
.sk.sel{border-color:#f0c060;color:#fff;background:#3a2810dd}.sk b{display:block;color:#f0c060;font-size:9px}
#target{position:absolute;top:14px;left:50%;transform:translateX(-50%);text-align:center;min-width:220px;max-width:min(360px,90vw);pointer-events:none;z-index:5}
#tname[data-pk="1"]{color:#ffe0c0}#tname[data-pk="2"]{color:#ff9a2e}#tname[data-pk="3"]{color:#ff4a3a}#tname[data-pk="4"]{color:#8fdcff}
#tname{font-size:13px;color:#ffb070;text-shadow:0 0 3px #000;margin-bottom:3px}
.tbar{height:6px;background:#300;border:1px solid #844}#thp{height:100%;background:#d22;width:100%}
#info{position:absolute;top:8px;right:12px;font-size:12px;color:#ddc;text-shadow:0 0 3px #000}
#charinfo{position:absolute;top:8px;left:12px;font-size:12px;color:#ddc;text-shadow:0 0 3px #000}
#log{position:absolute;left:12px;bottom:150px;font-size:12px;line-height:1.5;text-shadow:0 0 3px #000,0 0 3px #000;max-width:45vw}
#log div{animation:fade 8s forwards}@keyframes fade{0%,75%{opacity:1}100%{opacity:0}}
#dead{position:absolute;top:40%;width:100%;text-align:center;font-size:22px;color:#f55;text-shadow:0 0 6px #000}
#fx{position:fixed;inset:0;pointer-events:none;z-index:6;overflow:hidden}
.dmg{position:absolute;transform:translate(-50%,-50%);white-space:nowrap;pointer-events:none}
.dmg b{display:inline-block;font:900 20px 'Trebuchet MS',Tahoma,sans-serif;letter-spacing:.5px;color:#ffe9a8;text-shadow:0 0 2px #000c,1px 1px 0 #000a,-1px -1px 0 #0006,0 0 8px #ff9a2066;animation:dpop .28s cubic-bezier(.2,1.6,.4,1) both}
.dmg.big b{font-size:24px;color:#fff0c0}
.dmg.hurt b{color:#ff4a4a;font-size:18px;text-shadow:0 0 2px #000c,1px 1px 0 #000a,-1px -1px 0 #0006,0 0 8px #ff000055}
.dmg.crit b{color:#6fd6ff;font-size:26px;text-shadow:0 0 2px #000c,1px 1px 0 #000a,-1px -1px 0 #0006,0 0 10px #2a9cff99;animation:dpop .3s cubic-bezier(.2,1.6,.4,1) both,dshake .25s .3s 1}
.dmg.excd b{color:#7dff7a;font-size:26px;text-shadow:0 0 2px #000c,1px 1px 0 #000a,-1px -1px 0 #0006,0 0 10px #20ff4099;animation:dpop .3s cubic-bezier(.2,1.6,.4,1) both,dshake .25s .3s 1}
.dmg.exp b{color:#f0d060;font-size:13px}.dmg.heal b{color:#70ff70;font-size:14px}.dmg.miss b{color:#d0d0d0;font-size:13px;font-style:italic}
.dmg.lvup b{color:#ffe070;font:bold 24px Georgia,serif;text-shadow:0 0 8px #ff9000,0 0 2px #000;letter-spacing:2px}
.dmg.reward b{animation:none}
@keyframes dpop{0%{transform:scale(2.2);opacity:0}60%{opacity:1}100%{transform:scale(1)}}
@keyframes dshake{0%,100%{transform:translateX(0) scale(1)}25%{transform:translateX(-3px) scale(1.08)}75%{transform:translateX(3px) scale(1.08)}}
/* kill streak */
.kfx{position:fixed;left:50%;top:26%;transform:translate(-50%,-50%);z-index:70;pointer-events:none;text-align:center;width:min(92vw,900px);animation:kout 3.2s ease forwards}
.kfx .kt{position:relative;font:900 clamp(34px,9vw,84px)/1 Georgia,'Times New Roman',serif;letter-spacing:clamp(2px,1vw,8px);background:linear-gradient(#fffbe0 10%,#ffd050 45%,#ff7a10 70%,#a01800);-webkit-background-clip:text;background-clip:text;color:transparent;
  -webkit-text-stroke:1.5px #2a0800;filter:drop-shadow(0 0 10px #ff6a00) drop-shadow(0 4px 2px #000);animation:kin .55s cubic-bezier(.2,1.5,.4,1) both}
.kfx .kt::after{content:attr(data-t);position:absolute;inset:0;background:linear-gradient(110deg,transparent 40%,#fffffff0 50%,transparent 60%) -200% 0/300% 100% no-repeat;-webkit-background-clip:text;background-clip:text;color:transparent;-webkit-text-stroke:0;animation:ksheen 1.4s .4s ease-out}
.kfx .ks{margin-top:8px;font:bold clamp(12px,2.6vw,18px) 'Trebuchet MS',sans-serif;color:#ffe0b0;text-shadow:0 0 6px #000,0 1px 0 #000;letter-spacing:1px;animation:kin2 .5s .25s both}
.kfx .kring{position:absolute;left:50%;top:40%;width:60px;height:60px;margin:-30px;border-radius:50%;border:4px solid #ffb040;box-shadow:0 0 30px #ff6a00,inset 0 0 20px #ff6a00;animation:kring .8s ease-out both}
.kfx.t2 .kt{background-image:linear-gradient(#ffffff 10%,#ff9a9a 45%,#e01010 75%,#500000);filter:drop-shadow(0 0 12px #ff1010) drop-shadow(0 4px 2px #000)}
.kfx.t3 .kt,.kfx.t5 .kt{background-image:linear-gradient(#ffffff 10%,#ffe9a0 40%,#ffb000 65%,#8a4a00);filter:drop-shadow(0 0 16px #ffc000) drop-shadow(0 0 30px #ff8000) drop-shadow(0 4px 2px #000)}
.kfx.t4 .kt,.kfx.t6 .kt{background-image:linear-gradient(#ffffff 10%,#d8b0ff 40%,#9040ff 70%,#300060);filter:drop-shadow(0 0 16px #a050ff) drop-shadow(0 0 32px #6020ff) drop-shadow(0 4px 2px #000)}
.kfx.t3 .kring,.kfx.t5 .kring{border-color:#ffd040;box-shadow:0 0 40px #ffb000,inset 0 0 24px #ffb000}
.kfx.t4 .kring,.kfx.t6 .kring{border-color:#c080ff;box-shadow:0 0 40px #8030ff,inset 0 0 24px #8030ff}
.kfx.t3 .kt,.kfx.t4 .kt,.kfx.t5 .kt,.kfx.t6 .kt{animation:kin .55s cubic-bezier(.2,1.5,.4,1) both,kshake .4s .55s 2}
@keyframes kin{0%{transform:scale(3.2);opacity:0;filter:blur(8px)}100%{transform:scale(1);opacity:1}}
@keyframes kin2{0%{transform:translateY(12px);opacity:0}100%{transform:none;opacity:1}}
@keyframes kring{0%{transform:scale(.2);opacity:1}100%{transform:scale(9);opacity:0}}
@keyframes ksheen{to{background-position:200% 0}}
@keyframes kshake{0%,100%{transform:translate(0)}20%{transform:translate(-4px,2px)}40%{transform:translate(4px,-2px)}60%{transform:translate(-3px,-1px)}80%{transform:translate(3px,1px)}}
@keyframes kout{0%,78%{opacity:1}100%{opacity:0;transform:translate(-50%,-62%)}}
#labels .lbl{position:absolute;transform:translate(-50%,-100%);font-size:11px;white-space:nowrap;text-shadow:0 0 3px #000,0 0 2px #000;cursor:pointer;padding:1px 3px}
#labels .lbl.npc{color:#9cf}#labels .lbl.me{color:#fff;pointer-events:none}
#labels .lbl.item{color:#fff;background:#0008;border-radius:2px}#labels .lbl.item.exc{color:#7cf}#labels .lbl.item.gold{color:#fd6}#labels .lbl.item.jw{color:#f9f}
.win{position:absolute;background:#0b0805f2;border:1px solid #6b4a1f;border-radius:4px;box-shadow:0 0 20px #000;color:#ddd;font-size:12px}
.wt{padding:6px 10px;background:linear-gradient(#3a2810,#1a1008);color:#f0c060;font-weight:bold;border-bottom:1px solid #6b4a1f}
.wt .x{float:right;cursor:pointer;color:#c98a2a;font-size:15px;line-height:12px}
#w-inv{right:10px;top:36px;width:274px}
#equip{position:relative;height:240px;margin:8px 0 0 20px}
.slot{position:absolute;background:#1a120a;border:1px solid #4a3418;box-sizing:border-box;background-size:contain;background-repeat:no-repeat;background-position:center}
.slot i{position:absolute;bottom:2px;width:100%;text-align:center;font-size:9px;color:#6a5a40;font-style:normal}
.slot.filled i{display:none}
.slot.over{outline:2px solid #f0c060}
#grid{position:relative;width:256px;height:256px;margin:8px auto;background:#140e08 repeating-linear-gradient(0deg,#3a2810 0 1px,transparent 1px 32px),repeating-linear-gradient(90deg,#3a2810 0 1px,transparent 1px 32px);border:1px solid #4a3418}
.it{position:absolute;background-size:contain;background-repeat:no-repeat;background-position:center;box-sizing:border-box;border:1px solid transparent;cursor:pointer}
.it:hover{border-color:#f0c06088;background-color:#f0c06011}
.it.bad{background-color:#a0202044}
.it .n{position:absolute;right:2px;bottom:0;font-size:10px;color:#fff;text-shadow:0 0 2px #000}
.it .lv{position:absolute;left:2px;top:0;font-size:9px;color:#7cf;text-shadow:0 0 2px #000}
.zen{padding:0 12px 4px;color:#fd6}
.hint{padding:6px 10px 10px;color:#887;font-size:10px;line-height:1.5}
#w-char{left:10px;top:36px;width:250px}
#charstats{padding:10px 12px}
#charstats .r{display:flex;justify-content:space-between;align-items:center;padding:3px 0;border-bottom:1px solid #2a1e10}
#charstats .r b{color:#f0c060}#charstats button{margin-left:6px;background:#5a3e1a;border:0;color:#fff;border-radius:3px;cursor:pointer;width:20px}
#charstats .pts{color:#8f8;padding:6px 0}
#w-shop{left:10px;top:36px;width:310px}
#shopgrid{display:grid;grid-template-columns:repeat(4,1fr);gap:4px;padding:8px;max-height:62vh;overflow:auto}
.sh{height:72px;background:#140e08 center 4px/auto 46px no-repeat;border:1px solid #3a2810;cursor:pointer;position:relative}
.sh:hover{border-color:#f0c060}.sh span{position:absolute;bottom:2px;width:100%;text-align:center;font-size:9px;color:#fd6}
.sh.bad{opacity:.45}
#w-menu{left:50%;top:28%;transform:translateX(-50%);width:300px;text-align:center}
#w-menu button{display:block;width:80%;margin:10px auto;padding:9px;background:#1c140c;border:1px solid #5a3e1a;color:#e8d9b5;border-radius:4px;cursor:pointer}
#tip{position:fixed;z-index:2147483000!important;pointer-events:none;background:#000e;border:1px solid #6b4a1f;padding:8px 10px;font-size:12px;line-height:1.55;max-width:260px;text-align:center}
#tip .nm{font-weight:bold;font-size:13px}#tip .red{color:#f66}#tip .blue{color:#7cf}#tip .gold{color:#fd6}#tip .dim{color:#998}
#drag{position:fixed;z-index:30;pointer-events:none;opacity:.85}
.btnlink{display:flex;align-items:center;justify-content:center;padding:10px 14px;background:#1c140c;border:1px solid #5a3e1a;color:#9cf;border-radius:4px;font-size:13px;text-decoration:none}
.help{font-size:11px;color:#998;text-align:center;margin:10px 0 0}
#banner{position:absolute;top:18%;left:50%;transform:translateX(-50%);padding:10px 26px;background:linear-gradient(90deg,transparent,#000c 20%,#000c 80%,transparent);color:#ffd060;font:bold 20px Georgia,serif;text-shadow:0 0 8px #000;white-space:nowrap;animation:pop .5s ease-out}
@keyframes pop{from{transform:translateX(-50%) scale(1.4);opacity:0}to{transform:translateX(-50%) scale(1);opacity:1}}
#arena{position:absolute;top:48px;left:50%;transform:translateX(-50%);padding:6px 16px;background:#300c;border:1px solid #a33;color:#fdd;font-size:14px;border-radius:4px}
#online{color:#8c8;font-size:11px;margin-top:2px;text-align:right}
#evbar{text-align:right}#evbar span{display:block;color:#fd6;font-size:11px;margin-top:2px}
#w-quest{left:10px;top:36px;width:340px;max-height:78vh;display:flex;flex-direction:column}
#questlist{padding:8px 12px;overflow:auto}
#questlist h4{margin:8px 0 4px;color:#f0c060;font-size:12px}#questlist h4 small{color:#887;font-weight:normal}
.q{border:1px solid #3a2810;background:#140e08;padding:8px;margin-bottom:6px;border-radius:3px}
.q b{color:#fff}.q small{color:#998}.q p{margin:4px 0;color:#cba;line-height:1.4}
.qcls{padding:6px 8px;margin-bottom:6px;background:#1d1408;border:1px solid #5a4018;color:#dcc;font-size:12px}.qcls b{color:#ffd27a}.q.lock{opacity:.7}.q.lock .g{color:#e9a}
.q .g{color:#f99;font-size:11px}.q .g.ok{color:#8f8}.q .rw{color:#fd6;font-size:11px;margin-top:4px}
.q button{margin-top:6px;padding:5px 14px;background:linear-gradient(#c98a2a,#7a4d12);border:0;color:#fff;border-radius:3px;cursor:pointer}
#w-daily{left:10px;top:36px;width:360px;max-height:78vh;display:flex;flex-direction:column}#daily-body{padding:8px 12px;overflow:auto}
#daily-body h4{margin:8px 0 4px;color:#f0c060;font-size:12px}#daily-body .qbar{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:4px}
#daily-body button{margin-top:6px;padding:5px 14px;background:linear-gradient(#c98a2a,#7a4d12);border:0;color:#fff;border-radius:3px;cursor:pointer}#daily-body button[disabled]{opacity:.5;cursor:default}#daily-body .qbar button.on{outline:1px solid #ffd060}
#daily-body .q.claimed{opacity:.7}#daily-body .dstreak div{font-size:11px;color:#998;padding:1px 0}#daily-body .dstreak .now{color:#ffd060}#daily-body .dstreak .past{color:#8f8}
#w-grel{left:10px;top:120px;width:320px;max-height:60vh;display:flex;flex-direction:column}#grel-body{padding:8px 12px;overflow:auto}
#grel-body button{margin:6px 6px 0 0;padding:5px 14px;background:linear-gradient(#c98a2a,#7a4d12);border:0;color:#fff;border-radius:3px;cursor:pointer}
#labels .lbl .gname .gmark{width:12px;height:12px;vertical-align:-2px}#labels .lbl[data-grel="ally"] .gutag{color:#6cf}#labels .lbl[data-grel="rival"] .gutag{color:#f55} 
#labels .lbl[data-title]::before{content:attr(data-title);display:block;color:#ffd060;font-size:10px;font-weight:normal;text-shadow:0 0 2px #000}
#questlist .qbar{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:4px}#questlist .qbar button{padding:4px 12px;background:linear-gradient(#c98a2a,#7a4d12);border:0;color:#fff;border-radius:3px;cursor:pointer}
#questlist [data-quest-completed]{margin-top:6px;padding-top:6px;border-top:1px solid #3a2810}
.dim{color:#887}
#w-move{left:50%;top:18%;transform:translateX(-50%);width:300px}
#movelist{padding:8px}
.mv{display:flex;justify-content:space-between;padding:8px 10px;margin-bottom:4px;background:#140e08;border:1px solid #3a2810;cursor:pointer;border-radius:3px}
.mv:hover{border-color:#f0c060}.mv b{color:#fff}.mv span{color:#998;font-size:11px}.mv i{color:#f66;font-style:normal;font-weight:bold}
.mv.bad{opacity:.45}.mv.cur{border-color:#6b4a1f;background:#2a1c0e}
#nextev div{display:flex;justify-content:space-between;color:#cba}#nextev span{color:#fd6}

#preview{position:fixed;right:4vw;top:50%;transform:translateY(-50%);width:min(36vw,460px);height:min(80vh,620px);z-index:11;pointer-events:none;
  background:radial-gradient(ellipse at center 70%,#3a2810aa,transparent 65%)}
#screens.pv .panel{margin-right:min(36vw,460px)}
.ch.sel{border-color:#f0c060;background:#2a1c0e}

/* ---------- MU-style window skin (textures from Data/Interface) ---------- */
.win{background:#0a0806 url(../assets/ui/item_back01.jpg) center/100% 100% no-repeat;border:2px solid #3a2a14;box-shadow:0 0 0 1px #000,0 0 24px #000;border-radius:2px}
.win .wt{background:linear-gradient(#2a1d0c,#120a04);border-bottom:1px solid #6b4a1f;text-align:center;letter-spacing:1px;font-family:Georgia,serif}
.win .wt .x{position:absolute;right:8px;top:6px;width:16px;height:16px;background:url(../assets/ui/exit_01.jpg) center/contain;color:transparent;overflow:hidden}
.win .wt{position:relative}
.slot{background:#0c0907 var(--ico) center/contain no-repeat;border:1px solid #5a4020;opacity:1}
.slot.filled{background-image:none;background-color:#1a120a}
#w-inv{width:290px}#equip{height:256px;margin:8px auto 0;width:252px;position:relative}
#grid{background:url(../assets/ui/inventorybox2.jpg) 0 0/32px 32px repeat;border:1px solid #5a4020}
.pad{padding:10px 12px}
#w-opt{left:50%;top:22%;transform:translateX(-50%);width:300px}
#w-opt label{display:block;margin:10px 0;color:#cba}#w-opt input[type=range]{width:100%}
#w-skill{left:10px;top:36px;width:320px;max-height:78vh;overflow:auto}
.skr{padding:7px 8px;margin-bottom:5px;background:#140e08cc;border:1px solid #3a2810}.skr b{color:#fff}.skr span{color:#998;font-size:11px;display:block}
.skr.no{opacity:.5}
#w-vault{left:10px;top:36px;width:300px}
#vaultlist{display:grid;grid-template-columns:repeat(4,1fr);gap:4px;min-height:70px;max-height:46vh;overflow:auto}
.vz{margin-top:8px;color:#fd6;font-size:12px}.vz input{width:80px;background:#000;border:1px solid #5a3e1a;color:#fff;padding:3px}
.vz button,#w-vault button{background:#1c140c;border:1px solid #5a3e1a;color:#e8d9b5;padding:3px 7px;cursor:pointer;border-radius:2px}
#w-map{right:10px;top:36px;width:276px;padding-bottom:10px}#minimap{display:block;margin:10px auto 0;width:256px;height:256px;image-rendering:pixelated;border:1px solid #5a4020}
/* ---------- chat window like the original: log, input line, emoticons, channel tabs ---------- */
#chat{position:absolute;left:4px;bottom:220px;width:min(440px,42vw);pointer-events:auto;font-size:12px;z-index:6}
#chatbox{background:linear-gradient(#0008,#000a);border:1px solid #3a2a14;border-bottom:0;height:150px;overflow-y:auto;padding:4px 6px;scrollbar-width:thin;scrollbar-color:#6b4a1f #0006}
#chat.big #chatbox{height:300px}
#chatlog div{line-height:1.55;text-shadow:0 0 2px #000,0 0 2px #000;word-break:break-word;color:#eee}
#chatlog div b{color:#ffe28a;font-weight:normal}
#chatlog .sys{color:#fd6}#chatlog .info{color:#ccc}#chatlog .notice{color:#ffd060}
#chatlog .whisper,#chatlog .whisper b{color:#ff9cf0}
#chatlog .em{font-size:15px;vertical-align:-2px}
#chatbar{display:flex;gap:2px;background:#000c;border:1px solid #3a2a14;padding:2px}
#chatbar input{background:#0d0a06;border:1px solid #4a3418;color:#fff;padding:4px 6px;font-size:12px;outline:none}
#chatbar input:focus{border-color:#b08030}
#chatin{flex:1;min-width:0}#chatwho{width:76px;color:#ff9cf0!important}#chatwho[hidden]{display:none}
#emobtn{background:#1c140c;border:1px solid #5a3e1a;width:28px;cursor:pointer;font-size:15px;padding:0}
#chattabs{display:flex;gap:1px;background:#000c;border:1px solid #3a2a14;border-top:0;padding:2px}
#chattabs button{background:linear-gradient(#3a2a18,#1a120a);border:1px solid #5a3e1a;color:#c9b48a;font-size:11px;padding:2px 7px;cursor:pointer}
#chattabs button.on{background:linear-gradient(#8a2a10,#4a1206);color:#fff;border-color:#c06030}
#chattabs .sp{flex:1}
#chatshow{position:absolute;left:4px;bottom:calc(var(--barh) + 40px);background:#1c140c;border:1px solid #5a3e1a;color:#e8d9b5;padding:3px 8px;cursor:pointer;z-index:6}
#emojipick{position:absolute;left:100%;bottom:0;margin-left:4px;background:#000d;border:1px solid #5a3e1a;padding:4px;width:236px}
#emojipick[hidden]{display:none}
#emgrid{display:grid;grid-template-columns:repeat(9,1fr);gap:1px;height:216px;align-content:start;overflow:hidden}
#emgrid span{font-size:19px;text-align:center;cursor:pointer;border-radius:3px;line-height:26px}
#emgrid span:hover{background:#5a3e1a}
#empages{display:flex;flex-wrap:wrap;gap:2px;justify-content:center;margin-top:4px}
#empages button{background:#1c140c;border:1px solid #5a3e1a;color:#c9b48a;font-size:11px;width:24px;cursor:pointer;padding:2px 0}
#empages button.on{background:#8a2a10;color:#fff}
#log{bottom:150px}
.classes{flex-wrap:wrap}.classes button{min-width:46%}
/* ---------- layout like the original client: full-width bar, windows docked on the right ---------- */
:root{--barh:48px}
#bar{width:640px}
#w-inv{right:0;top:0;bottom:var(--barh);width:300px;display:flex;flex-direction:column;background:#0a0806 url(../assets/ui/item_back02.jpg) center/100% 100% no-repeat;border-width:0 0 0 2px;overflow:auto}
#w-inv[hidden]{display:none!important}
#w-char{right:300px;top:0;bottom:var(--barh);width:260px;background:#0a0806 url(../assets/ui/item_back01.jpg) center/100% 100% no-repeat}
#w-quest,#w-skill,#w-daily{right:0;left:auto;top:0;bottom:var(--barh);max-height:none;width:320px}
#w-inv:not([hidden]) ~ #w-quest{right:300px}
#w-shop,#w-vault{left:0;top:0;bottom:var(--barh);width:310px;max-height:none}
#w-map{right:auto;left:50%;top:60px;transform:translateX(-50%)}
#skills{bottom:calc(var(--barh) + 34px)}
#log{bottom:calc(var(--barh) + 70px)}
#chat{bottom:calc(var(--barh) + 40px)}
#log{display:none}
#exp{top:-7px}
#labels .lbl.me{color:#fff;text-align:center;line-height:1.4}
#labels .lbl .bub{display:inline-block;background:#fff;color:#000;padding:2px 6px;border-radius:3px;font-size:11px;max-width:220px;white-space:normal}
#tip .nm.exc{color:#5f5}#tip .excopt{color:#8cf}
#labels .lbl.item.excl{color:#5f5;font-weight:bold}

/* ---------- skill slot + popup (icons from Data/Interface/skill.jpg) ---------- */
#skillslot{position:absolute;left:307.5px;top:13px;width:24px;height:30px;z-index:3;cursor:pointer;pointer-events:auto;
  background:#000 url(../assets/ui/skill.jpg) 0 0/192px 192px no-repeat;border:1px solid #6b4a1f}
#skillslot span{position:absolute;left:1px;bottom:-1px;font:bold 9px Tahoma;color:#fff;text-shadow:0 0 2px #000}
#skillpop{position:absolute;left:50%;bottom:calc(var(--barh) + 12px);transform:translateX(-50%);display:flex;flex-wrap:wrap;gap:4px;max-width:420px;justify-content:center;
  padding:6px;background:#000a;border:1px solid #6b4a1f;pointer-events:auto}
.si{width:40px;height:40px;background:url(../assets/ui/skill.jpg) 0 0/320px 320px no-repeat;border:1px solid #5a4020;position:relative;cursor:pointer}
.si:hover,.si.sel{border-color:#f0c060;box-shadow:0 0 6px #f0c060}
.si b{position:absolute;left:2px;bottom:0;font:bold 12px Tahoma;color:#fff;text-shadow:0 0 3px #000,0 0 2px #000}
.si.nomp{filter:grayscale(.8) brightness(.6)}
#tip .sd{color:#ccc;font-size:11px}
#w-vault{width:290px}
#vaultlist.vgrid{display:block;position:relative;width:256px;height:480px;margin:0 auto;overflow:hidden;background:url(../assets/ui/inventorybox2.jpg) 0 0/32px 32px repeat;border:1px solid #5a4020;max-height:none}
#w-vault .pad{overflow:auto;max-height:calc(100% - 40px)}
#w-shop{width:290px}
#shopgrid{display:block;position:relative;width:256px;height:480px;margin:8px auto;padding:0;max-height:none;overflow:hidden;background:url(../assets/ui/inventorybox2.jpg) 0 0/32px 32px repeat;border:1px solid #5a4020}
#tip{background:#000d;border:1px solid #333;min-width:200px}
#tip .nm{margin-bottom:4px}
#w-move{max-height:80vh;overflow:auto}#movelist .mv{padding:6px 10px}

/* ---------- GM tools ---------- */
#gmbadge{position:absolute;left:50%;top:6px;transform:translateX(-50%);background:linear-gradient(#5a0c0c,#2a0404);border:1px solid #d04020;color:#ffd0a0;padding:3px 12px;font-size:12px;cursor:pointer;pointer-events:auto;z-index:7;box-shadow:0 0 10px #f402;letter-spacing:.5px}
#gmbadge b{color:#ff6040;margin-right:4px}
#gmhint{position:absolute;left:50%;top:34px;z-index:9!important;transform:translateX(-50%);background:#000c;border:1px solid #c06030;color:#ffd890;padding:4px 12px;font-size:12px;z-index:7}
#gmhint[hidden]{display:none}
#w-gm{left:316px;top:40px;width:400px;max-height:calc(var(--vh,100vh) - 140px);display:flex;flex-direction:column;z-index:8}
#w-gm[hidden]{display:none}
.gmtabs{display:flex;gap:2px;padding:6px 8px 0}.gmtabs button,.gmrow button{background:linear-gradient(#3a2a18,#1a120a);border:1px solid #5a3e1a;color:#e8d9b5;padding:4px 8px;cursor:pointer;font-size:12px}
.gmtabs button.on,.gmrow button.on{background:linear-gradient(#8a2a10,#4a1206);color:#fff;border-color:#c06030}
.gmrow button.red{color:#ff9080}
.gmp{padding:8px;overflow:auto;display:flex;flex-direction:column;gap:6px;min-height:0}
.gmp[hidden]{display:none}
.gmp input,.gmp select{background:#0d0a06;border:1px solid #4a3418;color:#fff;padding:4px 6px;font-size:12px}
.gmrow{display:flex;gap:6px;flex-wrap:wrap;align-items:center}.gmrow label{color:#cba}.gmrow input{width:56px}
.gmnote{color:#a99;font-size:11px}
.gmlist{max-height:260px;overflow:auto;border:1px solid #3a2a14;background:#0006}
.gmlist.small{max-height:150px}
.gmlist div{padding:3px 6px;border-bottom:1px solid #1e150a;cursor:pointer;display:flex;gap:6px;align-items:center}
.gmlist div:hover{background:#3a2a14}.gmlist div.on{background:#5a3010}
.gmlist .lv{color:#9cf;min-width:44px}.gmlist .nm{flex:1;color:#fff}.gmlist .here{color:#5f5;font-size:11px}.gmlist .away{color:#fa6;font-size:11px}
.gmlist button{background:#1c140c;border:1px solid #5a3e1a;color:#e8d9b5;padding:1px 6px;cursor:pointer}
.gmlist img{width:22px;height:22px;object-fit:contain}
.gmsel{color:#ffd890}
#labels .lbl .gmtag{color:#ff6040;font-weight:bold}
#shop-edit{background:#5a0c0c;border:1px solid #d04020;color:#ffd0a0;font-size:10px;padding:1px 6px;cursor:pointer;margin-left:6px}

/* ---------- MU cursors everywhere (instead of the Windows arrow / hand) ---------- */
html,body,*,*::before,*::after{cursor:url(../assets/ui/cursorpush.png) 4 2,default!important}
input[type=text],input[type=password],input:not([type]),input[type=number],textarea{cursor:text!important}
#view.attack{cursor:url(../assets/ui/cursorattack.png) 1 1,crosshair!important}
#view.talk,#labels .lbl.npc{cursor:url(../assets/ui/cursortalk.png) 12 14,pointer!important}
html[data-tk="1"] #view.talk,html[data-tk="1"] #labels .lbl.npc{cursor:url(../assets/ui/cursortalk1.png) 12 14,pointer!important}
html[data-tk="2"] #view.talk,html[data-tk="2"] #labels .lbl.npc{cursor:url(../assets/ui/cursortalk2.png) 12 14,pointer!important}
html[data-tk="3"] #view.talk,html[data-tk="3"] #labels .lbl.npc{cursor:url(../assets/ui/cursortalk3.png) 12 14,pointer!important}
#labels .lbl.item,.it,.slot .it,#shopgrid .it{cursor:url(../assets/ui/cursorget.png) 12 6,pointer!important}
#view.sit{cursor:url(../assets/ui/cursorsitdown.png) 12 12,pointer!important}
#view.lean{cursor:url(../assets/ui/cursorleanagainst.png) 12 12,pointer!important}
#view.dontmove{cursor:url(../assets/ui/cursordontmove.png) 15 15,not-allowed!important}
#view.gm{cursor:url(../assets/ui/cursorid.png) 2 2,crosshair!important}
#barfill{position:absolute;left:0;right:0;bottom:0;height:var(--barh);background:linear-gradient(#1a1712,#050403 30%,#0b0907);border-top:1px solid #3a3022;pointer-events:none}
/* ---------- login / character select over the 3D S6 scenes, loading screen ---------- */
.ptitle{text-align:center;color:#e8c070;font:bold 13px Georgia,serif;letter-spacing:1px;padding:6px 0 10px;border-bottom:1px solid #4a3418;margin-bottom:12px;text-shadow:0 0 6px #000}
body.menu3d #screens{background:radial-gradient(ellipse at center,transparent 55%,#000a 100%)}
body.menu3d #screens .panel{background:linear-gradient(#140d07ee,#0a0604f2);border:1px solid #8a6024;border-radius:3px;box-shadow:0 0 0 1px #000,0 0 30px #000c,inset 0 0 20px #0008}
.mulogo{background:url(../assets/ui/mu_logo_glow.png) center/contain no-repeat;position:relative}
.mulogo::after{content:'';position:absolute;inset:6% 4%;background:url(../assets/ui/mu_logo.png) center/contain no-repeat}
#loginlogo{display:none;position:absolute;left:50%;top:5vh;transform:translateX(-50%);width:min(460px,60vw);height:min(230px,30vw);pointer-events:none;filter:drop-shadow(0 0 20px #f80)}
#screens[data-sc=sc-login] #loginlogo{display:block}
body.menu3d #sc-login{width:min(320px,90vw);align-self:end;margin-bottom:12vh;padding:14px 18px}
body.menu3d #sc-login label{font-size:11px}
/* character select: list as a slim bar at the bottom, characters stand on the platforms */
body.menu3d #sc-chars{align-self:end;width:min(760px,96vw);margin-bottom:2vh;padding:10px 14px}
body.menu3d #sc-chars .ptitle{display:none}
body.menu3d #charlist{grid-template-columns:repeat(auto-fit,minmax(130px,1fr))}
body.menu3d .ch{padding:6px 8px;gap:6px}body.menu3d .ch b{font-size:13px}
body.menu3d #screens.pv .panel{margin-right:0}
body.menu3d #sc-chars .row{margin-top:8px}
#mchars{position:fixed;inset:0;pointer-events:none;z-index:11}
#mchars[hidden]{display:none}
.mchar{position:absolute;transform:translate(-50%,-100%);pointer-events:auto;text-align:center;background:linear-gradient(#2a1a0cdd,#0d0804ee);border:1px solid #7a5420;padding:4px 10px;min-width:96px;box-shadow:0 0 8px #000}
.mchar b{display:block;color:#fff;font-size:13px}.mchar span{display:block;color:#c9b48a;font-size:10px}.mchar .lv{color:#f0c060}
.mchar.sel{border-color:#ffd060;box-shadow:0 0 12px #f90a}.mchar.sel b{color:#ffd060}
/* loading screen */
#sc-load.big{width:100vw;height:var(--vh,100vh);max-width:none;border:0!important;border-radius:0;padding:0;background:#000!important;position:relative;isolation:isolate;overflow:hidden;display:flex;flex-direction:column;align-items:center;justify-content:flex-end;box-shadow:none!important}
#sc-load .mulogo{width:min(380px,50vw);height:min(190px,25vw);margin-bottom:auto;margin-top:6vh;filter:drop-shadow(0 0 18px #f80)}
#sc-load:not(.big) .mulogo{width:220px;height:110px;margin:0 auto 10px}
#loadmap{color:#ffd890;font:bold 20px Georgia,serif;text-shadow:0 0 8px #000,0 0 4px #000;margin-bottom:8px}
#sc-load.big #loadbar{width:min(520px,80vw);height:14px;background:#000a url(../assets/ui/progress_back.png) center/100% 100%;border:1px solid #8a6024;border-radius:0}
#sc-load.big #loadtxt{text-shadow:0 0 4px #000;color:#ddd}
#loadtip{color:#e8d9b5;font-size:13px;margin:10px 0 7vh;text-shadow:0 0 4px #000,0 0 4px #000;max-width:80vw;text-align:center}
#sc-load:not(.big) #loadtip{display:none}
body.menu3d #view{filter:brightness(1.3) saturate(1.1)}
body.menu3d #sc-chars{width:min(820px,96vw);padding:8px 10px}
body.menu3d #charlist{display:none}
body.menu3d #sc-chars .row{display:flex;gap:6px;margin-top:0}body.menu3d #sc-chars .row+.row{margin-top:6px}
#btn-del{display:none}body.menu3d #btn-del{display:block}
body.menu3d #sc-chars .row button,body.menu3d #sc-chars .row a{padding:7px 10px;font-size:12px}
#loginlogo{width:min(380px,50vw);height:min(190px,25vw)}
.win .wt{cursor:url(../assets/ui/cursorget.png) 12 6,move!important;user-select:none}
/* ---------- backdrops of the "Tipo 99b" select-server pack ---------- */
body[data-bg=login] #screens{background:#000} /* only the 3D login scene, never the old 2D picture */
body[data-bg=select] #screens{background:#000}
body[data-bg=login] #screens::before,body[data-bg=select] #screens::before{content:'';position:absolute;inset:0;background:radial-gradient(ellipse at center,transparent 60%,#0008 100%);pointer-events:none}
body[data-bg] #view{filter:none}
#screens[data-sc=sc-chars],#screens[data-sc=sc-create]{z-index:10}
body[data-bg=select] #view{z-index:10;pointer-events:none}
body[data-bg=select] #screens{z-index:9}
#screens[data-sc=sc-chars] ~ #view{pointer-events:auto}
/* login box: centered, fixed size so switching Login / Create account does not jump */
#sc-login{width:min(330px,92vw)!important;height:auto;margin-top:20vh!important;box-sizing:border-box;padding:0!important;margin-bottom:0!important;align-self:center!important;
  background:linear-gradient(#0d0906f2,#050302f5)!important;border:1px solid #9a7030!important;border-radius:2px!important;
  box-shadow:0 0 0 1px #000,0 0 0 3px #3a2810,0 0 0 4px #000,0 10px 40px #000!important;display:flex;flex-direction:column;overflow:hidden}
#sc-login .ptitle{margin:0;padding:8px 0;background:linear-gradient(#3a2810,#160e06);border-bottom:1px solid #9a7030;color:#f0d080;font-size:13px}
#sc-login .tabs{display:flex;gap:0;margin:10px 16px 6px}
#sc-login .tabs button{flex:1;padding:6px;font-size:12px;border-radius:0;background:#140e08;border:1px solid #4a3418;color:#b9a47a}
#sc-login .tabs button.sel{background:linear-gradient(#6a4416,#3a2408);color:#fff;border-color:#9a7030}
#sc-login form{padding:0 16px;overflow:auto;flex:1}
#sc-login label{display:block;font-size:11px;color:#c9b48a;margin:6px 0 2px}
#sc-login input{width:100%;box-sizing:border-box;padding:6px 8px;font-size:12px;background:#000;border:1px solid #5a4020;color:#fff;border-radius:0}
#sc-login input:focus{border-color:#d0a050;outline:none;box-shadow:0 0 6px #c80}
#sc-login button.main{width:100%;margin-top:10px;padding:8px;border-radius:0;font-size:13px;letter-spacing:1px}
#sc-login .help{font-size:10px;margin:6px 0 0;color:#988}
#sc-login .msg{padding:0 16px 8px;min-height:14px;font-size:11px}
#screens[data-sc=sc-login] #loginlogo{display:block;top:2vh;width:min(320px,42vw);height:min(160px,21vw)}
body[data-bg=select] #sc-chars{align-self:end;width:min(820px,96vw);margin-bottom:2vh;padding:8px 10px}
body[data-bg=select] #sc-create{align-self:center}
#shop-gm{display:block;width:calc(100% - 16px);margin:6px 8px 8px;padding:7px;background:linear-gradient(#8a1a0a,#4a0804);border:1px solid #e05030;color:#fff;font-weight:bold;cursor:pointer;letter-spacing:.5px}
#shop-gm[hidden]{display:none}
#srvtype{color:#e0a0a0;font-size:10px}
#sc-login form{flex:none;padding-bottom:4px}
/* ---------- bar like the original client: crystal gems, numbers inside the bar, EXP in the top channel ---------- */
.orb.hp .fill{background-image:url(../assets/ui/gem_red.png)!important}.orb.mp .fill{background-image:url(../assets/ui/gem_blue.png)!important}
.orb.hp.poison .fill{background-image:url(../assets/ui/gem_green.png)!important}
#hptxt,#mptxt{top:36px!important;width:64px!important;font:bold 8px/10px Arial,sans-serif!important;color:#fff;text-shadow:0 0 2px #000,0 0 2px #000}
#hptxt{left:30px!important;text-align:right}#mptxt{left:546px!important;text-align:left}
#exp{left:214px!important;right:auto!important;width:198px;top:10px!important;height:4px!important;background:#0008!important;border:0!important;z-index:3}
#expfill{background:linear-gradient(#fff4a0,#e8c040 60%,#a07010)!important}
#exptxt{display:none}
#explv{position:absolute;left:413px;top:3px;width:18px;text-align:center;font:bold 8px/14px Arial,sans-serif;color:#ffe080;z-index:3;text-shadow:0 0 2px #000}
#lvbox{font:bold 8px/15px Arial,sans-serif!important;color:#e0d0b0!important;letter-spacing:1px}
/* ---------- guild ---------- */
#w-guild{left:50%;top:12%;transform:translateX(-50%);width:340px;max-height:72vh;overflow:auto}
#gu-body{padding:10px;display:flex;flex-direction:column;gap:8px}
.gunote{color:#a99;font-size:11px;margin:4px 0}.gubox{border:1px solid #3a2a14;background:#0006;padding:8px}
.gubox b{color:#f0c060}.gubox input,#gu-body input{flex:1;background:#0d0a06;border:1px solid #4a3418;color:#fff;padding:4px 6px}
.gulist{max-height:220px;overflow:auto;border:1px solid #3a2a14;background:#0006}
.gulist div{display:flex;gap:6px;align-items:center;padding:3px 6px;border-bottom:1px solid #1e150a}
.gulist .nm{flex:1;color:#fff}.gulist .away{color:#c9b48a;font-size:11px}.gulist .on{color:#5f5}.gulist .off{color:#555}
.gulist button,#gu-body .gmrow button{background:linear-gradient(#3a2a18,#1a120a);border:1px solid #5a3e1a;color:#e8d9b5;padding:3px 8px;cursor:pointer}
#gu-body .gmrow button.red{color:#ff9080}
.guhead{display:flex;gap:10px;align-items:center}.guhead b{color:#ffd060;font-size:15px}
.gumark{width:36px;height:36px;display:grid;place-items:center;background:linear-gradient(135deg,#8a2a10,#2a0a04);border:1px solid #d08040;color:#fff;font:bold 18px Georgia,serif}
#labels .lbl .gutag{color:#80d0ff;font-size:10px}
#chatlog .guildmsg,#chatlog .guildmsg b{color:#80d0ff}
/* ---------- compact Move window (fits small screens / phones) ---------- */
#w-move{width:min(440px,94vw)!important;max-height:min(520px,78vh)!important;display:flex;flex-direction:column;overflow:hidden!important}
#w-move[hidden]{display:none!important}
#movelist{display:grid;grid-template-columns:1fr 1fr;gap:3px;padding:6px;overflow:auto;flex:1;min-height:0}
#movelist .mv{padding:4px 7px!important;margin:0;font-size:11px;border-radius:0;align-items:center;min-height:0}
#movelist .mv b{font-size:11px;font-weight:bold;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#movelist .mv span{font-size:10px;white-space:nowrap;margin-left:4px}
#movelist .mv.cur{border-color:#c98a2a;background:#2a1c0e}
#w-move .hint{padding:4px 8px;font-size:10px;max-height:64px;overflow:auto;border-top:1px solid #3a2810}
#w-move .hint #nextev{display:block}#w-move #nextev div{display:flex;justify-content:space-between}
@media (max-width:420px){#movelist{grid-template-columns:1fr}}
/* guild window docked right, like the original client */
#w-guild{left:auto!important;right:0!important;top:0!important;bottom:var(--barh)!important;transform:none!important;width:300px!important;max-height:none!important;display:flex;flex-direction:column;
  background:#0a0806 url(../assets/ui/item_back02.jpg) center/100% 100% no-repeat!important;overflow:hidden}
#w-guild[hidden]{display:none!important}
#gu-body{flex:1;min-height:0;padding:10px 16px}
.guhdr{margin:2px 10px 10px;padding:4px;text-align:center;background:#000c;border:1px solid #5a4020;color:#ddd;font:12px Arial}
.gumembers{flex:1;min-height:120px;overflow:auto;padding:4px 6px}
.gumembers div{display:flex;align-items:center;gap:6px;padding:3px 2px;font-size:12px}
.gumembers .gx{color:#e8a030;width:14px;text-align:center}.gumembers .nm{flex:1;color:#ddd}.gumembers .nm.me{background:#2a3a8a;color:#fff;padding:0 3px}
.gumembers .off .nm{color:#888}.gumembers .lv{color:#e8c040;font-size:11px}
.gumembers .gk{width:20px;height:16px;background:linear-gradient(#5a4a30,#2a2010);border:1px solid #8a7040;color:#e8c040;font-size:10px;padding:0;cursor:pointer}
.gumembers span.gk{background:none;border:0}
.gunotice{display:flex;gap:4px;padding:6px;color:#c9b48a;font-size:11px;min-height:18px}.gunotice input{flex:1;background:#000;border:1px solid #4a3418;color:#fff;padding:3px}
.gunotice button{background:#2a1c0e;border:1px solid #6b4a1f;color:#e8d9b5;cursor:pointer}
.guemblem{display:flex;flex-direction:column;align-items:center;gap:2px;padding:10px 0;opacity:.9}
.guemblem span{width:64px;height:64px;display:grid;place-items:center;background:radial-gradient(#5a5a5a,#1a1a1a);border:2px solid #888;border-radius:50%;color:#ddd;font:bold 34px Georgia,serif;text-shadow:0 0 6px #000}
.guemblem b{color:#ddd;letter-spacing:3px;font:bold 15px Georgia,serif;text-transform:uppercase}.guemblem i{color:#999;font-size:10px;font-style:normal}
.gufoot{display:flex;align-items:center;gap:8px;padding:6px 4px;color:#998;font-size:10px}
.gufoot button{width:34px;height:30px;background:linear-gradient(#5a4a30,#2a2010);border:1px solid #c0a060;color:#f0c040;font-size:16px;cursor:pointer}
#labels .lbl .gutag{color:#fff;background:#3a7a20cc;padding:0 3px;font-size:10px}
.gmark{image-rendering:pixelated;border:1px solid #666;background:#0008;display:inline-block;flex:none}
.gmark.letter{display:inline-grid;place-items:center;color:#ddd;font-family:Georgia,serif;background:radial-gradient(#555,#1a1a1a);border-radius:50%}
.guname{display:flex;align-items:center;gap:10px;margin:4px 6px 10px}.guname label{color:#ddd;font:bold 11px Arial}.guname input{flex:1;background:#000;border:1px solid #8a7040;color:#fff;padding:5px 8px}
.gugrid{display:grid;grid-template-columns:repeat(8,22px);grid-template-rows:repeat(8,22px);gap:1px;background:#333;border:2px solid #000;width:max-content;margin:4px auto 10px;cursor:crosshair;user-select:none;touch-action:none}
.gugrid i{display:block;background:transparent;box-shadow:inset 0 0 0 1px #0003}
.gugrid i[style*="transparent"]{background:repeating-conic-gradient(#3a3a3a 0 25%,#2a2a2a 0 50%) 0 0/8px 8px!important}
.gucol{display:flex;gap:10px;align-items:center;margin:0 6px}.gucol span{width:34px;height:34px;border:1px solid #888;flex:none}.gucol p{color:#ccc;font-size:11px;margin:0}
.gupal{display:grid;grid-template-columns:repeat(8,1fr);gap:2px;margin:8px 6px}.gupal i{height:24px;border:1px solid #000;cursor:pointer}.gupal i.on{outline:2px solid #fff}
.gupal i.x{background:repeating-linear-gradient(45deg,#000 0 3px,#555 3px 5px)!important}
.gunav{display:flex;justify-content:center;gap:6px;margin:10px 0}.gunav button{width:80px;padding:4px;background:linear-gradient(#3a3a3a,#1a1a1a);border:1px solid #777;color:#ccc;cursor:pointer}
.guconfirm{display:flex;flex-direction:column;align-items:center;gap:6px;margin:20px 0}.guconfirm b{color:#ffd060;font:bold 16px Georgia,serif;letter-spacing:2px}
.guemblem .gmark{border:2px solid #888}
.gulist .gmark{margin-right:2px}
/* ---------- Storage next to the Inventory, like the original ---------- */
#w-vault{left:auto!important;right:300px!important;top:0!important;bottom:var(--barh)!important;width:300px!important;max-height:none!important;transform:none!important;
  background:#0a0806 url(../assets/ui/item_back02.jpg) center/100% 100% no-repeat!important;display:flex;flex-direction:column}
#w-vault[hidden]{display:none!important}
#w-vault .pad{flex:1;min-height:0;overflow:auto;padding:8px 20px!important;display:flex;flex-direction:column;align-items:center;gap:6px}
#vaultlist.vgrid{flex:none}
.vzrow{display:flex;align-items:center;gap:8px;width:256px}.vzrow label{color:#ccc;font-size:11px;width:72px}
.vzrow b{flex:1;background:#000;border:1px solid #5a4020;color:#ff4040;font:12px Arial;padding:3px 6px;text-align:right}
.vzrow.fee label{color:#ff5050}.vzrow.fee b{background:none;border:0;color:#ddd;text-align:left}
.vzbtns{display:flex;gap:6px;width:256px}.vzbtns input{flex:1;min-width:0;background:#000;border:1px solid #5a4020;color:#fff;padding:3px 6px}
.vzbtns button{width:36px;height:30px;background:linear-gradient(#5a4a30,#2a2010);border:1px solid #c0a060;color:#f0d080;font-size:15px;cursor:pointer}
#w-vault .hint{font-size:10px;color:#999;width:256px}
#zen{color:#ff4040}
#w-inv .zen{display:flex;align-items:center;gap:8px;color:#ccc}#w-inv .zen b{flex:1;background:#000;border:1px solid #5a4020;color:#ff4040!important;font:12px Arial;padding:3px 6px;text-align:right}

/* ================= window skin from "Interfaz Downgrade 99b" (newui): every box except the chat ================= */
.win:not(#w-menu){
  background-color:#1a1a1a!important;
  background-image:url(../assets/ui/newui/newui_item_back01.png),url(../assets/ui/newui/newui_item_back03.png),url(../assets/ui/newui/newui_item_back02-L.png),url(../assets/ui/newui/newui_item_back02-R.png),url(../assets/ui/newui/newui_msgbox_back.png)!important;
  background-position:top center,bottom center,left 0 top 64px,right 0 top 64px,center!important;
  background-size:100% 64px,100% 45px,21px 320px,21px 320px,100% 100%!important;
  background-repeat:no-repeat,no-repeat,repeat-y,repeat-y,no-repeat!important;
  border:0!important;border-radius:0!important;box-shadow:0 0 0 1px #000,4px 4px 18px #000c!important;padding-bottom:30px;box-sizing:border-box}
.win:not(#w-menu) > .wt{background:none!important;border:0!important;height:42px;line-height:30px;padding:6px 40px 0!important;text-align:center;color:#fff!important;
  font:bold 12px Arial,sans-serif!important;letter-spacing:.5px!important;text-shadow:0 0 3px #000}
.win:not(#w-menu) > .wt .x{position:absolute;right:14px;top:14px;width:22px;height:18px;background:url(../assets/ui/newui/newui_exit_00.png) 0 0/22px 36px no-repeat!important;border:0;color:transparent!important;font-size:0}
.win:not(#w-menu) > .wt .x:hover{background-position:0 -18px!important}
.win:not(#w-menu) > :not(.wt){margin-left:12px;margin-right:12px}
.win button:not(.gk):not(.x):not([data-c]):not(.gmtabs button){background:url(../assets/ui/newui/newui_btn_empty.png) 0 0/100% 300% no-repeat!important;border:0!important;color:#ddd!important;border-radius:0!important;min-height:22px;text-shadow:0 0 2px #000}
.win button:not(.gk):not(.x):not([data-c]):hover{background-position:0 50%!important;color:#fff!important}
.win input,.win select{background:#000!important;border:1px solid #555!important;color:#fff!important;border-radius:0!important}
/* Zen boxes like newui_item_money */
#w-inv .zen,.vzrow:not(.fee){background:url(../assets/ui/newui/newui_item_money.png) center/100% 100% no-repeat;height:26px;padding:0 6px 0 34px;box-sizing:border-box;align-items:center}
#w-inv .zen{font-size:0!important;margin:6px 16px}
#w-inv .zen b,.vzrow:not(.fee) b{background:none!important;border:0!important;color:#ff4040!important;font:bold 12px Arial!important}
.vzrow:not(.fee) label{display:none}
/* item grids: dark slots with fine lines (newui_item_table) */
#grid,.vgrid,#shopgrid{background-color:#0b0b0b!important;background-image:linear-gradient(#2c2c2c 1px,transparent 1px),linear-gradient(90deg,#2c2c2c 1px,transparent 1px)!important;background-size:32px 32px!important;outline:1px solid #555;box-shadow:0 0 0 2px #000}
#equip .slot{background-color:#0d0d0d!important;border:1px solid #444!important;background-image:var(--ico)!important;background-size:contain!important;background-repeat:no-repeat!important;background-position:center!important}
#w-inv #equip{width:256px!important;height:232px!important;margin:6px auto 8px!important;position:relative}
#equip .slot{box-sizing:border-box;box-shadow:inset 0 0 0 1px #000,0 0 0 1px #222}
/* ---------- shining items +7..+15 / excellent (inventory, vault, shop, equipment) ---------- */
/* shining +7..+15 like on the character: a chrome light sliding over the item (silver +7, gold +9, blue-white +11, strong white +13..15) */
.it.g7::after,.it.g9::after,.it.g11::after,.it.g13::after{content:'';position:absolute;inset:0;pointer-events:none;
  background:linear-gradient(115deg,transparent 30%,var(--sh) 42%,transparent 50%,transparent 62%,var(--sh2,transparent) 70%,transparent 78%) -150% 0/260% 100% no-repeat;
  -webkit-mask:var(--icon) center/contain no-repeat;mask:var(--icon) center/contain no-repeat;animation:gsheen var(--sd,3s) linear infinite;mix-blend-mode:screen}
.it.g7::after{--sh:#ffffff40;--sd:4s}
.it.g9::after{--sh:#ffffff70;--sh2:#ffffff30;--sd:3.4s}
.it.g11{filter:drop-shadow(0 0 2px #ffffff40)}.it.g11::after{--sh:#ffffff80;--sh2:#ffffff30;--sd:2.8s}
.it.g13{filter:drop-shadow(0 0 2px #ffffff50);animation:g13pulse 2.4s ease-in-out infinite}.it.g13::after{--sh:#ffffffa0;--sh2:#ffffff40;--sd:2.2s}
@keyframes g13pulse{50%{filter:brightness(1.08) drop-shadow(0 0 4px #ffffff70)}}
.it.gexc:not(.g9):not(.g11):not(.g13){filter:drop-shadow(0 0 2px #40ff6080)}
@keyframes gsheen{to{background-position:150% 0}}
/* Chaos Machine */
#w-chaos{left:auto!important;right:300px!important;top:0!important;bottom:var(--barh)!important;width:300px!important;transform:none!important;display:flex;flex-direction:column}
#w-chaos[hidden]{display:none!important}
#w-chaos .pad{padding:8px 20px!important;display:flex;flex-direction:column;align-items:center;gap:8px}
#chaosgrid{position:relative;width:256px;height:128px;background-color:#0b0b0b;background-image:linear-gradient(#2c2c2c 1px,transparent 1px),linear-gradient(90deg,#2c2c2c 1px,transparent 1px);background-size:32px 32px;outline:1px solid #555;box-shadow:0 0 0 2px #000,0 0 20px #20a0ff40}
#chaosinfo{width:256px;font-size:11px;color:#ccc;line-height:1.5}#chaosinfo b{color:#ffd060;font-size:12px}#chaosinfo .cr{color:#ddd;margin-top:4px}#chaosinfo i{color:#ff6040;font-style:normal;font-weight:bold}
#chaos-go{width:120px;height:28px;font-weight:bold}#chaos-go:disabled{opacity:.45}
#w-chaos .hint{width:256px;font-size:10px;color:#999}
/* chat stays behind every window */
.win{z-index:8}#chat,#chatshow{z-index:4!important}
/* ---------- animated login / select backdrop: rocking ships, moving sea, glowing sun, mist ---------- */
#bgscene{position:absolute;inset:0;overflow:hidden;pointer-events:none;display:none}
body[data-bg=login] #bgscene,body[data-bg=select] #bgscene{display:block}
body[data-bg=login] #screens,body[data-bg=select] #screens{background:#000!important}
#bgscene .bgimg{position:absolute;inset:-4%;background:center/cover no-repeat;animation:rock 9s ease-in-out infinite;transform-origin:50% 70%}
body[data-bg=login] #bgscene{display:none}
body[data-bg=select] #bgscene{display:none}
@keyframes rock{0%,100%{transform:translateY(0) rotate(0) scale(1.02)}25%{transform:translateY(-7px) rotate(.35deg) scale(1.025)}50%{transform:translateY(4px) rotate(0) scale(1.02)}75%{transform:translateY(-5px) rotate(-.35deg) scale(1.025)}}
@keyframes breathe{0%,100%{transform:scale(1.02)}50%{transform:scale(1.05) translateY(-4px)}}
.bgwater{position:absolute;left:-10%;right:-10%;top:47%;bottom:0;opacity:.28;mix-blend-mode:screen;
  background:repeating-linear-gradient(176deg,transparent 0 14px,#9cd8ff55 15px,transparent 17px 30px),repeating-linear-gradient(4deg,transparent 0 22px,#ffffff33 23px,transparent 25px 44px);
  -webkit-mask:linear-gradient(transparent,#000 15%);mask:linear-gradient(transparent,#000 15%);animation:waves 7s linear infinite}
.bgwater.w2{opacity:.18;animation:waves2 11s linear infinite;background-size:180% 100%}
@keyframes waves{from{background-position:0 0,0 0}to{background-position:-300px 30px,240px -20px}}
@keyframes waves2{from{background-position:0 0,0 0}to{background-position:400px 20px,-200px 40px}}
body[data-bg=select] .bgwater{display:none}
.bgsun{position:absolute;left:38%;top:2%;width:30%;height:42%;background:radial-gradient(ellipse,#fff4c0aa,#ffb04040 40%,transparent 70%);mix-blend-mode:screen;animation:sun 5s ease-in-out infinite}
body[data-bg=select] .bgsun{left:30%;top:0;width:45%;background:radial-gradient(ellipse,#fffbe066,transparent 65%)}
@keyframes sun{0%,100%{opacity:.6;transform:scale(1)}50%{opacity:1;transform:scale(1.08)}}
.bgmist{position:absolute;inset:0;background:radial-gradient(ellipse 60% 20% at 20% 45%,#ffffff18,transparent),radial-gradient(ellipse 50% 15% at 80% 40%,#ffffff14,transparent);animation:mist 20s linear infinite;background-size:200% 100%}
@keyframes mist{from{background-position:0 0}to{background-position:-200% 0}}
#musicbtn{position:absolute;right:14px;top:12px;z-index:12;width:34px;height:34px;border-radius:50%;background:#000a;border:1px solid #c09040;color:#ffd890;font-size:17px;cursor:pointer}
#musicbtn.off{opacity:.45;text-decoration:line-through}
body:not([data-bg=login]):not([data-bg=select]) #musicbtn{display:none}
#screens .panel,#loginlogo,#mchars{position:relative;z-index:3}
#loginlogo{position:absolute}#mchars{position:fixed}
.bgwater{opacity:.13;top:49%}.bgwater.w2{opacity:.09}
.gmopts{font-size:11px;color:#cba}.gmopts label{display:flex;align-items:center;gap:3px}.gmopts select{padding:2px!important}
#gm-ilist.gmlist{max-height:260px}
.gmgrid{display:grid;grid-template-columns:1fr 1fr;gap:6px}.gmgrid label{display:flex;flex-direction:column;gap:2px;color:#cba;font-size:11px}.gmgrid input,.gmgrid select{width:100%;box-sizing:border-box}
#w-gm{width:480px}.gmtabs{flex-wrap:wrap}
#gm-plist div button{padding:1px 5px;font-size:10px}
/* monster name + life bar */
#labels .lbl.mon{display:flex;flex-direction:column;align-items:center;gap:1px;font-size:10px;color:#ffe0c0;pointer-events:auto}
#labels .lbl.mon .mhp{width:46px;height:4px;background:#300;border:1px solid #000;box-shadow:0 0 2px #000}
#labels .lbl.mon .mhp i{display:block;height:100%;width:100%;background:linear-gradient(#ff5040,#a01010)}
#labels .lbl.mon.boss .mn{color:#ff9050;font-weight:bold}#labels .lbl.mon.boss .mhp{width:80px}
#labels .lbl.mon.gold .mn{color:#ffd040}
#labels .lbl.mon.tgt .mn{color:#fff;font-weight:bold}
#labels .lbl.mon.hn .mn{display:none}#labels .lbl.mon.hh .mhp{display:none}

#gm-give{border-top:1px solid #6a5a3a;margin-top:6px;padding-top:4px}.gggrid{display:grid;grid-template-columns:1fr 1fr;gap:2px 8px;font-size:11px;color:#8f8;margin:4px 0}.gggrid label{display:flex;gap:4px;align-items:center}#gg-list div.sel{background:#5a3e1a}#gg-sel img{width:28px;height:28px;vertical-align:middle;margin-right:6px}
/* inventory: only as tall as its content (no empty space under the hint) */
#w-inv{bottom:auto!important;height:auto!important;max-height:calc(var(--vh,100vh) - var(--barh));padding-bottom:14px}
#w-inv>*{flex-shrink:0}   /* short screens (844 x 390): the parts keep their size and the window scrolls, instead of the grid being squeezed over the equipment slots */
.ggcls{font-size:11px;color:#cde;display:flex;flex-wrap:wrap;gap:4px 10px;align-items:center;margin:4px 0}.ggcls label{display:flex;gap:3px;align-items:center}
#w-gm .gmlist.small{max-height:220px}
/* original 3D login scene (World78): no painted backdrop */
body.login3d[data-bg=login] #bgscene{display:none}
body.login3d[data-bg=login] #screens{background:radial-gradient(ellipse at center,transparent 60%,#0006 100%)!important}
/* original 3D character select scene (World79) */
body.select3d[data-bg=select] #bgscene{display:none}
body.select3d[data-bg=select] #screens{background:radial-gradient(ellipse at center,transparent 60%,#0006 100%)!important}
body.select3d[data-bg=select] #view{z-index:0!important}
/* Season 6 skill icons are 20x28 */
.si{width:32px!important;height:45px!important}
#skillslot{width:21.5px!important;height:30px!important}
.skr .ski{display:inline-block;width:20px;height:28px;vertical-align:middle;margin-right:6px;float:left;border:1px solid #5a4020}
/* bottom bar buttons: hit areas exactly over the three painted icons, hover + pressed state */
#mb-char,#mb-inv,#mb-menu{top:17px!important;width:26px!important;height:27px!important;border-radius:3px;transition:box-shadow .1s,background .1s}
#mb-char{left:348px!important}#mb-inv{left:409px!important}#mb-menu{left:378px!important}
#mb-char:hover,#mb-inv:hover,#mb-menu:hover{background:#ffe0a022;box-shadow:inset 0 0 6px #ffd27a}
#mb-char.on,#mb-inv.on,#mb-menu.on{background:#00000055;box-shadow:inset 0 0 8px #ffb030,0 0 4px #ffb030}
#mb-char:active,#mb-inv:active,#mb-menu:active{transform:translateY(1px)}
/* Character / Storage / Shop: only as tall as their content */
#w-char{bottom:auto!important;height:auto!important;max-height:calc(var(--vh,100vh) - var(--barh));padding-bottom:12px}
#w-vault{bottom:auto!important;height:auto!important;max-height:calc(var(--vh,100vh) - var(--barh))}
#w-vault .pad{flex:none!important;padding-bottom:14px!important}
#w-shop{bottom:auto!important;height:auto!important;max-height:calc(var(--vh,100vh) - var(--barh));padding-bottom:10px}
/* compact Storage: 8 x 15 cells of 26px */
#w-vault{width:250px!important}
#vaultlist.vgrid{width:208px!important;height:390px!important;background-size:26px 26px!important}
#w-vault .vzrow,#w-vault .vzbtns,#w-vault .hint{width:208px!important}
#w-vault .pad{padding:6px 12px 12px!important;gap:5px!important}
#w-vault .vzrow label{width:60px}

/* GM: loading screen tab */
.glimgs{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0;max-height:190px;overflow:auto}
.glimg{position:relative;width:112px;height:63px;background:#000 center/cover no-repeat;border:1px solid #6a5a3a;cursor:pointer;flex:none}
.glimg:hover{border-color:#ffd27a}
.glimg button{position:absolute;right:2px;top:2px;width:18px;height:18px;padding:0;line-height:16px;background:#400a;border:1px solid #a33;color:#fff;cursor:pointer;font-size:11px}
#gl-maplist .glimg{width:56px;height:32px}
#gl-maplist .gmli{display:flex;align-items:center;gap:8px;padding:2px 4px}
#gl-tipstxt{width:100%;box-sizing:border-box;background:#000;color:#e8d9b5;border:1px solid #5a4020;font:12px Arial;resize:vertical}
.gmbtn{display:inline-block;background:#1c140c;border:1px solid #5a3e1a;color:#e8d9b5;padding:3px 8px;cursor:pointer;border-radius:2px}
.gmbtn:hover{border-color:#c0a060}
#loadprev{position:fixed;inset:0;z-index:100;cursor:pointer}
#loadprev .sc{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:flex-end}
#loadprev .mulogo{width:min(380px,50vw);height:min(190px,25vw);margin:6vh 0 auto;filter:drop-shadow(0 0 18px #f80)}
#loadprev .lm{color:#ffd890;font:bold 20px Georgia,serif;text-shadow:0 0 8px #000;margin-bottom:8px}
#loadprev .lb{width:min(520px,80vw);height:14px;background:#000a url(../assets/ui/progress_back.png) center/100% 100%;border:1px solid #8a6024}
#loadprev .lb i{display:block;height:100%;width:60%;background:linear-gradient(#ffb040,#a05010)}
#loadprev .lt{color:#e8d9b5;font-size:13px;margin:10px 0 7vh;text-shadow:0 0 4px #000;max-width:80vw;text-align:center}
.ggset{display:flex;gap:4px;margin-top:4px}.ggset span{width:40px;height:40px;background:#0008;border:1px solid #5a4020;display:flex;align-items:center;justify-content:center}.ggset img{max-width:38px;max-height:38px}
#gg-clsf{max-width:130px}
/* every docked window is only as tall as its content (scrolls if it ever gets taller than the screen) */
#w-guild,#w-quest,#w-skill,#w-chaos{bottom:auto!important;height:auto!important;max-height:calc(var(--vh,100vh) - var(--barh))!important;overflow:auto;padding-bottom:12px}
#w-guild #gu-body{flex:none!important}
/* admin / GM announcement: centred like the event banners, smaller letters, can be long (wraps) */
#banner.notice{font:bold 14px Arial,sans-serif;color:#ffe9a8;white-space:pre-line;max-width:min(760px,70vw);text-align:center;padding:8px 40px;letter-spacing:.2px}
/* ---- other players & party */
#labels .lbl.rp{color:#e8e8ff;text-align:center;line-height:1.35}
#labels .lbl.rp .pmate{color:#7fff7f;font-weight:bold}
#labels .lbl .php{width:54px;height:4px;margin:2px auto 0;background:#300;border:1px solid #000}#labels .lbl .php i{display:block;height:100%;background:#e22}
#partyhud{position:absolute;left:8px;top:34px;width:172px;pointer-events:auto;font:11px Arial,sans-serif;color:#ddd;z-index:5}
#partyhud[hidden]{display:none}
#partyhud .pth{display:flex;align-items:center;gap:6px;padding:2px 4px;background:#000a;border:1px solid #5a4020;color:#f0c060;font-weight:bold}
#partyhud .pth span{color:#bbb;font-weight:normal;flex:1}
#partyhud .pth button,#partyhud .ptk{background:#2a1a0c;border:1px solid #6a4a20;color:#e8d9b5;font-size:10px;padding:0 5px;cursor:pointer}
#partyhud .ptm{position:relative;margin-top:2px;padding:3px 5px 4px;background:#000a;border:1px solid #3a2a14}
#partyhud .ptm.me{border-color:#6a5a2a}#partyhud .ptm.away{opacity:.55}
#partyhud .ptn{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}#partyhud .ptn b{color:#ffd040}#partyhud .ptn span{color:#aaa}#partyhud .ptn i{color:#9cf;font-style:normal}
#partyhud .pbar{height:5px;margin-top:2px;background:#111;border:1px solid #000}#partyhud .pbar i{display:block;height:100%}
#partyhud .pbar.hp i{background:linear-gradient(#f44,#a00)}#partyhud .pbar.mp{height:3px}#partyhud .pbar.mp i{background:linear-gradient(#58f,#14a)}
#partyhud .ptk{position:absolute;right:3px;top:2px}
#pinvite{position:absolute;left:50%;top:30%;transform:translateX(-50%);pointer-events:auto;background:#0d0a06ee;border:1px solid #8a6024;padding:12px 18px;color:#e8d9b5;font:13px Arial,sans-serif;text-align:center;z-index:30;box-shadow:0 0 18px #000}
#pinvite[hidden]{display:none}#pinvite b{color:#ffd060}
#pinvite .pib{margin-top:10px;display:flex;gap:10px;justify-content:center}
#pinvite button,#pmenu button{background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6a4a20;color:#e8d9b5;padding:4px 12px;cursor:pointer}
#pinvite button:hover,#pmenu button:hover{border-color:#d0a050;color:#fff}
#pmenu{position:fixed;pointer-events:auto;background:#0d0a06f0;border:1px solid #8a6024;padding:6px;display:flex;flex-direction:column;gap:4px;min-width:150px;z-index:40;font:12px Arial,sans-serif}
#pmenu[hidden]{display:none}#pmenu .pmh{color:#ffd060;font-weight:bold;padding:0 2px 3px}#pmenu .pmh span{color:#aaa;font-weight:normal;font-size:11px}
#chatlog .partymsg{color:#8fd8ff}
/* captcha + account */
.capt{display:flex;gap:6px;align-items:center;margin:8px 0 4px;flex-wrap:wrap}
.capt img{width:170px;height:56px;border:1px solid #6a4a20;border-radius:2px;image-rendering:auto;background:#000}
.capt .cref{width:30px;height:30px;padding:0;font-size:16px;cursor:pointer}
.capt input{flex:1;min-width:120px;text-transform:uppercase;letter-spacing:3px}
.capt[hidden]{display:none}
#sc-login .help a{color:#e0b060}
.optacc{border-top:1px solid #4a3418;border-bottom:1px solid #4a3418;padding:6px 0;margin:6px 0}
.optacc b{color:#f0c060;font-size:12px}
#o-accf{display:flex;flex-direction:column;gap:4px;margin-top:6px}
#o-accf[hidden]{display:none}#o-accf input[hidden]{display:none}
#o-accf input{background:#0d0a06;border:1px solid #4a3418;color:#fff;padding:4px 6px}
#o-accf .omsg{font-size:11px;color:#f88}#o-accf .omsg.ok{color:#8f8}
#labels .lbl .gmtag.gm{color:#ffb040}
/* GM window: bigger, resizable, nothing cut */
#w-gm{width:min(620px,calc(100vw - 340px))!important;max-height:calc(var(--vh,100vh) - var(--barh) - 50px)!important;resize:both;overflow:hidden;min-width:420px;min-height:300px}
#w-gm .gmp{overflow:auto;flex:1;min-height:0}
#w-gm .gmrow{flex-wrap:wrap}
#w-gm .gmlist{max-height:none!important;min-height:120px;flex:1 1 auto}
#w-gm .gmlist.small{max-height:220px!important;min-height:0}
#gn-list .gmli{display:flex;align-items:center;gap:4px;padding:3px 4px;border-bottom:1px solid #2a1e10}
#gn-list .gmli button{padding:1px 7px}#gn-list .gmli button.on{border-color:#4f4;color:#8f8}
#gn-list .dim{color:#998;font-size:11px}
/* server closing / disconnected */
#srvdown{position:fixed;inset:0;z-index:200;display:grid;place-items:center;background:#0008;pointer-events:auto}
#srvdown[hidden]{display:none}
#srvdown.off{background:#000c}
#srvdown .sdbox{min-width:360px;padding:22px 34px;text-align:center;background:#0d0a06f2;border:1px solid #8a6024;box-shadow:0 0 30px #000;color:#e8d9b5;font:14px Arial,sans-serif}
#srvdown .sdt{color:#ff6040;font:bold 20px Georgia,serif;letter-spacing:1px}
#srvdown .sdn{color:#ffd060;font:bold 64px Georgia,serif;margin:8px 0;min-height:10px}
#srvdown .sdm{color:#bba;font-size:12px}
#srvdown button{margin-top:14px;background:linear-gradient(#c98a2a,#7a4d12);border:0;color:#fff;padding:9px 22px;font-weight:bold;cursor:pointer;border-radius:3px}

#w-bug{left:50%;top:18%;transform:translateX(-50%);width:380px}
#w-bug textarea{width:100%;box-sizing:border-box;background:#000;border:1px solid #5a4a2c;color:#fff;font:13px Tahoma,sans-serif;padding:6px;resize:vertical;margin:6px 0}
.bugtxt{margin:2px 0;color:#cba;font-size:12px;line-height:1.4}.bugtxt.dim{color:#887;margin-top:8px}
a.contact{color:#e8c070}.logincontact{text-align:center;color:#887;font-size:11px;margin-top:10px}

body.select3d #sc-create{position:absolute;left:4vw;top:50%;transform:translateY(-50%);margin:0;width:min(400px,92vw)}

#w-helper{left:50%;top:16%;transform:translateX(-50%);width:330px}
.helperpad label{display:flex;justify-content:space-between;align-items:center;margin:5px 0;color:#cba;font-size:12px}
.helperpad select{background:#000;border:1px solid #5a4a2c;color:#fff;padding:3px 5px;font:12px Tahoma,sans-serif;min-width:150px}
.helperpad .hpk{color:#cba;font-size:12px;margin:8px 0;display:flex;flex-wrap:wrap;gap:4px 10px}.helperpad .hpk label{display:inline-flex;gap:3px;margin:0}
#helperon{position:absolute;top:44px;left:50%;transform:translateX(-50%);padding:3px 14px;background:#0a3a12cc;border:1px solid #3c9a50;color:#9f9;font:bold 12px Tahoma,sans-serif;letter-spacing:1px;pointer-events:none;z-index:5}
#helperon small{color:#8c8;font-weight:normal;letter-spacing:0}

/* ================= phones / tablets (body.mobile) ================= */
body.mobile{touch-action:none;-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent}
body.mobile canvas{touch-action:none}
#mob{position:absolute;inset:0;pointer-events:none;z-index:7}
#mob>*{pointer-events:auto}
#joy{position:absolute;left:calc(18px + env(safe-area-inset-left));bottom:calc(var(--barh) * var(--barz) + 18px);width:132px;height:132px;border-radius:50%;background:radial-gradient(circle,#ffffff14 0,#ffffff08 60%,#0000 61%),radial-gradient(circle,#0006 0,#0003 70%);border:2px solid #ffffff30;touch-action:none}
#joyk{position:absolute;left:41px;top:41px;width:50px;height:50px;border-radius:50%;background:radial-gradient(circle at 40% 35%,#fff9,#bbb6 40%,#5556);border:2px solid #fff6;box-shadow:0 0 8px #000a}
/* right thumb: big attack button, the skills on two rings around it (tap = use, hold = keep using) */
#mpad{position:absolute;right:calc(14px + env(safe-area-inset-right));bottom:calc(var(--barh) * var(--barz) + 12px);width:236px;height:236px;pointer-events:none;transform:scale(var(--mz,1));transform-origin:100% 100%}
#mpad>*{pointer-events:auto;position:absolute;touch-action:none}
#m-atk{right:0;bottom:0;width:92px;height:92px;border-radius:50%;border:3px solid #d9a441;color:#fff;font-size:38px;line-height:1;background:radial-gradient(circle at 40% 35%,#c33,#501010);box-shadow:0 0 12px #000,inset 0 0 16px #000a}
#m-tgt{width:40px;height:40px;border-radius:50%;border:2px solid #8a7040;background:#140e08dd;font-size:19px;padding:0;box-shadow:0 0 6px #000}
#mskills{inset:0;pointer-events:none}
#mskills .ms{position:absolute;width:46px;height:60px;border-radius:9px;display:grid;place-items:center;overflow:hidden;border:2px solid #7a5a28;background:#000 center/cover no-repeat;box-shadow:0 0 6px #000;pointer-events:auto;touch-action:none}
#mskills .ms.sel{border-color:#ffd060;box-shadow:0 0 9px #ffb030}
#mskills .ms i{display:block;width:38px;height:53px;border-radius:5px}
#mskills .ms.cd{filter:brightness(.45)}
#mpad button:active,#mskills .ms:active{filter:brightness(1.6)}
#mmenu{position:absolute;right:calc(8px + env(safe-area-inset-right));top:calc(6px + env(safe-area-inset-top));transform:scale(var(--mz,1));transform-origin:100% 0;display:flex;flex-direction:column;align-items:flex-end;gap:6px}
#m-more{width:46px;height:42px;padding:0;background:#0c0906e0;border:1px solid #8a6a34;border-radius:8px;color:#ffd27a;box-shadow:0 0 6px #000}
#m-more b{font-size:22px;line-height:1}
#mmenu.open #m-more{background:#3a2610;border-color:#ffd060}
#mmlist{display:none;grid-template-columns:repeat(2,74px);gap:5px;padding:6px;background:#0a0704ee;border:1px solid #6b5530;border-radius:8px;box-shadow:0 6px 20px #000}
#mmenu.open #mmlist{display:grid}
#mmlist button{height:46px;padding:0;background:#16100a;border:1px solid #5a4424;border-radius:6px;color:#e8dcc0;font:10px Tahoma,sans-serif;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:2px}
#mmlist button b{font-size:18px;line-height:1}
#m-chat{position:absolute;left:calc(14px + env(safe-area-inset-left));bottom:calc(var(--barh) * var(--barz) + 12px + 150px * var(--mz,1));width:42px;height:42px;border-radius:50%;background:#0c0906cc;border:1px solid #6b5530;font-size:19px;padding:0}
body.mobile #joy{transform:scale(var(--mz,1));transform-origin:0 100%;left:calc(14px + env(safe-area-inset-left));bottom:calc(var(--barh) * var(--barz) + 12px)}
body.mobile #info{right:calc((62px * var(--mz,1)) / var(--uiz,1))}
body.mobile .hot{cursor:pointer}
#rotate{position:fixed;inset:0;z-index:9999;background:#000e;display:flex;align-items:center;justify-content:center;color:#ffd27a;font:bold 22px Georgia,serif;text-align:center;line-height:1.6}
#rotate small{color:#aa9;font:13px Tahoma,sans-serif}
body.mobile #bar,body.mobile #barfill{zoom:var(--barz)}
body.mobile #hud .win,body.mobile #w-menu,body.mobile #mu-dlg .box{zoom:var(--uiz)}
body.mobile #chat{width:min(320px,40vw);bottom:calc(var(--barh) * var(--barz) + 160px);font-size:11px;zoom:var(--uiz)}
body.mobile #chat.hide{display:none}
body.mobile #skills{display:none!important}
body.mobile #log{display:none}
body.mobile #info{zoom:var(--uiz)}
body.mobile #charinfo{zoom:var(--uiz)}
body.mobile #screens .panel{zoom:.8}
body.mobile .mchar{zoom:normal;transform:translate(-50%,-100%) scale(.7);transform-origin:50% 100%} /* zoom also scaled left/top: the names floated away from the heroes */
body.mobile #w-gm{zoom:calc(var(--uiz) * .9)}
body.mobile #w-inv,body.mobile #w-char,body.mobile #w-quest,body.mobile #w-skill,body.mobile #w-shop,body.mobile #w-vault{bottom:auto;height:650px;max-height:none}
body.mobile #w-inv>*{flex-shrink:0}

#w-cmd{left:50%;top:12%;transform:translateX(-50%);width:230px}
.cmdpad{display:flex;flex-direction:column;align-items:center;gap:6px}
.cmdpad button{width:170px;padding:6px 0;background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6a4a20;color:#e8d9b5;font:12px Tahoma,sans-serif;cursor:pointer}
.cmdpad button:hover{border-color:#d0a050;color:#fff}
.cmdtarget input{width:180px;text-align:center;padding:5px;background:#000;border:1px solid #6a4a20;color:#ffd060;font:bold 13px Tahoma,sans-serif}
#sreq{position:absolute;left:50%;top:24%;transform:translateX(-50%);pointer-events:auto;background:#0d0a06ee;border:1px solid #8a6024;padding:12px 18px;color:#e8d9b5;font:13px Arial,sans-serif;z-index:30;text-align:center}
#sreq[hidden]{display:none}#sreq b{color:#ffd060}#sreq .pib{margin-top:10px;display:flex;gap:10px;justify-content:center}
#sreq button{background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6a4a20;color:#e8d9b5;padding:4px 12px;cursor:pointer}
#w-trade{left:10px;top:36px;width:300px;background:#0b0806f2;padding-bottom:8px}
#w-trade .tr-box{margin:8px 10px 0;padding:6px 7px 7px;border:1px solid #4a3418;border-radius:3px;background:linear-gradient(#1a120ad0,#0d0906d0);transition:border-color .2s,box-shadow .2s}
#w-trade .tr-box.ok{border-color:#4caf50;box-shadow:0 0 8px #4caf5088}
#w-trade .tr-who{display:flex;gap:8px;align-items:center;font-size:12px;color:#c9a96a;margin-bottom:4px}#w-trade .tr-who span::before{content:'◆ ';color:#e0a030;font-size:9px}
#w-trade .tr-who b{flex:1;background:#000a;border:1px solid #3a2a14;padding:2px 6px;color:#ffd060;min-height:16px}
#w-trade .tr-meta{display:flex;gap:10px;font-size:11px;color:#a89070;margin-bottom:5px}#w-trade .tr-meta b{color:#e8d8b0;margin-left:4px}
#w-trade .tr-grid{position:relative;width:256px;height:128px;margin:0 auto;background-color:#000;background-image:linear-gradient(#ffffff10 1px,transparent 1px),linear-gradient(90deg,#ffffff10 1px,transparent 1px);background-size:32px 32px;border:1px solid #5a3e1a;box-shadow:inset 0 0 12px #000}
#w-trade .tr-grid.mine{outline:1px dashed transparent}#w-trade .tr-grid .tr-hint{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;text-align:center;font-size:11px;color:#7a6a50;pointer-events:none;padding:8px}
#w-trade .tr-grid .tr-hint[hidden]{display:none}
#w-trade .tr-zen{display:flex;align-items:center;gap:6px;margin-top:6px;font-size:13px;color:#ffd060}#w-trade .tr-zen b{background:#000a;border:1px solid #3a2a14;padding:2px 8px;min-width:110px;text-align:right}
#w-trade .tr-zen input{width:130px;text-align:right;background:#000a;border:1px solid #5a3e1a;color:#ffd060;padding:3px 6px;font-size:13px}
#w-trade .zc{display:inline-block;width:14px;height:14px;border-radius:50%;background:radial-gradient(circle at 35% 35%,#fff6b0,#e0a020 55%,#7a4a08);box-shadow:0 0 3px #000}
#w-trade .tok{color:#6f6;font-weight:bold;font-size:12px}
#w-trade .tr-warn{margin:8px 10px 0;color:#ff5a3a;font-size:11.5px}#w-trade .tr-warn::before{content:'⚠ '}
#w-trade .tr-btns{display:flex;gap:8px;justify-content:center;margin:10px 10px 0}#w-trade .tr-btns button{min-width:90px;padding:6px 14px}
.tradepad{display:flex;flex-wrap:wrap;gap:10px}.tside{flex:1;min-width:200px}.tside h4{margin:0 0 4px;color:#f0c060;font-size:12px}.tside h4 small{color:#887;font-weight:normal;font-size:10px}
.tlist{min-height:120px;max-height:220px;overflow:auto;background:#000a;border:1px solid #3a2810;padding:3px}
.tlist div{display:flex;justify-content:space-between;gap:6px;padding:2px 4px;font-size:12px;color:#ddd;border-bottom:1px solid #1d150b;cursor:pointer}
.tlist div:hover{background:#1a130b}.tlist .exc{color:#7f7}.tlist .lv{color:#9cf}
.tzen{margin-top:4px;font-size:12px;color:#cba}.tzen input{width:110px;background:#000;border:1px solid #5a4a2c;color:#fd6;padding:2px 4px}
.tok{color:#7f7;font-weight:bold}.tradepad .gmrow{width:100%;justify-content:center}
#w-friends{left:50%;top:14%;transform:translateX(-50%);width:300px}
#fr-list div{display:flex;align-items:center;gap:6px;padding:4px;border-bottom:1px solid #2a1d0d;font-size:12px;color:#ddd}
#fr-list i{width:8px;height:8px;border-radius:50%;background:#555}#fr-list i.on{background:#4c4}
#fr-list span{flex:1}#fr-list button{font-size:11px;padding:2px 6px}
#duelbar{position:absolute;top:64px;left:50%;transform:translateX(-50%);padding:4px 16px;background:#3a0a0acc;border:1px solid #c04040;color:#fdd;font:bold 13px Tahoma,sans-serif;letter-spacing:1px;pointer-events:none}
#w-store{left:50%;top:10%;transform:translateX(-50%);width:min(480px,96vw)}
#st-own input{width:180px;background:#000;border:1px solid #5a4a2c;color:#fff;padding:4px}
.lbl .pstore{display:block;color:#7cf;font-size:11px;background:#0008;border:1px solid #3a6a9a;padding:0 4px;margin-bottom:1px;cursor:pointer}
#cmd-name.pick { animation: cmdpick 1s ease-in-out infinite; }
@keyframes cmdpick { 50% { box-shadow: 0 0 0 1px #ffd060, 0 0 8px #ffd06088; } }
#chaosinfo .crec{margin-top:6px;border-top:1px solid #554;padding-top:4px}#chaosinfo .crec summary{cursor:pointer;color:#ffd060}#chaosinfo .crec p{margin:4px 0;font-size:10.5px;color:#bbb}#chaosinfo .crec p b{font-size:11px;color:#e8c070}
#chatlog .globalmsg{color:#ffb84a}#chatlog .globalmsg b{color:#ffd27a}
/* server list (before Login): first the server, then its Connect button with the load gauge */
#screens[data-sc=sc-server] #loginlogo{display:block}
#sc-server{background:none!important;border:0!important;box-shadow:none!important;width:min(620px,96vw)!important;align-self:center;padding:0!important;display:flex;flex-direction:column;align-items:center}
.srvrow{display:flex;gap:16px;align-items:flex-start;justify-content:center;flex-wrap:wrap;min-height:36px}
.srvgroups{display:flex;flex-direction:column;gap:6px}
.srvgroup{min-width:130px;padding:6px 18px;color:#e8d8c0;font-size:13px;background:linear-gradient(#6a1a14,#3a0c08);border:2px solid #1a0604;box-shadow:0 0 0 1px #a06a40,0 2px 8px #000;border-radius:3px;cursor:pointer;text-shadow:0 1px 2px #000}
.srvgroup:hover,.srvgroup.on{color:#fff;background:linear-gradient(#b0302a,#5a1210);box-shadow:0 0 0 1px #ffc070,0 0 10px #f60}
.srvlist{display:flex;flex-direction:column;gap:6px;animation:srvin .2s ease-out}
@keyframes srvin{from{opacity:0;transform:translateX(-8px)}to{opacity:1;transform:none}}
.srvbtn{display:flex;align-items:center;gap:10px;min-width:280px;padding:6px 10px 6px 14px;color:#ffc84a;font-size:13px;background:linear-gradient(#2a2a2a,#0e0e0e);border:2px solid #000;box-shadow:0 0 0 1px #8a7a60,0 2px 8px #000;border-radius:3px;cursor:pointer}
.srvbtn:hover{color:#fff;box-shadow:0 0 0 1px #ffd070,0 0 12px #f90}
.srvbtn .sn{flex:1;text-align:left}.srvbtn .sl{color:inherit}
.srvbtn.full{color:#f66}.srvbtn.full .sl b{color:#f33}
.gauge{display:flex;gap:2px;padding:2px;background:#000;border:1px solid #555}
.gauge b{width:6px;height:10px;background:#222;box-shadow:inset 0 0 0 1px #111}
.gauge b.on{background:var(--c);box-shadow:inset 0 0 0 1px #0006,0 0 3px var(--c)}
.srvclock{margin-top:14px;text-align:center;color:#eee;font-size:12px;text-shadow:0 1px 3px #000,0 0 6px #000}
.srvnote{margin-top:12px;max-width:520px;padding:8px 14px;color:#f0e0c0;font-size:12px;line-height:1.5;text-align:center;white-space:pre-line;background:#000a;border:1px solid #6b4a1f;border-radius:3px}
.srvvote{margin-top:10px;display:flex;gap:10px;justify-content:center;align-items:center;flex-wrap:wrap}.srvvote[hidden]{display:none}.srvvote img{max-width:min(468px,90vw);max-height:60px;display:block;border:1px solid #6b4a1f}
.srvvote a:hover img{box-shadow:0 0 10px #f90}
.srvver{position:fixed;left:50%;bottom:8px;transform:translateX(-50%);color:#ccc;font-size:11px;text-shadow:0 1px 2px #000,0 0 4px #000;white-space:nowrap}
#srvback{background:none;border:0;color:#c9a060;cursor:pointer;font-size:11px;margin-right:6px;padding:0}
#srvback:hover{color:#fff}
/* active buffs under the character name */
#buffbar{position:absolute;top:26px;left:12px;display:flex;gap:3px;pointer-events:auto;z-index:3}
#buffbar .bf{display:flex;flex-direction:column;align-items:center;width:24px;cursor:default}
#buffbar .bf i{display:block;width:20px;height:28px;border:1px solid #8a7040;box-shadow:0 0 3px #000}
#buffbar .bf.gold i{border-color:#ffd060;box-shadow:0 0 5px #fc0}
#buffbar .bf span{font-size:9px;color:#fff;text-shadow:0 0 2px #000,0 0 2px #000;margin-top:1px;white-space:nowrap}
#buffbar .bf.end{animation:bfblink .5s steps(2) infinite}
@keyframes bfblink{50%{opacity:.35}}
body.mobile #buffbar{zoom:var(--uiz);top:30px}
/* server list buttons + Guide / Updates window */
.srvbtns{display:flex;gap:8px;margin-top:12px}
.srvbtns button{padding:5px 16px;color:#e8d8b0;font-size:12px;background:linear-gradient(#3a2a18,#1a120a);border:1px solid #8a6024;border-radius:3px;cursor:pointer;box-shadow:0 2px 6px #000}
.srvbtns button:hover{color:#fff;border-color:#ffc070;box-shadow:0 0 8px #f90}
#w-guide{position:fixed;inset:0;z-index:60;background:#000a;display:flex;align-items:center;justify-content:center;padding:max(10px,env(safe-area-inset-top)) 10px}
#w-guide[hidden]{display:none}
#w-guide .gbox{box-sizing:border-box;width:min(760px,100%);height:min(86vh,900px);min-height:0;overflow:hidden;display:flex;flex-direction:column;background:linear-gradient(#140d07f5,#0a0604f8);border:1px solid #8a6024;border-radius:4px;box-shadow:0 0 0 1px #000,0 0 40px #000}
#w-guide .gtabs{display:flex;gap:4px;padding:6px;border-bottom:1px solid #4a3418;flex:none}
#w-guide .gtabs button{padding:5px 14px;background:linear-gradient(#3a2a18,#1a120a);border:1px solid #5a3e1a;color:#c9b48a;font-size:12px;cursor:pointer;border-radius:2px}
#w-guide .gtabs button.on{background:linear-gradient(#8a2a10,#4a1206);color:#fff;border-color:#c06030}
#w-guide .gtabs .sp{flex:1}
#w-guide .gbody{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;padding:6px 16px 16px;color:#d8ccb0;font-size:13px;line-height:1.5;overflow-wrap:anywhere}
#w-guide h3{margin:14px 0 6px;color:#ffd060;font-size:15px;border-bottom:1px solid #3a2a14;padding-bottom:3px}
#w-guide h3 small{color:#a89070;font-weight:normal;font-size:11px}
#w-guide ul{margin:4px 0;padding-left:18px}#w-guide li{margin:2px 0}
#w-guide b{color:#f0d890}
#w-guide p{margin:4px 0}
#w-guide .grates{display:flex;flex-wrap:wrap;gap:6px;margin:6px 0}
#w-guide .grates span{background:#000a;border:1px solid #5a3e1a;padding:3px 10px;border-radius:2px}
#w-guide .gcols{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:3px 12px}
#w-guide .gcols i{color:#a89070;font-style:normal;font-size:11px}
/* rankings */
#w-guide .rtabs{display:flex;flex-wrap:wrap;gap:4px;margin:8px 0}
#w-guide .rtabs button{padding:4px 12px;background:#1a120a;border:1px solid #5a3e1a;color:#c9b48a;font-size:12px;cursor:pointer;border-radius:2px}
#w-guide .rtabs button.on{background:linear-gradient(#8a2a10,#4a1206);color:#fff;border-color:#c06030}
#w-guide table.rank{width:100%;border-collapse:collapse;font-size:12px}
#w-guide .rank th{position:sticky;top:-6px;background:#1a120a;color:#ffd060;text-align:left;padding:5px 6px;border-bottom:1px solid #5a3e1a;font-weight:normal}
#w-guide .rank td{padding:4px 6px;border-bottom:1px solid #2a1e10;white-space:nowrap}
#w-guide .rank tr:nth-child(even) td{background:#ffffff06}
#w-guide .rank tr.t1 td:first-child{color:#ffd700;font-weight:bold}#w-guide .rank tr.t2 td:first-child{color:#d8d8e8;font-weight:bold}#w-guide .rank tr.t3 td:first-child{color:#e0a060;font-weight:bold}
#w-guide .rank tr.me td{background:#4a3a1066}
@media (max-width:560px){#w-guide .rank .hc{display:none}#w-guide .gbody{padding:4px 8px 12px}}
/* stats window: amount + reset */
#charstats .pts{display:flex;flex-wrap:wrap;align-items:center;gap:4px 8px}
#charstats .pts .amt{margin-left:auto;color:#ccc;font-size:11px}
#charstats .pts input{width:58px;background:#000;border:1px solid #6b4a1f;color:#ffd060;font-size:12px;padding:1px 3px;text-align:right}
#charstats .rst{margin-top:8px;text-align:center}
#charstats .rst button{width:100%;padding:5px;background:linear-gradient(#8a2a10,#4a1206);border:1px solid #c06030;color:#fff;cursor:pointer;font-size:12px;border-radius:2px}
#charstats .rst button:hover{box-shadow:0 0 8px #f60}
#charstats .rst small{display:block;color:#a89070;font-size:10px;margin-top:3px}
/* GM powers */
.gmself{display:flex;flex-wrap:wrap;gap:4px;padding:4px 8px;border-bottom:1px solid #4a3418}
.gmself button,.gmself select{font-size:11px;padding:3px 8px;background:#1a120a;border:1px solid #5a3e1a;color:#c9b48a;cursor:pointer;border-radius:2px;max-width:200px}
.gmself button.on{background:linear-gradient(#2a8a10,#145206);color:#fff;border-color:#60c030}
#labels .lbl.rp .plv{color:#c8b880;font-size:10px}
#labels .lbl.rp .php:not(.other) i{background:#3d3}

#w-menu .mvote{color:#ffd060!important;border-color:#c99a3a!important}

/* country flags + character profile (Rankings) */
img.flag{width:auto;vertical-align:-1px;margin-right:4px;border-radius:1px;box-shadow:0 0 1px #000}
#w-guide .rank tr.rp{cursor:pointer}#w-guide .rank tr.rp:hover td{background:#5a3a1455;color:#fff}
.prof{position:fixed;inset:0;z-index:260;display:grid;place-items:center;background:#0009;padding:10px}
.prof .pbox{position:relative;width:min(460px,96vw);max-height:92vh;overflow-y:auto;background:linear-gradient(#1c140b,#0d0905);border:1px solid #8a6024;box-shadow:0 0 0 1px #000,0 10px 40px #000;border-radius:4px;padding:14px 16px;color:#d8ccb0;font:12px Tahoma,Arial,sans-serif}
.prof .px{position:absolute;right:8px;top:6px;background:none;border:0;color:#c9a060;font-size:20px;cursor:pointer}
.prof .ph{font:bold 18px Georgia,serif;color:#ffd060;display:flex;align-items:center;gap:6px}.prof .ph span{font:11px Tahoma,sans-serif}.prof .ph .on{color:#5c5}.prof .ph .off{color:#887}
.prof .pc{margin:4px 0 10px;color:#cbb}
.prof .pst{display:grid;grid-template-columns:repeat(3,1fr);gap:4px;margin-bottom:10px}
.prof .pst div{background:#000a;border:1px solid #3a2810;padding:4px 6px;display:flex;justify-content:space-between;gap:6px}.prof .pst small{color:#998}.prof .pst b{color:#ffe0a0}
.prof .peq{display:grid;grid-template-columns:1fr 1fr;gap:4px}
.prof .pi{display:flex;gap:6px;align-items:center;background:#000a;border:1px solid #3a2810;padding:3px;min-height:40px}
.prof .pi i{flex:none;width:34px;height:34px;background:#0006 center/contain no-repeat}
.prof .pi span{display:flex;flex-direction:column;line-height:1.25;color:#e8e0c8;overflow-wrap:anywhere}.prof .pi small{color:#887;font-size:10px}
.prof .pi em{font-style:normal;color:#9cf;font-size:10px}.prof .pi em.x{color:#7f7}.prof .pi.exc span{color:#7f7}
.prof .pi.empty span{color:#554}
@media (max-width:420px){.prof .peq{grid-template-columns:1fr}.prof .pst{grid-template-columns:repeat(2,1fr)}}
#w-opt .ocountry{display:flex;align-items:center;gap:6px}#w-opt .ocountry select{flex:1;background:#000;border:1px solid #6b4a1f;color:#e8d9b5;padding:2px}

/* login box polish: framed panel, gold links (no browser-blue underlines), soft inputs */
#sc-login{background:radial-gradient(120% 80% at 50% 0,#2a1c0c 0,#0d0906 55%,#050302 100%)!important;border-color:#b08038!important;border-radius:6px!important;
  box-shadow:0 0 0 1px #000,0 0 0 4px #2a1c0c,0 0 0 5px #6a4a1c,0 14px 50px #000,inset 0 1px 0 #ffd27a22!important}
#sc-login .ptitle{position:relative;padding:10px 0;letter-spacing:1.5px;font:bold 14px Georgia,serif;text-shadow:0 1px 2px #000,0 0 10px #a60}
#sc-login .ptitle::after{content:'';position:absolute;left:15%;right:15%;bottom:-1px;height:1px;background:linear-gradient(90deg,#0000,#ffd27a,#0000)}
#sc-login .tabs{margin:14px 18px 8px;border-radius:4px;overflow:hidden;box-shadow:0 0 0 1px #4a3418}
#sc-login .tabs button{border:0!important;padding:7px;transition:background .15s,color .15s}
#sc-login .tabs button:not(.sel):hover{color:#fff;background:#24180c}
#sc-login form{padding:0 18px}
#sc-login label{color:#d6bf8e;letter-spacing:.3px}
#sc-login input{padding:8px 10px;border-radius:4px;background:#0a0704;border-color:#4a3418;transition:border-color .15s,box-shadow .15s}
#sc-login input:focus{border-color:#e0b060;box-shadow:0 0 0 2px #e0b06033,0 0 8px #c8800066}
#sc-login button.main{border-radius:4px;padding:9px;font-weight:bold;text-shadow:0 1px 2px #000;box-shadow:0 2px 10px #0008,inset 0 1px 0 #fff3;transition:filter .15s,box-shadow .15s}
#sc-login button.main:hover{filter:brightness(1.12);box-shadow:0 0 14px #f906,inset 0 1px 0 #fff4}
#sc-login .help{text-align:center;margin:10px 0 2px}
#sc-login a,#sc-login a:visited{color:#e0b060;text-decoration:none;transition:color .15s}
#sc-login a:hover{color:#fff;text-decoration:underline;text-underline-offset:2px}
#sc-login .logincontact{display:flex;justify-content:center;align-items:center;flex-wrap:wrap;gap:6px 10px;margin:8px 0 0;padding:10px 12px 12px;border-top:1px solid #3a2810;background:#00000055;color:#988;font-size:11px}
#sc-login .logincontact .sep{width:4px;height:4px;border-radius:50%;background:#6a4a1c}
#langbtn{position:absolute;right:56px;top:14px;z-index:12;display:flex;border:1px solid #c09040;border-radius:16px;overflow:hidden;background:#000a}
#langbtn button{padding:5px 9px;background:none;border:0;color:#b9a47a;font:bold 11px Tahoma,sans-serif;cursor:pointer}
#langbtn button.on{background:linear-gradient(#8a5a1a,#4a2c08);color:#fff}
body:not([data-bg=login]):not([data-bg=select]) #langbtn{display:none}
.votebox .vbts{display:flex;flex-wrap:wrap;gap:10px;justify-content:center;margin-top:10px}.votebox .vbtn{display:inline-flex;align-items:center;justify-content:center;padding:3px;background:#0b0805;border:1px solid #5a4424;border-radius:4px;color:#ffd060;font:bold 13px Tahoma,sans-serif;cursor:pointer}.votebox .vbtn:hover{border-color:#ffd060;box-shadow:0 0 10px #f906}.votebox .vbtn img{display:block;height:60px;max-width:220px}.votebox .vbtn img+span{display:none}.votebox .vbtn span{padding:8px 14px}
#sc-load.big::before{content:'';position:absolute;inset:-40px;z-index:-2;background:#000 var(--art,none) center/cover no-repeat;filter:blur(26px) brightness(.4)}
#sc-load.big::after{content:'';position:absolute;inset:0;z-index:-1;background:var(--art,none) center/var(--artfit,contain) no-repeat}
#sc-load.big>*{position:relative}

/* Menu: two columns of compact buttons, fits every screen (scrolls only if it really must) */
#w-menu{top:50%!important;transform:translate(-50%,-50%)!important;width:min(440px,94vw)!important;max-height:92vh;overflow-y:auto;display:grid;grid-template-columns:1fr 1fr;gap:6px;padding:0 12px 10px;box-sizing:border-box;align-content:start}
#w-menu[hidden]{display:none}
#w-menu>.wt{grid-column:1/-1}
#w-menu button{width:100%!important;margin:0!important;padding:8px 6px!important;font-size:12px;line-height:1.2;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#w-menu .mvote{grid-column:1/-1}
#w-menu #m-logout{grid-column:1/-1}
#w-menu .hint{grid-column:1/-1;margin:2px 0 0;font-size:10px;color:#a98;text-align:left}
#w-menu .hint summary{cursor:pointer;color:#c9a060;text-align:center;font-size:11px;list-style:none}
#w-menu .hint summary::before{content:'▸ '}#w-menu .hint[open] summary::before{content:'▾ '}
body.mobile #w-menu{zoom:var(--menuz,1)!important;max-height:calc(96vh / var(--menuz,1))}
body.mobile #w-menu button{padding:9px 6px!important;font-size:13px}
body.mobile #w-menu .hint{display:none}

/* ================= bottom bar v2: big HP / MP spheres with the numbers inside, potions, skills 1-8, EXP in % ================= */
:root{--barh:62px}
#bar.v2{width:940px;height:62px;bottom:0;transform:translateX(-50%);transform-origin:50% 100%}
#bar.v2>img{display:none}
#bar.v2::before{content:'';position:absolute;left:70px;right:70px;top:4px;bottom:0;background:linear-gradient(#1d1810f2,#0b0806fa 40%,#050403);border:1px solid #6b5228;border-bottom:0;border-radius:14px 14px 0 0;box-shadow:0 -2px 14px #000c,inset 0 1px 0 #ffd27a33}
#bar.v2 .orb{top:-40px;width:96px;height:96px;border-radius:50%;overflow:hidden;background:radial-gradient(circle at 50% 60%,#160606,#050202 70%);border:3px solid #7a5a26;box-shadow:0 0 0 2px #000,0 0 18px #000,inset 0 0 18px #000;z-index:4}
#bar.v2 .orb.hp{left:0}#bar.v2 .orb.mp{left:auto;right:0;background:radial-gradient(circle at 50% 60%,#060a16,#020305 70%)}
#bar.v2 .orb .fill{background:radial-gradient(circle at 40% 30%,#ff7a6a,#c41010 45%,#5a0404 85%)!important;background-size:auto!important;transition:height .25s}
#bar.v2 .orb.mp .fill{background:radial-gradient(circle at 40% 30%,#8ab8ff,#1046d0 45%,#04145a 85%)!important}
#bar.v2 .orb.hp.poison .fill{background:radial-gradient(circle at 40% 30%,#a8ff8a,#20a020 45%,#044a04 85%)!important}
#bar.v2 .orb::after{content:'';position:absolute;inset:0;border-radius:50%;background:radial-gradient(ellipse 55% 35% at 42% 22%,#ffffff66,#fff0 70%),radial-gradient(circle at 50% 50%,#0000 58%,#0008 100%);pointer-events:none}
#bar.v2 #hptxt,#bar.v2 #mptxt{top:0px!important;width:96px!important;text-align:center!important;font:bold 13px/16px Arial,sans-serif!important;color:#fff;text-shadow:0 0 3px #000,0 1px 2px #000,0 0 6px #000;z-index:5;pointer-events:auto}
#bar.v2 #hptxt{left:0!important}#bar.v2 #mptxt{left:auto!important;right:0}
#bar.v2 #exp{left:118px!important;width:704px!important;top:10px!important;height:9px!important;background:#000!important;border:1px solid #4a3a1c!important;border-radius:5px;overflow:hidden;z-index:3}
#bar.v2 #expfill{background:linear-gradient(#fff6b0,#f0c040 50%,#a07010)!important;box-shadow:0 0 6px #ffcc40}
#bar.v2 #exptxt{display:block!important;position:absolute;top:0;left:0;width:100%;font:bold 8px/9px Arial,sans-serif!important;color:#fff;text-shadow:0 0 2px #000,0 0 2px #000;text-align:center}
#bar.v2 #explv{left:840px;top:-6px;width:auto;font:bold 11px Arial,sans-serif;color:#ffe080;display:none}
#bar.v2 #lvbox{left:110px!important;top:30px!important;width:62px!important;height:22px!important;font:bold 10px/22px Arial,sans-serif!important;color:#e8d8b0!important;background:#000a;border:1px solid #4a3a1c;border-radius:4px}
#bar.v2 .hot{top:25px!important;width:34px!important;height:34px!important;background-color:#0a0806;border:1px solid #5a4422;border-radius:5px;box-shadow:inset 0 0 8px #000;background-size:26px 26px!important;line-height:14px!important;padding:0 2px;box-sizing:border-box;cursor:pointer;pointer-events:auto;display:flex;align-items:flex-end;justify-content:flex-end;font:bold 10px Arial,sans-serif!important}
#bar.v2 #hot-q{left:182px!important}#bar.v2 #hot-w{left:220px!important}#bar.v2 #hot-e{left:258px!important}
#bar.v2 .hk-l{position:absolute;top:26px;width:12px;font:bold 9px Arial,sans-serif;color:#c9a060;z-index:4;pointer-events:none;text-shadow:0 0 2px #000}
#bar.v2 #hk-q-l{left:185px}#bar.v2 #hk-w-l{left:223px}#bar.v2 #hk-e-l{left:261px}
#bar.v2 #skillslot{left:302px!important;top:19px!important;width:30px!important;height:41px!important;border:2px solid #c99a3a!important;border-radius:4px;box-shadow:0 0 8px #ffb03066}
#bar.v2 #hotbar{position:absolute;left:346px;top:21px;display:flex;gap:4px;z-index:3;pointer-events:auto}
#bar.v2 .hk{position:relative;width:30px;height:38px;border:1px solid #5a4422;border-radius:4px;background:#0a0806;box-shadow:inset 0 0 6px #000;cursor:pointer;overflow:hidden}
#bar.v2 .hk i{position:absolute;inset:1px;border-radius:3px}
#bar.v2 .hk b{position:absolute;left:2px;top:0;font:bold 10px Arial,sans-serif;color:#fff;text-shadow:0 0 2px #000,0 0 2px #000;z-index:1}
#bar.v2 .hk.sel{border-color:#ffd060;box-shadow:0 0 7px #ffb030}
#bar.v2 .hk.nomp i{filter:grayscale(.8) brightness(.55)}
#bar.v2 .hk:hover{border-color:#e8c070}
#bar.v2 .mbtn{top:24px!important;width:34px!important;height:34px!important;border:1px solid #6b5228;border-radius:6px;background:#0d0a06 center/21px 21px no-repeat;box-shadow:inset 0 0 8px #000}
#bar.v2 .mbtn:hover{border-color:#ffd27a;box-shadow:inset 0 0 8px #000,0 0 8px #ffb03088}
#bar.v2 #mb-char{left:666px!important;background-image:url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23e8c070%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Ccircle%20cx%3D%2212%22%20cy%3D%227.5%22%20r%3D%223.8%22/%3E%3Cpath%20d%3D%22M4.5%2021c0-4.4%203.4-7.5%207.5-7.5s7.5%203.1%207.5%207.5%22/%3E%3C/svg%3E")}
#bar.v2 #mb-inv{left:704px!important;background-image:url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23e8c070%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22M5%209h14l-1.2%2011.5H6.2z%22/%3E%3Cpath%20d%3D%22M9%209V6.5a3%203%200%200%201%206%200V9%22/%3E%3Cpath%20d%3D%22M9.5%2014h5%22/%3E%3C/svg%3E")}
#bar.v2 #mb-skill{left:742px!important;top:24px!important;width:34px!important;height:34px!important;background-image:url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A//www.w3.org/2000/svg%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20stroke%3D%22%23e8c070%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%3E%3Cpath%20d%3D%22M12%202.8l7.5%202.8v5.6c0%204.8-3.2%208.4-7.5%2010-4.3-1.6-7.5-5.2-7.5-10V5.6z%22/%3E%3Cpath%20d%3D%22M9%2011.5l2.2%202.2%204-4.2%22/%3E%3C/svg%3E")}
#bar.v2 #mb-menu{left:780px!important;background-image:none;color:#e8c070;font:bold 18px/32px Arial,sans-serif;text-align:center}
#bar.v2 #mb-menu::before{content:'☰'}
#bar.v2 #mb-char.on,#bar.v2 #mb-inv.on,#bar.v2 #mb-menu.on{border-color:#ffd060;box-shadow:inset 0 0 8px #ffb030}
#barfill{display:none!important} /* the owner: no dark strips at the sides of the bottom bar */
body.mobile #bar.v2 #hotbar,body.mobile #bar.v2 .hk-l{display:none}

/* top icon bar (left) + round radar map (right), like the newer clients */
#topbar{position:absolute;left:10px;top:30px;display:flex;gap:4px;z-index:4;pointer-events:auto}
#topbar button{width:30px;height:30px;padding:0;border:1px solid #6b5228;border-radius:6px;background:linear-gradient(#2a2014,#0d0a06);font-size:15px;line-height:28px;cursor:pointer;box-shadow:0 0 6px #000a;filter:saturate(.85)}
#topbar button:hover{border-color:#ffd27a;box-shadow:0 0 8px #ffb03088;filter:none;transform:translateY(-1px)}
#buffbar{top:66px!important}
#radar{position:absolute;right:12px;top:10px;width:150px;height:150px;border-radius:50%;border:3px solid #7a5a26;box-shadow:0 0 0 2px #000,0 0 14px #000;background:#000;z-index:4;pointer-events:auto;cursor:pointer}
body:not(.mobile) #info{top:168px!important;text-align:right}
body.mobile #topbar,body.mobile #radar{display:none}

/* chat: lighter, see-through like the newer clients */
#chatbox{background:linear-gradient(90deg,#000a,#0006 70%,#0000)!important;border:0!important;border-radius:6px 6px 0 0}
#chatbar{background:#0008!important;border:1px solid #3a2a1488!important;border-radius:0 0 4px 4px}
#chattabs{background:none!important;border:0!important;gap:3px!important;padding:3px 0 0!important}
#chattabs button{background:#000a!important;border:1px solid #5a3e1a88!important;border-radius:10px;padding:2px 10px!important;color:#c9b48a}
#chattabs button.on{background:linear-gradient(#a0702a,#5a3a10)!important;color:#fff!important;border-color:#e0b060!important}
#chatlog div{text-shadow:0 1px 2px #000,0 0 3px #000}
/* inventory buttons */
.invbtns{display:flex;gap:6px;justify-content:center;margin:4px 12px}
.invbtns button{flex:1;padding:4px 6px;background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6b5228;border-radius:4px;color:#e8d9b5;font-size:11px;cursor:pointer}
.invbtns button:hover{border-color:#ffd27a;color:#fff}

/* phones: a compact bottom bar - the HP / MP spheres stay inside the bar so nothing sticks up under the joystick / attack button */
body.mobile #bar.v2{width:640px}
body.mobile #bar.v2::before{left:34px;right:34px}
body.mobile #bar.v2 .orb{top:0;width:62px;height:62px;border-width:2px}
body.mobile #bar.v2 #hptxt,body.mobile #bar.v2 #mptxt{top:23px!important;width:62px!important;font:bold 12px/16px Arial,sans-serif!important}
body.mobile #bar.v2 #exp{left:72px!important;width:496px!important;top:8px!important;height:10px!important}
body.mobile #bar.v2 #exptxt{font-size:9px!important;line-height:10px!important}
body.mobile #bar.v2 #lvbox{left:72px!important;top:27px!important;width:60px!important}
body.mobile #bar.v2 #hot-q{left:142px!important}body.mobile #bar.v2 #hot-w{left:180px!important}body.mobile #bar.v2 #hot-e{left:218px!important}
body.mobile #bar.v2 #skillslot{left:305px!important}
body.mobile #bar.v2 #mb-char{left:400px!important}body.mobile #bar.v2 #mb-inv{left:438px!important}body.mobile #bar.v2 #mb-skill{left:476px!important}body.mobile #bar.v2 #mb-menu{left:514px!important}
body.mobile #mskills .ms{box-sizing:border-box}
body.mobile #mskills .ms i{width:36px;height:50px}
body.mobile #mpad{right:calc(30px + env(safe-area-inset-right))}
/* phones: chat goes to the free top-left corner (above the 💬 button) so it never covers the joystick; buffs move to the top middle */
body.mobile #chat{top:calc((24px + env(safe-area-inset-top)) / var(--uiz));bottom:auto;left:calc((10px + env(safe-area-inset-left)) / var(--uiz));width:320px}
body.mobile #chatbox{height:110px}
body.mobile #chat.big #chatbox{height:200px}
body.mobile #emojipick{bottom:auto;top:0}
body.mobile #buffbar{top:calc(36px + env(safe-area-inset-top))!important;left:50%!important;transform:translateX(-50%)}
body.mobile #partyhud{top:calc(24px / var(--uiz));left:calc(10px / var(--uiz));zoom:var(--uiz)}
body.mobile:has(#partyhud:not([hidden])) #chat{left:calc(190px + 14px / var(--uiz))}
/* PC: the party list goes under the icon bar and the buffs */
body:not(.mobile) #partyhud{top:112px}
/* the MU hand / sword closes while the mouse button is held (like the original client) */
body.press,body.press *:not(input):not(textarea){cursor:url(../assets/ui/cursorpush_down.png) 4 2,default!important}
body.press #view.attack{cursor:url(../assets/ui/cursorattack_down.png) 1 1,crosshair!important}
/* buffs: a row of icons at the top middle, details on hover (name, effect, time left) */
body:not(.mobile) #buffbar{top:40px!important;left:50%!important;transform:translateX(-50%)}
#buffbar{gap:4px!important}
#buffbar .bf{position:relative;width:auto!important}
#buffbar .bf i{width:24px!important;height:34px!important;border:2px solid #2fae4a!important;border-radius:3px;box-shadow:0 0 0 1px #000,0 0 6px #000!important}
#buffbar .bf.gold i{border-color:#ffd060!important}
#buffbar .bf span{position:absolute;bottom:2px;left:0;right:0;text-align:center;font:bold 10px Arial,sans-serif!important;color:#fff;text-shadow:0 0 2px #000,0 0 3px #000}
#mtip{position:fixed;z-index:9000;pointer-events:none;max-width:260px;padding:5px 9px;background:#0a0806ee;border:1px solid #6b5228;border-radius:3px;box-shadow:0 2px 10px #000;color:#eee;font:11px/15px Arial,sans-serif;text-align:center;white-space:pre-line}
#mtip b,#mtip i,#mtip span,#mtip em{display:block;font-style:normal}
#mtip .t-n{color:#6cb8ff}#mtip .t-k{color:#5fdc5f}#mtip em{color:#e050e0;margin-top:2px}
/* day / night clock next to the radar */
#dayclock{position:absolute;right:170px;top:12px;width:26px;height:26px;border-radius:50%;background:radial-gradient(#2a3a6a,#0a1024);border:2px solid #7a5a26;box-shadow:0 0 0 1px #000,0 0 8px #000;font-size:14px;line-height:22px;text-align:center;z-index:4;pointer-events:auto}
#dayclock:not(.night){background:radial-gradient(#6a5a2a,#24180a)}
#dayclock[hidden]{display:none}
body.mobile #dayclock{right:calc(14px + 4px * var(--mz,1));top:calc(10px + 48px * var(--mz,1));transform:scale(var(--mz,1));transform-origin:100% 0}
/* radar without a frame (the map fades out at its edges) */
#radar{width:220px!important;height:170px!important;border:0!important;border-radius:0!important;background:none!important;box-shadow:none!important;right:4px!important;top:4px!important}
#dayclock{right:196px;top:10px}
body:not(.mobile) #info{top:172px!important}

#info{background:linear-gradient(90deg,transparent,#0008 18%,#000a);padding:5px 9px 6px 26px;border-radius:6px;text-shadow:0 0 2px #000,0 1px 2px #000,0 0 6px #000}
#info #online,#info #srvtype,#info #evbar span{text-shadow:0 0 2px #000,0 1px 2px #000}
#online{color:#9ee89e}#srvtype{color:#f0b4b4}
body.mobile #info{font-size:14px;padding:4px 8px 5px 18px}body.mobile #online,body.mobile #evbar span{font-size:12px}body.mobile #srvtype{font-size:11px}
/* top left: only Vote and MU Helper, with our own drawn icons (also on phones, next to the chat button) */
#topbar{gap:6px!important}
#topbar button{width:44px!important;height:44px!important;padding:2px 0 0!important;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:0;background:radial-gradient(circle at 50% 35%,#3a2a16,#0d0a06 75%)!important;border:1px solid #8a6a30!important;border-radius:8px!important;filter:none!important;line-height:1!important}
#topbar button svg{width:26px;height:26px;display:block;filter:drop-shadow(0 1px 2px #000)}
#topbar button span{font:bold 9px Arial,sans-serif;color:#e8c070;text-shadow:0 1px 2px #000;margin-top:1px}
#topbar button:hover svg{filter:drop-shadow(0 0 4px #ffc040) brightness(1.15)}
#topbar button.on{border-color:#ffd060!important;box-shadow:0 0 8px #ffb030!important}
body.mobile #topbar{display:flex!important;top:auto!important;left:calc(64px + env(safe-area-inset-left))!important;bottom:calc(var(--barh) * var(--barz) + 12px + 150px * var(--mz,1));transform:scale(var(--mz,1));transform-origin:0 100%}
#bar.v2 #skillslot{width:29px!important;height:40px!important;overflow:hidden}
#bar.v2 #skillkey{position:absolute;left:2px;top:0;bottom:auto;font:bold 10px Arial,sans-serif;color:#fff;text-shadow:0 0 2px #000,0 0 2px #000}
/* ping to the server (top right, next to the day / night clock) */
#ping{position:absolute;right:230px;top:12px;height:22px;display:flex;align-items:flex-end;gap:2px;padding:0 7px 4px;background:#0a0806cc;border:1px solid #6b5228;border-radius:11px;z-index:4;pointer-events:auto;box-sizing:border-box}
#ping i{width:3px;background:#3a3a3a;border-radius:1px}
#ping i:nth-child(1){height:4px}#ping i:nth-child(2){height:7px}#ping i:nth-child(3){height:10px}#ping i:nth-child(4){height:13px}
#ping b{font:bold 11px/13px Arial,sans-serif;margin-left:4px;color:#ddd}
#ping.q4 i{background:#4c4}#ping.q3 i:nth-child(-n+3){background:#9d4}#ping.q2 i:nth-child(-n+2){background:#ec4}#ping.q1 i:nth-child(1){background:#f44}
#ping.q4 b{color:#7e7}#ping.q3 b{color:#bd6}#ping.q2 b{color:#fc5}#ping.q1 b{color:#f66}
#ping u{width:1px;height:13px;background:#6b522888;margin:0 6px 0 7px;align-self:flex-end;text-decoration:none}
#ping em{font:bold 11px/13px Arial,sans-serif;font-style:normal;color:#7e7;min-width:38px;text-align:left}
#ping em.f3{color:#bd6}#ping em.f2{color:#fc5}#ping em.f1{color:#f66}
body.mobile #ping{right:calc(14px + 36px * var(--mz,1));top:calc(12px + 48px * var(--mz,1));transform:scale(var(--mz,1));transform-origin:100% 0}
body.mobile #info{top:calc((18px + 70px * var(--mz,1)) / var(--uiz,1))!important}
#dayclock svg{width:20px;height:20px;display:block;margin:1px auto 0}
#dayclock{line-height:0!important}
/* ancient set items (Season 6) */
#tip .nm.anc{color:#4cf}#tip .anc{color:#ffd060}#tip .ancopt{color:#4cf}
/* PC: the side windows start a little lower (not glued to the top edge of the screen) */
body:not(.mobile) #w-trade,body:not(.mobile) #w-inv,body:not(.mobile) #w-char,body:not(.mobile) #w-quest,body:not(.mobile) #w-skill,body:not(.mobile) #w-shop,body:not(.mobile) #w-vault,body:not(.mobile) #w-chaos{top:64px}
body:not(.mobile) #w-guild{top:64px!important}
/* messages of the admin / GMs: marked for everyone */
#chatlog .staffmsg{color:#ffd060;font-weight:bold}#chatlog .gmtag{color:#ff5a3a;font-weight:bold}#chatlog .gmtag.gm{color:#5ad0ff}
.castleown{text-align:center;padding:18px 10px}.castleown .ct{font:bold 15px Georgia,serif;color:#ffd060;margin-bottom:10px;letter-spacing:1px}.castleown .cg{font:bold 18px Georgia,serif;color:#fff;margin:8px 0 4px}.castleown img{image-rendering:pixelated;border:1px solid #6b5228}

/* Season 6 map overlay (Tab) */
#bigmap{position:fixed;inset:0;width:100vw;height:100vh;pointer-events:none;z-index:15}
#bigmapui{display:none;pointer-events:auto;position:fixed;right:14px;bottom:calc(var(--barh,70px) + 70px);z-index:16;background:rgba(0,0,0,.55);border:1px solid #5a4a2c;border-radius:6px;padding:6px 8px;font:12px Tahoma,sans-serif;color:#ddd}
#bigmap:not([hidden])+#bigmapui{display:block}
#bigmapui div{display:flex;align-items:center;gap:6px;margin:3px 0}#bigmapui span{width:86px}
#bigmapui button{background:#2a2014;border:1px solid #7a5a26;color:#fd8;min-width:24px;height:22px;border-radius:4px;cursor:pointer}
#bigmapui b{width:40px;text-align:center;color:#fff}#bigmapui button[data-x]{width:100%;margin-top:4px}
body.mobile #bigmapui{right:8px;bottom:auto;top:70px;font-size:13px}body.mobile #bigmapui button{min-width:32px;height:30px}
.johopt{color:#ffe040}

body.mobile #w-trade{top:4px;left:calc(4px + env(safe-area-inset-left))}
.sockh{color:#c080ff;font-weight:bold}.sockopt{color:#d8a8ff}
.gens{display:inline-block;font:bold 9px Arial;padding:0 3px;margin-right:3px;border-radius:2px;vertical-align:1px;color:#fff}.gens.g1{background:#a0281e}.gens.g2{background:#1e4ea0}
#staffv{position:fixed;top:70px;left:50%;transform:translateX(-50%);width:min(360px,92vw);z-index:40;background:rgba(14,10,6,.96);border:1px solid #8a6a2c;border-radius:6px;padding:12px 14px;text-align:left;box-shadow:0 6px 30px #000}#staffv[hidden]{display:none}#staffv b{color:#ffd27a}#staffv .row{display:flex;margin-top:6px}#staffv .help{margin:4px 0}#sv-step2{gap:6px}#sv-step2 input{flex:1;min-width:0}

/* SD (Shield, Season 6): a yellow ring around the HP orb */
.sdring{position:absolute;inset:0;border-radius:50%;pointer-events:none;z-index:3;--sd:0%;background:conic-gradient(from 180deg,#ffe066 0,#ffb020 var(--sd),rgba(0,0,0,0) var(--sd));-webkit-mask:radial-gradient(circle,transparent 60%,#000 63%);mask:radial-gradient(circle,transparent 66%,#000 68%);filter:drop-shadow(0 0 3px #ffb020)}
.dmg.sd b{color:#ffd23c!important}

/* Master Skill Tree (Season 6): 3 trees of 4 x 9 - the icon whole (its own box, never cut) and the name under it */
#w-master { width: min(680px, 97vw); max-height: 94vh; overflow: auto; }
#mt-head { color: #e8c8ff; font-size: 13px; }
#mt-trees { display: flex; gap: 5px; padding: 0 5px; }
.mtt { flex: 1; min-width: 0; background: rgba(40, 20, 60, .35); border: 1px solid #5a3a7a; border-radius: 4px; }
.mth { text-align: center; font-size: 12px; color: #ffcf70; padding: 3px; border-bottom: 1px solid #5a3a7a; }
.mth span { color: #fff; margin-left: 4px; }
.mtg { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: 50px; gap: 3px; padding: 4px; }
.mtc { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; min-width: 0; border: 1px solid #3a2a4a; border-radius: 3px; background: #1a1222; cursor: pointer; overflow: hidden; font-style: normal; padding: 1px; }
.mtc.empty { visibility: hidden; cursor: default; }
.mtc u { flex: none; width: 18px; height: 25.2px; border: 1px solid #000; border-radius: 2px; text-decoration: none; }
.mtc s { display: block; max-width: 100%; text-align: center; font-size: 8.5px; line-height: 1.05; color: #d8cce0; text-decoration: none; word-break: break-word; overflow: hidden; }
.mtc.ico s { font-size: 8px; max-height: 2.1em; }
#mt-tabs { display: none; gap: 4px; padding: 0 5px 4px; }
#mt-tabs button { flex: 1; padding: 6px 2px; }
#mt-tabs button.on { background: #6a3a9a; color: #fff; border-color: #c9a0ff; }
.mtc.has { border-color: #c9a0ff; box-shadow: inset 0 0 6px #a060ff; }
.mtc.can { border-color: #ffcf70; }
.mtc.nofx { opacity: .45; }
.mtc.sel { outline: 2px solid #fff; outline-offset: -1px; }
.mtc b { position: absolute; right: 2px; top: 0; font-size: 10px; color: #7f7; text-shadow: 0 0 2px #000, 0 0 2px #000; }
#mt-info { font-size: 12px; min-height: 58px; }
#mt-info .g { color: #7f7; } #mt-info .r { color: #f88; }
#mt-info button { margin-top: 4px; }
/* phones (landscape): the tree window fills the screen above the bottom bar - its own size (no window zoom), one tree at a time, the info on the right */
body.mobile #hud #w-master { zoom: 1; position: fixed; left: 4px; right: 4px; top: 4px; bottom: 58px; width: auto; max-height: none; transform: none;
  display: grid; grid-template-columns: minmax(0, 1fr) 36%; grid-template-rows: auto auto auto 1fr; grid-template-areas: "wt wt" "head head" "tabs info" "trees info"; overflow: hidden; }
body.mobile #w-master > .wt { grid-area: wt; } body.mobile #mt-head { grid-area: head; padding: 2px 8px; font-size: 12px; }
body.mobile #mt-tabs { grid-area: tabs; display: flex; padding: 0 4px 3px; } body.mobile #mt-tabs button { padding: 4px 2px; font-size: 12px; }
body.mobile #mt-trees { grid-area: trees; min-height: 0; padding: 0 4px 4px; } body.mobile .mtt { display: none; height: 100%; } body.mobile .mtt.on { display: block; } body.mobile .mth { display: none; }
body.mobile .mtg { height: 100%; box-sizing: border-box; grid-template-rows: repeat(9, minmax(0, 1fr)); grid-auto-rows: unset; gap: 2px; padding: 2px; }
body.mobile .mtc u { zoom: .8; } body.mobile .mtc { flex-direction: row; gap: 4px; } body.mobile .mtc.ico s { font-size: 9px; max-height: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } body.mobile .mtc s { font-size: 8.5px; } body.mobile .mtc b { font-size: 11px; }
body.mobile #mt-info { grid-area: info; font-size: 13px; overflow: auto; padding: 6px; border-left: 1px solid #5a3a7a; } body.mobile #mt-info button { padding: 8px 14px; font-size: 14px; }

/* Market (vote points) */
#w-market { width: min(620px, 96vw); max-height: 90vh; overflow: auto; }
#mk-tabs button.on { background: #6a3a9a; color: #fff; }
#mk-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 6px; padding: 6px 8px 10px; }
.mkc { display: flex; flex-direction: column; align-items: center; gap: 3px; background: rgba(0, 0, 0, .35); border: 1px solid #3a3226; border-radius: 4px; padding: 5px 3px; text-align: center; }
.mkc.bad { opacity: .55; }
.mkc .it { position: relative !important; left: auto !important; top: auto !important; }
.mkn { font-size: 11px; min-height: 2.4em; line-height: 1.2; }
.mkn .mk-excellent-prefix { color: #5f5; }
.mkb { font-size: 12px; padding: 3px 8px; }
/* phones: the Market fills the screen above the bottom bar, like the Master tree, with its own (readable) size */
body.mobile #hud #w-market { zoom: 1; position: fixed; left: 4px; right: 4px; top: 4px; bottom: 58px; width: auto; max-height: none; transform: none; overflow: auto; }
body.mobile #mk-list { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 4px; }
body.mobile .mkn { font-size: 10.5px; } body.mobile .mkb { font-size: 13px; padding: 6px 12px; }
/* rankings: who is online */
.rdot{display:inline-block;width:8px;height:8px;border-radius:50%;margin-right:5px;vertical-align:middle;box-shadow:0 0 2px #000}.rdot.on{background:#5c5;box-shadow:0 0 5px #5c5}.rdot.off{background:#554}
.ronl{font-size:11px;color:#bba;padding:2px 6px 4px}
/* profile card: the character in 3D next to the items */
.prof .pbox{width:min(720px,96vw)}
.prof .pbody{display:grid;grid-template-columns:220px 1fr;gap:8px;align-items:start}
.prof .p3d{width:220px;height:330px;background:radial-gradient(ellipse at 50% 80%,#2a1c0c,#000 75%);border:1px solid #3a2810;border-radius:4px}
body.mobile .prof .pbody{grid-template-columns:150px 1fr}body.mobile .prof .p3d{width:150px;height:225px}
/* guild join requests (guild master) */
.gupend{padding:4px 6px;border-top:1px solid #3a2810;font-size:12px}.gupend>b{display:block;color:#ffd060;margin-bottom:3px}.gupend div{display:flex;align-items:center;gap:6px;padding:2px 0}.gupend .nm{flex:1}.gupend .ga{font-size:11px;padding:2px 8px}
/* the administrator's global message: gold letters in the middle of the screen */
#banner.adminmsg{top:34%;font:bold 22px Georgia,serif;color:#ffd700;text-shadow:0 0 6px #000,0 0 14px #8a6000,0 2px 0 #000;white-space:pre-line;max-width:min(900px,80vw);text-align:center;padding:12px 44px;background:linear-gradient(90deg,transparent,#000d 18%,#000d 82%,transparent)}
/* How to… help: folded topics */
.ht h3{cursor:pointer;user-select:none}.ht h3::before{content:"▸ ";color:#c9a060}.ht.open h3::before{content:"▾ "}.ht ol,.ht p{display:none}.ht.open ol,.ht.open p{display:block}
.ht ol{padding-left:22px;line-height:1.5}.ht li{margin:3px 0}

/* character window: the item bonuses fold away (closed until clicked) and use two columns */
.cbon{margin-top:4px}.cbon summary{cursor:pointer;color:#8f8;font-size:12px;padding:3px 0;user-select:none}
.cbg{display:grid;grid-template-columns:1fr 1fr;gap:1px 10px;font-size:10.5px}.cbg div{display:flex;justify-content:space-between;gap:4px;border-bottom:1px solid #0003}.cbg span{color:#9fc}.cbg b{color:#f0c060;white-space:nowrap}

/* character window: a number box next to every stat; the list scrolls when the screen is short (phones) */
#charstats .stn{width:52px;margin-left:6px;background:#000;border:1px solid #6b4a1f;color:#ffd060;font-size:12px;padding:1px 3px;text-align:right;border-radius:2px}
#charstats{overflow-y:auto;max-height:calc(var(--vh,100vh) - var(--barh) - 110px);scrollbar-width:thin}
body.mobile #charstats{max-height:555px;padding:6px 12px}body.mobile #charstats .r{padding:2px 0}body.mobile #charstats .stn{width:64px;font-size:14px;padding:3px}body.mobile #charstats button[data-st]{width:30px;height:26px;font-size:16px}

#chatlog div[data-from] b{cursor:pointer}#chatlog div[data-from] b:hover{text-decoration:underline}

/* ===== demo: windows in the style of the bottom bar (dark panel, thin gold frame, rounded slots). Active only with body.uiv2 ===== */
body.uiv2 .win:not(#w-menu){background:linear-gradient(#17120b,#0b0806 120px,#090705)!important;background-image:linear-gradient(#17120b,#0b0806 120px,#090705)!important;border:1px solid #7a5a26!important;border-radius:9px!important;
  box-shadow:0 0 0 1px #000,0 0 0 3px #14100a,0 0 0 4px #3a2c14,0 10px 30px #000d,inset 0 0 22px #000a!important;padding-bottom:12px!important;color:#d8ccb0!important}
body.uiv2 .win:not(#w-menu) > .wt{height:34px!important;line-height:34px!important;padding:0 40px!important;background:linear-gradient(#2c2010,#150e06)!important;border-bottom:1px solid #7a5a26!important;border-radius:8px 8px 0 0;
  color:#f0c868!important;font:bold 13px/34px Georgia,serif!important;letter-spacing:1.5px!important;text-shadow:0 1px 2px #000,0 0 8px #a0600060;box-shadow:inset 0 -6px 10px #0006,inset 0 1px 0 #6b522866;margin-bottom:8px}
body.uiv2 .win:not(#w-menu) > .wt .x{right:8px!important;top:7px!important;width:20px!important;height:20px!important;background:#0d0a06!important;border:1px solid #6b5228!important;border-radius:5px;font-size:0!important;box-shadow:inset 0 0 6px #000}
body.uiv2 .win:not(#w-menu) > .wt .x::before{content:'✕';font:bold 11px/18px Arial,sans-serif;color:#e8c070;display:block;text-align:center}
body.uiv2 .win:not(#w-menu) > .wt .x:hover{border-color:#ffd27a!important;box-shadow:inset 0 0 6px #000,0 0 8px #ffb03088}
body.uiv2 .win button:not(.gk):not(.x):not([data-c]):not(.gmtabs button){background:linear-gradient(#1c150b,#0d0a06)!important;border:1px solid #6b5228!important;border-radius:5px!important;color:#e8d8b0!important;box-shadow:inset 0 0 8px #000;min-height:22px}
body.uiv2 .win button:not(.gk):not(.x):not([data-c]):hover{border-color:#ffd27a!important;color:#fff!important;box-shadow:inset 0 0 8px #000,0 0 8px #ffb03066}
body.uiv2 .win input,body.uiv2 .win select{background:#050403!important;border:1px solid #5a4422!important;border-radius:4px!important;color:#f0e6c8!important}
body.uiv2 #equip .slot,body.uiv2 .slot{background-color:#0a0806!important;border:1px solid #5a4422!important;border-radius:5px;box-shadow:inset 0 0 8px #000!important}
body.uiv2 #grid,body.uiv2 .vgrid,body.uiv2 #shopgrid,body.uiv2 .tr-box{background-color:#0a0806!important;background-image:linear-gradient(#2e2412 1px,transparent 1px),linear-gradient(90deg,#2e2412 1px,transparent 1px)!important;background-size:32px 32px!important;border:1px solid #5a4422!important;outline:0!important;border-radius:5px;box-shadow:inset 0 0 12px #000}
body.uiv2 #w-inv .zen,body.uiv2 .vzrow:not(.fee){background:#050403!important;border:1px solid #5a4422;border-radius:5px;padding:0 8px!important}
body.uiv2 #w-inv .zen::before{content:'Zen';font:bold 11px Arial,sans-serif;color:#c9a060;margin-right:auto}
body.uiv2 #w-inv .zen b{color:#ffd060!important}
body.uiv2 #charstats .r{border-bottom:1px solid #2a2010!important;color:#c8bc9c}
body.uiv2 #charstats .r b{color:#ffe08a!important}
body.uiv2 #charstats .rst button{background:linear-gradient(#5a2410,#2a0e06)!important;border-color:#c07030!important}
body.uiv2 .cbon summary{color:#9fe08a}
body.uiv2 .mth{color:#f0c868!important;border-bottom:1px solid #6b5228!important;font-family:Georgia,serif;letter-spacing:1px}
body.uiv2 .mtt{background:#0d0a06aa;border:1px solid #2a2010;border-radius:6px}
body.uiv2 .mtc{background:#120e08!important;border:1px solid #4a3a1c!important;border-radius:5px!important;box-shadow:inset 0 0 6px #000}
body.uiv2 .mtc s{color:#cfc3a3!important}
body.uiv2 .mtc.sel,body.uiv2 .mtc:hover{border-color:#ffd060!important}
body.uiv2 .win ::-webkit-scrollbar{width:8px}body.uiv2 .win ::-webkit-scrollbar-thumb{background:#6b5228;border-radius:4px}body.uiv2 .win ::-webkit-scrollbar-track{background:#0a0806}
body.uiv2 .win{scrollbar-color:#6b5228 #0a0806}
/* Market: filters on top, the list scrolls under them; fits phones */
#w-market{display:flex;flex-direction:column;overflow:hidden!important;width:min(660px,96vw);max-height:calc(var(--vh,100vh) - var(--barh,60px) - 76px)}
#w-market[hidden]{display:none!important}
#mk-head{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;padding:2px 10px 6px}
#mk-tabs{display:flex;gap:6px;flex-wrap:wrap;padding:0 10px 8px;border-bottom:1px solid #3a2c14}
#mk-tabs select,#mk-tabs input{height:28px;padding:0 8px;font:13px Arial,sans-serif;box-sizing:border-box}
#mk-tabs #mk-cat{flex:1 1 150px;font-weight:bold;color:#ffd98a!important}#mk-tabs #mk-set{flex:1 1 130px}#mk-tabs #mk-q{flex:2 1 150px;min-width:0}#mk-tabs #mk-sort{flex:1 1 130px}
#mk-list{flex:1 1 auto;min-height:120px;overflow-y:auto;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;align-content:start;grid-template-columns:repeat(auto-fill,minmax(118px,1fr))}
.mkc{background:#0d0a06!important;border:1px solid #4a3a1c!important;border-radius:6px!important;box-shadow:inset 0 0 8px #000;padding:7px 4px!important}
.mkc:hover{border-color:#c9a060!important}
.mkd{color:#9fe08a;font-size:10px}
.mkb{min-width:74px}.mkb:disabled{opacity:.45}
body.mobile #hud #w-market{bottom:6px;top:4px;left:4px;right:4px;max-height:none;overflow:hidden!important}
body.mobile #mk-tabs select,body.mobile #mk-tabs input{height:34px;font-size:14px}
body.mobile #mk-tabs #mk-cat,body.mobile #mk-tabs #mk-set,body.mobile #mk-tabs #mk-sort{flex:1 1 30%}body.mobile #mk-tabs #mk-q{flex:1 1 100%;order:-1}
body.mobile #mk-list{grid-template-columns:repeat(auto-fill,minmax(104px,1fr))}
body.uiv2 #w-cmd button[data-c],body.uiv2 .win button[data-c]{background:linear-gradient(#1c150b,#0d0a06)!important;border:1px solid #6b5228!important;border-radius:5px!important;color:#e8d8b0!important;box-shadow:inset 0 0 8px #000}
body.uiv2 #w-cmd button[data-c]:hover,body.uiv2 .win button[data-c]:hover{border-color:#ffd27a!important;color:#fff!important}
body.uiv2 #w-menu{background:linear-gradient(#17120b,#0b0806 120px,#090705)!important;background-image:linear-gradient(#17120b,#0b0806 120px,#090705)!important;border:1px solid #7a5a26!important;border-radius:9px!important;box-shadow:0 0 0 1px #000,0 0 0 3px #14100a,0 0 0 4px #3a2c14,0 10px 30px #000d,inset 0 0 22px #000a!important;color:#d8ccb0}
body.uiv2 #w-menu>.wt{height:34px!important;line-height:34px!important;padding:0 40px!important;margin:0 -12px 6px!important;background:linear-gradient(#2c2010,#150e06)!important;border:0!important;border-bottom:1px solid #7a5a26!important;border-radius:8px 8px 0 0;color:#f0c868!important;font:bold 13px/34px Georgia,serif!important;letter-spacing:1.5px!important;text-align:center}
body.uiv2 #w-menu>.wt .x{position:absolute;right:8px!important;top:7px!important;width:20px!important;height:20px!important;background:#0d0a06!important;border:1px solid #6b5228!important;border-radius:5px;font-size:0!important;color:transparent!important}
body.uiv2 #w-menu>.wt .x::before{content:'✕';font:bold 11px/18px Arial,sans-serif;color:#e8c070;display:block;text-align:center}
body.uiv2 #w-menu button{background:linear-gradient(#1c150b,#0d0a06)!important;border:1px solid #6b5228!important;border-radius:5px!important;color:#e8d8b0!important;box-shadow:inset 0 0 8px #000}
body.uiv2 #w-menu button:hover{border-color:#ffd27a!important;color:#fff!important}

/* vault pages, jewel pack menu */
#vpages{display:flex;gap:4px;margin:0 0 2px;width:208px;flex:none}#vpages button{flex:1;position:relative;height:24px;padding:0!important;font-weight:bold}
#vpages button.on{border-color:#ffd060!important;color:#ffd060!important;box-shadow:inset 0 0 8px #ffb03055!important}
#vpages small{position:absolute;right:4px;top:1px;font:9px Arial,sans-serif;color:#9a8a60}
#vpages button[data-vault-action="refresh"]{flex:.65}#vpages button[data-vault-action="retry"]{flex:1.8}
#vpages button:focus-visible{outline:1px solid #ffd060;outline-offset:2px}#vpages button:disabled{opacity:.55;cursor:default}
#w-vault.busy #vaultlist,#w-vault.busy .vzbtns{opacity:.6;pointer-events:none}
.invbtns{display:flex;gap:6px}.invbtns button{flex:1}
#packmenu{position:fixed;left:50%;top:50%;transform:translate(-50%,-50%);z-index:45;pointer-events:auto;min-width:250px;padding:0 10px 10px;background:linear-gradient(#17120b,#0a0806);border:1px solid #7a5a26;border-radius:9px;box-shadow:0 0 0 1px #000,0 10px 30px #000d;font:12px Arial,sans-serif;color:#d8ccb0}
#packmenu[hidden]{display:none}
#packmenu .pkh{position:relative;margin:0 -10px 8px;padding:8px 34px 8px 12px;background:linear-gradient(#2c2010,#150e06);border-bottom:1px solid #7a5a26;border-radius:8px 8px 0 0;color:#f0c868;font:bold 13px Georgia,serif}
#packmenu .pkh .x{position:absolute;right:8px;top:6px;width:20px;height:20px;line-height:18px;text-align:center;border:1px solid #6b5228;border-radius:5px;color:#e8c070;cursor:pointer;background:#0d0a06}
#packmenu .pkr{display:flex;align-items:center;gap:5px;padding:4px 0;border-bottom:1px solid #2a2010}#packmenu .pkr span{flex:1}#packmenu .pkr b{color:#ffe08a;margin-left:4px}#packmenu .pkr.no{opacity:.5}
#packmenu button{width:42px;height:26px;background:linear-gradient(#1c150b,#0d0a06);border:1px solid #6b5228;border-radius:5px;color:#e8d8b0;cursor:pointer;font-weight:bold}
#packmenu button:disabled{opacity:.35;cursor:default}#packmenu button:not(:disabled):hover{border-color:#ffd27a;color:#fff}
#packmenu .hint{margin-top:6px;color:#8a7c5c;font-size:11px}
body.mobile #packmenu{zoom:var(--uiz)}body.mobile #packmenu button{width:52px;height:34px}
/* speech bubble over the head: dark with a gold edge and light letters (black on white was hard to read over the bright ground) */
#labels .lbl .bub{background:#0b0806f2!important;color:#fff3c8!important;border:1px solid #c9a060;border-radius:6px!important;padding:3px 9px!important;font:bold 13px/1.3 Arial,sans-serif!important;max-width:260px!important;text-shadow:0 1px 2px #000;box-shadow:0 2px 8px #000c;margin-bottom:2px}

/* rankings: search + pages */
.rfind{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:6px 0}
.rfind input{flex:1 1 150px;min-width:120px;background:#0d0a07;border:1px solid #6b5326;color:#f3e2b0;border-radius:4px;padding:6px 8px;font:inherit}
#rpages{display:flex;flex-wrap:wrap;gap:4px}
#rpages button{background:#1a140c;border:1px solid #6b5326;color:#d9c48a;border-radius:4px;padding:5px 7px;font-size:12px;cursor:pointer}
#rpages button.on{background:#6b5326;color:#fff3c4}

/* pets: their strikes and how they grow */
.dmg.pet b{color:#ffb040;font-size:17px;text-shadow:0 0 2px #000c,1px 1px 0 #000a,0 0 8px #ff7a0066}.dmg.pet b::before{content:"🐾 ";font-size:12px}
#pethud{position:fixed;left:12px;top:84px;z-index:5;pointer-events:none;font:12px/1.3 Tahoma,Arial,sans-serif;color:#f3e2b0;text-shadow:0 0 3px #000,1px 1px 0 #000}
#pethud div{display:flex;align-items:center;gap:6px;margin:2px 0;white-space:nowrap}#pethud b{color:#ffd060;font-weight:bold;max-width:150px;overflow:hidden;text-overflow:ellipsis}
#pethud i{display:inline-block;width:70px;height:6px;background:#0009;border:1px solid #6b5326;border-radius:3px;overflow:hidden}#pethud u{display:block;height:100%;background:linear-gradient(#ffd060,#c98a1a)}
#pethud small{color:#cdb98a}
body.mobile #pethud{top:auto;bottom:calc(var(--barh,62px) + 74px);left:8px;font-size:11px}body.mobile #pethud i{width:46px}

/* phones: the close button of a window is easy to hit (the tap area is bigger than the little cross), nothing is wider than the screen */
body.mobile .win .x,body.mobile .pbox .px{overflow:visible}
body.mobile .win .x::after,body.mobile .pbox .px::after{content:"";position:absolute;inset:-16px}
.prof .pbox{box-sizing:border-box;max-width:calc(100vw - 12px)}
body.mobile .prof .pbox{max-height:calc(var(--vh,100vh) - 12px)}
body.mobile .votebox .vbtn{box-sizing:border-box}

/* the Muun as a companion: its name and level over it, its moods in a little bubble; its line top left can be tapped to rename it */
#labels .lbl.petl{color:#ffd9a0;font-size:10px;text-align:center;line-height:1.3;cursor:default}#labels .lbl.petl.own{cursor:pointer}
#labels .lbl.petl .pn{color:#ffc060;font-weight:bold}#labels .lbl.petl .plv{color:#cdb98a}
#labels .lbl.petl .bub{display:inline-block;background:#120d08e6;border:1px solid #c9a24a;border-radius:9px;padding:2px 7px;color:#fff3c4;font-size:13px;margin-bottom:2px}
#pethud [data-pet]{pointer-events:auto;cursor:pointer}

/* Market -> Buy points (PayPal): one block over the whole width of the window (the list under it is a grid of small cells) */
.mkpay{grid-column:1/-1;width:100%;max-width:680px;margin:0 auto;padding:10px 14px 14px;box-sizing:border-box;font-size:14px}
.mkpay p{margin:6px 0 12px;line-height:1.5}.mkpay .mktest{color:#ffd060;font-weight:bold}
.mkpacks{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px;margin:0 0 14px}
.mkpack{display:flex;flex-direction:column;align-items:center;gap:6px;margin:0;padding:16px 10px 12px;text-align:center;background:linear-gradient(#2a1c3c,#170f24);border:1px solid #6a4a9a;border-radius:6px;color:#eee;font-size:14px;min-width:0}
.mkpack:hover{border-color:#b79cff;background:linear-gradient(#35234d,#1c122c)}
.mkpack b{color:#ffd060;font-size:19px;line-height:1.1}.mkpack b small{display:block;font-size:11px;font-weight:normal;color:#cbb;letter-spacing:.08em;text-transform:uppercase}
.mkpack span{font-weight:bold;font-size:16px}.mkpack i{font-style:normal;margin-top:4px;padding:8px 12px;border-radius:4px;background:#ffc439;color:#111;font-weight:bold;font-size:12.5px;white-space:nowrap;width:100%;box-sizing:border-box}
.mkpack:disabled{opacity:.6}
.mkpayrow{display:flex;flex-wrap:wrap;align-items:center;gap:10px}#mk-paid{padding:9px 16px;white-space:nowrap}
body.mobile .mkpacks{grid-template-columns:repeat(auto-fit,minmax(130px,1fr));gap:8px}

.mkdon{padding:10px 12px;border:1px dashed #6a4a9a;border-radius:6px}.mkdon b{color:#ffd060}
#mk-amt{width:84px;height:32px;padding:0 8px;font:bold 15px Arial,sans-serif;box-sizing:border-box;text-align:right}

#newver{position:fixed;z-index:100002;left:50%;top:calc(6px + env(safe-area-inset-top));transform:translateX(-50%);display:flex;align-items:center;gap:10px;padding:7px 10px 7px 14px;background:#1c1408f2;border:1px solid #c89a3a;border-radius:6px;box-shadow:0 6px 24px #000c;color:#f0e2c0;font:13px Arial,sans-serif;white-space:nowrap}
#newver button{padding:6px 12px;background:linear-gradient(#ffe7a6,#d99a35);border:0;border-radius:4px;color:#1d1202;font:bold 12.5px Arial,sans-serif;cursor:pointer}
#newver i{font-style:normal;font-size:18px;padding:0 4px;cursor:pointer;color:#cbb}
body.mobile #newver{font-size:12px;max-width:calc(100vw - 16px);white-space:normal}

/* phones: nothing on top of the joystick - the icons (Vote, Helper, Ranking, Market, Donate) at the top in the middle, the pet line under them,
   the chat button next to the menu button (top right); the menu window always inside the visible screen (svh: without the browser's bar) */
body.mobile #topbar{top:calc(4px + env(safe-area-inset-top))!important;bottom:auto!important;left:50%!important;transform:translateX(-50%) scale(var(--mz,1))!important;transform-origin:50% 0!important}
body.mobile #pethud{top:calc(env(safe-area-inset-top) + 8px + 62px * var(--mz,1))!important;bottom:auto!important;left:50%!important;transform:translateX(-50%)}
body.mobile #topbar #m-chat{position:static!important;transform:none!important;border-radius:9px!important}
body.mobile #topbar #m-chat b{font-size:17px;line-height:1}body.mobile #topbar #m-chat span{font-size:8px;color:#e8d9b5;line-height:1.2}
body.mobile #w-menu{max-height:calc(94svh / var(--menuz,1))!important;overflow-y:auto!important;-webkit-overflow-scrolling:touch}
@media (orientation:landscape) and (max-height:500px){
 body.mobile #w-menu{width:min(620px,96vw)!important;grid-template-columns:1fr 1fr 1fr;gap:5px}
 body.mobile #w-menu button{padding:7px 5px!important;font-size:12px}
}

/* phones, staff: the ADMIN / GM badge at the top in the middle and the row of icons just under it (GM Tools also in the ☰ menu) */
body.mobile #gmbadge{top:calc(3px + env(safe-area-inset-top));padding:2px 10px;font-size:11px;z-index:8}
body.mobile:has(#gmbadge:not([hidden])) #topbar{top:calc(28px + env(safe-area-inset-top))!important}
body.mobile:has(#gmbadge:not([hidden])) #pethud{top:calc(env(safe-area-inset-top) + 32px + 62px * var(--mz,1))!important}
#mmlist .mgm{color:#ff9070!important;border-color:#a03a20!important}

/* GM Tools -> Server -> Bot players: its own block that never shrinks to a thin line */
.gssub{display:flex;gap:4px;margin:0 0 8px;flex-wrap:wrap}
.gssub button{flex:1;padding:5px 8px}
.gssub button.on{background:linear-gradient(#8a2a10,#4a1206)!important;color:#fff!important;border-color:#c06030!important}
.gss[hidden]{display:none!important}
.gss{display:flex;flex-direction:column;gap:6px;min-height:0}
#gsn-title,#gsn-text{width:100%;box-sizing:border-box;background:#0d0804;color:#f0e0c0;border:1px solid #5a3e1a;padding:6px 8px;font:inherit;resize:vertical}
#gsn-list>div{display:flex;align-items:flex-start;gap:6px;padding:6px 4px;border-bottom:1px solid #3a2a14}
#gsn-list .nt{flex:1;min-width:0}#gsn-list .nt b{display:block;color:#ffd060}#gsn-list .nt small{color:#9c8a66}#gsn-list .nt p{margin:2px 0 0;color:#d8ccb0;white-space:pre-wrap;overflow-wrap:anywhere;max-height:4.5em;overflow:hidden}
.gsbots{flex:none;margin:8px 0 10px;padding:8px;border:1px solid #3a2a14;border-radius:6px;background:#0004}
.gsbots .gmrow{display:flex;align-items:center;gap:8px;flex-wrap:wrap;margin:0 0 6px}.gsbots .gmrow b{color:#e8c070}
#w-gm #gs-botlist{flex:none!important;min-height:34px!important;height:auto!important;max-height:180px!important}
#gs-botlist>div{cursor:default}#gs-botlist .nm{flex:1}

/* News tab of the guide window (admin can publish / delete here) */
#w-guide .gnews h3 small{color:#9c8a66;font-weight:400;font-size:11px;margin-left:6px}
#w-guide .gnews p{margin:4px 0 12px;white-space:normal}
#w-guide .gnews-del{float:right;padding:2px 10px;font-size:11px}
#w-guide .gnews-add{display:flex;flex-direction:column;gap:6px;margin:8px 0 14px;padding:10px;border:1px solid #7a5420;background:#1a1008}
#w-guide .gnews-add input,#w-guide .gnews-add textarea{width:100%;box-sizing:border-box;background:#0d0804;color:#f0e0c0;border:1px solid #5a3e1a;padding:6px 8px;font:inherit;resize:vertical}
#w-guide .gnews-add button{align-self:flex-end;padding:6px 18px}

/* a video behind the server select / login (Settings: loginVideo) instead of the 3D scene */
#bgvideo{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;pointer-events:none;z-index:0;background:#000}
body[data-bg=login] #bgvideo{filter:brightness(.82)} /* the windows and the heroes stay easy to read over it */
#bgvideo[hidden]{display:none}
body.bgvid[data-bg=login] #bgscene{display:none!important}
#bgcredit{position:absolute;left:10px;bottom:6px;z-index:1;font:10px Tahoma,sans-serif;color:#fff8;text-shadow:0 1px 2px #000;pointer-events:none}#bgcredit[hidden]{display:none}

/* personal store: item cards (picture with the full tooltip, name, price: Zen, jewels, wanted items) */
#st-list{display:flex;flex-direction:column;gap:6px;width:100%;box-sizing:border-box;min-height:0;max-height:min(58vh,520px);overflow-y:auto;padding:6px}
#st-list div{display:block;justify-content:normal;padding:0;border:0;cursor:auto;font-size:inherit;color:inherit} /* not the plain trade-list rows */
#st-list .stcard{display:flex;padding:7px;border:1px solid #3a2a14}
#st-list .stpic{display:flex;padding:3px;border:1px solid #2a1e0e}
#st-list .stinfo{display:flex}#st-list .stp{display:flex}
#st-list .stempty{display:flex;flex-direction:column;align-items:center;gap:6px;padding:22px 10px;color:#9a8a6a;text-align:center;font-size:12px}
#st-list .stempty b{font-size:26px;opacity:.6}
#st-own{width:100%}#st-own input{flex:1;min-width:0}#st-own .bugtxt{margin:6px 0 2px}
#w-store .tradepad{flex-direction:column;flex-wrap:nowrap}
.stcard{display:flex;gap:10px;align-items:flex-start;padding:7px;border:1px solid #3a2a14;border-radius:5px;background:#0006}
.stpic{flex:none;min-width:64px;min-height:64px;display:flex;align-items:center;justify-content:center;background:#000a;border:1px solid #2a1e0e;border-radius:4px;padding:3px}
.stpic .it{position:relative!important;left:auto!important;top:auto!important;cursor:help}
.stinfo{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}
.stname{font-weight:bold;color:#e8dcc4}.stname.exc{color:#5ef05e}.stname.anc{color:#58b8ff}.stname.lv{color:#ffd27a}
.stp{font-size:12px;color:#fd6;display:flex;align-items:center;gap:5px}.stp.want{color:#9fe0ff}
.sti{display:inline-block;width:20px;height:20px;background:center/contain no-repeat;flex:none}
.stinfo button{align-self:flex-start;margin-top:3px;padding:4px 14px}
.lbl .pstore.mine{color:#ffd27a;border-color:#9a7030}
.lbl .pstore:hover{background:#123a;color:#fff}
/* the price window */
.stdlg{position:fixed;inset:0;z-index:20000;display:flex;align-items:center;justify-content:center;background:#0008}
.stbox{width:min(520px,94vw);max-height:92vh;overflow-y:auto;background:linear-gradient(#1a120a,#0b0805);border:1px solid #9a7030;border-radius:6px;padding:14px 16px;box-shadow:0 10px 40px #000;color:#e8dcc4;font-size:13px;display:flex;flex-direction:column;gap:8px}
.stbox .sth{font:bold 15px Georgia,serif;color:#ffd27a;text-align:center}
.stbox .stitem{display:flex;gap:10px;align-items:center}
.stbox label{display:flex;flex-direction:column;gap:3px;color:#c9b48a;font-size:12px}
.stbox input,.stbox select{background:#000;border:1px solid #5a4020;color:#fff;padding:5px 7px;font:inherit}
.stbox .stsec{margin-top:4px;color:#ffd27a;font-weight:bold;border-top:1px solid #3a2a14;padding-top:6px}
.stbox .stjw{display:flex;gap:6px;flex-wrap:wrap}.stbox .stjw label{flex-direction:row;align-items:center;gap:3px}.stbox .stjw input{width:58px}
.stbox .sres{display:flex;flex-direction:column;max-height:180px;overflow-y:auto}
.stbox .sres>div[data-id]{display:flex;align-items:center;gap:6px;padding:3px 6px;cursor:pointer;border-bottom:1px solid #2a1e0e}.stbox .sres>div[data-id]:hover{background:#3a2810}
.stbox .srow{display:flex;flex-wrap:wrap;align-items:center;gap:6px 10px;padding:6px;border:1px solid #3a2a14;border-radius:4px;background:#0005}
.stbox .srow .nm{font-weight:bold;color:#9fe0ff;min-width:110px}.stbox .srow label{flex-direction:row;align-items:center;gap:4px}
.stbox .srow input[type=number]{width:62px}.stbox .srow .x{margin-left:auto;padding:2px 9px}
.stbox .stbtns{display:flex;gap:8px;justify-content:center;margin-top:4px}.stbox .stbtns button{padding:7px 18px}
.stbox .dim{color:#988;font-size:11px}

/* choosing the skill of a key of the bar */
.hkpick{position:fixed;z-index:30000;background:linear-gradient(#1a120a,#0b0805);border:1px solid #9a7030;border-radius:5px;padding:7px;box-shadow:0 6px 24px #000;max-width:min(330px,94vw)}
.hkpick .hkph{color:#ffd27a;font:bold 12px Tahoma,sans-serif;margin-bottom:6px;text-align:center}
.hkpick .hkpl{display:flex;flex-wrap:wrap;gap:4px;justify-content:center}
.hkpick .si{position:relative;width:32px;height:44px;border:1px solid #5a4422;border-radius:3px;cursor:pointer}
.hkpick .si:hover,.hkpick .si.sel{border-color:#ffd27a;box-shadow:0 0 6px #fc6}
.hkpick .si b{position:absolute;right:1px;bottom:0;font:bold 10px Tahoma;color:#fff;text-shadow:0 0 2px #000}
.hkpick .hkclr{display:block;margin:7px auto 0;padding:3px 12px}
#bar.v2 .hk.drop{border-color:#ffd27a;box-shadow:0 0 8px #fc6}
#mskills .msedit{position:absolute;width:30px;height:30px;border-radius:50%;background:#000a;border:1px solid #c09040;color:#ffd27a;font:16px/28px sans-serif;text-align:center;pointer-events:auto;z-index:2}
#st-own .strow{display:flex;gap:6px;align-items:center}#st-own .strow input{flex:1;min-width:0;padding:6px 8px}#st-own .strow button{flex:none;padding:6px 14px}
/* Skills window: wide with 2 columns (it was one long narrow list); phones: as wide as the screen, 1 or 2 columns by the width */
#w-skill{width:min(640px,96vw)!important;max-height:min(560px,calc(var(--vh,100vh) - var(--barh) - 70px))!important;height:auto!important}
#skilllist{display:grid;grid-template-columns:1fr 1fr;gap:5px}
#skilllist .skr{margin:0;padding:5px 7px;min-height:38px}
#skilllist .skr span{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
@media (max-width:560px){#skilllist{grid-template-columns:1fr}}
body.mobile #w-skill{height:auto!important;max-height:calc(var(--vh,100vh) - var(--barh) - 10px)!important;width:min(640px,98vw)!important;left:50%!important;right:auto!important;transform:translateX(-50%)}
.it .n.bdl{color:#ffd060;font-weight:bold;left:2px;right:auto;top:0;bottom:auto}
/* emotes window */
#w-emote{left:50%;top:80px;transform:translateX(-50%);width:min(460px,96vw)}
#emote-list{display:grid;grid-template-columns:repeat(auto-fill,minmax(130px,1fr));gap:5px}
#emote-list button{padding:7px 6px;font-size:12px}
#emote-list button .ei{display:inline-block;width:1.5em;margin-right:4px;text-align:center}
/* GM: inventory of a player */
#w-gminv{left:50%;top:70px;transform:translateX(-50%);width:min(520px,96vw);max-height:calc(var(--vh,100vh) - 160px);overflow:auto}
#gminv-list h4{margin:8px 0 4px;color:#e8c070;font-size:12px}
#gminv-list .gmi{display:flex;align-items:center;gap:8px;padding:3px 4px;border-bottom:1px solid #3a3020}
#gminv-list .gmi .nm{flex:1;font-size:12px}#gminv-list .gmi small{color:#998;font-size:11px}
#gminv-list .gmi button{padding:2px 8px;color:#f88}
#packmenu{width:min(380px,94vw);box-sizing:border-box}#packmenu .pkh{cursor:move;touch-action:none}
/* Killer / Hero names */
.lbl .pkname{color:#ff4a3a!important;text-shadow:0 0 6px #ff2a1a88,0 1px 2px #000}
.lbl .heroname{color:#ffd860!important;text-shadow:0 0 8px #ffc03099,0 1px 2px #000}
/* Events window */
#w-events{left:50%;top:12%;transform:translateX(-50%);width:min(440px,96vw);max-height:calc(var(--vh,100vh) - var(--barh) - 20px);display:flex;flex-direction:column}
#w-events .pad{display:flex;flex-direction:column;min-height:0;overflow:hidden}
#w-events .evtabs{display:flex;gap:6px;margin-bottom:8px}
#w-events .evtabs button{flex:1;padding:6px 0;background:#1a140c;border:1px solid #5a4424;color:#cbb88e;font:600 12px Tahoma,sans-serif;border-radius:4px;cursor:pointer}
#w-events .evtabs button.on{background:linear-gradient(#6a4a18,#3a2810);color:#ffe7a8;border-color:#c89a40}
#ev-body{overflow-y:auto;min-height:120px;max-height:min(60vh,520px);-webkit-overflow-scrolling:touch}
#w-events .evlist{display:flex;flex-direction:column;gap:4px}
#w-events .evrow{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:6px 9px;background:#0e0b07cc;border:1px solid #3a2c18;border-radius:4px}
#w-events .evrow div{display:flex;flex-direction:column;min-width:0}
#w-events .evrow b{color:#f0dcae;font-size:12.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#w-events .evrow small{color:#9a8a6a;font-size:10.5px}
#w-events .evrow span{color:#cbb88e;font:12px Tahoma,sans-serif;white-space:nowrap;font-variant-numeric:tabular-nums}
#w-events .evrow.on{border-color:#3fae72;background:#0b1a10cc}#w-events .evrow.on span{color:#5fe09a;font-weight:bold}
#w-events .evrow.win b{color:#ffd860}
#w-events .evnote{margin-top:8px;color:#cbb88e;font-size:12px;text-align:center}
#w-events .evempty{color:#9a8a6a;text-align:center;padding:24px 8px}
body.mobile #w-events{width:min(440px,94vw);top:4px}
body.mobile #ev-body{max-height:calc(var(--vh,100vh) - 110px)}
#labels .lbl.npc .ghp{display:block;margin:2px auto 0;width:52px;height:4px;background:#300;border:1px solid #000;box-shadow:0 0 2px #000}
#labels .lbl.npc .ghp i{display:block;height:100%;width:100%;background:linear-gradient(#ff5040,#a01010)}
/* Events window: the rows always stack (the skin's generic window rules must not move them) */
#w-events #ev-body{position:relative!important;display:block!important}
#w-events #ev-body .evlist{position:static!important;display:flex!important;flex-direction:column!important;width:100%!important;height:auto!important}
#w-events #ev-body .evrow{position:static!important;display:flex!important;width:auto!important;height:auto!important;min-height:0!important;margin:0!important;left:auto!important;top:auto!important;transform:none!important;box-sizing:border-box;border-image:none!important;box-shadow:none!important}
#w-events #ev-body .evrow > div{position:static!important;display:flex!important;flex-direction:column!important;background:none!important;border:0!important;padding:0!important;width:auto!important;height:auto!important;box-shadow:none!important;border-image:none!important}
#w-events .evrow small.evwin{color:#ffd860;font-size:11px;margin-top:2px}

#sc-load.artwait{visibility:hidden} /* until the loading picture is there */
/* Inventory pages: two buttons over the bag; drag an item onto a button to move it to that page. */
#inv-pages{display:flex;gap:4px;width:256px;max-width:calc(100% - 24px);box-sizing:border-box;margin:6px auto 0}
#inv-pages button{position:relative;flex:1 1 0;min-width:0;min-height:26px;padding:2px 6px;background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6b5228;border-radius:4px;color:#e8d9b5;font:bold 12px Arial;text-align:center;cursor:pointer}
#inv-pages button .pgc{position:absolute;right:5px;top:3px;font:10px/1 Arial;color:#e8d9b5;opacity:.55;pointer-events:none}
#inv-pages button:hover,#inv-pages button:focus-visible{border-color:#ffd27a;color:#fff;outline:2px solid #ffd27a;outline-offset:1px}
#inv-pages button.on,#inv-pages button[aria-pressed="true"]{background:linear-gradient(#6b5228,#3a2a18);border-color:#ffd27a;color:#fff}
#inv-pages button.on .pgc,#inv-pages button[aria-pressed="true"] .pgc{opacity:.8}
#inv-pages button:disabled{opacity:.45;cursor:not-allowed}
@media (pointer:coarse){#inv-pages button{min-height:40px}}
/* Personal Store windows and [Store] label */
#w-pstore{right:310px;top:36px;width:296px;z-index:19}
#w-pstore .pad{padding:8px 10px}
#w-pstore .pst-name{display:block;font-size:11px;color:#ccc;margin-bottom:6px}
#w-pstore .pst-name input,#w-pstore .pst-form input,#w-pstore .pst-detail input{width:100%;box-sizing:border-box;background:#000;border:1px solid #5a4020;color:#fff;padding:4px 6px;font:12px Arial;border-radius:3px}
#w-pstore .pst-grid{position:relative;margin:0 auto;background-color:#0b0b0b;background-image:linear-gradient(#2c2c2c 1px,transparent 1px),linear-gradient(90deg,#2c2c2c 1px,transparent 1px);background-size:32px 32px;outline:1px solid #555;max-width:100%}
#w-pstore .pst-item{cursor:pointer}
#w-pstore .pst-item.selected,#w-pstore .pst-item:focus-visible{outline:2px solid #ffd27a;outline-offset:-2px}
#w-pstore .pst-item .pprice{position:absolute;right:1px;bottom:0;font-size:9px;color:#ffd27a;background:#000a;padding:0 2px;border-radius:2px;pointer-events:none}
#w-pstore .pst-item .lv{position:absolute;left:1px;top:0;font-size:10px;color:#fff;text-shadow:0 0 2px #000}
#w-pstore .pst-item .q{position:absolute;left:1px;bottom:0;font-size:10px;color:#9fe;text-shadow:0 0 2px #000}
#w-pstore .pst-empty{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;color:#8a7a5a;font-size:12px;text-align:center;padding:4px}
#w-pstore .pst-detail{margin:8px 0;min-height:56px;display:flex;flex-direction:column;gap:6px;font-size:12px;color:#e8d9b5}
#w-pstore .pst-price{color:#ffd27a;font-weight:bold}
#w-pstore button{min-height:28px;padding:3px 10px;background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6b5228;border-radius:4px;color:#e8d9b5;font-size:12px;cursor:pointer}
#w-pstore button:hover:not(:disabled),#w-pstore button:focus-visible{border-color:#ffd27a;color:#fff}
#w-pstore button:disabled{opacity:.45;cursor:not-allowed}
#w-pstore .pst-btns{display:flex;gap:6px}
#w-pstore .pst-status{min-height:16px;font-size:11px;color:#9fe}
#labels .lbl .pstore{display:block;color:#ffd27a;font-size:11px;cursor:pointer;pointer-events:auto;text-shadow:0 0 3px #000}
#labels .lbl .pstore:hover,#labels .lbl .pstore:focus-visible{color:#fff;text-decoration:underline;outline:none}
@media (max-width:560px){#w-pstore{right:0;left:0;margin:0 auto;width:calc(100vw - 8px);max-width:296px;top:48px}}
@media (pointer:coarse){#w-pstore button{min-height:40px}#w-pstore .pst-item{min-width:32px}}

.reset-overlay{position:fixed;inset:0;z-index:60;display:flex;align-items:center;justify-content:center;background:#0007;padding:8px;box-sizing:border-box}
.reset-dialog{position:relative!important;left:auto!important;right:auto!important;top:auto!important;transform:none!important;width:min(360px,100%);max-width:100%;box-sizing:border-box;display:block!important}
.reset-dialog .pad{padding:12px 14px;font-size:13px;color:#e8d9b5;text-align:center}
.reset-dialog p{margin:0 0 8px;line-height:1.45;overflow-wrap:anywhere}
.reset-dialog .rq{font-weight:bold;color:#ffd27a}
.reset-dialog .rmap{font-size:12px;color:#b8a77c}
.reset-dialog .rmsg{min-height:0;color:#ff8a70}
.reset-dialog .rbtns{display:flex;gap:10px;justify-content:center;margin-top:10px}
.reset-dialog .rbtns button{min-width:84px;min-height:32px;padding:4px 14px;background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6b5228;border-radius:4px;color:#e8d9b5;font-size:13px;cursor:pointer}
.reset-dialog .rbtns button:hover:not(:disabled),.reset-dialog .rbtns button:focus-visible{border-color:#ffd27a;color:#fff;outline:2px solid #ffd27a;outline-offset:1px}
.reset-dialog .rbtns button:disabled{opacity:.5;cursor:wait}
.rst small{display:block}
/* Personal store: "Put in your store" dialog, price blocks, buy confirmation */
.pst-overlay{position:fixed;inset:0;z-index:70;display:flex;align-items:center;justify-content:center;background:#0007;padding:8px;box-sizing:border-box}
.pst-put{position:relative!important;left:auto!important;right:auto!important;top:auto!important;transform:none!important;display:block!important;width:min(440px,100%);max-height:calc(100vh - 16px);overflow:auto;box-sizing:border-box}
.pst-put .pad{padding:10px 12px;font-size:12px;color:#e8d9b5}
.pst-put-item{display:flex;gap:10px;align-items:flex-start;margin-bottom:8px}
.pst-put-pic{position:relative!important;left:auto!important;top:auto!important;background-size:contain;background-repeat:no-repeat;background-position:center;cursor:help;border:1px solid #3a2a14;flex:none}
.pst-put-name{font-weight:bold}.pst-put-name.exc{color:#5f5}.pst-put-name.anc{color:#6cf}.pst-put-name.lv{color:#ffd27a}
.pst-sec{margin:8px 0 4px;color:#ffd27a;font-weight:bold}
.pst-field,.pst-put label{display:block}
.pst-put input[type=number],.pst-put input[type=search]{background:#000;border:1px solid #5a4020;color:#fff;padding:3px 6px;font:12px Arial;border-radius:3px;box-sizing:border-box}
.pst-field input{width:100%;margin-top:3px}
.pst-jewels{display:grid;grid-template-columns:repeat(5,1fr);gap:6px}
.pst-jewel{display:flex;flex-direction:column;align-items:center;gap:3px}.pst-jewel input{width:100%;text-align:center}
.sti{display:inline-block;width:24px;height:24px;background-size:contain;background-repeat:no-repeat;background-position:center;flex:none;vertical-align:middle}
.pst-search{width:100%}
.pst-results{display:flex;flex-direction:column;gap:2px;max-height:150px;overflow:auto;margin-top:3px}
.pst-hit,.pst-want button{background:linear-gradient(#3a2a18,#1a120a);border:1px solid #6b5228;border-radius:3px;color:#e8d9b5;cursor:pointer;text-align:left;font-size:12px;padding:3px 6px;display:flex;gap:6px;align-items:center}
.pst-hit:hover,.pst-hit:focus-visible,.pst-want button:hover,.pst-want button:focus-visible{border-color:#ffd27a;color:#fff}
.pst-wants{display:flex;flex-direction:column;gap:4px;margin:6px 0}
.pst-want{display:flex;flex-wrap:wrap;gap:6px;align-items:center;padding:3px;border:1px solid #3a2a14}.pst-want .nm{flex:1 1 120px}.pst-want input[type=number]{width:56px}
.pst-reason{color:#ff8a70;font-size:12px;min-height:0}
.pst-terms{display:flex;flex-direction:column;gap:2px}.pst-terms .stp{display:flex;align-items:center;gap:4px;color:#ffd27a}.pst-terms .stp.want{color:#9fe}
.pst-give{font-size:12px;color:#9fe;display:flex;flex-direction:column;gap:1px}
.pst-confirm{color:#ffd27a;font-weight:bold}
@media (max-width:420px){.pst-jewels{grid-template-columns:repeat(3,1fr)}}
/* U310-M (.294): Where do I find it? */
.q .qwhere{margin:4px 6px 0 0;background:#24384d;border-color:#4d7aa3;color:#cfe6ff}
.qguide{margin-top:6px;padding:6px 8px;background:#0007;border:1px solid #4d6a85;border-radius:5px;font-size:12px;line-height:1.5;text-align:left}
.qguide .qg{margin:3px 0}.qguide .qg small{color:#9ab}
body.mobile .qguide{font-size:13px}


@media (orientation:portrait){
 body.mobile #hud :is(#w-quest,#w-move,#w-guild,#w-opt,#w-cmd,#w-events,#w-friends,#w-store,#w-helper,#w-bug,#w-ach,#w-daily,#w-guide,#w-emote,#w-skill){
  height:auto!important;overflow-y:auto!important;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;top:calc(6px + env(safe-area-inset-top))!important;bottom:auto!important}
}
@media (orientation:landscape){
 body.mobile #hud :is(#w-quest,#w-move,#w-guild,#w-opt,#w-cmd,#w-events,#w-friends,#w-store,#w-helper,#w-bug,#w-ach,#w-daily,#w-guide,#w-emote,#w-skill){
  height:auto!important;overflow-y:auto!important;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;top:4px!important;bottom:auto!important}
}
/* the scroll bar of these windows: wide enough for a finger, gold like the frame */
body.mobile #hud .win::-webkit-scrollbar{width:10px}
body.mobile #hud .win::-webkit-scrollbar-thumb{background:#7a5a28;border-radius:5px}
body.mobile #hud .win::-webkit-scrollbar-track{background:#0006}
/* U310 .304: Quests / Vault / Save are no longer in the menu (quests and the vault at their NPCs, the game saves by itself) */
#w-menu button[hidden]{display:none!important}
#charinfo{background:linear-gradient(90deg,#000b,#0008 80%,transparent);padding:3px 18px 4px 8px;border-radius:6px;text-shadow:0 0 2px #000,0 1px 2px #000,0 0 6px #000;color:#f3e6c8}
#charinfo b{color:#ffe7a0}
#pethud div{background:linear-gradient(90deg,#000c,#0009 80%,transparent);padding:3px 16px 3px 8px;border-radius:6px;text-shadow:0 0 2px #000,0 1px 2px #000,0 0 6px #000}
#pethud small{color:#f0dca8}
#target .tbar{position:relative;height:13px}
#thpt{position:absolute;inset:0;font:bold 10px/13px Tahoma,sans-serif;color:#fff;text-shadow:0 0 2px #000,0 0 2px #000;white-space:nowrap}
#labels .lbl.mon .mlv{font-weight:normal;color:#c8c8a0;font-size:9px}
body.mobile #target{top:calc(8px + env(safe-area-inset-top) + 42px * var(--mz,1));min-width:180px;z-index:5}
body.mobile:has(#gmbadge:not([hidden])) #target{top:calc(32px + env(safe-area-inset-top) + 42px * var(--mz,1))}
body.mobile #tname{font-size:12px}
body:not(.mobile) #hud :is(#w-quest,#w-move,#w-guild,#w-opt,#w-cmd,#w-events,#w-friends,#w-store,#w-helper,#w-bug,#w-ach,#w-daily,#w-guide,#w-emote,#w-skill){height:auto!important;bottom:auto!important;overflow-y:auto!important;overscroll-behavior:contain}
body:not(.mobile) #hud .win::-webkit-scrollbar{width:8px}
body:not(.mobile) #hud .win::-webkit-scrollbar-thumb{background:#7a5a28;border-radius:4px}
body:not(.mobile) #hud .win::-webkit-scrollbar-track{background:#0006}

#topbar button{position:relative}#topbar .tbdot{position:absolute;top:2px;right:3px;width:10px;height:10px;border-radius:50%;background:#ff3a2a;border:1px solid #fff;box-shadow:0 0 6px #ff3a2a;animation:tbdot 1.2s ease-in-out infinite}@keyframes tbdot{50%{transform:scale(1.25)}}
