.tokens-room{width:min(100%,75rem);margin-inline:auto;text-align:left;color:var(--tokens-ink);font-variant-numeric:tabular-nums}
.game-shell .play .tokens-room .session-banner{max-width:none;margin:0 0 22px;text-align:left}
.game-shell .play .tokens-room .session-banner>:is(h2,.meta){max-width:none;margin-inline:0;text-align:left}
.game-shell .play .tokens-room p{max-width:none;margin-inline:0;text-align:left;line-height:1.65;color:var(--tokens-muted)}
.tokens-room button{font:inherit;touch-action:manipulation}
.tokens-room .button{min-height:44px;font-size:.92rem;white-space:normal;line-height:1.5}
.tokens-room button:focus-visible{outline:3px solid #868058;outline-offset:4px}
.tokens-room button:disabled{cursor:default;opacity:.35;transform:none}
.game-shell .play .tokens-room .actions{justify-content:flex-start;margin:20px 0 0;gap:10px}
.tokens-teams{display:flex;gap:30px;margin:0 0 22px;border-bottom:1px solid var(--tokens-line)}
.tokens-teams>div{display:flex;gap:18px;align-items:baseline;padding:10px 0 12px;min-width:0;border-bottom:3px solid transparent}
.tokens-teams strong{font-size:1rem;font-weight:650;color:#696a5b}
.tokens-teams span{font-size:.82rem;color:#696b5d}
.tokens-teams>[data-tokens-active=true]{border-bottom-color:#81754b}
.tokens-teams>[data-tokens-active=true]>strong{color:var(--tokens-ink)}
.tokens-desk{display:grid;grid-template-columns:minmax(0,1.3fr) minmax(280px,.85fr);gap:clamp(25px,5vw,75px);align-items:center}
.tokens-tray{width:min(100%,585px);border:1px solid #c3bea2;border-radius:22px;padding:clamp(14px,2.5vw,30px);background:linear-gradient(145deg,#efeedc,#e5e4cc);box-shadow:inset 0 0 0 4px #fffdf225,0 5px 0 #b9baa244,0 17px 25px #5658380a}
.tokens-pile{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:clamp(7px,1.5vw,18px)}
.tokens-position{min-width:0;aspect-ratio:1;display:grid;place-items:center}
.tokens-stone{display:block;position:relative;width:88%;height:77%;border:1px solid #b5a26d;border-radius:43% 51% 46% 45%;background:radial-gradient(ellipse at 32% 18%,#ffffff88,transparent 57%),repeating-linear-gradient(105deg,#a58a4f12 0 1px,transparent 1px 5px),linear-gradient(145deg,#e3d49d,#c4af77);box-shadow:inset 1px 3px 1px #fff2c4aa,inset 0 -5px 0 #9c874b35,0 4px 1px #96916b4d,0 7px 9px #4e50361c}
.tokens-position:nth-child(3n+1) .tokens-stone{transform:rotate(-8deg) translate(3%,4%)}
.tokens-position:nth-child(3n+2) .tokens-stone{transform:rotate(6deg) translate(-2%,-2%)}
.tokens-stone[data-tokens-piece-state=selected]{outline:3px solid #a16b40;outline-offset:3px}
.tokens-stone[data-tokens-piece-state=removed]{background:transparent;border:2px dashed #b9b59b;box-shadow:none;opacity:.65}
.tokens-control-desk{min-width:0;border-top:2px solid #a8ac8b;padding-top:19px}
.game-shell .play .tokens-room .tokens-remaining-label{font-size:.93rem;margin:0}
.tokens-count{display:block;font-size:clamp(4rem,8vw,7.2rem);font-weight:650;line-height:1.15;color:var(--tokens-ink);letter-spacing:-.035em}
.game-shell .play .tokens-room .tokens-turn-label{font-size:.88rem;margin:10px 0 17px;color:#6a6a5c}
.tokens-take-controls{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:11px}
.tokens-take{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-width:0;min-height:91px;padding:12px;border:1px solid #b9bda2;border-radius:5px;background:#fbfbef;color:#565842;box-shadow:0 3px 0 #b4b79b55;cursor:pointer;transition:background .13s,transform .13s}
.tokens-take>span{font-size:.82rem}
.tokens-take>strong{font-size:2rem;line-height:1;font-weight:650}
.tokens-take:enabled:hover{background:#f3edcf;transform:translateY(-2px)}
.tokens-take:enabled:active{transform:translateY(1px)}
.game-shell .play .tokens-room .tokens-rule{font-size:.92rem;margin:22px 0 0}
.game-shell .play .tokens-room .tokens-immediate{font-size:.84rem;margin:12px 0 0;color:#726956}
.game-shell .play .tokens-room .tokens-last-move{min-height:3.3em;font-size:.88rem;margin:18px 0 0}
.tokens-replay-layout{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(280px,1fr);gap:clamp(25px,4vw,65px);align-items:start}
.tokens-frame-controls{display:flex;gap:10px;flex-wrap:wrap;margin-bottom:14px}
.tokens-frame-controls>.button[aria-pressed=true]{border-color:#85835b;background:#eeefd8;color:#5b5f42;box-shadow:inset 0 0 0 1px #85835b}
.game-shell .play .tokens-room .tokens-frame-count{font-size:.9rem;margin:0 0 13px}
.tokens-frame-count>strong{font-size:1.45rem;margin-left:12px;color:var(--tokens-ink)}
.game-shell .play .tokens-room :is(.tokens-result-note,.tokens-removed-note,.tokens-last-rule){font-size:.88rem;margin:16px 0 22px}
.tokens-replay-desk{min-width:0;border-top:2px solid #a5ab8d;padding-top:17px}
.tokens-replay-summary h3{font-size:1rem;margin:0;font-weight:650;line-height:1.5}
.game-shell .play .tokens-room .tokens-replay-summary p{font-size:2rem;line-height:1.3;margin:12px 0;color:var(--tokens-ink)}
.tokens-history-heading{font-size:.96rem;margin:24px 0 13px;font-weight:650}
.tokens-record-list{list-style:none;padding:0;margin:0;display:grid;gap:6px;max-height:30dvh;overflow-y:auto;padding-right:6px}
.tokens-record-list button{display:flex;justify-content:space-between;gap:15px;align-items:center;width:100%;padding:10px 12px;min-height:44px;text-align:left;border:0;border-bottom:1px solid #d4d6bf;background:transparent;color:#5d6554;font-size:.9rem;line-height:1.5;cursor:pointer}
.tokens-record-list button>strong{font-size:.96rem;white-space:nowrap;color:#566345;font-weight:600}
.tokens-record-list button[aria-pressed=true]{background:#eaeed7;border-left:3px solid #8a925e}
.tokens-strategy{margin-top:22px;border-top:1px solid #c8ceb5;padding-top:12px}
.tokens-strategy summary{font-size:.9rem;min-height:44px;cursor:pointer;padding:7px 0}
.game-shell .play .tokens-room .tokens-strategy p{font-size:.88rem;line-height:1.7;margin:12px 0}
.tokens-strategy [data-tokens-decision=lost] .tokens-decision{color:#956343}
.tokens-strategy [data-tokens-decision=held] .tokens-decision,.tokens-strategy [data-tokens-decision=finish] .tokens-decision{color:#4c7950}
@media(max-width:800px){.tokens-desk,.tokens-replay-layout{grid-template-columns:minmax(0,1fr);gap:22px}.tokens-tray{max-width:510px}.tokens-control-desk,.tokens-replay-desk{max-width:510px}.tokens-count{font-size:4rem}.tokens-take{min-height:80px}.tokens-record-list{max-height:none;overflow:visible;padding-right:0}.tokens-room .button{font-size:.9rem}.tokens-teams{gap:22px}.tokens-teams>div{gap:12px}.tokens-pile{gap:10px}.tokens-record-list button{gap:12px}}
@media(max-width:400px){.tokens-room .button{font-size:.88rem}.tokens-tray{padding:14px;border-radius:16px}.tokens-pile{gap:7px}.tokens-teams>div{flex-direction:column;gap:3px}.tokens-count{font-size:3.6rem}.tokens-take-controls{gap:8px}.tokens-take{min-height:75px;padding:9px}.tokens-record-list button{font-size:.88rem}.tokens-record-list button>strong{font-size:.91rem}}
@media(prefers-reduced-motion:reduce){.tokens-take{transition:none}.tokens-take:enabled:hover{transform:none}}

.page-game .game-shell.theme-tokens:has(.tokens-room) {
  --tokens-ink:#192f34;
  --tokens-muted:#465b5c;
  --tokens-line:#b6c3ba;
  --tokens-teal:#265959;
  --tokens-rust:#9a4429;
  background:#f3f3e9;
  color:var(--tokens-ink);
}
.page-game .game-shell.theme-tokens:has(.tokens-room) .game-toolbar {
  background:#f3f3e9;
  border-color:var(--tokens-line);
  color:var(--tokens-ink);
}
.game-shell.theme-tokens .play .tokens-room .session-banner { margin-bottom:.8rem }
.game-shell.theme-tokens .play .tokens-room .session-banner h2 {
  color:var(--tokens-ink);
  font-size:clamp(1.75rem,4.2vw,3.3rem);
  letter-spacing:-.035em;
  text-wrap:balance;
}
.game-shell.theme-tokens .play .tokens-room .session-banner .meta { color:var(--tokens-muted) }
.tokens-teams { gap:clamp(.5rem,2vw,1.5rem);margin:0 0 1rem }
.tokens-teams>div { padding:.45rem .6rem .5rem;gap:.55rem }
.tokens-teams :is(strong,span) { color:var(--tokens-muted) }
.tokens-teams>[data-tokens-active=true] {
  border-color:var(--tokens-teal);
  background:#e0ece6;
}
.tokens-teams>[data-tokens-active=true][data-tokens-side="1"] {
  border-color:var(--tokens-rust);
  background:#f6e5d8;
}
.tokens-desk,.tokens-replay-layout {
  grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);
  gap:clamp(1.25rem,4.4vw,4rem);
}
.tokens-tray {
  width:100%;
  padding:clamp(.6rem,1.6vw,1.25rem);
  border:1px solid #2c5255;
  border-radius:clamp(.75rem,2vw,1.45rem);
  background:linear-gradient(135deg,#326763,#1b4147);
  box-shadow:inset 0 0 0 4px #ffffff15,0 .35rem 0 #183639,0 .9rem 1.4rem #18363924;
}
.tokens-pile {
  column-gap:clamp(.3rem,1vw,.8rem);
  row-gap:clamp(.25rem,.9vh,.65rem);
}
.tokens-position {
  aspect-ratio:auto;
  height:clamp(2.1rem,min(5.7vw,8.5dvh),4.8rem);
  border-radius:48%;
  background:radial-gradient(ellipse at center,#122e3270 0 60%,transparent 69%);
}
.tokens-stone {
  width:clamp(1.65rem,78%,4.75rem);
  height:78%;
  border-color:#a99069;
  background:
    radial-gradient(ellipse at 30% 15%,#ffffffd9 0 7%,#ffffff45 28%,transparent 48%),
    radial-gradient(ellipse at 62% 20%,#ffebce,#ead4b0 68%,#baa382 100%);
  box-shadow:inset 1px 2px 1px #fff6de,0 3px 0 #23333590,0 6px 8px #0d222659;
}
.tokens-stone[data-tokens-piece-state=selected] {
  outline-color:#ffbf78;
}
.tokens-stone[data-tokens-piece-state=removed] {
  border-color:#d7e0d0;
  opacity:1;
}
.tokens-control-desk,.tokens-replay-desk {
  border-color:var(--tokens-line);
  padding-top:.75rem;
}
.tokens-count { line-height:1; font-weight:800 }
.game-shell .play .tokens-room .tokens-turn-label { color:var(--tokens-muted);margin:.35rem 0 .8rem }
.tokens-take-controls { gap:clamp(.35rem,1.2vw,.75rem) }
.tokens-take {
  min-height:clamp(3.65rem,9vh,5rem);
  color:#fff;
  background:#245654;
  border-color:#204c4a;
  border-radius:.55rem;
  box-shadow:0 3px 0 #183738;
}
.tokens-take:enabled:hover { background:#316966 }
.tokens-take:disabled {
  opacity:1;
  color:#526460;
  background:#e4e9df;
  border-color:#9ea9a2;
  box-shadow:none;
}
.game-shell .play .tokens-room .tokens-last-move { min-height:0;margin:.85rem 0 0 }
.game-shell .play .tokens-room .tokens-rule { margin:.95rem 0 0 }
.game-shell .play .tokens-room .tokens-immediate { color:var(--tokens-muted);margin:.4rem 0 0 }
.game-shell .play .tokens-room .actions { margin-top:.85rem;flex-wrap:wrap }
.page-game .game-shell.theme-tokens:has(.tokens-room) .game-toolbar .button,
.page-game .game-shell.theme-tokens .play .tokens-room .button.secondary {
  color:var(--tokens-ink);
  background:#fbfcf5;
  border-color:#899d94;
}
.page-game .game-shell.theme-tokens .play .tokens-room .button.cta {
  color:white;
  background:var(--tokens-teal);
  border-color:var(--tokens-teal);
}
.page-game .game-shell.theme-tokens .play .tokens-room .button.cta:hover { background:#1a4343 }
.page-game .game-shell.theme-tokens .play .tokens-room .button:disabled {
  color:#526460;
  background:#e4e9df;
  border-color:#9ea9a2;
  opacity:1;
}
.page-game .game-shell.theme-tokens .play .tokens-room .button[aria-pressed=true],
.tokens-record-list button[aria-pressed=true] {
  background:#d9e9e2;
  color:var(--tokens-ink);
  border-color:var(--tokens-teal);
}
.tokens-record-list button,.tokens-record-list button>strong { color:var(--tokens-ink) }
@media(max-width:800px) {
  .tokens-desk,.tokens-replay-layout { grid-template-columns:1fr;gap:1.1rem }
  .tokens-desk>section { display:contents }
  .tokens-desk .tokens-tray { grid-row:1 }
  .tokens-desk .tokens-control-desk { grid-row:2 }
  .game-shell .play .tokens-desk .tokens-last-move { margin:0 }
  .tokens-tray,.tokens-control-desk,.tokens-replay-desk { max-width:none }
  .tokens-position { height:clamp(2.1rem,10vw,3.8rem) }
  .tokens-control-desk { padding-top:.6rem }
}
@media(max-width:540px) {
  .game-shell.theme-tokens.wide:has(.tokens-room) .game-toolbar {
    display:grid;
    grid-template-columns:minmax(0,1fr);
    gap:.25rem;
    padding:.4rem .75rem;
  }
  .game-shell.theme-tokens.wide:has(.tokens-room) .game-toolbar-title { display:flex;padding:0 }
  .game-shell.theme-tokens.wide:has(.tokens-room) .game-toolbar-title strong {
    white-space:normal;
  }
  .game-shell.theme-tokens.wide:has(.tokens-room) .game-toolbar-actions {
    justify-content:flex-start;
    margin:0;
  }
  .page-game .game-shell.theme-tokens.wide .play:has(.tokens-room) {
    justify-content:flex-start;
    min-height:0;
    margin-block:0;
    padding-block:.85rem 2rem;
  }
}
@media(max-width:400px) {
  .tokens-count { font-size:3.2rem }
  .tokens-take { min-height:3.65rem;padding:.35rem }
}

