* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, Helvetica, sans-serif;
}

body {
    height: 100vh;
    background: #f4f4f4;
    color: #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    text-align: center;
}

.playerContainer {
    display: flex;
    justify-content: space-around;
    width: 100%;
    align-items: center;
}

#resetScore {
    padding: 0.6rem 1.2rem;
    background: #333;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: background 0.2s ease;
}

#resetScore:hover {
    color: red;
}

.title {
    font-size: 2.5rem;
    font-weight: bold;
    letter-spacing: 2px;
    color: #222;
}

#player-x,
#player-o {
    font-size: 1.2rem;
    font-weight: 500;
    color: #555;
}

#cell-container {
    display: grid;
    grid-template-columns: repeat(3, 100px);
    grid-template-rows: repeat(3, 100px);
    gap: 0;
    border: 3px solid #333;
}

.cell {
    background-color: #fff;
    color: #333;
    font-size: 2.5rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 1px solid #333;
    transition: background 0.2s;
}

.cell:hover {
    background: #eaeaea;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-box {
    background: #fff;
    border-radius: 8px;
    padding: 1.5rem;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.modal-box p {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: #333;
}

.modal-input {
    padding: 0.5rem;
    width: 80%;
    margin-bottom: 1rem;
    font-size: 1rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

.modal-button {
    padding: 0.6rem 1.2rem;
    background: #333;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: background 0.2s ease;
}

.modal-button:hover {
    background: #555;
}
