/* ==========================================================================
   山东财经大学校友年会专题模块 —— 样式（手机 H5 + PC 端共用）
   设计令牌与形象门户保持一致（深蓝 + 金色，校训"克明峻德 格物致知"）
   零构建、零第三方依赖：纯 CSS，移动优先，PC 端通过宽度断点增强
   ========================================================================== */
:root {
  --blue: #044585;
  --blue-deep: #03356a;
  --blue-ink: #02203f;
  --blue-mid: #0a5aa8;
  --blue-light: #3d8ed6;
  --blue-pale: #eaf2fb;
  --blue-mist: #f4f8fd;
  --gold: #c8a45c;
  --gold-deep: #a8823c;
  --gold-light: #e3ca94;
  --gold-pale: #fbf6e9;
  --ivory: #f8f6f1;
  --paper: #ffffff;
  --ink: #14212f;
  --muted: #6b7c90;
  --line: rgba(4, 69, 133, .12);
  --line-gold: rgba(200, 164, 92, .38);
  --ok: #2f9e6f;
  --warn: #d08a1a;
  --danger: #c4402f;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Consolas, monospace;
  --shadow-sm: 0 1px 3px rgba(2, 32, 63, .06), 0 6px 18px rgba(2, 32, 63, .05);
  --shadow: 0 2px 8px rgba(2, 32, 63, .08), 0 14px 38px rgba(2, 32, 63, .10);
  --radius: 14px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--sans);
  color: var(--ink);
  background: var(--blue-mist);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--blue-mid); text-decoration: none; }
.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.center { text-align: center; }
.right { text-align: right; }
.nowrap { white-space: nowrap; }
.hidden { display: none !important; }

/* ---------------- 顶栏 ---------------- */
.an-top {
  position: sticky; top: 0; z-index: 30;
  background: linear-gradient(135deg, var(--blue-ink), var(--blue-deep) 55%, var(--blue));
  color: #fff; padding: 12px 16px;
  display: flex; align-items: center; gap: 12px;
  box-shadow: var(--shadow-sm);
}
.an-top .logo {
  width: 38px; height: 38px; border-radius: 10px; flex: 0 0 auto;
  background: rgba(200, 164, 92, .18); border: 1px solid var(--line-gold);
  display: grid; place-items: center; font-weight: 700; color: var(--gold-light);
  font-size: 17px;
}
.an-top h1 { font-size: 16px; margin: 0; font-weight: 650; letter-spacing: .4px; }
.an-top .sub { font-size: 11.5px; color: rgba(255, 255, 255, .72); }
.an-top .spacer { flex: 1; }
.an-top .who { font-size: 12px; color: rgba(255, 255, 255, .85); text-align: right; line-height: 1.3; }

/* ---------------- 容器 ---------------- */
.wrap { max-width: 760px; margin: 0 auto; padding: 14px 14px calc(84px + var(--safe-bottom)); }
.wrap.pc { max-width: 1240px; padding-bottom: 32px; }

/* ---------------- 卡片 ---------------- */
.card {
  background: var(--paper); border-radius: var(--radius);
  border: 1px solid var(--line); box-shadow: var(--shadow-sm);
  padding: 16px; margin-bottom: 14px;
}
.card.gold { border-color: var(--line-gold); background: linear-gradient(180deg, var(--gold-pale), var(--paper) 70%); }
.card h2 { font-size: 15.5px; margin: 0 0 10px; display: flex; align-items: center; gap: 8px; }
.card h2 .bar { width: 4px; height: 16px; border-radius: 2px; background: var(--gold); }
.card h2 .tag { margin-left: auto; }

/* ---------------- 届次横幅 ---------------- */
.hero {
  border-radius: 18px; padding: 18px; color: #fff; margin-bottom: 14px;
  background: radial-gradient(1000px 300px at 0% 0%, rgba(200, 164, 92, .28), transparent 60%),
              linear-gradient(135deg, var(--blue-ink), var(--blue) 70%, var(--blue-mid));
  box-shadow: var(--shadow);
}
.hero .kicker { font-size: 11.5px; letter-spacing: 2px; color: var(--gold-light); text-transform: uppercase; }
.hero h2 { margin: 6px 0 4px; font-size: 20px; line-height: 1.35; }
.hero .theme { color: rgba(255, 255, 255, .85); font-size: 13px; }
.hero .facts { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 12px; font-size: 12.5px; color: rgba(255, 255, 255, .92); }
.hero .facts span { display: inline-flex; align-items: center; gap: 5px; }
.hero .motto { margin-top: 10px; font-size: 12px; color: var(--gold-light); letter-spacing: 3px; }

