/* ===== responsive-v1: device-aware layout layer (load LAST) =====
   Tiers: xs<360 | s 360-389 | m 390-429 | l 430-599 | tablet 600-1023 | laptop 1024-1439
          desktop 1440-1919 | tv/FHD 1920-2559 | 4k >=2560. Plus landscape-phone + touch/TV-remote rules. */
:root{--cw:150px;--cwd:290px;--gmin:140px;--gap:14px;--mcw:136px;--hh:64px;--mpad:16px;--bfs:16px;--tap:44px}
html{-webkit-text-size-adjust:100%;text-size-adjust:100%;overflow-x:clip;scroll-padding-top:calc(var(--hh) + 8px)}
body{overflow-x:clip;font-size:var(--bfs);padding-top:var(--hh)!important;min-height:100vh;min-height:100dvh;-webkit-tap-highlight-color:transparent}
img,video,canvas,svg{max-width:100%}
/* avatar decorations are 120% of the avatar, centred on it: the global max-width above must not cap them */
img.dsv,.dw>.dsv{max-width:none!important;max-height:none!important;left:-10%!important;top:-10%!important;width:120%!important;height:120%!important;margin:0!important}
header{height:var(--hh)!important;padding-left:max(var(--mpad),env(safe-area-inset-left))!important;padding-right:max(var(--mpad),env(safe-area-inset-right))!important;padding-top:env(safe-area-inset-top,0px)}
main{padding-left:max(var(--mpad),env(safe-area-inset-left))!important;padding-right:max(var(--mpad),env(safe-area-inset-right))!important}
main:not(.mu){padding-bottom:calc(96px + env(safe-area-inset-bottom,0px))!important}
.card{width:var(--cw)!important}.card.wd{width:var(--cwd)!important}
.grid{grid-template-columns:repeat(auto-fill,minmax(var(--gmin),1fr))!important;gap:var(--gap)!important}
.grid .card{width:auto!important}
.mu-card,.mu-skc{width:var(--mcw)!important}
.pop,.spc,.dlc,.cpk-sh{max-height:calc(100dvh - 24px);overflow-y:auto;overscroll-behavior:contain}
p,h1,h2,h3,.mt{overflow-wrap:anywhere}
input,select,textarea{font-size:max(16px,1em)} /* stops iOS zoom-on-focus */
@supports(height:100dvh){.hx{max-height:calc(100dvh - var(--hh) - 20px)}}

/* ---- phones ---- */
@media(max-width:359px){
 :root{--cw:122px;--cwd:236px;--gmin:112px;--gap:10px;--mcw:116px;--mpad:10px;--hh:56px}
 .logo{font-size:22px!important}.hr{gap:2px!important}.ib{width:34px!important;height:34px!important}
 .langb{padding:0 6px!important}
 #cnav a,#cnav .cdots{width:38px!important;height:38px!important}#cnav a.act{width:46px!important}
 .hx .hx-bt .btn{font-size:13px!important}
}
@media(min-width:360px) and (max-width:389px){:root{--cw:134px;--cwd:256px;--gmin:122px;--gap:12px;--mcw:128px;--mpad:12px;--hh:60px}}
@media(min-width:390px) and (max-width:429px){:root{--cw:146px;--cwd:276px;--gmin:134px;--mcw:140px;--mpad:14px}}
@media(min-width:430px) and (max-width:599px){:root{--cw:158px;--cwd:300px;--gmin:146px;--gap:16px;--mcw:150px;--mpad:16px}}
/* big phones + small tablets, portrait */
@media(min-width:600px) and (max-width:1023px){
 :root{--cw:176px;--cwd:330px;--gmin:164px;--gap:18px;--mcw:164px;--mpad:22px;--hh:64px;--bfs:16.5px}
 #cnav{bottom:calc(14px + env(safe-area-inset-bottom,0px))}
 #cnav a,#cnav .cdots{width:52px!important;height:42px!important}#cnav a.act{width:62px!important}
 .spc,.dlc{max-width:440px}
}
/* landscape phones / very short screens */
@media(orientation:landscape) and (max-height:520px){
 :root{--hh:48px;--mpad:max(14px,env(safe-area-inset-left))}
 .logo{font-size:21px!important}
 .ib{width:34px!important;height:34px!important}
 .hx{height:calc(100dvh - 64px)!important;min-height:260px!important;max-height:none}
 .hx .hx-c{padding-bottom:56px!important;gap:6px!important}.hx .hx-d{display:none!important}
 #cnav{bottom:calc(4px + env(safe-area-inset-bottom,0px))}
 #cnav a,#cnav .cdots{height:32px!important;width:42px!important}
 .pop,.spc,.dlc{max-height:calc(100dvh - 12px)}
 .mu-stage{max-width:min(240px,42vh)!important}
 #sp,#dlp{align-items:center!important}
}

