/* ============================================================
   微信客服工作台 - 科技风深色主题
   ============================================================ */
:root {
  --bg: #0a0e1a;
  --bg2: #0f1525;
  --panel: rgba(255,255,255,0.04);
  --panel-border: rgba(255,255,255,0.08);
  --panel-hover: rgba(255,255,255,0.07);
  --ink: #e8ecf4;
  --muted: #6b7a94;
  --line: rgba(255,255,255,0.06);
  --accent: #00d4ff;
  --accent2: #7c3aed;
  --accent-grad: linear-gradient(135deg, #00d4ff, #7c3aed);
  --danger: #ff4757;
  --success: #00e676;
  --online: #00e676;
  --glow: 0 0 20px rgba(0,212,255,0.15);
  --radius: 16px;
  --radius-sm: 12px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.5;
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, textarea, select { font-family: inherit; font-size: 14px; color: var(--ink); }
a { color: var(--accent); text-decoration: none; }

/* 滚动条 */
::-webkit-scrollbar { width: 5px; height: 5px; }
::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.1); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255,255,255,0.2); }
::-webkit-scrollbar-track { background: transparent; }

/* ============================================================
   整体布局
   ============================================================ */
body {
  display: flex;
  height: 100vh;
  width: 100vw;
}

/* ---------- 左侧导航 ---------- */
.sidenav {
  width: 72px;
  background: linear-gradient(180deg, #0d1222, #0a0e1a);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  z-index: 40;
}
.sidenav-brand {
  display: flex; align-items: center; gap: 12px;
  padding: 20px 14px;
}
.brand-icon {
  width: 40px; height: 40px;
  border-radius: 12px;
  background: var(--accent-grad);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; flex-shrink: 0;
  box-shadow: 0 0 20px rgba(0,212,255,0.3);
}
.brand-text { display: none; }
.brand-title { color: #fff; font-weight: 700; font-size: 15px; }
.brand-sub { color: var(--muted); font-size: 12px; margin-top: 2px; }
.sidenav-close { display: none; }

.sidenav-nav { flex: 1; display: flex; flex-direction: column; gap: 4px; padding: 10px; }
.nav-item {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 8px;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 14px;
  transition: all .2s;
}
.nav-item i { font-size: 20px; }
.nav-item:hover { background: var(--panel-hover); color: var(--ink); }
.nav-item.active { background: rgba(0,212,255,0.12); color: var(--accent); box-shadow: inset 0 0 20px rgba(0,212,255,0.05); }
.nav-item span { display: none; }

.sidenav-footer { padding: 14px 10px; border-top: 1px solid var(--line); }

/* ---------- 会话列表 ---------- */
.conv-list {
  width: 360px;
  background: var(--bg2);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  z-index: 20;
}
.conv-header {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 18px 8px;
}
.conv-header-titles { flex: 1; }
.conv-title { font-size: 18px; font-weight: 700; color: var(--ink); }
.conv-subtitle { font-size: 12px; color: var(--muted); margin-top: 2px; }

.icon-btn {
  width: 38px; height: 38px;
  border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 18px;
  color: var(--ink);
  background: transparent;
  transition: all .15s;
  position: relative;
}
.icon-btn:hover { background: var(--panel-hover); }
.hamburger { display: none; }

.bell { position: relative; }
.badge {
  position: absolute; top: 2px; right: 2px;
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px;
  background: var(--danger); color: #fff;
  font-size: 11px; font-weight: 600;
  display: flex; align-items: center; justify-content: center;
}

.conv-section-label { padding: 14px 18px 8px; }
.eyebrow { font-size: 11px; letter-spacing: 2px; color: var(--muted); text-transform: uppercase; font-weight: 600; }
.section-title { font-size: 24px; font-weight: 800; color: var(--ink); margin-top: 2px; }

.search-box {
  margin: 6px 18px 12px;
  display: flex; align-items: center; gap: 8px;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}
.search-box i { color: var(--muted); font-size: 16px; }
.search-box input { flex: 1; border: none; outline: none; background: transparent; color: var(--ink); }
.search-box input::placeholder { color: var(--muted); }

.user-list { flex: 1; overflow-y: auto; padding: 4px 10px; }
.user-card {
  display: flex; align-items: center; gap: 12px;
  padding: 12px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all .15s;
  margin-bottom: 4px;
}
.user-card:hover { background: var(--panel-hover); }
.user-card.active { background: rgba(0,212,255,0.08); border-left: 3px solid var(--accent); }
.u-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  background: linear-gradient(135deg, rgba(0,212,255,0.2), rgba(124,58,237,0.2));
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 16px; flex-shrink: 0;
  overflow: visible;
  position: relative;
}
.u-avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.u-avatar::after {
  content: ''; position: absolute; bottom: 0; right: 0;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--success); border: 2px solid var(--bg2);
}
.u-info { flex: 1; min-width: 0; }
.u-name { font-weight: 600; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.u-preview { font-size: 12px; color: var(--muted); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.u-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; flex-shrink: 0; }
.u-time { font-size: 11px; color: var(--muted); }
.u-unread {
  min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px; background: var(--danger); color: #fff;
  font-size: 11px; font-weight: 600;
  display: flex; align-items: center; justify-content: center;
}

.conv-footer {
  padding: 12px 18px;
  border-top: 1px solid var(--line);
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; color: var(--muted);
}
.online-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--online); box-shadow: 0 0 6px var(--online); }
.empty-tip { text-align: center; color: var(--muted); padding: 40px 0; font-size: 13px; }

