/* ============================================================
   综合导航站 - 透明玻璃化（Glassmorphism）样式
   前台 + 后台共用
   ============================================================ */

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

:root {
  --glass-bg: rgba(255, 255, 255, 0.08);
  --glass-border: rgba(255, 255, 255, 0.18);
  --glass-highlight: rgba(255, 255, 255, 0.25);
  --text-main: #f8fafc;
  --text-dim: rgba(248, 250, 252, 0.72);
  --accent: #8b5cf6;
  --radius: 20px;
}

html, body { min-height: 100%; }

body {
  font-family: "Microsoft YaHei", "PingFang SC", -apple-system, "Segoe UI", sans-serif;
  color: var(--text-main);
  background: linear-gradient(135deg, #1e1b4b 0%, #312e81 25%, #4c1d95 50%, #701a75 75%, #0f172a 100%);
  background-size: 400% 400%;
  animation: bgShift 22s ease infinite;
  overflow-x: hidden;
  position: relative;
}

@keyframes bgShift {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

/* ---------- 背景光斑 ---------- */
.orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(90px);
  opacity: .45;
  z-index: 0;
  pointer-events: none;
}
.orb-1 { width: 420px; height: 420px; background: #8b5cf6; top: -120px; left: -120px; }
.orb-2 { width: 380px; height: 380px; background: #06b6d4; bottom: -100px; right: -100px; }
.orb-3 { width: 260px; height: 260px; background: #ec4899; top: 42%; left: 62%; opacity: .3; }

/* ---------- 玻璃卡片通用 ---------- */
.glass {
  background: var(--glass-bg);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

/* ---------- 顶部导航 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 14px 28px;
  margin: 16px auto 0;
  max-width: 1200px;
  border-radius: 18px;
}
.topbar-row { display: flex; align-items: center; gap: 20px; width: 100%; }
.topbar-user { justify-content: flex-end; border-top: 1px solid rgba(255,255,255,.09); padding-top: 10px; }
.logo {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 23px;
  font-weight: 900;
  color: #7c2d12;
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 1px;
  background: linear-gradient(135deg, #fde047, #f59e0b);
  border: 2px solid #d97706;
  border-radius: 12px;
  padding: 8px 18px;
  box-shadow: 0 4px 14px rgba(245,158,11,.4);
  overflow: hidden;
  transition: transform .2s, box-shadow .2s;
}
.logo::after {
  content: "";
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(105deg, transparent, rgba(255,255,255,.65), transparent);
  transform: skewX(-20deg);
  animation: logoShine 2.6s ease-in-out infinite;
}
@keyframes logoShine {
  0% { left: -60%; }
  60%, 100% { left: 130%; }
}
.logo:hover { transform: translateY(-1px); box-shadow: 0 6px 18px rgba(245,158,11,.5); }
.menu { display: flex; gap: 4px; flex-wrap: wrap; }
.menu a, .user a {
  color: var(--text-main);
  text-decoration: none;
  padding: 8px 13px;
  border-radius: 10px;
  font-size: 14px;
  transition: background .2s, color .2s;
  white-space: nowrap;
}
.menu a:hover, .user a:hover { background: var(--glass-highlight); }
.user { margin-left: auto; display: flex; align-items: center; gap: 2px; flex-wrap: wrap; }
.user .uname { font-size: 13px; color: var(--text-dim); margin-right: 6px; }

/* ---------- 主容器 ---------- */
.wrap { max-width: 1200px; margin: 0 auto; padding: 26px 20px 60px; position: relative; z-index: 1; }

/* ---------- 首页 Hero ---------- */
.hero { text-align: center; padding: 70px 20px 46px; }
.hero h1 { font-size: 44px; font-weight: 800; letter-spacing: 1px; text-shadow: 0 4px 24px rgba(0,0,0,.35); }
.hero .sub { margin-top: 14px; font-size: 16px; color: var(--text-dim); }
.search {
  display: flex;
  gap: 10px;
  max-width: 560px;
  margin: 30px auto 0;
  padding: 10px;
  border-radius: 60px;
}
.search input {
  flex: 1;
  border: 0;
  outline: 0;
  background: transparent;
  color: #fff;
  font-size: 15px;
  padding: 8px 14px;
}
.search input::placeholder { color: rgba(255,255,255,.55); }
.search .btn-primary { border-radius: 40px; padding: 11px 28px; }

/* ---------- 区块 ---------- */
.block { margin-top: 40px; }
.block-title {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 18px;
  padding-left: 12px;
  border-left: 4px solid var(--accent);
}
.page-h1 { font-size: 26px; margin-bottom: 18px; }

/* ---------- 网格卡片 ---------- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
}
.card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 26px 22px;
  text-decoration: none;
  color: var(--text-main);
  transition: transform .22s, box-shadow .22s, border-color .22s;
}
.card:hover {
  transform: translateY(-5px);
  border-color: var(--glass-highlight);
  box-shadow: 0 16px 44px rgba(0, 0, 0, .35);
}

/* 分类卡片 */
.cat-card { align-items: center; text-align: center; padding: 32px 20px; }
.c-icon { font-size: 52px; line-height: 1; }
.cat-card:hover .c-icon { transform: scale(1.12) rotate(-4deg); }
.c-icon, .big-icon { display: inline-block; transition: transform .25s; }
.c-name { font-size: 19px; font-weight: 700; margin-top: 6px; }
.c-count { font-size: 13px; color: var(--text-dim); }

/* 内容卡片 */
.item-card { padding: 22px; }
.tag {
  align-self: flex-start;
  font-size: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), #6d28d9);
  padding: 4px 10px;
  border-radius: 20px;
}
.item-card h3 { font-size: 17px; font-weight: 700; margin-top: 4px; }
.item-card p { font-size: 13px; color: var(--text-dim); line-height: 1.6; }
.item-card .go { font-size: 13px; color: #c4b5fd; margin-top: auto; padding-top: 8px; }
.thumb { width: 100%; height: 120px; object-fit: cover; border-radius: 12px; }
.badge-corner {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, #ef4444, #b91c1c);
  padding: 3px 10px;
  border-radius: 20px;
  box-shadow: 0 2px 8px rgba(239, 68, 68, .35);
  z-index: 2;
}
.card { position: relative; }
.dl-btn {
  display: inline-block;
  margin-top: auto;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 700;
  align-self: flex-start;
}
.dl-btn.free { color: #064e3b; background: linear-gradient(135deg, #6ee7b7, #34d399); }
.dl-btn.coins { color: #451a03; background: linear-gradient(135deg, #fcd34d, #f59e0b); }
.dl-big { height: 160px; object-fit: contain; background: rgba(255,255,255,.9); }
.btn-big { font-size: 15px; padding: 12px 28px; border-radius: 24px; display: inline-block; }
.dl-box { margin-top: 14px; padding: 14px 16px; border: 1px dashed rgba(196,181,253,.5); border-radius: 12px; background: rgba(139,92,246,.08); }
.dl-label { font-size: 13px; color: var(--text-dim); }
.dl-url { font-family: Consolas, Menlo, monospace; font-size: 14px; color: #e9d5ff; word-break: break-all; margin: 6px 0 10px; }

.empty {
  padding: 30px;
  text-align: center;
  color: var(--text-dim);
  grid-column: 1 / -1;
}

/* ---------- 分类页头 ---------- */
.page-head {
  display: flex;
  align-items: center;
  gap: 22px;
  padding: 30px;
  margin-bottom: 30px;
}
.big-icon {
  font-size: 64px;
  width: 96px;
  height: 96px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 24px;
  background: linear-gradient(135deg, var(--accent, #8b5cf6), rgba(255,255,255,.12));
}
.ph-text h1 { font-size: 28px; }
.ph-text p { margin-top: 6px; color: var(--text-dim); }

/* ---------- 详情页 ---------- */
.detail { padding: 36px; max-width: 1000px; margin: 0 auto; }
.crumb { font-size: 13px; color: var(--text-dim); margin-bottom: 14px; }
.crumb a { color: #c4b5fd; text-decoration: none; }
.detail h1 { font-size: 28px; margin-bottom: 18px; }
.dimg { max-width: 100%; border-radius: 14px; margin-bottom: 18px; }
.desc { line-height: 1.9; color: #e2e8f0; margin-bottom: 22px; white-space: pre-wrap; }
/* 帖子详情论坛式两栏：左楼主卡 + 右正文 */
.post-wrap { display: flex; gap: 22px; align-items: flex-start; }
.post-user { flex: 0 0 180px; background: rgba(139,92,246,.10); border: 1px solid rgba(196,181,253,.30); border-radius: 14px; padding: 16px 14px; text-align: center; }
.post-avatar { width: 64px; height: 64px; border-radius: 50%; margin: 0 auto 10px; background: linear-gradient(135deg, #a78bfa, #7c3aed); color: #fff; font-size: 28px; font-weight: 700; display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 12px rgba(124,58,237,.35); }
.post-uname { font-weight: 700; color: #ddd6fe; font-size: 16px; margin-bottom: 6px; }
.post-tag { display: inline-block; font-size: 11px; color: #7c3aed; background: #ddd6fe; border-radius: 20px; padding: 2px 12px; margin-bottom: 12px; font-weight: 600; }
.post-meta { display: flex; flex-direction: column; gap: 6px; font-size: 12px; color: var(--text-dim); }
.post-main { flex: 1; min-width: 0; }
/* 详情图集：单列大图，点击可全屏放大 */
.gallery { display: flex; flex-direction: column; gap: 16px; margin-bottom: 24px; }
.gimg { width: 100%; max-width: 960px; border-radius: 12px; border: 1px solid rgba(255,255,255,.1); cursor: zoom-in; }
/* 图片全屏查看灯箱 */
#lb{display:none;position:fixed;inset:0;background:rgba(0,0,0,.92);z-index:9999;align-items:center;justify-content:center;cursor:zoom-out}
#lbImg{max-width:94vw;max-height:92vh;border-radius:10px}
#lbClose{position:fixed;top:16px;right:26px;color:#fff;font-size:40px;line-height:1;cursor:pointer;z-index:10000;font-weight:300}
/* 玩家留言 */
.comments { padding: 26px 28px; margin-top: 22px; max-width: 1000px; margin-left: auto; margin-right: auto; }
.comments .block-title { margin-bottom: 14px; }
/* 评论区：楼层竖排（一排竖下来） */
.cmt-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 18px; }
.cmt-floor { display: flex; gap: 14px; border: 1px solid rgba(255,255,255,.10); background: rgba(255,255,255,.06); border-radius: 14px; padding: 14px 16px; transition: border-color .2s; }
.cmt-floor:hover { border-color: rgba(196,181,253,.45); }
.cmt-side { flex: 0 0 120px; display: flex; flex-direction: column; align-items: center; gap: 3px; text-align: center; }
.cmt-avatar { width: 44px; height: 44px; border-radius: 50%; background: linear-gradient(135deg, #38bdf8, #6366f1); color: #fff; font-size: 20px; font-weight: 700; display: flex; align-items: center; justify-content: center; box-shadow: 0 3px 8px rgba(56,189,248,.28); }
.cmt-user { font-weight: 600; color: #ddd6fe; font-size: 14px; }
.cmt-lv { font-size: 11px; color: #fbbf24; }
.cmt-floor-no { font-size: 11px; color: var(--text-dim); font-family: Consolas, Menlo, monospace; }
.cmt-main { flex: 1; min-width: 0; }
.cmt-time { font-size: 12px; color: var(--text-dim); }
.cmt-del { font-size: 12px; color: #fda4af; text-decoration: none; margin-left: auto; }
.cmt-del:hover { text-decoration: underline; }
.cmt-body { line-height: 1.7; color: #e2e8f0; white-space: pre-wrap; word-break: break-word; margin-bottom: 8px; }
.cmt-foot2 { display: flex; align-items: center; gap: 12px; font-size: 12px; }
.cmt-empty { color: var(--text-dim); padding: 10px 0 16px; font-size: 14px; }
.cmt-login { color: var(--text-dim); padding: 6px 0 12px; font-size: 14px; }
.cmt-login a { color: #c4b5fd; }
.cmt-ban { color: #fbbf24; background: rgba(251,191,36,.08); border: 1px dashed rgba(251,191,36,.4); border-radius: 10px; padding: 10px 14px; font-size: 14px; }
.cmt-form { display: flex; flex-direction: column; gap: 10px; }
.cmt-form textarea {
  width: 100%; padding: 12px 14px; border: 1px solid var(--glass-border); border-radius: 12px;
  background: rgba(255,255,255,.1); color: #fff; font-size: 14px; outline: none;
  font-family: inherit; resize: vertical; line-height: 1.6; box-sizing: border-box;
}
.cmt-form textarea:focus { border-color: var(--accent); background: rgba(255,255,255,.16); }
.cmt-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.cmt-tip { font-size: 12px; color: var(--text-dim); }
/* 窄屏适配 */
@media (max-width: 760px) {
  .post-wrap { flex-direction: column; }
  .post-user { flex: none; width: 100%; display: flex; align-items: center; gap: 12px; text-align: left; }
  .post-avatar { margin: 0; width: 48px; height: 48px; font-size: 22px; }
  .post-meta { flex-direction: row; gap: 10px; }
  .cmt-floor { flex-direction: column; }
  .cmt-side { flex: none; flex-direction: row; align-items: center; gap: 8px; width: 100%; }
}
.dl-foot { margin-top: 26px; padding: 20px 22px; border: 1px solid rgba(196,181,253,.35); border-radius: 16px; background: rgba(139,92,246,.08); }
.dl-title { font-size: 15px; font-weight: 700; color: #e9d5ff; margin-bottom: 6px; }
.dl-price { font-size: 16px; margin: 4px 0 8px; }
.dl-price b { color: #fcd34d; font-size: 18px; }
.dl-url { font-family: Consolas, Menlo, monospace; font-size: 14px; color: #e9d5ff; word-break: break-all; margin: 8px 0 12px; }
.img-list { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.img-list img { width: 80px; height: 80px; object-fit: cover; border-radius: 8px; border: 1px solid rgba(255,255,255,.15); }

/* ---------- 按钮 ---------- */
.btn-primary {
  display: inline-block;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  color: #fff;
  background: linear-gradient(135deg, #8b5cf6, #6d28d9);
  padding: 12px 26px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  transition: opacity .2s, transform .2s;
}
.btn-primary:hover { opacity: .9; transform: translateY(-1px); }
.btn-sm { padding: 7px 15px; font-size: 13px; border-radius: 9px; }
.btn-ghost {
  display: inline-block;
  text-decoration: none;
  color: var(--text-main);
  padding: 12px 22px;
  border-radius: 12px;
  border: 1px solid var(--glass-border);
  font-size: 14px;
}

/* ---------- 表单（登录/注册等） ---------- */
.auth { max-width: 430px; margin: 40px auto; padding: 34px 36px; }
.auth h1 { font-size: 24px; margin-bottom: 20px; text-align: center; }
.auth form, .form-card form { display: flex; flex-direction: column; gap: 6px; }
label { font-size: 14px; color: var(--text-dim); display: block; margin-bottom: 12px; }
label input, label select, label textarea {
  display: block;
  width: 100%;
  margin-top: 7px;
  padding: 11px 13px;
  border: 1px solid var(--glass-border);
  border-radius: 11px;
  background: rgba(255,255,255,.12);
  color: #fff;
  font-size: 14px;
  outline: none;
  font-family: inherit;
}
label input:focus, label select:focus, label textarea:focus {
  border-color: var(--accent);
  background: rgba(255,255,255,.18);
}
label input::placeholder { color: rgba(255,255,255,.45); }
label select option { color: #1e293b; }
label textarea { resize: vertical; line-height: 1.6; }
label.check {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}
label.check input { width: auto; margin: 0; }
.auth button { margin-top: 10px; }
.auth .tip, .tip { margin-top: 16px; font-size: 13px; color: var(--text-dim); }
.tip a { color: #c4b5fd; text-decoration: none; }
.q {
  font-size: 16px;
  font-weight: 700;
  color: #fde68a;
  background: rgba(255,255,255,.1);
  padding: 12px 14px;
  border-radius: 10px;
  margin: 10px 0 18px;
}

.err {
  background: rgba(239, 68, 68, .16);
  border: 1px solid rgba(248, 113, 113, .4);
  color: #fecaca;
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 14px;
  margin-bottom: 14px;
  line-height: 1.6;
  word-break: break-all;
}
.ok {
  background: rgba(16, 185, 129, .16);
  border: 1px solid rgba(52, 211, 153, .4);
  color: #a7f3d0;
  border-radius: 10px;
  padding: 11px 14px;
  font-size: 14px;
  margin-bottom: 14px;
  line-height: 1.6;
}

/* ---------- 提示条 ---------- */
.toast {
  position: fixed;
  top: 90px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 99;
  padding: 12px 26px;
  font-size: 14px;
  border-radius: 40px;
  background: rgba(15, 23, 42, .72);
  box-shadow: 0 10px 30px rgba(0,0,0,.35);
}

/* ---------- 页脚 ---------- */
.footer {
  max-width: 1200px;
  margin: 10px auto 24px;
  padding: 18px;
  text-align: center;
  font-size: 13px;
  color: var(--text-dim);
  position: relative;
  z-index: 1;
}

/* ============================================================
   后台样式
   ============================================================ */
.admin-body { padding-bottom: 30px; }
.admin-layout { display: flex; gap: 20px; max-width: 1400px; margin: 16px auto 0; padding: 0 20px; position: relative; z-index: 1; align-items: flex-start; }

.sidebar {
  width: 230px;
  flex-shrink: 0;
  position: sticky;
  top: 16px;
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.sidebar .logo { font-size: 16px; padding: 6px 10px 16px; border-bottom: 1px solid var(--glass-border); margin-bottom: 6px; }
.sidebar nav { display: flex; flex-direction: column; gap: 4px; }
.sidebar nav a {
  color: var(--text-main);
  text-decoration: none;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 14px;
  transition: background .2s;
}
.sidebar nav a:hover { background: var(--glass-highlight); }
.side-user { margin-top: auto; padding-top: 14px; font-size: 12px; color: var(--text-dim); border-top: 1px solid var(--glass-border); }

.admin-main { flex: 1; min-width: 0; }
.admin-main h1 { font-size: 24px; margin-bottom: 20px; }

.toolbar { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.inline-form { display: inline-flex; }
.inline-form select {
  padding: 9px 12px;
  border: 1px solid var(--glass-border);
  border-radius: 10px;
  background: rgba(255,255,255,.12);
  color: #fff;
  font-size: 14px;
  outline: none;
}
.inline-form select option { color: #1e293b; }

/* 统计卡片 */
.stats { grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); margin-bottom: 30px; }
.stat { text-align: center; padding: 26px 16px; }
.stat b { display: block; font-size: 34px; font-weight: 800; color: #fff; }
.stat span { font-size: 13px; color: var(--text-dim); }

/* 表格 */
.table { width: 100%; border-collapse: collapse; overflow: hidden; font-size: 14px; }
.table th, .table td { padding: 12px 14px; text-align: left; border-bottom: 1px solid rgba(255,255,255,.09); }
.table th { background: rgba(255,255,255,.06); color: #e9d5ff; font-weight: 600; white-space: nowrap; }
.table tr:hover td { background: rgba(255,255,255,.05); }
.table .c-icon { font-size: 22px; }
.table .dot { display: inline-block; width: 14px; height: 14px; border-radius: 50%; margin-right: 8px; vertical-align: -2px; }
.table .td-url { color: var(--text-dim); font-size: 13px; word-break: break-all; }
.table .td-desc { color: var(--text-dim); font-size: 13px; max-width: 180px; }
.table .ops a { color: #c4b5fd; text-decoration: none; margin-right: 10px; white-space: nowrap; }
.table .ops a:hover { text-decoration: underline; }
.empty-td { text-align: center; color: var(--text-dim); padding: 30px !important; }

/* 表单卡片（后台） */
.form-card { max-width: 640px; padding: 28px 30px; }
.form-card label { margin-bottom: 16px; }
.color-readonly { max-width: 130px; }
.quick p { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- 卡片商城 ---------- */
.card-shop { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 10px; padding: 26px 20px; }
.card-shop h3 { font-size: 20px; }
.card-shop .price { font-size: 30px; font-weight: 800; color: var(--accent, #ec4899); margin: 2px 0; }
.card-shop .price::first-letter { font-size: 22px; }
.card-shop .hint { font-size: 12px; color: var(--text-dim); }
.btn-buy { width: 100%; text-align: center; }

/* 订单确认 / 购买成功 */
.order-confirm { text-align: center; padding: 10px 0 6px; }
.order-confirm .oc-name { font-size: 22px; font-weight: 700; }
.order-confirm .oc-price { font-size: 26px; font-weight: 800; color: #f0abfc; margin: 6px 0; }
.order-confirm .oc-price b { color: #f9a8d4; }
.order-confirm .oc-tip { font-size: 13px; color: var(--text-dim); margin-top: 8px; }
.success-box { text-align: center; }
.order-detail { margin: 14px 0; display: flex; flex-direction: column; gap: 6px; }
.key-label { margin: 16px 0 8px; color: var(--text-dim); font-size: 14px; }
.key-box {
  display: flex; align-items: center; justify-content: center; gap: 14px; flex-wrap: wrap;
  background: rgba(255,255,255,.08); border: 1px dashed rgba(255,255,255,.4);
  border-radius: 14px; padding: 16px 18px; margin-bottom: 10px;
}
.key-text { font-family: Consolas, Menlo, monospace; font-size: 24px; font-weight: 700; letter-spacing: 1.5px; color: #fde68a; word-break: break-all; }
.key-warn { font-size: 12px; color: var(--text-dim); margin-bottom: 16px; }
.copy-btn { cursor: pointer; }
.tips { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 8px; }
.btn-ghost {
  display: inline-block; padding: 10px 20px; border-radius: 10px; text-decoration: none;
  color: var(--text); background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.25);
}
.btn-ghost:hover { background: rgba(255,255,255,.14); }
.key-cell code { font-family: Consolas, Menlo, monospace; background: rgba(255,255,255,.07); padding: 3px 8px; border-radius: 6px; letter-spacing: .5px; }
.page-h1 { margin-bottom: 18px; }
.stat-inline { display: inline-block; padding: 8px 16px; border-radius: 10px; font-size: 13px; }
.stat-inline b { color: #f9a8d4; }
.stat-inline.active { background: rgba(139,92,246,.28); color: #ede9fe; }

/* ---------- 金币 / 充值 ---------- */
.coin-badge {
  display: inline-block; padding: 4px 12px; border-radius: 999px;
  background: rgba(245,158,11,.18); border: 1px solid rgba(245,158,11,.45);
  color: #fcd34d; font-size: 13px; font-weight: 600; white-space: nowrap;
}
.perm-badge {
  display: inline-block; padding: 4px 12px; border-radius: 999px;
  background: rgba(139,92,246,.2); border: 1px solid rgba(139,92,246,.55);
  color: #ddd6fe; font-size: 13px; font-weight: 600; white-space: nowrap;
}
.reg-badge {
  display: inline-block; padding: 4px 12px; border-radius: 999px;
  background: rgba(34,211,238,.12); border: 1px solid rgba(34,211,238,.4);
  color: #a5f3fc; font-size: 13px; font-weight: 600; white-space: nowrap;
}
.oc-warn { font-size: 13px; color: #fca5a5; margin-top: 10px; }
.oc-warn.ok { color: #86efac; }
.oc-stock { font-size: 13px; color: var(--text-dim); margin-top: 8px; }
.oc-stock b { color: #c4b5fd; }
.oc-stock.bad b { color: #f87171; }
.oc-block { margin-top: 10px; padding: 10px 12px; border: 1px solid rgba(248,113,113,.4); background: rgba(248,113,113,.1); border-radius: 10px; color: #fecaca; font-size: 13px; line-height: 1.7; }
.recharge-box { max-width: 620px; }
.recharge-rule { margin: 4px 0 14px; color: var(--text-dim); font-size: 14px; }
.recharge-rule b { color: #fcd34d; }
.recharge-notice { background: rgba(251,191,36,.1); border: 1px solid rgba(251,191,36,.3); color: #fde68a; padding: 10px 14px; border-radius: 10px; font-size: 13px; margin-bottom: 16px; }
.qr-row { display: flex; gap: 18px; justify-content: center; flex-wrap: wrap; margin: 16px 0; }
.qr-item { text-align: center; }
.qr-item h3 { font-size: 15px; margin-bottom: 10px; }
.qr-img { width: 210px; height: 210px; object-fit: contain; background: #fff; padding: 8px; border-radius: 12px; box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.qr-empty {
  width: 210px; height: 210px; display: flex; align-items: center; justify-content: center;
  border: 1px dashed rgba(255,255,255,.3); border-radius: 12px; color: var(--text-dim);
  font-size: 13px; line-height: 1.9; background: rgba(255,255,255,.03);
}
.qr-preview { width: 120px; height: 120px; object-fit: contain; background: #fff; padding: 6px; border-radius: 8px; display: block; margin: 6px 0; }
.qr-none { color: var(--text-dim); font-size: 13px; margin-right: 8px; }
.qr-set { display: flex; flex-wrap: wrap; gap: 18px; }
.qr-set .qr-col { flex: 0 0 240px; display: flex; flex-direction: column; gap: 6px; font-size: 13px; }
.qr-set .qr-col b { color: #e9d5ff; }
.qr-set .qr-wide { flex: 1 1 320px; }
.qr-set input[type="file"] { font-size: 12px; }
.recharge-form { margin-top: 10px; }
.recharge-form .qr-tip-label { font-size: 13px; color: var(--text-dim); }
.amount-tabs { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0 10px; }
.amount-tab {
  padding: 8px 16px; border-radius: 10px; border: 1px solid rgba(255,255,255,.22);
  background: rgba(255,255,255,.06); color: var(--text); cursor: pointer; font-size: 14px;
}
.amount-tab:hover { background: rgba(255,255,255,.14); }
.amount-tab.active { background: linear-gradient(135deg, #8b5cf6, #6d28d9); border-color: transparent; color: #fff; }
.badge { display: inline-block; padding: 3px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; }
.badge-pending { background: rgba(245,158,11,.2); color: #fcd34d; border: 1px solid rgba(245,158,11,.4); }
.badge-ok { background: rgba(16,185,129,.2); color: #6ee7b7; border: 1px solid rgba(16,185,129,.4); }
.badge-no { background: rgba(239,68,68,.18); color: #fca5a5; border: 1px solid rgba(239,68,68,.4); }
.recharge-entry {
  display: flex; align-items: center; gap: 14px; text-decoration: none;
  padding: 16px 20px; border-radius: 14px; margin-bottom: 4px;
}
.re-icon { font-size: 34px; }
.re-text { flex: 1; color: var(--text); line-height: 1.6; }
.re-text b { font-size: 16px; }
.recharge-entry .go { color: #c4b5fd; font-size: 14px; }
.form-sec { font-size: 16px; margin: 6px 0 14px; color: #fcd34d; }

/* ---------- 论坛式：板块导航 / 帖子列表 ---------- */
.board-grid { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.board-card {
  display: flex; align-items: flex-start; gap: 14px; padding: 18px 20px;
  text-decoration: none; border-top: 3px solid var(--bd, #8b5cf6);
  transition: transform .18s ease, box-shadow .18s ease;
}
.board-card:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(0,0,0,.28); }
.bd-icon { font-size: 34px; line-height: 1.2; }
.bd-text { flex: 1; min-width: 0; }
.bd-text h3 { font-size: 17px; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
.bd-count {
  display: inline-block; min-width: 20px; padding: 1px 7px; text-align: center;
  border-radius: 999px; font-size: 12px; background: var(--bd, #8b5cf6); color: #fff;
}
.bd-text p { color: var(--text-dim); font-size: 13px; line-height: 1.6; margin-bottom: 6px; }
.bd-last { font-size: 12px; color: var(--text-dim); }
.list-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.list-total { font-size: 13px; color: var(--text-dim); }
.post-list { padding: 0 8px; overflow: hidden; }
.post-row {
  display: flex; align-items: center; gap: 16px; padding: 13px 14px;
  border-bottom: 1px solid rgba(255,255,255,.07); text-decoration: none; color: var(--text);
}
.post-row:last-child { border-bottom: none; }
.post-row:hover { background: rgba(139,92,246,.08); }
.post-main { flex: 1; min-width: 0; }
.post-main h3 { font-size: 15px; font-weight: 600; margin-bottom: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.post-main h3:hover { color: #c4b5fd; }
.post-main p { font-size: 12px; color: var(--text-dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.post-badge {
  display: inline-block; padding: 1px 8px; margin-right: 6px; border-radius: 999px;
  font-size: 11px; font-weight: 600; background: linear-gradient(135deg, #f59e0b, #ef4444); color: #fff;
  vertical-align: 1px;
}
.post-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 2px; flex: 0 0 auto; }
.pm-views { font-size: 12px; color: var(--text-dim); }
.pm-time { font-size: 12px; color: var(--text-dim); }
.pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 16px; }
.pager-now { font-size: 13px; color: var(--text-dim); }

/* 后台分类层级 */
.row-sub { background: rgba(139,92,246,.06); }
.row-top { font-weight: 600; }
.sub-badge {
  display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: 999px;
  font-size: 11px; background: rgba(139,92,246,.2); color: #c4b5fd;
}

/* 详情页增强 */
.btn-copy {
  margin-left: 10px; padding: 4px 12px; font-size: 12px; vertical-align: 2px;
  border: 1px solid rgba(196,181,253,.4); border-radius: 999px; background: transparent;
  color: #c4b5fd; cursor: pointer;
}
.btn-copy:hover { background: rgba(139,92,246,.2); }
.item-stats { font-size: 13px; color: var(--text-dim); margin: -8px 0 16px; }
.item-qr {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  margin: 0 auto 24px; padding: 12px; width: 160px;
  border: 1px solid rgba(255,255,255,.12); border-radius: 12px; background: rgba(255,255,255,.03);
}
.item-qr img { width: 130px; height: 130px; object-fit: contain; background: #fff; border-radius: 8px; }
.item-qr span { font-size: 12px; color: var(--text-dim); }

/* ---------- 响应式 ---------- */
@media (max-width: 860px) {
  .topbar { flex-wrap: wrap; padding: 12px 16px; gap: 10px; }
  .user { margin-left: 0; width: 100%; justify-content: flex-start; }
  .hero h1 { font-size: 30px; }
  .admin-layout { flex-direction: column; }
  .sidebar { width: 100%; position: static; }
  .sidebar nav { flex-direction: row; flex-wrap: wrap; }
  .sidebar nav a { padding: 8px 12px; font-size: 13px; }
  .side-user { display: none; }
  .table { font-size: 13px; }
  .table th, .table td { padding: 9px 8px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
}

/* ===== 公司板块：设备台账表格 & PDF 图册 ===== */
.table-wrap { overflow-x: auto; border-radius: 14px; }
.data-table { width: 100%; border-collapse: collapse; font-size: 14px; table-layout: fixed; }
.data-table th, .data-table td { padding: 9px 10px; text-align: left; border-bottom: 1px solid rgba(139,92,246,.14); border-right: 1px solid rgba(139,92,246,.08); vertical-align: top; word-break: break-all; }
.data-table th:last-child, .data-table td:last-child { border-right: none; }
.data-table thead th { background: rgba(139,92,246,.10); color: var(--accent, #8b5cf6); font-weight: 600; white-space: nowrap; text-align: center; }
.data-table thead th:first-child { width: 48px; }
.data-table tbody tr:nth-child(even) { background: rgba(139,92,246,.04); }
.data-table tbody tr:hover { background: rgba(139,92,246,.09); }
.data-table tbody td:first-child { text-align: center; color: #64748b; font-weight: 600; }
.data-table td:nth-child(2) { font-weight: 600; color: #1e293b; }
.data-table .empty-td { text-align: center; color: #94a3b8; padding: 20px 0; }
.year-head { margin: 26px 0 4px; font-size: 18px; color: var(--accent, #8b5cf6); padding: 10px 14px; background: rgba(139,92,246,.08); border-radius: 12px; border-left: 4px solid #8b5cf6; }
.year-head.empty { opacity: .6; }
.month-head { margin: 16px 0 8px; font-size: 15px; color: #475569; padding-left: 4px; border-left: 3px solid rgba(139,92,246,.5); padding-left: 10px; }
.month-head.empty { color: #94a3b8; border-left-color: rgba(148,163,184,.5); }
.month-head .mh-cnt { font-size: 12px; color: #8b5cf6; background: rgba(139,92,246,.1); padding: 2px 8px; border-radius: 20px; margin-left: 4px; }
/* 公司板块三级导航：年份卡片 / 月份列表 / 返回链接 */
.year-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; margin-top: 6px; }
.year-card { align-items: center; text-align: center; padding: 30px 20px 24px; gap: 10px; }
.year-card.empty { grid-column: auto; opacity: .62; padding: 30px 20px 24px; }
.year-icon { font-size: 46px; line-height: 1; display: inline-block; transition: transform .25s; }
.year-card:hover .year-icon { transform: scale(1.12) rotate(-4deg); }
.year-text { display: flex; flex-direction: column; align-items: center; gap: 4px; width: 100%; }
.year-text h3 { margin: 4px 0 0; font-size: 18px; font-weight: 700; color: #1e293b; letter-spacing: .5px; }
.year-cnt { font-size: 13px; color: #94a3b8; }
.year-card .go { font-size: 13px; font-weight: 600; color: #8b5cf6; background: rgba(139,92,246,.10); padding: 6px 18px; border-radius: 20px; margin-top: 6px; }
.year-card.empty .go { color: #94a3b8; background: rgba(148,163,184,.10); }
.month-list { border-radius: 16px; overflow: hidden; margin-top: 6px; }
.month-row { display: flex; align-items: center; gap: 14px; padding: 15px 18px; border-bottom: 1px solid rgba(139,92,246,.10); text-decoration: none; text-align: left; }
.month-row:last-child { border-bottom: none; }
.month-row:hover { background: rgba(139,92,246,.08); }
.month-row.empty { opacity: .55; padding: 15px 18px; }
.mr-icon { font-size: 24px; line-height: 1; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; background: rgba(139,92,246,.10); border-radius: 12px; flex-shrink: 0; }
.mr-main { flex: 1; min-width: 0; }
.mr-main h3 { margin: 0 0 3px; font-size: 15px; font-weight: 700; color: #1e293b; }
.mr-main p { margin: 0; font-size: 12.5px; color: #94a3b8; }
.mr-cnt { font-size: 12.5px; font-weight: 600; color: #8b5cf6; background: rgba(139,92,246,.12); padding: 4px 12px; border-radius: 20px; white-space: nowrap; }
.month-row.empty .mr-cnt { color: #94a3b8; background: rgba(148,163,184,.12); }
.sub-back { color: #8b5cf6; text-decoration: none; font-size: 14px; margin-right: 10px; font-weight: 600; }
.sub-back:hover { text-decoration: underline; }
.pdf-card { text-align: left; }
.pdf-card .pdf-icon { display: block; line-height: 0; }
.pdf-card .pdf-icon .pdf-thumb {
  width: 96px; height: 72px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,.25);
  background: #fff;
  box-shadow: 0 3px 10px rgba(15,23,42,.18);
}
.pdf-card h3 { font-size: 15px; }
.pdf-card .pdf-meta { margin: 3px 0; font-size: 13px; color: #475569; }
.pdf-card .pdf-meta b { color: #8b5cf6; font-weight: 600; }
.pdf-card .btn-primary { margin-top: 10px; }
.form-hint { grid-column: 1 / -1; font-size: 12px; color: #94a3b8; margin: 0; }
.progress-track { width: 100%; height: 14px; border-radius: 20px; background: rgba(139,92,246,.12); overflow: hidden; }
.progress-bar { height: 100%; width: 0%; border-radius: 20px; background: linear-gradient(90deg, #8b5cf6, #a78bfa); transition: width .2s; }
.progress-text { font-size: 12px; color: #8b5cf6; margin-top: 6px; }

/* ===== 后台：公司板块管理 ===== */
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; }
.form-grid label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; color: #64748b; }
.form-grid input, .form-grid select { padding: 9px 12px; border-radius: 10px; border: 1px solid rgba(139,92,246,.25); background: rgba(255,255,255,.75); color: #1e293b; font-size: 14px; }
.form-grid input:focus, .form-grid select:focus { outline: none; border-color: #8b5cf6; }
.form-grid .btn-primary { margin-top: 22px; align-self: end; }
.msg-err { background: rgba(239,68,68,.1); border: 1px solid rgba(239,68,68,.3); color: #dc2626; padding: 10px 14px; border-radius: 10px; margin-bottom: 14px; }
.msg-ok { background: rgba(16,185,129,.1); border: 1px solid rgba(16,185,129,.3); color: #059669; padding: 10px 14px; border-radius: 10px; margin-bottom: 14px; }
.company-admin-grid { margin-top: 16px; }
.admin-card { text-align: center; padding: 26px 18px; }
.admin-card .ac-icon { font-size: 38px; }
.admin-card h3 { margin: 8px 0 6px; font-size: 17px; }
.admin-card p { color: #64748b; font-size: 13px; min-height: 36px; }
.admin-card .go { display: inline-block; margin-top: 10px; font-size: 13px; }

/* ===== 头像系统（顶栏 / 个人中心 / 评论区楼层）===== */
.top-avatar { width: 30px; height: 30px; border-radius: 50%; object-fit: cover; border: 2px solid rgba(196,181,253,.55); vertical-align: middle; margin-right: 2px; display: inline-block; }
.top-avatar.txt { display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #a78bfa, #7c3aed); color: #fff; font-size: 14px; font-weight: 700; line-height: 1; }
.avatar-box { text-align: center; margin-bottom: 18px; }
.profile-avatar { width: 88px; height: 88px; border-radius: 50%; object-fit: cover; border: 3px solid rgba(196,181,253,.6); box-shadow: 0 6px 18px rgba(124,58,237,.35); }
.profile-avatar.txt { display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #a78bfa, #7c3aed); color: #fff; font-size: 38px; font-weight: 700; }
.avatar-name { margin: 10px 0 2px; font-size: 17px; font-weight: 700; color: #e2e8f0; }
.avatar-sub { margin: 0 0 4px; font-size: 13px; color: var(--text-dim); }
.avatar-form { display: flex; flex-direction: column; gap: 10px; margin-bottom: 6px; }
.avatar-form label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--text-dim); }
.avatar-form input[type="file"] { padding: 8px 10px; border: 1px dashed rgba(196,181,253,.45); border-radius: 10px; background: rgba(255,255,255,.08); color: #e2e8f0; font-size: 13px; }
.divider { border: none; border-top: 1px solid rgba(255,255,255,.12); margin: 20px 0 4px; }
.sub-h2 { font-size: 18px; margin: 16px 0 10px; color: #e9d5ff; }
/* 评论区楼层头像（图片版） */
.cmt-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; background: linear-gradient(135deg, #38bdf8, #6366f1); color: #fff; font-size: 20px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; box-shadow: 0 3px 8px rgba(56,189,248,.28); }
/* 记录删除按钮（购买/充值记录） */
.ops-del { font-size: 12px; color: #fda4af; text-decoration: none; margin-left: 10px; }
.ops-del:hover { text-decoration: underline; color: #f87171; }

/* 管理员快捷编辑按钮（前台标题旁） */
.admin-edit { font-size: 13px; font-weight: 400; color: #a78bfa; text-decoration: none; margin-left: 10px; vertical-align: middle; background: rgba(139,92,246,.12); padding: 3px 10px; border-radius: 8px; white-space: nowrap; }
.admin-edit:hover { background: rgba(139,92,246,.28); color: #ddd6fe; }
