.container {
    max-width: 600px;
    margin: 80px auto;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    padding: 32px;
}

.game-btn.disabled,
.game-btn[disabled] {
    background: #ccc;
    color: #888;
    cursor: not-allowed;
    pointer-events: none;
}

body {
    font-family: Arial, sans-serif;
    margin: 2em;
}

.filter {
    margin-bottom: 1em;
}

.game-list {
    list-style: none;
    padding: 0;
}

.game-item {
    padding: 0.5em;
    border-bottom: 1px solid #ccc;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.game-links {
    display: flex;
    gap: 0.5em;
}

.game-btn {
    background: #1976d2;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.3em 0.8em;
    text-decoration: none;
    font-size: 0.95em;
    cursor: pointer;
    transition: background 0.2s;
}

.game-btn:hover {
    background: #1565c0;
}

/* Loading spinner */
#loading {
    display: none;
    text-align: center;
    margin: 2em 0;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #1976d2;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    animation: spin 1s linear infinite;
    margin: auto;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

#messages {
    list-style-type: none;
    padding: 0;
    margin: 0;
    width: 100%;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

.message-item {
    background-color: #f0f0f0;
    border-radius: 18px;
    padding: 10px 15px;
    margin-bottom: 8px;
    max-width: 80%;
    align-self: flex-start;
    word-wrap: break-word;
}

.message-mine {
    background-color: #007bff;
    /* A distinct color for your messages */
    color: white;
    /* White text for better contrast */
    align-self: flex-end;
    /* Aligns the bubble to the right */
}