/* ==========================================================================
   小鱼来了 — 设计系统（移动优先，桌面自适应）
   ========================================================================== */
:root {
  --brand: #0b74ff;
  --brand-600: #0962d8;
  --brand-050: #eaf2ff;
  --accent: #00c2b2;
  --accent-050: #e6faf8;

  --bg: #f4f6fb;
  --surface: #ffffff;
  --surface-2: #fafbfe;
  --line: #e8ecf3;
  --line-strong: #d7deea;

  --text: #16202e;
  --text-2: #5a6b82;
  --text-3: #93a1b5;

  --ok: #12a45b;
  --warn: #f59e0b;
  --danger: #e5484d;
  --danger-050: #fdecec;

  --r-sm: 8px;
  --r: 12px;
  --r-lg: 18px;
  --r-xl: 24px;

  --shadow-sm: 0 1px 2px rgba(16, 32, 60, 0.06);
  --shadow: 0 4px 16px rgba(16, 32, 60, 0.08);
  --shadow-lg: 0 12px 40px rgba(16, 32, 60, 0.14);

  --tabbar-h: 58px;
  --topbar-h: 52px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);

  --font: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB",
    "Microsoft YaHei", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -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-family: inherit; font-size: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; font-weight: 700; line-height: 1.35; }
p { margin: 0 0 8px; }
ul { margin: 0; padding-left: 18px; }

/* ---------- 启动 ---------- */
.boot { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100vh; gap: 8px; }
.boot-logo { font-size: 56px; animation: bob 1.6s ease-in-out infinite; }
.boot-text { font-size: 20px; font-weight: 700; }
.boot-sub { color: var(--text-3); font-size: 13px; }
@keyframes bob { 0%,100% { transform: translateY(0) } 50% { transform: translateY(-8px) } }

