/* Page Settings */
body {
    background-color: #f8f8f8;
}

#pageWrapper {
    max-width: 480px;
    margin: 0 auto;
    padding: 8px;
    box-sizing: border-box;
    color: #333;
}

/* Header Area Settings */
header > #title {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 12px;
    text-align: center;
}
header > #playerCount > #setPlayers {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
header > #playerCount > #setPlayers > button {
    width: 32px;
    height: 32px;
    font-size: 18px;
    font-weight: bold;
    background-color: white;
    border: 1px solid #ccc;
    border-radius: 8px;
    cursor: pointer;
}
header > #playerCount > #setPlayers > span {
    width: 3px;
}
header > #playerList > #players > input[readonly] {
    cursor: pointer;
}

/* Main Area Settings */
main {
    margin: 6px 0;
    background-color: #3f4a41;
    border-radius: 16px;
    padding: 14px 0;
    text-align: center;
    color: white;
}
main > div#canvasWrapper {
    position: relative;
    width: 100%;
    height: 312px;
}
main > div#canvasWrapper > canvas#ladders {
    display: block;
    width: 100%;
    height: 100%;
}
main > div#canvasWrapper > canvas#traces {
    display: block;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Footer Area Settings */
footer {
    margin-top: 10px;
}
footer > #actionButtons {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-top: 12px;
}
footer > #actionButtons > button {
    flex: 1;
    padding: 12px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 8px;
    border: none;
    color: white;
    cursor: pointer;
}
footer > #actionButtons > #startButton {
    background-color: #2196F3;
}
footer > #actionButtons > #summaryButton {
    background-color: #9E9E9E;
}
footer > #actionButtons > #summaryButton.enabled {
    background-color: #4CAF50;
}

/* Etc. */
header > #playerCount,
header > #playerList,
footer > #rewardList {
    margin-bottom: 10px;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 10px;
}
.grid-container input {
    width: 100%;
    padding: 4px;
    box-sizing: border-box;
    border-radius: 8px;
    border: 1px solid #ccc;
    text-align: center;
    font-size: 1em;
}

.legend {
    font-size: 13px;
    color: #666;
    margin-bottom: 6px;
}