/* ===== 群汇 · 全局样式 ===== */
:root {
  --brand-900: #0b3d36;
  --brand-800: #0d4f46;
  --brand-700: #0f766e;
  --brand-600: #0d9488;
  --brand-500: #14b8a6;
  --mint: #eef7f3;
  --mint-strong: #d9eee6;
  --bg: #f4f7f6;
  --card: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --line: #e7efec;
  --amber: #b45309;
  --danger: #b91c1c;
  --shadow: 0 14px 34px rgba(11, 61, 54, .08);
  --radius: 14px;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body { margin: 0; padding: 0; }
body {
  background: #e9efed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
img { display: block; }
svg { display: inline-block; vertical-align: middle; }

.shell {
  position: relative;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  box-shadow: 0 0 70px rgba(11, 61, 54, .10);
  padding-bottom: 84px;
}

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 16px;
  background: rgba(244, 247, 246, .97);
  border-bottom: 1px solid rgba(231, 239, 236, .8);
}
.topbar.slim { padding: 10px 14px; }
.back-link { display: inline-flex; align-items: center; gap: 2px; font-size: 12.5px; color: #4b5563; }
.back-link svg { width: 17px; height: 17px; }
.topbar-title { position: absolute; left: 50%; transform: translateX(-50%); font-size: 14px; font-weight: 600; color: #374151; }
.topbar-right { margin-left: auto; }

.brand { display: flex; align-items: center; gap: 10px; }
.logo {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: linear-gradient(145deg, var(--brand-800), var(--brand-600));
  color: #fff;
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 1px;
  box-shadow: 0 6px 14px rgba(15, 118, 110, .28);
}
.logo.big { width: 56px; height: 56px; font-size: 25px; margin: 0 auto 6px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.25; }
.brand-text b { font-size: 18px; letter-spacing: 1px; color: var(--brand-900); }
.brand-text small { font-size: 10.5px; color: #8296a1; letter-spacing: .4px; }

.top-login {
  padding: 6px 13px;
  border: 1px solid #cfe3dc;
  border-radius: 999px;
  color: var(--brand-700);
  font-size: 12px;
  font-weight: 500;
  background: #fff;
}
.top-user { display: flex; align-items: center; gap: 7px; font-size: 12px; color: var(--brand-800); }
.avatar-dot {
  display: grid; place-items: center;
  width: 30px; height: 30px; border-radius: 50%;
  background: linear-gradient(145deg, #12857a, #0f766e);
  color: #fff; font-size: 13px; font-weight: 700;
}

/* ---------- 首页 Hero ---------- */
.page { padding: 0 14px 18px; }
.hero {
  position: relative;
  overflow: hidden;
  margin-top: 6px;
  padding: 20px 18px 16px;
  border-radius: 20px;
  color: #fff;
  background: linear-gradient(148deg, #0b3d36 0%, #0e594e 48%, #117a6d 100%);
  box-shadow: 0 14px 30px rgba(11, 61, 54, .22);
}
.hero-glow {
  position: absolute; inset: -40% -20% auto auto;
  width: 240px; height: 240px; border-radius: 50%;
  background: radial-gradient(circle, rgba(56, 217, 188, .30), transparent 65%);
  pointer-events: none;
}
.hero-glow::after {
  content: ""; position: absolute; left: -150px; top: 120px;
  width: 180px; height: 180px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 255, 255, .10), transparent 62%);
}
.live-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 11px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .12);
  border: 1px solid rgba(255, 255, 255, .22);
  font-size: 11.5px; color: rgba(255, 255, 255, .92);
}
.live-pill b { font-size: 13px; letter-spacing: .5px; }
.live-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: #7bf0d3;
  box-shadow: 0 0 0 0 rgba(123, 240, 211, .7);
  animation: pulse 1.8s infinite;
}
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(123, 240, 211, .6); }
  70% { box-shadow: 0 0 0 8px rgba(123, 240, 211, 0); }
  100% { box-shadow: 0 0 0 0 rgba(123, 240, 211, 0); }
}
.hero h1 { margin: 13px 0 6px; font-size: 23px; line-height: 1.38; font-weight: 700; letter-spacing: .5px; }
.hero-sub { margin: 0; font-size: 12px; color: rgba(255, 255, 255, .70); letter-spacing: .3px; }
.hero-stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  margin-top: 16px; padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, .16);
}
.hs { text-align: center; }
.hs:not(:last-child) { border-right: 1px solid rgba(255, 255, 255, .12); }
.hs b { display: block; font-size: 18px; letter-spacing: .5px; }
.hs span { font-size: 10.5px; color: rgba(255, 255, 255, .62); }

