/* ==========================================================================
   沃德商协会 · 前台 H5 样式（移动优先，PC 居中展示）
   ========================================================================== */
:root {
  --brand: #1d4ed8;
  --brand-2: #2563eb;
  --brand-light: #eff6ff;
  --gold: #c9922b;
  --text: #0f172a;
  --text-2: #475569;
  --muted: #94a3b8;
  --line: #eef2f7;
  --bg: #f4f6fa;
  --radius: 14px;
}

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

html, body {
  margin: 0; padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: #e9edf5;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { display: block; }

.app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  padding-bottom: 66px;
  box-shadow: 0 0 60px rgba(15, 23, 42, .08);
}
.app.no-tabbar { padding-bottom: 0; }

/* ---------------------------------------------------------------- 顶部 */
.hero {
  background: linear-gradient(150deg, #0f172a 0%, #1e3a8a 48%, #2563eb 100%);
  color: #fff;
  padding: 18px 18px 58px;
  position: relative;
  overflow: hidden;
}
.hero:after {
  content: ""; position: absolute; width: 260px; height: 260px; border-radius: 50%;
  right: -110px; top: -130px; background: rgba(255, 255, 255, .07);
}
.hero:before {
  content: ""; position: absolute; width: 160px; height: 160px; border-radius: 50%;
  left: -70px; bottom: -60px; background: rgba(255, 255, 255, .05);
}
.hero-top { display: flex; align-items: center; gap: 11px; position: relative; z-index: 2; }
.hero-logo {
  width: 44px; height: 44px; border-radius: 12px; background: rgba(255,255,255,.16);
  border: 1px solid rgba(255,255,255,.28); overflow: hidden; flex: none;
  display: flex; align-items: center; justify-content: center; font-size: 17px; font-weight: 700;
}
.hero-logo img { width: 100%; height: 100%; object-fit: cover; }
.hero-name { font-size: 17px; font-weight: 600; letter-spacing: .5px; }
.hero-slogan { font-size: 11.5px; opacity: .78; margin-top: 3px; letter-spacing: .3px; }
.hero-search {
  margin-top: 16px; position: relative; z-index: 2;
  background: rgba(255,255,255,.16); border: 1px solid rgba(255,255,255,.22);
  border-radius: 22px; height: 38px; display: flex; align-items: center; gap: 8px; padding: 0 14px;
  color: rgba(255,255,255,.82); font-size: 12.5px;
}
.hero-stats {
  display: flex; gap: 0; margin-top: 16px; position: relative; z-index: 2;
  background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.16);
  border-radius: 12px; padding: 11px 0; backdrop-filter: blur(6px);
}
.hero-stats > div { flex: 1; text-align: center; border-right: 1px solid rgba(255,255,255,.14); }
.hero-stats > div:last-child { border-right: none; }
.hero-stats b { font-size: 16px; font-weight: 600; }
.hero-stats span { display: block; font-size: 10.5px; opacity: .72; margin-top: 2px; }

/* ---------------------------------------------------------------- 通用 */
.wrap { padding: 0 14px; }
.pull-up { margin-top: -42px; position: relative; z-index: 3; }

.card {
  background: #fff; border-radius: var(--radius);
  box-shadow: 0 2px 12px rgba(15, 23, 42, .05);
  overflow: hidden;
}
.card + .card { margin-top: 12px; }
.card-pad { padding: 15px; }

.section { margin-top: 14px; }
.section-head {
  display: flex; align-items: center; gap: 8px; padding: 0 4px 10px;
}
.section-head h3 { margin: 0; font-size: 15.5px; font-weight: 600; letter-spacing: .2px; }
.section-head h3:before {
  content: ""; display: inline-block; width: 3px; height: 14px; border-radius: 2px;
  background: var(--brand-2); margin-right: 8px; vertical-align: -2px;
}
.section-more { margin-left: auto; font-size: 12px; color: var(--muted); display: flex; align-items: center; gap: 2px; }