/* ---------- 骨架 ---------- */
.shell { min-height: 100vh; padding-bottom: calc(var(--tabbar-h) + var(--safe-b) + 12px); }
.topbar {
  position: sticky; top: 0; z-index: 40;
  height: calc(var(--topbar-h) + var(--safe-t));
  padding-top: var(--safe-t);
  display: flex; align-items: center; gap: 10px;
  padding-inline: 12px;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.topbar .title { font-size: 17px; font-weight: 700; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar .icon-btn { flex: none; }

/* 标题做成回首页链接时的样式：看起来可点，但不像按钮那么重 */
.topbar .title-link {
  color: var(--text-1);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
}
.topbar .title-link:active { opacity: .6; }
.topbar #nav-home { font-size: 17px; }
.page { padding: 12px; max-width: 1180px; margin: 0 auto; }
.page.flush { padding: 0; }

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 45;
  height: calc(var(--tabbar-h) + var(--safe-b));
  padding-bottom: var(--safe-b);
  display: grid; grid-template-columns: repeat(5, 1fr);  /* 列数由 JS 按 TABS 长度内联覆盖 */
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: saturate(180%) blur(14px);
  border-top: 1px solid var(--line);
}
.tabbar a {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; color: var(--text-3); font-size: 11px; font-weight: 600;
}
.tabbar a .ico { font-size: 20px; line-height: 1; }
.tabbar a.active { color: var(--brand); }
.tabbar a.active .ico { transform: translateY(-1px); }
/* 7 个一级入口时压缩一下，避免窄屏拥挤 */
@media (max-width: 480px) {
  .tabbar a { font-size: 10px; gap: 1px; }
  .tabbar a .ico { font-size: 17px; }
}
@media (min-width: 481px) and (max-width: 720px) {
  .tabbar a { font-size: 10.5px; }
  .tabbar a .ico { font-size: 18px; }
}

.fab {
  position: fixed; right: 16px; bottom: calc(var(--tabbar-h) + var(--safe-b) + 16px); z-index: 46;
  width: 56px; height: 56px; border-radius: 50%; border: none;
  background: linear-gradient(135deg, var(--brand), var(--accent));
  color: #fff; font-size: 26px; line-height: 1; box-shadow: var(--shadow-lg);
  display: flex; align-items: center; justify-content: center;
}
.fab:active { transform: scale(0.94); }

/* ---------- 通用 ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); }
.card + .card { margin-top: 12px; }
.card-pad { padding: 14px; }
.section { margin: 16px 0 8px; }
.section-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.section-head h2 { font-size: 16px; }
.section-head .more { font-size: 13px; color: var(--text-3); }

.row { display: flex; align-items: center; gap: 10px; }
.row.between { justify-content: space-between; }
.row.wrap { flex-wrap: wrap; }
.grow { flex: 1; min-width: 0; }
.muted { color: var(--text-2); }
.dim { color: var(--text-3); }
.small { font-size: 13px; }
.tiny { font-size: 12px; }
.strong { font-weight: 700; }
.center { text-align: center; }
.ellipsis { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clamp2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.clamp3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.mt8 { margin-top: 8px } .mt12 { margin-top: 12px } .mt16 { margin-top: 16px } .mt24 { margin-top: 24px }
.mb8 { margin-bottom: 8px } .mb12 { margin-bottom: 12px } .mb16 { margin-bottom: 16px }
.gap6 { gap: 6px } .gap8 { gap: 8px } .gap12 { gap: 12px }
.hide { display: none !important; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 42px; padding: 0 16px; border-radius: var(--r);
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--text);
  font-size: 15px; font-weight: 600; cursor: pointer; transition: .15s;
  white-space: nowrap;
}
.btn:active { transform: scale(0.98); }
.btn:disabled { opacity: .5; pointer-events: none; }
.btn-primary { background: var(--brand); border-color: var(--brand); color: #fff; }
.btn-primary:active { background: var(--brand-600); }
.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-ghost { background: transparent; border-color: transparent; color: var(--brand); }
.btn-outline { background: var(--brand-050); border-color: #cfe0ff; color: var(--brand-600); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 13px; border-radius: 9px; }
.btn-block { width: 100%; }
.btn-group { display: flex; gap: 8px; }
.btn-group .btn { flex: 1; }

.icon-btn {
  width: 36px; height: 36px; border-radius: 10px; border: none; background: transparent;
  display: inline-flex; align-items: center; justify-content: center; font-size: 18px;
  color: var(--text-2); cursor: pointer;
}
.icon-btn:active { background: var(--line); }

/* ---------- 标签 / 徽章 ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips.scroll { flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.chips.scroll::-webkit-scrollbar { display: none; }
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  height: 30px; padding: 0 12px; border-radius: 999px;
  background: var(--surface); border: 1px solid var(--line-strong);
  font-size: 13px; color: var(--text-2); white-space: nowrap; cursor: pointer;
}
.chip.active { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.chip.soft { background: var(--brand-050); border-color: transparent; color: var(--brand-600); }
.badge {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 1px 7px; border-radius: 6px; font-size: 11px; font-weight: 700;
  background: var(--brand-050); color: var(--brand-600);
}
.badge.ok { background: #e7f7ee; color: var(--ok); }
.badge.warn { background: #fef4e3; color: #b26a00; }
.badge.danger { background: var(--danger-050); color: var(--danger); }
.badge.gray { background: #eef1f6; color: var(--text-2); }
.badge.accent { background: var(--accent-050); color: #00857a; }

/* ---------- 表单 ---------- */
.field { margin-bottom: 14px; }
.field > label { display: block; font-size: 13px; font-weight: 600; color: var(--text-2); margin-bottom: 6px; }
.field .hint { font-size: 12px; color: var(--text-3); margin-top: 5px; }
.input, .textarea, .select {
  width: 100%; padding: 11px 12px; border: 1px solid var(--line-strong);
  border-radius: var(--r); background: var(--surface); outline: none; transition: .15s;
}
.input:focus, .textarea:focus, .select:focus { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-050); }
.textarea { min-height: 120px; resize: vertical; line-height: 1.7; }
.input-lg { height: 48px; font-size: 16px; }
.input-group { display: flex; gap: 8px; }
.input-group .input { flex: 1; }
.switch { position: relative; width: 46px; height: 26px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider { position: absolute; inset: 0; background: #cbd5e1; border-radius: 999px; transition: .2s; }
.switch .slider::before { content: ""; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .2s; }
.switch input:checked + .slider { background: var(--brand); }
.switch input:checked + .slider::before { transform: translateX(20px); }

.checkbox { display: flex; align-items: flex-start; gap: 8px; font-size: 14px; cursor: pointer; }
.checkbox input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--brand); }

