body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f9;
    color: #333;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}
/*
.container {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-width: 600px;
    width: 100%;
    text-align: center;
}
*/
.container {
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.3);
    width: 90%;
    text-align: center;
}

.view {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh;
    width: 100vw;
}
.game-view {
    width: 100vw;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: #111;
}
/*
IMPORTANT!!
For setting the "hidden" class, hiding sections, switching views, etc.
*/
.hidden {
    display: none !important;
}

h1 {
    color: #007bff;
    margin-bottom: 20px;
}

p {
    margin-bottom: 20px;
    font-size: 1.1em;
}

hr {
    border: 0;
    height: 1px;
    background-color: #ccc;
    margin: 25px 0;
}

/* Style for the main "Create New Game" button */
#createGameButton {
    /* Primary Color Style */
    background-color: #007bff; /* Blue for Create */
    color: white;
    border: none;
    padding: 12px 25px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 18px;
    margin-bottom: 10px;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s;
    font-weight: bold;
    width: 80%; /* Make it prominent */
}

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

/* Style for the API Test Button (Secondary/Development) */
#testApiButton {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 10px 20px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 16px;
    margin-bottom: 10px;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s;
}

#testApiButton:hover {
    background-color: #218838;
}

/* Join Game List Styles */
.join-game-section {
    text-align: left;
}

.join-game-section h2 {
    color: #6c757d;
    margin-bottom: 15px;
    font-size: 1.5em;
}

.game-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.game-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    background-color: #f9f9f9;
}

.game-info {
    font-size: 1.1em;
    font-weight: bold;
    color: #333;
}

.game-join-button {
    background-color: #ffc107; /* Yellow for Join */
    color: #333;
    border: none;
    padding: 8px 15px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
    font-weight: bold;
}

.game-join-button:hover {
    background-color: #e0a800;
}

.placeholder {
    color: #888;
    text-align: center;
    font-style: italic;
    padding: 10px;
}

/* API Response Styles (Unchanged) */
.api-test-section {
    text-align: left;
    margin-top: 20px;
    padding: 10px;
    border: 1px dashed #ccc;
    border-radius: 5px;
}

.response-box {
    margin-top: 10px;
    border-top: 1px solid #ccc;
    padding-top: 10px;
    text-align: left;
}

.response-box h3 {
    color: #6c757d;
}

#apiResponse {
    background-color: #e9ecef;
    padding: 15px;
    border-radius: 4px;
    white-space: pre-wrap;
    word-wrap: break-word;
    font-family: 'Consolas', 'Courier New', monospace;
    color: #000;
}

/* --- MAGICAL ATHLETES BOARD STYLES --- */

.board-container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 40px;
  gap: 20px;
  background-color: #111;
}

.row {
  display: flex;
  gap: 10px;
}

.column {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-left: calc(80px * 11); /* Align with end of top row */
}

.column-up {
  margin-left: calc(80px * 26); /* Align with end of bottom row */
}

.board-grid {
    display: grid;
    grid-template-columns: repeat(13, 7vmin); 
    grid-template-rows: repeat(5, 7vmin);
    gap: 0.5vmin;
    padding: 2vmin;
    background: #222;
    border-radius: 8px;
    border: 2px solid #444;
}

.square {
    width: 100%;
    height: 100%;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2vmin; /* Text scales with board */
    font-weight: bold;
    color: white;
    text-align: center;
    box-shadow: inset 0 0 10px rgba(0,0,0,0.2);
}

/*
.square.finish {
  background-color: white;
  color: black;
}
*/
.square.finish {
    background-color: #fff !important;
    color: #000;
}

/* Color cycling: blue, red, purple, yellow, green */
.square:nth-child(5n+1) { background-color: #3498db; } /* blue */
.square:nth-child(5n+2) { background-color: #e74c3c; } /* red */
.square:nth-child(5n+3) { background-color: #9b59b6; } /* purple */
.square:nth-child(5n+4) { background-color: #f1c40f; color: black; } /* yellow */
.square:nth-child(5n)   { background-color: #2ecc71; } /* green */


button {
    padding: 10px 20px;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    font-weight: bold;
    transition: transform 0.1s;
}
button:active { transform: scale(0.95); }
#createGameButton { background: #007bff; color: white; width: 100%; font-size: 1.2rem; }
