/* ==========================================================================
   学习型社群平台 · 设计体系
   一套响应式样式：≤900px 手机（底部导航），>900px 电脑（左侧导航）
   ========================================================================== */

/* ---- 品牌字体 Noto Sans SC（按应用实际内容提取的 woff2 子集，重生成见 scripts/build-font-subsets.py）
   字重只有 400/500/700 三档：CSS 里的 600/650 按就近规则落到 700，与原系统粗体渲染一致 */
@font-face {
  font-family: "Noto Sans SC";
  src: url("/fonts/NotoSansSC-400.subset.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Noto Sans SC";
  src: url("/fonts/NotoSansSC-500.subset.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Noto Sans SC";
  src: url("/fonts/NotoSansSC-700.subset.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --brand: #0052d9;
  --brand-600: #0b3fa8;
  --brand-100: #e8f0ff;
  --brand-50: #f2f7ff;
  --green: #0aa17a;
  --green-100: #e6f6f0;
  --orange: #e08a00;
  --orange-100: #fff4e0;
  --red: #d93026;
  --red-100: #fdeceb;
  --purple: #7b5cf0;
  --bg: #f5f7fa;
  --card: #ffffff;
  --ink: #1d2129;
  --ink-2: #4e5969;
  --ink-3: #86909c;
  --ink-4: #a9b0bb;
  --line: #e5e6eb;
  --line-2: #f0f1f3;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(29, 33, 41, .05), 0 4px 16px rgba(29, 33, 41, .05);
  --shadow-lg: 0 12px 40px rgba(29, 33, 41, .16);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --nav-h: 56px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body { margin: 0; padding: 0; }
body {
  background-color: var(--bg);
  background-image: linear-gradient(180deg, rgba(0, 82, 217, .05), rgba(0, 82, 217, 0) 340px);
  background-attachment: fixed;
  color: var(--ink);
  font: 15px/1.65 "Noto Sans SC", -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Hiragino Sans GB", "Source Han Sans SC", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
a { color: var(--brand); text-decoration: none; }
img { max-width: 100%; display: block; }
button, input, textarea, select { font: inherit; color: inherit; }
::selection { background: var(--brand-100); }

/* ------------------------------------------------------------- 布局骨架 */
.app { min-height: 100vh; }
.boot { height: 100vh; display: grid; place-content: center; gap: 14px; justify-items: center; }
.boot-logo { width: 54px; height: 54px; display: grid; place-content: center; }
.boot-logo img { width: 54px; height: 54px; object-fit: contain; }
.boot-logo:not(:has(img)) { border-radius: 16px; background: var(--brand); color: #fff; font-size: 24px; font-weight: 700; }
.boot-text { color: var(--ink-3); font-size: 13px; }

.shell { display: flex; min-height: 100vh; }
.side {
  display: none;
  width: 232px; flex: none; background: var(--card); border-right: 1px solid var(--line);
  padding: 18px 12px; position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.view { padding: 14px 14px calc(var(--nav-h) + 22px + var(--safe-bottom)); max-width: 920px; width: 100%; margin: 0 auto; }
.view.wide { max-width: 1180px; }
.view.full { max-width: none; }   /* 智跃智库：占满宽度，分类树贴最左 */
.page-banner { height: 210px; border-radius: 16px; margin-bottom: 12px; background-size: 100% 100%, cover; background-position: center, center; background-repeat: no-repeat; }
.view.full .page-banner { border-radius: 0; margin: -14px -14px 12px; height: 200px; }

.topbar {
  position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, .92);
  backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--line);
  padding: 10px 14px; display: flex; align-items: center; gap: 10px; min-height: 52px;
}
.topbar h1 { font-size: 16px; margin: 0; font-weight: 650; letter-spacing: -.2px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar .sub { font-size: 12px; color: var(--ink-3); font-weight: 400; }
.icon-btn {
  width: 36px; height: 36px; border-radius: 10px; border: 1px solid transparent; background: transparent;
  display: grid; place-content: center; cursor: pointer; color: var(--ink-2); flex: none; position: relative; font-size: 17px;
}
.icon-btn:active { background: var(--line-2); }
.icon-btn:hover { background: var(--line-2); }
.badge-dot { position: absolute; top: 5px; right: 5px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--red); color: #fff; font-size: 10px; line-height: 16px; text-align: center; border: 2px solid #fff; }

.tabbar {
  position: fixed; bottom: 0; left: 0; right: 0; z-index: 40; height: calc(var(--nav-h) + var(--safe-bottom));
  padding-bottom: var(--safe-bottom); background: rgba(255, 255, 255, .96); backdrop-filter: blur(12px);
  border-top: 1px solid var(--line); display: flex;
}
.tabbar a { flex: 1; display: grid; place-content: center; gap: 1px; color: var(--ink-3); font-size: 11px; position: relative; }
.tabbar a .ic { font-size: 19px; line-height: 1.1; }
/* 当前圈子入口：用首字方块代替 emoji（emoji 在部分安卓字体里会渲染成怪异图形） */
.tab-ic { width: 21px; height: 21px; border-radius: 7px; background: var(--brand-100); color: var(--brand); font-size: 12px; font-weight: 700; display: grid; place-content: center; line-height: 1; flex: none; }
.tabbar a .tab-ic { margin: 0 auto 1px; }
.side-nav a .tab-ic { width: 19px; height: 19px; font-size: 11px; }
.tabbar a.on .tab-ic { background: var(--brand); color: #fff; }
.tabbar a.on { color: var(--brand); font-weight: 600; }
.tabbar a .dot { position: absolute; top: 6px; left: 50%; margin-left: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--red); }
/* 底部中间的「＋发布」浮起圆钮（移动端专属） */
.tabbar-plus { flex: 1; border: 0; background: none; display: grid; place-content: center; cursor: pointer; padding: 0; }
.tabbar-plus .plus { width: 46px; height: 46px; border-radius: 50%; background: var(--brand); color: #fff; font-size: 25px; line-height: 1; display: grid; place-content: center; margin-top: -22px; box-shadow: 0 4px 12px rgba(0, 82, 217, .38); }
.tabbar-plus:active .plus { transform: scale(.93); }

.side-brand { display: flex; align-items: center; gap: 9px; padding: 6px 10px 16px; }
.side-brand .lg { width: 30px; height: 30px; border-radius: 9px; background: var(--brand); color: #fff; display: grid; place-content: center; font-weight: 700; }
.side-brand b { font-size: 14.5px; }
.side-brand-img { height: 30px; width: auto; max-width: 100%; display: block; }
.side-nav { display: flex; flex-direction: column; gap: 2px; }
.side-nav a { display: flex; align-items: center; gap: 10px; padding: 9px 11px; border-radius: 9px; color: var(--ink-2); font-size: 14px; }
.side-nav a:hover { background: var(--line-2); }
.side-nav a.on { background: var(--brand-100); color: var(--brand); font-weight: 600; }
.side-nav a .ic { width: 19px; text-align: center; }
.side-nav a .ic2 { display: inline-flex; width: 19px; justify-content: center; }
.side-nav a .ic2 svg { width: 18px; height: 18px; }
.list-item .ic2 { display: inline-flex; justify-content: center; color: var(--ink-2); }
.list-item .ic2 svg { width: 20px; height: 20px; }
.tabbar a .ic2 { display: inline-flex; }
.tabbar a .ic2 svg { width: 20px; height: 20px; }
/* 按钮/标签前缀线性图标（E11）：随字号缩放、与文字同色、基线对齐 */
.b-ic { display: inline-flex; align-items: center; vertical-align: -0.16em; margin-right: 5px; }
.b-ic svg { width: 1.05em; height: 1.05em; display: block; }
/* 建圈功能模块「点 ⓘ 展开说明」的小圆钮 */
.mod-info { flex: none; width: 18px; height: 18px; border-radius: 50%; border: 1px solid var(--line); background: var(--line-2); color: var(--ink-3); font-size: 12px; line-height: 1; cursor: pointer; }
.mod-info:hover { background: var(--brand-50); color: var(--brand); border-color: var(--brand); }
.q-ic { width: 14px; height: 14px; vertical-align: -2px; margin-right: 3px; }
.side-sect { font-size: 11px; color: var(--ink-4); padding: 16px 11px 6px; letter-spacing: .06em; }
.side-me { margin-top: auto; padding: 12px 10px 0; border-top: 1px solid var(--line-2); display: flex; align-items: center; gap: 8px; font-size: 13px; }
.side-me .who { flex: 1; min-width: 0; overflow: hidden; }
.side-me .who b { display: block; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-me .who span { display: block; color: var(--ink-3); font-size: 11.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

@media (min-width: 901px) {
  .side { display: flex; flex-direction: column; }
  .tabbar { display: none; }
  .view { padding: 20px 26px 48px; }
  .topbar { display: none; }
  .circle-tabs { position: sticky; top: 0; }
}

/* ------------------------------------------------------------- 通用件 */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card + .card { margin-top: 12px; }
.card-pad { padding: 14px 16px; }
.card-hd { padding: 13px 16px; border-bottom: 1px solid var(--line-2); display: flex; align-items: center; gap: 8px; }
.card-hd h3 { margin: 0; font-size: 15px; font-weight: 650; flex: 1; }
.card-hd .hint { font-size: 12px; color: var(--ink-3); font-weight: 400; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 38px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--line);
  background: #fff; color: var(--ink); cursor: pointer; font-size: 14px; font-weight: 500;
  transition: .15s; white-space: nowrap; user-select: none;
}
.btn:hover { border-color: #c6cfdd; background: #fbfcfe; }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn.primary:hover { background: #0747bd; border-color: #0747bd; }
.btn.danger { color: var(--red); border-color: #f3c9c6; background: #fff; }
.btn.danger:hover { background: var(--red-100); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--ink-2); }
.btn.sm { height: 30px; padding: 0 11px; font-size: 13px; border-radius: 8px; }
.btn.lg { height: 46px; font-size: 15.5px; border-radius: 12px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .5; pointer-events: none; }
.btn-row { display: flex; gap: 8px; flex-wrap: wrap; }
.btn-row.end { justify-content: flex-end; }

.chip { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; padding: 2px 9px; border-radius: 999px; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.chip.brand { background: var(--brand-100); color: var(--brand); }
.chip.green { background: var(--green-100); color: var(--green); }
.chip.orange { background: var(--orange-100); color: var(--orange); }
.chip.red { background: var(--red-100); color: var(--red); }
.chip.purple { background: #f0ecff; color: var(--purple); }
.chip.line { background: transparent; border: 1px solid var(--line); }
.chip.solid { background: var(--brand); color: #fff; }
/* 「问答」筛选入口突出：品牌描边 + 浅底 + 加粗，选中时实心 */
.chip.chip-q { border-color: var(--brand); color: var(--brand); font-weight: 600; background: var(--brand-50); }
.chip.chip-q.solid { background: var(--brand); color: #fff; border-color: var(--brand); }
.chip-row { display: flex; flex-wrap: wrap; gap: 6px; }

.field { margin-bottom: 12px; }
.field > label { display: block; font-size: 12.5px; color: var(--ink-2); margin-bottom: 5px; font-weight: 500; }
.field > label .req { color: var(--red); }
.inp, .ta, .sel {
  width: 100%; height: 38px; padding: 0 11px; border: 1px solid var(--line); border-radius: 10px;
  background: #fff; outline: none; transition: .15s; font-size: 14px;
}
.ta { height: auto; min-height: 84px; padding: 9px 11px; line-height: 1.6; resize: vertical; }
.inp:focus, .ta:focus, .sel:focus { border-color: var(--brand); box-shadow: 0 0 0 3px rgba(0, 82, 217, .1); }
.inp::placeholder, .ta::placeholder { color: var(--ink-4); }
.sel { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%2386909c' d='M0 0h10L5 6z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 30px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 12px; }
@media (max-width: 560px) { .grid2 { grid-template-columns: 1fr; } }
.help { font-size: 12px; color: var(--ink-3); margin-top: 5px; }

.seg { display: inline-flex; background: var(--line-2); border-radius: 10px; padding: 3px; gap: 2px; }
.seg button { border: 0; background: transparent; padding: 5px 12px; border-radius: 8px; font-size: 13px; color: var(--ink-2); cursor: pointer; }
.seg button.on { background: #fff; color: var(--brand); font-weight: 600; box-shadow: 0 1px 3px rgba(0, 0, 0, .07); }

.circle-tabs { display: flex; gap: 4px; overflow-x: auto; padding: 6px 10px; background: var(--card); border-bottom: 1px solid var(--line); scrollbar-width: none; position: sticky; top: 52px; z-index: 20; }
.circle-tabs::-webkit-scrollbar { display: none; }
.circle-tabs a { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: 999px; font-size: 14px; color: var(--ink-2); white-space: nowrap; transition: background .18s ease, color .18s ease, box-shadow .18s ease, transform .12s ease; }
.circle-tabs a:hover { background: var(--brand-50); color: var(--brand); }
.circle-tabs a:active { transform: scale(.97); }
.circle-tabs a .ic2 { display: inline-flex; }
.circle-tabs a .ic2 svg { width: 18px; height: 18px; display: block; }
.circle-tabs a.on { background: var(--brand); color: #fff; font-weight: 650; box-shadow: 0 2px 8px rgba(0, 82, 217, .28); }
@media (prefers-reduced-motion: reduce) { .circle-tabs a { transition: none; } .circle-tabs a:active { transform: none; } }
@media (min-width: 901px) { .circle-tabs { top: 0; border: 1px solid var(--line); border-radius: var(--radius); margin-bottom: 14px; } }

.avatar { width: 38px; height: 38px; border-radius: 11px; background: var(--brand-100); color: var(--brand); display: grid; place-content: center; font-size: 14px; font-weight: 650; flex: none; overflow: hidden; }
.avatar.sm { width: 28px; height: 28px; border-radius: 8px; font-size: 12px; }
.avatar.lg { width: 54px; height: 54px; border-radius: 15px; font-size: 20px; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar svg { width: 62%; height: 62%; display: block; }
.avatar.g-1 { background: #e8f0ff; color: #0052d9; }
.avatar.g-2 { background: #e6f6f0; color: #0aa17a; }
.avatar.g-3 { background: #fff4e0; color: #c26a00; }
.avatar.g-4 { background: #f0ecff; color: #7b5cf0; }
.avatar.g-5 { background: #fdeceb; color: #d93026; }

.list { display: flex; flex-direction: column; }
.list-item { display: flex; align-items: center; gap: 11px; padding: 12px 16px; border-bottom: 1px solid var(--line-2); }
.list-item:last-child { border-bottom: 0; }
.list-item:hover { background: #fafcff; }
.list-item .li-body { flex: 1; min-width: 0; }
.list-item .li-title { font-size: 14.5px; font-weight: 550; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.list-item .li-sub { font-size: 12.5px; color: var(--ink-3); margin-top: 2px; }
.list-item.click { cursor: pointer; }

.empty { padding: 34px 20px; text-align: center; color: var(--ink-3); }
.empty .ic { font-size: 34px; opacity: .35; margin-bottom: 8px; }
.empty .empty-ill { width: 148px; max-width: 52%; height: auto; margin: 0 auto 12px; display: block; }
.empty p { margin: 0 0 4px; font-size: 14px; }
.empty .sub { font-size: 12.5px; color: var(--ink-4); }
.skeleton { padding: 16px; }
.sk-line { height: 12px; border-radius: 6px; background: linear-gradient(90deg, #eef0f4 25%, #f6f7fa 37%, #eef0f4 63%); background-size: 400% 100%; animation: sk 1.3s ease infinite; margin-bottom: 9px; }
@keyframes sk { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }

.loading-more { text-align: center; color: var(--ink-4); font-size: 12.5px; padding: 14px; }
.load-more { text-align: center; padding: 6px 14px 16px; }

/* ------------------------------------------------------------- 登录 / 邀请 */
.auth { position: relative; min-height: 100vh; display: grid; place-items: center; padding: 24px 18px;
  background: url('/img/login/bg-wide.jpg') center/cover no-repeat fixed, linear-gradient(160deg, #0b3fa8 0%, #0052d9 55%, #3d7bff 100%); }
.auth-box { width: 100%; max-width: 400px; background: rgba(255, 255, 255, .86); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border: 1px solid rgba(255, 255, 255, .65); border-radius: 20px; padding: 32px 30px 26px; box-shadow: 0 24px 64px rgba(0, 20, 60, .3); }
.auth-brand { position: absolute; top: 30px; left: 34px; display: flex; flex-direction: column; align-items: center; gap: 12px; z-index: 2; pointer-events: none; }
.auth-brand-logo { height: 88px; width: auto; filter: drop-shadow(0 4px 12px rgba(0, 20, 60, .18)); }
.auth-brand-word { height: 26px; width: auto; filter: drop-shadow(0 1px 2px rgba(255, 255, 255, .5)); }
.auth h2 { margin: 0 0 4px; font-size: 21px; }
.auth .desc { margin: 0 0 20px; color: var(--ink-3); font-size: 13px; line-height: 1.6; }
.auth-tip { margin-top: 14px; padding: 10px 12px; background: var(--brand-50); border-radius: 10px; font-size: 12.5px; color: var(--ink-2); line-height: 1.7; }
.auth-foot-in { text-align: center; color: var(--ink-4); font-size: 12px; margin-top: 18px; }
.inp-wrap { position: relative; }
.inp-wrap .inp { padding-left: 38px; }
.inp-ic { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; opacity: .5; pointer-events: none; }
@media (max-width: 900px) {
  .auth { background-attachment: scroll; background-image: url('/img/login/bg-tall.jpg'), linear-gradient(160deg, #0b3fa8, #0052d9 55%, #3d7bff); }
  .auth-box { max-width: 360px; padding: 26px 22px 22px; }
}

/* ------------------------------------------------------------- 圈子卡片 */
.circle-card { display: block; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); margin-bottom: 12px; }
.circle-cover { height: 84px; background: linear-gradient(120deg, #0052d9, #4c8dff); position: relative; }
.circle-cover.img { background-size: cover; background-position: center; }
.circle-cover .tag { position: absolute; top: 9px; right: 9px; }
.circle-body { padding: 12px 14px 13px; }
.circle-body h4 { margin: 0 0 3px; font-size: 15.5px; display: flex; align-items: center; gap: 6px; }
.circle-body p { margin: 0 0 9px; font-size: 12.5px; color: var(--ink-3); line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.circle-meta { display: flex; align-items: center; gap: 12px; font-size: 12px; color: var(--ink-3); flex-wrap: wrap; }
/* 桌面端「我的圈子」左右排版：封面在左、内容在右 */
@media (min-width: 901px) {
  .circle-card { display: flex; align-items: stretch; }
  .circle-card .circle-cover { width: 240px; min-width: 240px; height: auto; min-height: 116px; flex: none; }
  .circle-card .circle-body { flex: 1; min-width: 0; display: flex; flex-direction: column; justify-content: center; padding: 14px 18px; }
  .circle-card .circle-body p { -webkit-line-clamp: 2; }
}
.cover-prev { width: 120px; height: 62px; border-radius: 8px; background: linear-gradient(120deg, #0052d9, #4c8dff) center/cover no-repeat; border: 1px solid var(--line); flex: none; }
/* 我的圈子列表：桌面一行两个，移动端一个 */
.circle-grid { display: grid; gap: 12px; grid-template-columns: 1fr; }
.circle-grid .circle-card { margin-bottom: 0; }
@media (min-width: 901px) { .circle-grid { grid-template-columns: repeat(2, 1fr); } }
.grid-cards { display: grid; gap: 12px; }
@media (min-width: 700px) { .grid-cards.cols-2 { grid-template-columns: 1fr 1fr; } .grid-cards.cols-3 { grid-template-columns: repeat(3, 1fr); } }

/* ------------------------------------------------------------- 动态流 */
.post { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px 10px; margin-bottom: 11px; box-shadow: var(--shadow); }
.post-hd { display: flex; align-items: center; gap: 10px; margin-bottom: 9px; }
.post-hd .who { flex: 1; min-width: 0; }
.post-hd .who b { font-size: 14.5px; font-weight: 600; }
.post-hd .who .meta { font-size: 12px; color: var(--ink-3); margin-top: 1px; display: flex; gap: 7px; flex-wrap: wrap; align-items: center; }
.post-body { font-size: 15px; line-height: 1.75; word-break: break-word; white-space: pre-wrap; }
.post-body p { margin: 0 0 .6em; }
.post-body h3 { font-size: 16px; margin: .3em 0 .5em; }
.post-body blockquote { margin: .5em 0; padding: 7px 12px; border-left: 3px solid var(--brand); background: var(--brand-50); color: var(--ink-2); border-radius: 0 8px 8px 0; }
.post-body a { text-decoration: underline; }
.post-tags { margin-top: 9px; display: flex; gap: 6px; flex-wrap: wrap; }
.post-tags a { color: var(--brand); background: var(--brand-50); padding: 1px 8px; border-radius: 999px; font-size: 12px; }
.post-link { margin-top: 9px; display: flex; gap: 9px; align-items: center; padding: 9px 11px; border: 1px solid var(--line); border-radius: 10px; background: #fbfcfe; font-size: 13px; min-width: 0; }
.post-link .u { color: var(--ink-3); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.post-att { margin-top: 10px; }
.att-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 6px; }
.att-grid.few { grid-template-columns: repeat(2, 1fr); }
.att-grid.many { grid-template-columns: repeat(3, 1fr); }
/* 只有一张图时放大展示，不再挤成 96px 小方块（真机反馈） */
.att-grid.one { grid-template-columns: 1fr; }
.att-grid.one img { aspect-ratio: auto; max-height: 62vh; width: 100%; object-fit: contain; background: #10141c; }
@media (min-width: 700px) { .att-grid.one img { max-width: 62%; } }
.att-grid img, .att-thumb { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 9px; background: var(--line-2); cursor: zoom-in; border: 1px solid var(--line); }
.att-media { width: 100%; border-radius: 10px; background: #000; max-height: 380px; }
.att-file { display: flex; align-items: center; gap: 9px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 10px; background: #fbfcfe; font-size: 13px; }
.att-file .fic { width: 30px; height: 30px; border-radius: 8px; background: var(--brand-100); color: var(--brand); display: grid; place-content: center; font-size: 13px; flex: none; }
.att-file .n { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.post-quote { margin-top: 10px; border-left: 3px solid var(--line); padding: 8px 11px; background: #fafbfc; border-radius: 0 8px 8px 0; font-size: 13px; color: var(--ink-2); }
.post-quote b { color: var(--ink); }
.post-ft { margin-top: 10px; padding-top: 9px; border-top: 1px solid var(--line-2); display: flex; align-items: center; gap: 4px; }
.act { flex: 1; display: flex; align-items: center; justify-content: center; gap: 5px; padding: 6px 4px; border-radius: 9px; border: 0; background: transparent; color: var(--ink-3); font-size: 13px; cursor: pointer; }
.act:hover { background: var(--line-2); color: var(--ink-2); }
.act.on { color: var(--brand); font-weight: 600; }
.act .n { font-variant-numeric: tabular-nums; }
/* 围观者：互动计数只读（是 span 不是 button，不可点、不可聚焦） */
.act.ro { cursor: default; opacity: .72; }
.act.ro:hover { background: transparent; color: var(--ink-3); }
.pin-flag { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; color: var(--orange); background: var(--orange-100); padding: 1px 7px; border-radius: 999px; }
.ann-flag { color: #fff; background: var(--red); }
.feat-flag { color: var(--green); background: var(--green-100); }
.moder-box { display: flex; gap: 8px; margin-top: 10px; padding: 9px 11px; background: var(--orange-100); border-radius: 10px; align-items: center; font-size: 13px; color: #7a5200; }

.composer { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; margin-bottom: 12px; box-shadow: var(--shadow); }
.composer .fake { display: flex; align-items: center; gap: 10px; color: var(--ink-3); font-size: 14px; }
.composer textarea { border: 0; padding: 0; min-height: 60px; box-shadow: none !important; }
.composer .tools { display: flex; align-items: center; gap: 6px; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--line-2); flex-wrap: wrap; }
.composer .tools .sp { flex: 1; }

.comment { display: flex; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--line-2); }
.comment:last-child { border-bottom: 0; }
.comment .cb { flex: 1; min-width: 0; }
.comment .ch { display: flex; align-items: baseline; gap: 7px; font-size: 13px; }
.comment .ch b { font-size: 13.5px; }
.comment .ch .t { color: var(--ink-4); font-size: 11.5px; }
.comment .cx { font-size: 14px; line-height: 1.65; margin-top: 2px; word-break: break-word; white-space: pre-wrap; }
.comment .ca { margin-top: 4px; display: flex; gap: 12px; font-size: 12px; color: var(--ink-3); }
.comment .ca button.ca-btn { border: 0; background: transparent; padding: 0; font: inherit; color: inherit; cursor: pointer; }
.comment .ca button.ca-btn:hover { color: var(--brand); text-decoration: underline; }
.comment .ca button.ca-btn:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.comment .ca span:hover { color: var(--brand); }
/* 围观者：评论计数只读，不做 hover 变色（避免看着像能点） */
.comment .ca span.ca-btn.ro { color: var(--ink-4); cursor: default; }
.comment .ca span.ca-btn.ro:hover { color: var(--ink-4); }

/* ---------------------------------------------------- 无障碍·键盘焦点环（G15）
   导航项本就都是真 <a href>/<button>（键盘可达），这里补齐「看得见」的焦点：
   仅 :focus-visible 命中——鼠标点按不出环，键盘 Tab 才出环，品牌色 + 2px 偏移。 */
.circle-tabs a:focus-visible, .tabbar a:focus-visible, .tabbar-plus:focus-visible,
.btn:focus-visible, .icon-btn:focus-visible, .act:focus-visible,
.chip.click:focus-visible, .list-item.click:focus-visible {
  outline: 2px solid var(--brand); outline-offset: 2px;
}
.circle-tabs a:focus-visible { border-radius: 999px; }
.tabbar a:focus-visible, .tabbar-plus:focus-visible { border-radius: 12px; }
.act:focus-visible { border-radius: 9px; }
@media (prefers-contrast: more), (forced-colors: active) {
  .circle-tabs a:focus-visible, .tabbar a:focus-visible, .btn:focus-visible, .icon-btn:focus-visible, .act:focus-visible { outline: 3px solid CanvasText; }
}

/* ------------------------------------------------------------- 课程 / 打卡 */
.course-card { display: flex; gap: 12px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; margin-bottom: 11px; box-shadow: var(--shadow); cursor: pointer; color: inherit; }
a.course-card { text-decoration: none; }
a.course-card:hover { border-color: #bcd0f5; }
.course-cover { width: 96px; height: 68px; border-radius: 10px; background: linear-gradient(120deg, #0b3fa8, #4c8dff); flex: none; display: grid; place-content: center; color: #fff; font-size: 19px; background-size: cover; background-position: center; }
.course-info { flex: 1; min-width: 0; }
.course-info h4 { margin: 1px 0 3px; font-size: 15px; }
.course-info p { margin: 0 0 6px; font-size: 12.5px; color: var(--ink-3); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.progress { height: 5px; border-radius: 3px; background: var(--line-2); overflow: hidden; }
.progress > i { display: block; height: 100%; background: var(--brand); border-radius: 3px; transition: width .4s; }
.progress.green > i { background: var(--green); }
.progress.orange > i { background: var(--orange); }

.lesson { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border-bottom: 1px solid var(--line-2); cursor: pointer; }
.lesson:last-child { border-bottom: 0; }
.lesson .idx { width: 24px; height: 24px; border-radius: 7px; background: var(--line-2); color: var(--ink-3); display: grid; place-content: center; font-size: 12px; flex: none; }
.lesson.done .idx { background: var(--green-100); color: var(--green); }
.lesson.locked { opacity: .55; }
.lesson .lb { flex: 1; min-width: 0; }
.lesson .lb .t { font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lesson .lb .m { font-size: 12px; color: var(--ink-3); margin-top: 1px; display: flex; gap: 8px; flex-wrap: wrap; }

.reader { padding: 16px 18px 26px; font-size: 15.5px; line-height: 1.85; }
.reader h3 { font-size: 17px; margin: .2em 0 .6em; }
.reader p { margin: 0 0 1em; }
.reader blockquote { margin: 1em 0; padding: 10px 14px; border-left: 3px solid var(--brand); background: var(--brand-50); border-radius: 0 10px 10px 0; color: var(--ink-2); }
.reader video, .reader audio { width: 100%; margin: 12px 0; border-radius: 10px; background: #000; }

.check-card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 15px; margin-bottom: 11px; box-shadow: var(--shadow); }
.check-card .top { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.check-card .top h4 { margin: 0; font-size: 15.5px; flex: 1; }
.today-task { display: flex; align-items: center; gap: 12px; padding: 13px 15px; border-radius: var(--radius); background: linear-gradient(120deg, #0052d9, #2f7bff); color: #fff; margin-bottom: 11px; box-shadow: 0 8px 24px rgba(0, 82, 217, .25); }
.today-task.done { background: linear-gradient(120deg, #0aa17a, #26bd95); box-shadow: 0 8px 24px rgba(10, 161, 122, .22); }
.today-task .tt-b { flex: 1; min-width: 0; }
.today-task .tt-b b { display: block; font-size: 15.5px; }
.today-task .tt-b span { font-size: 12.5px; opacity: .88; }
.today-task .btn { background: rgba(255, 255, 255, .18); border-color: rgba(255, 255, 255, .35); color: #fff; }
.today-task .btn:hover { background: rgba(255, 255, 255, .28); }

.cal { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; padding: 4px 2px; }
.cal .hd { text-align: center; font-size: 11px; color: var(--ink-4); padding: 4px 0; }
.cal .d { aspect-ratio: 1; border-radius: 9px; display: grid; place-content: center; font-size: 12.5px; background: var(--line-2); color: var(--ink-2); position: relative; }
.cal .d.on { background: var(--brand); color: #fff; font-weight: 600; }
.cal .d.makeup { background: var(--orange-100); color: var(--orange); }
.cal .d.future { background: #fff; border: 1px dashed var(--line); color: var(--ink-4); }
.cal .d.blank { background: transparent; }
.cal .d.today { box-shadow: 0 0 0 2px var(--brand-100), 0 0 0 3px var(--brand); }
.cal .d i { position: absolute; bottom: 3px; width: 4px; height: 4px; border-radius: 50%; background: var(--green); }
.cal .d.on i { background: #fff; }

/* ------------------------------------------------------------- 数据看板 */
.kpis { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 12px; }
@media (min-width: 720px) { .kpis { grid-template-columns: repeat(4, 1fr); } }
.kpi { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 13px 14px; box-shadow: var(--shadow); }
.kpi .k { font-size: 12px; color: var(--ink-3); display: flex; align-items: center; gap: 5px; }
.kpi .v { font-size: 25px; font-weight: 700; letter-spacing: -.6px; margin-top: 3px; font-variant-numeric: tabular-nums; }
.kpi .v small { font-size: 12.5px; font-weight: 500; color: var(--ink-3); margin-left: 3px; }
.kpi .d { font-size: 11.5px; color: var(--ink-3); margin-top: 3px; }
.kpi.up .v { color: var(--brand); }
.kpi.green .v { color: var(--green); }
.kpi .k-ic { width: 15px; height: 15px; flex: none; }
/* 个人主页 hero */
.profile-head { overflow: hidden; }
.profile-head > .card-pad { padding-top: 16px; }
.ph-id { display: flex; align-items: center; gap: 14px; margin-top: 0; }
.ph-id .avatar { border: 3px solid var(--card); background: var(--card); }

.chart { width: 100%; height: 150px; display: block; }
.chart text { font-size: 10px; fill: var(--ink-4); }
.bars { display: flex; flex-direction: column; gap: 9px; }
.bar-row { display: grid; grid-template-columns: 92px 1fr 44px; align-items: center; gap: 9px; font-size: 12.5px; }
.bar-row .nm { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-row .tr { height: 8px; background: var(--line-2); border-radius: 4px; overflow: hidden; }
.bar-row .tr > i { display: block; height: 100%; background: var(--brand); border-radius: 4px; }
.bar-row .vv { text-align: right; color: var(--ink-2); font-variant-numeric: tabular-nums; }
.funnel { display: flex; flex-direction: column; gap: 7px; }
.funnel .fr { display: grid; grid-template-columns: 96px 1fr auto; gap: 9px; align-items: center; font-size: 13px; }
.funnel .fb { height: 26px; border-radius: 7px; background: linear-gradient(90deg, var(--brand), #5b93ff); min-width: 6px; transition: width .5s; }
.funnel .fr:nth-child(2) .fb { opacity: .92; } .funnel .fr:nth-child(3) .fb { opacity: .84; }
.funnel .fr:nth-child(4) .fb { opacity: .76; } .funnel .fr:nth-child(5) .fb { opacity: .68; }

.rank-row { display: flex; align-items: center; gap: 11px; padding: 10px 14px; border-bottom: 1px solid var(--line-2); }
.rank-row:last-child { border-bottom: 0; }
.rank-no { width: 24px; text-align: center; font-weight: 700; color: var(--ink-3); font-size: 14px; flex: none; }
.rank-no.t1 { color: #e0a300; } .rank-no.t2 { color: #9aa5b1; } .rank-no.t3 { color: #c98a4b; }
.rank-body { flex: 1; min-width: 0; }
.rank-val { font-weight: 700; font-size: 15px; color: var(--brand); font-variant-numeric: tabular-nums; }

table.tb { width: 100%; border-collapse: collapse; font-size: 13.5px; }
table.tb th { background: #f7f9fc; text-align: left; padding: 9px 11px; font-weight: 600; color: var(--ink-2); font-size: 12.5px; white-space: nowrap; border-bottom: 1px solid var(--line); }
table.tb td { padding: 9px 11px; border-bottom: 1px solid var(--line-2); color: var(--ink-2); vertical-align: middle; }
table.tb tr:hover td { background: #fafcff; }
table.tb td.num, table.tb th.num { text-align: right; font-variant-numeric: tabular-nums; }
.tbl-wrap { overflow-x: auto; }

.notice { padding: 11px 13px; border-radius: 11px; background: var(--orange-100); border: 1px solid #ffe0a3; color: #7a5200; font-size: 13px; margin-bottom: 12px; line-height: 1.65; }
.notice.blue { background: var(--brand-50); border-color: #bcd0f5; color: #123a80; }
.notice.red { background: var(--red-100); border-color: #f3c9c6; color: #8c1f18; }
.notice.green { background: var(--green-100); border-color: #b6e5d4; color: #06604a; }
/* 围观模式横幅：左侧说明 + 右侧「申请加入」（窄屏自动换行） */
.notice.spectator-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 10px 14px 0; }
.notice.spectator-bar .sp { flex: 1; min-width: 200px; }

.note-row { display: flex; gap: 11px; padding: 12px 14px; border-bottom: 1px solid var(--line-2); align-items: flex-start; cursor: pointer; }
.note-row:last-child { border-bottom: 0; }
.note-row .ni { width: 34px; height: 34px; border-radius: 10px; background: var(--brand-100); color: var(--brand); display: grid; place-content: center; font-size: 15px; flex: none; }
.note-row.unread .ni { background: var(--brand); color: #fff; }
.note-row .nb { flex: 1; min-width: 0; }
.note-row .nb b { font-size: 14px; font-weight: 600; display: block; }
.note-row .nb p { margin: 2px 0 0; font-size: 12.5px; color: var(--ink-3); line-height: 1.55; }
.note-row .nb .t { font-size: 11.5px; color: var(--ink-4); margin-top: 3px; }
.note-row .nd { width: 7px; height: 7px; border-radius: 50%; background: var(--red); flex: none; margin-top: 7px; }

/* ------------------------------------------------------------- 弹层 / 提示 */
.mask { position: fixed; inset: 0; background: rgba(15, 23, 42, .45); z-index: 200; display: flex; align-items: flex-end; justify-content: center; animation: fade .18s; }
.modal { background: #fff; width: 100%; max-width: 560px; border-radius: 18px 18px 0 0; max-height: 88vh; display: flex; flex-direction: column; animation: up .22s cubic-bezier(.2, .8, .2, 1); }
.modal.center { border-radius: 18px; margin: auto 16px; max-height: 82vh; animation: pop .2s; }
@keyframes up { from { transform: translateY(24px); opacity: .5; } }
@keyframes pop { from { transform: scale(.96); opacity: 0; } }
@keyframes fade { from { opacity: 0; } }
.modal-hd { padding: 15px 18px 11px; border-bottom: 1px solid var(--line-2); display: flex; align-items: center; gap: 10px; flex: none; }
.modal-hd h3 { margin: 0; font-size: 16.5px; flex: 1; font-weight: 650; }
.modal-bd { padding: 16px 18px; overflow-y: auto; flex: 1; }
.modal-ft { padding: 11px 18px calc(13px + var(--safe-bottom)); border-top: 1px solid var(--line-2); display: flex; gap: 9px; justify-content: flex-end; flex: none; }
@media (min-width: 700px) { .mask { align-items: center; } .modal { border-radius: 18px; } }

.toast-host { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--nav-h) + 26px); z-index: 200; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; width: min(92vw, 420px); }
@media (min-width: 901px) { .toast-host { bottom: 30px; } }
.toast { display: inline-flex; align-items: center; gap: 9px; background: rgba(20, 26, 38, .94); color: #fff; padding: 9px 15px 9px 12px; border-radius: 11px; font-size: 13.5px; box-shadow: 0 8px 26px rgba(0, 0, 0, .25); animation: fade .18s; max-width: 100%; line-height: 1.5; border-left: 3px solid rgba(255, 255, 255, .28); }
.toast .t-ic { width: 18px; height: 18px; flex: none; }
.toast.ok { border-left-color: #34d399; }
.toast.err { border-left-color: #f87171; }

.lightbox { position: fixed; inset: 0; background: rgba(0, 0, 0, .9); z-index: 300; display: grid; place-items: center; padding: 18px; }
.lightbox img { max-width: 100%; max-height: 92vh; border-radius: 8px; }
.lightbox .close { position: absolute; top: 16px; right: 18px; color: #fff; font-size: 26px; background: transparent; border: 0; cursor: pointer; }

/* ------------------------------------------------------------- 工具 */
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; } .mt20 { margin-top: 20px; }
.mb8 { margin-bottom: 8px; } .mb12 { margin-bottom: 12px; } .mb16 { margin-bottom: 16px; }
.row { display: flex; align-items: center; gap: 9px; } .row.wrap { flex-wrap: wrap; }
.sp { flex: 1; } .min0 { min-width: 0; }
.t-2 { color: var(--ink-2); } .t-3 { color: var(--ink-3); } .t-brand { color: var(--brand); } .t-red { color: var(--red); } .t-green { color: var(--green); }
.f12 { font-size: 12px; } .f13 { font-size: 13px; } .f11 { font-size: 11px; }
.b { font-weight: 600; } .num { font-variant-numeric: tabular-nums; }
.ellip { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.center { text-align: center; } .right { text-align: right; }
.divider { height: 1px; background: var(--line-2); margin: 14px 0; }
.hide { display: none !important; }
.scroll-x { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ---------------------------------------------------------------- 手机端点击目标
   第三轮验收 F4：390 宽下扫到 11 处可点元素高度 < 32px（话题标签、公告链接、小按钮），
   拇指按不准。只在触屏宽度下放大，桌面端保持紧凑。 */
@media (max-width: 900px) {
  .btn.sm { height: 34px; padding: 0 13px; }
  .seg button { min-height: 32px; padding: 6px 12px; }
  .comment .ca button.ca-btn { min-height: 30px; padding: 5px 2px; }
  .att-open, .att-grid a { min-height: 32px; }
  /* 正文里的 #话题# 与 @某人：inline 链接加内边距撑到可点高度，display 必须换行内块才吃 padding */
  a.t-brand, .t-brand { display: inline-block; min-height: 30px; padding: 4px 6px; margin: -2px -2px; border-radius: 6px; }
  /* 置顶公告横幅里的整行链接 */
  .notice a, .ann-bar a { display: inline-flex; align-items: center; min-height: 32px; }
  .post-tags a, .circle-tabs a, .chip-row .chip { display: inline-flex; align-items: center; min-height: 32px; }
  .chip { min-height: 24px; }
}

/* ---------- 勋章墙（第 7 批·2026-10-19 验收补：之前 medalWall.js 用到的类名全无 CSS，墙渲染成一列裸文本） ---------- */
.medal-wall-hd { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.medal-wall-hd .sp { flex: 1; }
.medal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(132px, 1fr)); gap: 12px; }
.medal-cell { position: relative; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 16px 12px 12px; background: var(--card); text-align: center; }
.medal-cell .icon { font-size: 34px; line-height: 1.1; }
.medal-cell .icon .medal-ico { width: 58px; height: 58px; object-fit: cover; border-radius: 12px; display: inline-block; }
.medal-cell.off .icon .medal-ico { filter: grayscale(1); opacity: .55; }
.medal-cell .t { font-weight: 650; margin-top: 6px; font-size: 14px; }
.medal-cell .sub { font-size: 12px; color: var(--ink-3); margin-top: 2px; min-height: 16px; }
.medal-cell .bar { height: 6px; background: var(--line-2); border-radius: 3px; margin-top: 8px; overflow: hidden; }
.medal-cell .bar .fill { display: block; height: 100%; background: var(--brand); border-radius: 3px; }
.medal-cell.off { opacity: .68; }
.medal-cell.off .icon { filter: grayscale(1); }
.medal-cell.off .bar .fill { background: var(--ink-4); }
.medal-cell.on { border-color: var(--brand-100); background: var(--brand-50); }
.medal-cell.equipped { border-color: var(--brand); box-shadow: 0 0 0 2px var(--brand-100); }
.medal-cell.equipped::after { content: '佩戴中'; position: absolute; top: 8px; right: 8px; font-size: 11px; color: #fff; background: var(--brand); border-radius: 6px; padding: 1px 6px; }
.medal-cell .radio { display: inline-flex; align-items: center; gap: 4px; margin-top: 8px; font-size: 12px; color: var(--ink-2); cursor: pointer; }
.medal-cell .radio input { cursor: pointer; }
.author-badge { display: inline-flex; align-items: center; gap: 2px; font-size: 12px; color: var(--orange); background: var(--orange-100); border-radius: 6px; padding: 1px 6px; white-space: nowrap; }
.author-badge .medal-ico { width: 16px; height: 16px; object-fit: cover; border-radius: 4px; }
/* 勋章图鉴：9 组×每行 4 枚（L1→L4），已达点亮、未达置灰 */
.medal-groups { display: flex; flex-direction: column; gap: 14px; }
.medal-group { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 14px; background: var(--card); }
.medal-group.lit { border-color: var(--brand-100); background: var(--brand-50); }
.mg-hd { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.mg-hd .sp { flex: 1; }
.mg-hd .radio { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--ink-2); cursor: pointer; }
.mg-tiers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.medal-tier { text-align: center; }
.medal-tier .icon { display: grid; place-content: center; }
.medal-tier .icon .medal-ico { width: 48px; height: 48px; object-fit: cover; border-radius: 10px; }
.medal-tier .t { font-size: 12px; font-weight: 600; margin-top: 4px; }
.medal-tier .sub { font-size: 11px; color: var(--ink-3); margin-top: 1px; min-height: 14px; }
.medal-tier .bar { height: 4px; background: var(--line-2); border-radius: 2px; margin-top: 5px; overflow: hidden; }
.medal-tier .bar .fill { display: block; height: 100%; background: var(--ink-4); border-radius: 2px; }
.medal-tier.on .icon .medal-ico { box-shadow: 0 0 0 2px var(--brand-100); }
.medal-tier.on .bar .fill { background: var(--brand); }
.medal-tier.off .icon .medal-ico { filter: grayscale(1); opacity: .5; }

/* ---------- 头像上传 + 裁剪（第 4 批·2026-10-19） ---------- */
.avatar-edit { display: flex; align-items: center; gap: 12px; }
.avatar-edit .ae-preview { width: 64px; height: 64px; border-radius: 14px; overflow: hidden; background: var(--brand-100); color: var(--brand); display: grid; place-content: center; flex: none; }
.avatar-edit .ae-preview img { width: 100%; height: 100%; object-fit: cover; }
.avatar-edit .ae-preview svg { width: 62%; height: 62%; }
.crop-overlay { position: fixed; inset: 0; z-index: 1000; background: rgba(29, 33, 41, .5); display: grid; place-content: center; padding: 16px; }
.crop-modal { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow-lg); width: 320px; max-width: 92vw; overflow: hidden; }
.crop-hd { padding: 14px 16px; border-bottom: 1px solid var(--line); }
.crop-body { padding: 16px; display: flex; flex-direction: column; gap: 12px; align-items: center; }
.crop-frame { position: relative; width: 280px; max-width: 100%; aspect-ratio: 1 / 1; border-radius: 14px; overflow: hidden; background: var(--line-2); touch-action: none; }
.crop-stage { width: 100%; height: 100%; display: block; cursor: grab; }
.crop-stage:active { cursor: grabbing; }
.crop-guide { position: absolute; inset: 0; pointer-events: none; border-radius: 14px; box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .8); outline: 1px dashed rgba(0, 82, 217, .35); outline-offset: -6px; }
.crop-zoom-row { display: flex; align-items: center; gap: 8px; width: 100%; }
.crop-zoom { flex: 1; }
.crop-tip { text-align: center; }
.crop-ft { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 16px; border-top: 1px solid var(--line); }

/* ===== 第 9 批 P3 · 平台总榜页 ===== */
.rk-page { padding-bottom: 24px; }
.rk-title { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.rk-title h2 { margin: 0; font-size: 19px; }
.rk-trophy { filter: saturate(1.1); }
.rk-sub { color: var(--ink-3); font-size: 12.5px; margin: 4px 0 14px; }
.rk-tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.rk-seg { display: inline-flex; background: var(--line-2); border-radius: 10px; padding: 3px; gap: 2px; }
.rk-seg button { border: 0; background: transparent; color: var(--ink-2); font-size: 13px; font-weight: 600; padding: 6px 14px; border-radius: 8px; cursor: pointer; }
.rk-seg button.on { background: #fff; color: var(--brand); box-shadow: 0 1px 2px rgba(0, 0, 0, .06); }
.rk-signin { display: inline-flex; align-items: center; gap: 6px; margin-left: auto; border: 1px solid var(--brand); background: var(--brand); color: #fff; border-radius: 20px; padding: 6px 14px; font-size: 13px; font-weight: 600; cursor: pointer; }
.rk-signin small { font-weight: 400; opacity: .85; }
.rk-signin.done { background: var(--green-100); border-color: transparent; color: var(--green); cursor: default; }
/* 分值解释（与引擎同源，可展开） */
.rk-rules { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); margin-bottom: 14px; overflow: hidden; }
.rk-rules > summary { cursor: pointer; padding: 11px 14px; font-size: 13.5px; font-weight: 600; color: var(--ink-2); list-style: none; }
.rk-rules > summary::-webkit-details-marker { display: none; }
.rk-rules > summary::before { content: '▸ '; color: var(--ink-4); }
.rk-rules[open] > summary::before { content: '▾ '; }
.rk-rule-body { padding: 2px 14px 12px; border-top: 1px solid var(--line-2); }
.rk-rule { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px dashed var(--line-2); }
.rk-rule:last-child { border-bottom: 0; }
.rk-rule-l b { font-size: 13.5px; color: var(--ink); }
.rk-rule-cond { font-size: 12px; color: var(--ink-3); margin-top: 2px; line-height: 1.5; }
.rk-rule-r { text-align: right; white-space: nowrap; display: flex; flex-direction: column; align-items: flex-end; }
.rk-rule-pt { font-weight: 700; color: var(--brand); font-size: 14px; font-variant-numeric: tabular-nums; }
.rk-rule-pt.fold { color: var(--green); font-size: 13px; }
.rk-rule-r small { color: var(--ink-4); font-size: 11.5px; }
.rk-rule-foot { font-size: 11.5px; color: var(--ink-4); margin-top: 8px; }
/* 领奖台 */
.rk-podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; gap: 8px; align-items: end; margin-bottom: 14px; }
.rk-pod { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px 8px 10px; text-align: center; min-width: 0; }
.rk-pod .avatar { margin: 0 auto 6px; width: 46px; height: 46px; }
.rk-pod.r1 { border-color: #f0cf7a; background: linear-gradient(180deg, #fffdf5, #fff); }
.rk-pod.r1 .avatar { width: 58px; height: 58px; }
.rk-pod-medal { font-size: 20px; line-height: 1; }
.rk-pod.r1 .rk-pod-medal { font-size: 26px; }
.rk-pod-name { font-size: 13px; font-weight: 650; margin-top: 3px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-pod-dept { font-size: 11px; color: var(--ink-3); margin-top: 1px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-pod-score { font-size: 15px; font-weight: 700; color: var(--brand); margin-top: 4px; font-variant-numeric: tabular-nums; }
/* 榜单 */
.rk-list { padding: 0; overflow: hidden; }
.rk-loading { color: var(--ink-3); font-size: 13px; }
.rk-name { font-size: 14px; font-weight: 600; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rk-comp { display: flex; gap: 8px; flex-wrap: wrap; font-size: 11.5px; color: var(--ink-3); margin-top: 2px; }
/* 我的吸底条 */
.rk-me { position: sticky; bottom: 12px; z-index: 5; display: flex; align-items: center; gap: 12px; margin: 14px 0 0; padding: 12px 14px; background: var(--brand); color: #fff; border-radius: var(--radius-sm); box-shadow: 0 6px 18px rgba(0, 82, 217, .28); }
.rk-me .avatar { border: 2px solid rgba(255, 255, 255, .6); }
.rk-me-rank { min-width: 62px; }
.rk-me-no { font-size: 12px; opacity: .9; }
.rk-me-no b { font-size: 18px; margin: 0 2px; }
.rk-me-score { font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; }
.rk-me-score small { font-weight: 400; opacity: .85; margin-left: 2px; }
.rk-me-body { flex: 1; min-width: 0; }
.rk-me-body .rk-name { color: #fff; }
.rk-me-body .rk-comp { color: rgba(255, 255, 255, .82); }
.rk-me .btn.sm.primary { background: #fff; color: var(--brand); border-color: #fff; }
/* 积分明细抽屉 */
.rk-bd-score { font-size: 13px; color: var(--ink-2); margin-bottom: 10px; }
.rk-bd-score b { color: var(--brand); font-size: 16px; font-variant-numeric: tabular-nums; }
.rk-bd-block { margin-bottom: 12px; }
.rk-bd-h { font-size: 12px; font-weight: 700; color: var(--ink-3); margin-bottom: 4px; }
.rk-bd-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 0; border-bottom: 1px dashed var(--line-2); font-size: 13px; }
.rk-bd-row:last-child { border-bottom: 0; }
.rk-bd-k { color: var(--ink); min-width: 0; }
.rk-bd-circles { color: var(--ink-3); font-size: 11.5px; }
.rk-bd-v b { color: var(--green); font-variant-numeric: tabular-nums; }
.rk-bd-empty, .rk-bd-note { font-size: 12px; color: var(--ink-4); }
.rk-bd-note { margin-top: 10px; line-height: 1.5; }
/* 个人主页排行榜入口 */
.rk-entry { display: flex; align-items: center; gap: 12px; padding: 12px 14px; margin: 12px 0; background: var(--brand-50); border: 1px solid #d5e3ff; border-radius: var(--radius-sm); text-decoration: none; color: var(--ink); }
.rk-entry-ic { font-size: 22px; line-height: 1; }
.rk-entry-t { flex: 1; min-width: 0; }
.rk-entry-t b { font-size: 14px; }
.rk-entry-go { font-size: 22px; color: var(--brand); line-height: 1; }
/* 个人主页 2×2 入口卡 + 我的圈子折叠 */
.me-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.me-cell { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 22px 12px; background: var(--brand-50); border: 1px solid #d5e3ff; border-radius: var(--radius-sm); cursor: pointer; text-align: center; transition: box-shadow .15s, transform .15s; }
.me-cell:hover { box-shadow: 0 6px 18px rgba(0, 82, 217, .12); transform: translateY(-2px); }
.me-cell-ic { width: 54px; height: 54px; object-fit: contain; display: block; }
.me-cell-t { font-size: 14px; font-weight: 600; color: var(--ink); }
.me-cell-go { position: absolute; top: 8px; right: 11px; font-size: 16px; color: var(--brand); opacity: .6; }
.me-fold-hd { cursor: pointer; user-select: none; }
.me-caret { margin-left: auto; color: var(--ink-4); transition: transform .15s; }
.card.collapsed .me-caret { transform: rotate(-90deg); }
.card.collapsed > .list { display: none; }
@media (max-width: 520px) { .me-grid { grid-template-columns: 1fr 1fr; } }

/* ===== 第 9 批 P4 · 排行榜双 tab + 勋章榜 ===== */
.rk-toptabs { margin-bottom: 14px; }
.rk-toptabs .rk-title { margin-bottom: 10px; }
.rk-bigseg { display: flex; }
.rk-bigseg button { flex: 1; padding: 9px 0; font-size: 14px; }
.mlb-list { padding: 0; overflow: hidden; }
.mlb-row { display: flex; align-items: center; gap: 11px; padding: 10px 14px; border-bottom: 1px solid var(--line-2); cursor: pointer; }
.mlb-row:last-child { border-bottom: 0; }
.mlb-row:hover { background: #fafcff; }
.mlb-main { flex: 1; min-width: 0; }
.mlb-dept { font-size: 11.5px; color: var(--ink-3); margin-left: 6px; font-weight: 400; }
.mlb-strip { display: flex; gap: 8px; overflow-x: auto; margin-top: 4px; padding-bottom: 2px; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.mlb-strip::-webkit-scrollbar { height: 5px; }
.mlb-strip::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
.mlb-chip { flex: none; display: flex; flex-direction: column; align-items: center; gap: 1px; width: 40px; }
.mlb-chip .medal-ico { width: 34px; height: 34px; object-fit: contain; }
.mlb-chip-lv { font-size: 10px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.mlb-strip.mlb-empty { color: var(--ink-4); font-size: 12px; align-items: center; }
.mlb-total { flex: none; text-align: center; min-width: 40px; }
.mlb-total b { display: block; font-size: 17px; color: var(--brand); font-variant-numeric: tabular-nums; }
.mlb-total small { font-size: 11px; color: var(--ink-3); }
@media (max-width: 720px) {
  .rk-me { bottom: 74px; }
  .rk-signin { margin-left: 0; }
}

/* ===== 第 9 批 P5 · 我的证书 ===== */
.cert-page { padding-bottom: 24px; }
.cert-title { display: flex; align-items: baseline; gap: 8px; }
.cert-title h2 { margin: 0; font-size: 19px; }
.cert-sub { color: var(--ink-3); font-size: 12.5px; margin: 4px 0 14px; }
.cert-card { padding: 14px 16px; margin-bottom: 12px; }
.cert-card.revoked { opacity: .6; }
.cert-card-hd { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.cert-card-hd b { font-size: 15px; }
.cert-card-hd .hint { color: var(--ink-3); font-size: 12px; flex: none; }
.cert-serial { margin: 6px 0 2px; font-size: 12.5px; color: var(--ink-3); }
.cert-serial code { background: var(--line-2); padding: 2px 7px; border-radius: 6px; color: var(--brand); font-weight: 600; }
.cert-stats { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 8px; }
.cert-stat { display: inline-flex; align-items: baseline; gap: 5px; font-size: 13px; }
.cert-stat .k { color: var(--ink-3); font-size: 12px; }
.cert-stat b { color: var(--ink); font-variant-numeric: tabular-nums; }
.cert-badge { color: var(--green); font-size: 12px; font-weight: 600; }
.cert-doc { text-align: center; padding: 6px 4px; }
.cert-doc-brand { font-size: 12px; letter-spacing: 2px; color: var(--ink-3); }
.cert-doc-title { font-size: 18px; font-weight: 800; color: var(--brand); margin: 8px 0 14px; }
.cert-doc-holder { font-size: 26px; font-weight: 800; }
.cert-doc-line { color: var(--ink-2); font-size: 13px; margin: 10px 0 16px; }
.cert-doc-stats { display: flex; flex-wrap: wrap; gap: 8px 16px; justify-content: center; }
.cert-doc-foot { display: flex; justify-content: space-between; margin-top: 20px; padding-top: 12px; border-top: 1px dashed var(--line); font-size: 12px; color: var(--ink-3); }

/* ===== 创建圈子弹窗：紧凑、一屏展示 ===== */
.create-dlg .field { margin-bottom: 9px; }
.create-dlg .field > label { font-size: 12.5px; margin-bottom: 4px; }
.create-dlg textarea.ta { min-height: 50px; }
.create-dlg .help { margin-top: 3px; }
.cc-mods { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; border: 1px solid var(--line); border-radius: 8px; padding: 2px 12px; }
.cc-mods .mod-row { padding: 8px 0; border-bottom: 1px solid var(--line-2); }
.cc-mods .mod-row:nth-last-child(-n+2) { border-bottom: 0; }
.cc-mods .mod-row .f12 { margin-top: 2px; }
@media (max-width: 560px) { .cc-mods { grid-template-columns: 1fr; } .cc-mods .mod-row:last-child { border-bottom: 0; } }

/* ===== 智跃智库 · 全局知识库页（Phase C：折叠树 + 方形格子墙 + 查看器）===== */
.lib-title { display: flex; align-items: baseline; gap: 8px; }
.lib-title h2 { margin: 0; font-size: 19px; }
.lib-sub { color: var(--ink-3); font-size: 12.5px; margin: 4px 0 14px; }
.lib-shell { display: flex; align-items: flex-start; gap: 0; position: relative; }
.lib-tree { width: 244px; flex: none; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; transition: width .18s, opacity .18s; }
.lib-shell.collapsed .lib-tree { width: 0; opacity: 0; border: 0; pointer-events: none; }
.lib-rail { flex: none; width: 18px; height: 40px; margin: 10px 4px 0 0; border: 1px solid var(--line); background: #fff; border-radius: 6px; color: var(--ink-3); cursor: pointer; font-size: 12px; line-height: 1; }
.lib-shell.collapsed .lib-rail { transform: rotate(180deg); }
.lib-main { flex: 1; min-width: 0; }
.lib-tree-hd { padding: 10px 12px; font-weight: 700; font-size: 13px; border-bottom: 1px solid var(--line-2); }
.lib-tree-body { max-height: calc(100vh - 220px); overflow-y: auto; padding: 4px 6px 10px; }
.lib-node { display: flex; align-items: center; gap: 5px; padding: 7px 8px; border-radius: 8px; cursor: pointer; font-size: 13.5px; }
.lib-node:hover { background: var(--line-2); }
.lib-node.on { background: var(--brand-50); color: var(--brand); font-weight: 600; }
.lib-node.root { margin-bottom: 2px; }
.lib-ic { width: 14px; flex: none; }
.lib-node-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-node-n { font-size: 11px; color: var(--ink-4); flex: none; }
.lib-node-tools { display: none; gap: 2px; flex: none; }
.lib-node:hover .lib-node-tools { display: inline-flex; }
.lib-node-tools button { border: 0; background: transparent; cursor: pointer; font-size: 12px; color: var(--ink-3); padding: 0 2px; }
.lib-node-tools button:hover { color: var(--brand); }
.lib-caret { width: 14px; flex: none; color: var(--ink-4); font-size: 11px; transition: transform .12s; display: inline-block; }
.lib-caret.open { transform: rotate(90deg); }
.lib-caret.pad { opacity: .3; }
.lib-bar { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; align-items: center; }
.bank-move { display: inline-flex; align-items: center; gap: 6px; flex: 0 0 auto; white-space: nowrap; padding-left: 8px; margin-left: 2px; border-left: 1px solid var(--line); }
.bank-filters { display: flex; align-items: center; gap: 6px; flex: 1 1 auto; min-width: 0; overflow-x: auto; scrollbar-width: thin; }
.bank-filters > * { flex-shrink: 0; }
.bank-move .btn { height: 30px; }
.lib-search { flex: 0 1 230px; min-width: 150px; max-width: 260px; }
.lib-bar select { width: auto; flex: 0 0 auto; height: 30px; padding: 0 26px 0 8px; font-size: 12.5px; border: 1px solid var(--line); border-radius: 8px; background-color: #fff; color: var(--ink); cursor: pointer; }
.lib-tag-wrap { position: relative; display: inline-flex; }
.lib-tag-btn { height: 30px; flex: 0 0 auto; display: inline-flex; align-items: center; gap: 4px; padding: 0 10px; font-size: 12.5px; border: 1px solid var(--line); border-radius: 8px; background-color: #fff; color: var(--ink); cursor: pointer; }
.lib-tag-btn::after { content: '▾'; font-size: 10px; opacity: .55; }
.lib-tag-btn:hover { border-color: var(--brand); }
.lib-tag-btn.lib-tag-on { border-color: var(--brand); color: var(--brand); }
.lib-tag-pop { display: none; position: absolute; z-index: 40; top: calc(100% + 4px); left: 0; width: 220px; max-width: 80vw; max-height: 320px; overflow: auto; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 8px 24px rgba(0, 0, 0, .2); padding: 6px; text-align: left; }
.lib-tag-wrap.on .lib-tag-pop { display: block; }
.lib-tag-pop-hd { font-size: 11.5px; color: var(--ink-3); padding: 2px 6px 6px; }
.lib-tag-opt { display: flex; align-items: center; gap: 6px; font-size: 12.5px; padding: 4px 6px; border-radius: 6px; cursor: pointer; }
.lib-tag-opt:hover { background: var(--bg-2, #f5f7fa); }
.lib-tag-opt input { width: 15px; height: 15px; cursor: pointer; }
.lib-tag-opt .lib-tag-n { margin-left: auto; font-size: 11px; color: var(--ink-3); }
.lib-tag-pop-ft { border-top: 1px solid var(--line); margin-top: 4px; padding-top: 6px; text-align: right; }
.lib-crumb { font-size: 12.5px; color: var(--ink-2); margin-bottom: 10px; }
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(212px, 1fr)); gap: 12px; align-items: start; overflow: visible; }
.lib-tile { position: relative; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: visible; cursor: pointer; background: #fff; transition: box-shadow .15s, transform .15s; }
.lib-tile:hover { box-shadow: 0 6px 18px rgba(0, 82, 217, .12); transform: translateY(-2px); }
.lib-tile:has(.lib-tile-tags.on) { z-index: 50; }
.lib-tile-thumb { aspect-ratio: 1 / 1; position: relative; display: flex; align-items: center; justify-content: center; background: var(--bg); overflow: hidden; border-radius: var(--radius-sm) var(--radius-sm) 0 0; }
.lib-tile-code { position: absolute; top: 4px; left: 4px; background: rgba(0, 82, 217, .88); color: #fff; font-size: 10px; padding: 1px 5px; border-radius: 5px; font-variant-numeric: tabular-nums; }
.lib-tile-edit { position: absolute; top: 4px; right: 4px; width: 24px; height: 24px; border-radius: 6px; border: 1px solid var(--line); background: rgba(255,255,255,.92); color: var(--ink-2); cursor: pointer; font-size: 13px; display: flex; align-items: center; justify-content: center; }
.lib-tile-edit:hover { border-color: var(--brand); color: var(--brand); }
.lib-tile.archived { opacity: .95; }
.lib-tile-arch { position: absolute; left: 4px; right: 4px; bottom: 4px; text-align: center; background: rgba(0, 82, 217, .9); color: #fff; font-size: 11px; padding: 2px 4px; border-radius: 6px; }
.lib-tile-img { width: 100%; height: 100%; object-fit: cover; }
.lib-tile-ph { font-size: 44px; }
.lib-tile-cap { padding: 7px 9px; border-top: 1px solid var(--line-2); display: flex; align-items: center; gap: 6px; }
.lib-tile-title { flex: 1; min-width: 0; font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-tile-badge { flex: none; font-size: 11px; color: var(--ink-3); }
.lib-tile-foot { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 5px 9px; border-top: 1px solid var(--line-2); font-size: 11px; color: var(--ink-3); cursor: pointer; }
.lib-tile-by { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-tile-tagbtn { flex: none; border: 1px solid var(--line); background: #fff; color: var(--ink-2); border-radius: 999px; padding: 1px 8px; font-size: 11px; cursor: pointer; }
.lib-tile-tagbtn:hover { border-color: var(--brand); color: var(--brand); }
.lib-tile-tagbtn.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.lib-tile-tags { display: none; }
.lib-tile-tags.on { display: block; position: absolute; top: 100%; left: -1px; right: -1px; z-index: 30; margin-top: 2px; background: #fff; border: 1px solid var(--line); border-radius: 0 0 10px 10px; box-shadow: 0 12px 28px rgba(0, 0, 0, .18); padding: 8px 10px; font-size: 12px; text-align: left; cursor: default; max-height: 340px; overflow: auto; }
.lib-tt-hd { font-weight: 700; font-size: 11.5px; color: var(--ink-2); margin: 4px 0 3px; }
.lib-tt-whole { display: flex; flex-wrap: wrap; gap: 4px; }
.lib-tt-chip { background: #eef2fb; color: var(--brand); border-radius: 6px; padding: 1px 6px; font-size: 11px; }
.lib-tt-anno { padding: 3px 0; border-top: 1px dotted var(--line-2); }
.lib-tt-txt { display: block; }
.lib-tt-meta { display: block; color: var(--ink-3); font-size: 10.5px; }
.lib-tt-loc { color: #b25a00; margin-left: 4px; }
.lib-tt-add { margin-top: 8px; width: 100%; border: 1px dashed var(--brand); color: var(--brand); background: #fff; border-radius: 6px; padding: 4px 8px; font-size: 12px; cursor: pointer; }
.lib-tt-add:hover { background: #eef2fb; }
.lib-emptywrap { grid-column: 1 / -1; }
.lib-cat-cascade { display: flex; gap: 8px; flex-wrap: wrap; }
.lib-cat-cascade select { flex: 1 1 150px; min-width: 140px; }
/* 查看器（全屏浮层） */
.lib-viewer { position: fixed; inset: 0; z-index: 120; background: rgba(15, 23, 42, .55); display: flex; align-items: center; justify-content: center; padding: 16px; }
.lib-vw-panel { display: flex; flex-direction: column; position: relative; max-width: calc(100vw - 24px); max-height: calc(100vh - 24px); }
.lib-vw-bar { display: flex; align-items: center; gap: 10px; background: #fff; border-radius: 10px; padding: 10px 14px; margin-bottom: 10px; flex: none; }
.lib-vw-title { font-weight: 700; font-size: 15px; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-vw-pos { font-size: 12.5px; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.lib-vw-meta { position: relative; display: flex; gap: 8px; flex-wrap: wrap; align-items: center; font-size: 12px; color: var(--ink-3); background: #fff; border-radius: 10px; padding: 8px 14px; margin-bottom: 10px; flex: none; }
/* L2：标题/编号/创建人/日期 + 搜索框 合并成一个头部块 */
.lib-vw-hd { background: #fff; border-radius: 10px; padding: 0 14px; margin-bottom: 10px; flex: none; }
.lib-vw-hd .lib-vw-bar { background: transparent; border-radius: 0; margin-bottom: 0; padding: 10px 0; border-bottom: 1px solid var(--line-2); }
.lib-vw-hd .lib-vw-meta { background: transparent; border-radius: 0; margin-bottom: 0; padding: 8px 0; }
.lib-vw-search { padding: 8px 0; }
.lib-vw-search:empty { display: none; }
.lib-vw-search .lib-pv-search { position: static; margin: 0; padding: 0; box-shadow: none; }
.lib-vw-body { flex: 1; min-height: 0; overflow: hidden; display: flex; background: #fff; border-radius: 10px; padding: 0; }
.lib-vw-main { flex: 1; min-width: 0; overflow-y: auto; padding: 16px; }
.lib-vw-log { width: 0; flex: none; overflow: hidden; border-left: 1px solid var(--line); background: var(--bg); }
.lib-vw-log.on { overflow-y: auto; padding: 12px; }
.lib-vw-split { display: none; flex: none; width: 7px; cursor: col-resize; background: linear-gradient(90deg, transparent, var(--line-2)); }
.lib-vw-split.on { display: block; }
.lib-vw-split:hover { background: var(--brand); opacity: .5; }
.lib-vw-log-hd { display: flex; align-items: center; gap: 6px; font-weight: 700; font-size: 13px; margin-bottom: 8px; }
.lib-vw-log-hd > span { flex: 1; }
.lib-vw-log-refresh, .lib-vw-log-x { border: 1px solid var(--line); background: #fff; color: var(--ink-2); border-radius: 6px; cursor: pointer; font-size: 13px; padding: 1px 7px; }
.lib-vw-log-refresh:hover { color: var(--brand); border-color: var(--brand); }
.lib-vw-log-x:hover { color: var(--red); border-color: var(--red); }
.lib-vw-log-list { display: flex; flex-direction: column; gap: 6px; }
.lib-vw-log-list .lib-log-row { font-size: 12px; padding: 7px 9px; }
.lib-vw-log-hd { flex-wrap: wrap; }
.lib-vw-log-tab { border: 1px solid var(--line); background: #fff; color: var(--ink-2); border-radius: 999px; padding: 1px 9px; font-size: 12px; cursor: pointer; font-weight: 400; }
.lib-vw-log-tab.on { background: var(--brand); border-color: var(--brand); color: #fff; }
.lib-vw-log-body { min-height: 40px; }
.lib-vw-anno-item { border: 1.5px solid var(--line); border-radius: 8px; margin-bottom: 8px; background: #fff; overflow: hidden; }
.lib-vw-anno-item:hover { border-color: var(--brand); }
.lib-vw-anno-row { display: flex; align-items: center; gap: 6px; padding: 7px 9px; cursor: pointer; font-size: 12px; }
.lib-vw-anno-no { color: var(--brand); font-weight: 700; flex: none; }
.lib-vw-anno-txt { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-vw-anno-loc { color: var(--ink-3); font-size: 11px; flex: none; }
.lib-vw-anno-locate { background: var(--brand); color: #fff; border-radius: 999px; padding: 2px 11px; font-size: 12px; font-weight: 600; flex: none; }
.lib-vw-anno-row:hover .lib-vw-anno-locate { background: #0b3fa8; }
.lib-vw-anno-caret { border: 1px solid var(--line); background: #fff; color: var(--ink-3); border-radius: 6px; cursor: pointer; font-size: 11px; line-height: 1; padding: 3px 6px; flex: none; transition: transform .15s; }
.lib-vw-anno-caret:hover { color: var(--brand); border-color: var(--brand); }
.lib-vw-anno-item.open .lib-vw-anno-caret { transform: rotate(180deg); }
.lib-vw-anno-detail { display: none; border-top: 1px dashed var(--line-2); padding: 7px 10px; background: var(--bg); font-size: 11.5px; }
.lib-vw-anno-item.open .lib-vw-anno-detail { display: block; }
.lib-vw-anno-rev { padding: 2px 0; color: var(--ink-2); word-break: break-all; }
.lib-vw-anno-rev.cur { color: var(--brand); font-weight: 600; }
.lib-log-reason { color: #b25a00; font-size: 11px; flex: 1 1 100%; }
@keyframes libFlash { 0%, 100% { box-shadow: 0 0 0 0 rgba(240, 160, 0, 0); } 30% { box-shadow: 0 0 0 6px rgba(240, 160, 0, .55); } }
.lib-anno-bubble.lib-flash { animation: libFlash 1s ease 2; }
.lib-vw-log-search { margin-bottom: 8px; }
.lib-vw-log-search input { width: 100%; box-sizing: border-box; border: 1px solid var(--line); border-radius: 7px; padding: 5px 8px; font-size: 12px; }
.lib-log-code { color: var(--brand); font-size: 11px; font-variant-numeric: tabular-nums; flex: none; }
.lib-vw-code { font-size: 11px; color: var(--brand); background: #eef2fb; border-radius: 6px; padding: 1px 7px; font-variant-numeric: tabular-nums; }
.lib-anno-bubble .lib-anno-bubble-code { display: none; }
.lib-anno-bubble.open .lib-anno-bubble-code { display: block; color: var(--brand); font-size: 11px; font-weight: 600; margin-bottom: 2px; }
.lib-vw-loading { flex: 1; display: flex; align-items: center; justify-content: center; color: #fff; }
.lib-vw-grip { position: absolute; right: -3px; bottom: -3px; width: 18px; height: 18px; cursor: nwse-resize; z-index: 6; opacity: .5; background: linear-gradient(135deg, transparent 40%, var(--brand) 40%, var(--brand) 55%, transparent 55%, transparent 68%, var(--brand) 68%, var(--brand) 82%, transparent 82%); }
.lib-vw-grip:hover { opacity: 1; }
.lib-vw-text { white-space: pre-wrap; word-break: break-word; font-size: 14.5px; line-height: 1.75; margin-top: 8px; }
.lib-pv { margin-bottom: 18px; }
.lib-pv-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 12.5px; color: var(--ink-3); margin-bottom: 6px; }
.lib-pv-dl { color: var(--brand); text-decoration: none; }
.lib-pv-img { max-width: 100%; max-height: 62vh; border-radius: 10px; border: 1px solid var(--line); display: block; margin: 0 auto; }
.lib-pv-frame { width: 100%; height: 70vh; border: 1px solid var(--line); border-radius: 10px; background: #f0f2f5; }
.lib-pv-media { width: 100%; max-height: 70vh; border-radius: 10px; background: #000; }
.lib-pv-text { white-space: pre-wrap; word-break: break-word; background: var(--bg); border-radius: 10px; padding: 14px; font-size: 13.5px; }
.lib-pv-file { display: flex; align-items: center; gap: 12px; background: var(--bg); border-radius: 10px; padding: 14px; font-size: 13.5px; }
.lib-pv-pdf { display: flex; flex-direction: column; align-items: center; gap: 12px; background: var(--bg); border-radius: 10px; padding: 10px; overflow-x: auto; }
.lib-pv-pdfpage { position: relative; display: block; width: fit-content; max-width: none; margin: 0 auto; line-height: 0; box-shadow: 0 1px 6px rgba(0, 0, 0, .18); background: #fff; cursor: crosshair; }
.lib-pv-pdfcanvas { display: block; height: auto; }
.lib-pv-pdfnum { position: absolute; right: 6px; bottom: 4px; line-height: 1.4; font-size: 11px; color: var(--ink-3); background: rgba(255, 255, 255, .8); border-radius: 6px; padding: 1px 6px; }
.lib-pv-search { position: sticky; top: 0; z-index: 6; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; background: #fff; padding: 6px 0 8px; box-shadow: 0 6px 8px -8px rgba(0, 0, 0, .18); }
.lib-pv-search-info { font-size: 12px; color: var(--ink-3); min-width: 40px; }
.lib-pv-search-sp { flex: 1; }
.lib-pv-mark { background: #ffe58f; border-radius: 2px; padding: 0 1px; }
.lib-pv-mark.cur { background: #ff9632; outline: 2px solid #d9730d; }
.lib-pv-hit { position: absolute; background: rgba(255, 213, 0, .45); border: 2px solid #f0a000; border-radius: 3px; pointer-events: none; z-index: 4; box-shadow: 0 0 0 2px rgba(240, 160, 0, .25); }
.lib-pv-office { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 4px; }
.lib-pv-office-status { padding: 18px; text-align: center; color: var(--ink-3); font-size: 13px; }
.lib-docx { min-height: 40px; }
.lib-docx .docx-wrapper { background: transparent; padding: 0; box-shadow: none; }
.lib-docx .docx-wrapper > section.docx { box-shadow: 0 1px 5px rgba(0, 0, 0, .12); margin-bottom: 10px; }
.lib-xlsx-sheet { padding: 8px 10px; border-bottom: 1px solid var(--line-2); }
.lib-xlsx-name { font-weight: 700; font-size: 13px; color: var(--ink-2); margin-bottom: 6px; }
.lib-xlsx-table { overflow: auto; }
.lib-xlsx-table table { border-collapse: collapse; font-size: 12.5px; }
.lib-xlsx-table td, .lib-xlsx-table th { border: 1px solid var(--line-2); padding: 3px 9px; white-space: nowrap; }
.lib-xlsx-table tr:first-child td { background: var(--bg); font-weight: 600; }
/* 位置标签 */
.lib-pv-imgbox { max-height: 68vh; overflow: auto; text-align: center; background: var(--bg); border-radius: 10px; padding: 8px; }
.lib-pv-zoom { display: flex; gap: 6px; align-items: center; margin-bottom: 6px; }
.lib-pv-zoom .f11 { margin-left: auto; }
.lib-pv-imgwrap { position: relative; display: inline-block; cursor: crosshair; max-width: 100%; }
.lib-anno-dot { position: absolute; transform: translate(-50%, -50%); width: 22px; height: 22px; border-radius: 50%; border: 2px solid #fff; background: var(--brand); color: #fff; font-size: 0; cursor: pointer; box-shadow: 0 1px 4px rgba(0,0,0,.35); padding: 0; }
.lib-anno-dot:hover { background: #0b3fa8; }
.lib-anno-panel { margin-top: 16px; border-top: 1px solid var(--line-2); padding-top: 12px; }
.lib-anno-hd { font-weight: 700; font-size: 13.5px; display: flex; gap: 8px; align-items: baseline; margin-bottom: 6px; }
.lib-anno-item { display: flex; align-items: center; gap: 10px; padding: 6px 0; border-bottom: 1px dashed var(--line-2); font-size: 13.5px; }
.lib-anno-txt { flex: 1; min-width: 0; }
.lib-anno-by { font-size: 12px; color: var(--ink-3); flex: none; }
.lib-anno-del { border: 0; background: transparent; color: var(--ink-4); cursor: pointer; font-size: 13px; }
.lib-anno-del:hover { color: var(--red); }
.lib-anno-edit-btn { border: 0; background: transparent; color: var(--brand); cursor: pointer; font-size: 12px; padding: 0; flex: none; }
.lib-anno-edit { position: absolute; z-index: 6; width: 210px; max-width: 70%; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 8px 24px rgba(0, 0, 0, .22); padding: 8px; text-align: left; cursor: default; }
.lib-anno-edit textarea { width: 100%; border: 1px solid var(--line); border-radius: 6px; padding: 6px 8px; font-size: 13px; line-height: 1.5; resize: vertical; min-height: 46px; box-sizing: border-box; }
.lib-anno-edit-ft { display: flex; justify-content: flex-end; gap: 6px; margin-top: 6px; }
/* 位置标签：图上直接显示文字的小气泡 */
.lib-anno-bubble { position: absolute; z-index: 5; max-width: 180px; background: #fff; border: 1px solid var(--brand); color: var(--brand); border-radius: 999px; padding: 2px 10px; font-size: 12px; line-height: 1.5; cursor: pointer; box-shadow: 0 2px 8px rgba(0, 0, 0, .18); }
.lib-anno-bubble:hover { background: #eef2fb; }
.lib-anno-bubble .lib-anno-bubble-full, .lib-anno-bubble .lib-anno-bubble-meta, .lib-anno-bubble .lib-anno-bubble-hist, .lib-anno-bubble .lib-anno-bubble-acts { display: none; }
.lib-anno-bubble.open { border-radius: 10px; max-width: 260px; padding: 8px 10px; }
.lib-anno-bubble.open .lib-anno-bubble-short { display: none; }
.lib-anno-bubble.open .lib-anno-bubble-full { display: block; color: var(--ink-1); font-weight: 600; }
.lib-anno-bubble.open .lib-anno-bubble-meta { display: block; color: var(--ink-3); font-size: 11px; margin-top: 3px; }
.lib-anno-bubble.open .lib-anno-bubble-hist { display: block; color: #b25a00; font-size: 11px; margin-top: 4px; }
.lib-anno-bubble.open .lib-anno-bubble-acts { display: flex; gap: 12px; align-items: center; margin-top: 6px; }
.lib-anno-bubble-acts button { border: 0; background: transparent; cursor: pointer; font-size: 12px; padding: 0; }
.lib-anno-bubble-edit { color: var(--brand); }
.lib-anno-bubble-log { color: var(--brand); }
.lib-anno-bubble-del { color: var(--red); }
.lib-anno-bubble-close { margin-left: auto; color: var(--ink-4); }
.lib-anno-bubble.editing { max-width: 360px; padding: 8px 10px; }
.lib-anno-bubble.editing textarea { width: 100%; min-width: 200px; min-height: 64px; resize: both; overflow: auto; border: 1px solid var(--line); border-radius: 6px; padding: 5px 7px; font-size: 12px; line-height: 1.5; box-sizing: border-box; font-family: inherit; }
/* 编辑整体标签：挂在按钮下方的就地气泡 */
.lib-tag-edit { position: absolute; top: calc(100% - 2px); right: 10px; z-index: 30; width: 260px; max-width: 92%; background: #fff; border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 8px 24px rgba(0, 0, 0, .22); padding: 10px; text-align: left; }
.lib-tag-edit input { width: 100%; border: 1px solid var(--line); border-radius: 6px; padding: 6px 8px; font-size: 13px; margin: 6px 0 0; box-sizing: border-box; }
.lib-drop { transition: background .12s, box-shadow .12s; }
.dropping { outline: 2px dashed var(--brand); outline-offset: -8px; background: rgba(0, 82, 217, .05); border-radius: 12px; }
/* 智库留痕记录页 */
.lib-log { max-width: 860px; margin: 0 auto; }
.lib-log-hd { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.lib-log-hd h2 { font-size: 17px; margin: 0; flex: 1; min-width: 120px; }
.lib-log-list { display: flex; flex-direction: column; gap: 6px; }
.lib-log-row { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; background: #fff; border: 1px solid var(--line); border-left: 3px solid var(--ink-4); border-radius: 8px; padding: 8px 12px; font-size: 13px; }
.lib-log-row.k-ok { border-left-color: #2e9e5b; }
.lib-log-row.k-info { border-left-color: var(--brand); }
.lib-log-row.k-danger { border-left-color: var(--red); }
.lib-log-when { color: var(--ink-3); font-size: 12px; font-variant-numeric: tabular-nums; flex: none; }
.lib-log-who { font-weight: 600; color: var(--ink-1); flex: none; }
.lib-log-act { color: var(--ink-2); flex: none; }
.lib-log-detail { color: var(--ink-1); }
.lib-log-extra { color: var(--ink-3); font-size: 12px; flex: 1 1 100%; word-break: break-all; }
.lib-log-row.k-danger .lib-log-act { color: var(--red); }
.lib-log-row.k-ok .lib-log-act { color: #2e9e5b; }
@media (max-width: 720px) {
  .lib-tree { position: absolute; z-index: 20; left: 0; top: 0; box-shadow: 0 8px 24px rgba(0, 0, 0, .12); }
  .lib-shell.collapsed .lib-tree { display: none; }
  .lib-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); }
}

/* ---------- 右下角「意见反馈」全局入口 ---------- */
.fb-fab { position: fixed; right: 20px; bottom: 20px; z-index: 45; display: inline-flex; align-items: center; gap: 6px; height: 44px; padding: 0 16px; border: 0; border-radius: 22px; background: var(--brand); color: #fff; font-size: 14px; cursor: pointer; box-shadow: 0 6px 18px rgba(0, 82, 217, .32); }
.fb-fab:hover { filter: brightness(1.06); }
.fb-fab-ic { font-size: 18px; line-height: 1; }
.attach-box { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; width: 100%; min-height: 92px; margin-top: 6px; border: 1.5px dashed var(--line); border-radius: 12px; background: var(--brand-50); color: var(--ink-3); font-size: 12.5px; cursor: pointer; transition: border-color .12s, background .12s; }
.attach-box:hover, .attach-box.dropping { border-color: var(--brand); background: rgba(0, 82, 217, .07); color: var(--brand); }
.attach-box-ic { display: inline-flex; }
.attach-box-ic svg { width: 30px; height: 30px; }
.attach-box-hint { text-align: center; padding: 0 12px; }
/* 智恩豆商城 */
.ex-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.ex-card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; display: flex; flex-direction: column; transition: box-shadow .15s, transform .15s; }
.ex-card:hover { box-shadow: 0 6px 20px rgba(16, 24, 40, .10); transform: translateY(-2px); }
.ex-thumb { width: 100%; height: 132px; object-fit: cover; background: var(--line-2); }
.ex-noimg { display: grid; place-content: center; background: linear-gradient(135deg, #eef2ff, #f8fafc); }
.ex-noimg .bean { height: 62px; }
.ex-body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.ex-t { font-weight: 600; font-size: 14.5px; }
.ex-d { font-size: 12.5px; color: var(--ink-3); line-height: 1.5; }
.ex-cost { margin-top: auto; font-size: 13px; color: var(--brand); display: flex; align-items: baseline; gap: 4px; }
.ex-cost b { font-size: 18px; }
.ex-body > .btn { margin-top: 8px; }
.ex-notice { font-size: 12px; color: #b45309; background: #fff7ed; border: 1px solid #fed7aa; border-radius: 8px; padding: 4px 8px; }
.ex-notice.gray { color: var(--ink-3); background: #f3f4f6; border-color: var(--line); }
.ex-window { font-size: 11.5px; color: var(--ink-3); }
/* 动态投票卡片 */
.poll { margin-top: 10px; border: 1px solid var(--line); border-radius: 12px; padding: 10px; background: var(--brand-50, #f7f9ff); }
.poll-hd { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--brand); margin-bottom: 8px; }
.poll-hint { font-weight: 400; color: var(--ink-3); font-size: 12px; margin-left: auto; }
.poll-opt { position: relative; display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; border: 1px solid var(--line); background: #fff; border-radius: 10px; padding: 9px 12px; margin-bottom: 6px; cursor: pointer; font-size: 14px; overflow: hidden; }
button.poll-opt:hover { border-color: var(--brand); color: var(--brand); }
.poll-opt.done { cursor: default; }
.poll-opt .poll-bar { position: absolute; left: 0; top: 0; bottom: 0; background: rgba(0, 82, 217, .12); z-index: 0; transition: width .3s; }
.poll-opt.mine { border-color: var(--brand); }
.poll-txt { position: relative; z-index: 1; flex: 1; }
.poll-n { position: relative; z-index: 1; font-size: 12.5px; color: var(--ink-2); }
.poll-tag { position: relative; z-index: 1; font-size: 11px; color: var(--brand); }
.poll-ft { font-size: 12px; color: var(--ink-3); margin-top: 2px; }
/* 动态接龙卡片 */
.chain { margin-top: 10px; border: 1px solid var(--line); border-radius: 12px; padding: 10px; background: var(--brand-50, #f7f9ff); }
.chain-hd { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--brand); margin-bottom: 8px; }
.chain-list { display: flex; flex-direction: column; gap: 4px; max-height: 240px; overflow-y: auto; }
.chain-item { display: flex; align-items: baseline; gap: 8px; font-size: 13.5px; padding: 5px 8px; border-radius: 8px; background: #fff; border: 1px solid var(--line); }
.chain-item.mine { border-color: var(--brand); background: rgba(0, 82, 217, .04); }
.chain-no { flex: none; width: 20px; text-align: center; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.chain-who { flex: none; font-weight: 600; color: var(--ink); }
.chain-txt { flex: 1; min-width: 0; color: var(--ink-2); word-break: break-word; }
.chain-empty { font-size: 12.5px; color: var(--ink-3); padding: 6px 2px; }
.ex-filter { background: var(--card, #fff); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 1px 2px rgba(16, 24, 40, .04); }
.ex-filter-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ex-filter-lbl { font-size: 13px; color: var(--ink-3); flex-shrink: 0; }
.ex-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.ex-chip { border: 1px solid var(--line); background: #fff; color: var(--ink-2); font-size: 13px; padding: 4px 12px; border-radius: 999px; cursor: pointer; }
.ex-chip.on { color: var(--brand); border-color: var(--brand); background: rgba(0, 82, 217, .06); font-weight: 600; }
.ex-sort { display: flex; gap: 4px; }
.ex-sort-tab { border: 0; background: transparent; color: var(--ink-2); font-size: 13.5px; padding: 5px 12px; border-radius: 8px; cursor: pointer; }
.ex-sort-tab.on { color: var(--brand); background: rgba(0, 82, 217, .08); font-weight: 600; }
/* 智恩豆形象 */
.bean { height: 1.15em; width: auto; vertical-align: -0.2em; display: inline-block; }
.bean-amt { display: inline-flex; align-items: baseline; gap: 3px; }
.bean-amt b { font-weight: 700; }
.bean-amt .bean-unit { font-size: .82em; color: var(--ink-3); font-weight: 400; }
.bean-amt.big { align-items: center; gap: 7px; }
.bean-amt.big .bean { height: 34px; vertical-align: middle; }
.bean-amt.big b { font-size: 28px; color: var(--brand); line-height: 1; }
.ex-bal { display: inline-flex; align-items: center; }
.ex-filter-note { font-size: 12px; color: var(--ink-3); }
/* 商城 / 管理页加宽容器 */
.view.mall { max-width: 1600px; }
/* IT 后台右侧抽屉（人员编辑） */
.drawer-mask { position: fixed; inset: 0; background: rgba(16, 24, 40, .35); z-index: 90; }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(460px, 92vw); background: var(--card, #fff); z-index: 91; box-shadow: -8px 0 32px rgba(16, 24, 40, .18); display: flex; flex-direction: column; animation: drawerIn .18s ease; }
@keyframes drawerIn { from { transform: translateX(24px); opacity: .4; } to { transform: none; opacity: 1; } }
.drawer-hd { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.drawer-hd h3 { margin: 0; font-size: 16px; }
.drawer-bd { flex: 1; overflow-y: auto; padding: 16px 18px; }
.drawer-ft { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px; border-top: 1px solid var(--line); }
/* 商城（用户端）文字横幅 */
.ex-textbanner { height: 150px; border-radius: 16px; margin-bottom: 14px; display: flex; align-items: center; background: linear-gradient(115deg, #0052d9, #3a7be8 60%, #7aa8f0); color: #fff; box-shadow: 0 6px 18px rgba(0, 82, 217, .16); }
.ex-tb-in { padding: 0 34px; }
.ex-tb-title { font-size: 28px; font-weight: 800; letter-spacing: 1px; }
.ex-tb-sub { font-size: 14.5px; margin-top: 8px; opacity: .95; }
/* 商城设置 开启/关闭 开关 */
.ex-switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.ex-switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.ex-switch-track { width: 44px; height: 24px; border-radius: 999px; background: #cbd5e1; position: relative; transition: background .18s; flex: none; }
.ex-switch-knob { position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .2); transition: left .18s; }
.ex-switch input:checked + .ex-switch-track { background: var(--brand); }
.ex-switch input:checked + .ex-switch-track .ex-switch-knob { left: 22px; }
.ex-switch-lbl { font-size: 13.5px; color: var(--ink-2); }
.view.mall .ex-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
@media (max-width: 1280px) { .view.mall .ex-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 900px) { .view.mall .ex-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
/* 商城管理页：智库式左树 + 顶栏 */
.exadmin-shell { display: flex; align-items: flex-start; gap: 16px; }
.exadmin-tree { width: 220px; flex: none; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm, 10px); padding: 6px; position: sticky; top: 12px; box-shadow: 0 1px 2px rgba(16, 24, 40, .04); }
.ex-tree-sect { font-size: 12px; color: var(--ink-3); font-weight: 700; padding: 10px 10px 4px; }
.ex-tree-node { display: flex; align-items: center; gap: 8px; width: 100%; border: 0; background: transparent; color: var(--ink); font-size: 13.5px; text-align: left; padding: 7px 10px; border-radius: 8px; cursor: pointer; }
.ex-tree-node:hover { background: #f5f7fa; }
.ex-tree-node.on { background: rgba(0, 82, 217, .08); color: var(--brand); font-weight: 600; }
.ex-tree-node .n { margin-left: auto; font-size: 12px; color: var(--ink-3); background: #eef1f5; border-radius: 999px; padding: 0 7px; min-width: 18px; text-align: center; }
.ex-tree-node.on .n { background: rgba(0, 82, 217, .12); color: var(--brand); }
.exadmin-col { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.exadmin-header { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; box-shadow: 0 1px 2px rgba(16, 24, 40, .04); }
.exadmin-title { font-size: 17px; font-weight: 700; }
.exadmin-topbar { display: flex; align-items: center; gap: 10px; flex-wrap: nowrap; }
.exadmin-topbar .inp { flex: 1; min-width: 160px; width: auto; }
.exadmin-topbar .sel { width: auto; min-width: 132px; flex: none; }
.exadmin-main .tbl { width: 100%; }
/* 人员与组织：表格一行展示完、宽度自适应、横向滚动，不换行 */
.people-scroll { overflow-x: auto; }
.people-scroll table { width: auto; min-width: 100%; }
.people-scroll th, .people-scroll td { white-space: nowrap; }
.ex-thumbcell { width: 44px; height: 44px; border-radius: 8px; overflow: hidden; background: var(--brand-50, #eef2ff); display: flex; align-items: center; justify-content: center; }
.ex-thumbcell img { width: 100%; height: 100%; object-fit: cover; }
.ex-thumbcell .bean { height: 26px; }
.ex-imgprev { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.ex-imgprev img { width: 72px; height: 72px; object-fit: cover; border-radius: 10px; border: 1px solid var(--line); }
.fb-tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.fb-tab { border: 0; background: transparent; padding: 8px 12px; font-size: 13px; color: var(--ink-2); cursor: pointer; border-bottom: 2px solid transparent; }
.fb-tab.on { color: var(--brand); border-bottom-color: var(--brand); font-weight: 600; }
.fb-body { max-height: 68vh; overflow: auto; }
.fb-body textarea { width: 100%; box-sizing: border-box; min-height: 180px; }
.fb-row { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; margin-bottom: 8px; }
.fb-row-top { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; flex-wrap: wrap; }
.fb-content { font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; word-break: break-word; }
.fb-note { margin-top: 6px; font-size: 12px; color: var(--ink-2); background: rgba(0, 82, 217, .05); border-radius: 8px; padding: 6px 8px; }
.fb-filter { display: flex; gap: 6px; margin-bottom: 10px; flex-wrap: wrap; }
.fb-fbtn { border: 1px solid var(--line); background: #fff; color: var(--ink-2); border-radius: 999px; padding: 3px 12px; font-size: 12.5px; cursor: pointer; }
.fb-fbtn.on { border-color: var(--brand); color: var(--brand); background: rgba(0, 82, 217, .06); }
.fb-img-drop { margin-top: 10px; border: 1px dashed var(--line); border-radius: 10px; padding: 10px; background: rgba(0, 82, 217, .02); }
.fb-img-drop.dropping { border-color: var(--brand); background: rgba(0, 82, 217, .06); }
.fb-img-prev { margin-top: 8px; }
.fb-thumb-wrap { position: relative; display: inline-block; }
.fb-thumb { max-width: 140px; max-height: 120px; border: 1px solid var(--line); border-radius: 8px; object-fit: cover; cursor: zoom-in; display: block; }
.fb-thumb-x { position: absolute; top: -8px; right: -8px; width: 22px; height: 22px; border-radius: 50%; border: 0; background: var(--red, #d4380d); color: #fff; font-size: 13px; line-height: 1; cursor: pointer; }
.fb-zoom { text-align: center; }
.fb-zoom img { max-width: 100%; max-height: 70vh; border-radius: 8px; }
@media (max-width: 900px) { .fb-fab { bottom: 74px; } }