/* ---------- 列表项 ---------- */
.item {
  display: flex; gap: 12px; padding: 12px 14px;
  background: var(--surface); border-bottom: 1px solid var(--line);
}
.item:last-child { border-bottom: none; }
.item:active { background: var(--surface-2); }
.item-thumb { width: 96px; height: 72px; border-radius: var(--r); object-fit: cover; flex: none; background: linear-gradient(135deg, #e8f0ff, #e6faf8); }
.item-body { flex: 1; min-width: 0; }
.item-title { font-size: 15px; font-weight: 700; line-height: 1.4; }
.item-sub { font-size: 13px; color: var(--text-2); margin-top: 3px; }
.item-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; color: var(--text-3); margin-top: 7px; }

/* ---------- 详情 ---------- */
.hero { position: relative; background: #0b1420; }
.hero img { width: 100%; max-height: 58vh; object-fit: contain; margin: 0 auto; }
.gallery { display: flex; gap: 8px; overflow-x: auto; padding: 10px 12px; background: var(--surface); border-bottom: 1px solid var(--line); scrollbar-width: none; }
.gallery::-webkit-scrollbar { display: none; }
.gallery img { width: 78px; height: 78px; border-radius: var(--r); object-fit: cover; flex: none; border: 2px solid transparent; }
.gallery img.active { border-color: var(--brand); }
.detail-title { font-size: 21px; font-weight: 800; line-height: 1.4; }
.detail-sub { font-size: 14px; color: var(--text-2); margin-top: 8px; }

.ai-card { border: 1px solid #d8e6ff; background: linear-gradient(160deg, #f5f9ff, #f0fbfa); }
.ai-head { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--brand-600); }
.score-ring { width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: 18px; color: #fff; flex: none; }
.ai-list { margin: 8px 0 0; padding: 0; list-style: none; font-size: 13.5px; }
.ai-list li { padding-left: 20px; position: relative; margin-bottom: 5px; color: var(--text-2); }
.ai-list li::before { position: absolute; left: 0; }
.ai-list.good li::before { content: "✓"; color: var(--ok); font-weight: 700; }
.ai-list.risk li::before { content: "!"; color: var(--danger); font-weight: 700; }
.ai-list.tip li::before { content: "→"; color: var(--brand); font-weight: 700; }

.pipeline { display: flex; flex-direction: column; gap: 0; }
.stage { display: flex; gap: 10px; padding: 8px 0; position: relative; }
.stage .dot { width: 22px; height: 22px; border-radius: 50%; flex: none; display: grid; place-items: center; font-size: 11px; font-weight: 700; background: #eef1f6; color: var(--text-3); z-index: 1; }
.stage.done .dot { background: #e7f7ee; color: var(--ok); }
.stage.current .dot { background: var(--brand); color: #fff; box-shadow: 0 0 0 4px var(--brand-050); }
.stage:not(:last-child)::after { content: ""; position: absolute; left: 10px; top: 30px; bottom: -2px; width: 2px; background: var(--line-strong); }
.stage.done:not(:last-child)::after { background: #bfe7d0; }
.stage .body { flex: 1; }
.stage .name { font-size: 14px; font-weight: 600; }
.stage.current .name { color: var(--brand); font-weight: 700; }
.stage .desc { font-size: 12px; color: var(--text-3); }

/* ---------- 留言 ---------- */
.comment { display: flex; gap: 10px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.comment:last-child { border-bottom: none; }
.avatar { width: 36px; height: 36px; border-radius: 50%; flex: none; background: var(--brand-050); color: var(--brand-600); display: grid; place-items: center; font-weight: 700; font-size: 14px; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar.lg { width: 52px; height: 52px; font-size: 18px; }
.avatar.sm { width: 28px; height: 28px; font-size: 12px; }
.comment .body { flex: 1; min-width: 0; }
.comment .name { font-size: 13px; font-weight: 700; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.comment .content { font-size: 14.5px; margin-top: 3px; white-space: pre-wrap; word-break: break-word; }
.comment.ai { background: var(--brand-050); border-radius: var(--r); padding: 10px; border-bottom: none; margin-top: 6px; }
.comment.ai .avatar { background: linear-gradient(135deg, var(--brand), var(--accent)); color: #fff; }

/* ---------- 聊天 ---------- */
.chat-page { display: flex; flex-direction: column; height: 100vh; }
.chat-body { flex: 1; overflow-y: auto; padding: 12px; background: var(--bg); }
.msg { display: flex; gap: 8px; margin-bottom: 12px; align-items: flex-start; }
.msg.me { flex-direction: row-reverse; }
.msg .bubble { max-width: 74%; padding: 9px 12px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); font-size: 14.5px; white-space: pre-wrap; word-break: break-word; box-shadow: var(--shadow-sm); }
.msg.me .bubble { background: var(--brand); color: #fff; border-color: var(--brand); }
.msg.system { justify-content: center; }
.msg.system .bubble { background: #eef1f6; color: var(--text-2); font-size: 12.5px; border: none; max-width: 88%; text-align: center; }
.msg .meta { font-size: 11px; color: var(--text-3); margin-bottom: 3px; }
.chat-input { display: flex; gap: 8px; padding: 10px 12px calc(10px + var(--safe-b)); background: var(--surface); border-top: 1px solid var(--line); align-items: flex-end; }
.chat-input textarea { flex: 1; min-height: 42px; max-height: 120px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: var(--r); resize: none; outline: none; }

/* ---------- 会议 ---------- */
.video-grid { display: grid; grid-template-columns: 1fr; gap: 10px; }
.video-tile { position: relative; background: #0b1420; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 4/3; display: grid; place-items: center; color: #7b8ba3; }
.video-tile video { width: 100%; height: 100%; object-fit: cover; }
.video-tile .tag { position: absolute; left: 8px; bottom: 8px; background: rgba(0,0,0,.55); color: #fff; font-size: 12px; padding: 2px 8px; border-radius: 6px; }
.transcript { max-height: 320px; overflow-y: auto; }
.transcript .line { padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.transcript .spk { color: var(--brand-600); font-weight: 700; margin-right: 6px; font-size: 13px; }
.rec-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--danger); display: inline-block; animation: pulse 1.2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: .25 } }

/* ---------- 弹层 ---------- */
.sheet-mask { position: fixed; inset: 0; background: rgba(10, 20, 35, .45); z-index: 60; animation: fade .18s; }
@keyframes fade { from { opacity: 0 } to { opacity: 1 } }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 61;
  background: var(--surface); border-radius: var(--r-xl) var(--r-xl) 0 0;
  padding: 8px 16px calc(20px + var(--safe-b));
  max-height: 88vh; overflow-y: auto; animation: slideUp .22s cubic-bezier(.2,.8,.3,1);
}
@keyframes slideUp { from { transform: translateY(100%) } to { transform: translateY(0) } }
.sheet-handle { width: 40px; height: 4px; border-radius: 2px; background: var(--line-strong); margin: 6px auto 14px; }
.sheet h3 { font-size: 17px; margin-bottom: 12px; }

.modal-mask { position: fixed; inset: 0; background: rgba(10, 20, 35, .5); z-index: 70; display: grid; place-items: center; padding: 20px; }
.modal { background: var(--surface); border-radius: var(--r-lg); padding: 20px; width: 100%; max-width: 420px; box-shadow: var(--shadow-lg); animation: pop .18s; }
@keyframes pop { from { transform: scale(.94); opacity: 0 } to { transform: scale(1); opacity: 1 } }
.modal h3 { margin-bottom: 10px; }
.modal .actions { display: flex; gap: 10px; margin-top: 18px; }
.modal .actions .btn { flex: 1; }

.toast-host { position: fixed; left: 0; right: 0; top: calc(18px + var(--safe-t)); z-index: 90; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toast { background: rgba(20, 30, 46, .93); color: #fff; padding: 10px 18px; border-radius: 999px; font-size: 14px; max-width: 86vw; text-align: center; box-shadow: var(--shadow-lg); animation: toastIn .2s; }
.toast.ok { background: rgba(15, 130, 75, .95); }
.toast.err { background: rgba(200, 45, 50, .95); }
@keyframes toastIn { from { opacity: 0; transform: translateY(-10px) } to { opacity: 1; transform: none } }

/* ---------- 空状态 / 加载 ---------- */
.empty { text-align: center; padding: 48px 20px; color: var(--text-3); }
.empty .ico { font-size: 44px; margin-bottom: 10px; }
.skeleton { background: linear-gradient(90deg, #eef1f6 25%, #f6f8fc 37%, #eef1f6 63%); background-size: 400% 100%; animation: shimmer 1.3s infinite; border-radius: var(--r); }
@keyframes shimmer { 0% { background-position: 100% 50% } 100% { background-position: 0 50% } }
.spinner { width: 20px; height: 20px; border: 2px solid rgba(255,255,255,.35); border-top-color: #fff; border-radius: 50%; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg) } }
.load-more { text-align: center; padding: 16px; color: var(--text-3); font-size: 13px; }

/* ---------- 首页 ---------- */
.hero-banner { position: relative; border-radius: var(--r-xl); overflow: hidden; padding: 22px 20px; color: #fff; background: linear-gradient(135deg, #0b74ff, #00c2b2); }
.hero-banner h1 { font-size: 22px; }
.hero-banner p { margin: 6px 0 14px; opacity: .92; font-size: 13.5px; }
.hero-search { display: flex; align-items: center; gap: 8px; background: rgba(255,255,255,.94); border-radius: 999px; padding: 9px 16px; color: var(--text-3); font-size: 14px; }
.cat-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.cat-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 16px 10px; text-align: center; box-shadow: var(--shadow-sm); }
.cat-card .ico { font-size: 26px; }
.cat-card .name { font-weight: 700; margin-top: 6px; }
.cat-card .desc { font-size: 11.5px; color: var(--text-3); }

/* 首页一级入口：项目 / 活动 / 贸易 / 群聊 / 会议 同一横栏 */
.cat-grid-5 { grid-template-columns: repeat(5, 1fr); gap: 8px; }
.cat-grid-5 .cat-card { padding: 12px 4px; border-radius: var(--r); }
.cat-grid-5 .cat-card .ico { font-size: 22px; }
.cat-grid-5 .cat-card .name { font-size: 13px; margin-top: 4px; }
.cat-grid-5 .cat-card .desc {
  font-size: 10.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-top: 1px;
}
@media (max-width: 430px) {
  .cat-grid-5 { gap: 6px; }
  .cat-grid-5 .cat-card { padding: 10px 2px; }
  .cat-grid-5 .cat-card .ico { font-size: 20px; }
  .cat-grid-5 .cat-card .name { font-size: 12.5px; }
  .cat-grid-5 .cat-card .desc { display: none; }
}
.stat-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; text-align: center; }
.stat-row .n { font-size: 19px; font-weight: 800; color: var(--brand); }
.stat-row .l { font-size: 11.5px; color: var(--text-3); }
.industry-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.industry-cell { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 10px 4px; text-align: center; font-size: 12px; }
.industry-cell .ico { font-size: 20px; display: block; }

/* ---------- 首页：登录入口 / 会议与群聊快捷区 ---------- */
.hero-auth { display: flex; gap: 10px; margin-top: 14px; }
.hero-auth-btn {
  flex: 1;
  background: #fff;
  border-color: #fff;
  color: var(--brand-600);
  height: 38px;
  font-weight: 700;
}
.hero-auth-btn.ghost { background: rgba(255, 255, 255, .18); border-color: rgba(255, 255, 255, .55); color: #fff; }
.hero-auth-btn:active { transform: scale(.98); }

.login-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  background: linear-gradient(120deg, #eaf2ff, #e6faf8);
  border: 1px solid #cfe0ff;
  border-radius: var(--r-lg);
  padding: 12px 14px;
}

.quick-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
.quick-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  padding: 14px;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: .15s;
}
.quick-card:active { transform: scale(.98); }
.quick-card:hover { border-color: var(--brand); }
.quick-card .ico { font-size: 24px; }
.quick-card .t { font-weight: 700; font-size: 14.5px; }
.quick-card .d { font-size: 11.5px; color: var(--text-3); }

/* ---------- 分享海报 ---------- */
.poster-wrap { display: grid; place-items: center; padding: 10px 0; }
.poster-wrap canvas { width: 100%; max-width: 320px; border-radius: var(--r-lg); box-shadow: var(--shadow); }
.share-mode { display: flex; gap: 10px; align-items: flex-start; padding: 12px; border: 1px solid var(--line); border-radius: var(--r); margin-bottom: 10px; cursor: pointer; }
.share-mode.active { border-color: var(--brand); background: var(--brand-050); }
.share-mode .ico { font-size: 22px; }
.share-preview { background: var(--surface-2); border: 1px dashed var(--line-strong); border-radius: var(--r); padding: 12px; font-size: 13px; white-space: pre-wrap; word-break: break-all; color: var(--text-2); }

/* ---------- 表格（管理端） ---------- */
.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table th, .table td { padding: 10px 8px; text-align: left; border-bottom: 1px solid var(--line); }
.table th { color: var(--text-2); font-weight: 600; background: var(--surface-2); }

/* ---------- 文件卡片 ---------- */
.file-card { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.file-card .fico { width: 38px; height: 38px; border-radius: 9px; display: grid; place-items: center; font-size: 17px; background: var(--brand-050); color: var(--brand-600); flex: none; }
.file-card .fname { font-size: 14px; font-weight: 600; }
.file-card .fmeta { font-size: 11.5px; color: var(--text-3); }

/* ---------- 桌面适配 ---------- */
@media (min-width: 768px) {
  body { font-size: 15px; }
  .page { padding: 20px 24px; }
  .tabbar { display: none; }
  .fab { right: 32px; bottom: 32px; }
  .shell { padding-bottom: 40px; }
  .list-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 12px; }
  .list-grid .item { border: 1px solid var(--line); border-radius: var(--r-lg); border-bottom: 1px solid var(--line); }
  .cat-grid { grid-template-columns: repeat(3, 1fr); }
  .cat-grid-5 { grid-template-columns: repeat(5, 1fr); }
  .industry-grid { grid-template-columns: repeat(8, 1fr); }
  .video-grid { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
  .detail-layout { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 20px; align-items: start; }
  .detail-side { position: sticky; top: calc(var(--topbar-h) + 20px); }
  .sheet { left: auto; right: 24px; bottom: 24px; width: 440px; border-radius: var(--r-xl); }
  .modal { max-width: 520px; }
}
@media (min-width: 1100px) {
  .industry-grid { grid-template-columns: repeat(10, 1fr); }
}

/* ==========================================================================
   项目发布：资质要求 / 商务条件 / 当前环节面板 / 文书
   ========================================================================== */
.privacy-note {
  background: #eef6ff;
  border: 1px solid #cfe0ff;
  border-radius: var(--r);
  padding: 10px 12px;
  font-size: 12.5px;
  line-height: 1.7;
  color: #2b4a7a;
}
.privacy-note b { color: #17406f; }

/* 未登录访客的门禁卡片 */
.gate-card {
  text-align: center;
  background: linear-gradient(180deg, #f5f9ff, #fff);
  border: 1px solid #cfe0ff;
}
.gate-card .btn { height: 42px; }

/* ---------- 发布页：AI 两步流程 ---------- */
.step-hint {
  background: #f5f9ff;
  border: 1px solid #dbe8fb;
  border-radius: var(--r);
  padding: 10px 12px;
  font-size: 12.5px;
  line-height: 1.8;
  color: #33507a;
}
.step-hint b { color: #17406f; }

.summary-card {
  background: #f8fbff;
  border: 1px solid #dbe8fb;
  border-radius: var(--r-lg);
  padding: 12px;
}
.summary-points {
  margin: 6px 0 0;
  padding-left: 18px;
  font-size: 13px;
  line-height: 1.85;
  color: var(--text-2);
}
.summary-points li { margin-bottom: 2px; }

.warn-note {
  background: #fff8e6;
  border: 1px solid #ffe1a8;
  border-radius: var(--r);
  padding: 9px 12px;
  font-size: 12.5px;
  line-height: 1.7;
  color: #8a5a00;
  margin-top: 8px;
}
.warn-note b { color: #6b4600; }

/* ---------- 注册身份选择 / 实名认证 ---------- */
.acct-type { display: flex; gap: 10px; }
.acct-opt {
  flex: 1;
  text-align: center;
  padding: 12px 8px;
  border: 1.5px solid var(--line);
  border-radius: var(--r);
  cursor: pointer;
  transition: all .15s;
  background: #fff;
}
.acct-opt:hover { border-color: #b9d3f5; }
.acct-opt.active { border-color: var(--brand); background: #f2f8ff; box-shadow: 0 0 0 3px rgba(45,120,245,.08); }
.acct-opt .ico { font-size: 26px; line-height: 1.2; }
.acct-opt .strong { font-size: 14px; margin: 4px 0 2px; }

.verify-summary {
  background: #f6f9fe;
  border: 1px solid #e2ecfa;
  border-radius: var(--r);
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--text-2);
}
.verify-list { margin: 6px 0 0; padding-left: 18px; font-size: 12.5px; line-height: 1.8; color: var(--text-2); }
.verify-list li { margin-bottom: 2px; }

/* ---------- 微信绑定 ---------- */
.wx-bound, .wx-unbound {
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 12px;
  background: #f7fbf9;
}
.wx-unbound { background: #f8fafc; }

/* 微信内分享提示条 */
.wx-tip {
  background: #f0f9f1;
  border: 1px solid #cfe9d4;
  border-radius: var(--r);
  padding: 10px 12px;
  font-size: 12.5px;
  line-height: 1.75;
  color: #1f6b34;
  margin-bottom: 12px;
}
.wx-tip b { color: #14512a; }

/* ---------- 案例参考 ---------- */
.case-item {
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px 12px;
  margin-bottom: 8px;
  background: #fbfcfe;
}
.case-title { font-size: 13.5px; font-weight: 600; color: var(--text-1); }
.case-item .kv { font-size: 12.5px; margin-top: 3px; }
.case-item .kv .k { width: 62px; }

/* ---------- 上传队列（逐个文件进度） ---------- */
.upload-queue {
  margin-top: 10px;
  border: 1px solid var(--line);
  border-radius: var(--r);
  background: #fff;
  padding: 10px 12px;
}
.upload-queue-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.upload-item { padding: 6px 0; border-top: 1px dashed #eef2f7; }
.upload-item:first-of-type { border-top: 0; }
.upload-item-main {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  font-size: 12.5px;
}
.upload-item-name {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--text-1);
}
.upload-item-meta { flex: none; color: var(--text-3); font-variant-numeric: tabular-nums; }
.upload-item.is-error .upload-item-name { color: var(--danger); }
.upload-bar {
  height: 4px;
  border-radius: 999px;
  background: #eef2f7;
  margin-top: 5px;
  overflow: hidden;
}
.upload-bar > i {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--brand), #4aa3ff);
  transition: width .18s ease;
}
.upload-bar > i.err { background: var(--danger); }
/* 解析阶段：进度条走满并流动，表示「还在忙」而不是卡死 */
.upload-bar > i.busy {
  background: repeating-linear-gradient(
    115deg,
    var(--brand) 0 12px,
    #7cbcff 12px 24px
  );
  background-size: 200% 100%;
  animation: upload-stripe 1s linear infinite;
}
@keyframes upload-stripe {
  from { background-position: 0 0; }
  to { background-position: -48px 0; }
}
.upload-retry { margin-top: 6px; }

/* ---------- 文件保密 ---------- */
.secret-box {
  border: 1px solid #e6ddc8;
  border-radius: var(--r);
  background: #fffdf6;
  padding: 12px;
}
.file-locked {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 12px;
  border: 1px dashed #e0cfa8;
  border-radius: var(--r);
  background: #fffdf6;
}
.file-locked-ico { font-size: 26px; }
.file-locked-txt { flex: 1; min-width: 0; }
.file-unlocked-tip {
  background: #f0f9f1;
  border: 1px solid #cfe9d4;
  border-radius: var(--r);
  padding: 8px 12px;
  font-size: 12.5px;
  color: #1f6b34;
}
.file-countdown { font-variant-numeric: tabular-nums; }

/* ---------- 导入：拖拽区 ---------- */
.upload-zone {
  border: 2px dashed #c8d8ee;
  border-radius: var(--r-lg);
  background: #f8fbff;
  padding: 20px 14px;
  text-align: center;
  transition: border-color .15s, background .15s, transform .15s;
}
.upload-zone.dragging {
  border-color: var(--brand);
  background: #eef6ff;
  transform: scale(1.01);
}
.upload-zone-ico { font-size: 32px; line-height: 1.1; }
.upload-zone-main { font-size: 14px; font-weight: 600; color: var(--text-1); margin-top: 6px; }
.upload-zone-sub { font-size: 12.5px; color: var(--text-3); margin-top: 4px; line-height: 1.6; }
@media (max-width: 560px) {
  .upload-zone { padding: 16px 10px; }
  .upload-zone-ico { font-size: 26px; }
}

/* ---------- 悬赏配图 ---------- */
.bounty-img-box { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.bounty-img-list { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.bounty-img-item {
  position: relative;
  width: 96px;
  height: 96px;
  border-radius: var(--r);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #f4f7fb;
}
.bounty-img-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.bounty-img-del {
  position: absolute; top: 4px; right: 4px;
  width: 22px; height: 22px; line-height: 1;
  border: 0; border-radius: 50%;
  background: rgba(0, 0, 0, .55); color: #fff;
  font-size: 12px; cursor: pointer; padding: 0;
}
.bounty-img-cover {
  position: absolute; left: 4px; bottom: 4px;
  background: #ff8f00; color: #fff;
  font-size: 10px; padding: 1px 6px; border-radius: 999px;
}

/* ---------- 悬赏 ---------- */
.bounty-card { border: 1px solid #ffe0b2; background: linear-gradient(180deg, #fffdf7, #fff); }
.bounty-reward {
  flex: none;
  background: linear-gradient(135deg, #ff8f00, #ff6f00);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  padding: 5px 12px;
  border-radius: 999px;
  white-space: nowrap;
}

/* 无封面时的占位区 */
.hero-empty {
  display: grid;
  place-items: center;
  height: 168px;
  align-content: center;
  gap: 6px;
  background: linear-gradient(135deg, #eef4fb, #f7fbff);
}

/* ---------- 采购/供应：物资明细 ---------- */
.trade-item {
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px;
  margin-bottom: 10px;
  background: #f9fbfd;
}
.trade-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 0.8fr 1fr;
  gap: 6px;
  margin-top: 6px;
}
@media (max-width: 560px) {
  .trade-grid { grid-template-columns: 1fr 1fr; }
}

/* ---------- 数据表格（物资明细 2 条以上） ---------- */
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--line);
  border-radius: var(--r);
}
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 560px;
}
.data-table th,
.data-table td {
  padding: 9px 10px;
  text-align: left;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.data-table thead th {
  background: #f4f8fd;
  color: var(--text-2);
  font-weight: 600;
  white-space: nowrap;
}
.data-table tbody tr:last-child td { border-bottom: 0; }
.data-table tbody tr:nth-child(even) { background: #fafcff; }
.data-table .num { text-align: right; white-space: nowrap; }
.data-table .dim { color: var(--text-3); }
.data-table td .tiny { line-height: 1.5; }

/* 未登录时给操作按钮加一个锁的提示 */
.locked-hint {
  background: #fff8e6;
  border: 1px solid #ffe1a8;
  border-radius: var(--r);
  padding: 9px 12px;
  font-size: 12.5px;
  color: #8a5a00;
  margin-top: 8px;
}

.form-section-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-1);
  margin: 18px 0 10px;
  padding-left: 9px;
  border-left: 3px solid var(--brand);
  line-height: 1.2;
}

/* ---------- 资质要求：可增删的多行 ---------- */
.qual-row {
  background: #f7f9fc;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px;
  margin-bottom: 10px;
}
.qual-meta { display: flex; align-items: center; gap: 8px; margin-top: 6px; }
.qual-meta .select { flex: 1; min-width: 0; }
.qual-req-wrap {
  display: inline-flex; align-items: center; gap: 4px;
  font-size: 12.5px; color: var(--text-2); white-space: nowrap; cursor: pointer;
}
.qual-note { margin-top: 6px; }

/* ---------- 商务条件 / 资质清单：键值表 ---------- */
.kv-table { display: flex; flex-direction: column; gap: 8px; }
.kv { display: flex; gap: 10px; font-size: 13.5px; line-height: 1.6; }
.kv .k { flex: none; width: 106px; color: var(--text-3); }
.kv .v { flex: 1; min-width: 0; color: var(--text-1); word-break: break-word; }

.qual-list { display: flex; flex-direction: column; gap: 8px; }
.qual-item { background: #f7f9fc; border-radius: var(--r); padding: 9px 11px; }
.qual-item-name { font-size: 13.5px; font-weight: 600; color: var(--text-1); }

/* ---------- 当前环节面板 ---------- */
.stage-panel { border: 1px solid #cfe0ff; background: linear-gradient(180deg, #f5f9ff, #fff); }
.stage-note {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px 12px;
  margin-bottom: 8px;
}
.qual-upload-row {
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px;
  margin-bottom: 10px;
}
.qual-upload-row input[readonly] { background: #f2f5f9; color: var(--text-2); }

/* ---------- 文书视图 ---------- */
.doc-view {
  max-height: 56vh;
  overflow-y: auto;
  padding: 4px 2px;
  font-size: 13.5px;
  line-height: 1.9;
  color: var(--text-1);
}
.doc-h2 { text-align: center; letter-spacing: 6px; font-size: 19px; margin: 4px 0; }
.doc-sub { text-align: center; color: var(--text-3); font-size: 12.5px; margin-bottom: 14px; }
.doc-meta {
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 10px 12px;
  margin-bottom: 14px;
  font-size: 12.5px;
  background: #f7f9fc;
}
.doc-meta b { color: var(--text-3); font-weight: 600; }
.doc-h3 { font-size: 14px; font-weight: 700; margin: 16px 0 6px; }
.doc-row { font-size: 13px; margin: 3px 0; }
.doc-row b { color: var(--text-2); font-weight: 600; }
.doc-foot {
  margin-top: 18px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  color: var(--text-3);
  font-size: 11.5px;
}

/* 转发到微信引导 */
.wx-guide { text-align: center; padding: 18px 4px 6px; }
.wx-guide-ico { font-size: 44px; line-height: 1.1; }
.wx-guide-arrow {
  font-size: 40px;
  color: #07c160;
  font-weight: 800;
  animation: wxArrow 1.4s ease-in-out infinite;
}
@keyframes wxArrow {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(10px, -10px); }
}
.wx-guide-t { font-size: 17px; font-weight: 800; margin-top: 8px; }
.wx-guide-d { font-size: 12.5px; color: var(--muted); line-height: 1.8; margin-top: 8px; }
.wx-qr {
  margin: 16px auto 4px;
  width: 200px; height: 200px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px;
  box-shadow: 0 4px 18px rgba(15,30,60,.08);
}
.wx-qr img { width: 100%; height: 100%; display: block; image-rendering: pixelated; }

/* 微信接入状态提示 */
.wx-status {
  margin-top: 12px;
  padding: 9px 12px;
  border-radius: 10px;
  font-size: 11.5px;
  line-height: 1.6;
  background: #f4f6f8;
  color: var(--muted);
  text-align: left;
}
.wx-status.ok { background: #eafaf0; color: #0e8f5f; }

/* 公众号接入配置页 */
.wxsetup-hero {
  background: linear-gradient(135deg, #3a4a63 0%, #55637a 100%);
  border-radius: 16px; padding: 20px; color: #fff;
}
.wxsetup-hero.ok { background: linear-gradient(135deg, #07c160 0%, #0aa552 100%); }
.wxsetup-hero-t { font-size: 20px; font-weight: 800; }
.wxsetup-hero-s { font-size: 12.5px; opacity: .92; margin-top: 8px; line-height: 1.7; }

.wxsetup-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.wxsetup-stat { background: #f7fafd; border-radius: 10px; padding: 10px; text-align: center; }
.wxsetup-stat.ok { background: #eafaf0; }
.wxsetup-stat b { display: block; font-size: 14px; color: var(--muted); }
.wxsetup-stat.ok b { color: #0e8f5f; }
.wxsetup-stat span { font-size: 10.5px; color: var(--muted); }

.wxsetup-field { display: flex; gap: 10px; padding: 10px 0; border-bottom: 1px dashed var(--line); }
.wxsetup-field:last-child { border-bottom: none; }
.wxsetup-field-ico { font-size: 15px; }
.wxsetup-field-k { font-size: 12.5px; font-weight: 700; font-family: ui-monospace, Consolas, monospace; }
.wxsetup-field-l { font-size: 11.5px; color: var(--text); margin-top: 2px; }
.wxsetup-field-d { font-size: 11px; color: var(--muted); margin-top: 2px; line-height: 1.5; }
.wxsetup-field.ok .wxsetup-field-k { color: #0e8f5f; }

.wxsetup-code {
  background: #1e2430; color: #d8e2f0;
  border-radius: 10px; padding: 12px 14px;
  font-size: 11.5px; line-height: 1.8;
  overflow-x: auto; margin: 0;
  font-family: ui-monospace, Consolas, monospace;
}

.wxsetup-step { display: flex; gap: 12px; padding: 12px 0; border-bottom: 1px dashed var(--line); }
.wxsetup-step:last-child { border-bottom: none; }
.wxsetup-step-n {
  width: 24px; height: 24px; flex: 0 0 24px; border-radius: 50%;
  background: var(--brand); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700;
}
.wxsetup-step-t { font-size: 13.5px; font-weight: 700; }
.wxsetup-step-d { font-size: 12px; color: var(--muted); line-height: 1.65; margin-top: 4px; }

@media (max-width: 520px) {
  .wxsetup-grid { grid-template-columns: 1fr; }
}