/* ---------- 主内容区 ---------- */
.main {
  flex: 1;
  background: var(--bg);
  background-image: radial-gradient(ellipse at top, rgba(0,212,255,0.03) 0%, transparent 60%);
  display: flex;
  flex-direction: column;
  min-width: 0;
  position: relative;
}
.view { flex: 1; display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.view[hidden], [hidden] { display: none !important; }

/* ---------- 聊天视图 ---------- */
.chat-header {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 18px;
  background: var(--bg2);
  border-bottom: 1px solid var(--line);
  flex-shrink: 0;
}
.chat-user-avatar {
  width: 38px; height: 38px; border-radius: 50%;
  background: linear-gradient(135deg, rgba(0,212,255,0.2), rgba(124,58,237,0.2));
  color: var(--accent);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; overflow: hidden;
}
.chat-user-name { flex: 1; font-weight: 600; font-size: 15px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-header-actions { display: flex; gap: 4px; }
.back-btn { display: none; }

.messages { flex: 1; overflow-y: auto; padding: 20px 24px; }
.chat-empty { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--muted); gap: 10px; }
.chat-empty i { font-size: 42px; opacity: .3; }

.date-divider { text-align: center; margin: 16px 0; }
.date-divider span { background: rgba(255,255,255,0.06); color: var(--muted); font-size: 12px; padding: 4px 12px; border-radius: 12px; }

.msg-row { display: flex; margin-bottom: 14px; gap: 10px; align-items: flex-start; }
.msg-row.me { flex-direction: row-reverse; }
.msg-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px; overflow: hidden;
}
.msg-avatar.cust { background: rgba(0,212,255,0.15); color: var(--accent); }
.msg-avatar.agent { background: rgba(124,58,237,0.15); color: #a78bfa; }
.msg-bubble-wrap { display: flex; flex-direction: column; max-width: 65%; }
.msg-row.me .msg-bubble-wrap { align-items: flex-end; }
.msg-bubble {
  padding: 10px 14px;
  border-radius: 16px;
  font-size: 14px;
  word-break: break-word;
  white-space: pre-wrap;
  line-height: 1.5;
}
.msg-row.cust .msg-bubble {
  background: var(--panel); color: var(--ink);
  border: 1px solid var(--panel-border);
  border-top-left-radius: 4px;
}
.msg-row.me .msg-bubble {
  background: var(--accent-grad); color: #fff;
  border-top-right-radius: 4px;
  box-shadow: 0 4px 16px rgba(0,212,255,0.2);
}
.msg-bubble.media img, .msg-bubble.media video { max-width: 260px; max-height: 260px; border-radius: 8px; display: block; }
.msg-time { font-size: 11px; color: var(--muted); margin-top: 4px; }

/* ---------- 输入区 ---------- */
.composer {
  border-top: 1px solid var(--line);
  background: var(--bg2);
  padding: 10px 16px 14px;
  flex-shrink: 0;
}
.composer-toolbar { display: flex; gap: 10px; margin-bottom: 10px; transition: all .2s; }
.composer-toolbar[hidden] { display: none; }
.tool-card {
  flex: 1;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  padding: 14px 0;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 14px;
  color: var(--muted);
  font-size: 12px;
  transition: all .15s;
}
.tool-card i { font-size: 22px; }
.tool-card:hover { background: var(--panel-hover); color: var(--accent); border-color: var(--accent); }
.composer-row { display: flex; gap: 10px; align-items: flex-end; }
.composer-row textarea {
  flex: 1;
  border: 1px solid var(--panel-border);
  background: var(--panel);
  border-radius: 14px;
  padding: 12px 16px;
  resize: none;
  max-height: 120px;
  outline: none;
  line-height: 1.5;
  color: var(--ink);
  transition: border-color .15s;
}
.composer-row textarea:focus { border-color: var(--accent); }
.composer-row textarea::placeholder { color: var(--muted); }
.plus-btn {
  width: 46px; height: 46px; border-radius: 14px;
  background: var(--panel); border: 1px solid var(--panel-border);
  color: var(--muted); font-size: 22px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all .2s;
}
.plus-btn.active { transform: rotate(45deg); color: var(--accent); border-color: var(--accent); }
.send-btn {
  width: 46px; height: 46px; border-radius: 14px;
  background: var(--accent-grad); color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 18px; flex-shrink: 0;
  transition: all .15s;
  box-shadow: 0 4px 16px rgba(0,212,255,0.3);
}
.send-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(0,212,255,0.4); }
.send-btn:active { transform: scale(.95); }

