/* UI4 · Rune forge material. Layout and gameplay remain owned by their original files.
   Repeated #stage gives the material layer priority over legacy theme paints. */
:root{
  --k-ink:#ece6da;--k-muted:#b6afa3;--k-amber:#ffc46b;--k-rune:#46c9d6;
  --k-rad:#6cd48f;--k-dire:#ef897a;--k-display:'FG Display',sans-serif;--k-body:'FG Body',sans-serif;
  --k-grain:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' opacity='.055' filter='url(%23n)'/%3E%3C/svg%3E");
  --k-face:linear-gradient(180deg,#303740,#1c222a);--k-rim:linear-gradient(145deg,#7b8691,#343c47 55%,#697481);
  --k-button-shadow:inset 0 1px #ffffff2b,inset 0 -3px #0007,0 2px 0 #050608,0 6px 14px #0006;
  --k-panel-shadow:inset 0 0 0 1px var(--edge,#414c58),inset 0 2px #ffffff15,inset 0 -22px 32px #0004,0 9px 24px #0007;
  --k-ease:cubic-bezier(.16,1,.3,1);
}
#stage{--font:var(--k-body);--title:var(--k-display);font-variant-numeric:tabular-nums;caret-color:var(--k-amber)}
#stage ::selection{background:#805719;color:#fff3d9}
#stage :is(input,textarea)::placeholder{color:var(--k-muted);opacity:1}
#stage *{scrollbar-width:thin;scrollbar-color:#8c7857 #11151a}
#stage ::-webkit-scrollbar{width:9px;height:9px}
#stage ::-webkit-scrollbar-track{background:#11151a}
#stage ::-webkit-scrollbar-thumb{background:#766345;border:2px solid #11151a;border-radius:4px}
#stage#stage#stage :is(.k-btn,.Btn,.lb button,button[data-act],button[data-mt],.sm-actions button,button[data-pg],button[data-sh],button[data-go],button[data-pgemo],.pg-quick button,.pg-chips button,.cw-i,button[data-setpos],button[data-setlane],button[data-move],button[data-pgline],button[data-lang],:where(#FastFwd,#ADLog,#SettingsButton),.AudioBtn){
  position:relative;isolation:isolate;border:2px solid transparent;border-radius:6px;
  background:var(--k-face) padding-box,var(--k-rim) border-box;color:var(--k-ink);
  box-shadow:var(--k-button-shadow);font-family:var(--k-display);font-weight:600;
  letter-spacing:.35px;clip-path:none;filter:none;backdrop-filter:none;
  transition:transform 100ms var(--k-ease);text-shadow:none;cursor:pointer;
}
#stage#stage#stage :is(.k-btn,.Btn,button[data-act],button[data-mt],.sm-actions button,button[data-pg],button[data-sh],button[data-go],.pg-quick button,.pg-chips button,button[data-setpos],button[data-setlane],button[data-lang])::after{
  content:'';position:absolute;inset:1px;border-radius:4px;pointer-events:none;
  background:linear-gradient(105deg,transparent 35%,#fff3 49%,transparent 63%);opacity:0;
  transform:translateX(-70%);z-index:1;
}
#stage#stage#stage :is(.k-btn.primary,.Btn.green,.btn-primary,button[data-mt].on,button[data-mt="report"],button[data-act="lockPos"],button[data-act="toMatch"],button[data-act="new"]){
  --k-face:linear-gradient(180deg,#ffc267,#e38a1f);--k-rim:linear-gradient(145deg,#ffe4b3,#965118 65%,#ffbe63);color:#211407;
}
#stage#stage#stage :is(.k-btn.rune,button[data-act="analyze"],button[data-act="sim"],button[data-act="refAll"]){
  --k-face:linear-gradient(#1d373e,#102229);--k-rim:linear-gradient(145deg,#7ddee8,#205663);color:#c9f6fa;
}
#stage#stage#stage .lb button.on{--k-face:linear-gradient(#3a3329,#211f1d);--k-rim:linear-gradient(145deg,#d7b575,#775b33);color:#ffe1a3}
#stage#stage#stage :is(.k-btn.danger,.Btn.red,button[data-act="clear"],button[data-sh="delAcc"]){
  --k-face:linear-gradient(#442a2c,#25191e);--k-rim:linear-gradient(145deg,#cf8a83,#613c41);color:#ffd0c5;
}
#stage#stage#stage :is(.k-btn.ghost,.btn-ghost,.sm-actions button:not([data-act="new"]),button[data-act="home"],button[data-act="back"],button[data-pg="leave"]){
  --k-face:linear-gradient(#20262e,#141a21);--k-rim:linear-gradient(145deg,#616d79,#303b45);box-shadow:inset 0 1px #ffffff13,inset 0 -2px #0004,0 2px 6px #0004;
}
#stage#stage#stage :is(.k-btn.sm,.mt-top .ctl button){padding:7px 14px;min-height:42px;font-size:19px}
#stage#stage#stage :is(.k-btn.icon,#SettingsButton,.AudioBtn){min-width:46px;min-height:46px}
#stage#stage#stage :is(button,.Btn,.cw-i,.Tile):focus-visible{outline:3px solid #ffe1a3;outline-offset:4px;box-shadow:0 3px 12px #0009,inset 0 0 0 2px #ffe1a3}
#stage#stage#stage :is(button,.Btn,.cw-i):active:not(:disabled){transform:translateY(2px);box-shadow:inset 0 2px 5px #0009,inset 0 1px #fff2,0 1px 2px #0006}
#stage#stage#stage :is(button,.Btn):disabled{color:#b6afa3;--k-face:linear-gradient(#242a31,#191e24);--k-rim:linear-gradient(#4c5560,#323b45);box-shadow:inset 0 1px #fff1;cursor:default;filter:none;opacity:1}
@media(hover:hover){
  #stage#stage#stage :is(.k-btn,.Btn,button[data-act],button[data-mt],button[data-pg],button[data-sh],button[data-go],button[data-setpos],button[data-setlane]):hover:not(:disabled){box-shadow:inset 0 1px #ffffff4d,inset 0 -3px #0007,0 2px 0 #050608,0 7px 16px #0008,0 0 0 1px var(--k-amber)}
  #stage#stage#stage :is(.k-btn,.Btn,button[data-act],button[data-mt],button[data-pg],button[data-sh],button[data-go]):hover:not(:disabled)::after{animation:k-sheen 420ms var(--k-ease)}
}
/* Arrow rim and recessed face are separate layers, leaving the native button intact. */
#stage#stage#stage :is(.k-cta,button.play.btn-primary,button[data-act="toMatch"],button[data-act="lockPos"]){
  --k-rim:linear-gradient(150deg,#ffe8bf,#dc983d 50%,#874610);background:var(--k-rim);
  border:0;border-radius:0;clip-path:polygon(0 0,calc(100% - 24px) 0,100% 50%,calc(100% - 24px) 100%,0 100%);
  min-height:64px;padding:14px 39px 14px 24px;filter:drop-shadow(0 5px 8px #0007);color:#211407;
}
#stage#stage#stage :is(.k-cta,button.play.btn-primary,button[data-act="toMatch"],button[data-act="lockPos"])::before{
  content:'';position:absolute;inset:2px;z-index:-1;background:linear-gradient(#ffc267,#e38a1f);
  clip-path:polygon(0 0,calc(100% - 22px) 0,100% 50%,calc(100% - 22px) 100%,0 100%);box-shadow:inset 0 1px #fff7,inset 0 -4px #70380c66;
}
#stage#stage#stage :is(.k-cta,button.play.btn-primary,button[data-act="toMatch"],button[data-act="lockPos"])::after{inset:0;animation:k-cta-sheen 3.2s ease-out infinite}
/* Carved tab tracks. Existing .on state stays authoritative. */
#stage#stage#stage :is(.k-tabs,.stabs,.sm-tabs,.lib-tabs,.lb-opt,.sh-nav,.lg-lang){padding:4px;gap:4px;background:#080d12;border:1px solid #313b45;border-radius:8px;box-shadow:inset 0 2px 6px #000b,inset 0 -1px #ffffff0c}
#stage#stage#stage :is([data-stab],[data-smtab],[data-lib],.lib-tabs button,.sh-nav button){position:relative;border:1px solid transparent;border-radius:4px;box-shadow:none;background:transparent;color:var(--k-muted);font-family:var(--k-display)}
#stage#stage#stage :is([data-stab].on,[data-smtab].on,[data-lib].on,.lib-tabs button.on,.sh-nav button.on){background:linear-gradient(#303741,#1c222a);border-color:#5d6671;color:var(--k-amber);box-shadow:inset 0 1px #fff2,inset 0 -2px #ffbc57,0 3px 8px #0008}
/* Default steel/stone, focal bronze, then faction variants. */
#stage#stage#stage :is(.k-panel,.sh-team,.sh-sel,.sh-shop,.mt-team,.mt-feed,.mt-bot,.mt-end .box,.sm-wrap,.report-banner,.panel,.pf-card,.lg-panel,.lobby-main,.lobby-side,.lib-panel,#PostChat.show){
  --edge:#414c58;--accent:var(--k-amber);border:1px solid #090c10;border-radius:0;
  background-image:var(--k-grain),linear-gradient(180deg,#242b33,#151a21);box-shadow:var(--k-panel-shadow);
}
#stage#stage#stage :is(.k-panel.feat,.sh-sel,.report-banner,.mt-end .box,.panel-emphasis){
  --edge:#9b733d;--accent:var(--k-amber);background-image:var(--k-grain),radial-gradient(ellipse at 30% 0,#aa753625,transparent 65%),linear-gradient(#2a2928,#171a20);
  box-shadow:var(--k-panel-shadow),inset 0 1px #ffdaa149,0 12px 30px #0008;
}
#stage#stage#stage :is(.k-panel.rad,.mt-team.R){--edge:#387451;--accent:var(--k-rad)}
#stage#stage#stage :is(.k-panel.dire,.mt-team.D){--edge:#87453c;--accent:var(--k-dire)}
#stage#stage#stage :is(.k-panel,.sh-team,.sh-sel,.sh-shop,.report-banner,.mt-end .box,.panel,.pf-card,.lg-panel){clip-path:polygon(0 0,calc(100% - 18px) 0,100% 18px,100% 100%,18px 100%,0 calc(100% - 18px))}
#stage#stage#stage :is(.k-panel,.sh-team,.sh-sel,.sh-shop,.panel,.pf-card,.lg-panel){position:relative}
#stage#stage#stage :is(.k-panel,.sh-team,.sh-sel,.sh-shop)::before,
#stage#stage#stage :is(.k-panel,.sh-team,.sh-sel,.sh-shop)::after{
  content:'';position:absolute;width:27px;height:3px;background:var(--accent);pointer-events:none;opacity:.8;z-index:1;
}
#stage#stage#stage :is(.k-panel,.sh-team,.sh-sel,.sh-shop)::before{top:8px;right:-5px;transform:rotate(45deg)}
#stage#stage#stage :is(.k-panel,.sh-team,.sh-sel,.sh-shop)::after{bottom:8px;left:-5px;transform:rotate(45deg)}
#stage#stage#stage :is(.lb,.lib-box,.cl-box,.st-wrap){--edge:#414c58;background-image:var(--k-grain),linear-gradient(#242b33,#151a21);border:1px solid #090c10;box-shadow:var(--k-panel-shadow)}
/* Continuous steps: finished -> active -> upcoming. */
#stage#stage#stage #Shop .stages{gap:0;padding:4px;background:#090d13;border:1px solid #39414a;box-shadow:inset 0 2px 7px #0009;border-radius:6px}
#stage#stage#stage #Shop .stages span{margin:0;border:0;background:transparent;color:var(--k-muted);clip-path:polygon(0 0,calc(100% - 14px) 0,100% 50%,calc(100% - 14px) 100%,0 100%,14px 50%);padding-left:24px;padding-right:26px}
#stage#stage#stage #Shop .stages span:first-child{clip-path:polygon(0 0,calc(100% - 14px) 0,100% 50%,calc(100% - 14px) 100%,0 100%);padding-left:16px}
#stage#stage#stage #Shop .stages span.done{background:linear-gradient(#243e30,#182820);color:#a9e3ba}
#stage#stage#stage #Shop .stages span.on{background:linear-gradient(#654923,#372819);color:#ffe1a3;box-shadow:inset 0 1px #f5cc7966,inset 0 -2px #f9b851}
/* Compact shop: the photograph is the card; price occupies its own dark corner. */
#stage#stage#stage :is(.k-item,.sh-shop .it[data-buy]){position:relative;display:block;min-height:0;overflow:hidden;border:2px solid transparent;border-radius:3px;background:linear-gradient(#171e26,#0c1117) padding-box,linear-gradient(145deg,#81929f,#344654) border-box;box-shadow:inset 0 1px #fff2,0 3px 7px #0007;filter:none;backdrop-filter:none;touch-action:pan-x pan-y;transition:transform 120ms var(--k-ease)}
#stage#stage#stage :is(.k-item.t2,.sh-shop .it.u3-cost-mid){background:linear-gradient(#15252b,#0c171f) padding-box,linear-gradient(145deg,#80e4ea,#225767) border-box;box-shadow:inset 0 1px #b6fdff55,0 3px 7px #0007}
#stage#stage#stage :is(.k-item.t3,.sh-shop .it.u3-cost-high){background:linear-gradient(#2a241c,#14151b) padding-box,linear-gradient(145deg,#ffe0a1,#956027) border-box;box-shadow:inset 0 1px #ffe8b855,0 3px 7px #0007}
#stage#stage#stage .sh-shop .it img{display:block;width:100%;height:auto;aspect-ratio:4/3;object-fit:cover;filter:none}
#stage#stage#stage .sh-shop .it .item-name{position:absolute;inset:0 0 auto;display:block;padding:4px 5px;min-height:0;height:auto;font:500 13px/1.55 var(--k-body);color:var(--k-ink);background:#080e17eb;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;opacity:0;pointer-events:none}
#stage#stage#stage .sh-shop .it .c{position:absolute;left:auto;right:0;bottom:0;display:flex;width:auto;min-height:0;gap:3px;padding:2px 5px;border:0;background:#080d15ed;color:var(--k-amber);font:600 17px/1.35 var(--k-display);box-shadow:inset 1px 1px #b9a47855}
#stage#stage#stage .sh-shop .it .c .ui-icon{width:14px;height:14px}
#stage#stage#stage .sh-shop .it.no{opacity:1;border-style:dashed;filter:none}
#stage#stage#stage .sh-shop .it.no img{filter:none;opacity:.5}
#stage#stage#stage .sh-shop .it.tap2{opacity:1;border-color:#ffe1a3;animation:k-tap 700ms ease-in-out infinite}
#stage#stage#stage .sh-shop .it.tap2 .item-name{opacity:1}
#stage#stage#stage .sh-shop .it.tap2::after{content:'Chạm lần nữa để mua';position:absolute;left:0;right:0;top:32px;padding:4px;background:#372310f5;color:#ffe1a3;z-index:3;font:600 14px/1.35 var(--k-display);box-shadow:none;filter:none}
#stage#stage#stage .sh-shop .col{padding:10px 5px;background:#10171f;border:1px solid #394552;box-shadow:inset 0 2px 5px #0006}
#stage#stage#stage .sh-shop .col h5{min-height:40px;margin-bottom:8px}
#stage#stage#stage .sh-shop .ci{gap:8px}
@media(hover:hover){
  #stage#stage#stage .sh-shop .it:hover:not(.no){transform:translateY(-2px);box-shadow:inset 0 1px #fff5,0 6px 12px #0009}
  #stage#stage#stage .sh-shop .it:hover .item-name{opacity:1}
}
#stage#stage#stage #Shop .slots.big .sl.empty{border:1px dashed #7a8793;background:#0e141d;box-shadow:inset 0 2px 7px #0007}
#stage#stage#stage #Shop .fg-band{position:relative;background:linear-gradient(#171f28,#111822);border-color:#4c5969;box-shadow:inset 0 1px #ffffff0e}
#stage#stage#stage #Shop .fg-band.on{border-color:#d6a65f;background:linear-gradient(#30271c,#1b1d23);box-shadow:inset 0 1px #ffe1a333,0 0 0 1px #eaaa5040}
#stage#stage#stage #Shop .fg-band.on::after{content:'';position:absolute;inset:0 auto auto 0;width:45%;height:2px;pointer-events:none;background:linear-gradient(90deg,transparent,#ffe2a5,transparent);animation:k-band-gleam 380ms var(--k-ease)}
#stage#stage#stage #Shop .fb-add{border:1px dashed #8995a0;background:#101720;box-shadow:inset 0 2px 6px #0005;color:var(--k-muted)}
#stage#stage#stage #Shop .u3-axis{border-bottom:1px solid #827251;color:#d6c8b1}
#stage#stage#stage #Shop .fb-its{background-image:linear-gradient(90deg,#8a785623 1px,transparent 1px);background-size:calc(100% / 15) 100%}
/* Meter consumes existing percentages only. No new probability calculation. */
#stage#stage#stage .k-meter{position:relative;width:100%;height:14px;margin-top:14px;border:1px solid #435763;border-radius:4px;background:#070e15;box-shadow:inset 0 2px 6px #000c;min-height:0}
#stage#stage#stage .k-meter .k-fill{display:block;height:100%;width:calc(var(--k-value,0) * 1%);background:linear-gradient(#68e4e9,#2295ac);box-shadow:inset 0 1px #fff7;transform-origin:left;animation:k-meter-in 350ms var(--k-ease)}
#stage#stage#stage .k-meter .k-best{position:absolute;top:-4px;bottom:-4px;left:calc(var(--k-best,0) * 1%);width:3px;background:#ffc46b;box-shadow:0 1px 5px #0008}
#stage#stage#stage .k-meter .k-ticks{position:absolute;inset:17px 0 auto;display:flex;justify-content:space-between;font:500 12px/1.4 var(--k-display);color:var(--k-muted);min-height:0}
#stage#stage#stage .k-meter .k-ticks i{font-style:normal}
/* Alive faces retain their native colour. An empty countdown is not a death state. */
#stage#stage#stage #Match .mt-row .pt{border:1px solid #5b9c76;box-shadow:inset 0 1px #fff3,0 3px 7px #0008}
#stage#stage#stage #Match .mt-team.D .pt{border-color:#c27769}
#stage#stage#stage #Match .mt-row:not(.isdead) .pt img{filter:none;opacity:1}
#stage#stage#stage #Match .mt-row .dead:empty{display:none}
#stage#stage#stage #Match .mt-row.isdead .pt img{filter:none;opacity:.35}
#stage#stage#stage #Match .mt-row.isdead .dead{display:grid;background:#19111d7a;border:1px solid #c58376;color:#fff2e7}
#stage#stage#stage #Match .mt-feed #feed>div{position:relative;animation:k-feed-enter 180ms var(--k-ease);filter:none;backdrop-filter:none}
#stage#stage#stage #Match #feed>div:has(.u3-first-blood){background:linear-gradient(90deg,#62331f,#1f2028);box-shadow:inset 3px 0 #ffc46b}
#stage#stage#stage #Match #feed>.k-roshan{background:linear-gradient(90deg,#373244,#1b202a);box-shadow:inset 3px 0 #c3a5e0}
#stage#stage#stage #Match #feed>.k-tower{background:linear-gradient(90deg,#153a40,#1b202a);box-shadow:inset 3px 0 #68d7df}
#stage#stage#stage #Match .mt-bot .gw{flex:0 0 auto}
#stage#stage#stage #Match .mt-bot svg{height:113px}
#stage#stage#stage #Match .mt-bot{gap:5px;padding:14px 18px}
#stage#stage#stage #Match .mt-bot h4{margin-bottom:5px}
#stage#stage#stage #Match .mt-bot .tbar{margin-top:6px}
#stage#stage#stage #Match .mt-end .box .big{animation:k-result 320ms var(--k-ease)}
#stage#stage#stage #Match .mt-end .box{position:relative;overflow:hidden}
#stage#stage#stage #Match .mt-end .box::after{content:'';position:absolute;inset:0;pointer-events:none;background:linear-gradient(105deg,transparent 35%,#ffe1a325 49%,transparent 64%);animation:k-sheen 850ms var(--k-ease)}
/* Report hierarchy: focal forecast, compact supporting evidence, one primary action. */
#stage#stage#stage #Summary .report-banner{min-height:184px;--edge:#6c9b78;background-image:var(--k-grain),radial-gradient(ellipse at 10% 0,#87cf8f28,transparent 65%),linear-gradient(#29392e,#151e25);box-shadow:var(--k-panel-shadow),inset 0 1px #cbe8b33d,0 12px 30px #0008}
#stage#stage#stage #Summary .report-banner.loss{--edge:#b07462;background-image:var(--k-grain),radial-gradient(ellipse at 10% 0,#d87b5333,transparent 65%),linear-gradient(#3c2b28,#171b23)}
#stage#stage#stage #Summary .report-banner .result{animation:k-result 320ms var(--k-ease)}
#stage#stage#stage #Summary .report-banner::after{content:'';inset:0;width:auto;height:auto;border:0;transform:none;pointer-events:none;background:linear-gradient(105deg,transparent 35%,#ffe1a322 49%,transparent 64%);animation:k-sheen 850ms var(--k-ease)}
#stage#stage#stage #Summary .u3-stat-grid{grid-template-columns:1.7fr repeat(5,minmax(0,1fr))}
#stage#stage#stage #Summary .u3-stat{padding:14px 12px;border:0;background:linear-gradient(#1e2730,#161e27);box-shadow:inset 0 1px #fff1,inset 0 -1px #0008}
#stage#stage#stage #Summary .u3-stat:first-child{padding:16px 18px 34px;background:linear-gradient(#1d363e,#14252e);box-shadow:inset 0 1px #7cdde044,inset 0 0 0 1px #416773}
#stage#stage#stage #Summary .u3-stat:first-child>b{font-size:42px}
#stage#stage#stage #Summary .u3-stat .k-meter span{min-height:0}
#stage#stage#stage #PostChat.show{bottom:auto;min-height:570px;max-height:calc(100% - 48px)}
#stage#stage#stage #PostChat #PgLog{flex:0 1 auto;min-height:160px;max-height:330px;overflow:auto}
#stage#stage#stage #PostChat .pg-emo{order:3;margin:0;padding-top:10px}
#stage#stage#stage #PostChat .pg-in{order:4}
#stage#stage#stage #PostChat .pg-chips{order:5}
#stage#stage#stage #PostChat .pg-quick{order:2}
#stage#stage#stage #PostChat .pg-emo button{background:linear-gradient(#393026,#201c1a) padding-box,linear-gradient(145deg,#b3935f,#594128) border-box}
/* Decorative feedback only; never changes a gameplay field. */
#stage .k-enter{animation:k-panel-enter 280ms var(--k-ease) both;animation-delay:var(--k-delay,0ms)}
#stage .k-forged{position:relative}
#stage .k-forged::after{content:'';position:absolute;inset:0;pointer-events:none;background:#ffe1a3;animation:k-forge 300ms ease-out both;z-index:4}
#stage .k-count-host{position:relative}
#stage .k-count-host{color:transparent!important}
#stage#stage#stage .k-count{position:absolute;inset:0;min-height:0;pointer-events:none;color:var(--k-count-color,var(--k-rune));font:inherit;letter-spacing:inherit;white-space:nowrap}
#stage#stage#stage :is(#SettingsButton,.AudioBtn){position:absolute}
@keyframes k-sheen{0%{transform:translateX(-75%);opacity:0}25%{opacity:.8}100%{transform:translateX(75%);opacity:0}}
@keyframes k-cta-sheen{0%,65%{transform:translateX(-85%);opacity:0}72%{opacity:.8}87%,100%{transform:translateX(85%);opacity:0}}
@keyframes k-panel-enter{from{transform:translateY(7px);opacity:.78}to{transform:translateY(0);opacity:1}}
@keyframes k-feed-enter{from{transform:translateX(12px);opacity:.6}to{transform:translateX(0);opacity:1}}
@keyframes k-result{from{transform:scale(.96);opacity:.7}to{transform:scale(1);opacity:1}}
@keyframes k-meter-in{from{transform:scaleX(0)}to{transform:scaleX(1)}}
@keyframes k-band-gleam{from{transform:translateX(0);opacity:.7}to{transform:translateX(125%);opacity:0}}
@keyframes k-forge{from{opacity:.65}to{opacity:0}}
@keyframes k-tap{0%,100%{transform:translateY(0)}50%{transform:translateY(-2px)}}
html.touch #stage#stage#stage :is(button,.Btn,.cw-i){min-width:64px;min-height:64px;font-size:24px}
html.touch #stage#stage#stage :is(.k-btn.icon,#SettingsButton,.AudioBtn){min-width:64px}
html.touch #stage#stage#stage .sh-shop .it .item-name{opacity:1;font-size:20px;line-height:1.35;padding:2px 4px;background:linear-gradient(#080e17eb,#080e17b8)}
html.touch #stage#stage#stage .sh-shop .it .c{font-size:23px;line-height:1.3;min-height:0;padding:1px 4px}
html.touch #stage#stage#stage .sh-shop .it .c .ui-icon{width:23px;height:23px}
html.touch #stage#stage#stage .sh-shop .it[data-buy]{width:116px;max-width:100%;justify-self:center}
html.touch #stage#stage#stage .sh-shop .it.tap2::after{font-size:20px;top:33px}
html.touch #stage#stage#stage #Summary .u3-stat:first-child>b{font-size:50px}
html.touch #stage#stage#stage .k-meter .k-ticks{font-size:20px;top:18px}
html.touch #stage#stage#stage #Summary .u3-stat:first-child{padding-bottom:44px}
html.touch #stage#stage#stage #Summary .report-banner{min-height:220px}
html.touch #stage#stage#stage #PostChat.show{min-height:660px}
html.touch #stage#stage#stage #PostChat #PgLog{min-height:150px;max-height:290px}
html.touch #stage#stage#stage #Match .mt-bot svg{height:94px}
/* Wide landscape keeps the existing three-column lobby with independent scrolling. */
html.touch.wide #stage#stage#stage .ui-lobby-grid{grid-template-columns:460px minmax(0,1fr) 570px;overflow:visible;align-items:stretch}
html.touch.wide #stage#stage#stage :is(.ui-lobby-left,.ui-lobby-right){display:flex;grid-column:auto;overflow:auto;min-height:0}
html.touch.wide #stage#stage#stage .ui-lobby-center{min-height:0;overflow:auto}
html.touch.wide #stage#stage#stage .ui-lobby-grid .panel{padding:22px}
html.touch.wide #stage#stage#stage .ui-hero-showcase .pcard{height:300px}
html.touch.wide #stage#stage#stage .panel-head h3{font:600 28px/1.4 var(--k-display)}
html.touch.wide #stage#stage#stage :is(.ui-quest-row,.ui-quest-row b,.ui-weekly-line,.ui-rank-row,.ui-rank-row b,.ui-rank-row strong,.ui-feat-heroes span){font-size:23px}
/* Readability coverage beyond the three UI3 screens. */
html.touch #stage#stage#stage :is(.lib-note,.lib-list td,.lib-list td span,.lib-list td b,.lib-list th,.lb-style button span,.panel-head h3,.ui-display-kicker,.ttl,.medal,.medal span,.adm,.adp,.pill,.sh-brand,.ui-showcase-name p,.RoundMarker,.seat-label,.HeroContainer .YouLabel,.sgp,.TypeLabel .info,.TypeLabel .i,.PlayerName .dim){font-size:20px;line-height:1.4}
html.touch #stage#stage#stage :is(.TypeLabel i,.mn-top .brand,.mn-top .badge,.ui-showcase-name p b,.lb small,.lb-head span,.lb .sub,.lb .PlanTag,.lb-times span,.lb-timers span,.lb-timer span,.lb label>span){font-size:20px;line-height:1.4}
html.touch #stage#stage#stage :is(.ui-brand .brand,.ui-topbar .badge){font-size:20px;line-height:1.4}
html.touch #stage#stage#stage .lb-opt>span{font-size:20px!important;color:var(--k-muted)!important;line-height:1.4}
html.touch #stage#stage#stage .HeroContainer .PlanTag{font-size:20px!important;line-height:1.4!important}
html.touch #stage#stage#stage .HeroContainer .PlayerName{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
html.touch #stage#stage#stage .lib-list td{padding:14px 12px}
html.touch #stage#stage#stage .lib-note{line-height:1.55;margin:12px 0}
html.touch #stage#stage#stage .mt-top .ctl{gap:8px}
#stage#stage#stage .lib-list th{font:600 17px/1.5 var(--k-display);text-align:left;color:var(--k-amber);padding:12px;border-bottom:1px solid #6d725e;background:#17222b}
#stage#stage#stage .lib-list th:not(:first-child){text-align:right;white-space:nowrap}
#stage#stage#stage :is(.lib-note,.lb-note){color:var(--k-muted)!important}
html.touch #stage#stage#stage .lobby-brand>span{font-size:20px;line-height:1.4}
@media(prefers-reduced-motion:reduce){
  #stage#stage#stage *,#stage#stage#stage *::before,#stage#stage#stage *::after{animation:none!important;transition:none!important;scroll-behavior:auto!important}
}