/* ---------- 滚动公告 ---------- */
.notice {
  display: flex; align-items: center; gap: 9px;
  margin-top: 12px; padding: 9px 11px;
  background: #fff; border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
}
.notice-label {
  display: inline-flex; align-items: center; gap: 4px;
  flex: 0 0 auto;
  padding-right: 9px; border-right: 1px solid var(--line);
  color: var(--brand-700); font-size: 11.5px; font-weight: 600;
}
.notice-label svg { width: 13px; height: 13px; }
.notice-viewport { flex: 1; overflow: hidden; min-width: 0; }
.notice-track {
  display: inline-flex; white-space: nowrap;
  animation: marquee 42s linear infinite;
  will-change: transform;
}
.notice-track:hover { animation-play-state: paused; }
.notice-run { padding-right: 56px; font-size: 12px; color: #52616b; }
.notice-run i { color: #b9c6c2; font-style: normal; padding: 0 6px; }
.notice-run::after { content: "◆"; color: #cfe0da; padding-left: 56px; }
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- 搜索 ---------- */
.search-card {
  margin-top: 12px; padding: 11px;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius);
}
.search-box {
  display: flex; align-items: center; gap: 8px;
  padding: 4px 5px 4px 12px;
  background: #f3f8f6; border: 1px solid #e2ece8;
  border-radius: 999px;
}
.search-box svg { width: 16px; height: 16px; color: #8aa39c; flex: 0 0 auto; }
.search-box input {
  flex: 1; min-width: 0;
  border: 0; background: transparent; outline: none;
  font-size: 13px; color: #26332f;
  padding: 8px 0;
}
.search-box input::placeholder { color: #9db0aa; }
.search-btn {
  border: 0; flex: 0 0 auto;
  padding: 7px 17px; border-radius: 999px;
  background: var(--brand-700); color: #fff;
  font-size: 12.5px; font-weight: 600;
}
.search-btn:active { transform: scale(.97); }
.search-hint { margin-top: 8px; font-size: 11.5px; color: #7b8b95; }
.search-hint .hint-lock { display: inline-flex; align-items: center; gap: 4px; }
.search-hint .hint-lock svg { width: 12px; height: 12px; }
.search-hint a { color: var(--brand-700); font-weight: 600; }
.search-hint .hint-ok { display: inline-flex; align-items: center; gap: 5px; color: var(--brand-700); }
.search-hint .hint-ok svg { width: 13px; height: 13px; }

/* ---------- 群列表 ---------- */
.list-section { margin-top: 4px; }
.section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin: 15px 2px 9px;
}
.section-head h2 { margin: 0; font-size: 15.5px; font-weight: 700; letter-spacing: .3px; color: #16241f; }
.section-head span { font-size: 11px; color: #8a9aa0; }

.group-list { display: flex; flex-direction: column; gap: 10px; }
.group-card {
  display: flex; gap: 12px;
  padding: 13px;
  background: #fff; border: 1px solid #eaf1ee;
  border-radius: var(--radius);
  transition: transform .18s ease, box-shadow .18s ease;
}
.group-card:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(11, 61, 54, .08); }
.g-avatar {
  width: 52px; height: 52px; flex: 0 0 52px;
  border-radius: 12px; object-fit: cover;
  border: 1px solid #e8f1ed;
  background: var(--mint);
}
.g-main { flex: 1; min-width: 0; }
.g-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.g-head h3 { margin: 1px 0 0; font-size: 14.5px; font-weight: 700; color: #1a2823; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.g-time { flex: 0 0 auto; font-size: 10px; color: #a3b1b3; }
.g-desc {
  margin: 5px 0 9px; font-size: 12px; line-height: 1.62; color: #6b7a81;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.g-meta { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 999px;
  background: #f0f7f4; color: #128073;
  font-size: 10.5px; white-space: nowrap;
}
.chip svg { width: 11px; height: 11px; }
.g-lock { display: inline-flex; align-items: center; gap: 2px; font-size: 11px; color: #96a5a9; }
.g-lock svg { width: 12px; height: 12px; }
.g-lock.member { color: var(--brand-700); }
.g-lock svg:last-child { width: 13px; height: 13px; }

.load-more {
  width: 100%; margin-top: 12px; padding: 12px;
  border: 1px dashed #c9ded6; border-radius: 12px;
  background: #fff; color: var(--brand-700);
  font-size: 12.5px; font-weight: 500;
}
.load-more:hover { background: #f7fcfa; }
.list-foot { text-align: center; font-size: 11px; color: #a6b4b6; margin: 12px 0 4px; }

.empty {
  padding: 34px 16px; text-align: center;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  color: #8a9a9e;
}
.empty.small { padding: 24px 16px; }
.empty-icon svg { width: 34px; height: 34px; color: #b9cdc6; }
.empty p { margin: 8px 0 4px; font-size: 13px; color: #4b5a58; }
.empty span { font-size: 11.5px; }
.empty .btn { margin-top: 10px; }

/* ---------- 底部导航 ---------- */
.bottom-nav {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  z-index: 50;
  display: flex; width: 100%; max-width: 520px;
  padding: 7px 0 calc(7px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, .98);
  border-top: 1px solid #e7efec;
}
.nav-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 3px 0 1px; color: #9aa9ab; font-size: 10.5px;
}
.nav-item svg { width: 21px; height: 21px; }
.nav-item.active { color: var(--brand-700); font-weight: 600; }
.nav-item.active svg { stroke-width: 2.2; }

/* ---------- 按钮与表单 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 11px 18px; border-radius: 12px;
  font-size: 13.5px; font-weight: 600;
  border: 0; transition: transform .12s ease, box-shadow .18s ease, background .18s;
}
.btn:active { transform: scale(.985); }
.btn.primary {
  background: linear-gradient(135deg, #0f766e, #10a081);
  color: #fff;
  box-shadow: 0 8px 18px rgba(15, 118, 110, .24);
}
.btn.primary:hover { box-shadow: 0 10px 22px rgba(15, 118, 110, .32); }
.btn.ghost { background: #fff; border: 1px solid #cfe3dc; color: var(--brand-700); }
.btn.block { display: flex; width: 100%; }
.btn.danger { background: #fff1f1; color: var(--danger); border: 1px solid #f3d2d2; }
.btn.sm { padding: 7px 12px; font-size: 12px; border-radius: 9px; }

.field { display: block; margin-bottom: 15px; }
.field > span { display: block; font-size: 12px; font-weight: 600; color: #34443f; margin-bottom: 6px; }
.field > span em { color: var(--danger); font-style: normal; }
.field input, .field textarea, .field select {
  width: 100%; padding: 12px 13px;
  border: 1px solid #e2ebe7; border-radius: 12px;
  background: #f8fbfa; color: #1f2d29; font-size: 13.5px;
  outline: none; transition: border .18s, box-shadow .18s;
}
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: #9fd3c6; box-shadow: 0 0 0 3px rgba(20, 184, 166, .10); background: #fff;
}
.field textarea { resize: vertical; line-height: 1.7; }
.field-hint { display: block; margin-top: 5px; font-size: 11px; color: #93a3a5; font-style: normal; }
.field-error { margin-top: 5px; font-size: 11px; color: var(--danger); }

/* ---------- 会员弹层 ---------- */
.sheet-mask {
  position: fixed; inset: 0; z-index: 110;
  background: rgba(9, 32, 28, .48);
  animation: fade .2s ease;
}
.sheet {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  margin: 0 auto;
  width: 100%; max-width: 520px;
  padding: 24px 20px calc(24px + env(safe-area-inset-bottom));
  background: #fff;
  border-radius: 24px 24px 0 0;
  animation: slideUp .26s cubic-bezier(.22,.9,.3,1);
  max-height: 88vh; overflow: auto;
}
@keyframes slideUp { from { transform: translateY(60px); opacity: .6; } to { transform: translateY(0); opacity: 1; } }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.sheet-close {
  position: absolute; right: 14px; top: 12px;
  width: 30px; height: 30px; border: 0; border-radius: 50%;
  background: #f1f5f4; color: #6b7b7d; font-size: 18px; line-height: 1;
}
.sheet-crown {
  width: 50px; height: 50px; margin: 0 auto 10px;
  display: grid; place-items: center;
  border-radius: 16px; background: var(--mint); color: var(--brand-700);
}
.sheet-crown svg { width: 26px; height: 26px; }
.sheet h3 { margin: 0; text-align: center; font-size: 18px; color: #14231f; }
.sheet-sub { margin: 6px 0 14px; text-align: center; font-size: 12px; color: #7f9094; }
.sheet-list { margin: 0 0 16px; padding: 12px 14px; list-style: none; background: #f6faf8; border-radius: 12px; }
.sheet-list li { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: #465855; padding: 5px 0; }
.sheet-list li svg { width: 15px; height: 15px; color: #16a34a; flex: 0 0 auto; }
.sheet-price { display: flex; align-items: baseline; justify-content: center; gap: 4px; margin: 4px 0 14px; }
.sheet-price b { font-size: 27px; color: var(--brand-800); letter-spacing: .5px; }
.sheet-price span { font-size: 12px; color: #8fa0a3; }
.sheet-tip { margin: 10px 0 0; text-align: center; font-size: 11.5px; color: #8a9a9d; }
.sheet-tip a { color: var(--brand-700); font-weight: 600; }

/* ---------- 详情页 ---------- */
.detail-page { padding-top: 8px; }
.detail-actions { display: flex; justify-content: flex-end; gap: 8px; margin-bottom: 9px; }
.pill {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 6px 12px; border-radius: 999px;
  border: 1px solid #e3ece8; background: #fff;
  font-size: 11.5px; color: #556663;
}
.pill svg { width: 13px; height: 13px; }
.pill.on { color: var(--brand-700); border-color: #cfe3dc; background: #f4fbf8; }
.card {
  padding: 16px; background: #fff;
  border: 1px solid #eaf1ee; border-radius: 16px;
  box-shadow: 0 6px 18px rgba(11, 61, 54, .04);
}
.detail-head { display: flex; gap: 12px; align-items: center; }
.detail-avatar { width: 58px; height: 58px; border-radius: 14px; object-fit: cover; flex: 0 0 auto; border: 1px solid #e8f1ed; }
.detail-cate {
  display: inline-block; padding: 2px 8px; border-radius: 999px;
  background: var(--mint); color: var(--brand-700);
  font-size: 10px; letter-spacing: .5px;
}
.detail-head h1 { margin: 6px 0 0; font-size: 19px; line-height: 1.35; letter-spacing: .2px; }
.detail-desc { margin: 14px 0; font-size: 13px; line-height: 1.85; color: #4d5d5a; white-space: pre-wrap; }
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.info-cell { padding: 9px 11px; background: #f7faf9; border: 1px solid #edf4f1; border-radius: 10px; }
.info-cell span { display: block; font-size: 10.5px; color: #8a9a9d; }
.info-cell b { display: block; margin-top: 2px; font-size: 12.5px; color: #22332e; font-weight: 600; }
.info-cell b.ok { color: #12805c; }

.qr-card { margin-top: 12px; }
.qr-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.qr-head h2 { margin: 0; font-size: 15px; }
.qr-tag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 999px;
  background: #f3f9f7; color: #128073; font-size: 10.5px;
}
.qr-tag svg { width: 12px; height: 12px; }
.qr-wrap { text-align: center; }
.qr-wrap img { width: 216px; height: 216px; margin: 0 auto; border-radius: 12px; border: 1px solid #eef4f1; background: #fff; }
.qr-wrap p { margin: 10px 0 0; font-size: 11.5px; color: #7e8f92; }
.qr-wrap .qr-warn { color: var(--amber); font-size: 10.5px; margin-top: 4px; }
.qr-empty {
  display: grid; place-items: center; gap: 6px;
  height: 180px; border: 1px dashed #d7e4df; border-radius: 14px;
  color: #93a4a6; font-size: 12px; background: #fbfdfc;
}
.qr-empty svg { width: 30px; height: 30px; color: #b7cbc4; }
.qr-empty small { font-size: 10.5px; color: #a3b3b5; }

.qr-lock { position: relative; height: 320px; border-radius: 14px; overflow: hidden; background: #f7faf9; }
.qr-blur {
  position: absolute; inset: 0;
  background-position: center; background-repeat: no-repeat; background-size: 216px 216px;
  filter: blur(13px); opacity: .55; transform: scale(1.05);
}
.qr-lock-inner {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 4px; padding: 18px;
  background: linear-gradient(180deg, rgba(255,255,255,.72), rgba(255,255,255,.94));
  text-align: center;
}
.lock-badge {
  display: grid; place-items: center;
  width: 44px; height: 44px; border-radius: 50%;
  background: #fff; color: var(--brand-700);
  box-shadow: 0 8px 20px rgba(11, 61, 54, .12);
}
.lock-badge svg { width: 21px; height: 21px; }
.qr-lock-inner h3 { margin: 6px 0 0; font-size: 15px; }
.qr-lock-inner p { margin: 0 0 10px; font-size: 12px; color: #7b8c8f; }
.qr-lock-inner .btn { padding: 10px 24px; }
.qr-lock-inner .qr-tip { margin: 8px 0 0; font-size: 11px; }
.qr-lock-inner .qr-tip a { color: var(--brand-700); font-weight: 600; }

.tip-card {
  display: flex; gap: 10px; margin-top: 12px; padding: 13px;
  background: #fffdf7; border: 1px solid #f3e7cd; border-radius: 14px;
}
.tip-icon { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 9px; background: #fdf3dd; color: var(--amber); }
.tip-icon svg { width: 16px; height: 16px; }
.tip-card b { font-size: 12px; color: #8a5a12; }
.tip-card p { margin: 3px 0 0; font-size: 11.5px; line-height: 1.7; color: #8d7a58; }

/* ---------- 登录 / 注册 ---------- */
.auth-wrap { min-height: 100vh; padding: 46px 20px 30px; display: flex; flex-direction: column; align-items: center; }
.auth-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 24px; }
.auth-card {
  width: 100%; max-width: 400px;
  padding: 24px 22px; background: #fff;
  border: 1px solid #e9f1ee; border-radius: 20px;
  box-shadow: var(--shadow);
}
.auth-card h1 { margin: 0; font-size: 21px; letter-spacing: .5px; color: #16241f; }
.auth-sub { margin: 6px 0 18px; font-size: 12px; color: #8a9a9d; }
.form-error { margin-bottom: 14px; padding: 10px 12px; border-radius: 10px; background: #fef2f2; color: var(--danger); font-size: 12px; }
.agree { display: flex; align-items: flex-start; gap: 8px; margin: -2px 0 16px; font-size: 11.5px; color: #6f8184; line-height: 1.6; }
.agree input { width: 15px; height: 15px; margin-top: 1px; accent-color: var(--brand-700); }
.auth-foot { margin-top: 16px; text-align: center; font-size: 12px; color: #7d8e91; }
.auth-foot a { color: var(--brand-700); font-weight: 600; }
.auth-copy { margin-top: 22px; font-size: 11px; color: #a2b1b3; letter-spacing: .5px; }

/* ---------- 我的 ---------- */
.profile-card {
  margin-top: 8px; padding: 18px 16px;
  border-radius: 18px;
  background: linear-gradient(145deg, #0b3d36, #0f6a5f 60%, #12786b);
  color: #fff;
  box-shadow: 0 14px 30px rgba(11, 61, 54, .22);
}
.profile-top { display: flex; align-items: center; gap: 12px; }
.profile-avatar {
  width: 48px; height: 48px; border-radius: 50%; flex: 0 0 auto;
  display: grid; place-items: center;
  background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.25);
  font-size: 20px; font-weight: 700;
}
.profile-info { flex: 1; min-width: 0; }
.profile-info h1 { margin: 0; font-size: 17px; letter-spacing: .5px; }
.profile-info p { margin: 3px 0 0; font-size: 10.5px; color: rgba(255,255,255,.62); }
.member-badge {
  padding: 4px 10px; border-radius: 999px;
  font-size: 11px; background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.22);
  color: #dcfaf1;
}
.member-badge.on { background: linear-gradient(135deg, #f2d377, #e0b34a); color: #5b3b06; border-color: #f2d377; font-weight: 700; }
.profile-stats { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 15px; padding-top: 13px; border-top: 1px solid rgba(255,255,255,.16); text-align: center; }
.profile-stats b { display: block; font-size: 15px; }
.profile-stats span { font-size: 10.5px; color: rgba(255,255,255,.62); }
.member-line { display: flex; align-items: center; gap: 6px; margin-top: 13px; padding-top: 11px; border-top: 1px dashed rgba(255,255,255,.22); font-size: 11.5px; color: #d9f5ec; }
.member-line svg { width: 15px; height: 15px; }
.member-line.off { color: #ffe6ba; }
.member-line b { color: #fff; }

.redeem-card { margin-top: 12px; }
.redeem-card h2 { margin: 0; font-size: 15px; }
.card-sub { margin: 4px 0 12px; font-size: 11.5px; color: #8a9a9d; }
.redeem-row { display: flex; gap: 8px; }
.redeem-row input {
  flex: 1; min-width: 0; padding: 11px 13px;
  border: 1px solid #e2ebe7; border-radius: 11px;
  background: #f8fbfa; font-size: 13px; letter-spacing: 1px; text-transform: uppercase;
  outline: none;
}
.redeem-row input:focus { border-color: #9fd3c6; background: #fff; }
.redeem-row .btn { padding: 11px 20px; }
.my-cards { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.used-card { font-size: 10.5px; color: #93a3a5; background: #f5f8f7; padding: 3px 7px; border-radius: 6px; }

.menu-list { margin-top: 12px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.menu-item { display: flex; align-items: center; gap: 10px; padding: 14px 15px; font-size: 13px; border-bottom: 1px solid #f1f6f4; color: #3d4f4b; }
.menu-item:last-child { border-bottom: 0; }
.menu-item svg { width: 17px; height: 17px; color: var(--brand-700); }
.menu-item span { flex: 1; }
.menu-item svg:last-child { color: #b6c4c6; width: 14px; height: 14px; }
.menu-item:hover { background: #fafcfb; }

/* ---------- 发布 ---------- */
.page-title { margin: 10px 2px 12px; }
.page-title h1 { margin: 0; font-size: 20px; letter-spacing: .3px; }
.page-title p { margin: 5px 0 0; font-size: 11.5px; color: #8a9a9d; }
.form-card { padding: 16px; }
.avatar-picker { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.avatar-opt {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 6px; border: 1px solid #e6eeeb; border-radius: 11px;
  background: #f9fbfa; transition: border .15s, background .15s;
}
.avatar-opt img { width: 100%; aspect-ratio: 1; border-radius: 8px; object-fit: cover; }
.avatar-opt small { font-size: 9.5px; color: #94a4a6; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar-opt.selected { border-color: var(--brand-600); background: #eefaf6; box-shadow: 0 0 0 2px rgba(20,184,166,.12) inset; }
.avatar-opt.selected small { color: var(--brand-700); }
.avatar-random {
  width: 100%; aspect-ratio: 1; border-radius: 8px;
  display: grid; place-items: center;
  background: linear-gradient(145deg, #0f766e, #14a58c);
  color: #fff; font-size: 11px;
}
.upload-box {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 6px; height: 132px;
  border: 1px dashed #cfe0da; border-radius: 13px;
  background: #fbfdfc; color: #8fa0a2;
  cursor: pointer; overflow: hidden;
}
.upload-icon svg { width: 24px; height: 24px; color: #a9c5bc; }
.upload-text { font-size: 11.5px; }
#qrPreview { width: 118px; height: 118px; border-radius: 8px; object-fit: contain; }
.form-note { display: flex; gap: 5px; align-items: center; margin: 10px 0 0; font-size: 10.5px; color: #97a6a8; }
.form-note svg { width: 13px; height: 13px; }

/* ---------- 通用页脚 / 提示 ---------- */
.site-foot { margin-top: 22px; text-align: center; font-size: 10.5px; color: #a6b4b6; line-height: 1.9; }
.site-foot p { margin: 0; }

.toast {
  position: fixed; left: 50%; bottom: 92px; transform: translateX(-50%) translateY(12px);
  z-index: 120; max-width: 80vw;
  padding: 9px 16px; border-radius: 999px;
  background: rgba(12, 35, 31, .90); color: #fff;
  font-size: 12px; opacity: 0; pointer-events: none;
  transition: opacity .22s, transform .22s;
}
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

.result-page { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 40px 24px; text-align: center; }
.result-icon { width: 60px; height: 60px; border-radius: 50%; display: grid; place-items: center; background: var(--mint); color: var(--brand-700); font-size: 24px; margin-bottom: 4px; }
.result-icon svg { width: 30px; height: 30px; }
.result-page h1 { margin: 0; font-size: 20px; }
.result-page p { margin: 0 0 14px; font-size: 12.5px; color: #7f9094; }

/* ---------- 后台登录 ---------- */
.admin-body { background: #eef2f0; }
.admin-body .shell { max-width: none; box-shadow: none; background: #eef2f0; padding-bottom: 0; }
.admin-login { min-height: 100vh; display: grid; place-items: center; padding: 30px 18px; }
.admin-card { width: 100%; max-width: 380px; padding: 28px 24px; background: #fff; border-radius: 18px; box-shadow: var(--shadow); text-align: center; }
.admin-card h1 { margin: 10px 0 4px; font-size: 19px; }
.admin-card > p { margin: 0 0 18px; font-size: 11.5px; color: #8a9a9d; }
.admin-card .field { text-align: left; }
.admin-tip { margin-top: 14px; font-size: 10.5px; color: #a1afb1; }

/* ---------- 后台 ---------- */
.admin-shell { display: flex; min-height: 100vh; }
.admin-side {
  width: 208px; flex: 0 0 208px;
  background: linear-gradient(180deg, #0b3d36, #0d5047);
  color: #fff; padding: 18px 14px; display: flex; flex-direction: column;
  position: sticky; top: 0; height: 100vh;
}
.admin-logo { display: flex; align-items: center; gap: 9px; margin-bottom: 22px; }
.admin-logo .logo { width: 35px; height: 35px; font-size: 16px; background: rgba(255,255,255,.14); box-shadow: none; }
.admin-logo b { display: block; font-size: 14px; }
.admin-logo small { font-size: 10px; color: rgba(255,255,255,.55); }
.admin-side nav { display: flex; flex-direction: column; gap: 3px; scrollbar-width: none; }
.admin-side nav::-webkit-scrollbar { display: none; }
.admin-side nav a { padding: 10px 12px; border-radius: 9px; font-size: 12.5px; color: rgba(255,255,255,.72); }
.admin-side nav a:hover { background: rgba(255,255,255,.08); color: #fff; }
.admin-side nav a.active { background: rgba(255,255,255,.14); color: #fff; font-weight: 600; }
.admin-exit { margin-top: auto; padding: 10px 12px; font-size: 12px; color: rgba(255,255,255,.6); border-top: 1px solid rgba(255,255,255,.12); }

.admin-main { flex: 1; min-width: 0; padding: 20px 24px 40px; }
.admin-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 18px; }
.admin-head h1 { margin: 0; font-size: 20px; color: #16241f; }
.admin-head span { font-size: 11.5px; color: #7d8e91; }

.admin-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat-card { padding: 15px 16px; background: #fff; border: 1px solid #e5eeeb; border-radius: 13px; }
.stat-card span { font-size: 11.5px; color: #7d8e91; }
.stat-card b { display: block; margin-top: 4px; font-size: 26px; letter-spacing: .5px; color: #0f2a24; }
.stat-card small { font-size: 10.5px; color: #9aacae; }

.panel { background: #fff; border: 1px solid #e5eeeb; border-radius: 13px; padding: 16px; margin-bottom: 16px; }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.panel-head h3 { margin: 0; font-size: 14px; }
.panel-head span { font-size: 11px; color: #93a3a5; }
.panel table { width: 100%; border-collapse: collapse; font-size: 12px; }
.pager { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 12px 2px 2px; font-size: 12px; color: #7d8f92; }
.pager select { padding: 5px 8px; border: 1px solid #dfe8e4; border-radius: 8px; background: #fff; font-size: 12px; color: #42544f; }
.panel th { text-align: left; padding: 8px 8px; color: #7d8e91; font-weight: 500; border-bottom: 1px solid #edf3f0; font-size: 11px; }
.panel td { padding: 9px 8px; border-bottom: 1px solid #f3f7f5; color: #384a46; vertical-align: middle; }
.panel tr:last-child td { border-bottom: 0; }
.tbl-title { display: flex; align-items: center; gap: 9px; }
.tbl-title img { width: 30px; height: 30px; border-radius: 8px; object-fit: cover; }
.tbl-title b { display: block; font-size: 12.5px; }
.tbl-title small { color: #98a8aa; font-size: 10px; }
.qr-thumb { display: block; width: 46px; height: 46px; object-fit: contain; border: 1px solid #e4efeb; border-radius: 8px; background: #fff; }
.qr-thumb-empty { font-size: 11px; color: #9aabae; }
.qr-current { margin-top: 8px; font-size: 11px; color: #7f9194; }
.qr-current img { margin-top: 6px; width: 78px; height: 78px; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 10.5px; background: #f0f5f3; color: #5c6f6b; }
.badge.green { background: #e9f8f1; color: #0f8055; }
.badge.amber { background: #fdf3e2; color: #9a6512; }
.badge.red { background: #fdeeee; color: #b23c3c; }
.row-actions { display: flex; gap: 6px; justify-content: flex-end; flex-wrap: wrap; }
.row-actions button { border: 1px solid #e0eae6; background: #fff; color: #4a625c; border-radius: 7px; padding: 4px 9px; font-size: 11px; }
.row-actions button:hover { border-color: #b7d8cd; color: var(--brand-700); }
.row-actions button.danger { color: #b23c3c; border-color: #f4dcdc; }

.admin-toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 12px; }
.admin-toolbar input, .admin-toolbar select, .admin-toolbar textarea {
  padding: 8px 11px; border: 1px solid #dfe9e5; border-radius: 9px; font-size: 12px; background: #f9fbfa; outline: none;
}
.admin-toolbar input:focus, .admin-toolbar textarea:focus { border-color: #a6d5c8; background: #fff; }
.admin-toolbar .spacer { flex: 1; }

.avatar-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; }
.avatar-item { border: 1px solid #e7efec; border-radius: 10px; padding: 7px; text-align: center; background: #fafcfb; }
.avatar-item img { width: 100%; aspect-ratio: 1; border-radius: 8px; object-fit: cover; }
.avatar-item small { display: block; margin-top: 4px; font-size: 10.5px; color: #8b9b9d; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.avatar-item .mini-del { margin-top: 4px; border: 0; background: none; color: #b23c3c; font-size: 10px; }

.notice-list { display: flex; flex-direction: column; gap: 8px; }
.notice-item { display: flex; gap: 8px; align-items: flex-start; padding: 10px; border: 1px solid #ecf2ef; border-radius: 10px; background: #fbfdfc; }
.notice-item .txt { flex: 1; font-size: 12px; color: #435551; line-height: 1.6; word-break: break-all; }
.notice-item .ops { display: flex; gap: 5px; flex-shrink: 0; }
.notice-item .ops button { border: 0; background: none; color: #7d8e91; font-size: 11px; }
.notice-item .ops button.danger { color: #b23c3c; }

.modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; background: rgba(12,32,28,.45); padding: 18px; }
.modal-card { width: 100%; max-width: 560px; max-height: 88vh; overflow: auto; background: #fff; border-radius: 16px; padding: 20px; }
.modal-card h3 { margin: 0 0 14px; font-size: 16px; }
.modal-card .field { margin-bottom: 12px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 16px; }

.loading { padding: 40px; text-align: center; color: #9aa9ab; font-size: 12px; }

@media (max-width: 760px) {
  .admin-shell { flex-direction: column; }
  .admin-side { width: 100%; flex: none; height: auto; position: static; padding: 12px; }
  .admin-side nav { flex-direction: row; overflow-x: auto; gap: 6px; padding-bottom: 4px; }
  .admin-side nav a { white-space: nowrap; padding: 7px 11px; }
  .admin-exit { display: none; }
  .admin-cards { grid-template-columns: repeat(2, 1fr); }
  .admin-main { padding: 16px 14px 40px; }
  .admin-head { flex-direction: column; align-items: flex-start; gap: 4px; }
  .panel { overflow-x: auto; }
  .panel table { min-width: 560px; }
}

@media (max-width: 360px) {
  .hero h1 { font-size: 21px; }
  .avatar-picker { grid-template-columns: repeat(4, 1fr); gap: 6px; }
}

/* ===== 第二版新增：Hero 快捷发布 ===== */
.hero-actions { display: flex; gap: 9px; margin-top: 14px; }
.ha-btn {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 8px; border-radius: 12px;
  background: rgba(255, 255, 255, .14);
  border: 1px solid rgba(255, 255, 255, .26);
  color: #fff; font-size: 12.5px; font-weight: 600;
  transition: background .18s;
}
.ha-btn:hover { background: rgba(255, 255, 255, .22); }
.ha-btn svg { width: 16px; height: 16px; }
.ha-btn em { font-style: normal; opacity: .82; font-size: 11.5px; }
.ha-btn.need-member { background: rgba(255, 255, 255, .08); border-style: dashed; }

/* ===== Tab 切换 ===== */
.tabs { display: flex; gap: 6px; margin-top: 11px; padding: 4px; background: #f3f8f6; border-radius: 11px; }
.tab {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 4px;
  padding: 8px 6px; border: 0; border-radius: 8px;
  background: transparent; color: #6d807c; font-size: 12.5px; font-weight: 500;
}
.tab em { font-style: normal; font-size: 10.5px; color: #9bb0aa; }
.tab.active { background: #fff; color: var(--brand-800); font-weight: 700; box-shadow: 0 2px 8px rgba(11, 61, 54, .10); }
.tab.active em { color: var(--brand-600); }
.login-tabs { margin: 0 0 16px; }

/* ===== 每日次数提示 ===== */
.quota-bar {
  display: flex; align-items: center; gap: 6px;
  margin-top: 10px; padding: 9px 12px;
  background: #fff8e9; border: 1px solid #f6e4bf; border-radius: 11px;
  font-size: 11.5px; color: #8a6320;
}
.quota-bar svg { width: 13px; height: 13px; flex: 0 0 auto; }
.quota-bar b { color: #b45309; }
.quota-bar a { margin-left: auto; color: var(--brand-700); font-weight: 700; }

/* ===== 名片列表 ===== */
.card-item { display: flex; gap: 12px; padding: 13px; background: #fff; border: 1px solid #eaf1ee; border-radius: var(--radius); }
.card-contact { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.cc {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 3px 8px; border-radius: 7px;
  background: #f6faf8; border: 1px solid #e9f1ee;
  font-size: 10.5px; color: #546763;
}
.cc svg { width: 11px; height: 11px; color: #8aa39c; }
.cc.locked { color: #97a7a9; border-style: dashed; }
.cards-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin: 6px 0 12px; padding: 16px;
  border-radius: 16px; color: #fff;
  background: linear-gradient(135deg, #0b3d36, #118274);
}
.cards-banner h1 { margin: 0; font-size: 19px; letter-spacing: .5px; }
.cards-banner p { margin: 4px 0 0; font-size: 11.5px; color: rgba(255, 255, 255, .72); }
.cards-banner .btn { background: #fff; color: var(--brand-800); box-shadow: none; }
.btn-sm { padding: 7px 12px; font-size: 12px; border-radius: 9px; }
.random-avatar-note {
  display: flex; align-items: center; gap: 7px;
  margin-top: 2px; padding: 11px 12px;
  border: 1px dashed #cfe3dc; border-radius: 11px;
  background: #f7fbf9; font-size: 11.5px; color: #6b807b;
}
.random-avatar-note svg { width: 15px; height: 15px; color: var(--brand-600); }
.lock-notice {
  display: flex; gap: 10px; align-items: flex-start;
  margin-bottom: 12px; padding: 14px;
  background: #fff8e9; border: 1px solid #f6e4bf; border-radius: var(--radius);
}
.lock-notice > svg { width: 18px; height: 18px; color: #b45309; flex: 0 0 auto; margin-top: 2px; }
.lock-notice b { font-size: 12.5px; color: #8a5a12; }
.lock-notice p { margin: 4px 0 8px; font-size: 11.5px; line-height: 1.7; color: #8d7a58; }

/* ===== 会员 / 支付 ===== */
.member-hero {
  margin: 8px 0 12px; padding: 22px 16px;
  border-radius: 18px; text-align: center; color: #fff;
  background: linear-gradient(150deg, #0d3129, #0f5f52 60%, #158a72);
  box-shadow: 0 14px 28px rgba(11, 61, 54, .22);
}
.mh-crown { display: inline-grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; background: rgba(242, 211, 119, .16); color: #f2d377; }
.mh-crown svg { width: 23px; height: 23px; }
.member-hero h1 { margin: 8px 0 4px; font-size: 20px; letter-spacing: 1px; }
.member-hero p { margin: 0; font-size: 11.5px; color: rgba(255, 255, 255, .72); }
.plan-card { margin-bottom: 12px; }
.plan-card h2, .pay-methods h2 { margin: 0 0 10px; font-size: 15px; }
.plan-list { margin: 0; padding: 0; list-style: none; }
.plan-list li { display: flex; gap: 9px; align-items: flex-start; padding: 8px 0; border-bottom: 1px dashed #eff5f2; font-size: 12px; color: #5b6d69; line-height: 1.65; }
.plan-list li:last-child { border-bottom: 0; }
.plan-list svg { width: 15px; height: 15px; color: #16a34a; flex: 0 0 auto; margin-top: 2px; }
.plan-list b { color: #22332e; margin-right: 4px; }
.member-active {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 12px; padding: 11px 13px;
  background: #fffaeb; border: 1px solid #f3e0b4; border-radius: 11px;
  font-size: 11.5px; color: #8a5a12;
}
.member-active svg { width: 14px; height: 14px; color: #c08a1e; }
.pay-methods { margin-bottom: 12px; }
.pay-method {
  display: flex; align-items: center; gap: 11px; width: 100%;
  padding: 13px; border: 1px solid #e6efeb; border-radius: 12px;
  background: #fbfdfc; text-align: left;
}
.pay-method:hover { border-color: #bfe0d7; background: #f7fcfa; }
.pay-method.disabled { opacity: .62; cursor: not-allowed; }
.pm-icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; color: #fff; font-size: 16px; font-weight: 700; flex: 0 0 auto; }
.pm-icon.alipay { background: #1677ff; }
.pm-text { flex: 1; min-width: 0; }
.pm-text b { display: block; font-size: 13px; color: #22332e; }
.pm-text small { font-size: 10.5px; color: #8a9a9d; }
.pm-amount { font-size: 14px; font-weight: 700; color: #b45309; }
.pay-note { margin: 10px 0 0; font-size: 11px; color: #8a9a9d; }
.pay-note a { color: var(--brand-700); font-weight: 600; }
.pay-card { margin-top: 12px; }
.pay-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.pay-head h2 { margin: 0; font-size: 15px; }
.pay-price { font-size: 19px; font-weight: 700; color: #b45309; }
.redeem-card h2 { margin: 0; font-size: 15px; }
.redeem-row { display: flex; gap: 8px; }
.redeem-row input {
  flex: 1; min-width: 0; padding: 11px 12px;
  border: 1px solid #e2ebe7; border-radius: 11px;
  background: #f8fbfa; font-size: 13px; outline: none;
}
.redeem-row input:focus { border-color: #9fd3c6; background: #fff; }
.my-cards { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.used-card { padding: 3px 8px; border-radius: 6px; background: #f4f8f6; color: #93a3a5; font-size: 10px; }

/* ===== 支付结果 / 次数用完 ===== */
.result-page.inline { min-height: auto; padding: 60px 18px; }
.result-icon.ok { background: #e7f7ef; color: #12805c; }
.quota-empty { padding: 60px 18px 30px; text-align: center; }
.quota-icon { display: inline-grid; place-items: center; width: 62px; height: 62px; border-radius: 50%; background: #fff6e3; color: #b45309; }
.quota-icon svg { width: 30px; height: 30px; }
.quota-empty h1 { margin: 14px 0 8px; font-size: 19px; }
.quota-empty p { margin: 0 0 6px; font-size: 12.5px; color: #6f807c; line-height: 1.8; }
.quota-empty .quota-sub { color: #93a3a5; font-size: 11.5px; margin-bottom: 20px; }
.quota-empty .btn { margin-bottom: 9px; }
.link-back { display: inline-block; margin-top: 10px; font-size: 12px; color: #8a9a9d; }

/* ===== 注册协议 / 表单细节 ===== */
.agree { display: flex; gap: 7px; align-items: flex-start; margin: -2px 0 14px; font-size: 11px; color: #7b8c8f; line-height: 1.6; }
.agree input { margin-top: 2px; accent-color: var(--brand-700); }
.form-error {
  margin-bottom: 13px; padding: 9px 11px;
  background: #fff4f4; border: 1px solid #f6d5d5; border-radius: 10px;
  font-size: 11.5px; color: #b91c1c;
}
.form-note { display: flex; align-items: center; gap: 5px; margin: 11px 0 0; font-size: 10.5px; color: #97a7a9; justify-content: center; }
.form-note svg { width: 12px; height: 12px; }

/* ===== 后台：设置表单 ===== */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.form-grid .field-wide { grid-column: 1 / -1; }
.switch-line { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; padding: 10px 12px; background: #f6faf8; border: 1px solid #e6f0ec; border-radius: 10px; font-size: 12px; color: #4a5d58; }
.switch-line input { accent-color: var(--brand-700); width: 15px; height: 15px; }
.hint-line { margin: 10px 0 0; padding: 9px 11px; background: #fff8e9; border: 1px solid #f6e4bf; border-radius: 9px; font-size: 11px; line-height: 1.8; color: #8a6320; }
@media (max-width: 720px) { .form-grid { grid-template-columns: 1fr; } }

/* ===== 第三版：首页名片区、会员套餐 ===== */
.cards-actions { display: flex; align-items: center; gap: 10px; margin-top: 12px; }
.cards-actions .load-more.as-link { flex: 1; margin-top: 0; text-align: center; display: block; }
.section-head-inline { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 11px; }
.section-head-inline h2 { margin: 0; font-size: 15px; }
.section-head-inline span { font-size: 11px; color: #8a9aa0; }
.package-card { margin-bottom: 12px; }
.package-list { display: flex; flex-direction: column; gap: 9px; }
.package-item {
  position: relative; display: flex; align-items: center; gap: 10px;
  padding: 13px 14px;
  border: 1.5px solid #e6efeb; border-radius: 12px;
  background: #fbfdfc; cursor: pointer;
  transition: border-color .16s, background .16s, box-shadow .16s;
}
.package-item input { position: absolute; opacity: 0; pointer-events: none; }
.package-item.active {
  border-color: var(--brand-600);
  background: #f4fbf8;
  box-shadow: 0 6px 16px rgba(15, 118, 110, .10);
}
.package-item.active::after {
  content: "已选"; position: absolute; top: -1px; right: -1px;
  padding: 2px 9px; border-radius: 0 11px 0 10px;
  background: var(--brand-600); color: #fff; font-size: 10px;
}
.pk-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.pk-info b { font-size: 13.5px; color: #1c2b26; }
.pk-info small { font-size: 11px; color: #8a9aa0; }
.pk-price { font-size: 17px; font-weight: 700; color: #b45309; }
.pk-unit { font-size: 10.5px; color: #9aa9ab; min-width: 58px; text-align: right; }

/* ===== 第四版：多支付通道 ===== */
.pay-form { margin-bottom: 9px; }
.pay-form:last-of-type { margin-bottom: 0; }
.pm-icon.epay { background: linear-gradient(135deg, #f97316, #ea580c); }
.pm-icon.wxpay { background: #07c160; }
.form-error + .card { margin-top: 0; }
.pay-card.simple { padding: 12px; }

/* ===== 第四版：推广代理 ===== */
.menu-extra { margin-left: auto; margin-right: 6px; font-style: normal; font-size: 11px; color: #b45309; }
.agent-hero {
  margin: 8px 0 12px; padding: 20px 16px; border-radius: 18px; color: #fff;
  background: linear-gradient(150deg, #0d3129, #14584b 60%, #1a7d63);
  box-shadow: 0 14px 28px rgba(11, 61, 54, .2); text-align: center;
}
.ah-badge { display: inline-grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: rgba(242,211,119,.16); color: #f2d377; }
.ah-badge svg { width: 21px; height: 21px; }
.agent-hero h1 { margin: 9px 0 5px; font-size: 18px; letter-spacing: .5px; }
.agent-hero p { margin: 0; font-size: 11.5px; line-height: 1.7; color: rgba(255,255,255,.75); }
.agent-hero p b { color: #f2d377; font-size: 13px; }
.ah-price { margin-top: 13px; display: flex; flex-direction: column; gap: 2px; }
.ah-price span { font-size: 11px; color: rgba(255,255,255,.66); }
.ah-price b { font-size: 27px; color: #f2d377; letter-spacing: .5px; }
.agent-apply h2 { margin: 0 0 4px; font-size: 15px; }
.tier-list { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.tier-item {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 11px 12px; border: 1px solid #e6efeb; border-radius: 12px; background: #f9fcfb;
}
.tier-info { display: flex; flex-direction: column; gap: 3px; }
.tier-info b { font-size: 13.5px; color: #17453c; }
.tier-info span { font-size: 11px; color: #93a3a5; }
.tier-info em { font-style: normal; color: #c8811a; font-weight: 700; }
.tier-buy { display: flex; align-items: center; gap: 9px; }
.tier-buy > b { font-size: 15px; color: #14584b; }
.agent-link-card h2, .withdraw-card h2 { margin: 0 0 4px; font-size: 15px; }
.link-row { display: flex; gap: 8px; margin-top: 10px; }
.link-row input {
  flex: 1; min-width: 0; padding: 10px 11px; border: 1px solid #e2ebe7; border-radius: 10px;
  background: #f8fbfa; font-size: 12px; color: #4a5d58; outline: none;
}
.agent-stats { display: flex; margin-top: 13px; padding-top: 12px; border-top: 1px dashed #edf3f0; }
.agent-stats > div { flex: 1; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.agent-stats b { font-size: 17px; color: #14584b; }
.agent-stats span { font-size: 10.5px; color: #93a3a5; }
.withdraw-card .field { margin-top: 10px; }
.mini-list { display: flex; flex-direction: column; gap: 8px; }
.mini-row {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 11px 12px; background: #fff; border: 1px solid #eaf1ee; border-radius: 11px;
}
.mini-row b { font-size: 12.5px; color: #22332e; }
.mini-row small { display: block; margin-top: 3px; font-size: 10.5px; color: #93a3a5; }
.mini-row em { font-style: normal; font-size: 13px; font-weight: 700; color: #c2410c; }
.mini-row em.wd-pending { color: #b45309; font-weight: 600; }
.mini-row em.wd-paid { color: #12805c; font-weight: 600; }
.mini-row em.wd-rejected { color: #b23c3c; font-weight: 600; }

/* ===== 第四版：微信扫码 ===== */
.wxpay-card { text-align: center; }
.wxpay-card h2 { margin: 4px 0 6px; font-size: 16px; }
.wxpay-amount { margin: 0 0 12px; font-size: 27px; font-weight: 700; color: #b45309; }
.wxpay-qr { display: grid; place-items: center; padding: 10px; }
.wxpay-qr img { width: 240px; height: 240px; border-radius: 10px; background: #fff; }
.wxpay-qr p { font-size: 11px; color: #8a9a9d; line-height: 1.7; word-break: break-all; }
.wxpay-qr code { font-size: 10px; color: #4a5d58; }
.wxpay-tip { font-size: 11.5px; color: #7f9094; }
.wxpay-state { margin: 10px 0 8px; font-size: 12px; color: #14584b; }

/* ===== 第四版：后台移动端适配 ===== */
@media (max-width: 820px) {
  .admin-shell { display: block; }
  .admin-side {
    position: sticky; top: 0; z-index: 60; width: 100%; height: auto;
    display: block; padding: 10px 12px 8px; border-radius: 0 0 14px 14px;
  }
  .admin-logo { margin-bottom: 9px; }
  .admin-logo .logo { width: 30px; height: 30px; font-size: 14px; }
  .admin-logo b { font-size: 13px; }
  .admin-logo small { display: none; }
  .admin-side nav { flex-direction: row; overflow-x: auto; gap: 6px; padding-bottom: 2px; -webkit-overflow-scrolling: touch; }
  .admin-side nav a {
    white-space: nowrap; padding: 8px 12px; font-size: 12px;
    background: rgba(255, 255, 255, .08); border-radius: 8px;
  }
  .admin-exit {
    display: block; position: absolute; right: 12px; top: 12px; margin: 0;
    padding: 5px 9px; border: 1px solid rgba(255, 255, 255, .34); border-radius: 7px;
    font-size: 11px; color: #fff;
  }
  .admin-main { padding: 14px 12px 44px; }
  .admin-head { margin-bottom: 12px; }
  .admin-head h1 { font-size: 18px; }
  .admin-cards { grid-template-columns: repeat(2, 1fr); gap: 10px; margin-bottom: 14px; }
  .stat-card { padding: 12px 13px; }
  .stat-card b { font-size: 21px; }
  .panel { padding: 12px; border-radius: 12px; }
  .panel table, .panel thead, .panel tbody, .panel tr, .panel td { display: block; width: 100%; }
  .panel thead { display: none; }
  .panel tr { border: 1px solid #e9f0ed; border-radius: 11px; padding: 6px 11px; margin-bottom: 9px; background: #fcfefd; }
  .panel tr:last-child { margin-bottom: 0; }
  .panel td { border: 0; padding: 5px 0; display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; text-align: right; }
  .panel td::before { content: attr(data-label); color: #8fa1a3; font-size: 11px; flex: 0 0 auto; text-align: left; }
  .panel td:not([data-label]) { justify-content: flex-end; }
  .panel td:not([data-label])::before { display: none; }
  .tbl-title { justify-content: flex-end; text-align: right; }
  .tbl-title img { width: 34px; height: 34px; }
  .row-actions { justify-content: flex-end; gap: 7px; flex-wrap: wrap; }
  .row-actions button { padding: 7px 11px; font-size: 12px; border-radius: 8px; }
  .admin-toolbar { gap: 7px; }
  .admin-toolbar input, .admin-toolbar select, .admin-toolbar textarea { flex: 1 1 130px; min-width: 0; }
  .admin-toolbar .spacer { display: none; }
  .form-grid { grid-template-columns: 1fr !important; }
  .avatar-grid { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  .notice-item { flex-direction: column; align-items: stretch; }
  .notice-item .ops { justify-content: flex-end; }
  .modal { padding: 0; align-items: flex-end; }
  .modal-card { max-width: none; max-height: 92vh; border-radius: 16px 16px 0 0; padding: 18px 16px 26px; }
  .modal-card input, .modal-card select, .modal-card textarea { font-size: 14px; }
  .setting-form .panel { border-radius: 12px; }
  .switch-line { font-size: 12.5px; line-height: 1.6; }
}

/* 移动端表格首列左对齐（标题/头像） */
@media (max-width: 820px) {
  .panel td:first-child { justify-content: flex-start; text-align: left; }
  .panel td:first-child::before { display: none; }
  .tbl-title { justify-content: flex-start; text-align: left; width: 100%; }
  .panel tr { padding: 9px 11px; }
  .panel td { padding: 4px 0; }
}

/* 名片区操作行：按钮不压缩 */
.cards-actions { align-items: stretch; }
.cards-actions .btn { flex: 0 0 auto; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.cards-actions .btn svg { width: 15px; height: 15px; }
.cards-actions .load-more.as-link { display: flex; align-items: center; justify-content: center; }

/* 后台导航按窗口宽度自动换行（不再横向滚动） */
@media (max-width: 820px) {
  .admin-side nav { flex-wrap: wrap; overflow-x: visible; row-gap: 7px; }
  .admin-side nav a { flex: 0 0 auto; }
}
@media (min-width: 821px) and (max-width: 1180px) {
  .admin-shell { grid-template-columns: 186px 1fr; }
  .admin-side { padding: 18px 12px; }
  .admin-side nav a { padding: 9px 11px; font-size: 12.5px; }
}

/* ===== 名片详情 / 二维码上传 ===== */
.contact-card h2 { margin: 0; font-size: 15px; }
.contact-row {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 0; border-bottom: 1px dashed #edf3f0;
}
.contact-row:last-of-type { border-bottom: 0; }
.ct-label { font-size: 12px; color: #8ba0a2; width: 58px; flex: 0 0 auto; }
.ct-value { flex: 1; min-width: 0; font-size: 14px; color: #1f2f2b; letter-spacing: .3px; word-break: break-all; }
.contact-row .btn { flex: 0 0 auto; }
.card-qr { margin-top: 14px; padding-top: 13px; border-top: 1px dashed #edf3f0; text-align: center; }
.card-qr-title { margin: 0 0 9px; font-size: 12px; color: #8ba0a2; }
.card-qr img { width: 190px; height: 190px; object-fit: contain; border-radius: 12px; background: #fff; border: 1px solid #eef3f1; }
.qr-warn { font-size: 10.5px; color: #9aabae; line-height: 1.7; }
.qr-upload { margin-top: 8px; }
.qr-upload-box {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
  height: 108px; border: 1.5px dashed #cfe0d9; border-radius: 12px; background: #f9fcfb;
  color: #2f7a68; font-size: 12.5px; cursor: pointer;
}
.qr-upload-box small { color: #9aabae; font-size: 10.5px; }
.qr-preview { position: relative; display: inline-flex; flex-direction: column; align-items: center; gap: 6px; }
.qr-preview img { width: 148px; height: 148px; object-fit: contain; border-radius: 10px; border: 1px solid #e8f0ec; background: #fff; }
.qr-remove { border: 1px solid #e6d3d3; background: #fff; color: #b23c3c; font-size: 11px; padding: 4px 10px; border-radius: 7px; cursor: pointer; }
.field .optional { font-style: normal; font-size: 10.5px; color: #9aabae; font-weight: 400; }

/* 采集导入 */
.collect-api{display:grid;gap:8px}
.collect-api>div{display:flex;flex-wrap:wrap;gap:8px;align-items:center;font-size:13px;color:#4c5f63}
.collect-api span{min-width:88px;color:#8496a0}
.collect-api code{background:#f2f7f5;border:1px solid #e2ece8;border-radius:8px;padding:5px 10px;font-size:12px;color:#0f4d42;word-break:break-all}
.collect-code{background:#0f2f2a;color:#c9efe3;border-radius:12px;padding:14px;font-size:12px;line-height:1.7;overflow:auto;white-space:pre-wrap;word-break:break-all;margin:0 0 10px}
.collect-tip{font-size:12px;color:#8496a0;line-height:1.8;margin:0}
.collect-summary{margin-top:12px;background:#eef8f3;border:1px solid #d6ece2;color:#0f4d42;border-radius:10px;padding:10px 12px;font-size:13px}
.collect-list{margin:8px 0 0;padding-left:18px;font-size:12px;color:#5d7276;line-height:1.9;max-height:240px;overflow:auto}
.collect-list li b{color:#20383a;font-weight:600}
.collect-list .cr-added{color:#0f8b5f}
.collect-list .cr-updated{color:#1e6fb8}
.collect-list .cr-skipped{color:#9aabae}
.collect-list .cr-failed{color:#c0392b}
.collect-recent{display:grid;grid-template-columns:repeat(auto-fill,minmax(120px,1fr));gap:14px}
.collect-thumb{background:#f7fbf9;border:1px solid #e6efeb;border-radius:12px;padding:10px;text-align:center}
.collect-thumb img{width:100%;aspect-ratio:1/1;object-fit:contain;background:#fff;border-radius:8px}
.collect-thumb b{display:block;font-size:12px;margin-top:6px;color:#20383a;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.collect-thumb small{color:#9aabae;font-size:11px}

/* 数据对接 */
.sync-form{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:12px}
.sync-form label{display:flex;flex-direction:column;gap:6px;font-size:12px;color:#8496a0}
.sync-form label span{font-weight:600;color:#4c5f63}
.sync-form input,.sync-form select{padding:9px 11px;border:1px solid #dfe8e5;border-radius:10px;font-size:13px;color:#20383a;background:#fff;outline:none;font-family:inherit}
.sync-form input:focus,.sync-form select:focus{border-color:#2f9e7e}


/* 推广中心自定义介绍与推广海报 */
.promote-intro h2 { font-size: 15px; margin: 0 0 8px; }
.promote-intro-text { font-size: 13px; line-height: 1.9; color: #4c625d; }
.poster-entry { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; padding-top: 14px; border-top: 1px dashed #e2ebe7; }
.poster-entry b { display: block; font-size: 13px; color: #173f38; }
.poster-entry small { display: block; margin-top: 4px; font-size: 11px; color: #8a9c98; line-height: 1.6; }
.poster-entry .btn { flex: none; }
.poster-modal { position: fixed; inset: 0; z-index: 80; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(8, 26, 23, .72); }
.poster-modal[hidden] { display: none; }
.poster-box { width: 100%; max-width: 460px; max-height: 92vh; overflow: auto; padding: 16px; border-radius: 18px; background: #fff; }
.poster-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; font-size: 15px; }
.poster-head button { border: 0; background: none; font-size: 24px; line-height: 1; color: #7d8f92; cursor: pointer; }
.poster-box canvas { display: block; width: 100%; height: auto; border-radius: 12px; background: #eef5ff; }
.poster-actions { margin-top: 14px; }

/* 后台海报模板设置 */
.poster-config { display: flex; gap: 18px; align-items: flex-start; flex-wrap: wrap; margin: 6px 0 10px; }
.poster-thumb { width: 180px; flex: none; }
.poster-thumb img, .poster-empty { display: block; width: 180px; height: 180px; object-fit: cover; border-radius: 12px; border: 1px solid #e2ebe7; background: #f6faf8; margin-bottom: 8px; }
.poster-empty { display: flex; align-items: center; justify-content: center; font-size: 12px; color: #9aabae; }
.poster-config .form-grid { flex: 1; min-width: 260px; }

/* 后台访客统计图 */
.chart-legend { display: flex; gap: 18px; padding: 4px 2px 6px; font-size: 11.5px; color: #6d817d; }
.chart-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.visit-chart { width: 100%; overflow: visible; position: relative; }
.visit-chart svg { display: block; width: 100%; height: auto; cursor: crosshair; }
.visit-meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 2px 0 8px; font-size: 11.5px; color: #8b9c9f; }
.visit-meta button { flex: none; }
.visit-hint { font-size: 11.5px; color: #8b9c9f; margin: 4px 2px 0; line-height: 1.7; }
.visit-tooltip { position: absolute; display: none; z-index: 8; min-width: 158px; padding: 8px 10px; border-radius: 8px; background: rgba(25, 42, 38, .94); color: #fff; font-size: 11.5px; line-height: 1.65; box-shadow: 0 8px 22px rgba(20, 40, 35, .18); pointer-events: none; }
.visit-tooltip.show { display: block; }
.visit-tooltip b { display: block; margin-bottom: 3px; color: #cfe3dc; font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.visit-tooltip .vt-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; white-space: nowrap; }
.visit-tooltip .vt-row em { font-style: normal; font-weight: 700; color: #9ee08f; }
.visit-tooltip .vt-row + .vt-row em { color: #9fc0ff; }
.visit-tooltip .vt-foot { margin-top: 3px; padding-top: 3px; border-top: 1px solid rgba(255, 255, 255, .12); color: #9fb2ad; font-size: 11px; white-space: nowrap; }
.vt-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 5px; vertical-align: 1px; }
.vt-dot.green { background: #7bc96f; }
.vt-dot.blue { background: #4a7bd0; }