/* ---------------- 指标 ---------------- */
.metrics { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.metric {
  background: var(--blue-mist); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 12px;
}
.metric .v { font-size: 19px; font-weight: 700; color: var(--blue-deep); line-height: 1.25; }
.metric .k { font-size: 11.5px; color: var(--muted); }
.metric.gold { background: var(--gold-pale); border-color: var(--line-gold); }
.metric.gold .v { color: var(--gold-deep); }

/* ---------------- 表单 ---------------- */
.field { margin-bottom: 12px; }
.field label { display: block; font-size: 12.5px; color: var(--muted); margin-bottom: 5px; }
.field .req::after { content: " *"; color: var(--danger); }
input, select, textarea {
  width: 100%; font-family: inherit; font-size: 15px; color: var(--ink);
  background: var(--paper); border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px; outline: none; transition: border-color .15s, box-shadow .15s;
}
input:focus, select:focus, textarea:focus { border-color: var(--blue-light); box-shadow: 0 0 0 3px rgba(61, 142, 214, .14); }
textarea { min-height: 74px; resize: vertical; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.checkline { display: flex; align-items: center; gap: 8px; font-size: 13.5px; margin: 6px 0; }
.checkline input { width: auto; }

/* ---------------- 按钮 ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid var(--line); background: var(--paper); color: var(--blue-deep);
  font-family: inherit; font-size: 14px; font-weight: 600; padding: 10px 16px;
  border-radius: 10px; cursor: pointer; transition: transform .08s, box-shadow .15s, background .15s;
}
.btn:active { transform: translateY(1px); }
.btn.primary { background: linear-gradient(135deg, var(--blue), var(--blue-mid)); color: #fff; border-color: transparent; box-shadow: 0 6px 16px rgba(4, 69, 133, .22); }
.btn.gold { background: linear-gradient(135deg, var(--gold-deep), var(--gold)); color: #fff; border-color: transparent; box-shadow: 0 6px 16px rgba(168, 130, 60, .25); }
.btn.ghost { background: transparent; }
.btn.danger { color: var(--danger); border-color: rgba(196, 64, 47, .35); }
.btn.block { width: 100%; }
.btn.sm { font-size: 12.5px; padding: 6px 10px; border-radius: 8px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btnrow { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------------- 徽标 ---------------- */
.badge {
  display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 600;
  padding: 2px 8px; border-radius: 999px; border: 1px solid var(--line); background: var(--blue-pale); color: var(--blue-deep);
}
.badge.gold { background: var(--gold-pale); border-color: var(--line-gold); color: var(--gold-deep); }
.badge.ok { background: rgba(47, 158, 111, .12); border-color: rgba(47, 158, 111, .3); color: var(--ok); }
.badge.warn { background: rgba(208, 138, 26, .12); border-color: rgba(208, 138, 26, .32); color: var(--warn); }
.badge.danger { background: rgba(196, 64, 47, .1); border-color: rgba(196, 64, 47, .3); color: var(--danger); }
.badge.muted { background: #f1f4f8; color: var(--muted); }

/* ---------------- 列表 ---------------- */
.rows { border-top: 1px solid var(--line); }
.row { display: flex; align-items: center; gap: 10px; padding: 11px 2px; border-bottom: 1px solid var(--line); }
.row .main { flex: 1; min-width: 0; }
.row .t { font-weight: 600; font-size: 14px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.row .d { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.row .act { display: flex; gap: 6px; flex: 0 0 auto; }
.empty { padding: 26px 10px; text-align: center; color: var(--muted); font-size: 13.5px; }

/* ---------------- 分段切换 ---------------- */
.seg { display: flex; gap: 6px; overflow-x: auto; padding: 3px; background: var(--blue-mist); border: 1px solid var(--line); border-radius: 12px; margin-bottom: 12px; }
.seg button {
  flex: 1 0 auto; border: 0; background: transparent; color: var(--blue-deep);
  font-family: inherit; font-size: 13.5px; font-weight: 600; padding: 8px 12px; border-radius: 9px; cursor: pointer;
}
.seg button.on { background: var(--paper); box-shadow: var(--shadow-sm); color: var(--blue); }

/* ---------------- 桌位网格 ---------------- */
.tablegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; }
.tcard {
  position: relative; text-align: left; cursor: pointer; font-family: inherit;
  background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 10px;
  transition: border-color .15s, box-shadow .15s, transform .08s;
}
.tcard:active { transform: translateY(1px); }
.tcard .no { font-size: 17px; font-weight: 700; color: var(--blue-deep); }
.tcard .nm { font-size: 11.5px; color: var(--muted); height: 32px; overflow: hidden; }
.tcard .ct { font-size: 12px; color: var(--blue-mid); font-weight: 600; }
.tcard .bar { height: 5px; border-radius: 3px; background: var(--blue-pale); margin-top: 6px; overflow: hidden; }
.tcard .bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--blue-light), var(--blue)); }
.tcard.full .bar i { background: var(--danger); }
.tcard.reserved { background: linear-gradient(180deg, var(--gold-pale), var(--paper)); border-color: var(--line-gold); }
.tcard.reserved .no { color: var(--gold-deep); }
.tcard.disabled { opacity: .62; cursor: not-allowed; }
.tcard .tips { position: absolute; top: 8px; right: 8px; font-size: 10.5px; }
.tcard.mine { border-color: var(--ok); box-shadow: 0 0 0 3px rgba(47, 158, 111, .12); }

/* ---------------- 二维码 ---------------- */
.qrbox { display: grid; place-items: center; gap: 8px; padding: 12px; background: var(--paper); border: 1px dashed var(--line); border-radius: 14px; }
.qrbox svg { width: 232px; height: 232px; display: block; }
.passcode { font-family: var(--mono); font-size: 27px; letter-spacing: 7px; font-weight: 700; color: var(--blue-deep); }
.countdown { font-size: 12.5px; color: var(--muted); }
.countdown b { color: var(--blue); }

/* ---------------- 表格（PC 管理端） ---------------- */
.tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.an { width: 100%; border-collapse: collapse; font-size: 13px; background: var(--paper); }
table.an th, table.an td { padding: 9px 10px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
table.an th { background: var(--blue-mist); color: var(--blue-deep); font-weight: 600; font-size: 12.5px; position: sticky; top: 0; }
table.an tr:hover td { background: var(--blue-mist); }
table.an td.wrapcell { white-space: normal; min-width: 160px; }

/* ---------------- 待办卡 ---------------- */
.todos { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.todo {
  text-align: left; cursor: pointer; font-family: inherit;
  background: var(--paper); border: 1px solid var(--line); border-radius: 12px; padding: 11px 12px;
}
.todo .n { font-size: 21px; font-weight: 700; color: var(--blue-deep); line-height: 1.2; }
.todo .l { font-size: 12.5px; color: var(--muted); }
.todo.hot { border-color: rgba(196, 64, 47, .3); background: linear-gradient(180deg, rgba(196, 64, 47, .05), var(--paper)); }
.todo.hot .n { color: var(--danger); }

/* ---------------- 底部导航（H5） ---------------- */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: flex; background: rgba(255, 255, 255, .97); backdrop-filter: blur(8px);
  border-top: 1px solid var(--line); padding-bottom: var(--safe-bottom);
}
.tabbar button {
  flex: 1; border: 0; background: transparent; font-family: inherit; cursor: pointer;
  padding: 8px 2px 9px; font-size: 11px; color: var(--muted); display: grid; gap: 2px; justify-items: center;
}
.tabbar button .ic { font-size: 18px; line-height: 1; }
.tabbar button.on { color: var(--blue); font-weight: 700; }

/* ---------------- 提示 ---------------- */
.toast {
  position: fixed; left: 50%; bottom: calc(96px + var(--safe-bottom)); transform: translateX(-50%);
  background: rgba(2, 32, 63, .93); color: #fff; font-size: 13.5px; padding: 10px 16px; border-radius: 10px;
  max-width: 86vw; z-index: 90; box-shadow: var(--shadow); opacity: 0; transition: opacity .2s, transform .2s;
  pointer-events: none; text-align: center;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(-6px); }
.toast.ok { background: rgba(20, 110, 78, .95); }
.toast.err { background: rgba(150, 42, 32, .95); }

/* ---------------- 模态 ---------------- */
.modal { position: fixed; inset: 0; z-index: 80; background: rgba(2, 32, 63, .45); display: grid; place-items: center; padding: 16px; }
.modal .box { background: var(--paper); border-radius: 16px; max-width: 460px; width: 100%; max-height: 86vh; overflow: auto; padding: 18px; box-shadow: var(--shadow); }
.modal h3 { margin: 0 0 10px; font-size: 16px; }

/* ---------------- 提示条 ---------------- */
.note { font-size: 12.5px; color: var(--muted); background: var(--blue-mist); border: 1px dashed var(--line); border-radius: 10px; padding: 9px 11px; }
.note.gold { background: var(--gold-pale); border-color: var(--line-gold); color: var(--gold-deep); }
.note.warn { background: rgba(208, 138, 26, .08); border-color: rgba(208, 138, 26, .3); color: #8a5b06; }
.note.ok { background: rgba(47, 158, 111, .08); border-color: rgba(47, 158, 111, .28); color: #1d6b4a; }

/* ---------------- 流程图（数据流转） ---------------- */
.flowline { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 12px; }
.flowline .step { background: var(--blue-pale); color: var(--blue-deep); border-radius: 8px; padding: 4px 9px; border: 1px solid var(--line); }
.flowline .arrow { color: var(--gold); }

/* ---------------- PC 增强 ---------------- */
@media (min-width: 900px) {
  body { font-size: 14.5px; }
  .wrap.pc { padding: 18px 22px 40px; }
  .metrics { grid-template-columns: repeat(4, 1fr); }
  .todos { grid-template-columns: repeat(4, 1fr); }
  .tablegrid { grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); }
  .pcgrid { display: grid; grid-template-columns: 1.35fr .95fr; gap: 16px; align-items: start; }
  .pcgrid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; align-items: start; }
  .qrbox svg { width: 268px; height: 268px; }
}
@media (max-width: 899px) {
  .hide-sm { display: none !important; }
}
@media (min-width: 900px) {
  .hide-lg { display: none !important; }
}

/* ================= 年会 H5 v2：首页介绍 / 历届相册 / 报名向导 / 通讯录 / 即时通讯 ================= */
.icbtn { width: 32px; height: 32px; border-radius: 9px; border: 1px solid rgba(255,255,255,.28); background: rgba(255,255,255,.1); color: #fff; font-size: 15px; line-height: 1; display: grid; place-items: center; margin-left: 6px; }
.icbtn:active { background: rgba(255,255,255,.22); }
.an-top .tt h1 { font-size: 16px; }
@media (max-width: 400px) { .an-top .tt h1 { font-size: 14.5px; } .an-top .tt .sub { font-size: 10.5px; } }

/* 首页 hero */
.hero { border-radius: 18px; padding: 20px 18px; color: #fff; position: relative; overflow: hidden; margin-bottom: 14px;
  background: radial-gradient(680px 260px at 8% -14%, rgba(200,164,92,.34), transparent 62%), linear-gradient(140deg, #011529, #03356a 58%, #0a5aa8); box-shadow: 0 8px 26px rgba(2,32,63,.22); }
.hero .kicker { font-size: 10.5px; letter-spacing: 2.6px; color: #e3ca94; }
.hero h2 { margin: 8px 0 6px; font-size: 21px; line-height: 1.36; letter-spacing: .5px; }
.hero .theme { font-size: 14px; color: rgba(255,255,255,.9); letter-spacing: 2px; }
.hero .facts { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 12.5px; color: rgba(255,255,255,.94); }
.hero .motto { margin-top: 10px; letter-spacing: 6px; font-size: 12px; color: #e3ca94; }

/* 四步进度 */
.steps4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.steps4 .s4 { text-align: center; padding: 8px 4px; border-radius: 10px; background: #f4f7fb; border: 1px solid var(--line); }
.steps4 .s4.on { background: #eaf5ee; border-color: #b9dcc6; }
.steps4 .s4 .d { font-size: 15px; color: #9aa7b5; }
.steps4 .s4.on .d { color: var(--ok); }
.steps4 .s4 .k { font-size: 12.5px; font-weight: 700; margin-top: 2px; }
.steps4 .s4 .v { font-size: 11px; color: var(--muted); margin-top: 1px; word-break: break-all; }

/* 亮点 chips / 议程 */
.chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chips .chip { font-size: 12px; color: var(--blue-deep); background: var(--blue-mist); border: 1px solid var(--line); border-radius: 999px; padding: 6px 11px; }
.chips .chip b { font-weight: 700; }
.agenda { display: flex; align-items: center; gap: 0; }
.agenda .ait { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--muted); white-space: nowrap; }
.agenda .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--gold); }
.agenda .ln { flex: 1 1 auto; min-width: 10px; height: 1px; background: linear-gradient(90deg, rgba(200,164,92,.6), rgba(200,164,92,.12)); margin: 0 6px; }

/* 指标（仅管理员） */
.metrics { display: grid; grid-template-columns: repeat(2, 1fr); gap: 9px; }
.metrics .metric { background: #f4f7fb; border: 1px solid var(--line); border-radius: 11px; padding: 11px 12px; }
.metrics .metric.gold { background: #fbf6e9; border-color: rgba(200,164,92,.45); }
.metrics .metric .v { font-size: 19px; font-weight: 800; color: var(--blue); }
.metrics .metric.gold .v { color: var(--gold-deep); }
.metrics .metric .k { font-size: 11.5px; color: var(--muted); margin-top: 2px; }

/* 历届相册 */
.gallery { display: grid; gap: 10px; }
@media (min-width: 420px) { .gallery { grid-template-columns: 1fr 1fr; } }
.gcard { border: 1px solid var(--line); border-radius: 13px; overflow: hidden; background: #fff; }
.gcard:active { transform: scale(.995); }
.gcard img { display: block; width: 100%; height: 118px; object-fit: cover; }
.gcard.single img { height: 190px; }
.gph { height: 118px; position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #fff;
  background: linear-gradient(140deg, #03356a, #0a5aa8); }
.gph.y1 { background: linear-gradient(140deg, #03356a, #0a5aa8); }
.gph.y2 { background: linear-gradient(140deg, #062a4d, #0f6b8f); }
.gph.y3 { background: linear-gradient(140deg, #201a3a, #3f4d8f); }
.gph.y4 { background: linear-gradient(140deg, #3a2a10, #8a6a2a); }
.gph.y0 { background: linear-gradient(140deg, #123a24, #1f7a4d); }
.gph .gy { font-size: 30px; font-weight: 800; letter-spacing: 1px; opacity: .96; font-family: var(--serif); }
.gph .gn { font-size: 11.5px; letter-spacing: 3px; opacity: .82; margin-top: 2px; }
.gcard .gc { padding: 9px 11px 11px; }
.gcard .gt { font-size: 13.5px; font-weight: 700; color: var(--ink); }
.gcard .gd { font-size: 11.5px; color: var(--muted); margin-top: 3px; line-height: 1.55; }

/* 报名向导 */
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 10px; }
@media (max-width: 360px) { .grid2 { grid-template-columns: 1fr; } }
.tablegrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
@media (max-width: 360px) { .tablegrid { grid-template-columns: repeat(2, 1fr); } }
.tcard { position: relative; text-align: left; padding: 9px 9px 8px; border-radius: 11px; border: 1px solid var(--line); background: #fff; }
.tcard .no { font-weight: 800; font-size: 14px; color: var(--blue); font-family: var(--mono); }
.tcard .nm { font-size: 10.5px; color: var(--muted); margin-top: 1px; height: 14px; overflow: hidden; }
.tcard .ct { font-size: 10.5px; color: var(--muted); margin-top: 3px; }
.tcard .bar { height: 3px; border-radius: 2px; background: #e8eef5; margin-top: 5px; overflow: hidden; }
.tcard .bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--blue), var(--blue-mid)); }
.tcard.mine { border-color: var(--gold); box-shadow: 0 0 0 2px rgba(200,164,92,.28) inset; background: #fffdf6; }
.tcard.disabled { opacity: .5; }
.tcard.full .bar i { background: #d9534f; }
.tcard .tips { position: absolute; top: 6px; right: 6px; font-size: 9.5px; color: #fff; background: var(--gold-deep); border-radius: 4px; padding: 1px 4px; }

/* 二维码 / 口令 */
.qrbox { text-align: center; padding: 10px 0 4px; }
.qrbox svg, .qrbox img { width: min(240px, 66vw); height: auto; }
.countdown { font-size: 12px; color: var(--muted); margin-top: 8px; }
.countdown b { color: var(--danger); font-family: var(--mono); }
.passcode { font-family: var(--mono); font-size: 26px; letter-spacing: 6px; color: var(--blue-deep); font-weight: 800; margin-top: 2px; }

/* 通讯录 */
.picklist { max-height: 46vh; overflow: auto; border: 1px solid var(--line); border-radius: 11px; padding: 6px; background: #fafcfe; }
.picklist .pick { display: flex; align-items: center; gap: 9px; padding: 8px 8px; border-radius: 8px; font-size: 13px; }
.picklist .pick + .pick { border-top: 1px dashed var(--line); }
.picklist .pick input { width: 17px; height: 17px; }

/* 即时通讯 */
.chatmembers { display: flex; flex-wrap: wrap; gap: 5px; margin-bottom: 9px; }
.chatbox { height: min(52vh, 420px); overflow-y: auto; background: #f5f8fc; border: 1px solid var(--line); border-radius: 12px; padding: 10px; display: flex; flex-direction: column; gap: 8px; }
.bubble { max-width: 82%; border-radius: 12px; padding: 8px 11px; font-size: 13.5px; line-height: 1.5; position: relative; }
.bubble.me { align-self: flex-end; background: linear-gradient(135deg, var(--blue), var(--blue-mid)); color: #fff; border-bottom-right-radius: 4px; }
.bubble.other { align-self: flex-start; background: #fff; border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.bubble .bn { font-size: 10.5px; color: var(--muted); margin-bottom: 2px; }
.bubble .bm { font-size: 9.5px; opacity: .65; margin-top: 3px; text-align: right; }
.sysmsg { align-self: center; font-size: 11px; color: var(--muted); background: #e9eef4; border-radius: 8px; padding: 4px 9px; max-width: 90%; text-align: center; }
.chatinput { display: flex; gap: 8px; margin-top: 10px; }
.chatinput input { flex: 1 1 auto; min-width: 0; }
.chatinput .btn { flex: 0 0 auto; }

/* 证书 */
.cert { border: 2px solid var(--gold); border-radius: 14px; padding: 18px 16px; text-align: center; background: linear-gradient(180deg, #fffdf6, #fff); }
.cert .ct { font-family: var(--serif); font-size: 19px; letter-spacing: 4px; color: var(--gold-deep); }
.cert .cn { font-size: 17px; font-weight: 800; margin: 10px 0 6px; }
.cert .cb { font-size: 12.5px; color: var(--muted); line-height: 1.75; }
.cert .cs { font-size: 11.5px; color: var(--muted); margin-top: 10px; }

/* 六页签 */
.tabbar button { flex: 1 1 0; }
.tabbar button span:last-child { font-size: 10px; }
@media (max-width: 360px) { .tabbar button span:last-child { font-size: 9px; } }
.hidden { display: none !important; }

/* 顶部登录态不换行 */
.an-top .who { white-space: nowrap; text-align: right; line-height: 1.25; max-width: 108px; overflow: hidden; }
.an-top .who .mono { font-size: 9.5px; opacity: .8; }
