/* =====================================================================
   ps-aff.css —— 推广返利（Affiliate）样式
   覆盖：推广页的规则弹层 + 返利中心（数据卡/等级/推广方式/8 个 Tab/提现弹层）
   字号一律 ≥13px（平哥眼睛老花）
   ===================================================================== */

.psaf-wrap { max-width: 1200px; margin: 0 auto; padding: 22px 20px 56px; }

/* ---------- 面包屑 / 标题 ---------- */
.psaf-crumb { font-size: 13px; color: #8a94a3; margin-bottom: 10px; }
.psaf-crumb a { color: #8a94a3; text-decoration: none; }
.psaf-crumb a:hover { color: #EB6100; }
.psaf-crumb i { margin: 0 7px; font-size: 11px; }
.psaf-title { font-size: 30px; font-weight: 800; color: #1a2332; margin: 0 0 6px; letter-spacing: -.01em; }
.psaf-lead { font-size: 14px; line-height: 1.75; color: #6b7789; margin: 0 0 20px; max-width: 780px; }

/* ---------- 数据卡 ---------- */
.psaf-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 18px; }
.psaf-stat { background: #fff; border: 1px solid #e8edf3; border-radius: 12px; padding: 15px 16px; }
.psaf-stat .k { font-size: 13px; color: #6b7789; display: flex; align-items: center; gap: 5px; margin-bottom: 9px; }
.psaf-stat .k i.fa-circle-info { color: #b6bfcc; font-size: 12px; cursor: help; }
.psaf-stat .v { font-size: 25px; font-weight: 800; color: #1a2332; line-height: 1.15; }
.psaf-stat .v small { font-size: 13px; font-weight: 600; color: #8a94a3; margin-left: 3px; }
.psaf-stat.hot { border-color: #ffd0b0; background: linear-gradient(180deg, #fff8f3, #fff); }
.psaf-stat.hot .v { color: #EB6100; }
.psaf-stat .sub { font-size: 13px; color: #8a94a3; margin-top: 6px; }

/* ---------- 两栏：等级 / 推广方式 ---------- */
.psaf-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 20px; }
.psaf-card { background: #fff; border: 1px solid #e8edf3; border-radius: 12px; padding: 18px 18px 16px; }
.psaf-card h3 { font-size: 16px; font-weight: 800; color: #1a2332; margin: 0 0 4px; display: flex; align-items: center; gap: 8px; }
.psaf-card h3 .tagn { font-size: 12px; font-weight: 700; color: #fff; background: #EB6100; border-radius: 20px; padding: 2px 9px; }

/* 等级 */
.psaf-lvnow { display: flex; align-items: flex-end; gap: 10px; margin: 12px 0 4px; }
.psaf-lvnow b { font-size: 22px; font-weight: 800; color: #EB6100; }
.psaf-lvnow span { font-size: 14px; color: #6b7789; }
.psaf-lvnow em { font-size: 22px; font-weight: 800; color: #1a2332; font-style: normal; margin-left: auto; }
.psaf-bar { height: 9px; background: #eef2f7; border-radius: 20px; overflow: hidden; margin: 10px 0 7px; }
.psaf-bar i { display: block; height: 100%; background: linear-gradient(90deg, #ffb150, #EB6100); border-radius: 20px; }
.psaf-barnote { font-size: 13px; color: #8a94a3; }
.psaf-lvtable { width: 100%; border-collapse: collapse; margin-top: 14px; font-size: 13px; }
.psaf-lvtable th { background: #f4f7fa; color: #5a6a7d; font-weight: 700; padding: 7px 8px; text-align: left; }
.psaf-lvtable td { padding: 7px 8px; border-bottom: 1px solid #eef2f7; color: #44506a; }
.psaf-lvtable tr.on td { background: #fff6ef; color: #b34a00; font-weight: 700; }

/* 推广方式 */
.psaf-copyrow { display: flex; gap: 8px; margin-top: 12px; }
.psaf-copyrow input {
  flex: 1; min-width: 0; height: 42px; border: 1px solid #dfe6ee; border-radius: 8px;
  padding: 0 12px; font-size: 13px; color: #1a2332; background: #f9fbfd; font-family: Consolas, monospace;
}
.psaf-btn {
  height: 42px; padding: 0 16px; border-radius: 8px; border: 1px solid var(--cf, #EB6100);
  background: var(--cf, #EB6100); color: #fff; font-size: 13px; font-weight: 700;
  cursor: pointer; white-space: nowrap; display: inline-flex; align-items: center; gap: 6px;
}
.psaf-btn:hover { filter: brightness(.94); }
.psaf-btn.ghost { background: #fff; color: var(--cf, #EB6100); }
.psaf-btn.ghost:hover { background: #fff6ef; }
.psaf-btn[disabled] { opacity: .55; cursor: not-allowed; }
.psaf-btn.sm { height: 34px; padding: 0 12px; font-size: 13px; }
.psaf-codebox {
  display: flex; align-items: center; gap: 12px; margin-top: 12px;
  background: #fff8f3; border: 1px dashed #ffc79c; border-radius: 10px; padding: 12px 14px;
}
.psaf-codebox .big { font-size: 24px; font-weight: 800; color: #EB6100; letter-spacing: .14em; font-family: Consolas, monospace; }
.psaf-qr { margin-top: 14px; display: flex; align-items: center; gap: 14px; }
.psaf-qr canvas, .psaf-qr img { width: 118px; height: 118px; border: 1px solid #e8edf3; border-radius: 8px; background: #fff; }
.psaf-qr .qn { font-size: 13px; color: #8a94a3; line-height: 1.8; max-width: 210px; }
.psaf-methodnote { font-size: 13px; line-height: 1.8; color: #6b7789; margin-top: 12px; padding-top: 12px; border-top: 1px dashed #e8edf3; }
.psaf-invrow { display: flex; gap: 8px; margin-top: 10px; }
.psaf-invrow input { flex: 1; min-width: 0; height: 42px; border: 1px solid #dfe6ee; border-radius: 8px; padding: 0 12px; font-size: 13px; }

/* ---------- Tab 栏 ---------- */
.psaf-tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 2px solid #eef2f7; margin-bottom: 0; }
.psaf-tab {
  padding: 10px 14px; font-size: 14px; font-weight: 600; color: #6b7789; cursor: pointer;
  border-bottom: 2px solid transparent; margin-bottom: -2px; white-space: nowrap; background: none; border-top: 0; border-left: 0; border-right: 0;
}
.psaf-tab:hover { color: #EB6100; }
.psaf-tab.on { color: #EB6100; border-bottom-color: #EB6100; font-weight: 800; }
.psaf-panel { background: #fff; border: 1px solid #e8edf3; border-top: 0; border-radius: 0 0 12px 12px; padding: 4px 0 0; }
.psaf-filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; padding: 13px 16px; border-bottom: 1px solid #eef2f7; font-size: 13px; color: #6b7789; }
.psaf-filters select, .psaf-filters input { height: 36px; border: 1px solid #dfe6ee; border-radius: 7px; padding: 0 9px; font-size: 13px; color: #1a2332; }
.psaf-filters .grow { margin-left: auto; }

.psaf-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.psaf-table th { background: #f7f9fc; color: #5a6a7d; font-weight: 700; padding: 10px 14px; text-align: left; white-space: nowrap; border-bottom: 1px solid #eef2f7; }
.psaf-table td { padding: 11px 14px; border-bottom: 1px solid #f1f5f9; color: #44506a; }
.psaf-table tr:hover td { background: #fcfdfe; }
.psaf-table .num { font-weight: 700; color: #1a2332; font-variant-numeric: tabular-nums; }
.psaf-table .plus { color: #c62828; font-weight: 700; }
.psaf-table .minus { color: #2e7d32; font-weight: 700; }
.psaf-table .mono { font-family: Consolas, monospace; font-size: 12.5px; }
.psaf-empty { padding: 44px 20px; text-align: center; }
.psaf-empty i { font-size: 30px; color: #dfe6ee; }
.psaf-empty b { display: block; font-size: 16px; color: #44506a; margin: 12px 0 6px; font-weight: 700; }
.psaf-empty p { font-size: 13px; color: #8a94a3; margin: 0; line-height: 1.8; }

.psaf-pill { display: inline-block; font-size: 12px; font-weight: 700; border-radius: 20px; padding: 2px 9px; white-space: nowrap; }
.psaf-pill.pending { background: #fff6e5; color: #a86a00; }
.psaf-pill.frozen { background: #eef4ff; color: #2b5fa8; }
.psaf-pill.settled { background: #e9f7ec; color: #2f7d32; }
.psaf-pill.cancelled { background: #f2f4f7; color: #8a94a3; }
.psaf-pill.registered { background: #fff6e5; color: #a86a00; }
.psaf-pill.active { background: #e9f7ec; color: #2f7d32; }

/* ---------- 按钮区 ---------- */
.psaf-actions { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin: 18px 0 0; }

/* ---------- 弹层（规则 / 提现） ---------- */
.psaf-mask { position: fixed; inset: 0; background: rgba(12, 22, 38, .5); z-index: 9000; display: none; align-items: flex-start; justify-content: center; overflow-y: auto; padding: 40px 16px; }
.psaf-mask.on { display: flex; }
.psaf-modal { background: #fff; border-radius: 14px; width: 100%; max-width: 720px; box-shadow: 0 20px 50px rgba(12, 22, 38, .3); }
.psaf-modal.narrow { max-width: 470px; }
.psaf-mhead { display: flex; align-items: center; justify-content: space-between; padding: 17px 22px; border-bottom: 1px solid #eef2f7; }
.psaf-mhead h3 { font-size: 18px; font-weight: 800; color: #1a2332; margin: 0; }
.psaf-mhead .x { font-size: 22px; color: #97a1b0; cursor: pointer; line-height: 1; background: none; border: 0; padding: 0 4px; }
.psaf-mhead .x:hover { color: #EB6100; }
.psaf-mbody { padding: 20px 22px 24px; }
.psaf-mbody h4 { font-size: 15px; font-weight: 800; color: #EB6100; margin: 18px 0 7px; }
.psaf-mbody h4:first-child { margin-top: 0; }
.psaf-mbody p, .psaf-mbody li { font-size: 14px; line-height: 1.95; color: #44506a; margin: 0 0 4px; }
.psaf-mbody ul { margin: 0; padding-left: 20px; }
.psaf-mfoot { padding: 0 22px 22px; display: flex; gap: 10px; justify-content: flex-end; }
.psaf-field { margin-bottom: 14px; }
.psaf-field label { display: block; font-size: 13px; font-weight: 700; color: #44506a; margin-bottom: 6px; }
.psaf-field input, .psaf-field select { width: 100%; height: 44px; border: 1px solid #dfe6ee; border-radius: 8px; padding: 0 12px; font-size: 14px; color: #1a2332; box-sizing: border-box; }
.psaf-field .hint { font-size: 13px; color: #8a94a3; margin-top: 6px; }
.psaf-field .hint b { color: #EB6100; }
.psaf-msg { font-size: 13.5px; padding: 10px 13px; border-radius: 8px; margin-bottom: 14px; line-height: 1.8; display: none; }
.psaf-msg.on { display: block; }
.psaf-msg.err { background: #fdecea; color: #b3261e; border-left: 3px solid #c62828; }
.psaf-msg.ok { background: #e9f7ec; color: #1b5e20; border-left: 3px solid #2e7d32; }

/* 页头大按钮（推广页） */
.psaf-hero-btns { display: flex; gap: 14px; flex-wrap: wrap; }
.psaf-hero-btns .psaf-btn { height: 54px; padding: 0 34px; font-size: 16px; border-radius: 8px; }

/* ---------- 手机 ---------- */
@media (max-width: 1000px) {
  .psaf-stats { grid-template-columns: repeat(2, 1fr); }
  .psaf-cols { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .psaf-wrap { padding: 16px 14px 40px; }
  .psaf-title { font-size: 24px; }
  .psaf-stats { grid-template-columns: 1fr 1fr; gap: 9px; }
  .psaf-stat { padding: 12px 13px; }
  .psaf-stat .v { font-size: 21px; }
  .psaf-copyrow { flex-wrap: wrap; }
  .psaf-copyrow input { width: 100%; flex: 1 0 100%; }
  .psaf-copyrow .psaf-btn { flex: 1; justify-content: center; }
  .psaf-tabs { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 2px; }
  .psaf-panel { overflow-x: auto; }
  .psaf-table { min-width: 620px; }
  .psaf-hero-btns .psaf-btn { flex: 1; padding: 0 18px; }
  .psaf-modal { border-radius: 12px; }
  .psaf-mbody { padding: 16px 16px 20px; }
}
