/* Shared match frame: every engine keeps its board, clocks, trays and result controls. */
.bq-route-game_play .bq-game-play-placeholder { padding-block:12px; }
.bq-game-chat-toggle,.bq-game-chat header .bq-game-chat-close { display:none; }
.bq-match-brand { display:none; }
.bq-match-tools { position:absolute; z-index:20; inset:-38px 0 auto; display:flex; height:36px; align-items:center; justify-content:flex-end; pointer-events:none; }
.bq-match-tools__end { display:flex; align-items:center; pointer-events:auto; }
.bq-match-tools button { display:grid; width:36px; height:36px; min-width:36px; place-items:center; padding:0; border:1px solid #2e6b8a; border-radius:6px; background:#071b35; color:#b9e6ef; box-shadow:0 3px 12px #0008; cursor:pointer; touch-action:manipulation; }
.bq-match-tools button:hover,.bq-game-arena > .bq-game-panel-toggle:hover,.bq-game-chat-dock > .bq-game-chat-toggle:hover { border-color:#6ddce1; color:#fff1bd; }
.bq-match-tools button:focus-visible,.bq-game-arena > .bq-game-panel-toggle:focus-visible,.bq-game-chat-dock > .bq-game-chat-toggle:focus-visible { outline:2px solid #ffcf69; outline-offset:2px; }
.bq-game-arena > .bq-game-panel-toggle,.bq-game-chat-dock > .bq-game-chat-toggle { z-index:25; display:grid; width:28px; height:28px; min-width:28px; place-items:center; padding:0; border:1px solid #2e6b8a; border-radius:5px; background:#071b35; color:#b9e6ef; box-shadow:0 3px 12px #0008; cursor:pointer; touch-action:manipulation; }
.bq-game-arena > .bq-game-panel-toggle { position:relative; }
.bq-game-arena > .bq-game-panel-toggle--opponent { grid-column:1; grid-row:1; justify-self:start; align-self:start; margin:4px 0 0 -12px; }
.bq-game-chat-dock { position:relative; grid-column:1; grid-row:2; align-self:end; min-width:0; height:min(100%,420px); }
.bq-game-chat-dock > .bq-game-chat-toggle { position:absolute; top:4px; left:-12px; border-color:#51b9c7; color:#bffff7; }
.bq-game-arena > .bq-game-panel-toggle--pieces { grid-column:3; grid-row:1; justify-self:end; align-self:start; margin:4px -12px 0 0; }
.bq-game-arena > .bq-game-panel-toggle--self { grid-column:3; grid-row:2; justify-self:end; align-self:end; margin:0 -12px 4px 0; }
.bq-game-arena.is-chat-collapsed > .bq-game-chat-dock { height:28px; }
.bq-game-panel-toggle span { display:block; font:700 1.65rem/1 sans-serif; transform:translateY(-2px); }
.bq-game-panel-toggle[aria-expanded="false"] span { transform:rotate(180deg) translateY(2px); }
.bq-game-settings-toggle svg { width:20px; height:20px; fill:none; stroke:currentColor; stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round; }
.bq-game-arena.is-opponent-collapsed > .bq-game-profile--opponent,.bq-game-arena.is-self-collapsed > .bq-game-profile--self,.bq-game-arena.is-pieces-collapsed > .bq-game-side-panel,.bq-game-arena.is-chat-collapsed .bq-game-chat { display:none; }

/* The board owns the centre; supporting panels use the remaining side space. */
body.bq-route-game_play:not(.bq-game-compact) { padding-top:0; overflow:hidden; }
body.bq-route-game_play:not(.bq-game-compact) .bq-header { position:relative; inset:auto; }
body.bq-route-game_play:not(.bq-game-compact) .bq-route-main { min-height:0; }
body.bq-route-game_play:not(.bq-game-compact) .bq-footer { display:none; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-play-placeholder { padding:0; min-height:0; height:calc(100dvh - var(--bq-match-header,84px)); }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-play-placeholder > .bq-shell { width:calc(100% - 32px); max-width:1600px; height:100%; min-height:0; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-board-slot { height:100%; min-height:0; padding:12px; border:0; background:transparent; box-shadow:none; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-board-slot::before,body.bq-route-game_play:not(.bq-game-compact) .bq-game-board-slot::after { display:none; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena { --bq-left-column:minmax(170px,220px); --bq-right-column:minmax(170px,220px); height:100%; grid-template-columns:var(--bq-left-column) minmax(0,1fr) var(--bq-right-column); grid-template-rows:auto minmax(0,1fr); gap:12px; align-content:stretch; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-opponent-collapsed.is-chat-collapsed { --bq-left-column:0px; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-self-collapsed.is-pieces-collapsed { --bq-right-column:170px; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-opponent-collapsed > .bq-game-panel-toggle--opponent { grid-column:2; grid-row:1; justify-self:start; align-self:start; margin:4px 0 0 -12px; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-self-collapsed > .bq-game-profile--self { display:flex; width:max-content; max-width:100%; min-width:0; min-height:38px; align-items:center; justify-self:end; padding:8px 40px 8px 12px; border-radius:5px; box-shadow:0 5px 18px #0007; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__avatar,
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__identity > :is(span,p,a),
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__identity > strong > i { display:none; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__identity { min-width:0; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage { grid-column:2; grid-row:1 / span 2; height:100%; min-height:0; min-width:0; padding:0; border:0; background:none; box-shadow:none; grid-template-rows:auto minmax(0,1fr) auto; gap:8px; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage::before { display:none; }
/* The side profiles own player identity while open. When hidden, a small name
   chip takes their place; clocks and match actions never become full-width bars. */
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage > .bq-game-stage__player { display:flex; min-width:0; min-height:38px; align-items:center; justify-content:flex-end; gap:8px; padding:0; border:0; background:none; box-shadow:none; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage > .bq-game-stage__player > span:first-child,
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage > .bq-game-stage__player > strong { display:none; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage > .bq-game-stage__player > :is(time,output) { display:grid; min-height:36px; flex:none; place-items:center; padding:7px 11px; border:1px solid #294f72; border-radius:5px; background:#081a39; color:#cce5f4; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage > .bq-game-stage__player.is-active > :is(time,output) { border-color:#c9a344; color:#fff0bc; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-opponent-collapsed .bq-game-stage:not([data-reversi-game]) > .bq-game-stage__player:first-child > strong,
body.bq-route-game_play:not(.bq-game-compact) .bq-game-arena.is-opponent-collapsed .bq-game-stage[data-reversi-game] > .bq-game-stage__player:nth-child(3) > strong { display:block; width:max-content; max-width:min(240px,42%); min-width:0; flex:0 1 auto; margin-right:auto; overflow:hidden; padding:10px 13px 10px 26px; border:1px solid #2e6b8a; border-radius:6px; background:#081e3d; color:#dcefff; box-shadow:0 5px 18px #0007; text-overflow:ellipsis; white-space:nowrap; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage__player > strong.is-vip-name .bq-vip-name { max-width:100%; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage__battlefield { display:grid; place-items:center; height:100%; min-height:0; min-width:0; overflow:visible; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage__battlefield > [data-layout-board]:not(iframe) { width:var(--bq-board-fit-width,100%); max-width:100%; min-width:0; margin:0; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage:has(iframe) { grid-template-rows:minmax(0,1fr) auto; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-stage iframe { width:100%; height:100%; min-height:0; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-side-panel { min-height:0; height:min(38dvh,340px); grid-column:3; grid-row:1; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-chat-dock > .bq-game-chat { width:100%; min-height:0; height:100%; max-height:100%; margin:0; grid-template-rows:auto auto minmax(0,1fr) auto auto; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-chat__messages { min-height:0; max-height:none; }
body.bq-route-game_play:not(.bq-game-compact) .bq-game-profile--self { grid-column:3; grid-row:2; align-self:end; }

html.bq-game-compact,body.bq-game-compact { height:100%; overflow:hidden; overscroll-behavior:none; }
body.bq-game-compact { --bq-match-header:60px; --bq-match-tabs:0px; padding:0; height:100dvh; }
body.bq-game-compact .bq-route-main { height:calc(100dvh - var(--bq-match-header) - var(--bq-match-tabs)); min-height:0; overflow:hidden; }
body.bq-game-compact .bq-game-play-placeholder { height:100%; min-height:0; padding:6px 3px; }
body.bq-game-compact .bq-game-play-placeholder > .bq-shell { width:100%; max-width:none; height:100%; min-height:0; }
body.bq-game-compact .bq-game-board-slot { height:100%; min-height:0; padding:0; border:0; box-shadow:none; background:none; overflow:visible; }
body.bq-game-compact .bq-game-board-slot::before,body.bq-game-compact .bq-game-board-slot::after { display:none; }
body.bq-game-compact .bq-game-arena { --bq-opponent-row:56px; --bq-self-row:56px; height:100%; min-height:0; grid-template-columns:minmax(0,1fr); grid-template-rows:var(--bq-opponent-row) minmax(0,1fr) var(--bq-self-row); gap:6px; align-content:stretch; align-items:stretch; }
body.bq-game-compact .bq-game-arena.is-opponent-collapsed { --bq-opponent-row:32px; }
body.bq-game-compact .bq-game-arena.is-self-collapsed { --bq-self-row:40px; }
body.bq-game-compact .bq-game-profile { grid-column:1/-1; min-width:0; grid-template-columns:42px minmax(0,1fr); align-items:center; gap:10px; padding:8px 10px; box-shadow:none; }
body.bq-game-compact .bq-game-profile--opponent { grid-row:1; }
body.bq-game-compact .bq-game-arena:has(.bq-game-stage > .bq-game-stage__player:first-child) .bq-game-profile--opponent { padding-inline-end:90px; }
body.bq-game-compact .bq-game-profile--self { grid-row:3; align-self:stretch; padding-inline-end:68px; }
body.bq-game-compact .bq-game-profile--self { padding-inline-end:10px; }
body.bq-game-compact .bq-game-arena > .bq-game-panel-toggle--pieces { display:none; }
body.bq-game-compact .bq-game-arena > :is(.bq-game-panel-toggle,.bq-game-chat-toggle) { width:40px; height:40px; min-width:40px; }
body.bq-game-compact .bq-game-arena > .bq-game-panel-toggle--opponent { grid-column:1; grid-row:1; justify-self:start; align-self:end; margin:0 0 0 4px; transform:translateY(40px); }
body.bq-game-compact .bq-game-arena > .bq-game-panel-toggle--self { grid-column:1; grid-row:3; justify-self:end; align-self:end; margin:0 4px 2px 0; }
body.bq-game-compact .bq-game-chat-dock { grid-column:1; grid-row:2; align-self:stretch; height:100%; pointer-events:none; }
body.bq-game-compact .bq-game-chat-dock > .bq-game-chat-toggle { top:auto; bottom:60px; left:4px; pointer-events:auto; }
body.bq-game-compact .bq-game-arena:has(.bq-game-chat.is-open) .bq-game-chat-toggle { visibility:hidden; }
body.bq-game-compact .bq-match-tools { top:-39px; height:40px; }
body.bq-game-compact .bq-match-tools button { width:40px; height:40px; min-width:40px; }
body.bq-game-compact .bq-game-profile__avatar { width:42px; padding:3px; }
body.bq-game-compact .bq-game-profile__identity { gap:5px; }
body.bq-game-compact .bq-game-profile__identity p,body.bq-game-compact .bq-game-profile__identity a { display:none; }
body.bq-game-compact .bq-game-profile__identity > strong { font-size:.72rem; }
body.bq-game-compact .bq-game-profile__identity > strong.is-vip { overflow:hidden; }
body.bq-game-compact .bq-game-profile__identity .bq-vip-name { flex:1; min-width:0; }
body.bq-game-compact .bq-game-profile__identity .bq-vip-name__handle { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
body.bq-game-compact .bq-game-profile__identity .bq-vip-name__crown { flex:none; }
body.bq-game-compact .bq-game-profile__identity > span { font-size:.54rem; }
body.bq-game-compact .bq-game-profile__identity > span img { width:20px; height:20px; flex-basis:20px; }
body.bq-game-compact .bq-game-stage { min-width:0; min-height:0; height:100%; grid-column:1; grid-row:2; grid-template-rows:minmax(0,1fr) auto; align-content:stretch; gap:4px; padding:0; border:0; background:none; box-shadow:none; }
body.bq-game-compact .bq-game-stage::before { display:none; }
body.bq-game-compact .bq-game-stage__battlefield { display:grid; min-width:0; min-height:0; height:100%; grid-template-columns:minmax(0,1fr); place-items:center; overflow:visible; }
body.bq-game-compact .bq-game-stage__battlefield > [data-layout-board]:not(iframe) { width:var(--bq-board-fit-width,100%); min-width:0; max-width:100%; margin:0; }
body.bq-game-compact .bq-game-stage__player { min-height:36px; grid-template-columns:auto minmax(0,1fr) auto; gap:5px; padding:4px 7px; font-size:.62rem; }
body.bq-game-compact .bq-game-stage__player.has-actions,body.bq-game-compact .bq-game-stage__player.has-actions.has-pass { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; }
body.bq-game-compact .bq-game-stage__player.has-actions { border:0; background:none; box-shadow:none; }
body.bq-game-compact .bq-game-stage__player.has-actions > time { min-height:36px; display:grid; place-items:center; padding:5px 7px; border:1px solid #9c7b30; border-radius:4px; background:#0a1b35; color:#fff0bc; }
body.bq-game-compact .bq-game-stage__player > strong { flex:1; min-width:0; font-size:.6rem; }
body.bq-game-compact .bq-game-stage__player > span:first-child { font-size:1rem; }
body.bq-game-compact .bq-game-stage__player > strong,body.bq-game-compact .bq-game-stage__player > span:first-child { display:none; }
body.bq-game-compact .bq-game-stage__player:first-child { position:absolute; top:-56px; right:8px; width:72px; height:44px; grid-template-columns:1fr; justify-items:center; }
body.bq-game-compact .bq-game-arena.is-opponent-collapsed .bq-game-stage__player:first-child { top:-32px; height:30px; }
body.bq-game-compact .bq-game-stage__player:not(:first-child) { justify-content:space-between; grid-template-columns:minmax(0,1fr) auto; }
body.bq-game-compact .bq-game-stage__player time { font-size:.7rem; }
body.bq-game-compact .bq-game-stage__player:first-child.is-check time { align-self:start; }
body.bq-game-compact .bq-game-stage__player:first-child.is-check::after { top:auto; bottom:1px; left:1px; right:1px; padding:1px; font-size:.38rem; text-align:center; transform:none; }
body.bq-game-compact .bq-game-stage__player.has-actions.is-check::after { right:52px; padding:2px; font-size:.4rem; }
body.bq-game-compact .bq-game-stage__player button,body.bq-game-compact .bq-game-stage__player a { min-height:36px; padding:5px 7px; font-size:.5rem; }
body.bq-game-compact .bq-game-side-panel { display:none; }
body.bq-game-compact .bq-game-stage__battlefield.has-piece-rails { grid-template-rows:auto auto auto; align-content:center; row-gap:4px; }
body.bq-game-compact .has-piece-rails > [data-layout-board] { grid-row:2; }
body.bq-game-compact .bq-mobile-piece-rail { display:flex; grid-row:1; align-items:center; justify-content:flex-start; flex-wrap:nowrap; width:var(--bq-rail-width,100%); max-width:100%; min-width:0; height:24px; gap:1px; padding:0; border:0; background:none; box-shadow:none; }
body.bq-game-compact .bq-mobile-piece-rail.is-self { grid-row:3; }
body.bq-game-compact .bq-mobile-piece-rail:empty { height:8px; }
body.bq-game-compact .bq-mobile-piece-rail > span { width:var(--bq-capture-size,18px); min-width:0; height:calc(var(--bq-capture-size,18px) * 1.22); flex:0 0 var(--bq-capture-size,18px); margin:0; font-size:.65rem; box-shadow:none; animation:none; }
body.bq-game-compact .bq-mobile-piece-rail > span:not(.bq-chess-game__captured-piece) { height:var(--bq-capture-size,18px); }
body.bq-game-compact .bq-mobile-piece-rail > .bq-sittuyin-game__captured-piece { font-size:0; border:0; background-color:transparent; }
body.bq-game-compact .bq-mobile-piece-rail > span::after { font-size:.5rem; }
/* Reusable pieces remain accessible controls, with small artwork inside a
   44px touch target. Long hands scroll horizontally instead of stacking. */
body.bq-game-compact .bq-mobile-piece-rail.has-controls { height:48px; gap:2px; overflow-x:auto; overflow-y:hidden; overscroll-behavior:contain; scrollbar-width:thin; }
body.bq-game-compact .bq-mobile-piece-rail > button { width:44px; height:44px; min-height:44px; flex:0 0 44px; padding:4px; background-size:26px 34px; box-shadow:none; }
body.bq-game-compact .bq-mobile-piece-rail > .bq-sittuyin-game__reserve-piece { background-size:26px; border-color:transparent; background-color:transparent; }
body.bq-game-compact .bq-mobile-piece-rail > button span { font-size:.85rem; }
body.bq-game-compact .bq-mobile-piece-rail > button b { font-size:.5rem; }
body.bq-game-compact .bq-mobile-piece-rail > button:focus-visible,body.bq-game-compact .bq-mobile-piece-rail > button.is-selected { outline:2px solid #ffe276; outline-offset:-2px; transform:none; }
body.bq-game-compact .bq-game-result { inset:4px; max-height:100%; overflow-y:auto; overscroll-behavior:contain; padding:14px; }
body.bq-game-compact .bq-game-chat-dock > .bq-game-chat-toggle { display:flex; width:40px; height:40px; justify-content:center; padding:0; }
.bq-game-chat-toggle svg { width:24px; height:24px; fill:none; stroke:currentColor; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.bq-game-chat-toggle:active { transform:scale(.96); }
.bq-game-chat-dot { position:absolute; top:1px; right:1px; width:10px; height:10px; border:2px solid #05152a; border-radius:50%; background:#ffcf63; }
body.bq-game-compact .bq-game-chat { position:fixed; z-index:600; right:12px; bottom:var(--bq-chat-bottom,128px); display:none; width:min(360px,calc(100% - 24px)); height:min(480px,var(--bq-chat-height,calc(100dvh - 230px))); min-height:0; max-height:none; margin:0; grid-template-rows:44px auto minmax(16px,1fr) auto; border:1px solid #4087a3; border-radius:12px; background:#04142ff5; box-shadow:0 14px 50px #000b; pointer-events:auto; }
body.bq-game-compact .bq-game-chat.is-open { display:grid; }
body.bq-game-compact .bq-game-chat:has([data-game-chat-vip]) { grid-template-rows:44px auto minmax(16px,1fr) auto auto; }
body.bq-game-compact .bq-game-chat header { min-height:44px; padding:0 0 0 14px; }
body.bq-game-compact .bq-game-chat header .bq-game-chat-close { display:grid; width:44px; height:44px; border:0; background:none; color:#dcefff; font-size:24px; }
body.bq-game-compact .bq-game-chat__messages { min-height:0; max-height:none; overscroll-behavior:contain; -webkit-overflow-scrolling:touch; }
body.bq-game-compact .bq-game-chat__message { font-size:.85rem; }
body.bq-game-compact .bq-game-chat form { grid-template-columns:minmax(0,1fr) 44px; padding:8px; }
body.bq-game-compact .bq-game-chat input { height:44px; font-size:16px; }
body.bq-game-compact .bq-game-chat form button { width:44px; height:44px; }
body.bq-game-compact .bq-game-chat__vip { min-width:0; overflow-x:auto; }
body.bq-game-compact .bq-game-chat__vip button { width:44px; height:44px; flex:0 0 44px; }
body.bq-game-compact .bq-game-stage:has(iframe) { grid-template-rows:minmax(0,1fr) auto; }
body.bq-game-compact .bq-game-stage iframe { width:100%; height:100%; min-height:0; }
body.bq-game-compact .bq-game-stage > p { margin:0; padding:4px; font-size:.6rem; }
body.bq-game-compact .bq-footer { display:none; }
/* During active play the shared arena owns the screen. The small brand is
   deliberately not a link, so it cannot accidentally navigate away. */
body.bq-match-focused :is(.bq-header,.bq-mobile-header,.bq-mobile-tabs,.bq-mobile-menu) { display:none!important; }
body.bq-match-focused .bq-game-board-slot { position:relative; }
body.bq-match-focused .bq-match-brand { position:absolute; inset:6px 0 auto; display:flex; justify-content:center; height:26px; pointer-events:none; }
body.bq-match-focused .bq-match-brand img { display:block; width:94px; height:26px; object-fit:contain; }
body.bq-route-game_play.bq-match-focused:not(.bq-game-compact) .bq-game-board-slot { padding-top:38px; }
body.bq-game-compact.bq-match-focused .bq-game-board-slot { padding-top:42px; }
body.bq-game-compact.bq-match-focused .bq-game-play-placeholder { padding-top:max(6px,env(safe-area-inset-top)); padding-bottom:max(6px,env(safe-area-inset-bottom)); }
body.bq-game-compact .bq-game-stage .bq-game-stage__resign { min-height:44px; padding:8px 10px; font-size:.65rem; line-height:1.25; touch-action:manipulation; }
@media (orientation:portrait) {
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed { --bq-opponent-row:44px; }
  body.bq-game-compact .bq-game-arena.is-self-collapsed { --bq-self-row:44px; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed > .bq-game-profile--opponent,
  body.bq-game-compact .bq-game-arena.is-self-collapsed > .bq-game-profile--self { display:flex; width:max-content; max-width:min(220px,calc(100% - 90px)); height:44px; align-items:center; padding:7px 10px 7px 48px; border-radius:5px; background:#081e3d; box-shadow:0 4px 12px #0007; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed:has(.bq-game-stage > .bq-game-stage__player:first-child) > .bq-game-profile--opponent { padding-inline-end:10px; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed > .bq-game-profile--opponent .bq-game-profile__avatar,
  body.bq-game-compact .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__avatar { display:none; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed > .bq-game-profile--opponent .bq-game-profile__identity,
  body.bq-game-compact .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__identity { display:flex; min-width:0; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed > .bq-game-profile--opponent .bq-game-profile__identity > span,
  body.bq-game-compact .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__identity > span { display:none; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed > .bq-game-profile--opponent .bq-game-profile__identity > strong > i,
  body.bq-game-compact .bq-game-arena.is-self-collapsed > .bq-game-profile--self .bq-game-profile__identity > strong > i { display:none; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed > .bq-game-panel-toggle--opponent { align-self:start; margin-top:2px; transform:none; }
  body.bq-game-compact .bq-game-arena.is-self-collapsed > .bq-game-panel-toggle--self { justify-self:start; align-self:start; margin:2px 0 0 4px; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed .bq-game-stage__player:first-child { top:-44px; }
}
@media (max-height:500px) and (orientation:landscape) {
  body.bq-game-compact.bq-match-focused .bq-game-board-slot { padding-top:34px; }
  body.bq-game-compact .bq-match-tools { top:-34px; height:34px; }
  body.bq-game-compact .bq-match-tools button { width:34px; height:34px; min-width:34px; }
  body.bq-game-compact .bq-game-arena > .bq-game-panel-toggle--pieces { display:none; }
  body.bq-game-compact .bq-game-arena > .bq-game-panel-toggle--opponent { grid-column:1; grid-row:1; justify-self:end; align-self:start; margin:4px; transform:none; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed > .bq-game-panel-toggle--opponent { justify-self:start; transform:translateY(42px); }
  body.bq-game-compact .bq-game-arena > .bq-game-panel-toggle--self { grid-column:3; grid-row:1; justify-self:end; align-self:start; margin:4px; }
  body.bq-game-compact .bq-game-chat-dock > .bq-game-chat-toggle { position:fixed; left:max(8px,env(safe-area-inset-left)); bottom:8px; width:40px; height:40px; margin:0; padding:0; }
  body.bq-game-compact .bq-game-arena { --bq-left-column:clamp(100px,17vw,150px); --bq-right-column:clamp(100px,17vw,150px); grid-template-columns:max(var(--bq-left-column),var(--bq-right-column)) minmax(0,1fr) max(var(--bq-left-column),var(--bq-right-column)); grid-template-rows:minmax(0,1fr); column-gap:6px; }
  body.bq-game-compact .bq-game-chat-dock { grid-column:1; grid-row:1; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed { --bq-left-column:0px; }
  body.bq-game-compact .bq-game-arena.is-self-collapsed { --bq-right-column:0px; }
  body.bq-game-compact .bq-game-profile { grid-column:1; grid-row:1; grid-template-columns:1fr; align-self:start; padding:8px; }
  body.bq-game-compact .bq-game-arena:has(.bq-game-stage > .bq-game-stage__player:first-child) .bq-game-profile--opponent { padding-inline-end:8px; }
  body.bq-game-compact .bq-game-profile--self { grid-column:3; align-self:start; padding:8px; }
  body.bq-game-compact .bq-game-stage { grid-column:2; grid-row:1; }
  /* Clocks/actions sit with the side profiles on short landscape screens,
     leaving the centre's full height to the decorated board and captures. */
  body.bq-game-compact .bq-game-stage:not(:has(iframe)) { grid-template-rows:minmax(0,1fr); }
  body.bq-game-compact .bq-game-stage__player:first-child { position:fixed; top:calc(var(--bq-match-header) + 158px); left:max(8px,env(safe-area-inset-left)); right:auto; width:var(--bq-left-column); height:36px; justify-items:center; }
  body.bq-game-compact .bq-game-stage__player.has-actions { position:fixed; right:max(8px,env(safe-area-inset-right)); bottom:calc(var(--bq-match-tabs) + 10px); width:var(--bq-right-column); }
  body.bq-game-compact .bq-game-stage__player.has-actions .bq-game-stage__resign { width:100%; min-width:0; max-width:100%; white-space:normal; text-align:center; }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed .bq-game-stage__player:first-child { top:42px; width:min(176px,20vw); display:flex; justify-content:space-between; }
  body.bq-game-compact .bq-game-arena.is-self-collapsed .bq-game-stage__player.has-actions { width:clamp(125px,24vw,210px); }
  body.bq-game-compact .bq-game-arena.is-opponent-collapsed .bq-game-stage__player:first-child > strong,body.bq-game-compact .bq-game-arena.is-self-collapsed .bq-game-stage__player.has-actions > strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
  body.bq-game-compact .bq-game-arena.is-self-collapsed .bq-game-stage__player.has-actions > strong { flex:0 0 100%; }
  body.bq-game-compact .bq-game-chat { top:44px; bottom:8px; left:8px; right:auto; width:min(300px,44vw); height:auto; max-height:none; }
}
