body {
    font-family: "Poppins", sans-serif;
    text-align: center;
    margin: 0;
    padding: 0;
    color: #fff;
}
body {
    background: linear-gradient(45deg, #d26b7e, #143db97b, #820ecf, #e8880a);
    background-size: 300% 300%;
    animation: gradientAnimation 8s infinite linear;
    height: 100vh;
}

@keyframes gradientAnimation {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

h1 {
    margin-top: 10px;
    font-size: 3rem;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.2);
    -webkit-text-stroke: 0.5px #101010;
    color: #ffffff;
}

.game-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
}

.grid, .pieces {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: repeat(3, 1fr);
    gap: 2px;
    width: 320px;
    height: 320px;
    padding: 5px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    box-shadow: 5px 10px 15px rgba(0, 0, 0, 0.3);
}

.cell, .piece {
    width: 100px;
    height: 100px;
    border-radius: 8px;
    background-size: 300px 300px;
    background-position: center;
    transition: all 0.3s ease-in-out;
}

.cell {
    background: rgba(255, 255, 255, 0.3);
    border: 2px dashed rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
}

.piece {
    cursor: grab;
    border: 2px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease;
}

.piece:active {
    transform: scale(1.1);
}

.pieces:empty {
    display: none;
}

.pieces:empty + .buttons {
    transform: translateY(-50px);
    transition: transform 0.5s ease;
}

.buttons {
    margin-top: 20px;
}

.buttons button {
    margin: 5px;
    padding: 12px 24px;
    font-size: 16px;
    font-weight: bold;
    color: #101010;
    background: #fdcb6e;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

.buttons button:hover {
    background: #e17055;
    color: #FFFFFF;
    transform: translateY(-2px);
}

#result {
    font-size: 22px;
    font-weight: bold;
    margin-top: 15px;
    transition: all 0.3s ease;
}

@media (max-width: 400px) {
    .grid, .pieces {
        width: 240px;
        height: 240px;
    }
    .cell, .piece {
        width: 74px;
        height: 74px;
    }

    h1 {
        font-size: 2rem;
    }
}

@media (min-width: 768px) {
    .game-container {
        flex-direction: row;
        justify-content: center;
        align-items: flex-start;
    }
}

.btn{
    border: 3px solid black;
    background-color: #e17055;
    padding: 5px;
    margin-top: 10px;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.3);
    font-size: 15px;
}

.fileLabel {
    font-size: 20px;
    font-weight: 600;
}

.heart {
    color : red;
}

.footer {
    font-size: 15px;
}

#hint-image {
    display: none;
    width : 200px;
    height: 200px;
    transform: translateX(40vw);
}

#hint {
    background: linear-gradient(45deg, #00eaff, #007bff);
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 20px;
    font-weight: 900;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease-in-out;
    box-shadow: 0 0 10px rgba(0, 255, 255, 0.5);
    letter-spacing: 3px;
    margin: 10px;
}
  
#hint:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(0, 255, 255, 0.8);
}
  
#hint:active {
    transform: scale(0.95);
    background: linear-gradient(45deg, #007bff, #00eaff);
}