/* 帮你投社区 · 独立站点样式（品牌色与 app.html / extension-social 保持一致） */
:root {
  --brand: #1677ff;
  --brand-2: #0958d9;
  --brand-3: #69a9ff;
  --brand-soft: #eaf2ff;
  /* 兼容历史类名：绿色变量现在指向品牌蓝 */
  --green: var(--brand);
  --green-dark: var(--brand-2);
  --green-soft: var(--brand-soft);
  --bg: #f5f7fb;
  --card: #ffffff;
  --ink: #17233d;
  --ink-2: #4e5969;
  --muted: #86909c;
  --line: #e5eaf2;
  --line-strong: #d6deeb;
  --up: #f5222d;
  --down: #00a870;
  --gold: #b7791f;
  --shadow: 0 10px 30px rgba(22, 119, 255, 0.07);
  --radius: 16px;
}

* { box-sizing: border-box; }
/* 必须在所有组件样式之前：作者样式里的 display 会覆盖浏览器对 hidden 属性的默认隐藏 */
[hidden] { display: none !important; }
html, body { margin: 0; padding: 0; }
body {
  background:
    radial-gradient(780px 380px at 92% -10%, rgba(22, 119, 255, 0.09), transparent 62%),
    linear-gradient(180deg, #f9fbff 0, var(--bg) 280px);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.55;
  min-height: 100vh;
}
a { color: var(--green-dark); text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.up { color: var(--up); }
.down { color: var(--down); }
.mono { font-variant-numeric: tabular-nums; }

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px clamp(16px, 4vw, 40px);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); flex: 0 0 auto; }
.brand-mark {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--brand-2), var(--brand) 62%, var(--brand-3));
  color: #fff;
  font-weight: 800;
  font-size: 18px;
  box-shadow: 0 8px 20px -10px rgba(22, 119, 255, 0.65);
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 15px; letter-spacing: 0.2px; }
.brand-text small { font-size: 11px; color: var(--muted); }
.top-actions { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.topbar-tools { display: flex; align-items: center; gap: 6px; }

/* 顶栏行情条：登录前后统一展示指数与黄金，窄屏横向滚动 */
.topbar-market {
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: flex-start;
  justify-content: safe center;
  gap: 2px;
  min-width: 0;
  padding: 3px;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(180deg, #fbfdff, #f5f9ff);
  scrollbar-width: none;
}
.topbar-market::-webkit-scrollbar { display: none; }
.topbar-market.is-scrollable {
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 18px), transparent);
  mask-image: linear-gradient(90deg, #000 calc(100% - 18px), transparent);
}
.topbar-market.is-scrollable.at-end {
  -webkit-mask-image: none;
  mask-image: none;
}
.mk-item {
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  padding: 4px 8px;
  border-radius: 8px;
  white-space: nowrap;
  transition: background 0.15s ease;
}
.mk-item:hover { background: #fff; }
.mk-name { font-size: 11px; color: var(--muted); }
.mk-price { font-size: 12px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums; }
.mk-chg {
  padding: 1px 4px;
  border-radius: 5px;
  font-size: 10px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.mk-chg.up { color: var(--up); background: rgba(245, 34, 45, 0.08); }
.mk-chg.down { color: var(--down); background: rgba(0, 168, 112, 0.1); }
.mk-chg.flat { color: var(--muted); background: #f1f4f9; }
.mk-empty { padding: 4px 10px; color: var(--muted); font-size: 11.5px; white-space: nowrap; }

/* 顶栏用户区：点击头像即可切换查看用户 */
.top-user-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 4px 9px 4px 5px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  cursor: pointer;
  transition: 0.16s ease;
}
.top-user-btn:hover { border-color: #bcd7ff; background: #f7fbff; box-shadow: 0 6px 16px -14px rgba(22, 119, 255, 0.8); }
.top-user-caret { color: var(--muted); flex: 0 0 auto; }

/* 更多操作菜单 */
.topbar-menu { position: relative; }
.topbar-menu > summary { list-style: none; cursor: pointer; }
.topbar-menu > summary::-webkit-details-marker { display: none; }
.topbar-menu[open] > summary { border-color: var(--brand); color: var(--brand); }
.topbar-menu-list {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 40;
  display: grid;
  min-width: 138px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 18px 44px -18px rgba(21, 38, 63, 0.35);
}
.topbar-menu-list a,
.topbar-menu-list button {
  display: block;
  width: 100%;
  padding: 8px 10px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--ink-2);
  font-size: 12.5px;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}
.topbar-menu-list a:hover,
.topbar-menu-list button:hover { background: var(--brand-soft); color: var(--brand-2); }

/* 查看用户：居中搜索弹窗 */
.view-drawer {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.view-drawer.open { display: flex; }
.view-drawer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(29, 33, 41, 0.48);
  backdrop-filter: blur(3px);
  animation: viewFadeIn 0.18s ease both;
}
.view-drawer-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  width: min(560px, calc(100vw - 32px));
  max-height: min(680px, 84vh);
  padding: 20px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 30px 90px -28px rgba(29, 33, 41, 0.5);
  animation: viewDialogIn 0.22s cubic-bezier(0.2, 0.9, 0.3, 1) both;
}
@keyframes viewFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes viewDialogIn { from { opacity: 0; transform: translateY(10px) scale(0.98); } to { opacity: 1; transform: translateY(0) scale(1); } }
.view-drawer-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.view-drawer-head h2 { margin: 0; font-size: 18px; letter-spacing: 0.02em; }
.view-drawer-head p { margin: 5px 0 0; color: var(--muted); font-size: 12.5px; line-height: 1.6; }
.view-drawer-close {
  flex: none;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}
.view-drawer-close:hover { border-color: var(--green); color: var(--green-dark); }
.view-drawer-search {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-top: 16px;
  padding: 11px 13px;
  border: 1px solid var(--line-strong);
  border-radius: 12px;
  background: #f7f8fa;
  color: var(--muted);
  transition: 0.15s ease;
}
.view-drawer-search:focus-within { border-color: var(--brand-3); background: #fff; box-shadow: 0 0 0 3px rgba(22, 119, 255, 0.11); }
.view-drawer-search svg { flex: none; }
.view-drawer-search input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; font-size: 14px; color: var(--ink); }
.view-drawer-search input::-webkit-search-cancel-button { display: none; }
.view-drawer-hint {
  flex: none;
  padding: 3px 7px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.4;
  white-space: nowrap;
}
.view-search-clear { flex: none; width: 20px; height: 20px; padding: 0; border: 0; border-radius: 50%; background: var(--line); color: var(--muted); font-size: 14px; line-height: 20px; cursor: pointer; }
.view-drawer-current { display: flex; align-items: center; gap: 7px; margin-top: 12px; padding: 8px 10px; border-radius: 9px; background: #f5f6f8; color: var(--muted); font-size: 12px; }
.view-drawer-current strong { color: var(--ink-2); max-width: 240px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.view-drawer-current em { padding: 1px 6px; border-radius: 999px; background: #fff3d8; color: #946300; font-style: normal; font-size: 11px; }
.view-user-list { flex: 1; min-height: 120px; overflow-y: auto; margin: 12px -6px 0; padding: 0 6px 8px; overscroll-behavior: contain; }
.view-user-section { padding: 5px 10px 7px; color: var(--muted); font-size: 11px; letter-spacing: 0.04em; }
.view-user-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: 0.15s ease;
}
.view-user-item:hover { background: #f3f7ff; border-color: #d6e4ff; }
.view-user-item.active { background: var(--brand-soft); border-color: #bcd7ff; }
.view-user-item.kbd-active { border-color: var(--brand); background: #f3f7ff; box-shadow: 0 0 0 2px rgba(22, 119, 255, 0.12); }
.view-user-item .avatar { flex: none; }
.view-user-item-main { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.view-user-item-name { display: flex; align-items: center; gap: 6px; color: var(--ink); font-size: 13.5px; font-weight: 600; }
.view-user-item-name > span:first-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.view-user-item-sub { margin-top: 1px; color: var(--muted); font-size: 11.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.view-user-item-badge { flex: none; padding: 1px 6px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-2); font-size: 10.5px; font-weight: 600; }
.view-user-item-check { flex: none; color: var(--green-dark); font-size: 15px; font-weight: 700; }
.view-user-empty { padding: 28px 12px; color: var(--muted); text-align: center; font-size: 12.5px; }
.view-drawer-foot { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 12px; padding-top: 12px; color: var(--muted); font-size: 11px; }
.view-drawer-foot kbd { padding: 1px 5px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; background: #fbfdff; font-family: inherit; font-size: 10.5px; }
body.view-drawer-open { overflow: hidden !important; }
.top-user { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px 4px 4px; border: 1px solid var(--line); border-radius: 999px; background: #fff; }
.top-user-name { font-size: 12.5px; font-weight: 600; max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top-user-badge { padding: 1px 6px; border-radius: 999px; background: #fff6e5; color: #b26a00; font-size: 10.5px; font-weight: 700; }
.view-user-btn .top-user-name { line-height: 1; }

/* ---------- 通用组件 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: 0.15s ease;
  white-space: nowrap;
}
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 8px 18px -12px rgba(22, 119, 255, 0.9); }
.btn-primary:hover { background: var(--green-dark); }
.btn-ghost { background: #fff; border-color: var(--line-strong); color: var(--ink-2); }
.btn-ghost:hover { border-color: var(--green); color: var(--green-dark); }
.btn-danger { background: #fff1f1; border-color: #ffd7d7; color: var(--up); }
.btn-danger:hover { background: #ffe4e4; }
.btn-sm { padding: 5px 11px; font-size: 12px; border-radius: 8px; }
.btn-lg { padding: 11px 22px; font-size: 14px; border-radius: 12px; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
/* 只读页「回到我的」：桌面显示文字，窄屏收成图标，避免顶栏被挤到换行 */
.readonly-back-btn { flex: 0 0 auto; }
.readonly-back-icon { display: none; flex: 0 0 auto; }
.icon-btn {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-2);
  cursor: pointer;
  transition: 0.15s ease;
}
.icon-btn:hover { border-color: var(--green); color: var(--green-dark); }
.link-btn { border: 0; background: none; color: var(--green-dark); font-size: 12px; cursor: pointer; padding: 0; }
.link-btn:hover { text-decoration: underline; }
.pill { display: inline-flex; align-items: center; padding: 2px 8px; border-radius: 999px; font-size: 11px; font-weight: 600; }
.pill-green { background: var(--green-soft); color: var(--green-dark); }
.pill-gray { background: #f1f4fb; color: var(--muted); }
.pill-amber { background: #fff6e5; color: #b26a00; }
.alert { margin: 16px clamp(16px, 4vw, 40px) 0; padding: 11px 14px; border-radius: 12px; font-size: 13px; }
.alert-error { background: #fff0f0; border: 1px solid #ffd2d2; color: #b42424; }

/* ---------- 头像 ---------- */
.avatar {
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--green-soft);
  color: var(--green-dark);
  font-weight: 800;
  font-size: 15px;
  user-select: none;
}
.avatar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
.avatar-sm { width: 28px; height: 28px; font-size: 12px; }
.avatar-lg { width: 56px; height: 56px; font-size: 20px; }
.avatar-xl { width: 74px; height: 74px; font-size: 26px; }

/* ---------- 页面容器 ---------- */
.social-page {
  max-width: 1280px;
  margin: 0 auto;
  padding: 26px clamp(16px, 4vw, 40px) 48px;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* ---------- 未登录首页：行情 ---------- */
.guest-market {
  margin-bottom: 18px;
  padding: 18px 20px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.gm-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; margin-bottom: 14px; }
.gm-head h2 { font-size: 15px; letter-spacing: -0.2px; }
.gm-head .eyebrow { margin-bottom: 3px; }
.gm-head small { color: var(--muted); font-size: 11px; }
.gm-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(152px, 1fr)); gap: 10px; }
.gm-item {
  padding: 11px 13px;
  border-radius: 12px;
  background: #fafbfc;
  border: 1px solid var(--line);
}
.gm-item .gm-name { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--ink-2); }
.gm-item .gm-name em { font-style: normal; color: var(--muted); font-size: 10px; }
.gm-item .gm-value { margin-top: 3px; font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; letter-spacing: -0.3px; }
.gm-item .gm-change { margin-top: 1px; font-size: 11.5px; font-variant-numeric: tabular-nums; }
.gm-item .gm-change.up { color: var(--up); }
.gm-item .gm-change.down { color: var(--down); }
.gm-item .gm-change.flat { color: var(--muted); }
.gm-empty { padding: 14px; border-radius: 10px; background: #fafbfc; border: 1px dashed var(--line-strong); color: var(--muted); font-size: 12px; }
.gm-link { color: var(--green-dark); font-size: 12px; }
.gm-clickable { cursor: pointer; transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease; }
.gm-clickable:hover { background: #fff; border-color: #bcd7ff; transform: translateY(-1px); }
.gm-clickable:focus-visible { outline: 2px solid rgba(22, 119, 255, 0.45); outline-offset: 2px; }
.mk-index { cursor: pointer; }
.mk-index:focus-visible { outline: 2px solid rgba(22, 119, 255, 0.45); outline-offset: 1px; }

/* ---------- 指数日 K 线弹窗 ---------- */
.kline-modal {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.kline-modal[hidden] { display: none; }
.kline-backdrop { position: absolute; inset: 0; background: rgba(16, 24, 40, 0.52); backdrop-filter: blur(2px); }
.kline-panel {
  position: relative;
  z-index: 1;
  width: min(900px, 100%);
  max-height: 88vh;
  overflow: auto;
  padding: 18px 20px 16px;
  border-radius: 20px;
  background: #fff;
  border: 1px solid var(--line);
  box-shadow: 0 30px 70px -30px rgba(16, 24, 40, 0.55);
  animation: qr-modal-in 0.18s ease both;
}
.kline-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; }
.kline-head h2 { display: flex; align-items: baseline; gap: 8px; font-size: 18px; letter-spacing: -0.2px; }
.kline-head h2 span { font-size: 11.5px; font-weight: 500; color: var(--muted); }
.kline-head p { margin-top: 4px; font-size: 11.5px; color: var(--muted); }
.kline-close {
  flex: none;
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: var(--muted);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}
.kline-close:hover { border-color: #bcd7ff; color: var(--brand-2); background: #f5f9ff; }
.kline-toolbar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.kline-summary { display: flex; align-items: baseline; gap: 8px; min-height: 26px; }
.kline-summary b { font-size: 23px; letter-spacing: -0.4px; font-variant-numeric: tabular-nums; }
.kline-summary span { font-size: 12px; font-variant-numeric: tabular-nums; }
.kline-ranges { display: inline-flex; gap: 2px; padding: 3px; border: 1px solid var(--line); border-radius: 10px; background: #f7f9fd; }
.kline-ranges button {
  padding: 5px 10px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  font-size: 11.5px;
  cursor: pointer;
}
.kline-ranges button:hover { color: var(--brand-2); background: #fff; }
.kline-ranges button.is-active { color: var(--brand-2); background: #fff; font-weight: 700; box-shadow: 0 2px 8px rgba(22, 119, 255, 0.12); }
.kline-chart { min-height: 260px; margin-top: 10px; }
.kline-chart svg { display: block; width: 100%; height: auto; }
.kline-state { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 10px; min-height: 240px; padding: 18px; color: var(--muted); font-size: 12.5px; text-align: center; }
.kline-note { margin-top: 8px; color: #9aa8c0; font-size: 10.5px; line-height: 1.6; }
body.kline-open { overflow: hidden; }


/* ---------- 未登录首页 ---------- */
.guest-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(300px, 0.85fr);
  gap: clamp(24px, 3.5vw, 44px);
  align-items: center;
  padding: clamp(26px, 4vw, 54px);
  border-radius: 24px;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.eyebrow { display: inline-block; font-size: 11px; letter-spacing: 2.4px; font-weight: 800; color: var(--green); margin-bottom: 14px; }
.guest-copy h1 { font-size: clamp(30px, 4vw, 46px); line-height: 1.16; letter-spacing: -1px; }
.guest-copy p { margin-top: 16px; max-width: 520px; color: var(--ink-2); font-size: 14.5px; }
.guest-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 26px; }
.guest-actions .muted { font-size: 12px; max-width: 270px; flex-basis: 100%; }
.guest-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.guest-tags span { padding: 5px 11px; border: 1px solid #d6e4ff; border-radius: 999px; background: var(--brand-soft); color: var(--brand-2); font-size: 11.5px; font-weight: 600; }
.btn-text { padding-left: 2px; padding-right: 2px; background: transparent; color: var(--brand-2); }
.btn-text:hover { color: var(--brand); text-decoration: underline; }
/* ---------- 桌面首页：手机版二维码卡片 ---------- */
.qr-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 340px;
  margin-left: auto;
  padding: 24px 22px 20px;
  border-radius: 20px;
  border: 1px solid #dbe7fb;
  background:
    radial-gradient(220px 140px at 50% -10%, rgba(22, 119, 255, 0.12), transparent 70%),
    #fff;
  box-shadow: 0 22px 46px -30px rgba(22, 119, 255, 0.45);
  text-align: center;
}
.qr-card-head .eyebrow { margin-bottom: 6px; }
.qr-card-head h2 { font-size: 18px; letter-spacing: -0.3px; }
.qr-card-head p { margin-top: 6px; font-size: 12px; color: var(--muted); }
.qr-box {
  display: grid;
  place-items: center;
  width: 212px;
  height: 212px;
  padding: 8px;
  overflow: hidden;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #fff;
  box-shadow: inset 0 0 0 6px #f7faff;
}
.qr-box img,
.qr-box canvas { display: block; width: 196px !important; height: 196px !important; }
.qr-placeholder { font-size: 11.5px; color: var(--muted); }
.qr-url {
  max-width: 100%;
  padding: 4px 10px;
  border-radius: 999px;
  background: #f5f8ff;
  color: var(--muted);
  font-size: 10.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.qr-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.qr-tip { font-size: 10.5px; color: #9aa8c0; }

/* ---------- 手机版二维码弹窗 ---------- */
.qr-modal {
  position: fixed;
  inset: 0;
  z-index: 1300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.qr-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(3px);
}
.qr-modal-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: min(380px, calc(100vw - 32px));
  padding: 28px 24px 22px;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 30px 70px -30px rgba(15, 23, 42, 0.55);
  text-align: center;
  animation: qr-modal-in 0.18s ease both;
}
.qr-modal-panel h2 { font-size: 19px; letter-spacing: -0.3px; }
.qr-modal-panel > p { font-size: 12.5px; color: var(--muted); }
.qr-modal-close {
  position: absolute;
  top: 10px;
  right: 12px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: #f2f5fa;
  color: var(--muted);
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
  transition: 0.15s ease;
}
.qr-modal-close:hover { background: #e8eefb; color: var(--ink); }
body.qr-modal-open { overflow: hidden; }
@keyframes qr-modal-in { from { opacity: 0; transform: translateY(8px) scale(0.98); } to { opacity: 1; transform: none; } }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; margin-top: 22px; }
.feature-grid article { padding: 22px; border-radius: var(--radius); background: var(--card); border: 1px solid var(--line); }
.feature-icon { font-size: 12px; font-weight: 800; color: var(--brand); letter-spacing: 1px; }
.feature-grid h3 { margin: 8px 0 6px; font-size: 15px; }
.feature-grid p { font-size: 12.5px; color: var(--muted); }

/* ---------- 未登录首页：Chrome 插件宣传 ---------- */
.extension-promo {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
  gap: 36px;
  align-items: center;
  margin-top: 22px;
  padding: clamp(26px, 4vw, 46px);
  overflow: hidden;
  border-radius: 24px;
  background: linear-gradient(135deg, #0b3d91, #1677ff 58%, #5aa8ff);
  color: #fff;
  box-shadow: 0 26px 64px -34px rgba(22, 119, 255, 0.75);
}
.extension-promo::before {
  content: "";
  position: absolute;
  top: -120px;
  right: -80px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.12);
  pointer-events: none;
}
.extension-promo::after {
  content: "";
  position: absolute;
  bottom: -160px;
  left: 32%;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: rgba(9, 88, 217, 0.28);
  pointer-events: none;
}
.extension-copy, .extension-visual { position: relative; z-index: 1; }
.extension-promo .eyebrow { color: #cfe3ff; }
.extension-promo h2 { font-size: clamp(23px, 3vw, 32px); line-height: 1.25; letter-spacing: -0.5px; }
.extension-promo p { margin-top: 12px; max-width: 560px; color: rgba(255, 255, 255, 0.84); font-size: 13.5px; }
.extension-points { display: flex; flex-wrap: wrap; gap: 8px 10px; margin: 18px 0 0; padding: 0; list-style: none; }
.extension-points li { padding: 4px 9px; border: 1px solid rgba(255, 255, 255, 0.26); border-radius: 999px; background: rgba(255, 255, 255, 0.1); font-size: 11px; }
.extension-promo .guest-actions { margin-top: 22px; }
.extension-promo .btn-primary { background: #fff; color: var(--brand-2); box-shadow: 0 10px 24px -16px rgba(0, 0, 0, 0.55); }
.extension-promo .btn-primary:hover { background: #eef5ff; }
.extension-promo .btn-ghost { border-color: rgba(255, 255, 255, 0.42); background: rgba(255, 255, 255, 0.08); color: #fff; }
.extension-promo .btn-ghost:hover { border-color: #fff; color: #fff; }
.extension-note { margin-top: 16px; padding: 11px 13px; border-radius: 11px; background: rgba(5, 35, 82, 0.24); color: rgba(255, 255, 255, 0.82); font-size: 11.5px; line-height: 1.7; }
.extension-note code { padding: 1px 5px; border-radius: 5px; background: rgba(255, 255, 255, 0.16); color: #fff; font-family: var(--mono, ui-monospace, monospace); font-size: 10.5px; }
.extension-cards { display: flex; justify-content: flex-end; }
.ext-window {
  width: min(350px, 100%);
  padding: 14px;
  border-radius: 18px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 28px 70px -26px rgba(2, 24, 64, 0.72);
  transform: rotate(2deg);
}
.ext-window-head { display: flex; align-items: center; gap: 9px; padding-bottom: 11px; border-bottom: 1px solid var(--line); }
.ext-logo { display: grid; place-items: center; flex: none; width: 34px; height: 34px; border-radius: 11px; background: linear-gradient(135deg, var(--brand-2), var(--brand) 62%, var(--brand-3)); color: #fff; font-size: 16px; font-weight: 800; }
.ext-window-title { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; }
.ext-window-title strong { font-size: 13px; }
.ext-window-title small { margin-top: 2px; color: var(--muted); font-size: 9.5px; }
.ext-connected { margin-left: auto; padding: 2px 7px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-2); font-size: 9.5px; font-weight: 700; white-space: nowrap; }
.ext-tabs { display: flex; gap: 5px; margin: 11px 0 8px; padding: 3px; border-radius: 9px; background: #f3f6fb; }
.ext-tabs span { flex: 1; padding: 5px 0; border-radius: 7px; color: var(--muted); font-size: 10px; text-align: center; }
.ext-tabs .active { background: #fff; color: var(--brand-2); font-weight: 700; box-shadow: 0 2px 7px rgba(22, 119, 255, 0.12); }
.ext-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 2px; border-bottom: 1px solid #f1f4fa; }
.ext-row:last-of-type { border-bottom: 0; }
.ext-row-main { display: flex; flex-direction: column; min-width: 0; }
.ext-row-main strong { font-size: 11px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ext-row-main small { margin-top: 1px; color: var(--muted); font-size: 9px; }
.ext-row em { font-style: normal; font-size: 11px; font-weight: 700; }
.ext-row em.up { color: var(--up); }
.ext-row em.down { color: var(--down); }
.ext-mini-chart { height: 36px; margin: 9px 0; border-radius: 8px; background: linear-gradient(180deg, rgba(22, 119, 255, 0.2), rgba(22, 119, 255, 0)); clip-path: polygon(0 76%, 16% 58%, 33% 66%, 49% 36%, 65% 46%, 82% 20%, 100% 30%, 100% 100%, 0 100%); }
.ext-window-cta { display: block; width: 100%; padding: 7px; border: 0; border-radius: 8px; background: var(--brand); color: #fff; font-size: 10.5px; font-weight: 700; text-align: center; }

/* ---------- 登录后资料卡 ---------- */
.profile-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px;
  border-radius: var(--radius);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}
.profile-main { flex: 1; min-width: 0; }
.profile-title { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; }
.profile-title h1 { font-size: 22px; letter-spacing: -0.4px; }
.username { color: var(--muted); font-size: 13px; }
.profile-meta { color: var(--muted); font-size: 12.5px; margin-top: 4px; }
.profile-stats { display: flex; gap: 22px; text-align: center; }
.profile-stats div { display: flex; flex-direction: column; }
.profile-stats strong { font-size: 20px; font-variant-numeric: tabular-nums; }
.profile-stats span { font-size: 11px; color: var(--muted); }


/* ---------- 主体布局 ---------- */
.layout { display: grid; grid-template-columns: 340px minmax(0, 1fr); gap: 18px; margin-top: 18px; align-items: start; }
.community { padding: 16px; position: sticky; top: 78px; max-height: calc(100vh - 100px); display: flex; flex-direction: column; }
.card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.card-head h2 { font-size: 15px; }
.search-row { display: flex; gap: 8px; margin: 12px 0; }
.search-row input {
  flex: 1;
  min-width: 0;
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: #fbfdff;
  font-size: 12.5px;
  outline: none;
}
.search-row input:focus { border-color: var(--brand-3); background: #fff; box-shadow: 0 0 0 3px rgba(22, 119, 255, 0.11); }
.user-list { overflow: auto; margin: 0 -6px; padding: 0 6px; }
.user-item {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  padding: 10px;
  border: 1px solid transparent;
  border-radius: 12px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: 0.15s ease;
}
.user-item:hover { background: #f6faff; border-color: var(--line); }
.user-item.active { background: var(--brand-soft); border-color: rgba(22, 119, 255, 0.25); }
.user-item .avatar { cursor: pointer; }
.user-item-main { flex: 1; min-width: 0; }
.user-item-name { display: flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; }
.user-item-name span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.user-item-sub { display: flex; gap: 8px; color: var(--muted); font-size: 11px; margin-top: 2px; }
.user-item-side { text-align: right; flex: 0 0 auto; }
.user-item-side strong { display: block; font-size: 13px; color: var(--green-dark); font-variant-numeric: tabular-nums; }
.user-item-side small { font-size: 10px; color: var(--muted); }
.state, .empty-mini { padding: 24px 10px; text-align: center; color: var(--muted); font-size: 12.5px; }

/* ---------- 通知 ---------- */
.bell-wrap { position: relative; }
.bell-btn { position: relative; }
.bell-badge {
  position: absolute;
  top: -5px;
  right: -5px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--up);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: grid;
  place-items: center;
  border: 2px solid #fff;
}
.notif-panel {
  position: absolute;
  right: 0;
  top: 44px;
  width: 340px;
  max-height: 430px;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(29, 33, 41, 0.16);
  z-index: 40;
  overflow: hidden;
}
.notif-head { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.notif-head strong { font-size: 13px; }
.notif-list { overflow: auto; }
.notif-item { display: flex; gap: 10px; padding: 11px 14px; border-bottom: 1px solid #f2f6fc; }
.notif-item:last-child { border-bottom: 0; }
.notif-item.unread { background: #f7f8fa; }
.notif-item-body { min-width: 0; }
.notif-item-title { font-size: 12.5px; font-weight: 600; }
.notif-item-text { font-size: 11.5px; color: var(--muted); word-break: break-word; }
.notif-item-time { font-size: 10.5px; color: #9aa8c0; margin-top: 2px; }

/* ---------- 用户详情 ---------- */
.detail { min-width: 0; }
.empty-detail { padding: 70px 24px; text-align: center; }
.empty-detail .empty-icon { font-size: 34px; }
.empty-detail h2 { margin: 10px 0 6px; font-size: 18px; }
.empty-detail p { color: var(--muted); font-size: 13px; }
.detail-card { padding: 20px; }
.detail-head { display: flex; align-items: center; gap: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.detail-head-main { flex: 1; min-width: 0; }
.detail-name { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.detail-name h2 { font-size: 20px; letter-spacing: -0.3px; }
.detail-sub { color: var(--muted); font-size: 12px; margin-top: 3px; }
.detail-side { display: flex; gap: 18px; text-align: center; }
.detail-side div { display: flex; flex-direction: column; }
.detail-side strong { font-size: 17px; }
.detail-side span { font-size: 10.5px; color: var(--muted); }
.detail-tabs { display: flex; gap: 6px; margin: 14px 0; padding: 4px; border-radius: 12px; background: #f2f3f5; width: fit-content; }
.tab-btn { border: 0; background: transparent; padding: 7px 16px; border-radius: 9px; font-size: 12.5px; font-weight: 600; color: var(--muted); cursor: pointer; }
.tab-btn.active { background: #fff; color: var(--green-dark); box-shadow: 0 2px 8px rgba(29, 33, 41, 0.08); }
.tab-count { display: inline-block; margin-left: 5px; font-size: 10.5px; color: var(--muted); }
.readonly-note { display: flex; align-items: center; gap: 7px; margin: 0 0 12px; padding: 8px 11px; border-radius: 9px; background: #fff8e9; color: #916000; font-size: 11.5px; }
.view-banner {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  /* margin: 14px 0 0; */
  margin: -12px 0 12px 0;
  padding: 14px 18px;
  border: 1px solid #f0d9a8;
  border-radius: var(--radius);
  background: #fffaf0;
  color: #7a5200;
}
.view-banner-icon { font-size: 20px; line-height: 1.2; }
.view-banner strong { display: block; font-size: 14px; color: #6b4700; }
.view-banner p { margin-top: 3px; font-size: 12px; color: #916a1a; }


/* ---------- 表格 ---------- */
.table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 12px; }
table.data { width: 100%; border-collapse: collapse; font-size: 12.5px; min-width: 640px; }
table.data th, table.data td { padding: 9px 11px; border-bottom: 1px solid #f0f1f3; text-align: right; white-space: nowrap; }
table.data th:first-child, table.data td:first-child { text-align: left; }
table.data th { position: sticky; top: 0; background: #f7f8fa; color: var(--muted); font-weight: 600; font-size: 11px; }
table.data tbody tr:hover { background: #fafbfc; }
table.data tbody tr:last-child td { border-bottom: 0; }
.cell-name { display: flex; flex-direction: column; gap: 1px; text-align: left; }
.cell-name strong { font-size: 12.5px; font-weight: 600; }
.cell-name small { color: var(--muted); font-size: 10.5px; }
.kind-tag { display: inline-block; padding: 1px 6px; border-radius: 5px; font-size: 10px; background: #f0f1f3; color: var(--muted); margin-right: 5px; }
.kind-tag.stock { background: #f0f1f3; color: #3867c8; }
.time-note { display: block; font-size: 9.5px; color: #9aa8c0; font-weight: 400; }
.table-actions { display: inline-flex; gap: 5px; }
.icon-mini { border: 1px solid var(--line); background: #fff; color: var(--muted); border-radius: 7px; padding: 2px 8px; font-size: 11px; cursor: pointer; }
.icon-mini:hover { color: var(--up); border-color: #ffc9c9; background: #fff6f6; }

/* ---------- 汇总 ---------- */
.summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-bottom: 13px; }
.summary-grid div { padding: 11px 13px; border-radius: 11px; background: #f7f8fa; border: 1px solid var(--line); }
.summary-grid span { display: block; font-size: 10.5px; color: var(--muted); }
.summary-grid strong { display: block; font-size: 16px; margin-top: 2px; font-variant-numeric: tabular-nums; }

/* ---------- 表单 ---------- */
.inline-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; margin-bottom: 13px; padding: 12px; border-radius: 12px; background: #f7f8fa; border: 1px dashed var(--line-strong); }
.inline-form label { display: flex; flex-direction: column; gap: 3px; font-size: 10.5px; color: var(--muted); }
.inline-form input, .inline-form select {
  height: 33px;
  padding: 0 10px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: #fff;
  font-size: 12.5px;
  outline: none;
  width: 120px;
}
.inline-form input:focus, .inline-form select:focus { border-color: var(--brand-3); box-shadow: 0 0 0 3px rgba(22, 119, 255, 0.11); }
.inline-form input.code { width: 110px; }
.inline-form input.wide { width: 170px; }
.inline-form .form-title { font-size: 11.5px; font-weight: 700; color: var(--ink-2); margin-right: auto; width: 100%; }

/* ---------- Toast ---------- */
.toast-root { position: fixed; top: 78px; right: 22px; z-index: 90; display: flex; flex-direction: column; gap: 8px; }
.toast {
  padding: 10px 15px;
  border-radius: 10px;
  background: var(--ink);
  color: #fff;
  font-size: 12.5px;
  box-shadow: 0 12px 30px rgba(29, 33, 41, 0.22);
  animation: toast-in 0.2s ease;
}
.toast.error { background: #b42424; }
.toast.success { background: #0e5cd8; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }

/* ---------- 响应式 ---------- */
@media (max-width: 960px) {
  /* 根页面顶栏：品牌与操作同行，行情条独占一行横向滚动，避免手机端溢出 */
  .topbar.social-topbar { flex-wrap: wrap; row-gap: 8px; padding-bottom: 8px; }
  .topbar.social-topbar .topbar-market {
    order: 3;
    flex: 1 0 100%;
    justify-content: flex-start;
    padding: 2px;
  }
  .topbar.social-topbar .top-actions { margin-left: auto; }
  /* 窄屏只保留箭头图标，保证顶栏一行放下 */
  .readonly-back-btn {
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: 50%;
  }
  .readonly-back-icon { display: block; }
  .readonly-back-text { display: none; }
  .guest-hero { grid-template-columns: 1fr; }
  .qr-card { max-width: 100%; margin: 4px auto 0; }
  .feature-grid { grid-template-columns: 1fr; }
  .extension-promo { grid-template-columns: 1fr; gap: 28px; }
  .extension-cards { justify-content: flex-start; }
  .ext-window { width: min(420px, 100%); transform: none; }
  .layout { grid-template-columns: 1fr; }
  .community { position: static; max-height: none; }
  .user-list { max-height: 320px; }
  .summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .topbar.social-topbar .topbar-hide-sm { display: none; }
  .brand-text small { display: none; }
  .top-user-name { display: none; }
  .top-actions { gap: 6px; }
  .top-actions .btn { padding-left: 10px; padding-right: 10px; }
  /* 手机上二维码入口冗余，且会挤压「回到我的」等按钮 */
  .topbar.social-topbar #qr-open { display: none; }
  .view-user-btn,
  .top-user-btn { padding: 3px 8px 3px 4px !important; }
  .view-user-btn .top-user-caret,
  .top-user-btn .top-user-caret { display: none; }
  .guest-market { padding: 14px; }
  .gm-head { flex-wrap: wrap; }
  .gm-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .gm-item .gm-value { font-size: 16px; }
  .qr-card { padding: 20px 16px 16px; }
  .qr-box { width: 196px; height: 196px; }
  .qr-box img, .qr-box canvas { width: 180px !important; height: 180px !important; }
  .qr-modal { padding: 12px; }
  .qr-modal-panel { padding: 26px 18px 18px; border-radius: 18px; }
  .kline-modal { padding: 0; align-items: flex-end; }
  .kline-panel { width: 100%; max-height: 92vh; padding: 16px 14px calc(14px + env(safe-area-inset-bottom)); border-radius: 18px 18px 0 0; }
  .kline-head h2 { font-size: 16.5px; }
  .kline-summary b { font-size: 20px; }
  .kline-ranges { width: 100%; justify-content: space-between; }
  .kline-ranges button { flex: 1; }
  .kline-chart { min-height: 230px; }
  .view-drawer { padding: 12px; }
  .view-drawer-panel { width: calc(100vw - 24px); max-height: 86vh; padding: 16px; border-radius: 16px; }

  .view-user-item { padding: 11px 10px; }
  .profile-card { flex-wrap: wrap; }
  .profile-stats { width: 100%; justify-content: space-around; }
  .detail-head { flex-wrap: wrap; }
  .detail-side { width: 100%; justify-content: space-around; }
  .notif-panel { width: calc(100vw - 32px); right: -8px; }
  .inline-form input, .inline-form select { width: 100%; }
  .inline-form label { flex: 1 1 45%; }
}

.footer { text-align: center; color: #8a9bb8; font-size: 12px; padding: 10px 16px 30px; }
.footer a { color: var(--brand-2); }

/* ---------- 功能模块：社区 / 我的 ---------- */
.module-nav {
  display: flex;
  gap: 8px;
  margin-top: 14px;
  padding: 6px;
  width: fit-content;
  border-radius: 16px;
  background: #f2f3f5;
  border: 1px solid var(--line);
}
.module-btn {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 18px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.16s ease, box-shadow 0.16s ease;
}
.module-btn > span:last-child { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; }
.module-btn strong { font-size: 13px; color: var(--ink-2); }
.module-btn small { font-size: 10px; color: var(--muted); }
.module-ico { font-size: 17px; line-height: 1; }
.module-btn:hover { background: rgba(255, 255, 255, 0.7); }
.module-btn.active { background: #fff; box-shadow: 0 3px 12px rgba(29, 33, 41, 0.1); }
.module-btn.active strong { color: var(--green-dark); }
.module-panel { margin-top: 14px; }
.module-panel .layout { margin-top: 0; }
.module-panel[hidden] { display: none; }

.mine-card { padding: 20px; }
.mine-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}
.mine-head-main { min-width: 0; }
.mine-head h2 { font-size: 19px; letter-spacing: -0.3px; }
.mine-head p { margin-top: 4px; }
.mine-stats { flex: 0 0 auto; }

/* ---------- 名称搜索联想 ---------- */
.inline-form .pick-hint {
  flex: 0 0 100%;
  font-size: 11px;
  color: var(--green-dark);
  padding: 2px 2px 0;
}
.inline-form .pick-hint[hidden] { display: none; }
.inline-form .suggest-list {
  flex: 0 0 100%;
  border: 1px solid var(--line-strong);
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 12px 26px rgba(29, 33, 41, 0.12);
  max-height: 260px;
  overflow: auto;
}
.inline-form .suggest-list[hidden] { display: none; }
.suggest-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 8px 12px;
  border: 0;
  border-bottom: 1px solid #f0f1f3;
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.suggest-item:last-child { border-bottom: 0; }
.suggest-item:hover { background: #f5f6f8; }
.suggest-item > span { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.suggest-item strong { font-size: 12.5px; font-weight: 600; color: var(--ink); }
.suggest-item small { font-size: 10.5px; color: var(--muted); }
.suggest-item em {
  flex: 0 0 auto;
  font-style: normal;
  font-size: 10px;
  color: var(--green-dark);
  background: var(--green-soft);
  border-radius: 5px;
  padding: 2px 7px;
}
.suggest-empty { padding: 10px 12px; font-size: 11.5px; color: var(--muted); }
.inline-form input.wide { width: 220px; }

/* ---------- 我的：完整账本由 social 首页 直接嵌入 ---------- */

@media (max-width: 640px) {
  .module-nav { width: 100%; }
  .module-btn { flex: 1; justify-content: center; padding: 8px 10px; }
  .module-btn small { display: none; }
  .mine-head { flex-wrap: wrap; }
  .mine-stats { width: 100%; justify-content: space-around; }
  .inline-form input.wide { width: 100%; }
}

/*
 * 平板 / 手机顶栏：登录按钮、手机版、图标按钮和用户胶囊统一高度。
 * 桌面端保留按钮大小差异（主按钮更醒目）；窄屏下高度不齐会显得凌乱。
 */
@media (max-width: 960px) {
  .topbar.social-topbar .top-actions .btn:not(.readonly-back-btn) {
    height: 34px;
    padding: 0 12px;
    border-radius: 9px;
    font-size: 12.5px;
    line-height: 1;
  }
  .topbar.social-topbar .top-user {
    height: 34px;
    padding: 2px 8px 2px 3px !important;
  }
}
