/* 제자리 찾기 — lib/mini.css 위에 이 게임에만 필요한 것 */
.app[data-game="place"] .stage--mini { touch-action: none; cursor: grab; }
.app[data-game="place"] .stage--mini.is-drag { cursor: grabbing; }
.app[data-game="place"] .mini-body { inset: 52px 16px 14px; gap: 10px; }
.pl { position: relative; display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 10px; justify-items: center; width: 100%; height: 100%; min-height: 0; }
.pl__time { width: min(100%, 200px); height: 4px; border-radius: 2px; background: rgba(var(--stage-ink), 0.1); overflow: hidden; }
.pl__time i { display: block; width: 100%; height: 100%; background: rgba(var(--stage-ink), 0.5); transform-origin: left center; }
.pl__time i.is-low { background: var(--p1); }
/* 판: 정사각형. 무대 안에서 들어갈 수 있는 가장 큰 크기로 가운데에 그려져요 (좌표는 getScreenCTM 으로 바꿔요) */
.pl__field { display: block; width: 100%; height: 100%; min-height: 0; overflow: visible; color: rgb(var(--stage-ink)); user-select: none; -webkit-user-select: none; }
.pl__shape path { stroke: rgba(18, 22, 19, 0.16); stroke-width: 0.8; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.pl__shape.is-in path { animation: pl-in 260ms var(--ease-pop, ease-out) both; transform-box: fill-box; transform-origin: center; }
.pl__shape.is-out path { animation: pl-out 380ms ease-in both; transform-box: fill-box; transform-origin: center; }
.pl__shape.is-mine path { fill-opacity: 0.78; }
@keyframes pl-in { from { transform: scale(0.6); opacity: 0; } }
@keyframes pl-out { to { transform: scale(0.85); opacity: 0; } }
/* 정답: 짙은 점선 (어느 색 도형 위에서도 보이게) */
.pl__ans path { fill: rgb(var(--stage-ink)); fill-opacity: 0.07; stroke: rgb(var(--stage-ink)); stroke-width: 2.2; stroke-dasharray: 6 5; stroke-linejoin: round; vector-effect: non-scaling-stroke; animation: pl-in 300ms var(--ease-out, ease-out) both; transform-box: fill-box; transform-origin: center; }
/* 손잡이: 도형 머리 쪽으로 뻗은 줄 끝의 동그라미. 끌면 돌고 커져요 */
.pl__stalk { stroke: rgb(var(--stage-ink)); stroke-opacity: 0.4; stroke-width: 0.7; stroke-dasharray: 1.6 1.6; pointer-events: none; }
.pl__knob { cursor: grab; }
.pl__knob circle + circle { fill: rgb(var(--stage-ink)); }
.pl__knob path { fill: none; stroke: var(--stage); stroke-width: 1; stroke-linecap: round; stroke-linejoin: round; pointer-events: none; }
/* 채점: 판 아래쪽에 겹쳐서 보여 줘요 */
.pl__res { position: absolute; left: 0; right: 0; bottom: 8px; margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: center; gap: 0 6px; pointer-events: none; text-shadow: 0 0 10px var(--stage), 0 0 10px var(--stage), 0 0 4px var(--stage); }
.pl__res b { font: 400 44px/1 var(--font-pixel); font-weight: 400; color: var(--sprout); font-variant-numeric: tabular-nums; display: inline-block; }
.pl__res b.is-pop { animation: kk-pop 420ms var(--ease-pop, ease-out); }
.pl__res span { font: 500 14px/1 var(--font-mono); color: var(--on-stage-muted); }
.pl__res em { flex-basis: 100%; font: 400 19px/25px var(--font-display); font-style: normal; }
.pl-cue { margin: 0; text-align: center; font: 600 15px/22px var(--font-sans); color: var(--ink-muted); word-break: keep-all; }
.pl-ctl { display: grid; gap: 10px; }
/* 보기·놓기·채점에서 아래쪽 높이가 같아야 판이 움직이지 않아요 */
.app[data-game="place"] .foot { min-height: 96px; }
.pl-demo { width: 190px; height: 152px; color: rgb(var(--stage-ink)); }
@media (min-width: 960px) and (min-height: 620px) {
  .app[data-game="place"] .mini-body { inset: 64px 32px 24px; }
  .app[data-game="place"] .foot-body { max-width: 560px; }
  .pl__res b { font-size: 56px; }
}
@media (prefers-reduced-motion: reduce) { .pl__shape.is-in path, .pl__shape.is-out path, .pl__ans path, .pl__res b.is-pop { animation: none; } }
