/* ============================================
   教练金钱大战 · iOS 高级质感
   System 主题 · 2026-10-04 改版
   ============================================ */

/* ===== CSS 变量 ===== */
:root {
  --bg: #f2f2f7;                 /* iOS 系统灰 */
  --bg-card: #ffffff;            /* 白卡片 */
  --bg-card-hover: #f8f8fc;
  --bg-input: #f5f5f7;
  --border: #e5e5ea;             /* 细分隔线 */
  --border-focus: #007aff;       /* iOS 蓝 */
  --text: #1d1d1f;               /* Apple 主文字 */
  --text-dim: #86868b;           /* 次级文字 */
  --text-bright: #000000;
  --gold: #f5a623;               /* 柔和金（金币） */
  --gold2: #ffb340;              /* 亮金 */
  --gold-dark: #c77f0f;
  --red: #ff3b30;                /* iOS 红 */
  --green: #34c759;              /* iOS 绿 */
  --blue: #007aff;               /* iOS 蓝 */
  --purple: #af52de;             /* iOS 紫 */
  --orange: #ff9500;
  --cyan: #32ade6;
  --pink: #ff2d55;
  --radius: 16px;
  --radius-sm: 12px;
  --shadow-gold: 0 4px 16px rgba(255, 149, 0, 0.18);
  --shadow-card: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.03);
}

/* ===== 全局 ===== */
* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

html, body {
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  font-size: 15px;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

/* iOS 简约：纯净系统灰背景，无光晕、无顶部装饰线 */

/* ===== 收集表容器 ===== */
.wrap {
  max-width: 520px;
  margin: 0 auto;
  padding: 0 12px 200px;
  position: relative;
  z-index: 1;
}

.header {
  text-align: center;
  padding: 34px 0 20px;
  position: relative;
}

/* 主标题：克制的深色 */
.header h1 {
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
  letter-spacing: 0.5px;
}

.header .sub {
  font-size: 13px;
  color: var(--text-dim);
  letter-spacing: 0.5px;
}

/* iOS 简约：标题下无装饰线 */

/* ===== 卡片：白色大圆角 ===== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 18px;
  margin-bottom: 12px;
  position: relative;
  overflow: hidden;
  transition: all 0.2s;
  box-shadow: var(--shadow-card);
}

/* iOS 简约：卡片无彩色竖条、无点缀圆点，统一白卡 */

/* 安全红线：极淡纯红提示（不用渐变），用专用 class 避免 nth-of-type 错位 */
.card-danger {
  border-color: rgba(255, 59, 48, 0.18);
  background: #fff5f5;
}

.card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 3px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding-left: 8px;
  letter-spacing: 0.3px;
}

/* 金币徽章：浅金胶囊 */
.card-title .badge {
  background: #fff3d6;
  color: #b8860b;
  font-size: 10px;
  padding: 3px 9px;
  border-radius: 999px;
  font-weight: 700;
  letter-spacing: 0.5px;
  border: 1px solid rgba(245, 166, 35, 0.25);
}

.card-desc {
  font-size: 12px;
  color: var(--text-dim);
  margin-bottom: 14px;
  padding-left: 8px;
}

/* ===== 表单项 ===== */
.field {
  margin-bottom: 14px;
}
.field:last-child { margin-bottom: 0; }

.field label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.field label .req {
  color: var(--red);
  margin-left: 2px;
  font-size: 11px;
}

.field label .opt {
  color: var(--text-dim);
  font-weight: 400;
  font-size: 12px;
  margin-left: 4px;
}

/* 输入框 */
input[type="date"],
input[type="text"],
select {
  width: 100%;
  padding: 12px 14px;
  font-size: 15px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text);
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  transition: all 0.2s;
}

input[type="date"]:focus,
select:focus {
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3.5px rgba(0, 122, 255, 0.12);
  background: #fff;
}

