body {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    background-color: #222;
    font-family: "Space Grotesk",sans-serif;
}

.board {
    display: grid;
    grid-template-columns: repeat(3, 100px);
    grid-template-rows: repeat(3, 100px);
    gap: 5px;
    background-color: #444; 
}

.game-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.header {
    text-align: center;
    color: #fff;
}

.header h1 {
    margin: 0;
    font-size: 2rem;
    color: #ff2c3e; 
}

.header p {
    margin: 5px 0 0 0;
    font-size: 1.2rem;
    color: #ccc;
    font-style: italic;
}

.cell {
    background-color: #fff;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5rem;
    color: #222;
    font-weight: bold;
    cursor: pointer;
    user-select: none;
}

.cell:hover {
    background-color: #d6d6d6;
}

#turn-status {
    margin-top: 10px;
    font-size: 1rem;
    font-weight: bold;
    color: #ffc107;
    background-color: #333;
    padding: 5px 15px;
    border-radius: 20px;
    display: inline-block;
}

.overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(0,0,0,0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    transition: opacity 0.3s ease;
}

.overlay.hidden{
    display: none;
    pointer-events: none;
}

#overlay-content{
    text-align: center;
    background-color: #2a2a2a;
    padding: 40px 60px;
    border-radius: 15px;
    border: 3px solid #ff4757;
}

#overlay-msg {
    color: #fff;
    font-size:2rem;
    margin-top:0;
    margin-bottom:25px;
}

#restart-btn {
    background-color: #ff4757;
    color:#fff;
    border:none;
    padding: 12px 30px;
    font-size:1.2rem;
    font-weight:bold;
    border-radius:5px;
    cursor:pointer;
    transition:background 0.2s, transform 0.3s;
}

#restart-btn:hover {
    background-color: #f7677f;
    transform:scale(1.05);
}