[hidden]{display:none!important}
.stage{max-width:640px;margin-inline:auto;padding:16px;position:relative}
.turnbar{--tb-st-lines:1;--tb-msg-lines:2;--tb-st-rt:0px;--tb-rt:0px;margin-bottom:8px}
:root:lang(ja) .turnbar{--tb-st-rt:11px;--tb-rt:11px}
.turnbar .status,.turnbar .message{line-height:1.75}.turnbar .message{font-size:16px}
.form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.field{display:flex;flex-direction:column;gap:6px;font-size:16px}
#setup select{min-height:44px;width:100%;padding:8px;font:16px var(--font);color:var(--ink);background:var(--surface);border:1px solid var(--line-strong);border-radius:6px}
#custom{margin-top:16px;padding:12px;display:grid;gap:8px}#custom label{display:flex;align-items:center;gap:8px;min-height:44px;font-size:16px}#custom input{width:20px;height:20px;flex:none}
.actions,.toolbar{display:flex;flex-wrap:wrap;gap:8px;margin-top:8px}.actions .btn,.toolbar .btn{min-height:44px;font-size:16px;padding:8px 12px}
.hint,#rules-summary{font-size:14px;color:var(--ink-sub);line-height:1.6}
#closing:empty{display:none}#closing{color:var(--warn);font-weight:700;margin:4px 0 8px}
#table{--felt-ink:#fff8ea;--felt-mark:#f8dc7c;margin:auto;padding:12px;border-radius:6px;background:#246a4d url('assets/felt.webp') repeat;color:var(--felt-ink)}
.card-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;max-width:234px;margin:auto}
.golf-card{position:relative;appearance:none;padding:0;border:2px solid transparent;border-radius:6px;background:none;min-width:44px;min-height:44px;touch-action:manipulation}
.golf-card:enabled,.pile-card:enabled{cursor:pointer}.golf-card:disabled{opacity:1}
.golf-card.legal{border:2px dashed var(--felt-mark)}
.golf-card:focus-visible,.pile-card:focus-visible{outline:3px solid var(--felt-mark);outline-offset:3px}
.golf-card:active{transform:translateY(1px)}
.stage .golf-card svg,.stage .pile-card svg{display:block;width:100%;height:auto;filter:var(--shadow-piece)}
.target-mark{position:absolute;right:-4px;bottom:-4px;display:grid;place-items:center;width:22px;height:22px;border-radius:50%;color:#193e30;background:var(--felt-mark);font-size:18px;font-weight:700}
.layout-title{text-align:center;font-size:16px;margin:0 0 6px;font-weight:700;line-height:24px;font-variant-numeric:tabular-nums}
.opponents{display:flex;justify-content:center;gap:16px;margin-bottom:8px}.opponent{flex:1;max-width:144px;min-width:0;padding:6px;border:2px solid transparent;border-radius:6px}
.opponent .card-grid{gap:3px}.opponent .layout-title{font-size:14px;line-height:20px}.opponent .golf-card{border:0;min-width:0;min-height:0}
.opponent .golf-card svg text{font-size:28px}
.opponent.active{border-color:var(--felt-mark);border-style:dashed}.active>.layout-title::before{content:'▶ ';font-size:12px}.winner>.layout-title::before{content:'★ '}
.piles{display:flex;justify-content:center;gap:16px;margin:8px 0;min-height:127px;align-items:start}
.pile{text-align:center;width:88px;min-width:0}.pile-card{display:block;appearance:none;padding:0;border:2px solid transparent;border-radius:6px;background:none;width:66px;min-height:88px;margin:auto;touch-action:manipulation}
.pile-card.legal{border-color:var(--felt-ink)}.pile-card.selected{outline:3px solid var(--felt-mark);outline-offset:2px;transform:translateY(-3px)}
.pile p{font-size:14px;line-height:20px;margin:5px 0 0}.discard-target .pile-card{border:2px dashed var(--felt-mark)}.discard-target p::before{content:'↓ '}
.your-layout{padding:8px;border:2px solid transparent;border-radius:6px}.your-layout.active{border-color:#fff8ea80}
#visible-score{text-align:center;color:var(--felt-ink);margin:4px 0 0;font-variant-numeric:tabular-nums}
#game-actions{justify-content:center;margin:0 0 8px;min-height:44px}#game-actions .btn{font-size:17px;padding:8px 12px;background:var(--felt-ink);color:#193e30;border-color:var(--felt-ink)}#game-actions .btn:disabled{opacity:.65;border-style:dashed}
.hinted{outline:3px dashed var(--felt-mark);outline-offset:3px}
.cpu-choice{outline:3px solid var(--felt-mark);outline-offset:2px}
#handoff{text-align:center;padding:16px 8px;border:2px solid var(--accent);border-radius:6px;margin-bottom:8px}
#result{margin-top:8px;padding:16px;border:1px solid var(--line);border-radius:6px}#result h2{font-size:20px;margin:0 0 8px}
#scores table{width:100%;font-size:14px;border-collapse:collapse}#scores th,#scores td{text-align:right;padding:8px;border-bottom:1px solid var(--line)}#scores th:first-child,#scores td:first-child{text-align:left}.table-scroll{overflow-x:auto}
.support{margin-top:12px;border-top:1px solid var(--line)}.support summary,#score-details summary{cursor:pointer;min-height:44px;line-height:44px;font-size:16px}
#rules-summary{margin:8px 0}.article{max-width:800px;margin:auto}.howto{margin:24px 0}.howto img{display:block;width:100%;max-width:100%;height:auto;border:1px solid var(--line);border-radius:6px}.howto figcaption{font-size:14px;line-height:1.6;color:var(--ink-sub);margin-top:8px}.lang-switch{text-align:right;font-size:14px}.ad-gap{height:150px}
.card-flight{position:fixed;z-index:30;pointer-events:none;transform-origin:top left}.card-flight svg{width:100%;height:100%;filter:var(--shadow-piece)}
@media(max-width:420px){.stage{padding:8px}#table{padding:8px}.card-grid{max-width:210px}.opponents{gap:8px}.opponent{max-width:122px;padding:4px}.opponent .layout-title{font-size:14px}.piles{gap:8px;min-height:118px}.pile-card{width:60px;min-height:80px}.pile{width:88px}.form-grid{gap:8px}.your-layout{padding:6px}.actions.controls .btn{flex:1}#game-actions{gap:8px;flex-wrap:wrap}.toolbar{justify-content:center}}
@media(prefers-reduced-motion:reduce){.pile-card.selected{transform:none}}
