.play-page { --lime: #97c75b; background: #2c2b28; }
.play-header { min-height: 62px; display: flex; justify-content: space-between; align-items: center; padding: 8px max(18px, calc((100% - 1130px) / 2)); background: #252420; border-bottom: 1px solid #3b3935; }
.play-header .brand { margin: 0; padding: 0; }
.play-header .brand span { display: inline; }
.back-link { font-size: 15px; color: #d6d4ce; white-space: nowrap; padding: 9px; }
.back-link:hover { color: white; }
.arena { width: min(1130px, calc(100% - 40px)); margin: 24px auto 45px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 360px); gap: clamp(20px, 4vw, 44px); align-items: start; }
.playing-area { min-width: 0; width: min(100%, 68dvh); margin: auto; }
.player-card { display: flex; align-items: center; gap: 10px; min-height: 57px; padding: 7px 0; }
.player-card small { display: block; color: #adaba4; font-size: 12px; margin-top: 3px; }
.player-icon { flex: 0 0 40px; height: 40px; display: grid; place-items: center; background: #474540; border-radius: 7px; color: #e6e3d9; font-size: 25px; }
.bot-icon { background: #434c36; color: #bad893; }
.thinking, .game-status { margin-left: auto; color: #d5e2c3; font-size: 13px; text-align: right; }
.thinking span { animation: pulse 900ms alternate infinite; }
@keyframes pulse { to { opacity: .3; } }
.board-row { display: grid; grid-template-columns: 25px minmax(0, 1fr); gap: 7px; }
.live-board { border-radius: 6px; touch-action: manipulation; box-shadow: 0 4px 16px #0003; }
.live-board .square { position: relative; padding: 0; border: 0; cursor: default; -webkit-tap-highlight-color: transparent; user-select: none; }
.live-board .square:focus-visible { outline: 3px solid #174e8b; outline-offset: -3px; z-index: 3; }
.live-board .square.own, .live-board .square.legal { cursor: pointer; }
.live-board .square.last { background: #c9d768; }
.live-board .square.dark.last { background: #a6bd50; }
.live-board .square.selected { background: #f4d36c; }
.live-board .square.check { background: radial-gradient(#ef6457 30%, #c96050 68%, #b15648); }
.live-board .square.legal::after { content: ""; position: absolute; z-index: 1; width: 27%; aspect-ratio: 1; border-radius: 50%; background: #25242144; pointer-events: none; }
.live-board .square.capture::after { width: 93%; border: 4px solid #25242150; background: transparent; }
.live-board .chess-piece { pointer-events: none; width: 99%; height: 99%; }
.coord { position: absolute; color: var(--dark-square); font-size: clamp(9px, 1.5vw, 13px); font-weight: 800; line-height: 1; pointer-events: none; }
.dark .coord { color: var(--light-square); }
.coord.rank { top: 3px; left: 3px; }.coord.file { right: 3px; bottom: 3px; }
.eval-bar { position: relative; overflow: hidden; border-radius: 5px; background: #23221e; }
#eval-fill { position: absolute; inset: auto 0 0; height: 50%; background: #e9e9df; transition: height 250ms ease; }
#eval-bar-text { position: absolute; bottom: 5px; left: 50%; transform: translateX(-50%); color: #2f2e29; background: #e9e9df; border-radius: 3px; padding: 1px 2px; font-size: 9px; font-weight: 800; }
.eval-bar.flipped #eval-fill { top: 0; bottom: auto; }.eval-bar.flipped #eval-bar-text { top: 5px; bottom: auto; }
.match-panel { min-width: 0; padding: 19px; background: #262521; border: 1px solid #403e39; border-radius: 12px; }
.panel-title { display: flex; align-items: center; gap: 10px; }
.panel-title > span { font-size: 35px; line-height: 1; color: var(--lime); }
.panel-title h1 { font-size: 25px; }
.panel-title p { margin-top: 5px; color: #c3c1bb; font-size: 13px; }
.panel-title b { color: #cbe7aa; background: #405331; padding: 2px 5px; border-radius: 4px; font-size: 10px; }
.engine-state { margin-top: 16px; min-height: 35px; font-size: 13px; color: #d5d0c5; }
.engine-state.ready { color: #a9d881; min-height: 0; }
.engine-state progress { display: block; width: 100%; height: 7px; margin-top: 7px; accent-color: var(--lime); }
.engine-state .btn { min-height: 34px; margin-top: 6px; padding-inline: 9px; }
[hidden] { display: none !important; }
.eval-panel { padding: 11px; margin-top: 15px; background: #35342f; border-radius: 8px; }
.eval-panel > div, .move-heading { display: flex; align-items: center; justify-content: space-between; gap: 6px; }
.eval-panel > div { font-size: 13px; font-weight: 700; }.eval-panel strong { font-size: 19px; }
.eval-panel p, .no-moves { margin-top: 6px; color: #c1bfb6; font-size: 13px; line-height: 1.5; }
.move-heading { margin-top: 15px; }.move-heading h2 { font-size: 17px; }
.text-button { color: #cbe7aa; padding: 5px; background: transparent; border: 0; cursor: pointer; font-size: 12px; }.text-button:disabled { color: #aaa89f; }
.moves { list-style: none; padding: 0; margin: 6px 0; max-height: 151px; overflow: auto; font-size: 13px; }
.moves li { display: grid; grid-template-columns: 29px 1fr 1fr; padding: 5px 6px; border-radius: 4px; }
.moves li:nth-child(odd) { background: #33322e; }.moves li span:first-child { color: #aaa79d; }
.credits { display: inline-block; margin-top: 12px; color: #b5b3a9; font-size: 11px; text-decoration: underline; }
#promotion { border: 1px solid #59574e; border-radius: 11px; background: #302f2a; color: white; padding: 17px; }
#promotion::backdrop { background: #0009; }
#promotion h2 { font-size: 18px; margin-bottom: 12px; }
#promotion-choices { display: flex; gap: 6px; }
#promotion-choices button { width: clamp(44px, 16vw, 61px); aspect-ratio: 1; border: 0; border-radius: 6px; background: #8ca56b; cursor: pointer; }
#promotion-choices .chess-piece { margin: auto; }
@media (max-width: 730px) {
  .play-header { min-height: 50px; }
  .arena { width: min(calc(100% - 18px), 580px); margin-top: 7px; grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .playing-area { width: 100%; }
  .board-row { grid-template-columns: 23px minmax(0, 1fr); gap: 4px; }
  .match-panel { padding: 13px; }
}

/* The setup view keeps the board and opponent list side by side. */
.play-page { min-height: 100dvh; }
.play-page.special-theme { background: #554377 url("scene.svg") center / cover fixed; }
.play-sidebar { background: #252421; }
.special-theme .play-sidebar { background: #22234c6b; }
.play-header { display: none; }
.arena { width: min(960px, calc(100% - var(--sidebar) - 54px)); margin: 16px 0 16px calc(var(--sidebar) + clamp(24px, 4vw, 54px)); grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(18px, 2.4vw, 32px); }
.playing-area { width: min(100%, 68dvh); margin: 0; }

.choosing #game-status, .choosing .player-card small { display: none; }
.special-theme .live-board { --light-square: #f5ecdd; --dark-square: #4a8c9f; border-radius: 2px; box-shadow: 0 3px 18px #1e214744; }
.special-theme .live-board .square { background-image: linear-gradient(145deg, #fff2, transparent 60%); }
.special-theme .live-board .square.dark { background-image: linear-gradient(145deg, #41749655, #5f6faf25); }
.special-theme .live-board .chess-piece { filter: drop-shadow(1px 2px 0 #57428555); }
.special-theme .live-board [data-piece]:is([data-piece="b"], [data-piece="n"], [data-piece="q"], [data-piece="k"], [data-piece="p"], [data-piece="r"]) .chess-piece { filter: sepia(.35) saturate(2.5) hue-rotate(174deg) drop-shadow(1px 2px 0 #5846af); }
.special-theme .live-board [data-piece]:is([data-piece="B"], [data-piece="N"], [data-piece="Q"], [data-piece="K"], [data-piece="P"], [data-piece="R"]) .chess-piece { filter: sepia(.3) saturate(3) hue-rotate(298deg) drop-shadow(1px 2px 0 #a8609670); }
.player-card { min-height: 50px; padding-block: 0 8px; }
.player-card:last-child { padding-block: 8px 0; }
.player-card strong { font-size: 14px; }
.player-icon { overflow: hidden; }
.player-icon svg { width: 100%; height: 100%; }
.bot-picker { display: grid; min-width: 0; grid-template-rows: auto auto minmax(0, 1fr) auto; height: calc(100dvh - 32px); min-height: 590px; background: #24244db8; border-radius: 5px; box-shadow: 0 3px 8px #271a5822; }
.picker-title { min-height: 48px; display: flex; align-items: center; justify-content: center; gap: 8px; background: #20234a42; }
.picker-title h1 { font-size: 18px; line-height: 1; }
.picker-profile { padding: 0 12px 15px; margin-top: clamp(24px, 5.8dvh, 56px); display: grid; grid-template-columns: 61px 1fr; align-items: end; row-gap: 14px; }
.picker-portrait { height: 61px; }
.picker-portrait svg { width: 100%; height: 100%; }
.picker-profile > p { min-height: 62px; padding: 10px 12px; position: relative; display: grid; align-content: center; background: #faf9f7; color: #272523; line-height: 1.35; border-radius: 11px; font-size: 14px; animation: speech-in 160ms ease-out; }
.picker-profile > p::before { content: ""; position: absolute; left: -6px; bottom: 16px; border: solid transparent; border-width: 6px 8px 6px 0; border-right-color: #faf9f7; }
@keyframes speech-in { from { opacity: .5; transform: translateX(3px); } }
.picker-name { grid-column: 1 / -1; font-weight: 800; font-size: 16px; }
.picker-name span { color: #c3c1d8; font-size: 14px; font-weight: 400; margin-inline: 5px; }
.bot-categories { overflow-y: auto; padding: 7px 11px 5px; scrollbar-width: thin; }
.bot-category { background: #ffffff0c; border-radius: 5px; margin: 0 0 8px; }
.bot-category summary { display: flex; align-items: center; min-height: 48px; gap: 8px; padding: 0 11px; cursor: pointer; font-weight: 750; list-style: none; }
.bot-category summary::-webkit-details-marker { display: none; }
.bot-category summary .category-icon { width: 36px; height: 36px; flex: 0 0 auto; }
.bot-category summary small { font-size: 12px; color: #c3c1d2; margin-left: auto; font-weight: 400; white-space: nowrap; }
.bot-category[open] summary { min-height: 43px; }
.bot-category[open] .category-icon { display: none; }
.bot-roster { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 7px; padding: 0 9px 10px; }
.bot-choice { aspect-ratio: 1; padding: 1px; background: #ffffff0b; border: 2px solid transparent; border-radius: 7px; cursor: pointer; transition: border-color 140ms ease, background 140ms ease; }
.bot-choice:hover { background: #ffffff23; }
.bot-choice[aria-pressed="true"] { border-color: #a0ca63; }
.bot-choice svg { display: block; width: 100%; height: 100%; }
.picker-footer { background: #2a233d49; padding: 12px; display: grid; gap: 10px; }
.picker-controls { display: flex; gap: 8px; align-items: center; }
#picker-options-toggle { display: flex; align-items: center; gap: 7px; flex: 1; min-height: 39px; padding: 0 10px; color: #e6dfee; background: #ffffff14; border: 1px solid #ffffff10; border-radius: 6px; cursor: pointer; font-size: 14px; text-align: left; }
#picker-options-toggle span:last-child { margin-left: auto; }
.picker-options { font-size: 13px; color: #e2dceb; }.picker-options input { accent-color: #96c159; }
.side-picks { border: 0; padding: 0; margin: 0; display: flex; gap: 3px; }
.side-picks legend, .sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.side-picks input { position: absolute; opacity: 0; }
.side-picks span:first-of-type { display: grid; place-items: center; width: 28px; height: 29px; border: 2px solid transparent; border-radius: 5px; font-size: 21px; color: #ece8e0; background: #18172563; cursor: pointer; }
.side-picks input:checked + span { border-color: #a5d163; background: #ffffff21; }
.side-picks input:focus-visible + span { outline: 2px solid white; }
.picker-play { min-height: 60px; font-size: 22px; cursor: pointer; }
.match-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 15px; }
.match-actions button { cursor: pointer; min-height: 41px; }
.play-page.hide-eval .board-row { grid-template-columns: minmax(0, 1fr); }
.hide-eval .eval-bar, .hide-eval .eval-panel { display: none; }

@media (max-width: 1010px) {
  .arena { width: calc(100% - var(--sidebar) - 32px); margin-left: calc(var(--sidebar) + 16px); grid-template-columns: minmax(0, 1fr) minmax(254px, 300px); }
}
@media (max-width: 730px) {
  .play-sidebar { display: none; }
  .play-header { display: flex; }
  .special-theme .play-header { background: #24244e; }
  .arena { width: min(calc(100% - 18px), 580px); margin: 7px auto 28px; grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .playing-area { width: 100%; }
  .bot-picker { height: auto; min-height: 0; grid-template-rows: auto auto auto auto; }
  .picker-profile { margin-top: 12px; }
  .bot-categories { max-height: 258px; }
  .bot-roster { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .picker-play { min-height: 48px; }
}

/* Opponent setup and active games share the same panel geometry. */
.match-panel { display: flex; flex-direction: column; padding: 0; height: calc(100dvh - 32px); min-height: 590px; border: 0; border-radius: 5px; background: #242421b8; }
.special-theme .match-panel { background: #24244db8; }
.match-panel .picker-title { flex: 0 0 48px; }
.match-profile { display: grid; grid-template-columns: 61px 1fr; padding: 0 12px; margin: clamp(24px, 5.8dvh, 56px) 0 35px; align-items: end; min-height: 62px; }
#match-portrait { height: 61px; } #match-portrait svg { width: 100%; height: 100%; }
#match-chat { position: relative; display: grid; align-content: center; min-height: 62px; padding: 10px 12px; font-size: 14px; line-height: 1.35; color: #272523; background: #faf9f7; border-radius: 11px; }
#match-chat::before { content: ""; position: absolute; left: -6px; bottom: 16px; border: solid transparent; border-width: 6px 8px 6px 0; border-right-color: #faf9f7; }
.engine-state { margin: 0; padding: 0 12px 9px; font-size: 12px; }.engine-state.ready { display: none; }
.eval-panel { background: #1b1b2730; border-radius: 0; padding: 9px 12px; margin: 0; }
.analysis-heading { font-size: 10px !important; font-weight: 400 !important; color: #c5c5cf; margin-bottom: 5px; }
.analysis-heading > strong { font-size: 11px; }.eval-panel #engine-line { margin-top: 5px; font-size: 10px; }
#candidate-lines > div { display: flex; gap: 6px; margin-bottom: 4px; align-items: center; font-size: 11px; }
#candidate-lines strong { border-radius: 3px; background: #f9f9f5; padding: 3px; color: #34332f; font-size: 11px; min-width: 43px; text-align: center; }
#candidate-lines span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #d6d5e2; }
.move-feedback { padding: 10px 13px; background: #ffffff0c; font-size: 14px; font-weight: 700; border-top: 1px solid #ffffff0b; }
.notation-heading { display: flex; justify-content: space-between; gap: 5px; padding: 10px 13px; border-block: 1px solid #ffffff12; font-size: 12px; color: #cecad8; }
.notation-heading #position-title { white-space: nowrap; text-overflow: ellipsis; overflow: hidden; }
.moves { margin: 0; max-height: none; min-height: 100px; flex: 1; padding: 5px 10px; font-size: 13px; }
.moves li { padding: 8px 3px; grid-template-columns: 30px 1fr 1fr; }
.moves li:nth-child(odd) { background: #ffffff05; }.moves li span:not(:first-child) { font-weight: 700; }
.no-moves { padding: 5px 13px; font-size: 12px; margin: 0; color: #b8b1c7; }
.match-bottom { margin-top: auto; padding: 15px 12px 9px; background: #ffffff07; }
.game-tools { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; }
.game-tools button { min-height: 48px; display: grid; place-items: center; background: #ffffff13; color: #e2d9ed; border: 0; border-radius: 9px; font-size: 29px; font-family: Arial,sans-serif; cursor: pointer; }
.game-tools button:hover { background: #ffffff26; }.game-tools button:disabled { opacity: .35; cursor: default; }
.secondary-tools { margin-top: 8px; display: flex; align-items: center; gap: 5px; }
.secondary-tools > button { background: transparent; color: #c6b8d5; border: 0; padding: 3px; cursor: pointer; font-size: 20px; }
.secondary-tools > .text-button { font-size: 11px; margin-left: auto; }.secondary-tools > .text-button + .text-button { margin-left: 3px; }
.match-bottom .credits { margin-top: 5px; font-size: 9px; color: #c2b7cc; }
.player-card { flex-wrap: wrap; }
.player-card .board-gear { margin-left: auto; }.player-card .clock + .board-gear { margin-left: 0; }
.board-gear { padding: 5px; border: 0; background: transparent; color: #c4becf; font-size: 19px; cursor: pointer; }
.thinking { flex-basis: 100%; font-size: 11px; }
.clock { background: #252221a6; color: #d6d2cc; border-radius: 5px; padding: 6px 9px; font-size: 18px; font-weight: 750; font-variant-numeric: tabular-nums; }
.clock.running { background: #f2efe6; color: #282620; }
#human-clock, #bot-clock { margin-left: auto; }
.board-wrap { min-width: 0; position: relative; aspect-ratio: 1; }
.live-board { width: 100%; height: 100%; touch-action: none; }
#board-arrows { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; z-index: 4; }
#board-arrows > path { fill: none; stroke-width: 20px; stroke-linejoin: round; opacity: .77; }
#board-arrows .suggestion { stroke: #9bc45b; }#board-arrows .threat { stroke: #e96357; }
.drag-ghost { position: fixed; aspect-ratio: 1; transform: translate(-50%,-50%); z-index: 20; pointer-events: none; }
.drag-ghost svg { width: 100%; height: 100%; }.dragging .chess-piece { opacity: .2; }
.outline-pieces .chess-piece g { fill: none !important; stroke-width: 2; }
.outline-pieces .chess-piece g circle { fill: #aaa; }
body[data-coordinates="none"] .live-board .coord, body[data-coordinates="outside"] .live-board .coord { display: none; }
#outer-coordinates { position: absolute; inset: 0; pointer-events: none; display: none; font-size: 11px; color: #d6d3dd; }
body[data-coordinates="outside"] #outer-coordinates { display: block; }
body[data-coordinates="outside"] .board-wrap { margin-left: 13px; margin-bottom: 13px; width: calc(100% - 13px); }
.outside-rank { position: absolute; left: -12px; transform: translateY(-50%); }.outside-file { position: absolute; bottom: -14px; transform: translateX(-50%); }

.bot-picker.options-open { grid-template-rows: auto auto minmax(0,1fr); }
.options-open #bot-categories { display: none; }
.options-open .picker-footer { min-height: 0; grid-row: 3; grid-template-rows: auto minmax(0,1fr) auto; }
.options-open .picker-options { overflow-y: auto; min-height: 0; padding: 7px 0; scrollbar-width: thin; }
.options-open .picker-loading:not([hidden]) { grid-row: 3; }
.options-open .picker-play { grid-row: 4; }
.picker-loading { font-size: 11px; color: #dbd2e4; }
.time-category { margin-top: 11px; }.time-category h2 { font-size: 13px; margin: 0 0 7px; color: #e4dfb6; }
.time-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 6px; }
.time-preset { position: relative; min-width: 0; }
.time-preset input { position: absolute; opacity: 0; }
.time-preset span { display: grid; place-items: center; min-height: 40px; border: 2px solid transparent; border-radius: 6px; background: #ffffff15; font-weight: 700; cursor: pointer; font-size: 13px; }
.time-preset input:checked + span { border-color: #9cc462; background: #ffffff1e; }
.time-preset input:focus-visible + span { outline: 2px solid #fff; }.no-timer { display: block; }
.variant-choice { min-height: 50px; background: #ffffff13; border-radius: 8px; margin-top: 15px; display: flex; gap: 10px; align-items: center; justify-content: center; font-size: 18px; font-weight: 700; }
.switch-row { display: flex !important; align-items: center; justify-content: space-between; gap: 12px; min-height: 40px; font-size: 13px; font-weight: 400; }
.switch-row input[type="checkbox"] { appearance: none; flex: 0 0 48px; width: 48px; height: 24px; background: #ffffff1c; border-radius: 20px; border: 0; position: relative; cursor: pointer; }
.switch-row input[type="checkbox"]::after { content: ""; position: absolute; top: 1px; left: 1px; width: 22px; height: 22px; border-radius: 50%; background: #c7c5bf; transition: transform 130ms ease; }
.switch-row input[type="checkbox"]:checked { background: #80b64b; }
.switch-row input[type="checkbox"]:checked::after { transform: translateX(24px); background: #f2f4e9; }
.switch-row input:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }

#board-settings, #resign-dialog, #result-dialog { border: 1px solid #555145; border-radius: 11px; background: #282722; color: #eeeae4; padding: 0; box-shadow: 0 12px 50px #0006; width: min(460px, calc(100% - 26px)); }
dialog::backdrop { background: #080719c9; }
.settings-scroll { max-height: min(68dvh, 620px); overflow-y: auto; padding: 14px; scrollbar-width: thin; }
.settings-preview { display: grid; grid-template-columns: repeat(8,1fr); grid-template-rows: repeat(3,1fr); height: 132px; background: var(--light); margin-bottom: 18px; }
.settings-preview i { background: var(--light); }.settings-preview i:nth-child(16n + 2),.settings-preview i:nth-child(16n + 4),.settings-preview i:nth-child(16n + 6),.settings-preview i:nth-child(16n + 8),.settings-preview i:nth-child(16n + 9),.settings-preview i:nth-child(16n + 11),.settings-preview i:nth-child(16n + 13),.settings-preview i:nth-child(16n + 15) { background: var(--dark); }
.settings-scroll > label { display: flex; align-items: center; justify-content: space-between; gap: 15px; min-height: 55px; color: #d2cec4; font-size: 13px; }
.settings-scroll select { width: 58%; height: 33px; font: inherit; color: #d8d3c9; background: #3a3832; border: 1px solid #4c4941; border-radius: 6px; padding: 0 7px; }
.dialog-actions { display: flex; gap: 15px; padding: 14px; background: #302e28; }
.dialog-actions .btn { flex: 1; cursor: pointer; font-size: 16px; }
#resign-dialog h2 { font-size: 19px; padding: 25px 20px 12px; }
#result-dialog { text-align: center; padding: 25px; max-width: 400px; position: fixed; }
#result-dialog h2 { font-size: 24px; margin: 10px 0; }#result-dialog p { margin-bottom: 25px; color: #c3bdb2; }
#result-dialog > .btn { display: block; width: 100%; margin-top: 10px; cursor: pointer; font-size: 18px; }
.result-symbol { font-size: 52px; color: #a4cb72; }
.dialog-close { position: absolute; top: 6px; right: 9px; padding: 0 5px; border: 0; background: transparent; color: #a9a39b; font-size: 28px; cursor: pointer; }
@media (max-width: 730px) {
  .match-panel { min-height: 490px; height: auto; }
  .match-profile { margin-top: 18px; margin-bottom: 20px; max-width: 360px; }
  .match-panel .moves { min-height: 95px; max-height: 220px; }
  .bot-picker.options-open { grid-template-rows: auto auto auto; }
  .options-open .picker-options { max-height: 380px; }
  .settings-preview { height: 100px; }
  .settings-scroll > label { min-height: 51px; }
  .clock { font-size: 15px; padding: 5px 7px; }
}
#candidate-lines { display: block; }
.board-row { display: block; position: relative; }
.eval-bar { position: absolute; width: 28px; right: calc(100% + 8px); top: 0; bottom: 0; }
.player-card .board-gear { margin-left: auto; }
@media (min-width: 731px) and (max-width: 1010px) {
  body:not(.hide-eval) .arena { margin-left: calc(var(--sidebar) + 37px); width: calc(100% - var(--sidebar) - 53px); }
}
@media (max-width: 730px) {
  .board-row { margin-left: 27px; }
  .hide-eval .board-row { margin-left: 0; }
  .eval-bar { width: 21px; right: calc(100% + 6px); }
}
#result-dialog.board-end-dialog { position: fixed; left: clamp(min(213px,50vw),var(--result-x,50vw),max(calc(100vw - 213px),50vw)); top: var(--result-y,42%); margin: 0; transform: translate(-50%,-50%); padding: 0; width: min(400px,calc(100% - 26px)); max-height: calc(100dvh - 24px); overflow-y: auto; border: 0; border-radius: 12px; background: #292722; }
@media (max-width:730px) { #result-dialog.board-end-dialog { left:50vw; } }
#result-dialog.board-end-dialog > h2 { margin: 0; padding: 25px 20px 9px; font-size: 24px; background: #3a3832; }
#result-dialog.board-end-dialog > p { background: #3a3832; padding: 0 20px 17px; margin: 0; font-size: 13px; }
#result-dialog.board-end-dialog > .btn { width: calc(100% - 64px); margin: 15px 32px 12px; min-height: 60px; font-size: 22px; }
.result-players { display: flex; align-items: center; justify-content: center; gap: 24px; padding: 16px 20px 0; }
.result-players > div { display: grid; gap: 5px; justify-items: center; width: 95px; min-width: 0; }.result-players strong { font-size: 12px; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.result-players span { width: 48px; height: 48px; background: #47443b; border-radius: 5px; font-size: 34px; display: grid; place-items: center; }.result-players .winner span { outline: 3px solid #9ac15e; }
.result-players > b { font-size: 23px; font-weight: 800; }
.result-secondary { display: flex; justify-content: center; gap: 25px; padding: 0 20px 15px; }.result-secondary .text-button { color: #bcb5a7; font-size: 12px; }
.result-marker { position: absolute; z-index: 6; right: -4%; top: -3%; display: grid; place-items: center; width: 38%; height: 38%; border-radius: 50%; color: white; font-size: clamp(12px,2.2vw,23px); pointer-events: none; box-shadow: 0 1px 3px #0003; }
.winner-marker { background: #9bc75c; }.loser-marker { background: #e54d49; }
.post-game-panel { padding: 14px 12px 0; }.post-game-panel > p { font-size: 13px; margin-bottom: 10px; color: #cdc6b8; }.post-game-panel > a { min-height: 52px; width: 100%; font-size: 19px; display: grid; place-items: center; }
.post-game-panel > div { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }.post-game-panel button { cursor: pointer; font-size: 14px; min-height: 40px; }