/* 日期选择器图标适配 */
input[type="date"]::-webkit-calendar-picker-indicator {
  opacity: 0.5;
  cursor: pointer;
}

/* 下拉箭头 */
select {
  background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%2386868b' d='M6 8L0 0h12z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  padding-right: 36px;
  cursor: pointer;
}

select option {
  background: var(--bg-card);
  color: var(--text);
}

/* ===== 复选框组 ===== */
.checkbox-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.checkbox-item {
  display: flex;
  align-items: center;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  cursor: pointer;
  transition: all 0.2s;
}

.checkbox-item:active {
  background: #ebebf0;
  transform: scale(0.99);
}

.checkbox-item input {
  margin-right: 10px;
  width: 19px;
  height: 19px;
  accent-color: var(--blue);
  cursor: pointer;
}

.checkbox-item.checked {
  border-color: rgba(0, 122, 255, 0.45);
  background: rgba(0, 122, 255, 0.05);
  box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.06);
}

.checkbox-item span {
  font-size: 14px;
  color: var(--text);
}

/* ===== 图片上传（iOS 实心浅灰） ===== */
.upload-box {
  position: relative;
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px;
  text-align: center;
  background: var(--bg-input);
  cursor: pointer;
  transition: all 0.2s;
}

.upload-box:hover,
.upload-box:active {
  background: rgba(0, 122, 255, 0.05);
}

.upload-box .icon {
  font-size: 28px;
  margin-bottom: 4px;
}

.upload-box .text {
  font-size: 12px;
  color: var(--text-dim);
}

.upload-box input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.upload-preview {
  margin-top: 8px;
  position: relative;
}

.upload-preview img {
  width: 100%;
  max-height: 140px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  display: block;
  background: var(--bg-input);
  border: 1px solid var(--border);
}

.upload-preview .remove {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(255, 59, 48, 0.92);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 26px;
  height: 26px;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* ===== 提交按钮：iOS 蓝主按钮 ===== */
.submit-btn {
  width: 100%;
  padding: 16px;
  font-size: 16px;
  font-weight: 600;
  color: #ffffff;
  background: var(--blue);
  border: none;
  border-radius: 14px;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0, 122, 255, 0.3);
  transition: all 0.2s;
  min-height: 52px;
  letter-spacing: 0.3px;
}

.submit-btn:active {
  transform: scale(0.98);
  background: #006fe6;
}

.submit-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* ===== 弹窗：毛玻璃 ===== */
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  padding: 20px;
}

.modal-mask.show { display: flex; }