/* 话术底部弹层 */
.quick-sheet {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: var(--bg2);
  border-radius: 20px 20px 0 0;
  box-shadow: 0 -4px 30px rgba(0,0,0,.4);
  max-height: 50vh;
  display: flex; flex-direction: column;
  z-index: 30; overflow: hidden;
  animation: slideUp .2s ease;
}
@keyframes slideUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
.quick-sheet[hidden] { display: none !important; }
.quick-sheet-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 20px; font-weight: 600; font-size: 16px; color: var(--ink);
  border-bottom: 1px solid var(--line);
}
.quick-sheet-close { background: none; border: none; color: var(--muted); font-size: 18px; cursor: pointer; }
.quick-search {
  display: flex; align-items: center; gap: 8px;
  margin: 12px 16px; padding: 10px 14px;
  background: var(--panel); border: 1px solid var(--panel-border);
  border-radius: 12px;
}
.quick-search i { color: var(--muted); }
.quick-search input {
  flex: 1; background: none; border: none; outline: none;
  color: var(--ink); font-size: 14px;
}
.quick-list { overflow-y: auto; flex: 1; padding: 8px; -webkit-overflow-scrolling: touch; }
.quick-item { padding: 12px 14px; cursor: pointer; font-size: 14px; color: var(--ink); border-radius: 10px; margin-bottom: 4px; transition: all .15s; line-height: 1.5; }
.quick-item:hover, .quick-item:active { background: rgba(0,212,255,0.12); color: var(--accent); }

/* 表情面板 */
.emoji-panel {
  position: absolute; bottom: 76px; left: 50%; transform: translateX(-50%);
  background: var(--bg2); border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  box-shadow: 0 8px 30px rgba(0,0,0,.4);
  width: 340px; max-width: calc(100vw - 32px); z-index: 30; overflow: hidden;
}
.emoji-panel[hidden] { display: none !important; }
#emojiGrid {
  display: grid; grid-template-columns: repeat(8, 1fr);
  gap: 2px; padding: 12px;
  max-height: 220px; overflow-y: auto; overflow-x: hidden;
}
#emojiGrid button {
  font-size: 22px; padding: 6px; border-radius: 8px;
  background: none; border: none; cursor: pointer;
}
#emojiGrid button:hover { background: var(--panel-hover); }

/* 加号菜单 */
.plus-panel {
  position: absolute; bottom: 90px; right: 16px;
  background: var(--bg2); border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  box-shadow: 0 8px 30px rgba(0,0,0,.4);
  padding: 8px; z-index: 30;
  display: flex; gap: 4px;
}
.plus-panel[hidden] { display: none !important; }
.plus-item {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 12px; border-radius: 10px;
  background: none; border: none; color: var(--ink);
  font-size: 12px; cursor: pointer;
}
.plus-item i { font-size: 24px; color: var(--accent); }
.plus-item:hover { background: var(--panel-hover); }

