/* ============================================================
   WeFlow · Global（重置 + 基础 + 共享原子类）
   ============================================================ */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

html, body { height: 100%; }
body {
  font-family: var(--wf-font);
  font-size: 14px;
  color: var(--wf-text);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; border: none; background: none; cursor: pointer; color: inherit; }
input, textarea, select { font-family: inherit; font-size: inherit; color: inherit; }
input, textarea { outline: none; border: none; background: none; }
ul, ol { list-style: none; }
img { display: block; max-width: 100%; }
svg { display: block; }
i[data-lucide] { display: inline-block; }

/* ---- 排版工具 ---- */
.ell { overflow: hidden; white-space: nowrap; text-overflow: ellipsis; }
.ell-2 { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.num { font-variant-numeric: tabular-nums; }
.fw-6 { font-weight: 600; }
.fw-7 { font-weight: 700; }
.tc { text-align: center; }
.muted { color: var(--wf-text-2); }
.muted-3 { color: var(--wf-text-3); }
.fs-11 { font-size: 11px; } .fs-12 { font-size: 12px; } .fs-13 { font-size: 13px; }
.fs-15 { font-size: 15px; } .fs-16 { font-size: 16px; } .fs-18 { font-size: 18px; }
.hide { display: none !important; }
.flex { display: flex; align-items: center; }
.flex-col { display: flex; flex-direction: column; }
.jb { justify-content: space-between; }
.jc { justify-content: center; }
.gap-4 { gap: 4px; } .gap-6 { gap: 6px; } .gap-8 { gap: 8px; } .gap-10 { gap: 10px; } .gap-12 { gap: 12px; }
.f1 { flex: 1; min-width: 0; }
.mt-4 { margin-top: 4px; } .mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; }
.mb-8 { margin-bottom: 8px; } .mb-12 { margin-bottom: 12px; } .mb-16 { margin-bottom: 16px; }
.px-14 { padding-left: 14px; padding-right: 14px; }

/* ---- 动画 ---- */
@keyframes wfFadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes wfUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes wfPop { from { opacity: 0; transform: scale(.92); } to { opacity: 1; transform: scale(1); } }
@keyframes wfSheetUp { from { transform: translateY(100%); } to { transform: none; } }
@keyframes wfSpin { to { transform: rotate(360deg); } }
@keyframes wfPulse { 0%, 100% { opacity: 1; } 50% { opacity: .45; } }
.anim-in { animation: wfUp .38s var(--wf-ease) both; }
.anim-fade { animation: wfFadeIn .3s ease both; }

/* ---- 骨架屏 ---- */
@keyframes wfShimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }
.skl {
  background: linear-gradient(90deg, #ECF0F3 25%, #F6F8FA 37%, #ECF0F3 63%);
  background-size: 400% 100%;
  animation: wfShimmer 1.2s infinite;
  border-radius: 8px;
}

/* ---- 按钮 ---- */
.wf-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 38px; padding: 0 16px; border-radius: 10px;
  font-size: 14px; font-weight: 600; border: 1px solid transparent;
  background: #fff; color: var(--wf-text);
  transition: transform .15s ease, background .18s ease, opacity .18s ease;
  user-select: none; white-space: nowrap;
}
.wf-btn:active { transform: scale(.96); }
.wf-btn svg { width: 16px; height: 16px; }
.wf-btn--primary { background: var(--wf-brand); color: #fff; }
.wf-btn--primary:hover { background: var(--wf-brand-800); }
.wf-btn--ink { background: var(--wf-ink); color: #fff; }
.wf-btn--ghost { border-color: var(--wf-line); color: var(--wf-text-2); }
.wf-btn--ghost:hover { border-color: var(--wf-text-3); color: var(--wf-text); }
.wf-btn--tint { background: var(--wf-brand-50); color: var(--wf-brand); border-color: var(--wf-brand-100); }
.wf-btn--danger { background: var(--wf-danger); color: #fff; }
.wf-btn--danger-ghost { border-color: var(--wf-danger-50); background: var(--wf-danger-50); color: var(--wf-danger); }
.wf-btn--wechat { background: var(--wf-wechat); color: #fff; }
.wf-btn--gold { background: linear-gradient(135deg, var(--lv-gold-1), var(--lv-gold-2)); color: #fff; }
.wf-btn--sm { height: 30px; padding: 0 12px; font-size: 12px; border-radius: 8px; }
.wf-btn--sm svg { width: 13px; height: 13px; }
.wf-btn--lg { height: 46px; font-size: 15px; border-radius: 12px; }
.wf-btn--pill { border-radius: 999px; }
.wf-btn--block { width: 100%; }
.wf-btn[disabled], .wf-btn.disabled { opacity: .45; pointer-events: none; }

/* ---- 标签 ---- */
.wf-tag {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 0 7px; height: 20px; border-radius: 6px;
  font-size: 11px; font-weight: 600; line-height: 1; white-space: nowrap;
}
.wf-tag svg { width: 11px; height: 11px; }
.wf-tag--brand { background: var(--wf-brand-50); color: var(--wf-brand); border: 1px solid var(--wf-brand-100); }
.wf-tag--gold { background: var(--wf-accent-50); color: var(--wf-accent-deep); border: 1px solid #FDE68A; }
.wf-tag--danger { background: var(--wf-danger-50); color: var(--wf-danger); }
.wf-tag--success { background: var(--wf-success-50); color: #15803D; }
.wf-tag--info { background: var(--wf-info-50); color: var(--wf-info); }
.wf-tag--purple { background: var(--wf-purple-50); color: var(--wf-purple); }
.wf-tag--gray { background: #F1F5F9; color: var(--wf-text-2); }
.wf-tag--ink { background: var(--wf-ink); color: #fff; }

/* ---- 卡片 ---- */
.wf-card {
  background: var(--wf-card); border-radius: var(--wf-r);
  box-shadow: var(--wf-shadow-1); border: 1px solid rgba(226, 232, 240, .6);
}

/* ---- 滚动条（后台用） ---- */
.slim-scroll::-webkit-scrollbar { width: 6px; height: 6px; }
.slim-scroll::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 3px; }
.slim-scroll::-webkit-scrollbar-track { background: transparent; }
