﻿/* ============================================================
   栖屿社区 · 管理后台样式 (Ant Design 5 设计语言重构)
   中性卡片 + 细边框轻阴影 + 收敛圆角 + 金色品牌强调
   ============================================================ */
:root {
  --gold: #d4a53a;
  --gold-weak: #f7dd9e;
  --gold-deep: #b8860b;
  --ink: rgba(0, 0, 0, .88);
  --text: rgba(0, 0, 0, .88);
  --text-2: rgba(0, 0, 0, .65);
  --muted: rgba(0, 0, 0, .45);
  --bg: #f5f5f5;
  --card: #ffffff;
  --line: #f0f0f0;
  --line-2: #d9d9d9;
  --red: #ff4d4f;
  --red-bg: #fff1f0;
  --green: #52c41a;
  --green-bg: #f6ffed;
  --gold-bg: #fffbe6;
  --shadow-card: 0 1px 2px rgba(0, 0, 0, .04);
  --shadow-pop: 0 6px 16px 0 rgba(0, 0, 0, .08), 0 3px 6px -4px rgba(0, 0, 0, .12), 0 9px 28px 8px rgba(0, 0, 0, .05);
  --radius: 8px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
html, body { height: 100%; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg); color: var(--text); font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
a { text-decoration: none; color: inherit; }
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-thumb { background: #d9d9d9; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #bfbfbf; }

/* ---------- 布局 ---------- */
.layout { display: flex; height: 100vh; }
.sidebar {
  width: 224px; background: #1f1f1f; color: rgba(255,255,255,.65);
  display: flex; flex-direction: column; flex-shrink: 0; transition: margin .25s;
}
.sidebar .brand { display: flex; align-items: center; gap: 10px; padding: 16px 20px 14px; border-bottom: 1px solid rgba(255,255,255,.08); }
.sidebar .brand .logo {
  width: 34px; height: 34px; border-radius: 8px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--gold-weak), var(--gold)); color: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,.2);
}
.sidebar .brand .logo svg { width: 20px; height: 20px; color: #fff; }
.sidebar .brand .name { font-size: 15px; font-weight: 600; color: rgba(255,255,255,.92); letter-spacing: .5px; }
.sidebar .brand .sub { font-size: 11px; color: rgba(255,255,255,.35); }
.sidebar nav { flex: 1; overflow-y: auto; padding: 8px; }
.sidebar nav .group { font-size: 12px; color: rgba(255,255,255,.35); padding: 12px 12px 4px; letter-spacing: 1px; }
.sidebar nav a {
  display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 6px; margin-bottom: 2px;
  color: rgba(255,255,255,.65); font-size: 14px; transition: all .18s; cursor: pointer; line-height: 1.5;
}
.sidebar nav a:hover { background: rgba(255,255,255,.08); color: rgba(255,255,255,.9); }
.sidebar nav a.active {
  background: var(--gold); color: #fff; font-weight: 500;
  box-shadow: 0 2px 6px rgba(212,165,58,.35);
}
.sidebar nav a .ico { width: 18px; height: 18px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.sidebar nav a .ico svg { width: 16px; height: 16px; }
.sidebar .foot { padding: 12px 20px; border-top: 1px solid rgba(255,255,255,.08); font-size: 12px; color: rgba(255,255,255,.3); }

.hamburger { display: none; border: none; background: none; color: var(--ink); cursor: pointer; margin-right: 12px; align-items: center; padding: 4px; }
.hamburger svg { width: 20px; height: 20px; display: block; }
@media (max-width: 768px) { .hamburger { display: inline-flex; } }
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 56px; background: var(--card); border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between; padding: 0 24px;
}
.topbar .page-title { font-size: 17px; font-weight: 600; color: var(--ink); }
.topbar-right { display: flex; align-items: center; gap: 12px; }
.topbar-right .avatar {
  width: 32px; height: 32px; border-radius: 50%; background: var(--gold);
  display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 600; font-size: 14px;
}
.topbar-right .name { font-weight: 500; font-size: 14px; color: var(--text-2); }
.topbar .btn-logout {
  display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line-2);
  background: #fff; color: var(--text); cursor: pointer; font-size: 13px; padding: 5px 12px;
  border-radius: 6px; transition: all .18s;
}
.topbar .btn-logout:hover { color: var(--gold-deep); border-color: var(--gold); }
.topbar .btn-logout svg { width: 14px; height: 14px; }
.content { flex: 1; overflow-y: auto; padding: 24px; }

/* ---------- 卡片 ---------- */
.card {
  background: var(--card); border-radius: var(--radius); border: 1px solid var(--line);
  box-shadow: var(--shadow-card); padding: 20px 24px; margin-bottom: 16px;
}
.card .card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 16px; flex-wrap: wrap; gap: 8px; }
.card .card-title { font-size: 16px; font-weight: 600; color: var(--ink); }
.card .card-title small { font-weight: 400; color: var(--muted); margin-left: 8px; font-size: 13px; }