/* ============================================================
   设置视图
   ============================================================ */
.settings-view { padding: 20px 28px; overflow-y: auto; }
.settings-header { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 16px; }
.settings-desc { color: var(--muted); margin-top: 6px; }

.settings-tabs {
  display: flex; flex-wrap: wrap; gap: 8px;
  padding-bottom: 12px; border-bottom: 1px solid var(--line);
  margin-bottom: 20px;
}
.tab-btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 16px; border-radius: var(--radius-sm);
  white-space: nowrap;
  color: var(--muted); font-size: 14px;
  transition: all .15s;
  border: 1px solid transparent;
}
.tab-btn i { font-size: 16px; }
.tab-btn:hover { background: var(--panel-hover); color: var(--ink); }
.tab-btn.active { background: rgba(0,212,255,0.12); color: var(--accent); border-color: rgba(0,212,255,0.2); }

.settings-card {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
  max-width: 720px;
}
.card-title { font-size: 18px; font-weight: 700; color: var(--ink); }
.card-desc { color: var(--muted); margin-top: 6px; font-size: 13px; }

.field { display: block; margin-top: 16px; }
.field > span { display: block; font-size: 13px; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.field input, .field textarea, .field select {
  width: 100%;
  border: 1px solid var(--panel-border);
  border-radius: var(--radius-sm);
  padding: 11px 14px;
  background: rgba(255,255,255,0.03);
  color: var(--ink);
  outline: none;
  transition: border-color .15s;
}
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); }
.field input::placeholder, .field textarea::placeholder { color: var(--muted); }
.field textarea { resize: vertical; min-height: 80px; }
.hint { font-size: 12px; color: var(--muted); margin-top: 6px; }
.divider { border: none; border-top: 1px solid var(--line); margin: 20px 0; }

/* 按钮 */
.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--accent-grad); color: #fff;
  padding: 11px 20px; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 500;
  transition: all .15s;
  box-shadow: 0 4px 16px rgba(0,212,255,0.25);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(0,212,255,0.35); }
.btn-primary:active { transform: scale(.98); }
.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--panel); color: var(--ink);
  border: 1px solid var(--panel-border);
  padding: 10px 16px; border-radius: var(--radius-sm);
  font-size: 14px;
  transition: all .15s;
}
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }
.mt-md { margin-top: 16px; }

