/* the play page: the round fills the screen; the controls sit left, the real wallets right, the blocks between */
body.play { min-height: 100vh; }
.top .chip .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); display: inline-block; }
.top .chip[data-state='live'] .dot { background: var(--acc); box-shadow: 0 0 0 4px rgba(42, 157, 255, .2); }
.top .chip[data-state='paused'] .dot { background: var(--ink-2); }
.top .chip[data-state='end'] .dot { background: var(--ink); }

.game { position: relative; display: grid; grid-template-columns: 392px minmax(0, 1fr) 336px; gap: 0 24px; padding: 116px var(--gutter) 28px; min-height: 100vh; max-width: 1520px; margin: 0 auto; }
.hud, .side { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.side { grid-column: 3; }

.bug { display: flex; align-items: stretch; height: 48px; font-family: var(--cond); font-style: italic; border-radius: 12px; overflow: hidden; border: 1px solid var(--line-2); background: rgba(18, 20, 23, .8); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.bug .rp { background: var(--acc); color: var(--acc-ink); font-weight: 900; font-size: 22px; padding: 0 13px; display: flex; align-items: center; }
.bug .rd { color: var(--ink); font-weight: 800; font-size: 19px; padding: 0 14px; display: flex; align-items: center; border-right: 1px solid var(--line-2); flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; }
.bug .ck { padding: 0 14px; display: flex; align-items: center; gap: 6px; }
.bug .ck b { font-weight: 900; font-size: 30px; }
.bug .ck small { font-size: 17px; color: var(--muted); font-weight: 700; }
.ctrl { display: flex; gap: 6px; }
.sp { height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(18, 20, 23, .7); color: var(--ink-2); font: italic 800 18px/1 var(--cond); cursor: pointer; }
.sp[aria-pressed='true'] { color: var(--acc); border-color: var(--acc); background: var(--acc-dim); }
.sp[data-pause] { font: 600 14px/1 var(--text); }

.capcard .cap { display: block; font: italic 900 62px/1 var(--cond); margin-top: 6px; letter-spacing: -.005em; }
.trace { display: block; width: 100%; height: 60px; margin-top: 8px; }
.card-foot { display: flex; justify-content: space-between; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.bag { display: flex; align-items: baseline; gap: 12px; margin-top: 6px; }
.bag b { font: italic 900 48px/1 var(--cond); }
.bag em { font: italic 900 28px/1 var(--cond); }
.sub { margin: 8px 0 0; color: var(--ink-2); font-size: 14.5px; }
.chips { display: flex; gap: 6px; margin: 14px 0 10px; }
.chips button { flex: 1; height: 36px; border-radius: 10px; border: 1px solid var(--line-2); background: transparent; display: grid; place-items: center; font: italic 800 19px/1 var(--cond); color: var(--ink-2); cursor: pointer; }
.chips button.on { border-color: var(--acc); color: var(--acc); background: var(--acc-dim); }
.acts { display: flex; flex-direction: column; gap: 8px; }
.bagcard .btn-primary { height: 54px; font-size: 17px; }
.sells { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.sells .btn { height: 44px; padding: 0 10px; font-size: 15px; }
kbd { font: 600 11px/1 var(--text); padding: 3px 5px; border-radius: 5px; border: 1px solid currentColor; opacity: .55; margin-left: 4px; }

.tower .r:first-child { margin-top: 8px; }
.side .tower .r { grid-template-columns: 34px 1fr 78px; }
.tape > div:last-child { margin-top: 8px; }
.tape .row { display: grid; grid-template-columns: 38px 44px 1fr 74px; gap: 6px; align-items: center; padding: 7px 0; border-top: 1px solid var(--line); font-size: 13.5px; color: var(--ink-2); animation: in .35s var(--spring); }
.tape .s { font: italic 900 16px/1 var(--cond); }
.tape .s.b { color: var(--ink); }
.tape .w { color: var(--ink); }
.tape .r { text-align: right; }
@keyframes in { from { opacity: 0; transform: translateY(-6px); } }

.lower { grid-column: 2; align-self: end; justify-self: center; display: flex; height: 46px; font-family: var(--cond); font-style: italic; opacity: 0; transform: translateY(10px); transition: opacity .3s var(--ease), transform .45s var(--spring); }
.lower.on { opacity: 1; transform: none; }
.lower .tag { background: var(--ink); color: var(--ground); font-weight: 900; font-size: 20px; padding: 0 14px; display: flex; align-items: center; border-radius: 10px 0 0 10px; }
.lower .txt { background: rgba(18, 20, 23, .9); border: 1px solid var(--line-2); border-left: 0; color: var(--ink); font-weight: 800; font-size: 23px; padding: 0 18px; display: flex; align-items: center; gap: 12px; border-radius: 0 10px 10px 0; }
.lower .txt span { font: 600 14px var(--text); color: var(--muted); font-style: normal; }

/* before and after the round */
.over { position: fixed; inset: 0; z-index: 45; display: grid; place-items: center; padding: 110px var(--gutter) 24px; background: rgba(10, 11, 13, .55); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); overflow-y: auto; }
.panel { width: min(560px, 100%); padding: 28px 30px; animation: rise .55s var(--spring); }
@keyframes rise { from { opacity: 0; transform: translateY(18px) scale(.98); } }
.panel .kick { margin: 0 0 12px; font: italic 800 22px/1 var(--cond); color: var(--acc); }
.panel h1 { margin: 0; font: italic 900 64px/.9 var(--cond); }
.panel .body { margin: 16px 0 0; color: var(--ink-2); font-size: 17px; }
.facts { margin: 18px 0 0; display: grid; }
.facts > div { display: grid; grid-template-columns: 11em 1fr; gap: 12px; padding: 9px 0; border-top: 1px solid var(--line); }
.facts dt { font: 600 14px/1.5 var(--text); color: var(--muted); }
.facts dd { margin: 0; font: 600 15px/1.5 var(--text); }
.panel .acts { margin-top: 22px; flex-direction: row; flex-wrap: wrap; }
.btn.big { height: 56px; padding: 0 28px; font-size: 17px; }
.note { margin: 14px 0 0; font-size: 13.5px; color: var(--muted); }
.picker { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.picker a { min-width: 44px; height: 36px; padding: 0 10px; border-radius: 10px; border: 1px solid var(--line-2); display: grid; place-items: center; text-decoration: none; font: italic 800 18px/1 var(--cond); color: var(--ink-2); }
.picker a[aria-current='true'] { border-color: var(--acc); color: var(--acc); background: var(--acc-dim); }
.picker a small { font: 600 11px var(--text); margin-left: 4px; color: var(--muted); }
.ft-head { display: flex; align-items: stretch; height: 46px; margin: -28px -30px 0; border-bottom: 1px solid var(--line-2); font-family: var(--cond); font-style: italic; overflow: hidden; border-radius: 18px 18px 0 0; }
.ft-tag { background: var(--acc); color: var(--acc-ink); font-weight: 900; font-size: 22px; padding: 0 16px; display: flex; align-items: center; }
.ft-name { font-weight: 900; font-size: 26px; padding: 0 14px; display: flex; align-items: center; }
.ft-when { color: var(--muted); font: 500 13px var(--text); display: flex; align-items: center; }
.ft-big { margin: 20px 0 0; font: italic 900 60px/.92 var(--cond); }
.ft-big em { font-style: italic; color: var(--acc); }
.final { margin-top: 16px; }
.final .r { grid-template-columns: 34px 1fr 64px 78px; }

@media (max-width: 1180px) { .game { grid-template-columns: 360px minmax(0, 1fr) 300px; } }
@media (max-width: 899px) {
  .game { display: flex; flex-direction: column; padding: 46vh var(--gutter) 24px; }
  .lower { order: -1; align-self: center; position: fixed; top: calc(98px + 34vh); left: 50%; transform: translate(-50%, 10px); z-index: 5; }
  .lower.on { transform: translate(-50%, 0); }
  .lower .txt { font-size: 18px; } .lower .txt span { display: none; }
  .hud, .side { width: 100%; }
  .bug .rd { display: none; }
  .capcard .cap { font-size: 48px; }
  .panel { padding: 22px 20px; } .ft-head { margin: -22px -20px 0; } .ft-when { display: none; }
  .panel h1 { font-size: 50px; } .ft-big { font-size: 46px; }
  .over { place-items: end center; }
}

/* ranked: one attempt in real time, a name on the board */
.ranked .ctrl { display: none; }
.namebox { display: grid; gap: 8px; margin-top: 18px; }
.namebox input { height: 50px; padding: 0 16px; border-radius: 12px; border: 1px solid var(--line-3); background: rgba(10, 11, 13, .6); color: var(--ink); font: 600 17px/1 var(--text); outline: none; transition: border-color .2s var(--ease), box-shadow .2s var(--ease); }
.namebox input:focus { border-color: var(--acc); box-shadow: 0 0 0 4px var(--acc-dim); }
.namebox input::placeholder { color: var(--muted); }
.picker a.rk { padding: 0 14px; font: 700 14px/1 var(--text); color: var(--acc); border-color: rgba(42, 157, 255, .4); }
.board:empty { display: none; }
.board { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.board .r { grid-template-columns: 34px 1fr 64px 78px; }
.board .r .s { color: var(--muted); }
.closed .game { visibility: hidden; }

/* phones mid-round: the trade buttons stay under the thumb, the tab bar steps aside */
@media (max-width: 899px) {
  .running .tabbar { display: none; }
  .running .bagcard { backdrop-filter: none; -webkit-backdrop-filter: none; background-color: rgba(18, 20, 23, .94); } /* a filter on the card would hold the fixed bar inside it */
  .running body { padding-bottom: calc(118px + env(safe-area-inset-bottom)); }
  .running .bagcard .acts { position: fixed; inset: auto 0 0; z-index: 44; padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom)); background: rgba(10, 11, 13, .92); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-top: 1px solid var(--line-2); }
  .running .bagcard .acts .btn-primary { height: 50px; }
  .running .sells .btn { height: 40px; }
}
