* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: #f0f2f5;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

header {
    text-align: center;
    padding: 30px 0;
}

header h1 {
    font-size: 28px;
    color: #1a73e8;
    margin-bottom: 6px;
}

.subtitle {
    color: #666;
    font-size: 15px;
}

.card {
    background: #fff;
    border-radius: 10px;
    padding: 24px;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.card h2 {
    font-size: 18px;
    margin-bottom: 16px;
    color: #1a1a1a;
}

/* 表单 */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #444;
}

.required {
    color: #e74c3c;
}

input[type="text"],
input[type="email"],
input[type="password"],
select,
textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.2s;
    font-family: inherit;
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: #1a73e8;
    box-shadow: 0 0 0 3px rgba(26,115,232,0.1);
}

textarea {
    resize: vertical;
}

/* 按钮 */
.btn {
    display: inline-block;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-primary {
    background: #1a73e8;
    color: #fff;
}

.btn-primary:hover {
    background: #1557b0;
}

.btn-secondary {
    background: #f0f0f0;
    color: #333;
}

.btn-secondary:hover {
    background: #e0e0e0;
}

.btn-danger {
    background: #e74c3c;
    color: #fff;
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

/* 提示 */
.alert {
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 16px;
    font-size: 14px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* 统计栏 */
.stats-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.stat-item {
    flex: 1;
    background: #fff;
    border-radius: 10px;
    padding: 16px;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.stat-number {
    display: block;
    font-size: 28px;
    font-weight: 700;
    color: #333;
}

.stat-label {
    font-size: 13px;
    color: #888;
}

.stat-pending .stat-number { color: #f39c12; }
.stat-processing .stat-number { color: #3498db; }
.stat-resolved .stat-number { color: #27ae60; }

/* 筛选栏 */
.filter-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-form {
    display: flex;
    gap: 8px;
}

.filter-form select {
    width: auto;
    padding: 6px 10px;
    font-size: 13px;
}

/* 问题列表 */
.question-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.question-item {
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 16px;
    transition: box-shadow 0.2s;
}

.question-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.question-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.question-id {
    font-size: 13px;
    color: #888;
    font-weight: 600;
}

.question-title {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a1a;
    flex: 1;
}

/* 徽章 */
.badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.badge-pending {
    background: #fff3cd;
    color: #856404;
}

.badge-processing {
    background: #cce5ff;
    color: #004085;
}

.badge-resolved {
    background: #d4edda;
    color: #155724;
}

.question-meta {
    display: flex;
    gap: 16px;
    font-size: 13px;
    color: #888;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.question-content {
    font-size: 14px;
    color: #444;
    background: #fafafa;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 10px;
    white-space: pre-wrap;
}

.question-reply {
    background: #e8f5e9;
    padding: 12px;
    border-radius: 6px;
    margin-bottom: 10px;
    font-size: 14px;
    color: #2e7d32;
    border-left: 3px solid #27ae60;
}

.question-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.question-actions select {
    width: auto;
    padding: 5px 8px;
    font-size: 13px;
}

.reply-form {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #eee;
}

.no-data {
    text-align: center;
    color: #999;
    padding: 30px 0;
}

/* 页脚 */
footer {
    text-align: center;
    padding: 20px 0;
}

.admin-link {
    color: #1a73e8;
    text-decoration: none;
    font-size: 14px;
    margin: 0 10px;
}

.admin-link:hover {
    text-decoration: underline;
}

/* 响应式 */
@media (max-width: 600px) {
    .container { padding: 12px; }
    .stats-bar { flex-direction: column; }
    .filter-bar { flex-direction: column; align-items: stretch; }
    .filter-form { flex-direction: column; }
    .question-meta { flex-direction: column; gap: 4px; }
    .question-actions { flex-direction: column; align-items: flex-start; }
}