/* 开关 */
.switch-row { display: flex; align-items: center; justify-content: space-between; padding: 12px 0; }
.switch { position: relative; display: inline-block; width: 46px; height: 26px; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider { position: absolute; inset: 0; cursor: pointer; background: rgba(255,255,255,0.1); border-radius: 26px; transition: .2s; }
.switch .slider::before { content: ''; position: absolute; width: 20px; height: 20px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .2s; box-shadow: 0 2px 4px rgba(0,0,0,.2); }
.switch input:checked + .slider { background: var(--success); }
.switch input:checked + .slider::before { transform: translateX(20px); }

/* 话术编辑 */
.quick-edit-item, .kw-item { border: 1px solid var(--panel-border); border-radius: var(--radius-sm); padding: 12px; margin-bottom: 10px; }
.quick-edit-item textarea, .kw-item input { width: 100%; border: 1px solid var(--panel-border); border-radius: 8px; padding: 8px 10px; outline: none; resize: vertical; background: rgba(255,255,255,0.03); color: var(--ink); }
.item-actions { display: flex; justify-content: flex-end; gap: 6px; margin-top: 8px; }
.mini-btn { padding: 5px 10px; border-radius: 8px; font-size: 12px; border: 1px solid var(--panel-border); color: var(--muted); }
.mini-btn:hover { color: var(--accent); border-color: var(--accent); }
.mini-btn.danger:hover { color: var(--danger); border-color: var(--danger); }

/* 二维码 */
.qr-frame { display: flex; justify-content: center; margin: 16px 0; }
.qr-inner { background: #fff; padding: 16px; border-radius: var(--radius); display: inline-block; }
.qr-inner canvas { display: block; }
.link { display: inline-flex; align-items: center; gap: 4px; margin-top: 12px; font-size: 13px; }

/* 头像上传 */
.avatar-row { display: flex; align-items: center; gap: 14px; margin-top: 16px; }
.avatar-preview { width: 56px; height: 56px; border-radius: 14px; background: var(--panel-hover); color: var(--accent); display: flex; align-items: center; justify-content: center; font-size: 20px; font-weight: 700; overflow: hidden; flex-shrink: 0; }
.avatar-preview img { width: 100%; height: 100%; object-fit: cover; }

/* 客服管理 */
.agent-admin-row, .domain-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.agent-admin-row:last-child, .domain-row:last-child { border-bottom: none; }
.agent-admin-row .grow, .domain-row .grow { flex: 1; min-width: 0; }
.domain-row .current-tag { color: var(--accent); font-weight: 600; }

/* Toast */
.toast {
  position: fixed; bottom: 40px; left: 50%; transform: translateX(-50%) translateY(20px);
  background: rgba(15,21,37,0.95); backdrop-filter: blur(10px);
  border: 1px solid var(--panel-border);
  color: #fff; padding: 10px 20px; border-radius: 20px;
  font-size: 13px; opacity: 0; pointer-events: none;
  transition: all .25s; z-index: 99;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* 遮罩 */
.overlay { position: fixed; inset: 0; background: rgba(0,0,0,.5); opacity: 0; pointer-events: none; transition: opacity .2s; z-index: 35; }
.overlay.show { opacity: 1; pointer-events: auto; }

/* ============================================================
   移动端
   ============================================================ */
@media (max-width: 720px) {
  .sidenav { position: fixed; top: 0; left: 0; bottom: 0; width: 260px; transform: translateX(-100%); transition: transform .25s ease; box-shadow: 4px 0 20px rgba(0,0,0,.4); }
  .sidenav.open { transform: translateX(0); }
  .sidenav.open .brand-text { display: block; }
  .sidenav.open .nav-item { justify-content: flex-start; padding: 12px 16px; }
  .sidenav.open .nav-item span { display: inline; }
  .sidenav-close { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 10px; background: var(--panel-hover); color: #fff; margin-left: auto; }
  .conv-list { width: 100%; border-right: none; }
  .hamburger { display: inline-flex; }
  .main { display: none; }
  body.chatting .conv-list { display: none; }
  body.chatting .main { display: flex; }
  body.settings-open .conv-list { display: none; }
  body.settings-open .main { display: flex; }
  .back-btn { display: inline-flex; }
  .settings-view { padding: 16px; }
  .settings-card { padding: 18px; }
  .messages { padding: 16px; }
  .msg-bubble-wrap { max-width: 78%; }
}

@media (min-width: 721px) {
  .back-btn { display: none; }
}

/* 状态徽章 */
.badge { display: inline-block; padding: 4px 12px; border-radius: 20px; font-size: 13px; font-weight: 600; }
.badge-ok { background: rgba(0,230,118,0.15); color: var(--success); }
.badge-warn { background: rgba(255,193,7,0.15); color: #ffc107; }

/* 连接状态徽章 */
.conn-badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 12px; border-radius: 20px;
  font-size: 12px; font-weight: 600;
  background: rgba(255,193,7,0.12); color: #ffc107;
  white-space: nowrap; flex-shrink: 0;
}
.conn-badge.connected { background: rgba(0,230,118,0.12); color: var(--success); }
.conn-dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; animation: pulse 2s infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .4; } }
.wechat-qr-area { text-align: center; padding: 10px 0; }
.wechat-qr-area .qr-frame { margin: 16px auto; }
.wechat-qr-area #wechatQrHint { margin-top: 12px; }

/* 自定义弹窗 */
.modal-overlay {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(0,0,0,.6); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.modal-overlay[hidden] { display: none !important; }
.modal-box {
  background: #0f1525;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 16px;
  padding: 24px;
  width: 100%; max-width: 360px;
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
}
.modal-title { font-size: 18px; font-weight: 700; color: #e8ecf4; margin-bottom: 12px; }
.modal-body { font-size: 14px; color: #6b7a94; margin-bottom: 16px; }
.modal-input {
  width: 100%;
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 10px;
  padding: 11px 14px;
  background: rgba(255,255,255,0.05);
  color: #e8ecf4;
  outline: none;
  font-size: 14px;
  margin-bottom: 16px;
}
.modal-input:focus { border-color: #00d4ff; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; }
