body {
    background-color: #0d1117;
    color: #c9d1d9;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    flex-direction: column;
}

.hidden {
    display: none !important;
}

.header {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 10;
}

.container {
    background-color: #161b22;
    border: 1px solid #30363d;
    border-radius: 6px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    width: 90%;
    max-width: 600px;
    margin-top: 20px;
}

.professional-title {
    color: #58a6ff;
    text-align: center;
    margin-bottom: 20px;
}

h1, h2, h3, h4 {
    text-align: center;
    color: #e6edf3;
    margin-bottom: 12px;
}

.description {
    text-align: center;
    color: #8b949e;
    margin-bottom: 24px;
    font-size: 0.9em;
}

input, button, select, .action-button {
    background-color: #0d1117;
    color: #c9d1d9;
    border: 1px solid #30363d;
    padding: 10px;
    margin: 8px 0;
    width: 100%;
    box-sizing: border-box;
    font-family: inherit;
    transition: all 0.3s ease;
    border-radius: 6px;
}

button:hover, .action-button:hover {
    background-color: #21262d;
    color: #58a6ff;
    cursor: pointer;
}

.action-button {
    display: inline-block;
    text-align: center;
    text-decoration: none;
    width: auto;
    padding: 8px 16px;
}

#admin-login-button {
    background-color: transparent;
    border-color: #58a6ff;
    color: #58a6ff;
    width: auto;
}

#toggle-moderation-panel-button {
    background-color: transparent;
    border-color: #ffc107;
    color: #ffc107;
    width: auto;
    margin-left: 10px;
}

/* Chat container styling */
#chat-container {
    display: flex;
    flex-direction: column;
    max-height: 90vh;
}

#chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 12px;
    border-bottom: 1px solid #30363d;
    margin-bottom: 12px;
}

#moderation-controls {
    padding: 16px;
    border: 1px solid #30363d;
    border-radius: 6px;
    margin-bottom: 16px;
}

.panel-title {
    margin-top: 0;
    font-size: 1.1em;
    color: #58a6ff;
}

#chat-status-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 10px;
}

#admin-panel-section {
    padding: 10px;
    border-top: 1px solid #30363d;
    margin-top: 10px;
}

#manage-user-form, #change-admin-details-form {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: flex-end;
}

#manage-user-form input, #manage-user-form select, #manage-user-form button,
#change-admin-details-form input, #change-admin-details-form button {
    flex: 1;
    min-width: 120px;
}

#user-lists {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 16px;
}

#user-lists > div {
    flex: 1;
}

#user-lists ul {
    list-style-type: none;
    padding: 0;
}

#user-lists li {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #30363d;
}

#user-lists li:last-child {
    border-bottom: none;
}

#user-lists li button {
    width: auto;
    padding: 4px 10px;
    margin-left: 5px;
    font-size: 0.8em;
}

#messages-container {
    flex-grow: 1;
    overflow-y: auto;
    padding: 16px 8px;
    background-color: #0d1117;
    border: 1px solid #30363d;
    border-radius: 6px;
    margin-bottom: 12px;
}

.message {
    margin-bottom: 12px;
    line-height: 1.4;
}

.message-meta {
    font-size: 0.8em;
    color: #8b949e;
    margin-left: 8px;
}

.message-actions {
    display: inline-flex;
    gap: 5px;
    margin-left: 10px;
}

.message-actions button {
    width: auto;
    padding: 2px 6px;
    font-size: 0.8em;
    background-color: #21262d;
}

#message-form {
    display: flex;
    gap: 8px;
}

#message-input {
    flex-grow: 1;
}

.badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.7em;
    font-weight: bold;
    margin-right: 8px;
}

.user-badge {
    background-color: #30363d;
    color: #c9d1d9;
}

.mod-badge {
    background-color: #238636;
    color: #fff;
}

.admin-badge {
    background-color: #f85149;
    color: #fff;
}

.owner-badge {
    background-color: #ffc107;
    color: #000;
}

.owner-message .message-user { color: #ffc107; }
.admin-message .message-user { color: #f85149; }
.mod-message .message-user { color: #238636; }
.user-message .message-user { color: #c9d1d9; }
