/* The next game starts with one compact setup card. */
.control-panel .setup-identity{display:flex;align-items:center;justify-content:space-between;flex-wrap:nowrap;gap:12px;padding:10px 20px;border-bottom:1px solid var(--line);margin:0;min-width:0}
.control-panel .setup-identity>div{min-width:0;flex:1}
.control-panel .setup-identity strong{font-size:17px;overflow-wrap:anywhere}
.control-panel .setup-identity button{width:auto;min-height:44px;margin:0;padding:7px 12px;font-size:16px}
.control-panel #account-stats{display:none}
.control-panel #new-game,.control-panel #find-game,.control-panel #create-room{background:#e8b859;color:#20252b;border:1px solid #e8b859;font-weight:700;min-height:50px;font-size:19px;opacity:1}
.control-panel #new-game:disabled,.control-panel #find-game:disabled,.control-panel #create-room:disabled{opacity:.65}
.control-panel #bot-panel[data-match-phase=finished]{display:none!important}
.control-panel #online-panel[data-match-phase=finished].match-running{display:none!important}
body[data-game-stage=finished] #play-view .game-play-status,body[data-game-stage=finished] #play-view .premove-tools{display:none}
body[data-game-mode=bot][data-game-stage=setup] #play-view .game-play-status,body[data-game-mode=bot][data-game-stage=setup] #play-view .game-utility-panel,body[data-game-mode=bot][data-game-stage=setup] #play-view .notation,body[data-game-mode=bot][data-game-stage=setup] #play-view #my-stats{display:none}
body[data-game-stage=setup] #play-view .control-panel .panel-body>.eyebrow,body[data-game-stage=setup] #play-view .bot-profile,body[data-game-stage=setup] #play-view .gentle-note,body[data-game-stage=setup] #play-view #hint,body[data-game-stage=setup] #play-view .time-categories,body[data-game-stage=setup] #play-view .rules-link{display:none}
body[data-game-stage=setup] #play-view .control-panel .panel-body{padding:14px 20px}
body[data-game-stage=setup] #play-view .field-label{margin-top:14px;margin-bottom:7px}
body[data-game-stage=setup] #play-view .time-note{margin:6px 0 0;font-size:14px}
body[data-game-stage=setup] #play-view #new-game{margin-top:18px;margin-bottom:0}
body[data-game-stage=setup] #play-view #bot-panel #level{margin-top:6px}
/* Online and friend setup share the desktop board layout with computer play. */
@media(max-width:900px),(pointer:coarse){
 body[data-game-mode=online][data-game-stage=setup] #play-view .workspace>.board-column,body[data-game-mode=online][data-game-stage=waiting] #play-view .workspace>.board-column{display:none!important}
 body[data-game-mode=online][data-game-stage=setup] #play-view .workspace,body[data-game-mode=online][data-game-stage=waiting] #play-view .workspace{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto!important;height:auto!important;max-width:560px;width:100%;margin-inline:auto;justify-content:center;align-content:start;gap:0;min-height:0}
 body[data-game-mode=online][data-game-stage=setup] #play-view .workspace>.control-panel,body[data-game-mode=online][data-game-stage=waiting] #play-view .workspace>.control-panel{grid-column:1!important;grid-row:1!important;display:block!important;height:auto!important;max-height:none;width:100%;justify-self:center;overflow:visible}
}
@media(pointer:coarse){
 body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace>.board-column{display:none!important}
 body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto!important;width:100%;max-width:560px;margin-inline:auto;align-content:start;min-height:0;height:auto!important;gap:0}
 body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace>.control-panel{grid-column:1!important;grid-row:1!important;width:100%;max-height:none;height:auto!important;display:block!important;overflow:visible}
}
@media(max-width:900px){
 body[data-game-stage=setup] #play-view .workspace>.board-column,body[data-game-stage=waiting] #play-view .workspace>.board-column{display:none!important}
 body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto!important;width:100%;max-width:560px;margin-inline:auto;justify-content:center;align-content:start;min-height:0;height:auto!important;gap:0}
 body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace>.control-panel{grid-column:1!important;grid-row:1!important;width:100%;justify-self:center;max-height:none;height:auto!important;display:block!important;overflow:visible}
 body[data-game-stage=setup] #play-view .mode-tabs{display:flex!important;flex-direction:row!important;padding:4px;gap:3px;border-right:0}
 body[data-game-stage=setup] #play-view .mode-tabs button{flex:1;padding:8px 5px;min-height:44px;font-size:16px}
 body[data-game-stage=setup] #play-view .setup-identity{padding:8px 16px}
 body[data-game-stage=setup] #play-view .panel-body{padding:12px 16px!important}
 body[data-game-stage=setup] #play-view .difficulty-label{margin-top:0}
 body[data-game-stage=setup] #play-view .segmented button{min-height:44px;padding:8px 5px;font-size:16px}
 body[data-game-stage=setup] #play-view select{min-height:46px;font-size:16px}
}
@media(min-width:540px) and (max-height:600px) and (max-width:900px),(min-width:540px) and (max-height:600px) and (pointer:coarse){
 body[data-game-stage=setup] #play-view .workspace,body[data-game-stage=waiting] #play-view .workspace{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto!important;width:100%;max-width:660px;margin-inline:auto;align-content:start;height:auto!important;gap:0}
 body[data-game-stage=setup] #play-view .workspace>.board-column,body[data-game-stage=waiting] #play-view .workspace>.board-column{display:none!important}
 body[data-game-stage=setup] #play-view .workspace>.control-panel,body[data-game-stage=waiting] #play-view .workspace>.control-panel{grid-column:1!important;grid-row:1!important;display:block!important;height:auto!important;max-height:none;overflow:visible;width:100%}
 body[data-game-stage=setup] #play-view #bot-panel:not([hidden]){display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px 16px;padding:10px 16px!important}
 body[data-game-stage=setup] #play-view .bot-strength-choice,body[data-game-stage=setup] #play-view #new-game{grid-column:1/-1}
 body[data-game-stage=setup] #play-view .field-label{margin:0 0 5px!important}
 body[data-game-stage=setup] #play-view .difficulty-label{margin:0!important}
 body[data-game-stage=setup] #play-view #level{min-height:24px;margin:0!important}
 body[data-game-stage=setup] #play-view .range-labels{display:none}
 body[data-game-stage=setup] #play-view .time-note{display:none}
 body[data-game-stage=setup] #play-view #new-game{margin:4px 0 0!important;min-height:44px;padding:8px 12px}
 body[data-game-stage=setup] #play-view .mode-tabs{display:flex!important;flex-direction:row!important;padding:3px;gap:2px}
 body[data-game-stage=setup] #play-view .mode-tabs button{flex:1;min-height:44px;font-size:15px;padding:7px 4px}
}
html[data-android-app=true] body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace>.board-column{display:none!important}
html[data-android-app=true] body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto!important;width:100%;max-width:560px;margin-inline:auto;align-content:start;min-height:0;height:auto!important;gap:0}
html[data-android-app=true] body[data-game-mode=bot][data-game-stage=setup] #play-view .workspace>.control-panel{grid-column:1!important;grid-row:1!important;width:100%;max-height:none;height:auto!important;display:block!important;overflow:visible}
html[data-android-app=true] body[data-game-mode=online]:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view .workspace>.board-column{display:none!important}
html[data-android-app=true] body[data-game-mode=online]:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view .workspace{grid-template-columns:minmax(0,1fr)!important;grid-template-rows:auto!important;width:100%;max-width:560px;margin-inline:auto;align-content:start;min-height:0;height:auto!important;gap:0}
html[data-android-app=true] body[data-game-mode=online]:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view .workspace>.control-panel{grid-column:1!important;grid-row:1!important;width:100%;max-height:none;height:auto!important;display:block!important;overflow:visible}

