/* Touch tablets: layout only. Input gain, release timing and game rules stay intact.
   This layer is declared before controls183 so its important tablet sizes win. */
@layer tablet193 {
 @media (min-width:600px) and (min-height:600px) and (pointer:coarse) {
  body.royal-theme[data-screen=lobby] #lobby {
   width:100%!important;max-width:1440px!important;padding:12px 24px max(12px,env(safe-area-inset-bottom))!important;gap:12px!important;
  }
  body.royal-theme #lobby .profile183 {height:68px!important;min-height:68px!important;flex-basis:68px!important;padding-left:76px!important}
  body.royal-theme #lobby #profileOpen {height:68px!important;min-height:68px!important;background-size:52px 52px!important;background-position:10px center!important;display:flex!important;align-items:center!important;justify-content:flex-start!important;padding-left:24px!important;rotate:0deg!important;transform:none!important}
  body.royal-theme #lobby .royal-player h1 {font-size:24px!important;max-width:none!important}
  body.royal-theme #lobby .lobby-xp,body.royal-theme #lobby .lobby-xp>b,body.royal-theme #lobby .lobby-xp>span {font-size:11px!important}
  body.royal-theme #lobby .lobby-xp>div {height:5px!important;max-width:160px!important;width:140px!important}
  body.royal-theme #lobby .lobby-grid {grid-template-columns:minmax(0,1fr)!important;grid-template-rows:minmax(0,1fr) 68px!important;gap:12px!important}
  body.royal-theme #lobby .showcase81 {padding:24px!important}
  body.royal-theme #lobby .welcome86 {padding-right:90px!important}
  body.royal-theme #lobby .welcome86 h2 {font-size:clamp(34px,3.6vw,48px)!important;line-height:1.08!important}
  body.royal-theme #lobby .lobby-play {display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1.4fr)!important;align-self:stretch!important;align-items:stretch!important;gap:14px!important;padding:0!important}
  body.royal-theme #lobby #matchConfigure183,body.royal-theme #lobby #homePlay {height:68px!important;min-height:68px!important;min-width:0!important;margin:0!important}
  body.royal-theme #lobby #homePlay {font-size:clamp(18px,2.1vw,26px)!important}
  body.royal-theme #lobby #matchConfigure183 b {font-size:15px!important;white-space:normal!important}
  body.royal-theme #lobby #matchConfigure183 small {font-size:10px!important}
  body.royal-theme #lobby .bottom-nav {max-width:none!important;width:100%!important;height:68px!important;min-height:68px!important;flex-basis:68px!important;grid-template-columns:repeat(3,minmax(0,1fr))!important}
  body.royal-theme #lobby .bottom-nav button {height:60px!important;min-height:60px!important;font-size:13px!important;gap:6px!important}
  body.royal-theme #lobby .bottom-nav button[data-ui-icon]::before {width:26px!important;height:26px!important}
  body.royal-theme #lobby .showcase81 #storeOpen144,body.royal-theme #lobby .showcase81 #eventsOpen155 {width:66px!important;height:66px!important;min-height:66px!important;right:18px!important;top:18px!important}
  body.royal-theme #lobby .showcase81 #eventsOpen155 {top:94px!important}
  body.royal-theme #lobby #storeOpen144 svg,body.royal-theme #lobby #eventsOpen155 svg {width:30px!important;height:30px!important}
  body.royal-theme #lobby #storeOpen144 span,body.royal-theme #lobby #eventsOpen155 span {font-size:10px!important}
  body.royal-theme #lobby .loadout183 {left:24px!important;right:auto!important;bottom:20px!important;width:min(520px,calc(100% - 48px))!important;padding:12px 16px!important;box-sizing:border-box!important}
  body.royal-theme #lobby .loadout183>span {font-size:10px!important}
  body.royal-theme #lobby .loadout183>b {font-size:15px!important}

  body.royal-theme[data-screen=game] #gameScreen {max-width:none!important}
  body.royal-theme[data-screen=game] .arena {--tablet-round193:84px}
  body.royal-theme[data-screen=game] .arena:has(#summaryBar134:not([hidden])) {--tablet-round193:116px}
  body.royal-theme[data-screen=game] #roundBoard104 {position:relative!important;inset:auto!important;transform:none!important;margin:6px 10px!important;width:calc(100% - 20px)!important;height:calc(var(--tablet-round193) - 12px)!important;max-width:none!important;min-height:0!important;grid-template-columns:1fr 1.35fr 1fr!important}
  body.royal-theme[data-screen=game] #roundBoard104 strong {font-size:34px!important}
  body.royal-theme[data-screen=game] .round-side104>span {font-size:13px!important}
  body.royal-theme[data-screen=game] .round-title104 b {font-size:11px!important;line-height:1.4!important}
  body.royal-theme[data-screen=game] .controls .turn {inset:12px 12px auto!important;width:auto!important;min-height:28px!important;justify-content:center!important;align-items:center!important;gap:8px!important}
  body.royal-theme[data-screen=game] .controls .turn b {font-size:17px!important;line-height:1.3!important}
  body.royal-theme[data-screen=game] #joy92 {width:160px!important;height:160px!important;left:calc(50% + 22px)!important;top:calc(50% - 72px)!important;transform:translateX(-50%)!important}
  body.royal-theme[data-screen=game] #joy92>i {width:54px!important;height:54px!important}
  body.royal-theme[data-screen=game] #joy92::after {font-size:11px!important;bottom:13px!important}
  body.royal-theme[data-screen=game] #release92 {left:calc(50% - 116px)!important;right:auto!important;top:calc(50% - 72px)!important;width:38px!important;height:160px!important;transform:none!important}
  body.royal-theme.left-handed[data-screen=game] #joy92 {left:calc(50% - 22px)!important}
  body.royal-theme.left-handed[data-screen=game] #release92 {left:calc(50% + 78px)!important}
  body.royal-theme[data-screen=game] #release92 .power,body.royal-theme[data-screen=game] #release92 #meter115 {width:38px!important;height:160px!important}
  body.royal-theme[data-screen=game] #release92 #powerRead98 {top:auto!important;bottom:-24px!important;left:50%!important;right:auto!important;width:max-content!important;max-width:74px!important;transform:translateX(-50%)!important;font-size:10px!important;line-height:1.2!important;text-align:center!important}
  body.royal-theme[data-screen=game] .tactics-panel {padding:8px 12px!important;height:42px!important}
  body.royal-theme[data-screen=game] .tactics-panel b,body.royal-theme[data-screen=game] #tacticsRound {font-size:12px!important}
  body.royal-theme[data-screen=game] .tactics {height:76px!important;padding:6px 10px 10px!important}
  body.royal-theme[data-screen=game] .shot-options {width:100%!important;gap:6px!important}
  body.royal-theme[data-screen=game] .shot-options button {height:58px!important;min-height:58px!important;font-size:13px!important;white-space:normal!important;line-height:1.2!important;padding:6px 4px!important}
  body.royal-theme[data-screen=game] .table-toolbar {top:10px!important;left:10px!important;right:10px!important}
  body.royal-theme[data-screen=game] .table-toolbar button {height:44px!important;min-height:44px!important;font-size:12px!important;padding:8px 12px!important}
  body.royal-theme[data-screen=game] #tableMenu {width:44px!important;font-size:0!important}
  body.royal-theme[data-screen=game] #tableHome {padding-left:32px!important}
  body.royal-theme[data-screen=game] .camera-controls {top:66px!important;right:10px!important;bottom:auto!important;gap:6px!important}
  body.royal-theme[data-screen=game] .camera-controls button {height:44px!important;min-height:44px!important;font-size:12px!important;padding:8px 12px!important}
 }
 @media (min-width:600px) and (min-height:600px) and (pointer:coarse) and (orientation:landscape) {
  body.royal-theme[data-screen=game] .arena {grid-template-columns:minmax(0,1fr) clamp(300px,28vw,360px)!important;grid-template-rows:148px var(--tablet-round193) minmax(216px,1fr) 42px 76px!important}
  body.royal-theme[data-screen=game] .stage {grid-area:1/1/6/2!important}
  body.royal-theme[data-screen=game] .scoreboard {grid-area:1/2!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;grid-template-rows:34px minmax(0,1fr)!important;gap:6px 8px!important;height:148px!important;padding:8px 10px!important}
  body.royal-theme[data-screen=game] .scoreboard .round {grid-area:1/1/2/3!important;display:flex!important;justify-content:center!important;align-items:center!important;gap:12px!important;min-width:0!important;padding:5px 10px!important}
  body.royal-theme[data-screen=game] .scoreboard .round>small,body.royal-theme[data-screen=game] #goal47 {font-size:10px!important}
  body.royal-theme[data-screen=game] #round {font-size:21px!important}
  body.royal-theme[data-screen=game] #turnClock {font-size:16px!important;margin-left:auto!important}
  body.royal-theme[data-screen=game] #player0 {grid-area:2/1!important}
  body.royal-theme[data-screen=game] #player1 {grid-area:2/2!important}
  body.royal-theme[data-screen=game] .scoreboard .player {height:100%!important;box-sizing:border-box!important;min-width:0!important;padding:5px!important;align-content:center!important;gap:2px!important}
  body.royal-theme[data-screen=game] .scoreboard .player>div:not(.points94) b {display:block!important;font-size:13px!important;line-height:1.2!important;white-space:normal!important;overflow-wrap:anywhere!important}
  body.royal-theme[data-screen=game] .scoreboard :is(#name0,#opponent) {display:block!important;max-width:100%!important;white-space:normal!important;overflow-wrap:anywhere!important}
  body.royal-theme[data-screen=game] .scoreboard .points94>span {font-size:9px!important}
  body.royal-theme[data-screen=game] .scoreboard .points94 strong {font-size:32px!important}
  body.royal-theme[data-screen=game] #roundBoard104 {grid-area:2/2!important}
  body.royal-theme[data-screen=game]:not(.match-ended79) .controls {grid-area:3/2!important;height:100%!important;min-height:0!important;overflow:hidden!important}
  body.royal-theme[data-screen=game] .tactics-panel {grid-area:4/2!important}
  body.royal-theme[data-screen=game] .tactics {grid-area:5/2!important}
 }
 @media (min-width:600px) and (min-height:600px) and (pointer:coarse) and (orientation:portrait) {
  body.royal-theme[data-screen=game] .arena {grid-template-columns:minmax(0,1fr)!important;grid-template-rows:104px var(--tablet-round193) minmax(0,1fr) 232px 42px 76px!important}
  body.royal-theme[data-screen=game] .scoreboard {grid-area:1/1!important;height:104px!important;padding:6px 12px!important}
  body.royal-theme[data-screen=game] .scoreboard .player>div:not(.points94) b {font-size:16px!important;white-space:normal!important}
  body.royal-theme[data-screen=game] .scoreboard .points94 strong {font-size:34px!important}
  body.royal-theme[data-screen=game] #roundBoard104 {grid-area:2/1!important}
  body.royal-theme[data-screen=game] .stage {grid-area:3/1!important}
  body.royal-theme[data-screen=game]:not(.match-ended79) .controls {grid-area:4/1!important;height:232px!important;min-height:0!important;overflow:hidden!important}
  body.royal-theme[data-screen=game] .controls .turn {top:4px!important}
  body.royal-theme[data-screen=game] .tactics-panel {grid-area:5/1!important}
  body.royal-theme[data-screen=game] .tactics {grid-area:6/1!important}
 }
 @media (min-width:600px) and (min-height:600px) and (max-height:899px) and (pointer:coarse) and (orientation:portrait) {
  body.royal-theme[data-screen=game] .arena {--tablet-round193:68px;grid-template-rows:86px var(--tablet-round193) minmax(0,1fr) 190px 36px 66px!important}
  body.royal-theme[data-screen=game] .scoreboard {height:86px!important}
  body.royal-theme[data-screen=game]:not(.match-ended79) .controls {height:190px!important}
  body.royal-theme[data-screen=game] #joy92 {width:128px!important;height:128px!important;top:38px!important}
  body.royal-theme[data-screen=game] #release92 {left:calc(50% - 96px)!important;top:38px!important;height:128px!important}
  body.royal-theme.left-handed[data-screen=game] #release92 {left:calc(50% + 58px)!important}
  body.royal-theme[data-screen=game] #release92 .power,body.royal-theme[data-screen=game] #release92 #meter115 {height:128px!important}
  body.royal-theme[data-screen=game] .tactics-panel {height:36px!important}
  body.royal-theme[data-screen=game] .tactics {height:66px!important}
  body.royal-theme[data-screen=game] .shot-options button {height:48px!important;min-height:48px!important}
 }
}
