/* Shared-table pieces and play surfaces */
.table-game {
  --felt: #224e44;
  --felt-deep: #122e31;
  --foil: #eccb85;
  --social-ink: #fff8ea;
}
.table-game:is([data-game="liar"],[data-game="mafia"],[data-game="switches"],[data-game="escape"]) {
  --felt: #394761; --felt-deep: #192331; --foil: #f1bc79;
}
.table-game:is([data-game="authors"],[data-game="telephone"],[data-game="partner"],[data-game="fakes"],[data-game="auction"]) {
  --felt: #654354; --felt-deep: #392a3a; --foil: #f4c49d;
}
.table-game:is([data-game="ladder"],[data-game="sequence"],[data-game="lowest"],[data-game="forehead"]) {
  --felt: #285e71; --felt-deep: #183e49; --foil: #bde8da;
}
.table-game > .gt-stack > .gt-feature:not(.gt-handoff):not(.gt-secret-card) {
  background: radial-gradient(ellipse at 16% -25%, var(--felt) 12%, transparent 75%), var(--felt-deep);
  padding: clamp(1rem, 3vw, 1.8rem); border: 1px solid var(--felt);
  box-shadow: inset 0 0 0 4px var(--felt-deep), inset 0 0 0 5px color-mix(in srgb,var(--foil) 35%,transparent);
  color: var(--social-ink); overflow-wrap: anywhere;
}
.table-game > .gt-stack > .gt-feature:not(.gt-handoff):not(.gt-secret-card) small { color: var(--foil); }
.table-game .social-choices, .table-game .social-duel {
  display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,8rem),1fr)); gap: .65rem;
}
.table-game .social-choices button, .table-game .social-duel button {
  position: relative; min-height: 3.5rem; box-shadow: 0 3px 0 var(--control-line); border-radius: 11px;
  overflow-wrap: anywhere; touch-action: manipulation;
}
.table-game .social-choices button:active, .table-game .social-duel button:active { transform: translateY(2px); }
.table-game[data-game="lowest"] .social-choices { grid-template-columns: repeat(5,minmax(0,1fr)); }
.table-game[data-game="lowest"] .social-choices button { padding-inline: 0; font-size: 1.3rem; font-variant-numeric: tabular-nums; }
.table-game .social-duel { grid-template-columns: repeat(2,minmax(0,1fr)); }
.table-game .social-duel button {
  min-height: clamp(6rem,15vw,11rem); padding: 1rem .5rem; background: #285759; color: #fff9e7;
  border: 2px solid #73a5a4; box-shadow: inset 0 0 0 4px #285759, inset 0 0 0 5px #91beb4, 0 3px 0 #1a3c3d;
  font-size: clamp(1.1rem,3vw,2rem);
}
.table-game .social-duel button:nth-child(2) { background: #743e4d; border-color: #bc8190; box-shadow: inset 0 0 0 4px #743e4d,inset 0 0 0 5px #d5a6a7,0 3px 0 #512b35; }
.table-game .social-duel button:hover:enabled { background: #326465; color: white; }
.table-game .social-duel button:nth-child(2):hover:enabled { background: #85485b; }
.table-game .social-order { display: grid; grid-template-columns: 1fr auto auto; background:var(--bg); border:1px solid var(--line); border-left:4px solid var(--accent); border-radius:10px; padding:.32rem .45rem .32rem .75rem; }
.table-game .social-order button { min-width:44px; }
.table-game .social-quote { border-inline-start: 4px solid var(--accent); padding:.75rem 1rem; background:var(--bg); border-radius:4px 12px 12px 4px; overflow-wrap:anywhere; }
.table-game .social-quote h3 { font-size:1rem; margin:0; }
.social-totals { list-style:none; display:grid; gap:.55rem; padding:0; margin:0; }
.social-totals li { display:flex; justify-content:space-between; gap:.5rem; padding:.45rem .65rem .7rem; border:1px solid var(--line); border-radius:8px; background:linear-gradient(to right,var(--accent) var(--share),var(--line) var(--share)) bottom / 100% 4px no-repeat; }
.social-totals li strong {overflow-wrap:anywhere}
.social-totals li span {white-space:nowrap}
.social-dice { display:flex; gap:clamp(.45rem,2vw,1rem); flex-wrap:wrap; align-items:center; justify-content:center; padding:1.1rem; background:radial-gradient(ellipse at top,var(--felt),var(--felt-deep)); border-radius:14px; box-shadow:inset 0 2px 6px #0004; }
.social-die { display:grid; grid-template: repeat(3,1fr) / repeat(3,1fr); width:clamp(2.8rem,9vw,4.8rem); aspect-ratio:1; padding:.5rem; gap:2px; box-sizing:border-box; background:linear-gradient(135deg,#fffcf1,#e1d7c0); border-radius:19%; box-shadow:0 4px 0 #b7a990,0 7px 9px #001b1c88; }
.social-die:nth-child(2) {transform:rotate(6deg)}
.social-die i { background:#273333; border-radius:50%; }
.social-die.social-hit {outline:3px solid #ffc453;outline-offset:2px}
.table-game .social-dice-row { display:grid;grid-template-columns:minmax(4rem,1fr) minmax(9rem,2fr); align-items:center; }
.social-dice-row .social-dice {padding:.5rem}
.social-dice-row .social-die {width:2.5rem;padding:.35rem;}
.social-clock .gt-actions {justify-content:space-between;font-variant-numeric:tabular-nums;}
.social-clock progress {width:100%;height:.6rem;accent-color:var(--accent)}
.table-game[data-game="forehead"] .social-clock + .gt-feature strong {font-size:clamp(2.7rem,8vw,6rem)}
.table-game[data-game="forehead"] .social-clock ~ .gt-actions button:first-child,
.table-game[data-game="forehead"] .social-clock ~ .gt-actions button:nth-child(2) {flex:1;min-height:3.7rem;font-size:1.25rem}
.table-game[data-game="forehead"] .social-clock ~ .gt-actions button:last-child {min-height:44px;}
.social-missions label { display:flex; align-items:center; gap:.65rem; min-height:48px; padding:.45rem .75rem; border:1px solid var(--control-line); border-radius:9px; cursor:pointer; }
.social-missions label:has(:checked) { background:var(--tint); border-color:var(--accent); }
.table-game .social-missions input { min-height:0; width:1.1rem;height:1.1rem;accent-color:var(--accent);flex:none; }
.table-game .social-switches { gap:.6rem; padding:clamp(.65rem,3vw,1.2rem); background:#27343b; border:4px solid #435058; border-radius:14px; }
.table-game .social-switches :is(button,span) { position:relative; min-height:3.25rem; padding:.4rem .1rem .7rem; background:linear-gradient(#53646c,#394852); color:#fff9e6; border:1px solid #8aa1a7; box-shadow:0 4px 0 #11242c; }
.social-switches :is(button,span)::after {content:"";position:absolute;bottom:5px;left:42%;width:16%;height:3px;border-radius:4px;background:#f1be75;}
.table-game .social-switches button:disabled {opacity:1; color:#c1d7cf; background:#303f45; transform:translateY(3px); box-shadow:inset 0 2px 4px #17262d;}
.social-switches button:disabled::after {background:#84dba0}
@media(prefers-reduced-motion:no-preference) {
  .social-ladder-path {stroke-dasharray:1; animation: social-trace .55s ease-out;}
  @keyframes social-trace {from {stroke-dashoffset:1} to {stroke-dashoffset:0}}
}
.table-game[data-game="ladder"] .gt-diagram { padding-block:.6rem; border-radius:12px; background:var(--bg); }
.table-game .social-gonu.gt-board {
  position:relative; isolation:isolate; width:min(100%,23rem); padding:0; gap:0; border-radius:17px; overflow:hidden;
  background:repeating-linear-gradient(6deg,#0000 0 14px,#67402412 15px 16px),linear-gradient(120deg,#e2ba82,#e9cb98 45%,#caa16d);
  box-shadow:inset 0 0 0 4px #a5784c,inset 0 0 0 7px #e8bf88;
}
.social-gonu::before {content:"";position:absolute;inset:16.667%;border:2px solid #735339;border-right:0;z-index:-1;
  background:linear-gradient(45deg,transparent calc(50% - 1px),#735339 50%,transparent calc(50% + 2px)),linear-gradient(-45deg,transparent calc(50% - 1px),#735339 50%,transparent calc(50% + 2px));}
.table-game .social-gonu.gt-board button {position:relative;opacity:1;background:transparent!important;color:transparent!important;border:0;box-shadow:none;}
.social-gonu button[data-stone]::after {content:"";display:block;position:absolute;width:53%;aspect-ratio:1;border-radius:50%;top:50%;left:50%;transform:translate(-50%,-50%);}
.social-gonu button[data-stone="1"]::after {background:radial-gradient(circle at 34% 24%,#657073,#202b2c 48%,#101a1c); box-shadow:0 4px 3px #36272077;}
.social-gonu button[data-stone="2"]::after {background:radial-gradient(circle at 34% 24%,white,#f8e7c2 55%,#c4b594); box-shadow:0 4px 3px #36272077;}
.social-gonu button[data-stone="0"]::after {width:14%;background:#825f3e;box-shadow:0 0 0 4px #e9cb98;}
.social-gonu button:enabled::after {outline:3px dashed #226356;outline-offset:4px;}
.social-gonu button:focus-visible {outline:3px solid #254b79!important;outline-offset:-5px;}
.table-game[data-game="yut"] .gt-diagram {background:radial-gradient(ellipse at center,#dfc9a0,#f4e2be);border:4px solid #ac845b;border-radius:16px;max-width:24rem;--control-line:#785b43;--tint:#fff1ca;}
.table-game[data-game="yut"] .gt-feature {grid-template-columns:auto auto;column-gap:1rem;align-items:center;}
.social-sticks { display:flex; grid-row:span 2; align-items:center;gap:4px; padding:.2rem;}
.social-sticks i {display:block;height:3.3rem;width:.6rem;border-radius:60% / 13%;transform:rotate(6deg); background:linear-gradient(to right,#9c6235,#e5bc7e 45%,#a46d3d);box-shadow:0 3px 3px #0004;}
.social-sticks i:nth-child(even) {transform:rotate(-5deg)}
.social-sticks i[data-flat="true"] {background:repeating-linear-gradient(42deg,#f0c88c 0 9px,#8f603c 10px 11px,#f0c88c 12px 16px);}
.social-keypad, .social-lock-guide {display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.6rem;}
.table-game .social-keypad button {display:grid;place-items:center;gap:.3rem;padding:.6rem .15rem;box-shadow:0 3px 0 var(--control-line);font-size:clamp(.82rem,2.3vw,1rem);}
.social-keypad button span {display:grid;place-items:center;width:2.2rem;aspect-ratio:1;border-radius:50%;background:var(--key);color:#202b36;font-size:1.35rem;}
.social-lock-guide span {background:var(--key);color:#192b34;padding:.6rem .45rem;border-radius:6px;font-size:clamp(.85rem,2.5vw,1.25rem);}
.table-game:is([data-game="telephone"],[data-game="auction"]) .gt-canvas { border:4px solid #b08e69; border-radius:8px; aspect-ratio:auto; height:auto; background:white; box-shadow:0 3px 8px #261a201c;}
.table-game[data-game="auction"][data-room-phase="bid"] .gt-canvas { border:9px ridge #9f825e; }


.social-survivors, .social-hints, .social-pairs {list-style:none;display:flex;flex-wrap:wrap;gap:.55rem;padding:0;}
.social-survivors li,.social-hints li,.social-pairs li {background:var(--bg);border:1px solid var(--line);border-radius:.6rem;padding:.4rem .75rem;overflow-wrap:anywhere;}
.social-survivors li::before {content:"";display:inline-block;width:.5rem;height:.5rem;margin-right:.4rem;border-radius:50%;background:#5a9473;}
.social-hints li {flex:1 1 6rem;padding:1rem .75rem;text-align:center;border-top:3px solid var(--accent);font-weight:700;}
.social-pairs li {flex:1 1 12rem;text-align:center;padding:.75rem;}
.table-game .social-pair {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.4rem;}
.social-pair strong {display:grid;place-items:center;min-height:4rem;padding:.4rem;background:#295b5a;color:#fff6e2;border-radius:10px;font-size:clamp(1.15rem,3vw,1.85rem);overflow-wrap:anywhere;}
.social-pair strong + strong {background:#6b4254;}

.table-game .social-question {padding:1.2rem;border:2px solid var(--felt);border-radius:12px;background:var(--felt-deep);color:var(--social-ink);font-size:clamp(1.15rem,2.9vw,1.55rem);font-weight:700;}

.social-switches span { display:grid; place-items:center; border-radius:8px; font-weight:700; }