/* A normal starting board with the setup window in front of it. */
.setup-backdrop{display:none;pointer-events:none}
@media(max-width:900px),(pointer:coarse){
 body:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view{position:relative;isolation:isolate;min-height:var(--setup-board-size,320px)}
 body:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view>.setup-backdrop{display:block;position:absolute;inset:0;overflow:hidden;z-index:0;border-radius:8px;pointer-events:none}
 body:is([data-game-stage=setup],[data-game-stage=waiting]) .setup-backdrop>.position-preview{position:absolute;width:var(--setup-board-size,100%);max-width:100%;height:auto;left:50%;top:50%;transform:translate(-50%,-50%);opacity:1;filter:none;border:1px solid var(--line);border-radius:5px}
 body:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view>.workspace{position:relative;z-index:1;padding:18px;min-height:var(--setup-board-size,320px);align-content:center!important}
 body:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view .control-panel{position:relative;isolation:isolate;background:transparent!important;box-shadow:0 8px 24px #0002}
 body:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view .control-panel::before{content:'';position:absolute;inset:0;z-index:-1;background:var(--paper);opacity:.78;border-radius:inherit;pointer-events:none}
 body:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view .time-note{width:fit-content;max-width:100%;padding-inline:4px;background:var(--paper);color:var(--muted)!important;border-radius:4px}
}
@media(max-height:650px){
 body:is([data-game-stage=setup],[data-game-stage=waiting]) #play-view>.workspace{padding:4px 12px}
}
