/* 主题变量 */
:root {
    /* 默认暗色主题 */
    --background-color: #1e1e1e;
    --text-color: #00ff00;
    --header-color: #333;
    --accent-color: #00ff00;
    --input-bg-color: #2d2d2d;
    --border-color: #444;
    --font-size: 14px;
    --notification-bg: rgba(0, 0, 0, 0.8);
}

body {
    font-family: Arial, sans-serif;
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

#userList {
    border: 1px solid #ccc;
    padding: 10px;
    margin: 10px 0;
    min-height: 100px;
}

.user-item {
    cursor: pointer;
    padding: 8px;
    margin: 5px 0;
    border-radius: 5px;
    border: 1px solid #eee;
    transition: all 0.2s ease;
}

.user-item:hover {
    background-color: #f0f0f0;
    border-color: #ddd;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.user-header {
    font-weight: bold;
    margin-bottom: 5px;
}

.ip-info span {
    display: block;
    margin: 2px 0;
    line-height: 1.4;
}

.user-table {
    width: 100%;
    border-collapse: collapse;
    margin: 10px 0;
    font-size: 0.9em;
}

.user-table th {
    background-color: var(--accent-color);
    color: white;
    text-align: left;
    padding: 8px 12px;
}

.user-table td {
    padding: 8px 12px;
    border-bottom: 1px solid var(--border-color);
}

.user-table tr.user-item:hover {
    cursor: pointer;
}

.user-table .user-name {
    font-weight: bold;
}

/* 用户在线状态样式 */
.status-online {
    background-color: rgba(76, 175, 80, 0.1);
}

.status-offline {
    background-color: rgba(158, 158, 158, 0.1);
    color: #777;
}

.user-status {
    font-weight: bold;
}

.status-online .user-status {
    color: #4CAF50;
}

.status-offline .user-status {
    color: #9E9E9E;
}

@media (max-width: 768px) {
    .user-table {
        font-size: 0.8em;
    }
    .user-table th, 
    .user-table td {
        padding: 6px 8px;
    }
}

.hidden {
    display: none;
}

#backButton {
    margin-bottom: 15px;
    padding: 5px 10px;
    cursor: pointer;
}

.terminal-container {
    display: flex;
    flex-direction: column;
    height: 400px;
    border: 1px solid #ccc;
    border-radius: 5px;
    overflow: hidden;
}

#outputArea {
    flex-grow: 1;
    background-color: #000;
    color: #0f0;
    font-family: 'Courier New', monospace;
    padding: 10px;
    border: none;
    resize: none;
    overflow-y: auto;
}

.input-container {
    display: flex;
    border-top: 1px solid #ccc;
}

#commandInput {
    flex-grow: 1;
    padding: 8px;
    border: none;
    outline: none;
    font-family: 'Courier New', monospace;
}

#runButton {
    padding: 8px 15px;
    background-color: #4CAF50;
    color: white;
    border: none;
    cursor: pointer;
}

#runButton:hover {
    background-color: #45a049;
}

/* 通知样式 */
.notification {
    color: white;
    padding: 10px 15px;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
    cursor: pointer;
    z-index: 1000;
    opacity: 0;
    transform: translateY(-20px);
    transition: opacity 0.3s, transform 0.3s;
}

.notification.warning {
    background-color: #FFC107;
    border-left: 4px solid #e0a800;
    color: #212529;
}

.notification.error {
    background-color: #F44336;
    border-left: 4px solid #d32f2f;
}

/* 登录页面样式 */
.login-container {
    max-width: 400px;
    margin: 100px auto;
    padding: 20px;
    background-color: var(--header-color);
    border-radius: 5px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
}

.login-title {
    text-align: center;
    margin-bottom: 20px;
}

.login-form {
    display: flex;
    flex-direction: column;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
}

.form-group input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: var(--background-color);
    color: var(--text-color);
}

.login-button {
    padding: 10px;
    background-color: var(--accent-color);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
}

.login-button:hover {
    opacity: 0.9;
}

/* 加载指示器样式 */
#loadingIndicator {
    text-align: center;
    margin-bottom: 20px;
    display: none;
}

.loading-text {
    margin-bottom: 10px;
}

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(0,0,0,.3);
    border-radius: 50%;
    border-top-color: var(--accent-color);
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.error-message {
    color: #ff4444;
    margin-top: 15px;
    text-align: center;
}

.error-message {
    color: red;
    margin-top: 10px;
}

/* 屏幕阅读器专用类 */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* 首页样式 */
.index-body {
    font-family: Arial, sans-serif;
    line-height: 1.6;
    margin: 0;
    padding: 20px;
    background-color: #f5f5f5;
    color: #333;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    background-color: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.index-body h1, .index-body h2 {
    color: #2c3e50;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}

.feature-list {
    list-style-type: none;
    padding: 0;
}

.feature-list li {
    margin: 10px 0;
    padding: 10px;
    background-color: #f8f9fa;
    border-radius: 4px;
}

.version-info {
    background-color: #e8f5e9;
    padding: 15px;
    border-radius: 4px;
    margin: 20px 0;
}

.author-info {
    text-align: center;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}