:root{font-family:Inter,"Segoe UI",Arial,sans-serif;color:#eef1ee;background:#1e1510;font-synthesis:none}
*{box-sizing:border-box}
html{min-height:100%}
body{margin:0;min-width:320px;min-height:100vh;background:radial-gradient(ellipse 70% 58% at 50% 36%,#53392750,transparent 78%),repeating-linear-gradient(90deg,#ffffff06 0 2px,transparent 3px 107px,#08050460 108px 110px,transparent 112px 220px),linear-gradient(120deg,#291b13,#1e1510 58%,#120d09)}
body:before{content:"";position:fixed;inset:0;pointer-events:none;background:repeating-linear-gradient(0deg,transparent 0 4px,#c79c6910 5px,transparent 6px 13px);opacity:.55}
button,input{font:inherit}button{cursor:pointer}button:disabled{opacity:.4;cursor:not-allowed}
button:focus-visible,input:focus-visible,#spinPad:focus-visible{outline:2px solid #e7d7b7;outline-offset:3px}
.app{position:relative;max-width:1600px;margin:auto;padding:26px clamp(14px,2.8vw,44px) 38px}
.topbar{min-height:65px;display:flex;align-items:center;justify-content:space-between;gap:14px;margin-bottom:25px;padding-bottom:17px;border-bottom:1px solid #5c686530}
.brand{display:flex;align-items:center;gap:15px}
.brand-ball{display:grid;place-items:center;width:48px;height:48px;flex:none;border:2px solid #e7e7df;border-radius:50%;background:radial-gradient(circle at 34% 24%,#444c4d,#0c1012 62%);color:#f5f3e9;font-size:21px;font-weight:900;box-shadow:inset -4px -6px 9px #0009,0 0 0 5px #293539}
.brand strong{display:block;font-size:20px;letter-spacing:.18em;line-height:1.1;font-weight:800;color:#f4f1e9}
.brand small{display:block;margin-top:6px;color:#9da9a7;font-size:11px;letter-spacing:.12em;text-transform:uppercase}
.top-actions{display:flex;gap:10px}
.ghost,.secondary{border:1px solid #4b595a;background:linear-gradient(#263135,#1b2528);color:#e8eeeb;border-radius:9px;padding:10px 15px;transition:background .18s,border-color .18s,transform .18s}
.ghost:hover,.secondary:hover{background:#344348;border-color:#80908e;transform:translateY(-1px)}
.text-button{border:0;background:transparent;color:#d2d9d3;padding:4px;font-size:12px;white-space:nowrap}
.text-button:hover{color:#fff;text-decoration:underline}
.game-layout{display:grid;grid-template-columns:minmax(0,1fr) 318px;align-items:start;gap:28px}
.board-column{min-width:0}
.scorebar{display:grid;grid-template-columns:minmax(0,1fr) minmax(156px,.8fr) minmax(0,1fr);align-items:center;gap:12px;margin-bottom:17px}
.player{display:flex;align-items:center;gap:11px;min-width:0;min-height:63px;padding:9px 14px;border:1px solid #394649;border-radius:11px;background:linear-gradient(135deg,#1f2a2d,#151e21);opacity:.64;box-shadow:inset 0 1px #ffffff0b}
.player.active{opacity:1;border-color:#b9c4bd;box-shadow:0 0 0 1px #a9b4a733,inset 0 1px #ffffff16}
.player:last-child{flex-direction:row-reverse;text-align:right}
.avatar{display:grid;place-items:center;width:38px;height:38px;flex:none;border:2px solid #aebbb7;border-radius:50%;background:radial-gradient(circle at 35% 30%,#6e7a7a,#212b2f 65%);color:#fff;font-weight:800;box-shadow:inset -2px -3px 5px #0006}
.player strong,.player small{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis}
.player strong{font-size:15px}.player small{margin-top:2px;font-size:11px;color:#a9b5b2}
.turn-dot{width:7px;height:7px;margin-left:auto;border-radius:50%;background:#d2dbc9;box-shadow:0 0 9px #d5e2c1;opacity:0;flex:none}
.player:last-child .turn-dot{margin:0 auto 0 0}.player.active .turn-dot{opacity:1}
.score-centre{text-align:center;min-width:0}
.score-centre span{display:block;color:#b7a888;font-size:10px;font-weight:800;letter-spacing:.24em}
.score-centre strong{display:block;margin-top:5px;color:#e8eeeb;font-size:15px;line-height:1.28}
.table-wrap{position:relative;width:100%;padding:9px;border:1px solid #435054;border-radius:25px;background:linear-gradient(145deg,#303b3d,#0c1316 42%,#242f31);box-shadow:0 8px 0 #05090b,0 22px 45px #0009,inset 0 1px #adb9b849;touch-action:none}
.table-wrap:after{content:"";position:absolute;inset:8px;border-radius:17px;box-shadow:inset 0 0 0 1px #f6f8ed19;pointer-events:none}
.table-wrap canvas{display:block;width:100%;height:auto;border-radius:17px;cursor:crosshair;touch-action:none}
.mobile-dock{display:none}
.table-footer{display:flex;justify-content:space-between;gap:16px;align-items:center;padding:20px 4px 10px;color:#c4cfca;font-size:12px}
.table-footer #hint{display:flex;align-items:center;gap:10px}.table-footer #hint:before{content:"";width:6px;height:6px;flex:none;border-radius:50%;background:#dac196;box-shadow:0 0 10px #dcbf87}
.table-footer #ballsLeft{color:#9caeaa;white-space:nowrap}
.aim-legend{display:flex;flex-wrap:wrap;gap:8px 16px;margin:5px 0 0;padding:11px 14px;border:1px solid #374347;border-radius:9px;color:#b8c6c2;background:#111b1e;font-size:11px}
.aim-legend .legend-object{color:#ebcf86}
.controls{position:relative;overflow:hidden;padding:21px;border:1px solid #596568;border-radius:17px;background:linear-gradient(160deg,#253135 0,#1a2428 44%,#141d20 100%);box-shadow:0 18px 38px #0006,inset 0 1px #dce7e122}
.controls:before{content:"";position:absolute;inset:0 0 auto;height:4px;background:linear-gradient(90deg,#7d8984,#d4d7c7 48%,#7d8984)}
.control-heading,.spin-heading,.aim-heading{display:flex;justify-content:space-between;align-items:center;gap:8px}
.control-heading{padding-bottom:17px;margin-bottom:22px;border-bottom:1px solid #78868238}
.control-heading span{color:#f3f1e9;font-size:15px;font-weight:800;letter-spacing:.16em}
.aim-heading{margin:0 0 10px;color:#c8d2ce;font-size:10px;font-weight:800;letter-spacing:.16em}
.aim-heading .text-button{letter-spacing:0;font-weight:500}
.aim-buttons{display:grid;grid-template-columns:1fr 1fr;gap:9px}
.aim-buttons .secondary{margin:0;padding:12px 5px;font-size:12px;font-weight:700;color:#ecf1ea}
.aim-tip{min-height:30px;margin:9px 0 25px;color:#a1b1ad;font-size:11px;line-height:1.4}
.control-label{display:flex;justify-content:space-between;align-items:baseline;margin:0 0 13px;color:#e6ede7;font-size:14px;font-weight:600}
.control-label strong{color:#eed4a3;font-size:19px;font-variant-numeric:tabular-nums}
input[type=range]{appearance:none;width:100%;height:8px;margin:0;border:1px solid #7b8580;border-radius:99px;background:linear-gradient(90deg,#d6d7bf,#98b2ae 55%,#526267);cursor:pointer}
input[type=range]::-webkit-slider-thumb{appearance:none;width:21px;height:21px;border:4px solid #e9e9df;border-radius:50%;background:#314145;box-shadow:0 2px 8px #0009}
input[type=range]::-moz-range-thumb{width:14px;height:14px;border:4px solid #e9e9df;border-radius:50%;background:#314145;box-shadow:0 2px 8px #0009}
.range-ends{display:flex;justify-content:space-between;margin-top:10px;color:#9caeaa;font-size:10px}
.spin-heading{margin:29px 0 14px;padding-top:24px;border-top:1px solid #78868238;color:#e6ede7;font-size:14px;font-weight:600}
.spin-row{display:flex;align-items:center;gap:19px}
.spin-pad{position:relative;width:126px;height:126px;flex:none;border:4px solid #edf0e9;border-radius:50%;background:radial-gradient(circle at 34% 26%,#fff 2%,#f0f3f1 38%,#c2cccb 76%,#8f9b9c 100%);box-shadow:inset -9px -10px 14px #6b797840,inset 5px 4px 7px #fff,0 7px 17px #0008;cursor:crosshair;touch-action:none}
.spin-pad:after{content:"";position:absolute;inset:6px;border:1px solid #ffffff96;border-radius:50%;pointer-events:none}
.spin-cross{position:absolute;background:#788c8d99}.spin-cross-x{left:14%;top:50%;width:72%;height:1px}.spin-cross-y{left:50%;top:14%;height:72%;width:1px}
#spinDot{position:absolute;left:50%;top:50%;width:13px;height:13px;border:2px solid white;border-radius:50%;background:#dd3038;box-shadow:0 0 0 1px #941e27,0 2px 5px #0005;transform:translate(-50%,-50%)}
.spin-notes{display:grid;gap:8px;color:#b5c4bd;font-size:11px}
.spin-value{margin-top:10px;color:#d8eee7;font-size:12px;font-weight:700}
.primary,.secondary{width:100%;margin-top:11px}
.primary{border:1px solid #f2efdf;border-radius:9px;padding:15px 14px;background:linear-gradient(180deg,#f0ead6,#bfc9bf);box-shadow:inset 0 1px #fff,0 9px 18px #0005;color:#182123;font-weight:900;letter-spacing:.08em;transition:filter .18s,transform .18s}
.primary:hover{filter:brightness(1.08);transform:translateY(-1px)}
#shootBtn{margin-top:27px;font-size:16px}
#restartBtn{background:transparent;color:#ccd6d0}
.control-tip{margin:21px 0 0;padding-top:16px;border-top:1px solid #78868238;color:#9bacaa;font-size:11px;line-height:1.55}
.overlay{position:fixed;inset:0;z-index:10;display:grid;place-items:center;padding:18px;background:#080d0ee8;backdrop-filter:blur(12px)}.overlay.hidden{display:none}
.modal{position:relative;width:min(670px,100%);padding:clamp(25px,4vw,43px);border:1px solid #7c8985;border-radius:18px;background:linear-gradient(150deg,#2a373a,#192326 60%,#11191b);box-shadow:0 30px 95px #000d,inset 0 1px #eaf1e535}
.modal:before{content:"";position:absolute;top:0;left:28px;right:28px;height:2px;background:linear-gradient(90deg,transparent,#e1dbc7,transparent)}
.modal-kicker{color:#c6b592;font-size:11px;font-weight:800;letter-spacing:.22em}
.modal h1,.modal h2{margin:9px 0 13px;line-height:1.08;color:#f3f2e9}.modal h1{font-size:clamp(31px,5vw,44px)}.modal h2{font-size:31px}
.modal p,.modal li{color:#b9c8c2;line-height:1.55}
.mode-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:11px;margin-top:27px}
.mode-card{min-height:162px;padding:18px 15px;border:1px solid #52615e;border-radius:11px;background:linear-gradient(145deg,#29383a,#1c292c);color:#f4f3ec;text-align:left;transition:border-color .18s,transform .18s,background .18s}
.mode-card:hover,.mode-card:focus-visible{border-color:#e0d2b6;background:#334447;transform:translateY(-3px)}
.mode-icon{display:block;margin-bottom:14px;color:#dcc9a7;font-size:28px}.mode-card strong,.mode-card small{display:block}.mode-card strong{font-size:15px}.mode-card small{margin-top:7px;color:#abbbb4;font-size:11px;line-height:1.4}
.resume{width:100%;margin-top:17px}.disclosure{margin:18px 0 0!important;font-size:11px}
.help ol{padding-left:24px}.help li{margin:10px 0}.help .primary{max-width:190px}
.close{position:absolute;right:20px;top:14px;border:0;background:none;color:#fff;font-size:30px}.result .primary,.result .secondary{max-width:220px;margin-right:9px}
@media(max-width:1120px){.game-layout{grid-template-columns:minmax(0,1fr) 292px;gap:18px}.controls{padding:17px}.scorebar{gap:7px}.player{padding:8px}}
@media(max-width:970px){.game-layout{grid-template-columns:1fr}.controls{max-width:620px;width:100%;margin:0 auto}.table-wrap{max-width:100%}}
@media(max-width:640px){.app{padding:14px 9px 25px}.topbar{margin-bottom:17px;padding-bottom:12px}.brand{gap:10px}.brand-ball{width:36px;height:36px;font-size:16px;box-shadow:0 0 0 3px #293539}.brand strong{font-size:14px}.brand small{font-size:9px;letter-spacing:.04em}.top-actions{gap:5px}.top-actions button{padding:8px;font-size:10px}.scorebar{grid-template-columns:1fr 1fr;gap:7px}.score-centre{grid-column:1/-1;grid-row:1;padding:0 0 5px}.score-centre span{font-size:9px}.score-centre strong{font-size:13px}.player{min-height:46px;padding:5px 8px;gap:7px}.avatar{width:28px;height:28px;font-size:11px}.player strong{font-size:11px}.player small{font-size:9px}.table-wrap{padding:4px;border-radius:13px}.table-wrap canvas{border-radius:9px}.table-footer{padding:13px 2px 6px;font-size:10px}.aim-legend{font-size:10px;padding:9px}.controls{display:block;padding:17px}.control-heading,.control-tip{display:flex}.mode-grid{grid-template-columns:1fr;gap:8px}.mode-card{min-height:74px;padding:11px 14px}.mode-icon{display:inline;margin:0 8px 0 0;font-size:19px}.mode-card strong{display:inline}.mode-card small{margin:4px 0 0}}
@media(max-width:970px){
  .app{padding-bottom:168px}
  .mobile-dock{display:block;position:fixed;z-index:8;left:0;right:0;bottom:0;padding:9px max(10px,env(safe-area-inset-right)) calc(10px + env(safe-area-inset-bottom)) max(10px,env(safe-area-inset-left));background:linear-gradient(180deg,#263438f5,#10191dfb);border-top:1px solid #a5b5af85;box-shadow:0 -10px 28px #000a;touch-action:manipulation}
  .mobile-dock-top{display:flex;align-items:center;justify-content:space-between;gap:8px;color:#cbd8d2;font-size:12px;font-weight:700;margin-bottom:7px}
  .mobile-dock-top button{border:0;background:transparent;color:#9eeaf0;font-size:12px;font-weight:700;padding:3px 5px}
  .mobile-dock-actions{display:grid;grid-template-columns:48px 48px minmax(0,1fr) 76px;gap:8px;align-items:end}
  .mobile-dock-actions>button{height:48px;border:1px solid #758b8b;border-radius:10px;background:#263b40;color:#fff;font-size:24px;touch-action:manipulation}
  .mobile-dock-actions #mobileShoot{background:#e1e4d4;color:#14272a;font-size:15px;font-weight:900;border-color:#e5ebdc}
  .mobile-dock-actions button:disabled{opacity:.45}
  .mobile-power{align-self:center;min-width:0}
  .mobile-power label{display:flex;justify-content:space-between;color:#eef2e9;font-size:12px;margin-bottom:12px}
  .mobile-power strong{color:#f4d89a}
  #mobilePower{height:14px;touch-action:none}
  #mobilePower::-webkit-slider-thumb{width:30px;height:30px}
  .controls{margin-top:12px}
  .control-tip{display:none}
}
@media(max-width:420px){.mobile-dock-actions{grid-template-columns:42px 42px minmax(0,1fr) 68px;gap:5px}.mobile-dock-actions>button{height:44px}.mobile-dock-actions #mobileShoot{font-size:13px}.mobile-dock-top{font-size:11px}}
@media(max-width:970px) and (max-height:500px) and (orientation:landscape){
  .app{padding:5px 8px 128px}
  .topbar,.scorebar .player,.table-footer,.aim-legend{display:none}
  .scorebar{display:block;margin:0 0 4px}
  .score-centre{display:flex;justify-content:center;align-items:center;gap:10px;min-height:19px}
  .score-centre span,.score-centre strong{margin:0;font-size:11px}
  .table-wrap{width:min(100%,calc((100dvh - 150px)*1.85185));margin-inline:auto;padding:3px;border-radius:12px}
  .table-wrap canvas{border-radius:9px}
  .controls{margin-top:18px}
}
@media(prefers-reduced-motion:reduce){.ghost,.secondary,.primary,.mode-card{transition:none}}
.rotate-gate{display:none}
@media (pointer:coarse) and (orientation:portrait) and (max-width:1000px){
  .rotate-gate{position:fixed;z-index:30;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:30px;text-align:center;color:#f4f2e9;background:radial-gradient(circle at center,#334449,#101b1f 75%)}
  .rotate-icon{display:grid;place-items:center;width:90px;height:90px;margin-bottom:18px;border:3px solid #cad8d3;border-radius:24px;color:#cfe9e9;font-size:68px;line-height:1;transform:rotate(-35deg)}
  .rotate-gate h2{margin:0 0 10px;font-size:clamp(24px,7vw,36px)}
  .rotate-gate p{max-width:340px;color:#bfd0cd;font-size:16px;line-height:1.5}
}
@media (pointer:coarse) and (orientation:landscape) and (max-height:600px){
  html,body{width:100%;height:100%;overflow:hidden}
  .app{height:100dvh;max-width:none;padding:3px max(6px,env(safe-area-inset-right)) 0 max(6px,env(safe-area-inset-left));overflow:hidden}
  .topbar{height:31px;min-height:0;margin:0;padding:0;border:0}
  .brand{gap:7px}.brand-ball{width:25px;height:25px;font-size:12px;box-shadow:none}.brand strong{font-size:12px;letter-spacing:.1em}.brand small{display:none}
  .top-actions button{padding:3px 8px;font-size:11px}
  .game-layout{display:block;height:calc(100dvh - 34px)}
  .board-column{height:100%;display:flex;flex-direction:column;align-items:center}
  .scorebar{display:grid;grid-template-columns:1fr minmax(120px,1fr) 1fr;gap:5px;width:min(620px,calc(100vw - 190px));height:35px;margin:0 auto 3px}
  .scorebar .player{display:flex;min-height:31px;height:31px;padding:2px 7px;border-radius:7px}
  .scorebar .avatar{width:22px;height:22px;font-size:10px}.scorebar .player strong{font-size:11px}.scorebar .player small{display:none}
  .score-centre{grid-column:auto;grid-row:auto;display:block;padding:0}.score-centre span{font-size:8px}.score-centre strong{font-size:11px;margin-top:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
  .table-wrap{width:min(calc((100dvh - 79px)*1.85185),calc(100vw - 180px));max-width:none;margin:auto;padding:3px;border-radius:11px;box-shadow:0 4px 15px #000a;flex:none}
  .table-wrap canvas{width:100%;border-radius:8px}
  .table-footer,.aim-legend{display:none}
  .mobile-dock{display:block;position:fixed;inset:0;z-index:8;padding:0;background:none;border:0;box-shadow:none;pointer-events:none}
  .mobile-dock-top{display:block;margin:0}.mobile-dock-top span{display:none}
  .mobile-dock-top #mobileSpin{position:absolute;right:calc(8px + env(safe-area-inset-right));top:39px;width:74px;height:34px;padding:3px;border:1px solid #9ab6b3;border-radius:8px;background:#23373bdc;color:#e9f5ed;font-size:11px;pointer-events:auto}
  .mobile-dock-actions{display:contents}
  .mobile-power{position:absolute;left:calc(8px + env(safe-area-inset-left));top:56px;bottom:12px;display:flex;flex-direction:column;align-items:center;width:55px;pointer-events:auto}
  .mobile-power label{display:flex;flex-direction:column;align-items:center;gap:0;margin:0;font-size:10px}.mobile-power strong{font-size:12px}
  #mobilePower{writing-mode:vertical-lr;direction:rtl;appearance:slider-vertical;width:27px;height:100%;min-height:100px;margin:5px 0;touch-action:none}
  .mobile-dock-actions #mobileShoot{position:absolute;right:calc(8px + env(safe-area-inset-right));top:43%;width:74px;height:55px;font-size:17px;pointer-events:auto}
  .mobile-dock-actions #mobileAimLeft,.mobile-dock-actions #mobileAimRight{position:absolute;bottom:14px;width:35px;height:35px;padding:0;font-size:21px;pointer-events:auto}
  #mobileAimLeft{right:calc(49px + env(safe-area-inset-right))}#mobileAimRight{right:calc(8px + env(safe-area-inset-right))}
  .controls{display:none}
  .controls.mobile-spin-open{display:block;position:fixed;z-index:9;right:calc(90px + env(safe-area-inset-right));top:50%;transform:translateY(-50%);width:195px;max-height:calc(100dvh - 12px);overflow:auto;margin:0;padding:12px;background:#152225f2}
  .controls.mobile-spin-open .control-heading,.controls.mobile-spin-open .aim-heading,.controls.mobile-spin-open .aim-buttons,.controls.mobile-spin-open .aim-tip,.controls.mobile-spin-open .control-label,.controls.mobile-spin-open #power,.controls.mobile-spin-open .range-ends,.controls.mobile-spin-open #shootBtn,.controls.mobile-spin-open #placeBtn,.controls.mobile-spin-open #restartBtn{display:none}
  .controls.mobile-spin-open .spin-heading{margin:0 0 8px;padding:0;border:0;font-size:11px}.controls.mobile-spin-open .spin-row{gap:8px}.controls.mobile-spin-open .spin-pad{width:105px;height:105px}.controls.mobile-spin-open .spin-notes{font-size:9px;gap:5px}
  .overlay{z-index:15;overflow:auto;padding:5px}.modal{max-height:calc(100dvh - 10px);overflow:auto;padding:14px}.modal h1{font-size:22px}.modal p{margin:5px 0;font-size:11px}.mode-grid{grid-template-columns:repeat(3,1fr);gap:5px;margin-top:8px}.mode-card{min-height:75px;padding:7px}.mode-icon{display:none}.mode-card strong{font-size:12px}.mode-card small{font-size:10px}
}
@media (pointer:coarse) and (orientation:landscape) and (max-height:600px){
  .topbar{display:none}
  .game-layout{height:100dvh}
  .scorebar{height:30px;margin-bottom:1px}
  .table-wrap{width:min(calc((100dvh - 40px)*1.85185),calc(100vw - 180px))}
  .mobile-dock-top #mobileSpin{right:calc(20px + env(safe-area-inset-right));top:40px;display:grid;place-items:center;width:52px;height:52px;padding:4px;border:2px solid #a6b8b5;border-radius:50%;background:#1a2c30e8;box-shadow:0 3px 12px #0008}
  .mobile-dock-top .mobile-cue-ball{position:relative;display:block;width:39px;height:39px;border:2px solid #f8fbf8;border-radius:50%;background:radial-gradient(circle at 30% 22%,#fff 4%,#f6f9f8 42%,#b5c4c6 100%);box-shadow:inset -3px -4px 5px #7c969455,0 1px 5px #0008}
  .mobile-dock-top #mobileSpinDot{position:absolute;display:block;left:50%;top:50%;width:9px;height:9px;border:2px solid #fff;border-radius:50%;background:#e43341;box-shadow:0 0 0 1px #a91d2a;transform:translate(-50%,-50%)}
  .controls.mobile-spin-open{right:calc(82px + env(safe-area-inset-right));width:290px;padding:15px}
  .controls.mobile-spin-open .spin-pad{width:126px;height:126px}
  .controls.mobile-spin-open .spin-heading{font-size:12px}
  .controls.mobile-spin-open .spin-notes{font-size:10px}
  .mobile-dock-actions #mobileShoot{display:none}
  .mobile-power{position:fixed;top:56px;bottom:12px;align-self:auto}
  .mobile-power-track{position:relative;display:block;flex:1;width:12px!important;height:auto!important;min-height:95px;margin:10px auto 15px;border:1px solid #b7c8c4;border-radius:99px;background:#52646a;touch-action:none;cursor:ns-resize}
  .mobile-power-fill{position:absolute;left:0;top:0;width:100%;height:var(--pull,0%);border-radius:99px;background:#32b7ed;pointer-events:none}
  .mobile-power-thumb{position:absolute;left:50%;top:var(--pull,0%);width:31px;height:31px;border:2px solid #dbe5e2;border-radius:50%;background:#fff;box-shadow:0 2px 8px #000a;transform:translate(-50%,-50%);pointer-events:none}
  .mobile-power-track[aria-disabled="true"]{opacity:.5}
}
@media (pointer:coarse) and (orientation:landscape) and (max-height:600px){
  .mobile-power{top:62px;bottom:14px;width:62px;padding:0 5px;border:1px solid #7d98995c;border-radius:15px;background:linear-gradient(180deg,#1d2e33e8,#142125ba);box-shadow:inset 0 1px #ffffff22,0 5px 16px #0007}
  .mobile-power label{display:flex;flex-direction:column;align-items:center;justify-content:center;width:100%;min-height:41px;padding:3px 0;border-bottom:1px solid #9badac45;color:#cbd8d5;font-size:9px;line-height:1.05;text-transform:uppercase;letter-spacing:.06em}
  .mobile-power strong{display:block;margin-top:3px;color:#f5f2e7;font-size:16px;font-variant-numeric:tabular-nums;letter-spacing:0}
  #mobilePower.mobile-power-track{width:18px!important;min-height:80px;margin:46px auto 17px;border:1px solid #91adaf;border-radius:99px;background:repeating-linear-gradient(180deg,#ffffff1c 0 1px,transparent 1px 22px),linear-gradient(90deg,#344c52,#647b7e 50%,#2a424a);box-shadow:inset 0 0 0 2px #11262d,0 0 0 3px #7d999a30}
  .mobile-power-fill{background:linear-gradient(180deg,#a9f2ef,#30bddf 60%,#1470c7);box-shadow:0 0 8px #1cc9ec9c}
  .mobile-power-thumb{width:25px;height:25px;border:2px solid #fff;background:radial-gradient(circle at 32% 28%,#fff,#dce8e5 68%,#a4b5b5);box-shadow:0 2px 7px #000b,0 0 0 3px #82c8ce55}
}
@media (pointer:coarse) and (orientation:landscape) and (max-height:600px){
  .app{padding:0 max(2px,env(safe-area-inset-right)) 0 max(2px,env(safe-area-inset-left))}
  .scorebar{width:min(680px,calc(100vw - 95px));height:17px;gap:2px;margin:0}
  .scorebar .player{height:17px;min-height:17px;padding:0 4px;border:0;border-radius:0;background:transparent;box-shadow:none;opacity:.8}
  .scorebar .player.active{opacity:1;border:0;box-shadow:none}
  .scorebar .avatar{width:15px;height:15px;border-width:1px;font-size:8px;box-shadow:none}
  .scorebar .player strong{font-size:10px}.scorebar .turn-dot{width:5px;height:5px}
  .score-centre span{font-size:7px;letter-spacing:.08em}.score-centre strong{font-size:10px}
  .table-wrap{width:min(calc((100dvh - 19px)*1.85185),calc(100vw - 12px));padding:2px;border-radius:9px;margin:0 auto;box-shadow:0 3px 10px #0008}
  .table-wrap canvas{border-radius:7px}
  .mobile-power{left:calc(2px + env(safe-area-inset-left));top:44px;bottom:10px;width:31px;padding:0 2px;border:0;border-radius:10px;background:#162b303b;box-shadow:none;backdrop-filter:blur(3px)}
  .mobile-power label{min-height:36px;border:0;color:#fff;font-size:8px;text-shadow:0 1px 3px #000}
  .mobile-power strong{font-size:12px}
  #mobilePower.mobile-power-track{width:13px!important;margin:28px auto 12px;border-color:#c2d5d2a6;box-shadow:inset 0 0 0 1px #102329,0 0 0 2px #28464b55}
  .mobile-power-thumb{width:22px;height:22px}
  .mobile-dock-top #mobileSpin{right:calc(5px + env(safe-area-inset-right));top:20px;width:30px;height:30px;padding:2px;border-width:1px;box-shadow:0 2px 5px #0005}
  .mobile-dock-top .mobile-cue-ball{width:24px;height:24px;border-width:1px}
  .mobile-dock-top #mobileSpinDot{width:7px;height:7px;border-width:1px}
  .mobile-dock-actions #mobileAimLeft,.mobile-dock-actions #mobileAimRight{bottom:5px;width:28px;height:28px;border-radius:7px;font-size:17px;opacity:.78}
  .mobile-dock-actions #mobileAimLeft:disabled,.mobile-dock-actions #mobileAimRight:disabled{opacity:.25}
  #mobileAimLeft{right:calc(36px + env(safe-area-inset-right))}#mobileAimRight{right:calc(5px + env(safe-area-inset-right))}
  .controls.mobile-spin-open{right:calc(40px + env(safe-area-inset-right))}
}