/* ---- laptops ---- */
@media(min-width:1024px){
 :root{--cw:190px;--cwd:340px;--gmin:178px;--gap:20px;--mcw:170px;--mpad:28px;--hh:68px}
 main:not(.mu){max-width:min(1500px,95vw)!important}
 main.mu{max-width:min(1500px,96vw)!important;margin:0 auto!important;padding-left:var(--mpad)!important;padding-right:var(--mpad)!important}
 .mu-cv{width:200px!important;height:200px!important}
 .mu-stage{max-width:min(460px,52vh)!important}
 .mu-meta,.mu-seek,.mu-vol,.mu-acts2,.mu-lyr,.mu-q{max-width:520px!important}
 .wcx-h,.wcx-seg,.wcx-list,.wcx-rep,.wcx-comp,.wcx-pk,.wcx-signin-bar,.wcx-tabs{max-width:780px}
 .spc{max-width:420px}.dlc{max-width:430px}
 a,button,.card{transition-property:transform,background-color,color,opacity,filter,box-shadow}
}
@media(hover:hover) and (pointer:fine){.card:hover .pw{transform:translateY(-3px);transition:transform .2s}}
@media(min-width:1280px){:root{--cw:204px;--gmin:192px;--mcw:182px}}

/* ---- desktops ---- */
@media(min-width:1440px){
 :root{--cw:216px;--cwd:380px;--gmin:204px;--gap:22px;--mcw:196px;--mpad:36px;--bfs:17px}
 main:not(.mu){max-width:min(1720px,94vw)!important}
 main.mu{max-width:min(1720px,95vw)!important}
 .mu-stage{max-width:min(520px,56vh)!important}
 .wcx-h,.wcx-seg,.wcx-list,.wcx-rep,.wcx-comp,.wcx-pk,.wcx-signin-bar,.wcx-tabs{max-width:860px}
}
@media(min-width:1700px){:root{--cw:232px;--cwd:410px;--gmin:220px;--mcw:210px;--mpad:44px}main:not(.mu){max-width:min(1900px,94vw)!important}main.mu{max-width:min(1900px,95vw)!important}}

/* ---- TV / FHD+ ---- */
@media(min-width:1920px){
 :root{--cw:256px;--cwd:460px;--gmin:244px;--gap:28px;--mcw:236px;--hh:84px;--mpad:56px;--bfs:19px;--tap:56px}
 main:not(.mu){max-width:min(2200px,94vw)!important}
 main.mu{max-width:min(2200px,95vw)!important}
 .logo{font-size:36px!important}
 .ib{width:52px!important;height:52px!important}.ib .i,.ib svg{width:26px;height:26px}
 .langb{height:48px!important;font-size:17px!important;padding:0 14px!important}
 .card h3,.mt{font-size:1.06em}
 .btn{min-height:var(--tap);font-size:18px;padding-left:28px;padding-right:28px}
 #cnav{bottom:32px}
 #cnav a,#cnav .cdots{width:70px!important;height:54px!important}#cnav a.act{width:84px!important}#cnav a .i{width:28px!important;height:28px!important}
 .mu-s{top:calc(var(--hh) - 8px)!important}
 .mu-stage{max-width:min(620px,58vh)!important}
 .mu-meta,.mu-seek,.mu-vol,.mu-acts2,.mu-lyr,.mu-q{max-width:640px!important}
 .mu-lyl{font-size:22px!important}
 .spc{max-width:520px}.dlc{max-width:520px}.cpk-sh{max-width:520px}
 .wcx-h,.wcx-seg,.wcx-list,.wcx-rep,.wcx-comp,.wcx-pk,.wcx-signin-bar,.wcx-tabs{max-width:1000px}
 .wcx-col{font-size:1.08em}
 :focus-visible{outline-width:4px!important;outline-offset:4px!important}
}
@media(min-width:2560px){
 :root{--cw:310px;--cwd:560px;--gmin:290px;--gap:36px;--mcw:280px;--hh:104px;--mpad:72px;--bfs:23px;--tap:68px}
 main:not(.mu){max-width:min(2800px,94vw)!important}main.mu{max-width:min(2800px,95vw)!important}
 .logo{font-size:44px!important}.ib{width:64px!important;height:64px!important}
 #cnav a,#cnav .cdots{width:86px!important;height:66px!important}#cnav a.act{width:104px!important}
 .mu-stage{max-width:min(760px,60vh)!important}
 .wcx-h,.wcx-seg,.wcx-list,.wcx-rep,.wcx-comp,.wcx-pk,.wcx-signin-bar,.wcx-tabs{max-width:1200px}
}
/* TV browsers: remote-control focus (set by device-class.js) */
html[data-dev=tv] :focus-visible{outline:4px solid var(--acc,#fff)!important;outline-offset:4px!important;border-radius:12px}
html[data-dev=tv] .card:focus-visible{transform:scale(1.06)}
html[data-dev=tv]{cursor:none}
/* touch: comfortable targets, no sticky hover */
@media(pointer:coarse){.ib,.cbtn,.langb{min-width:40px;min-height:40px}.btn{min-height:44px}}
@media(hover:none){.card:hover .pw{transform:none}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}}
