main {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem;
}

h1 {
    text-align: center;
    margin-bottom: 1rem;
}

#setup {
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
    width: 100%;
    max-width: 500px;
}

#players, #results {
    margin-bottom: 10px;
}

input {
    display: block;
    margin-bottom: 5px;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: calc(100% - 18px);
}

button {
    padding: 10px 15px;
    border: none;
    background-color: #007bff;
    color: white;
    border-radius: 4px;
    cursor: pointer;
    margin-right: 5px;
}

button:hover {
    background-color: #0056b3;
}

#game-container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

#game-controls {
    margin-bottom: 1rem;
}

#start-buttons {
    display: flex;
    justify-content: space-around;
    width: 100%;
    max-width: 500px; /* Should match canvas width calculation */
    padding: 0 50px;
    box-sizing: border-box;
    margin-bottom: 1rem;
}

#start-buttons button {
    flex-grow: 1;
    margin: 0 5px;
}

canvas {
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-top: 1rem;
}

.toggle-button {
    margin-top: 1rem;
    background-color: #28a745;
}

.toggle-button:hover {
    background-color: #218838;
}

#result-display {
    margin-top: 20px;
    padding: 10px;
    border-radius: 8px;
    background-color: #e9ecef;
    width: 100%;
    max-width: 480px;
    text-align: center;
}

#result-display p {
    margin: 5px 0;
    font-size: 1.1em;
}

.reset-button {
    margin-top: 1.5rem;
    padding: 15px 30px;
    font-size: 1.2rem;
    background-color: #dc3545;
    width: 100%;
    max-width: 500px;
}

.reset-button:hover {
    background-color: #c82333;
}