/* ---------- 统计卡片 (antd Statistic 风格) ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 24px; }
.stat {
  background: var(--card); border-radius: var(--radius); border: 1px solid var(--line);
  box-shadow: var(--shadow-card); padding: 20px 24px; position: relative; overflow: hidden;
  transition: box-shadow .2s;
}
.stat:hover { box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.stat .label { font-size: 14px; color: var(--text-2); }
.stat .value { font-size: 30px; font-weight: 600; color: var(--ink); margin-top: 8px; font-variant-numeric: tabular-nums; }
.stat .value small { font-size: 14px; color: var(--muted); font-weight: 400; margin-left: 4px; }
.stat .extra { font-size: 13px; color: var(--muted); margin-top: 6px; }
.stat .extra:not(:empty)::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); margin-right: 6px; vertical-align: 1px; }

/* ---------- 按钮 (antd Button 风格) ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; cursor: pointer;
  padding: 6px 15px; border-radius: 6px; font-size: 14px; line-height: 1.57;
  border: 1px solid var(--gold); background: var(--gold); color: #fff;
  transition: all .18s; font-weight: 400;
  box-shadow: 0 2px 0 rgba(0,0,0,.02);
}
.btn:hover { opacity: .88; }
.btn:active { opacity: 1; box-shadow: none; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.ghost { background: #fff; color: var(--text); border-color: var(--line-2); box-shadow: none; }
.btn.ghost:hover { color: var(--gold-deep); border-color: var(--gold); opacity: 1; }
.btn.danger { background: #fff; color: var(--red); border-color: #ffccc7; box-shadow: none; }
.btn.danger:hover { color: #fff; background: var(--red); border-color: var(--red); opacity: 1; }
.btn.small { padding: 2px 8px; font-size: 12px; border-radius: 4px; }

/* ---------- 工具栏 / 输入 ---------- */
.toolbar { display: flex; align-items: center; gap: 10px; margin-bottom: 0; flex-wrap: wrap; }
.toolbar input[type=text], .toolbar select {
  height: 32px; border: 1px solid var(--line-2); border-radius: 6px; padding: 0 11px;
  font-size: 14px; outline: none; background: #fff; min-width: 200px; transition: all .18s;
}
.toolbar input[type=text]:hover, .toolbar select:hover { border-color: #4096ff; }
.toolbar input[type=text]:focus, .toolbar select:focus { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(212,165,58,.15); }

/* ---------- 表格 (antd Table 风格) ---------- */
.table { width: 100%; border-collapse: separate; border-spacing: 0; }
.table th {
  text-align: left; font-size: 14px; color: var(--text-2); font-weight: 500;
  padding: 12px 16px; background: #fafafa; border-bottom: 1px solid var(--line); white-space: nowrap;
}
.table td { padding: 12px 16px; border-bottom: 1px solid var(--line); font-size: 14px; vertical-align: middle; }
.table tr:last-child td { border-bottom: none; }
.table tbody tr { transition: background .15s; }
.table tbody tr:hover td { background: #fafafa; }
.table .avatar-sm { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; vertical-align: middle; margin-right: 10px; }
.table .thumb { width: 48px; height: 32px; border-radius: 4px; object-fit: cover; vertical-align: middle; }
.table .actions { display: flex; gap: 8px; }
.table .actions .btn { padding: 2px 8px; font-size: 12px; }
.table .muted { color: var(--muted); }
.table .ellipsis { max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- 徽章 (antd Tag 风格) ---------- */
.badge { display: inline-block; padding: 1px 8px; border-radius: 4px; font-size: 12px; line-height: 20px; border: 1px solid transparent; }
.badge.green { background: var(--green-bg); color: var(--green); border-color: #b7eb8f; }
.badge.red { background: var(--red-bg); color: var(--red); border-color: #ffccc7; }
.badge.gold { background: var(--gold-bg); color: var(--gold-deep); border-color: #ffe58f; }
.badge.gray { background: #fafafa; color: var(--muted); border-color: var(--line-2); }

/* ---------- 分页 ---------- */
.pager { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin-top: 16px; font-size: 14px; color: var(--muted); }
.pager .btn { padding: 3px 10px; font-size: 13px; }
.pager .btn:disabled { opacity: .4; }

/* ---------- 表单 (antd Form 风格) ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 24px; }
.form-item label { display: block; font-size: 14px; color: var(--text-2); margin-bottom: 8px; }
.form-item input[type=text], .form-item input[type=password], .form-item input[type=number], .form-item input[type=email], .form-item input[type=color], .form-item select, .form-item textarea {
  width: 100%; height: 32px; border: 1px solid var(--line-2); border-radius: 6px; padding: 0 11px;
  font-size: 14px; outline: none; background: #fff; font-family: inherit; transition: all .18s;
}
.form-item textarea { height: auto; padding: 6px 11px; min-height: 90px; resize: vertical; }
.form-item input:hover, .form-item textarea:hover, .form-item select:hover { border-color: #4096ff; }
.form-item input:focus, .form-item textarea:focus, .form-item select:focus { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(212,165,58,.15); background: #fff; }
.form-item input[type=color] { padding: 2px; }
.form-item .full, .form-item.full { grid-column: 1 / -1; }

/* ---------- 模态框 (antd Modal 风格) ---------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(0, 0, 0, .45);
  display: flex; align-items: center; justify-content: center; z-index: 100;
  animation: maskIn .2s ease;
}
.modal {
  background: #fff; border-radius: 10px; width: 560px; max-width: 92vw; max-height: 88vh;
  overflow-y: auto; box-shadow: var(--shadow-pop); animation: modalIn .2s cubic-bezier(.08,.82,.17,1);
}
.modal.sm { width: 420px; }
.modal .m-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 24px; border-bottom: 1px solid var(--line); }
.modal .m-head h3 { font-size: 16px; font-weight: 600; color: var(--ink); }
.modal .m-close { border: none; background: none; font-size: 18px; color: var(--muted); cursor: pointer; padding: 4px; line-height: 1; border-radius: 4px; transition: all .15s; }
.modal .m-close:hover { color: var(--ink); background: rgba(0,0,0,.04); }
.modal .m-body { padding: 24px; }
.modal .m-foot { padding: 12px 24px 16px; border-top: 1px solid var(--line); display: flex; justify-content: flex-end; gap: 8px; }
@keyframes modalIn { from { transform: scale(.85); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@keyframes maskIn { from { opacity: 0; } to { opacity: 1; } }

/* ---------- Toast (antd message 风格) ---------- */
#toast {
  position: fixed; top: 24px; left: 50%; transform: translateX(-50%) translateY(-16px);
  z-index: 1000; padding: 8px 16px; border-radius: 8px; font-size: 14px; color: rgba(0,0,0,.88);
  background: #fff; box-shadow: var(--shadow-pop); opacity: 0; pointer-events: none;
  transition: all .3s cubic-bezier(.08,.82,.17,1); max-width: 70vw;
}
#toast[style*="opacity: 1"] { transform: translateX(-50%) translateY(0); }

/* ---------- 空状态 ---------- */
.empty { text-align: center; color: var(--muted); padding: 48px 0; font-size: 14px; }
.empty .emoji { font-size: 40px; margin-bottom: 12px; display: flex; align-items: center; justify-content: center; }
.empty .emoji svg { width: 44px; height: 44px; opacity: .35; }

/* ---------- 登录页 (兼容 admin.css 引用的类) ---------- */
.login-body { display: flex; align-items: center; justify-content: center; min-height: 100vh; background: #f5f5f5; }
.login-card {
  width: 380px; background: #fff; border-radius: 12px; padding: 40px 36px;
  box-shadow: var(--shadow-pop); border: 1px solid var(--line);
}
.login-card h1 { color: var(--ink); font-size: 20px; text-align: center; margin-bottom: 4px; font-weight: 600; }
.login-card .logo { width: 56px; height: 56px; margin: 0 auto 20px; border-radius: 12px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--gold-weak), var(--gold)); box-shadow: 0 4px 12px rgba(212,165,58,.3); }
.login-card .logo svg { width: 28px; height: 28px; color: #fff; }
.login-card .sub { text-align: center; color: var(--muted); font-size: 13px; margin-bottom: 28px; }
.login-card input {
  width: 100%; height: 40px; border: 1px solid var(--line-2); border-radius: 6px; padding: 0 12px;
  font-size: 14px; margin-bottom: 16px; background: #fff; color: var(--ink); outline: none; transition: all .18s;
}
.login-card input::placeholder { color: var(--muted); }
.login-card input:hover { border-color: #4096ff; }
.login-card input:focus { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(212,165,58,.15); }
.login-card .btn { width: 100%; height: 40px; font-size: 15px; margin-top: 4px; }
.login-msg { color: var(--red); font-size: 13px; margin-bottom: 10px; text-align: center; min-height: 18px; }

@media (max-width: 768px) {
  .sidebar { position: fixed; z-index: 50; height: 100%; margin-left: -224px; }
  .sidebar.open { margin-left: 0; }
  .form-grid { grid-template-columns: 1fr; }
  .content { padding: 16px; }
}

/* ============ 第二轮美化: logo / 交互 / 动画 / 细节 ============ */
/* logo 图片适配 */
.sidebar .brand .logo-img { width: 34px; height: 34px; border-radius: 8px; object-fit: cover; display: block; box-shadow: 0 2px 8px rgba(0,0,0,.35); }
.login-card .logo-img { width: 64px; height: 64px; border-radius: 14px; object-fit: cover; display: block; margin: 0 auto 18px; box-shadow: 0 8px 20px rgba(0,0,0,.14); }
/* 登录页背景光晕装饰 */
body.login-page { position: relative; overflow: hidden; }
body.login-page::before { content: ""; position: fixed; width: 480px; height: 480px; border-radius: 50%; background: radial-gradient(circle, rgba(212,165,58,.20), transparent 65%); top: -160px; right: -120px; pointer-events: none; z-index: 0; }
body.login-page::after { content: ""; position: fixed; width: 560px; height: 560px; border-radius: 50%; background: radial-gradient(circle, rgba(212,165,58,.13), transparent 65%); bottom: -220px; left: -160px; pointer-events: none; z-index: 0; }
.login-wrap { position: relative; z-index: 1; }
/* 卡片交互提升 */
.card { transition: box-shadow .25s, transform .25s; }
.card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.08); }
.stat:hover { transform: translateY(-2px); }
/* 内容区入场动画 */
.content .card, .content .stats { animation: fadeUp .35s ease both; }
.content .card:nth-of-type(2) { animation-delay: .05s; }
.content .card:nth-of-type(3) { animation-delay: .1s; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
/* 顶栏细节 */
.topbar { box-shadow: 0 1px 4px rgba(0,0,0,.04); }
/* 弹窗细节 */
.modal .m-body .form-grid { margin-bottom: 8px; }
.modal .m-foot .btn { min-width: 76px; }
/* 表格操作按钮列不换行 */
.table td:last-child { white-space: nowrap; }
/* 分页按钮组 */
.pager .btn.ghost { border-radius: 4px; }
/* 统计数字更精致 */
.stat .value { letter-spacing: -.5px; }
/* 工具按钮与输入框高度统一 */
.toolbar .btn { height: 32px; }
/* 侧边栏滚动条美化 */
.sidebar nav::-webkit-scrollbar { width: 4px; }
.sidebar nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,.15); }
/* ============ 第三轮: MUI Dashboard 风格统计卡 ============ */
.stat { display: flex; align-items: flex-start; gap: 14px; }
.stat-ico {
  width: 46px; height: 46px; border-radius: 12px; display: flex; align-items: center; justify-content: center;
  color: #fff; flex-shrink: 0;
}
.stat-ico svg { width: 22px; height: 22px; }
.stat-ico.blue   { background: linear-gradient(135deg, #4096ff, #1677ff); box-shadow: 0 6px 14px rgba(22,119,255,.30); }
.stat-ico.gold   { background: linear-gradient(135deg, #f7dd9e, #d4a53a); box-shadow: 0 6px 14px rgba(212,165,58,.32); }
.stat-ico.purple { background: linear-gradient(135deg, #9254de, #722ed1); box-shadow: 0 6px 14px rgba(114,46,209,.30); }
.stat-ico.green  { background: linear-gradient(135deg, #73d13d, #52c41a); box-shadow: 0 6px 14px rgba(82,196,26,.30); }
.stat-ico.red    { background: linear-gradient(135deg, #ff7875, #ff4d4f); box-shadow: 0 6px 14px rgba(255,77,79,.30); }
.stat-ico.orange { background: linear-gradient(135deg, #ffa940, #fa8c16); box-shadow: 0 6px 14px rgba(250,140,22,.30); }
.stat-ico.cyan   { background: linear-gradient(135deg, #36cfc9, #13c2c2); box-shadow: 0 6px 14px rgba(19,194,194,.30); }
.stat-ico.deep   { background: linear-gradient(135deg, #e0b45c, #b8860b); box-shadow: 0 6px 14px rgba(184,134,11,.32); }
.stat-info { flex: 1; min-width: 0; }
.stat-info .value { margin-top: 4px; }
.stat-info .extra { margin-top: 2px; }

/* ============ 第四轮: 侧边栏图标 + 卡片质感（MUI Dashboard 风格化） ============ */
/* --- 侧边栏菜单项: 图标块化 --- */
.sidebar nav a { gap: 12px; padding: 9px 12px; border-radius: 8px; margin-bottom: 3px; position: relative; }
.sidebar nav a .ico {
  width: 30px; height: 30px; border-radius: 8px; display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.07); transition: all .2s; flex-shrink: 0;
}
.sidebar nav a .ico svg { width: 15px; height: 15px; }
.sidebar nav a:hover { background: rgba(255,255,255,.07); }
.sidebar nav a:hover .ico { background: rgba(255,255,255,.14); }
.sidebar nav a.active {
  background: linear-gradient(90deg, rgba(212,165,58,.20), rgba(212,165,58,.05));
  color: #f5dd9d; font-weight: 500; box-shadow: none;
}
.sidebar nav a.active::before {
  content: ""; position: absolute; left: -8px; top: 22%; bottom: 22%; width: 3px; border-radius: 3px;
  background: linear-gradient(180deg, #f7dd9e, #d4a53a);
}
.sidebar nav a.active .ico { background: linear-gradient(135deg, #f7dd9e, #d4a53a); box-shadow: 0 3px 8px rgba(212,165,58,.4); }
.sidebar nav a.active .ico svg { color: #fff; }
/* --- 分组标题 --- */
.sidebar nav .group { padding: 18px 12px 6px; color: rgba(255,255,255,.28); font-size: 11px; letter-spacing: 2px; }
.sidebar nav .group:first-child { padding-top: 10px; }
/* --- 卡片 MUI 质感 --- */
.card, .stat {
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(0,0,0,.05), 0 4px 14px rgba(0,0,0,.04);
}
.card:hover {
  box-shadow: 0 2px 6px rgba(0,0,0,.06), 0 10px 26px rgba(0,0,0,.09);
  transform: translateY(-1px);
}
.card .card-title { position: relative; padding-left: 12px; }
.card .card-title::before {
  content: ""; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 3px; height: 16px; border-radius: 3px;
  background: linear-gradient(180deg, #f7dd9e, #d4a53a);
}
/* --- 统计卡 --- */
.stats { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.stat:hover { transform: translateY(-3px); box-shadow: 0 2px 6px rgba(0,0,0,.06), 0 12px 30px rgba(0,0,0,.10); }
.stat-ico { border-radius: 12px; }
/* --- 顶栏头像 --- */
.topbar-right .avatar {
  background: linear-gradient(135deg, #f7dd9e, #d4a53a);
  box-shadow: 0 2px 6px rgba(212,165,58,.35);
}


/* ============ 第五轮: ionicons 图标 + 侧边栏卡片效果 ============ */
/* ionicons(512 viewBox) 显示尺寸适配 */
.sidebar nav a .ico svg { width: 20px; height: 20px; }
.stat-ico svg { width: 24px; height: 24px; }
/* 菜单项卡片化 hover */
.sidebar nav a { transition: all .2s ease; }
.sidebar nav a:hover { background: rgba(255,255,255,.09); box-shadow: 0 4px 12px rgba(0,0,0,.28); }
.sidebar nav a:hover .ico { transform: scale(1.06); }
.sidebar nav a.active { transition: all .2s ease; }
.sidebar nav a.active .ico { transform: none; }


/* ============================================================
   第六轮: Adminator 风格整体改造（浅色侧边栏 + 高级卡片质感）
   ============================================================ */
:root {
  --bg: #f5f6fa;
  --line: #e9ecef;
  --line-2: #dee2e6;
  --radius: 10px;
  --shadow-card: 0 1px 3px rgba(16,24,40,.05), 0 1px 2px rgba(16,24,40,.04);
  --text: #1a1d29;
  --text-2: #495057;
  --muted: #868e96;
}
/* ---------- 侧边栏: 白色简约 ---------- */
.sidebar {
  background: #ffffff; color: #495057; border-right: 1px solid #e9ecef; width: 232px;
}
.sidebar .brand { border-bottom: 1px solid #f1f3f5; padding: 18px 20px 16px; }
.sidebar .brand .name { color: #1a1d29; }
.sidebar .brand .sub { color: #adb5bd; }
.sidebar nav { padding: 6px; }
.sidebar nav .group {
  color: #adb5bd; font-size: 11px; font-weight: 600; letter-spacing: 1.5px;
  padding: 20px 14px 8px;
}
.sidebar nav .group:first-child { padding-top: 10px; }
.sidebar nav a {
  color: #495057; border-radius: 8px; padding: 8px 12px; margin: 2px 4px;
}
.sidebar nav a:hover { background: #f8f9fa; color: #1a1d29; box-shadow: none; }
.sidebar nav a .ico { background: #f1f3f5; border-radius: 8px; }
.sidebar nav a:hover .ico { background: #e9ecef; transform: none; }
.sidebar nav a.active {
  background: linear-gradient(90deg, #fff7e0, #ffffff);
  color: #b8860b; font-weight: 600;
}
.sidebar nav a.active::before { left: -4px; }
.sidebar nav a.active .ico { background: linear-gradient(135deg, #f7dd9e, #d4a53a); }
.sidebar nav a.active .ico svg { color: #fff; }
.sidebar .foot { color: #adb5bd; border-top: 1px solid #f1f3f5; }
/* 侧边栏滚动条 */
.sidebar nav::-webkit-scrollbar-thumb { background: #e9ecef; }
/* ---------- 顶栏 ---------- */
.topbar { background: #ffffff; border-bottom: 1px solid #e9ecef; height: 60px; box-shadow: none; }
.topbar .page-title { font-size: 18px; font-weight: 700; color: #1a1d29; }
.topbar-right .name { color: #495057; font-weight: 500; }
.topbar .btn-logout { border-radius: 8px; border-color: #e9ecef; color: #495057; }
.topbar .btn-logout:hover { color: #b8860b; border-color: #d4a53a; }
/* ---------- 内容区 ---------- */
.content { padding: 24px 28px; }
/* ---------- 卡片 ---------- */
.card {
  background: #ffffff; border: 1px solid #e9ecef; border-radius: 10px;
  box-shadow: 0 1px 3px rgba(16,24,40,.05); padding: 22px 24px;
}
.card .card-title { font-size: 15px; font-weight: 700; color: #1a1d29; }
.card:hover { box-shadow: 0 2px 6px rgba(16,24,40,.06), 0 8px 20px rgba(16,24,40,.05); }
/* ---------- 统计卡: Adminator 风格 ---------- */
.stats { grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 18px; }
.stat {
  border-radius: 10px; border: 1px solid #e9ecef;
  box-shadow: 0 1px 3px rgba(16,24,40,.05); padding: 18px 20px;
}
.stat .label { font-size: 13px; color: #868e96; font-weight: 500; }
.stat .value { font-size: 26px; font-weight: 700; color: #1a1d29; letter-spacing: -.5px; }
.stat .extra {
  display: inline-block; margin-top: 8px; font-size: 12px; font-weight: 600;
  padding: 3px 10px; border-radius: 999px; background: #f1f3f5; color: #495057;
}
.stat:hover { transform: translateY(-3px); box-shadow: 0 4px 10px rgba(16,24,40,.08); }
/* ---------- 表格 ---------- */
.table thead th { background: #f8f9fa; color: #495057; font-weight: 600; }
.table tbody tr:hover { background: #f8f9fa; }
/* ---------- 按钮与输入框 ---------- */
.btn { border-radius: 8px; }
.toolbar input { border-radius: 8px; }
/* ---------- 弹窗遮罩微调 ---------- */
.modal .m-panel { border-radius: 12px; }
/* ---------- 分页 ---------- */
.pager .btn { border-radius: 6px; }
/* ---------- 标签/徽章 ---------- */
.tag { border-radius: 6px; }


/* ============================================================
   第七轮: 组件精修 —— 选中图标 / 弹窗 / 输入框 / 新页面组件
   ============================================================ */
/* ---------- 侧边栏选中态: 黑色 + 白色图标块 + 白点 ---------- */
.sidebar nav a { position: relative; }
.sidebar nav a.active {
  background: linear-gradient(90deg, #1f242e, #2c3340 70%, #363e4d);
  color: #fff; font-weight: 700;
  box-shadow: inset 3px 0 0 #000, 0 2px 6px rgba(0,0,0,.22);
}
.sidebar nav a.active::after {
  content: ""; position: absolute; right: 10px; top: 50%; transform: translateY(-50%);
  width: 6px; height: 6px; border-radius: 50%; background: #fff;
  box-shadow: 0 0 0 3px rgba(255,255,255,.25);
}
.sidebar nav a .ico {
  width: 26px; height: 26px; border-radius: 8px;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .2s ease;
}
.sidebar nav a .ico svg { width: 16px; height: 16px; }
.sidebar nav a.active .ico {
  background: linear-gradient(135deg, #4b5568, #1a1f2a);
  box-shadow: 0 3px 8px rgba(0,0,0,.4);
}
.sidebar nav a.active .ico svg { color: #fff; filter: drop-shadow(0 1px 1px rgba(0,0,0,.2)); }

/* ---------- 弹窗: 卡片化 + 入场动画 ---------- */
.modal-mask { backdrop-filter: blur(3px); background: rgba(15,23,42,.45); }
.modal {
  border-radius: 16px; border: 1px solid #f1f3f5;
  box-shadow: 0 12px 40px rgba(16,24,40,.18), 0 2px 8px rgba(16,24,40,.08);
  animation: mPop .22s cubic-bezier(.2,.9,.3,1.2); overflow: hidden;
}
@keyframes mPop { from { transform: scale(.94) translateY(8px); opacity: 0; } to { transform: none; opacity: 1; } }
.modal .m-head {
  background: linear-gradient(135deg, #fffdf6, #fff);
  border-bottom: 1px solid #f1f3f5; padding: 16px 20px;
}
.modal .m-head h3 { font-size: 15px; font-weight: 700; color: #1a1d29; margin: 0; }
.modal .m-close {
  border-radius: 8px; width: 28px; height: 28px; color: #868e96;
  transition: all .15s ease;
}
.modal .m-close:hover { background: #f1f3f5; color: #c0392b; }
.modal .m-body { padding: 20px; }
.modal .m-foot {
  padding: 14px 20px; background: #fafbfc; border-top: 1px solid #f1f3f5;
  display: flex; justify-content: flex-end; gap: 10px;
}

/* ---------- 输入框 / 下拉: 统一精致 ---------- */
.form-item label { font-size: 12px; font-weight: 600; color: #495057; margin-bottom: 6px; display: block; }
.form-item input[type=text], .form-item input[type=number], .form-item input[type=password],
.form-item select, .toolbar input, .toolbar select {
  height: 36px; border-radius: 8px; border: 1px solid #dee2e6;
  background: #fff; color: #1a1d29; font-size: 13px; padding: 0 12px;
  transition: all .18s ease; width: 100%; box-sizing: border-box;
}
.form-item input:hover, .form-item select:hover, .toolbar input:hover, .toolbar select:hover { border-color: #c9992e; }
.form-item input:focus, .form-item select:focus, .toolbar input:focus, .toolbar select:focus {
  border-color: #d4a53a; box-shadow: 0 0 0 3px rgba(212,165,58,.16); outline: none;
}
.form-item input[type=color] { height: 36px; border-radius: 8px; border: 1px solid #dee2e6; padding: 2px; cursor: pointer; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; }
.form-grid .form-item:first-child:nth-last-child(1) { grid-column: 1/-1; }

/* ---------- 新页面组件: tabs / mini-card ---------- */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; }
.tabs .tab {
  padding: 5px 14px; border-radius: 999px; border: 1px solid #e9ecef;
  background: #fff; color: #495057; font-size: 12px; font-weight: 600;
  cursor: pointer; transition: all .18s ease;
}
.tabs .tab:hover { border-color: #d4a53a; color: #b8860b; }
.tabs .tab.on {
  background: linear-gradient(135deg, #f7dd9e, #d4a53a); color: #fff;
  border-color: #d4a53a; box-shadow: 0 3px 8px rgba(212,165,58,.35);
}
.mini-card {
  background: #fff; border: 1px solid #e9ecef; border-radius: 12px; padding: 12px;
  box-shadow: 0 1px 3px rgba(16,24,40,.05); transition: all .2s ease;
}
.mini-card:hover { transform: translateY(-3px); box-shadow: 0 6px 16px rgba(16,24,40,.09); border-color: #f1d48c; }

/* ---------- 徽章 / 表格 / 操作列精修 ---------- */
.badge { border-radius: 999px; padding: 2px 10px; font-size: 12px; font-weight: 600; }
.badge.green { background: #e8f8ee; color: #1a9e57; }
.badge.red { background: #fff1f0; color: #d4380d; }
.badge.gray { background: #f1f3f5; color: #868e96; }
.badge.gold { background: #fff7e6; color: #b8860b; }
.table td { padding: 10px 12px; font-size: 13px; }
.table thead th { font-size: 12px; letter-spacing: .3px; }
.actions { display: flex; gap: 6px; flex-wrap: wrap; }
.actions .btn { white-space: nowrap; }
.empty { color: #adb5bd; font-size: 13px; padding: 26px 0; text-align: center; }

/* ---------- 分页精修 ---------- */
.pager { display: flex; align-items: center; gap: 10px; margin-top: 16px; font-size: 12px; color: #868e96; }
.pager .btn.small { min-width: 30px; }


/* ============================================================
   第八轮: 右上角用户菜单（个人信息 / 修改密码 / 更换头像）
   ============================================================ */
.topbar-right { display: flex; align-items: center; gap: 12px; }
.user-menu { position: relative; }
.user-btn {
  display: flex; align-items: center; gap: 8px; background: #fff; border: 1px solid #e9ecef;
  border-radius: 999px; padding: 4px 12px 4px 4px; cursor: pointer; transition: all .2s ease;
}
.user-btn:hover { border-color: #adb5bd; box-shadow: 0 2px 8px rgba(16,24,40,.08); }
.user-btn .avatar-img { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; }
.user-btn .avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: linear-gradient(135deg, #1f242e, #3a4356); color: #fff; font-size: 13px;
  display: inline-flex; align-items: center; justify-content: center; font-weight: 600;
}
.user-btn .name { font-size: 13px; color: #1a1d29; font-weight: 500; }
.user-btn .caret { color: #868e96; transition: transform .2s ease; }
.user-menu.open .caret { transform: rotate(180deg); }
.user-dropdown {
  position: absolute; right: 0; top: calc(100% + 10px); width: 232px; background: #fff;
  border: 1px solid #e9ecef; border-radius: 14px; box-shadow: 0 12px 36px rgba(16,24,40,.16);
  padding: 8px; display: none; z-index: 60;
  animation: mPop .18s ease;
}
.user-dropdown.open { display: block; }
.ud-head { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid #f1f3f5; margin-bottom: 6px; }
.ud-avatar { width: 40px; height: 40px; border-radius: 50%; object-fit: cover; }
.ud-avatar-fallback {
  width: 40px; height: 40px; border-radius: 50%;
  background: linear-gradient(135deg, #1f242e, #3a4356); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 600;
}
.ud-id b { display: block; font-size: 14px; color: #1a1d29; }
.ud-id small { color: #868e96; font-size: 12px; }
.ud-item {
  display: flex; align-items: center; gap: 8px; width: 100%; text-align: left;
  background: none; border: 0; border-radius: 8px; padding: 9px 12px;
  font-size: 13px; color: #1a1d29; cursor: pointer; transition: all .15s ease;
}
.ud-item:hover { background: #f1f3f5; }
.ud-item.danger { color: #d4380d; }
.ud-item.danger:hover { background: #fff1f0; }
.ud-divider { height: 1px; background: #f1f3f5; margin: 6px 4px; }

/* ---------- 个人信息弹窗 ---------- */
.profile-box { display: flex; gap: 18px; align-items: center; }
.p-avatar {
  width: 72px; height: 72px; border-radius: 50%; object-fit: cover;
  border: 3px solid #f1f3f5; background: #f8f9fa;
}
.p-rows { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; }
.p-row span { font-size: 12px; color: #868e96; display: block; margin-bottom: 2px; }
.p-row b { font-size: 14px; color: #1a1d29; }
.file-input {
  height: auto; padding: 9px 12px; border: 1px dashed #dee2e6; border-radius: 8px;
  background: #fafbfc; cursor: pointer; font-size: 13px; color: #495057;
}
.file-input:hover { border-color: #adb5bd; }


/* ============================================================
第九轮: 全面去金色 → 现代蓝色数据看板主题
（黑色侧边栏选中态 + 浅色看板结构保持不变，仅替换金色装饰）
============================================================ */
:root {
  --gold: #2563eb;
  --gold-weak: #3b82f6;
  --gold-deep: #1d4ed8;
  --gold-bg: #eff6ff;
}
/* 主按钮 → 蓝 */
.btn { border-color: #2563eb; background: linear-gradient(135deg, #3b82f6, #2563eb); box-shadow: 0 2px 8px rgba(37,99,235,.22); }
.btn:hover { opacity: .9; box-shadow: 0 4px 12px rgba(37,99,235,.30); }
.btn.ghost:hover { color: #1d4ed8; border-color: #93c5fd; background: #eff6ff; opacity: 1; }
/* 登录按钮 */
.login-card .btn { background: linear-gradient(135deg, #3b82f6, #2563eb); box-shadow: 0 4px 14px rgba(37,99,235,.28); }
/* 侧边栏 logo 图标块 */
.sidebar .brand .logo { background: linear-gradient(135deg, #3b82f6, #1d4ed8); box-shadow: 0 2px 8px rgba(37,99,235,.35); }
/* 退出按钮 hover */
.topbar .btn-logout:hover { color: #1d4ed8; border-color: #93c5fd; }
/* 统计卡圆点 */
.stat .extra:not(:empty)::before { background: #2563eb; }
/* 卡片标题左侧竖条 */
.card .card-title::before { background: linear-gradient(180deg, #3b82f6, #2563eb); }
/* 统计图标: gold / deep → 蓝 */
.stat-ico.gold, .stat-ico.deep { background: linear-gradient(135deg, #3b82f6, #2563eb); box-shadow: 0 6px 14px rgba(37,99,235,.32); }
/* 顶栏旧版头像 */
.topbar-right .avatar { background: linear-gradient(135deg, #3b82f6, #2563eb); }
/* 金色徽章 → 蓝色徽章 */
.badge.gold { background: #eff6ff; color: #1d4ed8; border-color: #93c5fd; }
/* 登录页背景光晕 → 蓝 */
body.login-page::before { background: radial-gradient(circle, rgba(59,130,246,.18), transparent 65%); }
body.login-page::after { background: radial-gradient(circle, rgba(59,130,246,.12), transparent 65%); }
/* 侧边栏选中态: 保持黑色（覆盖第四/六轮金色残留） */
.sidebar nav a.active { background: linear-gradient(90deg, #1f242e, #2c3340 70%, #363e4d); color: #fff; font-weight: 700; box-shadow: inset 3px 0 0 #000, 0 2px 6px rgba(0,0,0,.22); }
.sidebar nav a.active::before { background: linear-gradient(180deg, rgba(255,255,255,.85), rgba(255,255,255,.4)); left: -4px; }
.sidebar nav a.active .ico { background: linear-gradient(135deg, #4b5568, #1a1f2a); box-shadow: 0 3px 8px rgba(0,0,0,.4); }
.sidebar nav a.active .ico svg { color: #fff; }
/* 输入框 hover / focus → 蓝 */
.form-item input:hover, .form-item select:hover, .toolbar input:hover, .toolbar select:hover, .form-item textarea:hover { border-color: #93c5fd; }
.form-item input:focus, .form-item select:focus, .toolbar input:focus, .toolbar select:focus, .form-item textarea:focus { border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37,99,235,.15); outline: none; }
/* tabs 选中 → 蓝 */
.tabs .tab:hover { border-color: #93c5fd; color: #1d4ed8; }
.tabs .tab.on { background: linear-gradient(135deg, #3b82f6, #2563eb); color: #fff; border-color: #2563eb; box-shadow: 0 3px 8px rgba(37,99,235,.35); }
/* mini-card hover 边框 → 蓝 */
.mini-card:hover { border-color: #bfdbfe; }
/* 弹窗头部微金 → 中性浅灰 */
.modal .m-head { background: linear-gradient(135deg, #f8fafc, #fff); }
/* 设置页小标题强调 */
.settings-note { font-size: 12px; color: #868e96; line-height: 1.7; }
/* 登录页 logo 块（svg 版）→ 蓝 */
.login-card .logo { background: linear-gradient(135deg, #3b82f6, #2563eb); box-shadow: 0 4px 12px rgba(37,99,235,.3); }
.login-card input:focus { border-color: #2563eb; box-shadow: 0 0 0 2px rgba(37,99,235,.15); }

/* ============================================================
第十轮: 帖子分类图标显示(URL图片 / emoji / 首字兜底)
============================================================ */
.cls-icon {
  width: 38px; height: 38px; border-radius: 50%; object-fit: cover;
  background: #eff6ff; display: block; vertical-align: middle;
}
.cls-icon-emoji {
  font-size: 24px; line-height: 1; display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 50%; background: #f0f4fa;
}
.cls-icon-fallback {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 50%;
  background: linear-gradient(135deg, #e8f0fe, #dbe7fd); color: #2563eb;
  font-size: 15px; font-weight: 700;
}

/* ============================================================
   Tabler 主题（全局切换）
   ============================================================ */
body.theme-tabler {
  --gold: #206bc4;
  --gold-weak: #4299e1;
  --gold-deep: #1856a0;
  --bg: #f8fafc;
  --card: #ffffff;
  --line: #e9ecef;
  --line-2: #dee2e6;
  --shadow-card: 0 1px 2px 0 rgba(0,0,0,.05);
  --radius: 8px;
  background: var(--bg);
}

/* Tabler 侧边栏 - 浅色风格 */
body.theme-tabler .sidebar {
  background: #fff;
  color: #495057;
  border-right: 1px solid #e9ecef;
  width: 250px;
}
body.theme-tabler .sidebar .brand {
  border-bottom: 1px solid #e9ecef;
  padding: 20px 20px 16px;
}
body.theme-tabler .sidebar .brand .logo {
  background: #206bc4;
  border-radius: 6px;
}
body.theme-tabler .sidebar .brand .name {
  color: #182433;
}
body.theme-tabler .sidebar .brand .sub {
  color: #9aa5b1;
}
body.theme-tabler .sidebar nav .group {
  color: #9aa5b1;
  font-size: 11px;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: .5px;
}
body.theme-tabler .sidebar nav a {
  color: #495057;
  border-radius: 6px;
  margin-bottom: 2px;
  padding: 9px 12px;
}
body.theme-tabler .sidebar nav a:hover {
  background: #f1f3f5;
  color: #182433;
}
body.theme-tabler .sidebar nav a.active {
  background: #e8f3ff;
  color: #206bc4;
  font-weight: 500;
  box-shadow: none;
}
body.theme-tabler .sidebar .foot {
  border-top: 1px solid #e9ecef;
  color: #9aa5b1;
}

/* Tabler 顶部栏 */
body.theme-tabler .topbar {
  background: #fff;
  border-bottom: 1px solid #e9ecef;
  height: 60px;
  box-shadow: 0 1px 2px rgba(0,0,0,.03);
}
body.theme-tabler .topbar .page-title {
  color: #182433;
  font-weight: 600;
}

/* Tabler 卡片 */
body.theme-tabler .card {
  border: 1px solid #e9ecef;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(0,0,0,.05);
  background: #fff;
}
body.theme-tabler .card-head {
  border-bottom: 1px solid #e9ecef;
  padding: 16px 20px;
}
body.theme-tabler .card-title {
  color: #182433;
  font-weight: 600;
  font-size: 15px;
}

/* Tabler 按钮 */
body.theme-tabler .btn {
  border-radius: 6px;
  font-weight: 500;
}
body.theme-tabler .btn.primary, body.theme-tabler .btn[class*="primary"] {
  background: #206bc4;
  border-color: #206bc4;
}
body.theme-tabler .btn.primary:hover, body.theme-tabler .btn[class*="primary"]:hover {
  background: #1856a0;
  border-color: #1856a0;
}

/* Tabler 统计卡片 */
body.theme-tabler .stats .stat {
  background: #fff;
  border: 1px solid #e9ecef;
  border-radius: 8px;
  box-shadow: 0 1px 2px rgba(0,0,0,.05);
  padding: 20px;
}
body.theme-tabler .stat-ico.blue { background: #e8f3ff; color: #206bc4; }
body.theme-tabler .stat-ico.gold { background: #fff3bf; color: #f0b429; }
body.theme-tabler .stat-ico.purple { background: #e3d7ff; color: #7950f2; }
body.theme-tabler .stat-ico.green { background: #d1f2eb; color: #2fb344; }
body.theme-tabler .stat-ico.red { background: #ffe3e3; color: #e55353; }
body.theme-tabler .stat-ico.orange { background: #ffe8cc; color: #fd7e14; }
body.theme-tabler .stat-ico.cyan { background: #c5f6fa; color: #15aabf; }
body.theme-tabler .stat-ico.deep { background: #dbe4ff; color: #3b5bdb; }

/* Tabler 表格 */
body.theme-tabler .table th {
  background: #f8fafc;
  color: #65717d;
  font-weight: 500;
  font-size: 13px;
  border-bottom: 1px solid #e9ecef;
}
body.theme-tabler .table td {
  border-bottom: 1px solid #f1f3f5;
}

/* Tabler 切换按钮组 */
body.theme-tabler .theme-switcher {
  background: #f1f3f5;
  border-radius: 6px;
  padding: 3px;
  display: flex;
  gap: 2px;
}
body.theme-tabler .theme-switcher button {
  border: none;
  background: transparent;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 13px;
  cursor: pointer;
  color: #495057;
  transition: all .15s;
}
body.theme-tabler .theme-switcher button.active {
  background: #fff;
  color: #206bc4;
  font-weight: 500;
  box-shadow: 0 1px 2px rgba(0,0,0,.08);
}

/* ============================================================
   Tabler 主题 - 布局排版覆盖
   ============================================================ */

/* 整体布局 - 更宽的侧边栏，更多留白 */
body.theme-tabler .layout {
  background: #f8fafc;
}
body.theme-tabler .sidebar {
  width: 260px;
  box-shadow: 1px 0 0 #e9ecef;
}
body.theme-tabler .main {
  background: #f8fafc;
}

/* 顶部栏 - 更精致的样式 */
body.theme-tabler .topbar {
  padding: 0 24px;
  height: 64px;
  box-shadow: 0 1px 2px 0 rgba(0,0,0,.03);
}
body.theme-tabler .topbar .page-title {
  font-size: 18px;
  font-weight: 600;
  color: #182433;
}
body.theme-tabler .topbar-right .avatar {
  width: 36px;
  height: 36px;
  background: #206bc4;
  border-radius: 8px;
}

/* 内容区 - 更多内边距 */
body.theme-tabler #content {
  padding: 24px;
  max-width: 1400px;
}

/* 卡片 - Tabler 风格的卡片 */
body.theme-tabler .card {
  border-radius: 8px;
  box-shadow: 0 1px 2px 0 rgba(0,0,0,.05);
  border: 1px solid #e9ecef;
  margin-bottom: 20px;
}
body.theme-tabler .card-head {
  padding: 18px 20px;
  border-bottom: 1px solid #e9ecef;
}
body.theme-tabler .card-title {
  font-size: 15px;
  font-weight: 600;
  color: #182433;
}
body.theme-tabler .card-body,
body.theme-tabler .card > :not(.card-head) {
  padding: 20px;
}

/* 统计卡片 - Tabler 风格 */
body.theme-tabler .stats {
  gap: 20px;
  margin-bottom: 20px;
}
body.theme-tabler .stats .stat {
  border-radius: 8px;
  padding: 20px;
  box-shadow: 0 1px 2px 0 rgba(0,0,0,.05);
  border: 1px solid #e9ecef;
  transition: transform .15s, box-shadow .15s;
}
body.theme-tabler .stats .stat:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,.08);
  transform: translateY(-1px);
}
body.theme-tabler .stat .label {
  color: #65717d;
  font-size: 13px;
  font-weight: 500;
}
body.theme-tabler .stat .value {
  font-size: 28px;
  font-weight: 600;
  color: #182433;
  line-height: 1.2;
}
body.theme-tabler .stat .extra {
  color: #65717d;
  font-size: 12px;
  margin-top: 6px;
}
body.theme-tabler .stat-ico {
  width: 48px;
  height: 48px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}
body.theme-tabler .stat-ico svg {
  width: 22px;
  height: 22px;
}

/* 表格 - Tabler 风格 */
body.theme-tabler .table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}
body.theme-tabler .table th {
  padding: 12px 16px;
  background: #f8fafc;
  color: #65717d;
  font-weight: 500;
  font-size: 13px;
  text-align: left;
  border-bottom: 1px solid #e9ecef;
}
body.theme-tabler .table td {
  padding: 14px 16px;
  border-bottom: 1px solid #f1f3f5;
  color: #495057;
  font-size: 14px;
}
body.theme-tabler .table tr:hover td {
  background: #f8fafc;
}

/* 按钮 - Tabler 风格 */
body.theme-tabler .btn {
  border-radius: 6px;
  font-weight: 500;
  padding: 8px 16px;
  font-size: 14px;
  transition: all .15s;
}
body.theme-tabler .btn.small {
  padding: 6px 12px;
  font-size: 13px;
}
body.theme-tabler .btn.primary,
body.theme-tabler .btn[class*="primary"] {
  background: #206bc4;
  border-color: #206bc4;
  color: #fff;
}
body.theme-tabler .btn.primary:hover,
body.theme-tabler .btn[class*="primary"]:hover {
  background: #1856a0;
  border-color: #1856a0;
}
body.theme-tabler .btn.ghost {
  background: transparent;
  border-color: #dee2e6;
  color: #495057;
}
body.theme-tabler .btn.ghost:hover {
  background: #f8fafc;
  border-color: #adb5bd;
}

/* 表单 - Tabler 风格 */
body.theme-tabler input,
body.theme-tabler select,
body.theme-tabler textarea {
  border-radius: 6px;
  border: 1px solid #ced4da;
  padding: 8px 12px;
  font-size: 14px;
  transition: border-color .15s, box-shadow .15s;
}
body.theme-tabler input:focus,
body.theme-tabler select:focus,
body.theme-tabler textarea:focus {
  border-color: #206bc4;
  box-shadow: 0 0 0 3px rgba(32,107,196,.15);
  outline: none;
}

/* 标签 - Tabler 风格 */
body.theme-tabler .badge {
  border-radius: 6px;
  padding: 3px 8px;
  font-size: 12px;
  font-weight: 500;
}
body.theme-tabler .badge.blue { background: #e8f3ff; color: #206bc4; }
body.theme-tabler .badge.green { background: #d1f2eb; color: #2fb344; }
body.theme-tabler .badge.red { background: #ffe3e3; color: #e55353; }

/* 侧边栏菜单 - Tabler 风格 */
body.theme-tabler .sidebar nav a {
  padding: 10px 14px;
  font-size: 14px;
  border-radius: 6px;
  margin-bottom: 2px;
  color: #495057;
}
body.theme-tabler .sidebar nav a:hover {
  background: #f1f3f5;
  color: #182433;
}
body.theme-tabler .sidebar nav a.active {
  background: #e8f3ff;
  color: #206bc4;
  font-weight: 500;
}
body.theme-tabler .sidebar nav .group {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: #9aa5b1;
  padding: 16px 14px 6px;
}

/* 空状态 */
body.theme-tabler .empty {
  color: #9aa5b1;
  padding: 40px 20px;
  text-align: center;
}

/* 滚动条 - Tabler 风格 */
body.theme-tabler ::-webkit-scrollbar-thumb {
  background: #dee2e6;
  border-radius: 4px;
}
body.theme-tabler ::-webkit-scrollbar-thumb:hover {
  background: #adb5bd;
}

/* ============================================================
   Tabler 主题 - 侧边栏完整重写
   ============================================================ */
body.theme-tabler .sidebar {
  background: #fff;
  border-right: 1px solid #e9ecef;
  width: 260px;
  box-shadow: none;
}

/* Logo 区域 */
body.theme-tabler .sidebar .brand {
  padding: 20px 20px 16px;
  border-bottom: 1px solid #f1f3f5;
  gap: 12px;
}
body.theme-tabler .sidebar .brand .logo {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #206bc4;
  box-shadow: 0 2px 4px rgba(32,107,196,.2);
}
body.theme-tabler .sidebar .brand .name {
  font-size: 16px;
  font-weight: 600;
  color: #182433;
  letter-spacing: 0;
}
body.theme-tabler .sidebar .brand .sub {
  font-size: 12px;
  color: #9aa5b1;
  margin-top: 2px;
}

/* 菜单区域 */
body.theme-tabler .sidebar nav {
  padding: 12px;
}
body.theme-tabler .sidebar nav .group {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: #9aa5b1;
  padding: 16px 12px 6px;
}
body.theme-tabler .sidebar nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 6px;
  margin-bottom: 2px;
  color: #495057;
  font-size: 14px;
  transition: all .15s;
}
body.theme-tabler .sidebar nav a:hover {
  background: #f1f3f5;
  color: #182433;
}
body.theme-tabler .sidebar nav a.active {
  background: #e8f3ff;
  color: #206bc4;
  font-weight: 500;
}
body.theme-tabler .sidebar nav a .ico {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
body.theme-tabler .sidebar nav a .ico svg {
  width: 18px;
  height: 18px;
}

/* 底部区域 */
body.theme-tabler .sidebar .foot {
  padding: 16px 20px;
  border-top: 1px solid #f1f3f5;
  font-size: 12px;
  color: #9aa5b1;
}

/* 主题切换按钮 - Tabler 风格 */
body.theme-tabler .sidebar .theme-switcher-wrap {
  padding: 12px 16px;
  border-top: 1px solid #f1f3f5;
}
body.theme-tabler .sidebar .theme-switcher-wrap > div:first-child {
  color: #65717d;
  font-size: 12px;
  margin-bottom: 8px;
}
body.theme-tabler .theme-switcher {
  background: #f1f3f5;
  border-radius: 6px;
  padding: 3px;
  display: flex;
  gap: 2px;
}
body.theme-tabler .theme-switcher button {
  border: none;
  background: transparent;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 13px;
  cursor: pointer;
  color: #495057;
  transition: all .15s;
  flex: 1;
}
body.theme-tabler .theme-switcher button:hover {
  color: #182433;
}
body.theme-tabler .theme-switcher button.active {
  background: #fff;
  color: #206bc4;
  font-weight: 500;
  box-shadow: 0 1px 2px rgba(0,0,0,.08);
}

/* 修复：Tabler 主题下侧边栏分隔线颜色 */
body.theme-tabler .sidebar > div[style*="border-top"] {
  border-top-color: #f1f3f5 !important;
}
body.theme-tabler .sidebar > div[style*="border-top"] > div:first-child {
  color: #65717d !important;
}

/* ============================================================
   Tabler 主题 - 顶部横向导航布局
   ============================================================ */
body.theme-tabler .layout {
  flex-direction: column;
}

/* 侧边栏变成顶部栏 */
body.theme-tabler .sidebar {
  width: 100%;
  height: auto;
  flex-direction: row;
  align-items: center;
  border-right: none;
  border-bottom: 1px solid #e9ecef;
  box-shadow: 0 1px 2px rgba(0,0,0,.03);
}

/* Logo 区域 */
body.theme-tabler .sidebar .brand {
  border-bottom: none;
  padding: 12px 24px;
  border-right: 1px solid #f1f3f5;
  height: 60px;
}
body.theme-tabler .sidebar .brand .sub {
  display: none;
}

/* 菜单变成横向 */
body.theme-tabler .sidebar nav {
  display: flex;
  align-items: center;
  padding: 0 16px;
  flex: 1;
  height: 60px;
  overflow-x: auto;
}
body.theme-tabler .sidebar nav .group {
  display: none; /* 顶部导航不显示分组 */
}
body.theme-tabler .sidebar nav a {
  margin-bottom: 0;
  margin-right: 4px;
  padding: 8px 14px;
  white-space: nowrap;
}
body.theme-tabler .sidebar nav a.active {
  background: transparent;
  color: #206bc4;
  border-bottom: 2px solid #206bc4;
  border-radius: 0;
}
body.theme-tabler .sidebar nav a:hover {
  background: #f1f3f5;
}

/* 底部区域（版本号、主题切换）放到最右边 */
body.theme-tabler .sidebar .foot,
body.theme-tabler .sidebar > div[style*="border-top"] {
  display: none; /* 顶部导航不显示底部区域 */
}

/* 主区域占满全宽 */
body.theme-tabler .main {
  flex: 1;
  overflow-y: auto;
}

/* 内容区内边距 */
body.theme-tabler #content {
  padding: 24px 32px;
}

/* 顶部导航模式下，主题切换放到顶部栏右边 */
body.theme-tabler .topbar-right {
  margin-left: auto;
}
body.theme-tabler .topbar-right .theme-switcher {
  margin-right: 12px;
}

/* 顶部导航模式下，在 topbar 右侧加主题切换按钮组 */
body.theme-tabler .topbar-right::before {
  content: '';
  display: none;
}

/* 把原来侧边栏的主题切换按钮样式改成顶部栏风格 */
body.theme-tabler .sidebar > div[style*="padding:12px 16px"] {
  display: flex !important;
  align-items: center;
  border-top: none !important;
  padding: 0 16px 0 0 !important;
  height: 60px;
  margin-left: auto;
}
body.theme-tabler .sidebar > div[style*="padding:12px 16px"] > div:first-child {
  display: none;
}
body.theme-tabler .sidebar > div[style*="padding:12px 16px"] .theme-switcher {
  margin: 0;
}

/* ============================================================
   Tabler 主题 - 完整布局切换（确保整个界面完全变样）
   ============================================================ */

/* 重置：Tabler 主题下完全重置布局 */
body.theme-tabler .layout {
  display: flex !important;
  flex-direction: column !important;
  height: 100vh !important;
  overflow: hidden !important;
}

/* 原来的侧边栏变成顶部导航容器 */
body.theme-tabler .sidebar {
  display: flex !important;
  flex-direction: row !important;
  width: 100% !important;
  height: auto !important;
  min-height: 60px !important;
  max-height: 60px !important;
  flex-shrink: 0 !important;
  background: #fff !important;
  border-right: none !important;
  border-bottom: 1px solid #e9ecef !important;
  align-items: center !important;
}

/* Logo 区域 */
body.theme-tabler .sidebar .brand {
  display: flex !important;
  align-items: center !important;
  padding: 0 24px !important;
  height: 60px !important;
  border-bottom: none !important;
  border-right: 1px solid #f1f3f5 !important;
  flex-shrink: 0 !important;
}
body.theme-tabler .sidebar .brand .logo {
  width: 32px !important;
  height: 32px !important;
}
body.theme-tabler .sidebar .brand .sub {
  display: none !important;
}

/* 菜单区域 - 横向 */
body.theme-tabler .sidebar nav {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  flex: 1 !important;
  height: 60px !important;
  padding: 0 16px !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
}
body.theme-tabler .sidebar nav .group {
  display: none !important;
}
body.theme-tabler .sidebar nav a {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  padding: 0 14px !important;
  height: 60px !important;
  margin: 0 2px !important;
  border-radius: 0 !important;
  border-bottom: 2px solid transparent !important;
  white-space: nowrap !important;
}
body.theme-tabler .sidebar nav a.active {
  background: transparent !important;
  border-bottom-color: #206bc4 !important;
  color: #206bc4 !important;
}

/* 底部区域隐藏 */
body.theme-tabler .sidebar .foot {
  display: none !important;
}
body.theme-tabler .sidebar > div:last-child {
  display: flex !important;
  align-items: center !important;
  height: 60px !important;
  padding: 0 16px !important;
  border-top: none !important;
  border-left: 1px solid #f1f3f5 !important;
  margin-left: auto !important;
  flex-shrink: 0 !important;
}
body.theme-tabler .sidebar > div:last-child > div:first-child {
  display: none !important;
}

/* 主区域 */
body.theme-tabler .main {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 !important;
  min-height: 0 !important;
  overflow: hidden !important;
}
body.theme-tabler .topbar {
  height: 56px !important;
  flex-shrink: 0 !important;
}
body.theme-tabler #content {
  flex: 1 !important;
  overflow-y: auto !important;
  padding: 24px 32px !important;
}

/* ============================================================
   Tabler 主题 - 顶部导航优化（仿截图风格）
   ============================================================ */
body.theme-tabler .sidebar nav a {
  display: flex !important;
  flex-direction: row !important;
  align-items: center !important;
  gap: 8px !important;
  padding: 0 16px !important;
  height: 60px !important;
  margin: 0 2px !important;
  font-size: 14px !important;
  color: #495057 !important;
  border: none !important;
  border-bottom: 2px solid transparent !important;
  border-radius: 0 !important;
  transition: all .15s !important;
  position: relative !important;
}
body.theme-tabler .sidebar nav a:hover {
  background: transparent !important;
  color: #182433 !important;
}
body.theme-tabler .sidebar nav a.active {
  background: transparent !important;
  color: #206bc4 !important;
  font-weight: 500 !important;
  border-bottom-color: #206bc4 !important;
}
body.theme-tabler .sidebar nav a .ico {
  width: 18px !important;
  height: 18px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}
body.theme-tabler .sidebar nav a .ico svg {
  width: 18px !important;
  height: 18px !important;
}

