body {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    background: linear-gradient(to bottom, #1e3c72, #2a5298);
    font-family: Arial, sans-serif;
    user-select: none;
}

@media (max-width: 360px) {
    body {
        font-size: 12px;
    }
}

@media (min-width: 361px) and (max-width: 720px) {
    body {
        font-size: 14px;
    }
}

@media (min-width: 721px) and (max-width: 1080px) {
    body {
        font-size: 16px;
    }
}

@media (min-width: 1081px) and (max-width: 1440px) {
    body {
        font-size: 18px;
    }
}

@media (min-width: 1441px) {
    body {
        font-size: 20px;
    }
}

.game-container {
    text-align: center;
    user-select: none;
}

h1 {
    margin-bottom: 20px;
    color: white;
    user-select: none;
}

#board {
    display: grid;
    grid-template-columns: repeat(3, 100px);
    grid-template-rows: repeat(3, 100px);
    gap: 5px;
    justify-content: center;
    margin-bottom: 20px;
    user-select: none;
}

.cell {
    width: 100px;
    height: 100px;
    background-color: rgba(255, 255, 255, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 50px;
    cursor: pointer;
    user-select: none;
    border-radius: 10px;
}

.cell:hover {
    background-color: rgba(255, 255, 255, 1);
    user-select: none;
}

#message {
    font-size: 24px;
    margin-bottom: 15px;
    color: white;
    user-select: none;
}

#restart {
    padding: 10px 20px;
    font-size: 18px;
    border-radius: 8px;
    border: none;
    background-color: #333;
    color: #fff;
    cursor: pointer;
    user-select: none;
}

#restart:hover {
    background-color: #555;
    user-select: none;
}

.back-button {
    display: inline-block;
    margin-top: 15px;
    padding: 10px 20px;
    background-color: #007BFF;
    color: #fff;
    text-decoration: none;
    font-size: 18px;
    border-radius: 8px;
    transition: background-color 0.3s;
    user-select: none;
}

.back-button:hover {
    background-color: #0056b3;
    user-select: none;
}