.notice {
  display: flex; align-items: center; gap: 8px; padding: 10px 14px;
  background: #fff; border-radius: 11px; font-size: 12.5px; color: var(--text-2);
  box-shadow: 0 2px 12px rgba(15,23,42,.05);
}
.notice .tag { flex: none; background: #fff7ed; color: #c2410c; font-size: 10.5px; padding: 2px 7px; border-radius: 20px; }
.notice span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* 快捷入口 */
.quick-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; padding: 14px 6px; }
.quick-item { text-align: center; padding: 4px 0; }
.quick-ico {
  width: 44px; height: 44px; border-radius: 14px; margin: 0 auto 7px;
  display: flex; align-items: center; justify-content: center;
  background: var(--brand-light); color: var(--brand-2); overflow: hidden;
}
.quick-ico img { width: 100%; height: 100%; object-fit: cover; }
.quick-ico.g2 { background: #ecfdf5; color: #059669; }
.quick-ico.g3 { background: #fff7ed; color: #ea580c; }
.quick-ico.g4 { background: #f5f3ff; color: #7c3aed; }
.quick-item span { font-size: 11.5px; color: var(--text-2); }

/* 列表行 */
.list { background: #fff; border-radius: var(--radius); overflow: hidden; }
.row {
  display: flex; align-items: center; gap: 11px;
  padding: 13px 15px; border-bottom: 1px solid var(--line);
}
.row:last-child { border-bottom: none; }
.row:active { background: #fafcff; }
.row-thumb { width: 46px; height: 46px; border-radius: 11px; object-fit: cover; flex: none; background: #f1f5f9; }
.row-thumb.round { border-radius: 50%; }
.row-main { flex: 1; min-width: 0; }
.row-title { font-size: 14px; font-weight: 500; display: flex; align-items: center; gap: 6px; }
.row-title em { font-style: normal; }
.row-sub { font-size: 11.5px; color: var(--muted); margin-top: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-arrow { color: #cbd5e1; flex: none; }

/* 徽标 */
.badge {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 10.5px; padding: 2px 7px; border-radius: 20px; line-height: 16px;
  background: #f1f5f9; color: #64748b; white-space: nowrap;
}
.badge.blue { background: var(--brand-light); color: var(--brand); }
.badge.green { background: #ecfdf5; color: #047857; }
.badge.orange { background: #fff7ed; color: #c2410c; }
.badge.red { background: #fef2f2; color: #b91c1c; }
.badge.gold { background: #fef9ec; color: #a16207; }
.badge.purple { background: #f5f3ff; color: #6d28d9; }

/* 活动卡 */
.act-card { background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: 0 2px 12px rgba(15,23,42,.05); }
.act-card + .act-card { margin-top: 12px; }
.act-cover { position: relative; height: 152px; background: #e2e8f0; }
.act-cover img { width: 100%; height: 100%; object-fit: cover; }
.act-cover .date-badge {
  position: absolute; left: 12px; top: 12px; background: rgba(15,23,42,.72); color: #fff;
  border-radius: 8px; padding: 5px 9px; text-align: center; backdrop-filter: blur(4px);
}
.act-cover .date-badge b { display: block; font-size: 16px; line-height: 1.1; }
.act-cover .date-badge span { font-size: 10px; opacity: .85; }
.act-cover .state {
  position: absolute; right: 12px; top: 12px; font-size: 10.5px; padding: 3px 9px;
  border-radius: 20px; background: rgba(255,255,255,.92); color: var(--brand);
  font-weight: 500;
}
.act-body { padding: 12px 14px 14px; }
.act-title { font-size: 15px; font-weight: 600; line-height: 1.45; }
.act-meta { margin-top: 9px; display: flex; flex-direction: column; gap: 5px; font-size: 11.5px; color: var(--muted); }
.act-meta div { display: flex; align-items: center; gap: 5px; }
.act-foot { display: flex; align-items: center; gap: 8px; margin-top: 11px; padding-top: 11px; border-top: 1px solid var(--line); }
.act-foot .fee { color: #dc2626; font-weight: 600; font-size: 14px; }
.act-foot .fee.free { color: #059669; }
.act-foot .btn-mini { margin-left: auto; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  padding: 9px 16px; border-radius: 9px; font-size: 13px; border: 1px solid var(--line);
  background: #fff; color: var(--text-2); font-family: inherit; cursor: pointer;
}
.btn-primary { background: var(--brand-2); border-color: var(--brand-2); color: #fff; }
.btn-primary:active { background: var(--brand); }
.btn-block { display: flex; width: 100%; padding: 13px; font-size: 15px; border-radius: 11px; }
.btn-outline { border-color: var(--brand-2); color: var(--brand-2); background: #fff; }
.btn-sm { padding: 6px 12px; font-size: 12px; border-radius: 7px; }
.btn[disabled] { opacity: .5; }

/* ---------------------------------------------------------------- 详情 */
.detail-cover { position: relative; height: 210px; }
.detail-cover img { width: 100%; height: 100%; object-fit: cover; }
.detail-cover .shade {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(15,23,42,.15) 0%, rgba(15,23,42,.72) 100%);
}
.detail-cover .dt {
  position: absolute; left: 16px; right: 16px; bottom: 16px; color: #fff;
}
.detail-cover .dt h1 { margin: 0 0 6px; font-size: 18px; line-height: 1.4; font-weight: 600; }
.detail-cover .dt .m { font-size: 11.5px; opacity: .85; display: flex; gap: 10px; flex-wrap: wrap; }

.nav-bar {
  height: 48px; display: flex; align-items: center; gap: 10px; padding: 0 12px;
  background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20;
}
.nav-bar .t { font-size: 15px; font-weight: 600; flex: 1; text-align: center; }
.nav-bar .back { width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; color: var(--text-2); }
.nav-bar .right { width: 30px; }

.info-list { padding: 4px 15px; }
.info-row { display: flex; align-items: flex-start; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.info-row:last-child { border-bottom: none; }
.info-row .k { color: var(--muted); width: 76px; flex: none; font-size: 12.5px; }
.info-row .v { flex: 1; color: var(--text); line-height: 1.65; }

.rich { padding: 4px 15px 16px; font-size: 13.5px; line-height: 1.9; color: #334155; word-break: break-word; }
.rich p { margin: 0 0 10px; }
.rich img { max-width: 100%; border-radius: 8px; }
.rich h1, .rich h2, .rich h3 { font-size: 16px; margin: 18px 0 10px; font-weight: 700; line-height: 1.45; color: var(--text); }
.rich h4 { font-size: 14.5px; margin: 16px 0 8px; font-weight: 700; color: var(--text); }
.rich h5, .rich h6 { font-size: 13.5px; margin: 14px 0 8px; font-weight: 700; color: var(--text); }
.rich ul, .rich ol { margin: 0 0 12px; padding-left: 22px; }
.rich ul li { list-style: disc; margin-bottom: 5px; }
.rich ol li { list-style: decimal; margin-bottom: 5px; }
.rich blockquote {
  margin: 12px 0; padding: 10px 14px; border-left: 3px solid #bfdbfe;
  background: #f8fafc; color: #475569; border-radius: 0 8px 8px 0;
}
.rich blockquote p:last-child { margin-bottom: 0; }
.rich table { width: 100%; border-collapse: collapse; margin: 12px 0; font-size: 12.5px; }
.rich th, .rich td { border: 1px solid var(--line); padding: 7px 9px; text-align: left; }
.rich th { background: #f8fafc; font-weight: 600; }
.rich hr { border: 0; border-top: 1px solid var(--line); margin: 16px 0; }
.rich a { color: var(--brand); text-decoration: underline; }
.rich strong { font-weight: 700; color: var(--text); }
.rich code { background: #f1f5f9; padding: 1px 5px; border-radius: 4px; font-size: 12px; }
.rich pre {
  background: #0f172a; color: #e2e8f0; padding: 12px 14px;
  border-radius: 8px; overflow-x: auto; font-size: 12px; line-height: 1.7;
}
.rich pre code { background: none; color: inherit; padding: 0; }

.bottom-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 25;
  max-width: 480px; margin: 0 auto; background: #fff; border-top: 1px solid var(--line);
  padding: 10px 14px calc(10px + env(safe-area-inset-bottom));
  display: flex; align-items: center; gap: 10px;
}

/* 核销码 */
.verify-card {
  background: linear-gradient(135deg, #0f172a, #1d4ed8);
  color: #fff; border-radius: 14px; padding: 18px; text-align: center;
}
.verify-code {
  font-size: 26px; letter-spacing: 4px; font-weight: 700; margin: 10px 0 6px;
  font-family: ui-monospace, Menlo, Consolas, monospace;
}
.verify-card .sub { font-size: 11.5px; opacity: .8; }

/* 电子会牌 */
.mcard {
  border-radius: 18px; overflow: hidden; color: #fff;
  background: linear-gradient(135deg, #0b1224 0%, #1e3a8a 55%, #2563eb 100%);
  box-shadow: 0 16px 36px -14px rgba(15, 23, 42, .55);
  position: relative;
}
.mcard:after {
  content: ""; position: absolute; width: 210px; height: 210px; border-radius: 50%;
  right: -90px; bottom: -110px; background: rgba(255,255,255,.06);
}
.mcard-top { padding: 16px 18px 0; display: flex; align-items: center; gap: 8px; }
.mcard-top .org { font-size: 12px; font-weight: 600; letter-spacing: .6px; }
.mcard-top .en { margin-left: auto; font-size: 9px; letter-spacing: 1.6px; opacity: .6; }
.mcard-body { padding: 16px 18px 18px; display: flex; gap: 14px; align-items: center; position: relative; z-index: 2; }
.mcard-avatar { width: 62px; height: 62px; border-radius: 14px; object-fit: cover; border: 2px solid rgba(255,255,255,.4); flex: none; }
.mcard-name { font-size: 18px; font-weight: 600; }
.mcard-company { font-size: 11.5px; opacity: .82; margin-top: 4px; }
.mcard-foot {
  padding: 12px 18px; background: rgba(255,255,255,.08);
  display: flex; justify-content: space-between; align-items: center; font-size: 10.5px;
  border-top: 1px solid rgba(255,255,255,.12); position: relative; z-index: 2;
}
.mcard-foot .lv { color: #fcd34d; font-weight: 600; }

/* ---------------------------------------------------------------- 我的 */
.me-head {
  background: linear-gradient(150deg, #0f172a 0%, #1e3a8a 55%, #2563eb 100%);
  padding: 24px 18px 66px; color: #fff; position: relative; overflow: hidden;
}
.me-head:after {
  content: ""; position: absolute; width: 220px; height: 220px; border-radius: 50%;
  right: -90px; top: -100px; background: rgba(255,255,255,.07);
}
.me-user { display: flex; align-items: center; gap: 13px; position: relative; z-index: 2; }
.me-avatar {
  width: 58px; height: 58px; border-radius: 50%; background: rgba(255,255,255,.18);
  border: 2px solid rgba(255,255,255,.35); overflow: hidden; flex: none;
  display: flex; align-items: center; justify-content: center; font-size: 22px; font-weight: 600;
}
.me-avatar img { width: 100%; height: 100%; object-fit: cover; }
.me-name { font-size: 17px; font-weight: 600; }
.me-sub { font-size: 11.5px; opacity: .8; margin-top: 4px; }
.me-nums { display: flex; gap: 22px; margin-top: 16px; position: relative; z-index: 2; }
.me-nums b { font-size: 19px; font-weight: 600; display: block; }
.me-nums span { font-size: 10.5px; opacity: .72; }

.menu-list { background: #fff; border-radius: var(--radius); overflow: hidden; }
.menu-item { display: flex; align-items: center; gap: 11px; padding: 14px 15px; border-bottom: 1px solid var(--line); }
.menu-item:last-child { border-bottom: none; }
.menu-item .mi-ico {
  width: 30px; height: 30px; border-radius: 9px; display: flex; align-items: center; justify-content: center;
  background: var(--brand-light); color: var(--brand-2); flex: none; overflow: hidden;
}
.menu-item .mi-ico img { width: 100%; height: 100%; object-fit: cover; }
.menu-item .mi-t { flex: 1; font-size: 13.5px; }
.menu-item .mi-v { font-size: 12px; color: var(--muted); }

/* ---------------------------------------------------------------- 表单 */
.form-card { padding: 4px 0; }
.field { display: flex; align-items: center; gap: 12px; padding: 13px 15px; border-bottom: 1px solid var(--line); }
.field:last-child { border-bottom: none; }
.field > label { width: 84px; flex: none; font-size: 13px; color: var(--text-2); }
.field > label .req { color: #dc2626; margin-left: 2px; }
.field .input, .field select, .field textarea {
  flex: 1; border: none; outline: none; font-size: 13.5px; font-family: inherit;
  background: transparent; color: var(--text); padding: 0; width: 100%;
}
.field textarea { min-height: 66px; resize: vertical; line-height: 1.75; }
.field.col { flex-direction: column; align-items: stretch; gap: 8px; }
.field.col > label { width: auto; }
.field.col textarea { background: #f8fafc; border-radius: 9px; padding: 11px 12px; }
.field-pick { display: flex; gap: 8px; flex-wrap: wrap; }

/* 单选 / 多选选项组 */
.opt-group { display: flex; flex-wrap: wrap; gap: 9px; }
.opt-item {
  display: flex; align-items: center; gap: 7px;
  padding: 9px 14px; border: 1px solid #e3eaf3; border-radius: 10px;
  font-size: 13px; color: var(--text-2); background: #fff; cursor: pointer;
  transition: border-color .15s, background .15s;
}
.opt-item input { accent-color: var(--brand); }
.opt-item:has(input:checked) { border-color: var(--brand); background: var(--brand-light); color: var(--brand); }
.opt-item small { font-size: 11px; color: #a16207; }

/* 图片上传 */
.signup-upload { width: 100%; }
.signup-upload input[type=file] {
  font-size: 12.5px; color: var(--text-2);
}
.signup-upload .su-preview { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.signup-upload .su-preview img { width: 76px; height: 76px; object-fit: cover; border-radius: 9px; border: 1px solid var(--line); }
.signup-upload .hint { font-size: 11px; color: var(--muted); margin-top: 6px; }

.chip {
  padding: 7px 13px; border-radius: 20px; border: 1px solid #e3eaf3; font-size: 12.5px;
  color: var(--text-2); background: #fff;
}
.chip.on { border-color: var(--brand-2); background: var(--brand-light); color: var(--brand); font-weight: 500; }
.chip small { font-size: 10.5px; opacity: .7; margin-left: 3px; }

/* ---------------------------------------------------------------- 底部导航 */
.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  max-width: 480px; margin: 0 auto; background: rgba(255,255,255,.97);
  border-top: 1px solid var(--line); display: flex;
  padding-bottom: env(safe-area-inset-bottom);
  backdrop-filter: blur(10px);
}
.tabbar a {
  flex: 1; padding: 7px 0 6px; text-align: center; color: #94a3b8; font-size: 10.5px;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
}
.tabbar a.on { color: var(--brand-2); font-weight: 500; }
.tabbar a.on .ic { filter: drop-shadow(0 2px 4px rgba(37,99,235,.28)); }

/* ---------------------------------------------------------------- 其它 */
.empty { text-align: center; padding: 60px 20px; color: var(--muted); font-size: 13px; }
.empty .ic { color: #cbd5e1; margin-bottom: 10px; }

.toast {
  position: fixed; left: 50%; top: 42%; transform: translate(-50%, -50%);
  background: rgba(15,23,42,.88); color: #fff; padding: 11px 18px; border-radius: 10px;
  font-size: 13px; z-index: 90; max-width: 78%; text-align: center; line-height: 1.7;
}
.toast.success { background: rgba(5,150,105,.94); }
.toast.error { background: rgba(220,38,38,.94); }

.filter-bar {
  display: flex; gap: 8px; overflow-x: auto; padding: 11px 14px; background: #fff;
  border-bottom: 1px solid var(--line); position: sticky; top: 48px; z-index: 15;
}
.filter-bar::-webkit-scrollbar { display: none; }
.filter-bar .chip { flex: none; }

.pull-tip { text-align: center; font-size: 11px; color: #cbd5e1; padding: 14px 0; }

.avatar-sm { width: 34px; height: 34px; border-radius: 50%; flex: none; }

.thumb-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.thumb-grid img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 6px; }

.stat-line { display: flex; gap: 0; background: #fff; border-radius: 12px; padding: 13px 0; box-shadow: 0 2px 12px rgba(15,23,42,.05); }
.stat-line > div { flex: 1; text-align: center; border-right: 1px solid var(--line); }
.stat-line > div:last-child { border-right: none; }
.stat-line b { font-size: 17px; }
.stat-line span { display: block; font-size: 10.5px; color: var(--muted); margin-top: 3px; }

.footer-note { text-align: center; font-size: 10.5px; color: #b6c2d4; padding: 22px 0 12px; line-height: 1.9; }
