/* GP Games - Play on TV (3.15.0): the game-page buttons, the phone dialog and the three stand-alone pages (/tv/, /tv/connect/, /tv/control/). */

/* ---------- game page: the three buttons under "Play game" ---------- */
.gp-mobile-game-card.gp-has-extra { height: auto; min-height: 240px; }
.gp-mobile-game-card.gp-has-extra .gp-mgc-bottom { position: relative; flex-direction: column; align-items: center; gap: 9px; padding: 130px 16px 16px; }
.gp-mgc-bottom .gp-btn-mobile-tv,
.gp-mgc-bottom .gp-btn-dl-pulse { width: min(260px, 100%); box-sizing: border-box; justify-content: center; }
.gp-btn-mobile-tv {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 26px; border: 0; border-radius: 30px; cursor: pointer;
  color: #fff; font-weight: 800; font-size: 14px; line-height: 1; font-family: inherit; letter-spacing: .02em; text-decoration: none;
  background: linear-gradient(135deg, #6366f1 0%, #3b82f6 100%); box-shadow: 0 6px 20px rgba(59, 130, 246, .38);
}
.gp-btn-mobile-tv:active { transform: scale(.97); }
.gp-btn-dl-pulse {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 24px; border: 0; border-radius: 30px; cursor: pointer;
  color: #1a1200; font-weight: 800; font-size: 14px; line-height: 1; font-family: inherit; letter-spacing: .02em;
  background: linear-gradient(135deg, #fbbf24 0%, #f59e0b 100%); box-shadow: 0 0 0 0 rgba(251, 191, 36, .75);
  animation: gpDlPulse 1.5s ease-in-out infinite;
}
.gp-btn-dl-pulse:hover { filter: brightness(1.06); }
.gp-btn-dl-pulse[hidden] { display: none; }
.gp-play-overlay-content .gp-btn-dl-pulse { display: flex; width: max-content; margin: 14px auto 0; }
@keyframes gpDlPulse {
  0%   { box-shadow: 0 0 0 0 rgba(251, 191, 36, .75); transform: scale(1); }
  60%  { box-shadow: 0 0 0 14px rgba(251, 191, 36, 0); transform: scale(1.04); }
  100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); transform: scale(1); }
}
/* the download card / button that the blinking button points to */
.gp-dl-focus { animation: gpDlFocus 1s ease-in-out 4; outline: 2px solid rgba(251, 191, 36, .9); outline-offset: 3px; border-radius: 14px; }
@keyframes gpDlFocus { 0%, 100% { box-shadow: 0 0 0 0 rgba(251, 191, 36, 0); } 50% { box-shadow: 0 0 26px 6px rgba(251, 191, 36, .75); } }
@media (prefers-reduced-motion: reduce) { .gp-btn-dl-pulse, .gp-dl-focus { animation: none; } }

