/* TikTok Mall — 通用样式（前台 + 后台共用） */
* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: "Microsoft YaHei", "Segoe UI", system-ui, sans-serif;
    background: #f4f6fb;
    color: #1f2937;
}
.topbar {
    background: linear-gradient(90deg, #ff2d55, #fe2c55);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 20px;
}
.brand { font-weight: 800; font-size: 20px; letter-spacing: .5px; }
.nav a, .admin-menu a {
    color: #fff;
    text-decoration: none;
    margin-left: 14px;
    font-size: 14px;
    opacity: .92;
}
.nav a:hover { opacity: 1; text-decoration: underline; }
.container { max-width: 960px; margin: 22px auto; padding: 0 16px; }
.footer { text-align: center; color: #9ca3af; padding: 24px; font-size: 13px; }

.card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
    margin-bottom: 18px;
}
.card h2 { margin-top: 0; font-size: 18px; color: #111827; }
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 13px; color: #4b5563; margin-bottom: 6px; }
input[type=text], input[type=password], input[type=number], select, textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
}
input:focus, select:focus, textarea:focus { outline: none; border-color: #fe2c55; }
.btn {
    display: inline-block;
    background: #fe2c55;
    color: #fff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
}
.btn:hover { background: #e02649; }
.btn-secondary { background: #6b7280; }
.btn-secondary:hover { background: #4b5563; }
.row { display: flex; gap: 12px; flex-wrap: wrap; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px,1fr)); gap: 12px; }
.stat {
    background: #fff; border-radius: 12px; padding: 16px; text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
}
.stat .num { font-size: 22px; font-weight: 800; color: #fe2c55; }
.stat .lbl { font-size: 12px; color: #6b7280; margin-top: 4px; }

table { width: 100%; border-collapse: collapse; background: #fff; border-radius: 12px; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid #eef0f4; font-size: 13px; }
th { background: #2f5496; color: #fff; font-weight: 600; }
th:first-child { border-top-left-radius: 12px; }
th:last-child { border-top-right-radius: 12px; }
tr:nth-child(even) td { background: #fafbfe; }

.flash { padding: 12px 16px; border-radius: 8px; margin-bottom: 16px; font-size: 14px; }
.flash-ok { background: #dcfce7; color: #166534; }
.flash-error { background: #fee2e2; color: #991b1b; }

.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 12px; }
.badge-ok { background: #dcfce7; color: #166534; }
.badge-wait { background: #fef9c3; color: #854d0e; }
.badge-bad { background: #fee2e2; color: #991b1b; }
.badge-fail { background: #fee2e2; color: #991b1b; }

/* 后台（上：顶部栏 + 左：侧边栏 + 右：内容区） */
body.admin { background: #eef1f6; margin: 0; }
.admin-topbar {
    background: #1f2937; color: #fff;
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 22px;
}
.admin-topbar .brand { font-weight: 800; font-size: 17px; letter-spacing: .5px; }
.admin-topbar .who { color: #cbd5e1; font-size: 13px; }

.admin-wrap { display: flex; min-height: calc(100vh - 54px); }

/* 左侧菜单 */
.admin-side {
    width: 200px; flex-shrink: 0;
    background: #374151;
    padding: 12px 0;
    display: flex; flex-direction: column;
}
.admin-side a {
    color: #d1d5db; text-decoration: none;
    padding: 11px 18px; font-size: 14px;
    display: flex; align-items: center; gap: 10px;
    border-left: 3px solid transparent;
    transition: background .15s, color .15s;
}
.admin-side a:hover { background: #4b5563; color: #fff; }
.admin-side a.active {
    background: #4b5563; color: #fff; font-weight: 600;
    border-left-color: #fe2c55;
}
.admin-side a .ic { font-size: 16px; width: 20px; text-align: center; }
.admin-side a .lbl { flex: 1; }
.admin-submenu {
    margin: -4px 0 8px;
    padding: 3px 0 5px 30px;
    border-left: 1px solid #4b5563;
}
.admin-submenu a {
    display: block;
    color: #cbd5e1;
    padding: 7px 10px;
    font-size: 12px;
    border-left: 2px solid transparent;
}
.admin-submenu a:hover,
.admin-submenu a.active {
    color: #fff;
    background: #4b5563;
    border-left-color: #60a5fa;
}
.settings-subnav {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: -4px 0 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid #e5e7eb;
}
.settings-subnav a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 8px;
    color: #4b5563;
    background: #f3f4f6;
    text-decoration: none;
    font-size: 13px;
}
.settings-subnav a:hover,
.settings-subnav a.active {
    color: #1d4ed8;
    background: #dbeafe;
    font-weight: 600;
}

/* 右侧内容区 */
.admin-main {
    flex: 1; padding: 22px 24px; min-width: 0;
    max-width: 100%; box-sizing: border-box;
}
.admin-main .container { max-width: none; margin: 0; padding: 0; }
.admin-footer { text-align: center; color: #9ca3af; padding: 16px; font-size: 12px; background: #eef1f6; }

/* 侧边栏窄屏自适应 */
@media (max-width: 720px) {
    .admin-side { width: 60px; }
    .admin-side a .lbl { display: none; }
    .admin-side a { justify-content: center; padding: 12px 0; }
    .admin-main { padding: 16px; }
}

/* ============================================================
   会员端移动版（仅作用于 body.member，不影响后台桌面端）
   ============================================================ */
body.member { background: #f2f3f7; }
.member-topbar {
    position: sticky; top: 0; z-index: 20;
    justify-content: center; padding: 13px 16px;
    background: linear-gradient(90deg, #ff2d55, #fe2c55);
}
.member-topbar .brand { font-size: 18px; }
.member-footer { display: none; }
.member .container {
    max-width: 560px; margin: 0 auto; padding: 14px 14px 0;
}
.member--tab .container { padding-bottom: 86px; } /* 给底部 Tab 留白 */

/* 卡片：移动端更紧凑、圆角更大 */
.member .card { padding: 16px; border-radius: 14px; margin-bottom: 14px; }
.member .card h2 { font-size: 16px; margin-bottom: 12px; }

/* 表单：触控友好，输入框 16px 避免 iOS 聚焦缩放 */
.member input[type=text], .member input[type=password],
.member input[type=number], .member select, .member textarea {
    padding: 13px 14px; font-size: 16px;
}
.member .form-group { margin-bottom: 16px; }
.member .form-group label { font-size: 14px; margin-bottom: 7px; }

/* 按钮：移动端默认整行大按钮 */
.member .btn {
    display: block; width: 100%; padding: 14px; font-size: 16px;
    text-align: center; border-radius: 10px;
}
.member .btn-secondary { display: block; width: 100%; box-sizing: border-box; }
.member .row { flex-direction: column; gap: 10px; }

/* 统计卡片：两列网格 */
.member .grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
.member .stat { padding: 14px 10px; border-radius: 12px; }
.member .stat .num { font-size: 19px; }
.member .stat .lbl { font-size: 11px; }

/* 登录/注册卡片居中 */
.member .auth-wrap, .member .card.auth { max-width: 420px; margin: 8vh auto 0; }

/* 表格：窄屏横向滚动，表头固定底色 */
.member .table-wrap {
    width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch;
    border-radius: 10px;
}
.member table { font-size: 12px; white-space: nowrap; min-width: 100%; }
.member th, .member td { padding: 9px 10px; }
.member th { background: #fe2c55; } /* 会员端表头用品牌红，区别于后台蓝 */
.member tr:nth-child(even) td { background: #fafbfe; }

/* 底部固定 Tab 栏（App 风格） */
.bottom-tab {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
    display: flex; background: #fff;
    border-top: 1px solid #e5e7eb;
    box-shadow: 0 -2px 12px rgba(0,0,0,.07);
    padding: 6px 0 calc(6px + env(safe-area-inset-bottom, 0px));
}
.bottom-tab a {
    flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px;
    text-decoration: none; color: #6b7280; font-size: 11px; padding: 5px 2px;
}
.bottom-tab a .ic { font-size: 20px; line-height: 1; }
.bottom-tab a.active { color: #fe2c55; font-weight: 700; }
.bottom-tab a.active .ic { transform: scale(1.12); }
.member-global-tools {
    position: fixed; right: 12px; top: 8px; z-index: 40;
    display: flex; gap: 6px;
}
.member-global-tools a {
    color: #fff; background: rgba(0,0,0,.18); border: 1px solid rgba(255,255,255,.35);
    border-radius: 999px; padding: 4px 9px; font-size: 11px; text-decoration: none;
}
.online-dot { font-size: 12px; white-space: nowrap; }
.online-dot:before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 4px; background: #9ca3af; }
.online-dot.online { color: #059669; }
.online-dot.online:before { background: #10b981; }
.online-dot.offline { color: #6b7280; }

/* 我的：顶部用户头像卡 */
.me-profile {
    display: flex; align-items: center; gap: 14px;
    background: linear-gradient(135deg, #ff2d55, #fe2c55);
    color: #fff; padding: 18px 16px; border-radius: 14px;
    margin-bottom: 14px;
}
.me-avatar {
    width: 54px; height: 54px; border-radius: 50%;
    background: rgba(255,255,255,.22); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; font-weight: 800;
    border: 2px solid rgba(255,255,255,.45);
}
.me-info { flex: 1; min-width: 0; }
.me-name { font-size: 18px; font-weight: 700; }
.me-sub { font-size: 12px; opacity: .88; margin-top: 4px; }

/* 我的：余额大卡 */
.me-balance {
    background: #fff; border-radius: 14px; padding: 18px 16px;
    text-align: center; box-shadow: 0 2px 10px rgba(0,0,0,.05);
    margin-bottom: 14px;
}
.me-balance-lbl { font-size: 12px; color: #6b7280; }
.me-balance-num { font-size: 30px; font-weight: 800; color: #fe2c55; margin: 6px 0 12px; }
.me-balance-btn { width: 100%; }

/* 我的：三格统计 */
.me-stats {
    display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; margin-bottom: 14px;
}
.me-stat {
    background: #fff; border-radius: 12px; padding: 12px 8px; text-align: center;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
}
.me-stat .num { font-size: 15px; font-weight: 800; color: #fe2c55; }
.me-stat .lbl { font-size: 11px; color: #6b7280; margin-top: 3px; }

/* 我的：功能菜单列表（仿微信"我"的入口） */
.me-menu {
    background: #fff; border-radius: 14px;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
    overflow: hidden;
}
.me-item {
    display: flex; align-items: center; gap: 12px;
    padding: 14px 16px; text-decoration: none; color: #1f2937;
    border-bottom: 1px solid #f1f2f6; font-size: 15px;
}
.me-item:last-child { border-bottom: none; }
.me-item:active { background: #f7f8fb; }
.me-item .me-ic { font-size: 20px; width: 24px; text-align: center; }
.me-item .me-lbl { flex: 1; }
.me-item .me-arr { color: #c0c4cc; font-size: 18px; }
.me-item.me-disabled { color: #9ca3af; }
.me-item.me-logout { color: #fe2c55; font-weight: 600; }

/* 我的：银行卡信息键值对 */
.kv {
    display: flex; justify-content: space-between; align-items: center;
    padding: 12px 0; border-bottom: 1px solid #f1f2f6; font-size: 14px;
}
.kv:last-of-type { border-bottom: none; }
.kv span { color: #6b7280; }
.kv b { color: #1f2937; font-weight: 600; word-break: break-all; }

/* 桌面端（宽屏）也保持清爽：限制容器宽度，Tab 不变 */
@media (min-width: 600px) {
    .member .container { max-width: 560px; }
}

/* 后台派单：多行订单表 */
.dispatch-tbl { width: 100%; border-collapse: collapse; margin: 8px 0 4px; }
.dispatch-tbl th, .dispatch-tbl td { padding: 6px 8px; border-bottom: 1px solid #eee; font-size: 13px; }
.dispatch-tbl input, .dispatch-tbl select { width: 100%; padding: 6px 8px; border: 1px solid #d1d5db; border-radius: 6px; }
.row-del { background: #fee2e2; color: #b91c1c; border: none; padding: 4px 8px; border-radius: 6px; cursor: pointer; }

/* 会员端：按阶段分组订单 */
.stage-block { margin-bottom: 16px; border: 1px solid #eee; border-radius: 10px; overflow: hidden; }
.stage-head { background: #fff1f3; color: #be123c; padding: 8px 12px; font-weight: 700; display: flex; justify-content: space-between; }
.stage-head .stage-prog { font-weight: 400; color: #9ca3af; font-size: 12px; }
.stage-locked { padding: 14px 12px; color: #9ca3af; font-size: 13px; background: #fafafa; }
.order-row { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; border-top: 1px solid #f1f1f1; }
.order-row .o-meta { font-size: 13px; }
.order-row .o-meta b { color: #111827; }
.order-row .o-act a { color: #fe2c55; font-weight: 600; }
.order-row.done { opacity: .6; }
.order-row.done .o-act { color: #16a34a; }

/* 会员列表三点菜单 */
.ops-cell { width: 142px; text-align: right; }
.member-actions-wrap { display: inline-flex; align-items: center; justify-content: flex-end; gap: 6px; }
.member-lucky-shortcut {
  display: inline-flex; align-items: center; gap: 3px;
  color: #dc2626; background: #fff1f2; border: 1px solid #fecdd3;
  border-radius: 6px; padding: 5px 7px; font-size: 12px;
  font-weight: 700; white-space: nowrap; text-decoration: none;
}
.member-lucky-shortcut:hover, .member-lucky-shortcut:focus {
  color: #b91c1c; background: #ffe4e6; border-color: #fb7185; outline: none;
}
.member-menu { position: relative; display: inline-block; }
.member-menu:focus-within, .member-menu:hover { z-index: 9999; }
.member-menu-btn {
  background: transparent;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  padding: 2px 10px;
  cursor: pointer;
  font-size: 18px;
  line-height: 1.4;
  color: #374151;
  font-weight: 700;
  letter-spacing: 1px;
}
.member-menu-btn:hover, .member-menu-btn:focus { background: #f3f4f6; border-color: #9ca3af; outline: none; }
.member-menu-list {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  min-width: 120px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.10);
  padding: 4px 0;
  margin: 0;
  list-style: none;
  z-index: 9999;
  display: none;
}
.member-menu:focus-within .member-menu-list,
.member-menu:hover .member-menu-list { display: block; }
.member-menu-list li a {
  display: block;
  padding: 8px 14px;
  color: #374151;
  text-decoration: none;
  font-size: 14px;
  white-space: nowrap;
}
.member-menu-list li a:hover { background: #fff1f3; color: #be123c; }
.member-menu-list li a.menu-lucky-order {
  color: #dc2626;
  background: #fff1f2;
  font-weight: 700;
  border-left: 3px solid #ef4444;
  padding-left: 11px;
}
.member-menu-list li a.menu-lucky-order:hover,
.member-menu-list li a.menu-lucky-order:focus {
  color: #b91c1c;
  background: #ffe4e6;
  outline: none;
}
.menu-lucky-dot { color: #ef4444; font-size: 10px; vertical-align: 1px; }

/* 批量派单弹窗 */
.modal-mask {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  display: none;
  align-items: flex-start;
  justify-content: center;
  z-index: 1000;
  padding: 48px 16px;
  overflow-y: auto;
}
.modal {
  background: #fff;
  border-radius: 14px;
  width: 100%;
  max-width: 560px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
  padding: 20px 22px 24px;
}
.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  border-bottom: 1px solid #eef0f4;
  padding-bottom: 12px;
}
.modal-head h3 { margin: 0; font-size: 17px; color: #111827; }
.modal-bal {
  display: inline-block;
  margin-left: 10px;
  background: #fff1f3;
  color: #be123c;
  font-weight: 700;
  font-size: 13px;
  padding: 2px 10px;
  border-radius: 999px;
  vertical-align: middle;
}
.modal-x {
  background: transparent;
  border: none;
  font-size: 24px;
  line-height: 1;
  color: #9ca3af;
  cursor: pointer;
  padding: 0 4px;
}
.modal-x:hover { color: #374151; }
.modal-hint {
  background: #fffbeb;
  border: 1px solid #fde68a;
  color: #92400e;
  font-size: 12px;
  padding: 8px 10px;
  border-radius: 8px;
  margin: 0 0 12px;
}

/* ============================================================
   会员端：单订单顺序流程（预订页 / 详情 / 评论）
   ============================================================ */

/* ---- 预订页 hero（暗色，TikTok 风格） ---- */
.book-hero {
  display: flex; gap: 12px; align-items: flex-start;
  background: linear-gradient(135deg, #1f1f23 0%, #2a2a30 100%);
  color: #f3f4f6;
  border-radius: 14px;
  padding: 16px 14px;
  margin: 12px 0 14px;
}
.book-hero-l { flex: 1; min-width: 0; }
.book-h2 { font-size: 22px; margin: 0 0 10px; display: flex; align-items: center; gap: 6px; color: #fff; font-weight: 700; }
.book-h2 .book-ic { color: #fe2c55; font-size: 22px; }
.book-desc { font-size: 12px; line-height: 1.65; color: #d1d5db; margin: 0; }
.book-logo { width: 76px; height: 76px; flex-shrink: 0; align-self: center; }

/* ---- 统计 ---- */
.book-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.book-stat { background: #fff; border-radius: 12px; padding: 14px; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.book-stat-h { display: flex; align-items: center; gap: 6px; font-size: 13px; color: #6b7280; margin-bottom: 8px; }
.book-stat-h .book-ic { color: #fe2c55; font-size: 16px; }
.book-stat-h .book-q { margin-left: auto; color: #9ca3af; font-size: 12px; cursor: help; }
.book-stat-v { font-size: 20px; font-weight: 700; color: #111827; }

/* ---- CTA 按钮 ---- */
.book-cta-wrap { text-align: center; margin: 18px 0; }
.book-cta {
  display: inline-block;
  background: linear-gradient(90deg, #fe2c55 0%, #ff4d77 100%);
  color: #fff;
  font-size: 17px;
  font-weight: 700;
  padding: 14px 32px;
  border-radius: 999px;
  text-decoration: none;
  box-shadow: 0 4px 14px rgba(254,44,85,.35);
  min-width: 260px;
}
.book-cta--off { background: #d1d5db; box-shadow: none; color: #6b7280; cursor: not-allowed; }
.book-empty { font-size: 12px; color: #6b7280; margin-top: 12px; }

/* ---- 规则 ---- */
.book-rules { background: #fff; border-radius: 12px; padding: 12px 14px; font-size: 12px; color: #4b5563; line-height: 1.7; }
.book-rules p { margin: 0 0 6px; }
.book-rules p:last-child { margin-bottom: 0; }

/* ---- 详情/评论页：顶部 ---- */
.od-top { display: flex; align-items: center; gap: 8px; padding: 8px 4px 12px; }
.od-back { color: #6b7280; text-decoration: none; font-size: 26px; line-height: 1; padding: 2px 10px; }
.od-title { font-size: 17px; font-weight: 600; margin: 0; flex: 1; text-align: center; padding-right: 36px; }

/* ---- 详情/评论页：卡片 ---- */
.od-card { background: #fff; border-radius: 14px; padding: 0 0 20px; overflow: hidden; box-shadow: 0 1px 2px rgba(0,0,0,.05); }
.od-img { display: block; width: 240px; height: 240px; margin: 8px auto 14px; object-fit: contain; }
.od-name { font-size: 13px; color: #6b7280; line-height: 1.55; padding: 0 16px; margin: 0 0 14px; text-align: center; }
.od-rows { border-top: 1px solid #f3f4f6; }
.od-row { display: flex; justify-content: space-between; padding: 11px 16px; border-bottom: 1px solid #f3f4f6; font-size: 13px; }
.od-row span { color: #9ca3af; }
.od-row b { color: #111827; font-weight: 500; }
.od-row b.ok { color: #10b981; }
.od-submit {
  display: block; width: calc(100% - 32px); margin: 18px auto 4px;
  background: linear-gradient(90deg,#fe2c55,#ff4d77);
  color: #fff; text-align: center; font-size: 16px; font-weight: 700;
  padding: 13px 0; border-radius: 999px; border: none; cursor: pointer;
  box-shadow: 0 4px 14px rgba(254,44,85,.3); text-decoration: none;
  font-family: inherit;
}

/* ---- 三段进度条 ---- */
.prog3 { padding: 16px 24px 20px; }
.prog3-line { position: relative; height: 3px; background: #e5e7eb; border-radius: 2px; }
.prog3-fill { position: absolute; left: 0; top: 0; height: 100%; background: #fe2c55; border-radius: 2px; }
.prog3-dots { display: flex; justify-content: space-between; margin-top: -8px; }
.prog3-dot { display: block; width: 14px; height: 14px; border-radius: 50%; background: #e5e7eb; border: 2px solid #fff; box-sizing: border-box; }
.prog3-dot.on { background: #fe2c55; }
.prog3-labels { display: flex; justify-content: space-between; margin-top: 6px; font-size: 12px; color: #9ca3af; }
.prog3-labels b { font-weight: 500; }
.prog3-labels b.on { color: #fe2c55; font-weight: 700; }

/* ---- 待完成订单提示 ---- */
.pending-order-panel { padding: 30px 20px 24px; text-align: center; border-top: 1px solid #f3f4f6; border-bottom: 1px solid #f3f4f6; }
.pending-order-icon { width: 64px; height: 64px; margin: 0 auto 12px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: #fff1f3; color: #fe2c55; font-size: 30px; }
.pending-order-title { margin: 0; color: #111827; font-size: 19px; font-weight: 700; }
.pending-order-note { margin: 8px 0 0; color: #6b7280; font-size: 13px; }

/* ---- 评论页 ---- */
.rv-form { padding: 16px 16px 4px; }
.rv-stars { display: flex; justify-content: center; gap: 8px; font-size: 38px; color: #d1d5db; margin: 6px 0 10px; cursor: pointer; user-select: none; }
.rv-stars .rv-star.on { color: #fbbf24; }
.rv-comment { width: 100%; border: 1px solid #e5e7eb; border-radius: 8px; padding: 10px; font-size: 14px; resize: vertical; box-sizing: border-box; font-family: inherit; }
.rv-quick { display: block; margin: 8px auto 0; background: #fff7ed; color: #f97316; border: 1px solid #fed7aa; padding: 8px 18px; border-radius: 999px; font-size: 13px; cursor: pointer; font-family: inherit; }

/* ---- loading 蒙层 ---- */
.loading-mask { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.55); z-index: 1000; align-items: center; justify-content: center; }
.loading-mask.show { display: flex; }
.loading-box { background: #1f1f23; color: #fff; padding: 24px 32px; border-radius: 12px; text-align: center; min-width: 160px; }
.spinner { width: 36px; height: 36px; border: 3px solid #fe2c55; border-top-color: transparent; border-radius: 50%; animation: spin .8s linear infinite; margin: 0 auto 12px; }
@keyframes spin { to { transform: rotate(360deg); } }
.loading-txt { font-size: 14px; color: #f3f4f6; }

/* ---- 后台订单管理（搜索 + 行内编辑） ---- */
.order-search { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 8px 0 12px; }
.order-search input[type=text] { flex: 1; min-width: 220px; border: 1px solid #d1d5db; border-radius: 6px; padding: 8px 10px; font-size: 14px; font-family: inherit; }
.order-list { width: 100%; border-collapse: collapse; font-size: 13px; }
.order-list th, .order-list td { padding: 8px 10px; border-bottom: 1px solid #eef2f7; text-align: left; vertical-align: top; }
.order-list th { background: #f8fafc; color: #475569; font-weight: 600; }
.order-list tr:hover { background: #fafbff; }
.row-edit-btn { background: #2563eb; color: #fff; border: 0; padding: 4px 10px; border-radius: 5px; font-size: 12px; cursor: pointer; font-family: inherit; }
.row-edit-btn:hover { background: #1d4ed8; }
.order-select { width: 42px; text-align: center !important; }
.order-select input { width: 16px; height: 16px; cursor: pointer; }
.batch-toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 10px 0 12px; padding: 10px 12px; background: #f8fafc; border: 1px solid #e5e7eb; border-radius: 8px; font-size: 13px; }
.batch-toolbar label { display: inline-flex; align-items: center; gap: 6px; }
.batch-toolbar span { color: #6b7280; }
.batch-toolbar .btn { margin-left: auto; background: #2563eb; }
.batch-toolbar .btn:hover { background: #1d4ed8; }
.order-search select { min-width: 150px; width: auto; padding: 8px 10px; }
@media (max-width: 720px) {
  .batch-toolbar .btn { margin-left: 0; width: 100%; }
  .order-search select { min-width: 100%; width: 100%; }
}

/* ---- 余额不足充值弹窗 ---- */
.rc-modal-mask { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.55); z-index: 1100; align-items: center; justify-content: center; padding: 20px; box-sizing: border-box; }
.rc-modal-mask.show { display: flex; }
.rc-modal { background: #fff; width: 100%; max-width: 340px; border-radius: 16px; padding: 26px 22px 18px; text-align: center; box-shadow: 0 12px 40px rgba(0,0,0,.25); animation: rcpop .22s ease; }
@keyframes rcpop { from { transform: translateY(16px) scale(.96); opacity: 0; } to { transform: none; opacity: 1; } }
.rc-modal-ic { font-size: 42px; line-height: 1; margin-bottom: 8px; }
.rc-modal-title { font-size: 17px; font-weight: 700; color: #111827; margin: 0 0 6px; }
.rc-modal-sub { font-size: 13px; color: #6b7280; margin: 0 0 18px; }
.rc-amounts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.rc-amt { display: block; background: #fe2c55; color: #fff; text-decoration: none; padding: 14px 0; border-radius: 12px; font-size: 17px; font-weight: 700; }
.rc-amt:active { transform: scale(.97); }
.rc-other { display: inline-block; font-size: 13px; color: #2563eb; text-decoration: none; margin-bottom: 14px; }
.rc-close { width: 100%; background: #f3f4f6; color: #374151; border: 0; padding: 12px 0; border-radius: 12px; font-size: 14px; cursor: pointer; font-family: inherit; }
.rc-close:hover { background: #e5e7eb; }

/* ---- 会员充值申请页 ---- */
.rc-quick-row { display: flex; gap: 8px; margin: 10px 0 4px; flex-wrap: wrap; }
.rc-quick { flex: 1; min-width: 60px; text-align: center; background: #fff1f3; color: #fe2c55; border: 1px solid #ffd0d8; border-radius: 8px; padding: 9px 0; font-size: 13px; font-weight: 600; text-decoration: none; }
.rc-quick:hover { background: #ffe1e6; }
.rc-preset { font-size: 13px; color: #fe2c55; margin: 6px 0 0; }
.rc-note { font-size: 12px; color: #6b7280; margin-top: 12px; line-height: 1.5; }

/* ---- 幸运订单支付摘要 ---- */
.rc-summary { margin: 12px 0 10px; padding: 10px 12px; background: #fff7ed; border: 1px solid #fed7aa; border-radius: 10px; text-align: left; }
.rc-summary > div { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; color: #6b7280; line-height: 1.9; }
.rc-summary b { color: #374151; font-weight: 600; }
.rc-summary-total { border-top: 1px solid #fed7aa; margin-top: 4px; padding-top: 4px; color: #111827 !important; }
.rc-summary-total b { color: #fe2c55; font-size: 16px; }
.rc-modal-sub strong { color: #fe2c55; font-size: 16px; }
.rc-pay-note { font-size: 12px; color: #6b7280; margin: 0 0 10px; }
.od-row--total { border-top: 1px solid #f1f5f9; padding-top: 8px; margin-top: 4px; }
.od-row--total b { color: #fe2c55; }

/* 会员等级、首页内容与银行卡绑定 */
.vip-badge { display: inline-block; padding: 3px 8px; border-radius: 999px; background: #fff1f3; color: #be123c; font-size: 12px; font-weight: 700; white-space: nowrap; }
.vip-badge--light { background: rgba(255,255,255,.2); color: #fff; border: 1px solid rgba(255,255,255,.45); }
.home-vip { display: flex; align-items: center; gap: 8px; margin: 8px 0 10px; color: #6b7280; font-size: 13px; }
.home-welcome h2, .home-withdraw h2, .home-rules h2, .home-certificates h2 { margin-bottom: 8px; }
.home-welcome p, .home-rules p, .home-certificates p { color: #4b5563; line-height: 1.7; font-size: 13px; white-space: pre-wrap; }
.home-partner-images { display: grid; grid-template-columns: repeat(2,1fr); gap: 8px; margin-top: 12px; }
.home-partner-img { width: 100%; height: 120px; object-fit: cover; border-radius: 8px; background: #f3f4f6; }
.home-scroll { max-height: 190px; overflow: hidden; position: relative; }
.home-scroll ul { list-style: none; padding: 0; margin: 0; animation: homeScroll 18s linear infinite; }
.home-scroll li { display: flex; justify-content: space-between; gap: 8px; padding: 9px 0; border-bottom: 1px solid #f1f2f6; color: #4b5563; font-size: 13px; }
.home-scroll li small { color: #9ca3af; white-space: nowrap; }
.home-data-note { color: #9ca3af; font-size: 11px; margin: 10px 0 0; }
@keyframes homeScroll { from { transform: translateY(0); } to { transform: translateY(-45%); } }
.bank-bind-note { background: #fff7ed; border: 1px solid #fed7aa; color: #9a3412; padding: 10px; border-radius: 8px; font-size: 13px; line-height: 1.6; }
.bank-bound-badge { display: inline-block; padding: 4px 9px; border-radius: 999px; background: #dcfce7; color: #166534; font-size: 12px; margin-bottom: 8px; }
.menu-action { display: block; width: 100%; border: 0; background: transparent; color: #374151; text-align: left; padding: 8px 14px; font: inherit; font-size: 14px; cursor: pointer; }
.menu-action:hover { background: #fff1f3; color: #be123c; }
.modal-small { max-width: 380px; }
.modal-small .btn { margin-right: 8px; }

/* 最新会员端整改：左上角客服图标、任务进度、上下级与余额说明 */
.member-global-tools {
    left: 12px; right: auto; top: 8px;
    align-items: center;
}
.member-global-tools .member-cs-icon {
    width: 30px; height: 30px; padding: 0; display: inline-flex;
    align-items: center; justify-content: center; font-size: 18px;
    border-radius: 50%; background: rgba(0,0,0,.18);
}
.member-global-tools a.member-logout-link {
    position: fixed; right: 12px; top: 8px;
    padding: 4px 9px; font-size: 11px;
}
.member-global-tools .member-cs-disabled { opacity:.65; cursor:not-allowed; }
.member-global-tools .cs-code-status,
.login-bottom-tools .cs-code-status,
.me-cs-status { cursor: default; }
.task-progress-card {
    background: #fff; border-radius: 14px; padding: 16px; margin: 10px 0 14px;
    box-shadow: 0 2px 10px rgba(0,0,0,.05);
}
.task-progress-card > div:first-child { display:flex; align-items:center; justify-content:space-between; }
.task-progress-label { color:#6b7280; font-size:13px; }
.task-progress-card b { color:#fe2c55; font-size:26px; }
.task-progress-track { height:8px; background:#f1f2f6; border-radius:99px; overflow:hidden; margin:10px 0 6px; }
.task-progress-track i { display:block; height:100%; background:linear-gradient(90deg,#fe2c55,#ff7a9a); border-radius:99px; }
.task-progress-card small { color:#9ca3af; font-size:12px; }
.hierarchy-card h2 { margin-bottom: 4px; }
.hierarchy-row { display:flex; justify-content:space-between; gap:12px; padding:11px 0; border-bottom:1px solid #f1f2f6; font-size:13px; }
.hierarchy-row:last-child { border-bottom:0; }
.hierarchy-row > span { color:#6b7280; flex-shrink:0; }
.hierarchy-row b { text-align:right; word-break:break-all; }
.hierarchy-list { margin:0; padding-left:18px; text-align:right; list-style:none; }
.hierarchy-list li { margin-bottom:4px; }
.muted, .phone-preview-hint, .me-balance-note { color:#9ca3af; font-size:12px; }
.phone-preview-hint { margin:-8px 0 14px; }
.me-balance-note { margin:0; }
.reject-form { margin-top:8px; min-width:170px; }
.reject-form textarea { width:100%; font-size:12px; padding:6px 8px; margin-bottom:5px; }
.reject-form .btn { padding:6px 10px; font-size:12px; }

/* 充值拒绝原因展示（管理端/会员端共用） */
.rc-reject-reason { color: #b91c1c; font-size: 12px; margin-top: 4px; }
.admin .rc-reject-reason { font-size: 13px; }

/* 钱包 */
.wallet-head { display:flex; gap:12px; margin:14px 0; }
.wallet-head > div { flex:1; background:linear-gradient(135deg,#fe2c55,#ff5c7c); color:#fff; border-radius:14px; padding:16px; }
.wallet-bal-lbl, .wallet-commission .wallet-bal-lbl { color:rgba(255,255,255,.85); font-size:12px; }
.wallet-bal-num { font-size:26px; font-weight:700; margin-top:4px; }
.wallet-commission-num { font-size:22px; font-weight:700; margin-top:4px; }
.wallet-actions { display:flex; flex-direction:column; gap:12px; margin-bottom:14px; }
.wallet-form { background:#fff; border-radius:14px; padding:14px; box-shadow:0 1px 3px rgba(0,0,0,.06); }
.wallet-form .btn { margin-top:4px; }
.chg-tag { display:inline-block; padding:2px 8px; border-radius:8px; font-size:12px; background:#f1f5f9; color:#475569; }
.chg-balance { background:#e0f2fe; color:#0369a1; }
.chg-recharge { background:#dcfce7; color:#15803d; }
.chg-withdraw { background:#fee2e2; color:#b91c1c; }
.chg-commission { background:#fef9c3; color:#a16207; }
.chg-in { color:#15803d; font-weight:600; }
.chg-out { color:#b91c1c; font-weight:600; }

/* 冻结提示 */
.frozen-card { text-align:center; padding:30px 18px; }
.frozen-ic { font-size:46px; }
.frozen-card h2 { color:#b91c1c; }
.frozen-card p { color:#6b7280; margin:10px 0; }

/* 代理权限 */
.perm-toggle { display:inline-flex; align-items:center; gap:4px; font-size:13px; }
.perm-toggle input { vertical-align:middle; }

/* 登录/注册页语言切换器：放在底部操作区，和联系客服入口并列 */
.login-bottom-tools {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  margin-top: 14px; min-height: 34px;
}
.login-bottom-tools .login-cs-link { margin: 0; flex: 1; text-align: center; }
.login-bottom-tools .login-cs-link.cs-code-status { cursor: default; }
.login-bottom-tools .login-lang {
  position: static; display: inline-flex; flex: 0 0 auto;
}
.login-bottom-tools .login-lang form {
  display: inline-flex; align-items: center; gap: 4px; margin: 0;
  padding: 5px 8px; border: 1px solid #e5e7eb; border-radius: 999px;
  background: #f8fafc; font-size: 12px;
}
.login-bottom-tools .login-lang .ls-icon { font-size: 12px; color: #6b7280; }
.login-bottom-tools .login-lang select {
  max-width: 112px; padding: 1px 13px 1px 1px; border: 0; outline: 0;
  background: transparent; color: #374151; font-size: 12px; cursor: pointer;
}
.login-bottom-tools--register { justify-content: flex-end; }
/* 兼容旧版页面中仍使用的右上角语言切换器 */
.card-with-ls { position: relative; }
.card-with-ls > h2 { padding-right: 130px; }
.card-with-ls .lang-switcher-top {
  position: absolute;
  top: 10px;
  right: 12px;
  z-index: 5;
}
.card-with-ls .lang-switcher-top form {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin: 0;
  padding: 2px 6px;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1.4;
}
.card-with-ls .lang-switcher-top .ls-icon {
  font-size: 12px;
  color: #6b7280;
  cursor: default;
}
.card-with-ls .lang-switcher-top select {
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: 0;
  outline: 0;
  padding: 1px 14px 1px 2px;
  font-size: 12px;
  color: #374151;
  max-width: 92px;
  cursor: pointer;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'><path fill='%239ca3af' d='M0 2l4 4 4-4z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 2px center;
}
.card-with-ls .lang-switcher-top select:focus { color: #fe2c55; }

/* ============================================================
   会员端可切换色彩风格（由后台系统设置控制）
   ============================================================ */
body.member {
  --member-primary: #2563eb;
  --member-primary-dark: #1d4ed8;
  --member-primary-soft: #eff6ff;
  --member-primary-border: #bfdbfe;
  --member-bg: #f2f3f7;
  --member-surface: #fff;
  --member-text: #1f2937;
  --member-muted: #6b7280;
  --member-border: #f1f2f6;
  background: var(--member-bg);
  color: var(--member-text);
}
body.member.member-theme-blue {
  --member-primary: #2563eb;
  --member-primary-dark: #1d4ed8;
  --member-primary-soft: #eff6ff;
  --member-primary-border: #bfdbfe;
}
body.member.member-theme-black {
  --member-primary: #111827;
  --member-primary-dark: #030712;
  --member-primary-soft: #272b33;
  --member-primary-border: #4b5563;
  --member-bg: #0f1115;
  --member-surface: #181b21;
  --member-text: #f3f4f6;
  --member-muted: #a1a1aa;
  --member-border: #2b3039;
}
body.member.member-theme-yellow {
  --member-primary: #ca8a04;
  --member-primary-dark: #a16207;
  --member-primary-soft: #fefce8;
  --member-primary-border: #fde68a;
}
body.member.member-theme-cyan {
  --member-primary: #0891b2;
  --member-primary-dark: #0e7490;
  --member-primary-soft: #ecfeff;
  --member-primary-border: #a5f3fc;
}
body.member.member-theme-green {
  --member-primary: #16a34a;
  --member-primary-dark: #15803d;
  --member-primary-soft: #f0fdf4;
  --member-primary-border: #bbf7d0;
}
body.member .member-topbar {
  background: linear-gradient(90deg, var(--member-primary-dark), var(--member-primary));
}
body.member .card,
body.member .stat,
body.member .me-balance,
body.member .me-stat,
body.member .me-menu,
body.member .wallet-form,
body.member .book-stat,
body.member .book-rules,
body.member .od-card,
body.member .bottom-tab {
  background: var(--member-surface);
  color: var(--member-text);
}
body.member .card h2,
body.member .me-item,
body.member .kv b,
body.member .book-stat-v,
body.member .od-row b,
body.member .pending-order-title,
body.member .rc-modal-title {
  color: var(--member-text);
}
body.member .form-group label,
body.member .me-balance-lbl,
body.member .me-stat .lbl,
body.member .book-stat-h,
body.member .book-rules,
body.member .od-row span,
body.member .pending-order-note {
  color: var(--member-muted);
}
body.member input[type=text],
body.member input[type=password],
body.member input[type=number],
body.member select,
body.member textarea {
  background: var(--member-surface);
  color: var(--member-text);
  border-color: var(--member-border);
}
body.member input:focus,
body.member select:focus,
body.member textarea:focus {
  border-color: var(--member-primary);
}
body.member .btn,
body.member .rc-amt {
  background: var(--member-primary);
}
body.member .btn:hover,
body.member .rc-amt:hover {
  background: var(--member-primary-dark);
}
body.member .btn-secondary { background: #6b7280; }
body.member .stat .num,
body.member .me-balance-num,
body.member .me-stat .num,
body.member .task-progress-card b,
body.member .order-row .o-act a,
body.member .rc-preset,
body.member .rc-modal-sub strong,
body.member .rc-summary-total b,
body.member .od-row--total b {
  color: var(--member-primary);
}
body.member .member-global-tools .member-cs-icon,
body.member .member-global-tools a.member-logout-link {
  background: rgba(0,0,0,.18);
}
.member-global-tools .member-header-lang {
  position: fixed; right: 78px; top: 8px; z-index: 41;
  display: inline-flex; align-items: center;
}
.member-global-tools .member-header-lang form {
  display: inline-flex; align-items: center; gap: 3px; margin: 0;
  padding: 3px 7px; border: 1px solid rgba(255,255,255,.38);
  border-radius: 999px; background: rgba(0,0,0,.18);
}
.member-global-tools .member-header-lang .ls-icon {
  font-size: 12px; line-height: 1; cursor: default;
}
.member-global-tools .member-header-lang select {
  width: 78px; padding: 1px 11px 1px 1px; border: 0; outline: 0;
  color: #fff; background: transparent; font-size: 11px;
  appearance: none; -webkit-appearance: none; cursor: pointer;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='8' height='8' viewBox='0 0 8 8'><path fill='%23ffffff' d='M0 2l4 4 4-4z'/></svg>");
  background-repeat: no-repeat; background-position: right 1px center;
}
.member-global-tools .member-header-lang option { color: #111827; background: #fff; }
body.member .bottom-tab a.active { color: var(--member-primary); }
body.member .member th { background: var(--member-primary); }
body.member .me-profile,
body.member .wallet-head > div {
  background: linear-gradient(135deg, var(--member-primary-dark), var(--member-primary));
}
body.member .me-balance .me-balance-num { color: var(--member-primary); }
body.member .task-progress-track i,
body.member .prog3-fill {
  background: linear-gradient(90deg, var(--member-primary), var(--member-primary-dark));
}
body.member .book-stat-h .book-ic,
body.member .book-h2 .book-ic { color: var(--member-primary); }
body.member .book-cta,
body.member .od-submit {
  background: linear-gradient(90deg, var(--member-primary-dark), var(--member-primary));
  box-shadow: 0 4px 14px rgba(0,0,0,.20);
}
body.member .prog3-dot.on { background: var(--member-primary); }
body.member .pending-order-icon,
body.member .vip-badge,
body.member .rc-quick {
  background: var(--member-primary-soft);
  color: var(--member-primary);
  border-color: var(--member-primary-border);
}
body.member .stage-head {
  background: var(--member-primary-soft);
  color: var(--member-primary-dark);
}
body.member .me-item.me-logout { color: var(--member-primary); }
body.member .me-item,
body.member .kv,
body.member .od-row,
body.member .home-scroll li {
  border-color: var(--member-border);
}
body.member .rc-summary {
  background: var(--member-primary-soft);
  border-color: var(--member-primary-border);
}
body.member .rc-summary-total { border-color: var(--member-primary-border); }

/* 黑色质感：同时调整主要内容面的对比度，避免深色主题出现黑底黑字。 */
body.member.member-theme-black .topbar,
body.member.member-theme-black .member-topbar { color: #fff; }
body.member.member-theme-black .card,
body.member.member-theme-black .book-stat,
body.member.member-theme-black .book-rules,
body.member.member-theme-black .od-card,
body.member.member-theme-black .pending-order-panel,
body.member.member-theme-black .me-menu,
body.member.member-theme-black .wallet-form {
  border: 1px solid var(--member-border);
}
body.member.member-theme-black tr:nth-child(even) td,
body.member.member-theme-black table,
body.member.member-theme-black th,
body.member.member-theme-black td {
  background-color: var(--member-surface);
  color: var(--member-text);
}
body.member.member-theme-black .member th { background: var(--member-primary); }
body.member.member-theme-black .book-hero { background: linear-gradient(135deg, #050608 0%, #20242c 100%); }
body.member.member-theme-black .rc-modal,
body.member.member-theme-black .rc-close { background: var(--member-surface); color: var(--member-text); }
body.member.member-theme-black .rc-close { border: 1px solid var(--member-border); }
body.member.member-theme-black .me-item:active { background: #22262e; }
