/**
 * 슬라이딩 숫자 퍼즐 전용 스타일 (sliding-puzzle.css)
 */

.sliding-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 460px;
  margin: 0 auto;
}

.sliding-board {
  width: 100%;
  aspect-ratio: 1 / 1;
  background: #cbd5e1;
  border-radius: var(--radius-lg);
  padding: 12px;
  display: grid;
  gap: 10px;
  position: relative;
  box-shadow: var(--shadow);
  user-select: none;
}

.sliding-board.size-3 {
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
}

.sliding-board.size-4 {
  grid-template-columns: repeat(4, 1fr);
  grid-template-rows: repeat(4, 1fr);
}

.sliding-tile {
  background: white;
  border-radius: var(--radius-md);
  display: grid;
  place-items: center;
  font-size: clamp(20px, 5vw, 32px);
  font-weight: 800;
  font-family: var(--font-sans);
  color: var(--ink);
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.8);
  transition: transform 0.08s ease, background-color 0.15s ease;
}

.sliding-tile:hover {
  background: #f8fafc;
  transform: scale(0.98);
}

.sliding-tile.in-place {
  border-color: #86efac;
  color: #15803d;
}

.sliding-tile.tile-empty {
  background: transparent;
  box-shadow: none;
  border: none;
  cursor: default;
}

@media (max-width: 500px) {
  .sliding-board {
    padding: 8px;
    gap: 6px;
  }
}
