
/* KING OS V243 GAME PHONE COMPATIBILITY */
:root{
  --king-phone-bg:#000;
  --king-phone-gold:#f5cc66;
  --king-phone-gold2:#fff1af;
}
html.king-game-phone, html.king-game-phone body{
  background:#000!important;
  overscroll-behavior:none!important;
  -webkit-text-size-adjust:100%!important;
}
.king-game-phone body{
  touch-action:manipulation!important;
  user-select:none!important;
  -webkit-user-select:none!important;
  -webkit-touch-callout:none!important;
}
.king-game-phone a,
.king-game-phone button,
.king-game-phone input,
.king-game-phone select,
.king-game-phone textarea,
.king-game-phone .hot,
.king-game-phone .card,
.king-game-phone .mini,
.king-game-phone .back{
  touch-action:manipulation!important;
  -webkit-tap-highlight-color:rgba(255,216,92,.28)!important;
}
.king-game-phone a,
.king-game-phone button,
.king-game-phone .hot,
.king-game-phone .card,
.king-game-phone .mini,
.king-game-phone .back{
  cursor:pointer!important;
}
.king-game-phone img{
  -webkit-user-drag:none!important;
  user-select:none!important;
}

/* 手機/遊戲手機固定用 16:9 等比例舞台，避免熱區因寬螢幕或手機比例被拉歪 */
html.king-game-phone .stage{
  position:fixed!important;
  inset:auto!important;
  left:50%!important;
  top:50%!important;
  width:min(100vw,177.7778vh)!important;
  height:min(100vh,56.25vw)!important;
  transform:translate(-50%,-50%)!important;
  overflow:hidden!important;
  background:#000!important;
}
html.king-game-phone .bg,
html.king-game-phone .stage-img{
  position:absolute!important;
  inset:0!important;
  width:100%!important;
  height:100%!important;
  object-fit:fill!important;
}

/* 使用手機直向時仍可操作，但提示橫向會更適合 */
.king-phone-rotate-tip{
  position:fixed;
  left:50%;
  bottom:calc(env(safe-area-inset-bottom,0px) + 10px);
  transform:translateX(-50%);
  z-index:99999;
  padding:8px 14px;
  border:1px solid rgba(245,204,102,.75);
  border-radius:999px;
  background:rgba(0,0,0,.72);
  color:#fff1af;
  font:700 13px/1.2 -apple-system,BlinkMacSystemFont,"Noto Sans TC","Noto Sans JP","Noto Sans KR",Arial,sans-serif;
  letter-spacing:.02em;
  box-shadow:0 0 18px rgba(245,204,102,.25);
  pointer-events:none;
  opacity:0;
  transition:opacity .25s ease;
}
@media (orientation:portrait) and (max-width:900px){
  html.king-game-phone .king-phone-rotate-tip{opacity:1}
}

/* debug 熱區在手機上更清楚 */
html.king-game-phone.debug-hot .hot,
html.king-game-phone .debug-hot .hot{
  outline:2px solid rgba(255,221,90,.92)!important;
  background:rgba(255,210,70,.18)!important;
}

/* 外部連結中轉頁手機按鈕 */
.king-openlink-page button,
.king-openlink-page a{
  min-height:48px;
}
