/* MasaLobi Pişti V1.23 — 4-seat layout. Two-seat baseline remains untouched. */
.lobby-choice{
  display:block;width:100%;margin:7px 0 13px;padding:11px 12px;
  border:1px solid #b99963;border-radius:8px;
  background:#fffaf0;color:#1b2633;font:600 14px system-ui;
}
#create-room #room-mode-wrap[hidden]{display:none}
body.is-playing .pisti-four-seat{display:none}
body.is-playing #pisti-play[data-player-count="4"] .pisti-four-seat{
  position:absolute;display:flex;flex-direction:column;align-items:center;
  justify-content:center;gap:10px;top:37%;width:18%;max-width:160px;z-index:5;pointer-events:none;
}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-left{left:1.2%}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-right{right:1.2%}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label{
  display:flex;flex-direction:column;gap:2px;align-items:center;max-width:100%;
  padding:5px 8px;border:1px solid #c5a265;border-radius:9px;
  background:#051f28ef;text-align:center;color:#f8e2b8;
  box-shadow:0 2px 9px #002014aa;
}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label b{
  font:700 12px system-ui;overflow:hidden;text-overflow:ellipsis;max-width:100%;white-space:nowrap;
}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label small{
  font:600 10px system-ui;color:#b8ead2;max-width:100%;text-wrap:balance;
}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-cards{
  display:flex;justify-content:center;align-items:center;width:100%;height:65px;
}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-cards .salon-backcard{
  width:39px;height:55px;margin-right:-23px;flex-shrink:0;box-sizing:border-box;
}
body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-cards .salon-backcard:last-child{margin-right:0}
body.is-playing #pisti-play[data-player-count="4"] .salon-felt-widget{top:120px}
body.is-playing #pisti-play[data-player-count="4"] .salon-felt-widget strong{font-size:18px}
body.is-playing #pisti-play[data-player-count="4"] .center-play{gap:11px}
body.is-playing #pisti-play[data-player-count="4"] .salon-backcards{top:51px}
body.is-playing #pisti-play[data-player-count="4"] .salon-self-banner{bottom:105px}
body.is-playing #pisti-play[data-player-count="4"] .salon-opponent-banner{
  border-color:#cba66b;max-width:58%;
}
body.is-playing #pisti-play[data-player-count="4"][data-game-mode="teams"] .pisti-seat-label:has(small[data-teammate="true"]){
  border-color:#50d9ad;box-shadow:0 0 0 1px #368e73,0 2px 9px #002014aa;
}
body.is-playing #pisti-play[data-player-count="4"] .result-versus{
  display:flex;flex-wrap:wrap;justify-content:center;gap:8px;
}
@media(max-width:900px){
  body.is-playing #pisti-play[data-player-count="4"] .pisti-four-seat{width:22%;top:38%;gap:5px}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label{padding:3px 5px}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label b{font-size:10px}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label small{font-size:9px}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-cards .salon-backcard{width:29px;height:44px;margin-right:-18px}
  body.is-playing #pisti-play[data-player-count="4"] .salon-felt-widget{top:103px;min-width:0}
  body.is-playing #pisti-play[data-player-count="4"] .center-play{gap:5px}
}
@media(max-width:520px){
  body.is-playing #pisti-play[data-player-count="4"] .pisti-four-seat{top:43%;width:24%}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-left{left:0}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-right{right:0}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-cards .salon-backcard{width:24px;height:36px;margin-right:-16px;border-width:2px}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label b{font-size:9px}
  body.is-playing #pisti-play[data-player-count="4"] .pisti-seat-label small{font-size:8px}
  body.is-playing #pisti-play[data-player-count="4"] .center-play{top:55%}
  body.is-playing #pisti-play[data-player-count="4"] .salon-felt-widget{
    top:102px;font-size:9px;padding:3px;
  }
}

body.is-playing .pisti-four-scoreboard{display:grid;gap:6px;margin:14px 0}
body.is-playing .pisti-four-scoreline{
  display:flex;align-items:center;justify-content:space-between;gap:20px;
  border:1px solid #977043;border-radius:9px;padding:11px 13px;
  background:linear-gradient(110deg,#0a2b45,#081c34);color:#f3eee2;
}
body.is-playing .pisti-four-scoreline.is-mine{border-color:#e9bc66;background:#123d48}
body.is-playing .pisti-four-scoreline strong{font:800 21px Georgia,serif;color:#ffdd95}
body.is-playing .result-breakdown{display:table;width:100%;table-layout:fixed}
body.is-playing .result-breakdown td,body.is-playing .result-breakdown th{overflow-wrap:anywhere}

/* Phone: keep both lateral hands above the bottom hand; place deck between left seat and centre. */
@media(max-width:700px){
 body.is-playing #pisti-play[data-player-count="4"] .pisti-four-seat{top:22%}
 body.is-playing #pisti-play[data-player-count="4"] .salon-felt-widget{display:none}
 body.is-playing #pisti-play[data-player-count="4"] .center-play .game-deck{
  left:23%!important;top:49%!important;bottom:auto!important;
  transform:translateY(-50%)!important;
 }
}
@media(max-width:520px){
 body.is-playing #pisti-play[data-player-count="4"] .pisti-four-seat{top:22%}
}
