/* 15-Puzzle specific premium styles */
.puzzle-board {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(4, 1fr);
    gap: 8px;
    width: 100%;
    max-width: 400px;
    aspect-ratio: 1; /* Makes it a square */
    margin: 2rem auto;
    background: rgba(255, 255, 255, 0.05); /* Board background */
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    position: relative;
}

.tile {
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, rgba(255,255,255,0.15) 0%, rgba(255,255,255,0.05) 100%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    font-size: 2rem;
    font-weight: 700;
    color: white;
    cursor: pointer;
    user-select: none;
    transition: transform 0.15s ease-out, background 0.2s;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

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

.tile:not(.empty):hover {
    background: linear-gradient(135deg, rgba(255,255,255,0.25) 0%, rgba(255,255,255,0.1) 100%);
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(99, 102, 241, 0.3);
}

.tile:not(.empty):active {
    transform: translateY(0) scale(0.95);
}

/* Specific styling correct position */
.tile.correct {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.4) 0%, rgba(76, 175, 80, 0.1) 100%);
    border-color: rgba(76, 175, 80, 0.4);
    box-shadow: 0 0 10px rgba(76, 175, 80, 0.2);
}

.win-message {
    text-align: center;
    margin-top: 1rem;
    animation: fadeIn 0.5s ease-out forwards;
}

.win-message h2 {
    color: #4caf50;
    margin-bottom: 0.5rem;
}

.win-message.hidden {
    display: none;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.stats {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 15px 0;
    font-size: 1.1rem;
    font-weight: 500;
}