.modal {
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 22px;
  padding: 32px 22px 24px;
  width: 100%;
  max-width: 360px;
  text-align: center;
  animation: pop 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

@keyframes pop {
  from { transform: scale(0.9); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

.modal .emoji {
  font-size: 48px;
  margin-bottom: 10px;
}

.modal h3 {
  font-size: 20px;
  color: var(--text);
  margin-bottom: 20px;
  font-weight: 700;
}

.modal .stat {
  background: linear-gradient(135deg, #fff6e0 0%, #fff0cc 100%);
  border: 1px solid rgba(245, 166, 35, 0.2);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 12px;
}

.modal .stat-label {
  font-size: 13px;
  color: var(--text-dim);
  margin-bottom: 6px;
}

.modal .stat-value {
  font-size: 34px;
  font-weight: 700;
  color: #f5a623;
}

.modal .tip {
  font-size: 13px;
  color: var(--text-dim);
  margin: 14px 0 20px;
}

.modal .monthly-summary {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin: 12px 0;
  text-align: left;
}

.modal .monthly-summary .ms-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.modal .monthly-summary .ms-title span {
  color: var(--text-dim);
  font-weight: 400;
  font-size: 12px;
  margin-left: 4px;
}

.modal .monthly-summary .ms-row {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  color: var(--text-dim);
  padding: 4px 0;
}

.modal .monthly-summary .ms-row .hl {
  color: #f5a623;
  font-weight: 600;
  font-size: 15px;
}

.modal .modal-btn {
  width: 100%;
  padding: 14px;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(135deg, #ffb340, #f5a623);
  border: none;
  border-radius: 12px;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: 0 3px 10px rgba(245, 166, 35, 0.3);
}

.modal .modal-btn:active {
  transform: scale(0.97);
}

/* ===== Toast ===== */
.toast {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(28, 28, 30, 0.88);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: #fff;
  padding: 12px 22px;
  border-radius: 999px;
  font-size: 13px;
  z-index: 1000;
  display: none;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.2);
}

.toast.show { display: block; }

/* ===== 顶部赚钱榜：毛玻璃 ===== */
.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(242, 242, 247, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 8px 12px 10px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.topbar-title {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #f5a623;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 6px;
}

.topbar-title .tb-icon {
  font-size: 14px;
}

.topbar-title .tb-month {
  margin-left: auto;
  color: var(--text-dim);
  font-size: 10px;
  font-weight: 400;
}

.topbar-list {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.topbar-list::-webkit-scrollbar { display: none; }

.tb-cell {
  flex: 1;
  min-width: 0;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 6px 4px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}

.tb-cell:active {
  background: rgba(0, 122, 255, 0.08);
  border-color: rgba(0, 122, 255, 0.35);
  transform: scale(0.96);
}

.tb-cell-empty {
  opacity: 0.35;
}

.tb-rank {
  font-size: 16px;
  line-height: 1;
  margin-bottom: 2px;
}

.tb-name {
  color: var(--text);
  font-size: 11px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.tb-bonus {
  color: #f5a623;
  font-size: 12px;
  font-weight: 700;
  margin-top: 2px;
}

/* ===== 个人战绩弹层 ===== */
.personal-modal .pm-rank {
  text-align: center;
  font-size: 14px;
  color: #f5a623;
  font-weight: 700;
  margin: -4px 0 14px;
}

.personal-modal .stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin-bottom: 14px;
}

.pm-title {
  font-size: 22px;
  margin: 8px 0 4px;
  color: var(--text);
  font-weight: 800;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin: 14px 0 10px;
}

.stats-item {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 10px;
  text-align: center;
}

.stats-num {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 4px;
}

.stats-num.blue { color: var(--blue); }
.stats-num.orange { color: var(--orange); }
.stats-num.green { color: var(--green); }
.stats-num.purple { color: var(--purple); }

.stats-lbl {
  font-size: 12px;
  color: var(--text-dim);
}

.stats-tip {
  text-align: center;
  font-size: 13px;
  color: #f5a623;
  font-weight: 600;
  padding: 8px 0 2px;
}

/* ===== 固定底部提交栏 ===== */
.submit-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px 14px calc(14px + env(safe-area-inset-bottom));
  background: rgba(242, 242, 247, 0.72);
  backdrop-filter: blur(20px) saturate(160%);
  -webkit-backdrop-filter: blur(20px) saturate(160%);
  border-top: 1px solid rgba(0,0,0,0.06);
  z-index: 40;
}

.submit-bar .submit-btn {
  margin: 0 auto;
  max-width: 520px;
  padding: 16px;
  min-height: 54px;
}

/* ===== 后台管理 ===== */
.admin-wrap {
  max-width: 1400px;
  margin: 0 auto;
  padding: 20px;
  position: relative;
  z-index: 1;
}

.admin-header {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 22px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-card);
}

.admin-header h1 {
  font-size: 22px;
  color: var(--text);
  margin-bottom: 6px;
  font-weight: 700;
}

.admin-header .meta {
  font-size: 13px;
  color: var(--text-dim);
}

.filter-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0;
  align-items: center;
}

.filter-bar select,
.filter-bar input {
  width: auto;
  min-width: 130px;
  padding: 8px 12px;
  font-size: 13px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text);
}

.filter-bar .btn {
  padding: 8px 18px;
  font-size: 13px;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
  transition: all 0.15s;
}

.filter-bar .btn-primary {
  background: #007aff;
  color: #fff;
}

.filter-bar .btn-default {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
}

.filter-bar .btn-export {
  background: #34c759;
  color: #fff;
}

/* 汇总卡片 */
.summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
  margin: 14px 0;
}

.summary-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow-card);
}

