.pc { --pc-green: #b9f35b; padding-bottom: 16px; }
.pc button, .pc input { touch-action: manipulation; }
.pc-head { display: flex; align-items: center; gap: 10px; margin: 8px 0 20px; }
.pc-head svg { width: 36px; height: 36px; flex: none; }
.pc-head div { flex: 1; min-width: 0; }
.pc-head small { color: var(--muted); font-size: .75rem; letter-spacing: .08em; }
.pc-head h1 { margin: 0; font-size: 1.2rem; }
.pc-exit { min-width: 44px; min-height: 44px; border: 1px solid var(--border); border-radius: 14px; background: var(--surface); font-size: 1.5rem; }
.pc-panel { padding: 20px; border: 1px solid var(--border); border-radius: 22px; background: linear-gradient(145deg, #182447, #111831); }
.pc-panel h2 { font-size: 1.35rem; line-height: 1.3; margin: 12px 0 8px; }
.pc-panel p { color: var(--muted); margin-top: 10px; }
.pc-panel .btn { width: 100%; margin-top: 12px; }
.pc-kicker { color: var(--pc-green); font-size: .75rem; font-weight: 750; letter-spacing: .09em; text-transform: uppercase; }
.pc-rules { padding-left: 20px; margin: 16px 0; color: var(--muted); font-size: .92rem; }
.pc-rules li + li { margin-top: 8px; }
.pc-mini-pitch { display: block; width: 100%; border-radius: 16px; margin-bottom: 18px; }
.pc-link-label { display: block; color: var(--muted); font-size: .82rem; margin-top: 18px; }
.pc-link { display: block; width: 100%; min-width: 0; background: #0b142b; color: var(--text); border: 1px solid var(--border); border-radius: 12px; padding: 12px; font: inherit; font-size: .85rem; margin: 6px 0; }
.pc-info { margin: 14px 0; padding: 12px 14px; border: 1px solid #3d4768; background: #121d36; border-radius: 12px; color: var(--muted); font-size: .85rem; }
.pc-error { border-color: #89536a; color: #ffb5c1; background: #301c32; }
.pc-status { min-height: 24px; color: var(--muted); font-size: .85rem; margin: 12px 0; text-align: center; }
.pc-players { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; margin: 8px 0 12px; }
.pc-player { display: grid; justify-items: center; gap: 3px; font-size: .8rem; color: var(--muted); }
.pc-avatar { display: grid; place-items: center; height: 38px; width: 38px; border-radius: 12px; background: #283c50; color: var(--pc-green); font-weight: 800; }
.pc-player:last-child .pc-avatar { background: #352561; color: #bba7ff; }
.pc-player b { color: var(--text); font-size: .95rem; }
.pc-score { font-size: 2.25rem; font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; letter-spacing: .08em; }
.pc-score span { color: #606c87; font-weight: 400; }
.pc-round { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin: 10px 0; color: var(--muted); font-size: .8rem; }
.pc-clock { color: var(--pc-green); font-weight: 750; font-variant-numeric: tabular-nums; white-space: nowrap; }
.pc-clock.is-urgent { color: #ff9aab; }
.pc-pitch { position: relative; overflow: hidden; border: 1px solid #315251; border-radius: 20px; background: #102b30; }
.pc-pitch svg { width: 100%; display: block; }
.pc-pitch-label { position: absolute; top: 12px; left: 12px; border: 1px solid #a7efd333; border-radius: 100px; padding: 4px 9px; color: #b5d7ce; background: #0a252bc9; font-size: .65rem; font-weight: 700; letter-spacing: .1em; }
.pc-pitch .pc-zone { fill: #a5d9cc; fill-opacity: .04; stroke: #b4f9dc; stroke-opacity: .18; stroke-dasharray: 3 5; }
.pc-pitch[data-choice="left"] #pc-zone-left, .pc-pitch[data-choice="center"] #pc-zone-center, .pc-pitch[data-choice="right"] #pc-zone-right { fill: #c6f432; fill-opacity: .18; stroke: #c6f432; stroke-opacity: .85; stroke-dasharray: none; }
#pc-ball-motion { transform-origin: 180px 228px; transition: none; will-change: transform; }
#pc-keeper-motion { transition: none; will-change: transform; transform-origin: 180px 137px; }
.pc-shot-badge { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); border-radius: 100px; padding: 5px 12px; background: #0b172be8; color: #e7f6e9; font-size: .85rem; font-weight: 700; white-space: nowrap; }
.pc-instruction { margin: 18px 0 10px; }
.pc-instruction h2 { font-size: 1.15rem; }
.pc-instruction p { color: var(--muted); font-size: .85rem; margin-top: 4px; }
.pc-directions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pc-dir { display: grid; place-items: center; gap: 4px; min-height: 76px; padding: 10px 4px; background: #192943; border: 1px solid #354960; border-radius: 15px; font-weight: 650; font-size: .85rem; }
.pc-dir span { font-size: 1.35rem; color: var(--pc-green); }
.pc-dir[aria-pressed="true"] { border-color: var(--pc-green); background: #294231; }
.pc-dir:disabled { cursor: default; opacity: .5; }
.pc-dir[aria-pressed="true"]:disabled { opacity: 1; }
.pc-history { margin-top: 16px; border-top: 1px solid var(--border); padding-top: 12px; }
.pc-history-row { display: grid; grid-template-columns: 64px 1fr; align-items: center; gap: 8px; font-size: .78rem; color: var(--muted); margin: 6px 0; }
.pc-dots { display: flex; flex-wrap: wrap; gap: 5px; }
.pc-dot { width: 20px; height: 20px; border-radius: 50%; border: 1px solid #42516c; display: grid; place-items: center; color: #b1bdd3; background: #19243c; font-size: .7rem; }
.pc-dot.goal { background: #b9f35b; color: #17321f; border-color: #b9f35b; }
.pc-dot.save { background: #492b40; color: #ffb6c4; border-color: #81516a; }
.pc-final { margin-top: 16px; text-align: center; }
.pc-final h2 { font-size: 1.5rem; }
.pc-final-mark { font-size: 2rem; color: var(--pc-green); }
.pc-wait-dot { width: 10px; height: 10px; display: inline-block; background: var(--pc-green); border-radius: 50%; margin-right: 7px; box-shadow: 0 0 0 5px #b9f35b18; }
@media (max-width: 350px) { .pc-panel { padding: 16px; } .pc-score { font-size: 1.9rem; } .pc-head h1 { font-size: 1.05rem; } }

/* Movement is driven only during the forward shot, never on neutral reset. */
#pc-ball-shadow { transform-origin: 180px 241px; }
.pc-pitch[data-phase="flight"] .pc-zone,
.pc-pitch[data-phase="impact"] .pc-zone { fill-opacity: .04; stroke-opacity: .18; }
.pc-impact-goal .pc-pitch { animation: pc-net-flash .48s ease-out; }
.pc-impact-goal .pc-score b { animation: pc-score-pop .3s ease-out; }
.pc-impact-goal .pc-shot-badge { color: #caff8e; border: 1px solid #8fc94c66; animation: pc-badge-in .2s ease-out; }
.pc-impact-save .pc-shot-badge { color: #c2e8ff; border: 1px solid #7db8dc66; animation: pc-badge-in .2s ease-out; }
.pc-final { scroll-margin-top: calc(12px + var(--st)); }
.pc-panel .pc-final-score { color: var(--text); font-size: clamp(1.1rem, 5vw, 1.45rem); font-weight: 800; font-variant-numeric: tabular-nums; margin: 10px 0; }
@keyframes pc-net-flash { from { box-shadow: inset 0 0 26px #b9f35b25; border-color: #b9f35b; } to { box-shadow: inset 0 0 0 transparent; border-color: #315251; } }
@keyframes pc-score-pop { 45% { color: var(--pc-green); } }
@keyframes pc-badge-in { from { opacity: 0; translate: 0 4px; } to { opacity: 1; translate: 0 0; } }

.pc-rematch { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border); }
.pc-panel #pc-rematch-status { color: var(--text); font-size: .85rem; margin-top: 0; }
.pc-panel .pc-rematch-time { font-size: .75rem; margin-top: 6px; }
.pc-rematch .btn { min-height: 46px; }
.pc-final > .btn { min-height: 44px; margin-top: 8px; font-size: .9rem; }
.pc-final #pc-result-reason { font-size: .9rem; }

.pc-player { min-width: 0; }
.pc-player b, .pc-player-identity { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pc-player-identity { font-size: .68rem; color: var(--muted); }
