/* 更新服务站点后台样式 */
* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: #f0f2f5;
    color: #333;
    font-size: 14px;
}

.admin-layout { display: flex; min-height: 100vh; }

/* 侧边栏 */
.sidebar {
    width: 220px;
    background: linear-gradient(180deg, #1e293b 0%, #0f172a 100%);
    color: #cbd5e1;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0; left: 0; bottom: 0;
    z-index: 100;
}
.sidebar-brand {
    padding: 20px 18px;
    font-size: 17px;
    font-weight: 600;
    color: #fff;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    display: flex; align-items: center; gap: 10px;
}
.sidebar-brand i { color: #38bdf8; }
.sidebar-nav { flex: 1; padding: 12px 0; overflow-y: auto; }
.sidebar-nav .nav-link {
    display: flex; align-items: center; gap: 12px;
    padding: 11px 20px;
    color: #cbd5e1;
    text-decoration: none;
    transition: all .15s;
    border-left: 3px solid transparent;
}
.sidebar-nav .nav-link:hover { background: rgba(255,255,255,0.06); color: #fff; }
.sidebar-nav .nav-link.active {
    background: rgba(56,189,248,0.12);
    color: #38bdf8;
    border-left-color: #38bdf8;
}
.sidebar-nav .nav-link i { width: 18px; text-align: center; }
.sidebar-footer { padding: 12px 20px; border-top: 1px solid rgba(255,255,255,0.08); }

/* 主区域 */
.main-wrap {
    flex: 1;
    margin-left: 220px;
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.topbar {
    height: 56px;
    background: #fff;
    border-bottom: 1px solid #e5e7eb;
    display: flex; align-items: center; justify-content: space-between;
    padding: 0 24px;
    position: sticky; top: 0; z-index: 50;
}
.topbar-title { font-weight: 600; font-size: 16px; }
.topbar-actions { display: flex; align-items: center; }
.main-content { padding: 24px; flex: 1; }

/* 卡片 */
.card {
    border: none;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    margin-bottom: 18px;
}
.card-header {
    background: #fff;
    border-bottom: 1px solid #f0f0f0;
    font-weight: 600;
    padding: 14px 18px;
    display: flex; justify-content: space-between; align-items: center;
}
.card-body { padding: 18px; }

/* 统计卡片 */
.stat-card {
    border-radius: 10px;
    padding: 20px;
    color: #fff;
    display: flex; justify-content: space-between; align-items: center;
}
.stat-card .stat-num { font-size: 28px; font-weight: 700; }
.stat-card .stat-label { font-size: 13px; opacity: 0.9; }
.stat-card .stat-icon { font-size: 40px; opacity: 0.4; }
.stat-card.bg-blue { background: linear-gradient(135deg, #3b82f6, #1d4ed8); }
.stat-card.bg-green { background: linear-gradient(135deg, #10b981, #047857); }
.stat-card.bg-orange { background: linear-gradient(135deg, #f59e0b, #b45309); }
.stat-card.bg-purple { background: linear-gradient(135deg, #8b5cf6, #6d28d9); }

/* 表格 */
table.data-table { width: 100%; }
table.data-table th {
    background: #f8fafc; color: #64748b; font-weight: 600;
    padding: 10px 12px; text-align: left; font-size: 12px;
    text-transform: uppercase; letter-spacing: 0.5px;
    border-bottom: 1px solid #e5e7eb;
}
table.data-table td { padding: 12px; border-bottom: 1px solid #f1f5f9; vertical-align: middle; }
table.data-table tr:hover td { background: #f8fafc; }

/* 标签 */
.tag { display: inline-block; padding: 2px 8px; border-radius: 4px; font-size: 12px; font-weight: 500; }
.tag-success { background: #dcfce7; color: #166534; }
.tag-warning { background: #fef3c7; color: #92400e; }
.tag-danger  { background: #fee2e2; color: #991b1b; }
.tag-info    { background: #dbeafe; color: #1e40af; }
.tag-gray    { background: #f1f5f9; color: #475569; }
.tag-purple  { background: #f3e8ff; color: #6b21a8; }

/* 按钮 */
.btn { border-radius: 6px; font-weight: 500; }
.btn-sm { padding: 4px 10px; font-size: 12px; }

/* 登录页 */
.login-wrap {
    min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, #1e293b, #0f172a);
}
.login-card {
    width: 380px;
    background: #fff;
    border-radius: 12px;
    padding: 36px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
}
.login-logo {
    text-align: center;
    margin-bottom: 24px;
    color: #1e293b;
    font-size: 20px;
    font-weight: 700;
}
.login-logo i { color: #3b82f6; margin-right: 8px; }

/* 空状态 */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #94a3b8;
}
.empty-state i { font-size: 60px; margin-bottom: 16px; }

/* 模态框 */
.modal-content { border-radius: 10px; border: none; }
.modal-header { border-bottom: 1px solid #f1f5f9; }

/* 表单 */
.form-label { font-weight: 500; color: #475569; margin-bottom: 6px; }
.form-control, .form-select { border-radius: 6px; border-color: #e2e8f0; }
.form-control:focus, .form-select:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.1);
}

/* Toast */
.toast-container { position: fixed; top: 20px; right: 20px; z-index: 9999; }

/* 响应式 */
@media (max-width: 768px) {
    .sidebar { transform: translateX(-100%); transition: transform .3s; }
    .sidebar.show { transform: translateX(0); }
    .main-wrap { margin-left: 0; }
}