.summary-card .label {
  font-size: 12px;
  color: var(--text-dim);
  margin-bottom: 8px;
}

.summary-card .value {
  font-size: 26px;
  font-weight: 800;
}

.summary-card .value.blue { color: var(--blue); }
.summary-card .value.orange { color: var(--orange); }
.summary-card .value.green { color: var(--green); }

.coach-summary {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-card);
}

.coach-summary h3 {
  font-size: 15px;
  margin-bottom: 12px;
  color: var(--text);
  font-weight: 600;
}

.coach-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 10px;
}

.coach-item {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
}

.coach-item .name {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
}

.coach-item .row {
  font-size: 12px;
  color: var(--text-dim);
  display: flex;
  justify-content: space-between;
}

/* 表格 */
.table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: auto;
  box-shadow: var(--shadow-card);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 1200px;
}

thead th {
  background: var(--bg-input);
  padding: 12px 10px;
  text-align: left;
  font-weight: 600;
  color: var(--text-dim);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
  position: sticky;
  top: 0;
}

tbody td {
  padding: 10px;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  vertical-align: top;
}

tbody tr:hover {
  background: rgba(0, 122, 255, 0.03);
}

.thumb {
  width: 50px;
  height: 50px;
  object-fit: cover;
  border-radius: 8px;
  cursor: pointer;
  border: 1px solid var(--border);
}

.tag {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 600;
}

.tag-good { background: rgba(52, 199, 89, 0.12); color: #1d9e4e; }
.tag-bad { background: rgba(255, 59, 48, 0.12); color: #d92c22; }
.tag-warn { background: rgba(255, 149, 0, 0.14); color: #c77f0f; }
.tag-neutral { background: rgba(0, 122, 255, 0.12); color: #0a6ad4; }

.bonus-cell { font-weight: 700; color: #f5a623; }
.zero { color: var(--red); }

.empty {
  text-align: center;
  padding: 40px;
  color: var(--text-dim);
  font-size: 14px;
}

/* ===== 登录页 ===== */
.login-wrap {
  max-width: 380px;
  margin: 80px auto 0;
  padding: 20px;
  position: relative;
  z-index: 1;
}

.login-card {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 32px 24px;
  text-align: center;
  box-shadow: var(--shadow-card);
}

.login-card h2 {
  font-size: 20px;
  margin-bottom: 6px;
  color: var(--text);
  font-weight: 700;
}

.login-card .pin-tip {
  font-size: 13px;
  color: var(--text-dim);
  margin-bottom: 4px;
}

/* ===== 图片预览大图 ===== */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1001;
  padding: 20px;
  cursor: zoom-out;
}

.lightbox.show { display: flex; }

.lightbox img {
  max-width: 95%;
  max-height: 90vh;
  border-radius: 12px;
}

/* ===== 九宫格密码键盘 ===== */
.pin-display {
  display: flex;
  justify-content: center;
  gap: 14px;
  margin: 18px 0 22px;
}

.pin-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: transparent;
  transition: all 0.15s;
}

.pin-dot.filled {
  background: #f5a623;
  border-color: #f5a623;
  box-shadow: 0 0 8px rgba(245, 166, 35, 0.4);
  transform: scale(1.15);
}

.pin-dot.error {
  background: var(--red);
  border-color: var(--red);
  animation: pinShake 0.4s;
}

@keyframes pinShake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}

.pin-pad {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 320px;
  margin: 0 auto;
}

.pin-key {
  height: 56px;
  border: none;
  border-radius: 14px;
  background: var(--bg-input);
  font-size: 24px;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  transition: all 0.1s;
  user-select: none;
  -webkit-user-select: none;
  font-family: -apple-system, "SF Pro Display", "Segoe UI", sans-serif;
}

.pin-key:active {
  background: rgba(245, 166, 35, 0.2);
  transform: scale(0.94);
}

.pin-key.fn {
  background: transparent;
  color: var(--text-dim);
  font-size: 16px;
}

.pin-key.fn:active {
  background: var(--bg-input);
}

.pin-key.blank {
  background: transparent;
  cursor: default;
  pointer-events: none;
}

/* 登录页九宫格 */
.login-card .pin-display { margin: 22px 0 26px; }
.login-card .pin-pad { margin-bottom: 18px; }

/* 删除弹窗九宫格（紧凑版） */
#delModal .pin-display { margin: 14px 0 18px; }
#delModal .pin-pad { gap: 8px; }
#delModal .pin-key { height: 48px; font-size: 20px; border-radius: 11px; }

/* ===== 响应式 ===== */
@media (max-width: 640px) {
  .admin-wrap { padding: 12px; }
  table { font-size: 12px; min-width: 900px; }
  thead th, tbody td { padding: 8px 6px; }
  .header h1 { font-size: 22px; }
}

/* ===== 全员榜（后台） ===== */
.lb-list { margin-top: 12px; }
.lb-row {
  display: flex;
  align-items: center;
  padding: 12px 10px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border);
  margin-bottom: 8px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
}
.lb-row.lb-empty { opacity: 0.4; }
.lb-rank {
  width: 44px;
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  color: #f5a623;
  flex-shrink: 0;
}
.lb-info { flex: 1; padding: 0 12px; min-width: 0; }
.lb-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 2px;
}
.lb-sub { font-size: 11px; color: var(--text-dim); }
.lb-bonus {
  font-size: 18px;
  font-weight: 700;
  color: #f5a623;
  flex-shrink: 0;
}
.lb-empty-tip {
  text-align: center;
  padding: 16px;
  font-size: 13px;
  color: #f5a623;
  font-weight: 600;
}
.back-lb-btn {
  display: block;
  width: 100%;
  margin-top: 12px;
  padding: 10px;
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}
.back-lb-btn:active { background: var(--bg-input); }