/* ---------- phone dialog ---------- */
.gptv-modal { position: fixed; inset: 0; z-index: 2147483000; display: flex; align-items: flex-end; justify-content: center; background: rgba(5, 7, 14, .7); padding: 0; }
.gptv-modal[hidden] { display: none; }
.gptv-sheet { width: min(480px, 100%); max-height: 88vh; overflow: auto; box-sizing: border-box; padding: 20px 18px calc(20px + env(safe-area-inset-bottom)); border-radius: 20px 20px 0 0; background: #141726; color: #eef0f8; border: 1px solid rgba(255, 255, 255, .09); font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }
@media (min-width: 640px) { .gptv-modal { align-items: center; padding: 20px; } .gptv-sheet { border-radius: 20px; } }
.gptv-sheet h2 { margin: 0 0 4px; font-size: 20px; }
.gptv-sheet p { margin: 0 0 14px; color: #aab0c6; font-size: 13.5px; line-height: 1.5; }
.gptv-close { float: right; width: 40px; height: 40px; margin: -8px -8px 0 0; border: 0; border-radius: 12px; background: transparent; color: #c7ccdf; font-size: 24px; cursor: pointer; }
.gptv-list { display: grid; gap: 8px; margin: 0 0 14px; }
.gptv-dev { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 14px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .08); }
.gptv-dev b { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gptv-dev small { color: #8d94ad; display: block; font-weight: 400; }
.gptv-dot { width: 9px; height: 9px; border-radius: 50%; background: #64748b; flex: none; }
.gptv-dot.on { background: #22c55e; box-shadow: 0 0 8px #22c55e; }
.gptv-field { display: grid; gap: 6px; margin: 0 0 12px; font-size: 13px; color: #aab0c6; }
.gptv-field input, .gptv-page input { box-sizing: border-box; width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .14); background: #0d0f1b; color: #fff; font-size: 17px; letter-spacing: .08em; }
.gptv-btn, .gptv-btn-s { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 20px; border: 0; border-radius: 12px; cursor: pointer; font-weight: 800; font-size: 15px; color: #fff; text-decoration: none; background: linear-gradient(135deg, #6366f1, #3b82f6); }
.gptv-btn-s { min-height: 40px; padding: 0 14px; font-size: 13.5px; }
.gptv-btn-s.ghost, .gptv-btn.ghost { background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .12); }
.gptv-btn:disabled, .gptv-btn-s:disabled { opacity: .55; cursor: default; }
.gptv-msg { min-height: 18px; margin: 10px 0 0; font-size: 13px; color: #fca5a5; }
.gptv-msg.ok { color: #86efac; }
.gptv-help { margin: 14px 0 0; padding: 12px; border-radius: 12px; background: rgba(99, 102, 241, .1); border: 1px solid rgba(99, 102, 241, .25); font-size: 13px; color: #c7ccdf; line-height: 1.55; }

/* ---------- shared look of the stand-alone pages ---------- */
body.gp-tvpage { margin: 0; min-height: 100vh; background: radial-gradient(1200px 700px at 20% 0%, #1b1f3d 0%, #0b0d17 60%); color: #eef0f8; font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif; }
.gptv-brand { font-weight: 800; letter-spacing: .02em; }
.gptv-brand span { color: #8b9cff; }
[hidden] { display: none !important; }

/* TV screen (/tv/) - sizes follow the screen so it reads from the sofa */
body.gptv-tv { overflow: hidden; cursor: none; }
.gptv-home { box-sizing: border-box; min-height: 100vh; padding: 4vh 5vw; display: flex; flex-direction: column; justify-content: center; gap: 4vh; }
.gptv-home .gptv-brand { font-size: 3.2vh; }
.gptv-card { display: flex; align-items: center; gap: 5vw; padding: 5vh 4vw; border-radius: 28px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .1); }
.gptv-qr { flex: none; width: 38vh; height: 38vh; padding: 0; border-radius: 18px; background: #fff; overflow: hidden; }
.gptv-qr svg { display: block; width: 100%; height: 100%; }
.gptv-steps h1 { margin: 0 0 2.5vh; font-size: 5.4vh; }
.gptv-steps ol { margin: 0 0 3vh; padding-left: 1.4em; font-size: 3vh; line-height: 1.5; color: #d6dbee; }
.gptv-steps li { margin-bottom: 1.2vh; }
.gptv-steps small { color: #98a0bb; font-size: 2.3vh; }
.gptv-code-label { margin: 0 0 .5vh; color: #98a0bb; font-size: 2.4vh; }
.gptv-code { font-size: 9vh; font-weight: 800; letter-spacing: .22em; color: #fff; font-variant-numeric: tabular-nums; }
.gptv-timer { margin: .5vh 0 0; color: #98a0bb; font-size: 2.2vh; }
.gptv-ready { gap: 3vw; }
.gptv-ready h1 { margin: 0 0 1vh; font-size: 6vh; }
.gptv-ready p { margin: 0; font-size: 3.2vh; color: #c7ccdf; }
.gptv-check { flex: none; width: 14vh; height: 14vh; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 8vh; background: rgba(34, 197, 94, .18); color: #4ade80; border: 2px solid rgba(34, 197, 94, .5); }
.gptv-status { min-height: 3vh; margin: 0; color: #98a0bb; font-size: 2.2vh; }
@media (max-aspect-ratio: 1/1) { .gptv-card { flex-direction: column; text-align: center; } .gptv-qr { width: 40vw; height: 40vw; } }

/* phone pages (/tv/connect/) */
.gptv-phone { box-sizing: border-box; max-width: 520px; margin: 0 auto; padding: calc(18px + env(safe-area-inset-top)) 16px 30px; }
.gptv-phone .gptv-brand { margin: 4px 0 16px; font-size: 18px; }
.gptv-panel { padding: 18px 16px; margin-bottom: 14px; border-radius: 18px; background: rgba(255, 255, 255, .05); border: 1px solid rgba(255, 255, 255, .09); }
.gptv-panel h1 { margin: 0 0 12px; font-size: 20px; }
.gptv-panel p { margin: 0 0 14px; color: #aab0c6; font-size: 14px; line-height: 1.55; }
.gptv-panel label { display: grid; gap: 6px; margin-bottom: 12px; font-size: 13px; color: #aab0c6; }
.gptv-games { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.gptv-game { position: relative; display: block; width: 100%; padding: 0; border: 0; border-radius: 14px; overflow: hidden; cursor: pointer; text-align: left; background: #1b1f36; color: #fff; aspect-ratio: 16/11; }
.gptv-game img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.gptv-game span { position: absolute; left: 0; right: 0; bottom: 0; padding: 22px 10px 9px; font-weight: 700; font-size: 13.5px; background: linear-gradient(180deg, transparent, rgba(0, 0, 0, .85)); }

/* controller (/tv/control/) */
body.gptv-control { overflow: hidden; overscroll-behavior: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; background: #07080f; }
.gptv-ctl { position: fixed; inset: 0; display: flex; flex-direction: column; padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left); }
.gptv-ctl-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; }
.gptv-ctl-title { font-weight: 800; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gptv-ctl-pill { flex: none; padding: 6px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700; background: rgba(148, 163, 184, .18); color: #cbd5e1; }
.gptv-ctl-pill.ok { background: rgba(34, 197, 94, .18); color: #4ade80; }
.gptv-ctl-pill.bad { background: rgba(239, 68, 68, .18); color: #fca5a5; }
.gptv-ctl-stage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 6px 12px; }
.gptv-pad { box-sizing: border-box; position: relative; width: 100%; height: 100%; max-width: 100%; border-radius: 22px; touch-action: none; background:
  linear-gradient(rgba(139, 156, 255, .06) 1px, transparent 1px) 0 0 / 12.5% 12.5%, linear-gradient(90deg, rgba(139, 156, 255, .06) 1px, transparent 1px) 0 0 / 12.5% 12.5%, #11142a;
  border: 2px solid rgba(139, 156, 255, .35); box-shadow: inset 0 0 50px rgba(99, 102, 241, .15); }
.gptv-pad.is-down { border-color: #8b9cff; background-color: #171b38; }
.gptv-pad-hint { position: absolute; inset: 0; display: flex; flex-direction: column; gap: 6px; align-items: center; justify-content: center; text-align: center; padding: 20px; color: #7f87a6; font-size: 15px; line-height: 1.5; pointer-events: none; transition: opacity .3s; }
.gptv-pad-hint small { color: #5f6783; }
.gptv-pad.touched .gptv-pad-hint { opacity: 0; }
.gptv-touchdot { position: absolute; width: 46px; height: 46px; margin: -23px 0 0 -23px; border-radius: 50%; pointer-events: none; background: rgba(139, 156, 255, .35); border: 2px solid #c7d0ff; }
.gptv-rotate { display: none; text-align: center; font-size: 12.5px; color: #8d94ad; padding: 0 12px 6px; }
@media (orientation: portrait) { .gptv-rotate { display: block; } }
.gptv-ctl-bar { display: flex; gap: 8px; padding: 8px 12px 12px; }
.gptv-ctl-bar button { flex: 1; min-height: 48px; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .12); background: rgba(255, 255, 255, .07); color: #eef0f8; font-size: 14px; font-weight: 700; cursor: pointer; }
.gptv-ctl-bar button:active { background: rgba(255, 255, 255, .16); }
.gptv-ctl-bar #gptvExit { color: #fca5a5; }

/* TV: the game screen */
.gptv-cursor { position: fixed; z-index: 2147483600; width: 5.2vh; height: 5.2vh; margin: -2.6vh 0 0 -2.6vh; border-radius: 50%; pointer-events: none; background: rgba(139, 156, 255, .35); border: .4vh solid #fff; box-shadow: 0 0 2vh rgba(99, 102, 241, .9); opacity: 0; transition: opacity .25s; }
.gptv-cursor.on { opacity: 1; }
.gptv-cursor.down { background: rgba(250, 204, 21, .55); transform: scale(.85); }
.gptv-banner { position: fixed; left: 50%; top: 3vh; transform: translateX(-50%); z-index: 2147483601; padding: 1.4vh 3vh; border-radius: 999px; background: rgba(15, 18, 36, .92); border: 1px solid rgba(255, 255, 255, .2); color: #fff; font: 700 2.4vh/1.2 -apple-system, 'Segoe UI', Roboto, sans-serif; }

/* ======================================================================================================
   Game controller (landscape phone). One unit u = 1% of the smaller of (screen height, 55% of width), so the pad keeps its shape
   on tall phones, short phones and tablets alike.
   ====================================================================================================== */
body.gptv-m-g .gptv-ctl { display: none; }
body.gptv-m-t .gptv-gp, body.gptv-m-t .gptv-rotfull { display: none; }
body.gptv-m-g.gptv-portrait .gptv-gp { display: none; }
body.gptv-m-g:not(.gptv-portrait) .gptv-rotfull { display: none; }
body.gptv-ended .gptv-ctl { display: flex !important; }
body.gptv-ended .gptv-gp, body.gptv-ended .gptv-rotfull { display: none !important; }

/* "turn your phone sideways" */
.gptv-rotfull { position: fixed; inset: 0; z-index: 20; display: flex; align-items: center; justify-content: center; text-align: center; padding: 24px; background: radial-gradient(900px 600px at 50% 0%, #20244a 0%, #0a0b14 70%); }
.gptv-rotfull-in { max-width: 340px; }
.gptv-rotfull-ico { width: 92px; height: 92px; color: #8b9cff; animation: gptvTurn 2.6s ease-in-out infinite; transform-origin: 50% 50%; }
@keyframes gptvTurn { 0%, 15% { transform: rotate(0); } 55%, 85% { transform: rotate(-90deg); } 100% { transform: rotate(0); } }
.gptv-rotfull h2 { margin: 18px 0 6px; font-size: 22px; }
.gptv-rotfull p { margin: 0 0 20px; color: #aab0c6; font-size: 14.5px; line-height: 1.5; }
.gptv-rotfull .gptv-btn { width: 100%; margin-bottom: 10px; }
@media (prefers-reduced-motion: reduce) { .gptv-rotfull-ico { animation: none; } }

.gptv-gp { --u: min(1vh, .55vw); position: fixed; inset: 0; z-index: 10; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; touch-action: none; -webkit-tap-highlight-color: transparent; }
.gptv-gp * { touch-action: none; -webkit-tap-highlight-color: transparent; }
.gp-body {
  position: absolute; inset: 0; overflow: hidden; color: #e8ebf7;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
  background:
    repeating-linear-gradient(45deg, rgba(255, 255, 255, .018) 0 2px, transparent 2px 5px),
    radial-gradient(130% 120% at 50% -10%, #2c3050 0%, #14172a 48%, #07080f 100%);
}
.gp-body::before { content: ""; position: absolute; inset: calc(var(--u) * 1.4); border-radius: calc(var(--u) * 9); border: calc(var(--u) * .35) solid rgba(255, 255, 255, .06); box-shadow: inset 0 0 calc(var(--u) * 8) rgba(0, 0, 0, .55); pointer-events: none; }

/* light bar + status */
.gp-light { position: absolute; left: 50%; top: calc(var(--u) * 1.6); width: calc(var(--u) * 30); height: calc(var(--u) * 1.1); transform: translateX(-50%); border-radius: 99px; background: #4f6bff; box-shadow: 0 0 calc(var(--u) * 3) #4f6bff; transition: background .4s, box-shadow .4s; }
.gp-light.ok { background: #35e08b; box-shadow: 0 0 calc(var(--u) * 3.4) #35e08b; }
.gp-light.bad { background: #ff5468; box-shadow: 0 0 calc(var(--u) * 3) #ff5468; animation: gpBlink 1s ease-in-out infinite; }
@keyframes gpBlink { 50% { opacity: .35; } }
.gp-title { position: absolute; left: 50%; top: calc(var(--u) * 4); transform: translateX(-50%); max-width: calc(var(--u) * 60); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: max(10px, calc(var(--u) * 2.6)); font-weight: 700; letter-spacing: .04em; color: #8e95b4; }
.gp-pill { margin-top: calc(var(--u) * 1.6); font-size: max(9.5px, calc(var(--u) * 2.3)); font-weight: 700; color: #9aa2c2; white-space: nowrap; }

/* shoulders */
.gp-sh { position: absolute; top: calc(var(--u) * 3.2); width: calc(var(--u) * 27); height: calc(var(--u) * 8.5); padding: 0; border: calc(var(--u) * .3) solid rgba(255, 255, 255, .1); border-radius: calc(var(--u) * 4.5) calc(var(--u) * 4.5) calc(var(--u) * 1.4) calc(var(--u) * 1.4); cursor: pointer;
  background: linear-gradient(#4a5070, #232640 70%, #1a1c30); box-shadow: 0 calc(var(--u) * .8) calc(var(--u) * 1.6) rgba(0, 0, 0, .55), inset 0 calc(var(--u) * .3) 0 rgba(255, 255, 255, .22); color: #aeb5d6; font: 800 max(11px, calc(var(--u) * 3)) system-ui, sans-serif; }
.gp-sh i { font-style: normal; letter-spacing: .06em; }
.gp-l1 { left: calc(var(--u) * 7); }
.gp-r1 { right: calc(var(--u) * 7); }
.gp-sh.on, .gp-pillbtn.on { transform: translateY(calc(var(--u) * .6)); background: linear-gradient(#6a74b8, #3a4380); color: #fff; box-shadow: 0 0 calc(var(--u) * 2.4) rgba(120, 140, 255, .65), inset 0 0 calc(var(--u) * 1.5) rgba(0, 0, 0, .35); }

/* d-pad */
.gp-dpad { position: absolute; left: calc(var(--u) * 7); top: calc(var(--u) * 17); width: calc(var(--u) * 38); height: calc(var(--u) * 38); filter: drop-shadow(0 calc(var(--u) * 1) calc(var(--u) * 1.4) rgba(0, 0, 0, .6)); }
.gp-dpad svg { width: 100%; height: 100%; display: block; overflow: visible; }
.gp-dpad .gl { fill: #7e86a8; }
.gp-dpad .arm { fill: #7d93ff; opacity: 0; transition: opacity .06s; }
.gp-dpad .arm.on { opacity: .42; }

/* sticks */
.gp-stick { position: absolute; bottom: calc(var(--u) * 6); width: calc(var(--u) * 34); height: calc(var(--u) * 34); }
.gp-ls { left: 27%; }
.gp-rs { right: 27%; }
.gp-base { position: absolute; inset: 0; border-radius: 50%; background: radial-gradient(circle at 50% 42%, #06070d 0 46%, #151828 47% 72%, #252a42 73% 100%); box-shadow: inset 0 calc(var(--u) * .8) calc(var(--u) * 2.4) #000, 0 calc(var(--u) * .3) 0 rgba(255, 255, 255, .1); border: calc(var(--u) * .35) solid rgba(255, 255, 255, .07); }
.gp-knob { position: absolute; left: 21%; top: 21%; width: 58%; height: 58%; border-radius: 50%; transition: transform .16s cubic-bezier(.3, 1.5, .5, 1);
  background: radial-gradient(circle at 36% 30%, #878da8 0%, #484d68 34%, #23273b 78%, #171a2b 100%);
  box-shadow: 0 calc(var(--u) * 1.3) calc(var(--u) * 2.2) rgba(0, 0, 0, .7), inset 0 calc(var(--u) * .35) calc(var(--u) * .5) rgba(255, 255, 255, .3), inset 0 calc(var(--u) * -.6) calc(var(--u) * 1.2) rgba(0, 0, 0, .55); }
.gp-knob::after { content: ""; position: absolute; inset: 22%; border-radius: 50%; border: calc(var(--u) * .3) solid rgba(255, 255, 255, .12); background: radial-gradient(circle, rgba(0, 0, 0, .35), transparent 70%); }
.gp-stick.on .gp-knob { background: radial-gradient(circle at 36% 30%, #a3b1ff 0%, #5565c8 34%, #2b3270 78%, #1b2050 100%); }

/* centre: Select / menu / Start */
.gp-mid { position: absolute; left: 50%; top: calc(var(--u) * 12); transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; }
.gp-mid-row { display: flex; gap: calc(var(--u) * 7); }
.gp-pillbtn { height: calc(var(--u) * 5.6); padding: 0 calc(var(--u) * 3.4); border: calc(var(--u) * .3) solid rgba(255, 255, 255, .12); border-radius: 99px; cursor: pointer; background: linear-gradient(#41466a, #1e2138); color: #a9b1d6; font: 800 max(9px, calc(var(--u) * 2.1)) system-ui, sans-serif; letter-spacing: .12em; text-transform: uppercase; box-shadow: 0 calc(var(--u) * .5) calc(var(--u) * 1.2) rgba(0, 0, 0, .55), inset 0 calc(var(--u) * .25) 0 rgba(255, 255, 255, .2); }
.gp-ps { margin-top: calc(var(--u) * 3.2); width: calc(var(--u) * 12.5); height: calc(var(--u) * 12.5); padding: 0; border-radius: 50%; cursor: pointer; border: calc(var(--u) * .35) solid rgba(255, 255, 255, .16); color: #cfd6ff;
  background: radial-gradient(circle at 35% 28%, #5c6390, #252949 62%, #151830); box-shadow: 0 calc(var(--u) * .9) calc(var(--u) * 2) rgba(0, 0, 0, .65), inset 0 calc(var(--u) * .35) calc(var(--u) * .5) rgba(255, 255, 255, .3); }
.gp-ps svg { width: 60%; height: 60%; display: block; margin: 0 auto; }
.gp-ps:active { background: radial-gradient(circle at 35% 28%, #7c86d6, #343b8a 62%, #1c214e); }

/* face buttons */
.gp-face { position: absolute; right: calc(var(--u) * 7); top: calc(var(--u) * 17); width: calc(var(--u) * 38); height: calc(var(--u) * 38); }
.fb { position: absolute; width: 36%; height: 36%; display: flex; align-items: center; justify-content: center; border-radius: 50%; font-style: normal;
  background: radial-gradient(circle at 36% 28%, #50567a 0%, #292d49 52%, #171a2e 100%); border: calc(var(--u) * .3) solid rgba(255, 255, 255, .1);
  box-shadow: 0 calc(var(--u) * .9) calc(var(--u) * 1.8) rgba(0, 0, 0, .65), inset 0 calc(var(--u) * .35) calc(var(--u) * .5) rgba(255, 255, 255, .28); transition: transform .05s, box-shadow .08s; pointer-events: none; }
.fb svg { width: 56%; height: 56%; display: block; filter: drop-shadow(0 0 calc(var(--u) * .5) currentColor); }
.f-tri { left: 32%; top: 0; color: #4fe0a8; }
.f-cir { right: 0; top: 32%; color: #ff6a7d; }
.f-cro { left: 32%; bottom: 0; color: #6c98ff; }
.f-squ { left: 0; top: 32%; color: #f08ad8; }
.fb.on { transform: scale(.92); background: radial-gradient(circle at 36% 28%, #7480b8 0%, #3a4180 55%, #1f2350 100%); box-shadow: 0 0 calc(var(--u) * 3) currentColor, inset 0 0 calc(var(--u) * 1.6) rgba(0, 0, 0, .4); }

/* menu sheet */
.gp-menu { position: absolute; inset: 0; z-index: 5; display: flex; align-items: center; justify-content: center; background: rgba(4, 5, 12, .78); }
.gp-menu[hidden] { display: none; }
.gp-menu-card { width: min(92vw, 420px); max-height: 92vh; overflow: auto; box-sizing: border-box; padding: 16px; border-radius: 18px; background: #151829; border: 1px solid rgba(255, 255, 255, .1); display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.gp-menu-card h3 { grid-column: 1 / -1; margin: 0 0 2px; font-size: 17px; }
.gp-menu-card button { min-height: 44px; padding: 0 12px; border-radius: 12px; border: 1px solid rgba(255, 255, 255, .12); background: rgba(255, 255, 255, .07); color: #eef0f8; font-size: 14px; font-weight: 700; cursor: pointer; }
.gp-menu-card button[hidden] { display: none; }
.gp-menu-card .primary { grid-column: 1 / -1; background: linear-gradient(135deg, #6366f1, #3b82f6); border: 0; }
.gp-menu-card .danger { color: #fca5a5; }
.gp-menu-card #gmTouch { grid-column: 1 / -1; }
.gm-seg { grid-column: 1 / -1; display: grid; gap: 6px; }
.gm-seg span { font-size: 12px; color: #98a0bb; }
.gm-seg > div { display: flex; gap: 6px; }
.gm-seg button { flex: 1; min-height: 38px; font-size: 13px; }
.gm-seg button.on { background: #3b4bd8; border-color: #6e7dff; }

/* touch-pad screen: the button that goes back to the game controller */
.gptv-ctl-bar #gptvPadMode { color: #a9b6ff; }

/* Play on TV dialog: one-time setup steps */
.gptv-setup h3 { margin: 0 0 8px; font-size: 16px; }
.gptv-howto { margin: 0 0 14px; padding: 0 0 0 20px; font-size: 14px; line-height: 1.6; color: #d6dbee; }
.gptv-howto li { margin-bottom: 6px; }
.gptv-howto b { color: #fff; overflow-wrap: break-word; }
.gptv-setup .gptv-btn { width: 100%; }
.gptv-more { margin: 12px 0 0; border-top: 1px solid rgba(255, 255, 255, .09); padding-top: 12px; }
.gptv-more summary { cursor: pointer; font-weight: 700; font-size: 14px; color: #a9b6ff; padding: 6px 0; }
.gptv-more[open] summary { margin-bottom: 8px; }

/* full-screen prompt + chip (controller) */
.gptv-gofull { position: fixed; inset: 0; z-index: 30; display: flex; align-items: center; justify-content: center; text-align: center; padding: 24px; background: radial-gradient(900px 600px at 50% 0%, #20244a 0%, #0a0b14 70%); }
.gptv-gofull[hidden] { display: none; }
.gptv-gofull .gptv-rotfull-ico { animation: none; }
.gptv-gofull .gptv-btn { width: 100%; margin-bottom: 10px; }
.gptv-gofull h2 { margin: 18px 0 6px; font-size: 22px; }
.gptv-gofull p { margin: 0 0 20px; color: #aab0c6; font-size: 14.5px; line-height: 1.5; }
.gptv-fschip { position: fixed; top: calc(6px + env(safe-area-inset-top, 0px)); left: 50%; transform: translateX(-50%); z-index: 15; padding: 6px 14px; border-radius: 999px; border: 1px solid rgba(255, 255, 255, .18); background: rgba(21, 24, 41, .86); color: #dfe3f5; font-size: 12px; font-weight: 700; cursor: pointer; }
.gptv-fschip[hidden] { display: none; }
body.gptv-ended .gptv-gofull, body.gptv-ended .gptv-fschip { display: none !important; }
html, body.gptv-control { overscroll-behavior: none; }