/* 备案页脚 */
.beian-footer {
  text-align: center;
  padding: 20px 0 28px;
  margin-top: 28px;
  font-size: 12px;
  color: var(--text-dim, #999);
}
.beian-footer a {
  color: inherit;
  text-decoration: none;
}
.beian-footer a:active {
  opacity: .7;
}

/* ==================== 月度结算（仅朱威） ==================== */
.settle-entry {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  padding: 9px 18px;
  border: 1px solid rgba(245, 166, 35, .4);
  border-radius: 12px;
  background: rgba(245, 166, 35, .1);
  color: #c77f0f;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all .15s;
}
.settle-entry:active { transform: scale(.96); }

.settle-modal { max-width: 420px; text-align: left; padding: 26px 18px 20px; }
.settle-title { text-align: center; margin: 0 0 12px; }
.settle-month {
  display: flex; align-items: center; justify-content: center; gap: 18px;
  margin-bottom: 14px; font-size: 16px; font-weight: 700; color: var(--text);
}
.settle-month button {
  width: 34px; height: 34px; border-radius: 10px;
  border: 1px solid var(--border); background: var(--bg-input);
  color: var(--text); font-size: 18px; cursor: pointer;
}
.settle-month button:active { background: var(--bg-card-hover); }

.settle-list { max-height: 52vh; overflow-y: auto; margin-bottom: 16px; }
.settle-total {
  text-align: center; font-size: 13px; color: var(--text-dim);
  padding: 8px 0 12px; border-bottom: 1px dashed var(--border); margin-bottom: 10px;
}
.settle-total b { color: #f5a623; }
.settle-empty { text-align: center; color: var(--text-dim); font-size: 13px; padding: 18px 0; }

.st-row {
  display: flex; align-items: center; justify-content: space-between;
  padding: 11px 12px; border: 1px solid var(--border); border-radius: var(--radius-sm);
  margin-bottom: 8px; background: var(--bg-card);
}
.st-row.settled { border-color: rgba(52, 199, 89, .35); background: rgba(52, 199, 89, .05); }
.st-name { font-size: 14px; font-weight: 700; color: var(--text); }
.st-tag.ok {
  font-size: 11px; font-weight: 600; color: #1d9e4e;
  border: 1px solid rgba(52, 199, 89, .4); border-radius: 999px;
  padding: 1px 6px; margin-left: 4px;
}
.st-sub { font-size: 12px; color: var(--text-dim); margin-top: 3px; }
.st-sub b { color: #f5a623; }
.st-ops { display: flex; gap: 8px; align-items: center; }
.st-view {
  font-size: 12px; color: #c77f0f; text-decoration: none;
  border: 1px solid rgba(245, 166, 35, .4); border-radius: 8px; padding: 5px 10px;
}
.st-undo {
  font-size: 12px; color: #d92c22; border: 1px solid rgba(255, 59, 48, .35);
  border-radius: 8px; padding: 5px 10px; background: none; cursor: pointer; font-family: inherit;
}
.st-go {
  flex-shrink: 0; border: none; border-radius: 10px; padding: 8px 16px;
  background: linear-gradient(135deg, #ffb340, #f5a623); color: #fff;
  font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit;
  box-shadow: 0 3px 8px rgba(245, 166, 35, 0.3);
}
.st-go:active { transform: scale(.95); }

.st-form {
  border: 1px dashed rgba(245, 166, 35, .45); border-radius: var(--radius-sm);
  padding: 12px; margin: -4px 0 8px; background: rgba(245, 166, 35, .05);
}
.st-form-row { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.st-form-row label { flex-shrink: 0; width: 70px; font-size: 12px; color: var(--text-dim); }
.st-form-row input {
  flex: 1; min-width: 0; border: 1px solid var(--border); border-radius: 8px;
  background: var(--bg-input); color: var(--text); font-size: 14px; padding: 8px 10px;
  font-family: inherit;
}
.st-form-row .req { color: #d92c22; }
.st-form-btns { display: flex; gap: 8px; }
.st-form-btns button { flex: 1; border: none; border-radius: 10px; padding: 9px 0; font-size: 13px; font-weight: 600; cursor: pointer; font-family: inherit; }
.st-confirm { background: linear-gradient(135deg, #ffb340, #f5a623); color: #fff; }
.st-confirm:disabled { opacity: .6; }
.st-cancel { background: none; border: 1px solid var(--border) !important; color: var(--text-dim); }

/* 结算只读视图提示 */
.settle-ro-tip { margin-top: 4px; font-size: 11px; color: var(--text-dim); opacity: .8; }
.st-tag.wait {
  font-size: 11px; font-weight: 600; color: var(--text-dim);
  border: 1px dashed var(--border); border-radius: 999px;
  padding: 2px 8px; flex-shrink: 0;
}

/* 一键结算本月面板（关闭按钮上方；仅朱威可见） */
.settle-batch { margin: 0 0 12px; }
.settle-batch-btn {
  width: 100%; border: none; border-radius: 12px; padding: 12px 0;
  font-size: 14px; font-weight: 600; cursor: pointer; font-family: inherit;
  background: linear-gradient(135deg, #ffb340, #f5a623); color: #fff;
  box-shadow: 0 3px 10px rgba(245, 166, 35, 0.3);
  transition: transform .15s;
}
.settle-batch-btn:active { transform: scale(.98); }

/* ==================== 结算明细弹窗（点击人名弹出） ==================== */
.st-name-link { cursor: pointer; transition: opacity .15s; }
.st-name-link:active { opacity: .6; }

.settle-detail-modal { max-width: 460px; text-align: left; padding: 26px 18px 20px; }
.sd-head {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 17px; font-weight: 700; color: var(--text); margin-bottom: 6px;
}
.sd-head #sdMonth { color: var(--text-dim); font-size: 14px; font-weight: 400; }
.sd-sum {
  text-align: center; font-size: 13px; color: var(--text-dim);
  padding: 4px 0 12px; border-bottom: 1px dashed var(--border); margin-bottom: 12px;
}
.sd-sum b { color: #f5a623; font-size: 15px; }

.sd-list { max-height: 55vh; overflow-y: auto; margin-bottom: 14px; }
.sd-item {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--bg-input); padding: 10px 12px; margin-bottom: 8px;
}
.sd-row1 { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.sd-date { font-size: 13px; font-weight: 600; color: var(--text); }
.sd-bonus { font-size: 14px; font-weight: 700; color: #f5a623; }
.sd-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.sd-tag {
  display: inline-block; font-size: 11px; font-weight: 600;
  padding: 2px 7px; border-radius: 999px;
}
.sd-tag.ok   { background: rgba(52,199,89,.12); color: #1d9e4e; }
.sd-tag.warn { background: rgba(255,149,0,.14); color: #c77f0f; }
.sd-tag.bad  { background: rgba(255,59,48,.12); color: #d92c22; }
.sd-tag.dim  { background: rgba(142,142,147,.14); color: #8e8e93; }
.sd-note { margin-top: 6px; font-size: 11px; color: var(--text-dim); }

/* ==================== 赚钱榜待审核角标 + 个人课程列表 ==================== */
.tb-name { position: relative; }
.tb-badge {
  position: absolute;
  top: -4px;
  right: -8px;
  min-width: 16px;
  height: 16px;
  line-height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #ff3b30;
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  text-align: center;
  box-shadow: 0 1px 4px rgba(255, 59, 48, 0.4);
}

.pm-pending {
  text-align: center;
  font-size: 12px;
  font-weight: 700;
  color: #c77f0f;
  background: rgba(255, 149, 0, 0.1);
  border: 1px solid rgba(255, 149, 0, 0.3);
  border-radius: 999px;
  padding: 4px 12px;
  margin: -6px 0 8px;
  display: inline-block;
}

.personal-modal .pm-pending-wrap { text-align: center; }

.pm-list { margin-top: 14px; text-align: left; max-height: 46vh; overflow-y: auto; }
.pm-list-title {
  font-size: 14px; font-weight: 700; color: var(--text);
  padding-bottom: 8px; border-bottom: 1px solid var(--border); margin-bottom: 10px;
}
.pm-item {
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  background: var(--bg-input); padding: 10px 12px; margin-bottom: 8px;
}
.pm-row1 { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.pm-date { font-size: 13px; font-weight: 600; color: var(--text); }
.pm-status { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.pm-status.ok   { background: rgba(52,199,89,.12); color: #1d9e4e; }
.pm-status.warn { background: rgba(255,149,0,.14); color: #c77f0f; }
.pm-status.bad  { background: rgba(255,59,48,.12); color: #d92c22; }
.pm-row2 { display: flex; align-items: center; justify-content: space-between; margin-top: 6px; gap: 8px; }
.pm-bonus { font-size: 14px; font-weight: 700; color: #f5a623; }
.pm-thumb {
  width: 34px; height: 34px; object-fit: cover; border-radius: 8px;
  cursor: pointer; border: 1px solid var(--border); margin-left: 4px;
  flex-shrink: 0;
}
.pm-ops { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.rv-btn {
  border: none; border-radius: 8px; padding: 5px 12px;
  font-size: 12px; font-weight: 700; cursor: pointer;
  color: #fff; font-family: inherit;
}
.rv-btn.ok  { background: #34c759; }
.rv-btn.mid { background: #ff9500; }
.rv-btn.no  { background: #ff3b30; }
.rv-btn:disabled { opacity: .5; }
