/* ============================================================
   慧港教练 · 网页中台样式
   配色取自品牌 Logo：主蓝 #3068B8 / 亮蓝 #4088E0 / 辅橙 #E8901C
   ============================================================ */
:root {
  --brand: #3068B8;
  --brand-d: #1B3A63;
  --brand-dd: #122946;
  --brand-l: #4088E0;
  --brand-bg: #E8F0FB;
  --accent: #E8901C;
  --accent-l: #F0A840;
  --accent-bg: #FDF3E3;

  --bg: #F2F5F9;
  --cream: #FFFFFF;
  --line: #E6EDF4;
  --line2: #D8E3EE;
  --text: #1B2A3D;
  --text2: #445a75;
  --sub: #7C8CA0;
  --sub2: #9DACBE;

  --ok: #1E7A4B;
  --ok-bg: #EAF7F0;
  --warn: #C0453F;
  --warn-bg: #FBEDEC;
  --gold: #A6690F;
  --gold-bg: #FDF6E7;
  --cyan: #1F6E8C;
  --cyan-bg: #E9F3F8;

  --r: 12px;
  --r-sm: 8px;
  --sh: 0 4px 18px rgba(27, 58, 99, 0.07);
  --sh2: 0 10px 34px rgba(27, 58, 99, 0.16);
}

* { box-sizing: border-box; }
html, body { height: 100%; overflow: hidden; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 13px/1.6 -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}
a { color: inherit; text-decoration: none; }
.hidden { display: none !important; }
.muted { color: var(--sub); font-size: 12px; }
.row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.grow { flex: 1; min-width: 0; }
.mt8 { margin-top: 8px; } .mt12 { margin-top: 12px; } .mt16 { margin-top: 16px; }
.nowrap { white-space: nowrap; }
.mono { font-family: "SF Mono", Menlo, Consolas, monospace; font-size: 12px; }

/* ---------------- 登录 ---------------- */
.login-wrap {
  min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(150deg, #1B3A63 0%, #3068B8 62%, #4088E0 100%);
  position: relative; overflow: hidden;
}
.login-wrap::after {
  content: ''; position: absolute; width: 620px; height: 620px; border-radius: 50%;
  right: -180px; bottom: -260px;
  background: radial-gradient(circle, rgba(240,168,64,.28) 0%, rgba(240,168,64,0) 70%);
}
.login-box {
  position: relative; z-index: 2;
  width: 400px; background: #fff; border-radius: 18px; padding: 30px;
  box-shadow: 0 24px 70px rgba(0, 0, 0, .34);
}
.login-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.login-brand img { height: 42px; }
.login-brand b { font-size: 23px; letter-spacing: 2px; display: block; }
.login-brand span { font-size: 11px; color: var(--accent); letter-spacing: 1.5px; }
.login-tip {
  margin-top: 14px; padding: 10px 12px; border-radius: var(--r-sm);
  background: var(--brand-bg); color: #2B5A9E; font-size: 12px; line-height: 1.7;
}

/* ---------------- 布局 ---------------- */
#app { display: flex; height: 100vh; min-height: 0; }

.side {
  width: 222px; flex-shrink: 0; height: 100vh; overflow: hidden;
  background: linear-gradient(180deg, var(--brand-d) 0%, var(--brand-dd) 100%);
  color: #fff; display: flex; flex-direction: column;
}
.side-brand {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 16px 14px; border-bottom: 1px solid rgba(255, 255, 255, .1);
}
.side-brand img { height: 32px; }
.side-brand b { display: block; font-size: 17px; letter-spacing: 1.5px; }
.side-brand span { font-size: 10px; color: var(--accent-l); letter-spacing: 1px; }

#menu { flex: 1; overflow-y: auto; padding: 8px 0 16px; }
#menu .grp { padding: 12px 16px 5px; font-size: 10px; color: #8FB4DC; letter-spacing: 1.4px; }
#menu a {
  display: flex; align-items: center; gap: 9px;
  padding: 9px 16px; font-size: 13px; color: #D3E1F0;
  border-left: 3px solid transparent; cursor: pointer; transition: background .14s;
}
#menu a:hover { background: rgba(255, 255, 255, .07); }
#menu a.on { background: rgba(48, 104, 184, .34); border-left-color: var(--accent); color: #fff; font-weight: 600; }
#menu a .mi { width: 18px; text-align: center; font-size: 13px; opacity: .9; }
#menu a .badge {
  margin-left: auto; min-width: 18px; height: 18px; padding: 0 5px;
  border-radius: 9px; background: var(--warn); color: #fff;
  font-size: 10px; line-height: 18px; text-align: center;
}
.side-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 12px 14px; border-top: 1px solid rgba(255, 255, 255, .1); font-size: 12px;
}
.side-foot .who { overflow: hidden; }
.side-foot .who b { display: block; font-size: 12.5px; }
.side-foot .who span { font-size: 10.5px; color: #9FC3E8; }

.main { flex: 1; min-width: 0; display: flex; flex-direction: column; height: 100vh; overflow: hidden; }
.topbar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 13px 20px; background: #fff; border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 10px rgba(27, 58, 99, .05); z-index: 10;
}
.topbar .tb-title { flex: 1; min-width: 0; }
.topbar h1 { margin: 0; font-size: 17px; font-weight: 700; }
.topbar .crumb { font-size: 12px; color: var(--sub); margin-top: 2px; }

/* 返回上一页：桌面端顶栏左侧，走浏览器历史 */
.topbar .back {
  flex-shrink: 0; padding: 5px 12px 5px 9px; border-radius: 999px;
  font-size: 12.5px; font-weight: 600;
}
.topbar .back[disabled] { opacity: .38; cursor: not-allowed; }

.content { padding: 16px 20px 44px; flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; }

/* ---------------- 底部导航栏 ----------------
   所有有权限的功能页平铺成一条可横向滚动的快捷条。
   与左侧菜单同源（MENU），所以权限、角标口径天然一致；
   它挂在 .main 里而不是整窗底部，是为了不横跨左侧菜单。 */
.botnav {
  flex-shrink: 0; display: flex; align-items: center; gap: 6px;
  padding: 7px 14px; background: #fff; border-top: 1px solid var(--line);
  box-shadow: 0 -2px 10px rgba(27, 58, 99, .05);
  overflow-x: auto; overflow-y: hidden; z-index: 9;
  scrollbar-width: none;
}
.botnav::-webkit-scrollbar { height: 0; }
.botnav .bn-label {
  flex-shrink: 0; padding-right: 8px; margin-right: 2px;
  border-right: 1px solid var(--line);
  font-size: 10.5px; letter-spacing: 1px; color: var(--sub2);
  display: flex; align-items: center; gap: 5px;
}
.botnav a {
  flex-shrink: 0; display: flex; align-items: center; gap: 5px;
  padding: 5px 12px; border-radius: 999px; border: 1px solid transparent;
  font-size: 12px; color: var(--text2); white-space: nowrap; cursor: pointer;
  transition: background .14s, color .14s;
}
.botnav a:hover { background: var(--brand-bg); color: var(--brand); }
.botnav a.on { background: var(--brand); color: #fff; font-weight: 600; box-shadow: 0 2px 8px rgba(48, 104, 184, .3); }
.botnav a .mi { font-size: 12px; opacity: .9; }
.botnav a .badge {
  min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px;
  background: var(--warn); color: #fff; font-size: 10px; line-height: 16px; text-align: center;
}

/* 装修器要固定视口：内容区不滚，交给内部各列滚 */
body.app-locked #content { display: flex; flex-direction: column; overflow: hidden; padding-bottom: 14px; }

/* ---------------- 卡片 ---------------- */
.card { background: #fff; border-radius: var(--r); box-shadow: var(--sh); margin-bottom: 14px; overflow: hidden; }
.card-h { display: flex; align-items: center; gap: 8px; padding: 13px 16px; border-bottom: 1px solid var(--line); }
.card-h b { font-size: 14px; }
.card-h .right { margin-left: auto; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.pad { padding: 14px 16px; }
.pad0 { padding: 0; }

.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 1180px) { .grid3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 820px) { .grid2, .grid3 { grid-template-columns: 1fr; } }

/* ---------------- 按钮 ---------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 0; border-radius: var(--r-sm); padding: 8px 14px;
  font-size: 13px; font-weight: 600; cursor: pointer;
  background: var(--brand); color: #fff;
  box-shadow: 0 3px 10px rgba(48, 104, 184, .2);
  transition: transform .14s, opacity .14s;
}
.btn:active { transform: translateY(1px); }
.btn.sm { padding: 5px 10px; font-size: 12px; border-radius: 6px; }
.btn.ghost { background: #fff; border: 1px solid var(--line2); color: var(--text2); box-shadow: none; }
.btn.ghost:hover { border-color: var(--brand-l); color: var(--brand); }
.btn.accent { background: var(--accent); box-shadow: 0 3px 10px rgba(232, 144, 28, .22); }
.btn.dark { background: linear-gradient(135deg, var(--brand-d) 0%, var(--brand) 100%); }
.btn.danger { background: var(--warn); box-shadow: 0 3px 10px rgba(192, 69, 63, .2); }
.btn.wide { width: 100%; }
.btn[disabled], .btn.dis { opacity: .45; pointer-events: none; }

/* ---------------- 表单 ---------------- */
input, select, textarea {
  width: 100%; border: 1px solid var(--line2); border-radius: var(--r-sm);
  padding: 8px 11px; font-size: 13px; background: #fff; color: var(--text);
  outline: none; font-family: inherit; transition: border-color .14s;
}
input:focus, select:focus, textarea:focus { border-color: var(--brand-l); }
textarea { resize: vertical; line-height: 1.6; }
input[disabled], select[disabled], textarea[disabled] { background: #F4F7FA; color: var(--sub); }
label.f { display: block; margin: 10px 0 4px; font-size: 12px; color: var(--sub); }

.field { margin-bottom: 14px; }
.flabel { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; font-size: 12.5px; font-weight: 600; color: var(--text2); }
.flabel .req { color: var(--warn); font-style: normal; }
.flabel .fbadge { font-size: 10.5px; font-weight: 500; color: var(--sub); background: var(--bg); border-radius: 5px; padding: 1px 6px; }
.fctl { position: relative; display: flex; align-items: center; gap: 8px; }
.fctl > input, .fctl > select, .fctl > textarea { flex: 1; min-width: 0; }
.fhint { margin-top: 5px; font-size: 11.5px; color: var(--sub2); line-height: 1.6; }
.funit { flex-shrink: 0; font-size: 12px; color: var(--sub); }
.fro { flex: 1; padding: 8px 11px; border-radius: var(--r-sm); background: #F4F7FA; border: 1px dashed var(--line2); font-size: 12.5px; color: var(--text2); }
.fcolor { display: flex; gap: 8px; align-items: center; flex: 1; }
.fcolor input[type=color] { width: 46px; height: 34px; padding: 2px; flex-shrink: 0; }
.fimg { display: flex; flex-direction: column; gap: 8px; flex: 1; }
.fimg img { max-width: 100%; max-height: 160px; border-radius: var(--r-sm); border: 1px solid var(--line); object-fit: contain; background: #F7FAFC; }
.fimg .ph { padding: 22px; border: 1px dashed var(--line2); border-radius: var(--r-sm); color: var(--sub2); font-size: 12px; text-align: center; }
.fchks { display: flex; flex-wrap: wrap; gap: 8px 14px; }
.chk { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; cursor: pointer; }
.chk input { width: auto; }

/* 开关 */
.sw { position: relative; display: inline-block; width: 42px; height: 23px; flex-shrink: 0; }
.sw input { opacity: 0; width: 0; height: 0; position: absolute; }
.sw span { position: absolute; inset: 0; background: #C9D6E3; border-radius: 99px; transition: .18s; cursor: pointer; }
.sw span::after { content: ''; position: absolute; width: 17px; height: 17px; left: 3px; top: 3px; background: #fff; border-radius: 50%; transition: .18s; }
.sw input:checked + span { background: var(--brand); }
.sw input:checked + span::after { transform: translateX(19px); }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 760px) { .form-grid { grid-template-columns: 1fr; } }

/* ---------------- 徽标 ---------------- */
.pill {
  display: inline-block; font-size: 11px; padding: 1px 8px; border-radius: 6px;
  background: var(--bg); color: var(--sub); border: 1px solid var(--line);
  white-space: nowrap; line-height: 1.7;
}
.pill.blue { background: var(--brand-bg); color: #24559B; border-color: #C9DCF3; }
.pill.orange { background: var(--accent-bg); color: #9A5E0C; border-color: #F3DCB6; }
.pill.green { background: var(--ok-bg); color: var(--ok); border-color: #C9E7D8; }
.pill.red { background: var(--warn-bg); color: var(--warn); border-color: #EFC7C3; }
.pill.gold { background: var(--gold-bg); color: var(--gold); border-color: #EDD9A8; }
.pill.cyan { background: var(--cyan-bg); color: var(--cyan); border-color: #C7E1EC; }
.pill.gray { background: #EEF2F6; color: #6B7C90; border-color: #DFE6ED; }

/* ---------------- 表格 ---------------- */
.tbl { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.tbl th, .tbl td { padding: 9px 12px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl th { background: #F6F9FC; font-weight: 600; color: #55739A; white-space: nowrap; font-size: 12px; }
.tbl tbody tr:hover td { background: #F7FAFD; }
.tbl tbody tr.clickable { cursor: pointer; }
.tbl td .row { gap: 6px; }
.tbl-wrap { overflow-x: auto; }
.empty { padding: 46px 20px; text-align: center; color: var(--sub2); font-size: 13px; }

/* ---------------- KPI ---------------- */
.kpis { display: grid; grid-template-columns: repeat(auto-fill, minmax(158px, 1fr)); gap: 12px; margin-bottom: 14px; }
.kpi {
  background: #fff; border-radius: var(--r); padding: 15px;
  box-shadow: var(--sh); cursor: pointer; transition: transform .12s, box-shadow .12s;
  border-left: 3px solid var(--brand);
}
.kpi:hover { transform: translateY(-2px); box-shadow: 0 10px 24px rgba(27, 58, 99, .13); }
.kpi b { display: block; font-size: 23px; line-height: 1.2; color: var(--brand-d); font-weight: 700; }
.kpi i { font-style: normal; font-size: 14px; font-weight: 500; margin-right: 2px; }
.kpi span { font-size: 12px; color: var(--sub); }
.kpi small { display: block; margin-top: 5px; font-size: 11px; color: var(--sub2); }
.kpi.orange { border-left-color: var(--accent); } .kpi.orange b { color: #B06E0E; }
.kpi.green { border-left-color: var(--ok); } .kpi.green b { color: var(--ok); }
.kpi.red { border-left-color: var(--warn); } .kpi.red b { color: var(--warn); }
.kpi.cyan { border-left-color: var(--cyan); } .kpi.cyan b { color: var(--cyan); }

/* ---------------- 键值对 ---------------- */
.kvs { display: flex; flex-direction: column; }
.kv { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 8px 0; border-bottom: 1px dashed var(--line); }
.kv:last-child { border-bottom: 0; }
.kv > span { color: var(--sub); font-size: 12.5px; flex-shrink: 0; }
.kv > b { font-weight: 600; text-align: right; font-size: 12.5px; word-break: break-all; }

/* ---------------- 分段 / 筛选 ---------------- */
.seg { display: inline-flex; gap: 4px; padding: 4px; border-radius: 10px; background: #E4EBF3; }
.seg button {
  border: 0; background: transparent; padding: 6px 15px; border-radius: 7px;
  font-size: 12.5px; color: var(--text2); cursor: pointer; font-family: inherit;
}
.seg button.on { background: #fff; color: var(--brand-d); font-weight: 600; box-shadow: 0 2px 8px rgba(27, 58, 99, .09); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 5px 13px; border-radius: 99px; font-size: 12.5px;
  background: #fff; border: 1px solid var(--line2); color: var(--text2); cursor: pointer;
  transition: all .14s;
}
.chip:hover { border-color: var(--brand-l); }
.chip.on { background: var(--brand); border-color: var(--brand); color: #fff; font-weight: 600; }
.chip.on.orange { background: var(--accent); border-color: var(--accent); }
.chip.on.dark { background: var(--brand-d); border-color: var(--brand-d); }

.filters { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.filters input, .filters select { width: auto; min-width: 150px; }

/* ---------------- 弹窗 / 抽屉 / 提示 ---------------- */
.modal-mask {
  position: fixed; inset: 0; z-index: 900;
  background: rgba(18, 41, 70, .46);
  display: flex; align-items: center; justify-content: center;
  animation: fade .16s ease;
}
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.modal {
  background: #fff; border-radius: 16px; max-width: 92vw; max-height: 88vh;
  display: flex; flex-direction: column; box-shadow: var(--sh2);
  animation: pop .18s cubic-bezier(.2, .9, .3, 1.2);
}
@keyframes pop { from { transform: scale(.94); opacity: .4; } to { transform: scale(1); opacity: 1; } }
.modal-h { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal-h b { font-size: 15px; }
.modal-b { padding: 18px 20px; overflow-y: auto; }
.modal-f { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 20px; border-top: 1px solid var(--line); }
.x { cursor: pointer; color: var(--sub2); font-size: 14px; padding: 2px 6px; border-radius: 6px; }
.x:hover { background: var(--bg); color: var(--text); }

.drawer-mask {
  position: fixed; inset: 0; z-index: 880; background: rgba(18, 41, 70, .4);
  display: flex; justify-content: flex-end; opacity: 0; transition: opacity .2s;
}
.drawer-mask.on { opacity: 1; }
.drawer {
  background: #fff; height: 100%; max-width: 94vw; display: flex; flex-direction: column;
  transform: translateX(24px); transition: transform .22s cubic-bezier(.2, .8, .3, 1);
  box-shadow: -12px 0 40px rgba(18, 41, 70, .2);
}
.drawer-mask.on .drawer { transform: translateX(0); }
.drawer-h { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 17px 22px; border-bottom: 1px solid var(--line); }
.drawer-h b { font-size: 15.5px; }
.drawer-b { flex: 1; overflow-y: auto; padding: 18px 22px; }
.drawer-f { display: flex; justify-content: flex-end; gap: 10px; padding: 14px 22px; border-top: 1px solid var(--line); background: #FBFCFE; }

#toast-root { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 1000; display: flex; flex-direction: column; gap: 8px; align-items: center; pointer-events: none; }
.toast {
  padding: 9px 18px; border-radius: 99px; font-size: 13px;
  background: rgba(27, 58, 99, .94); color: #fff; box-shadow: 0 8px 24px rgba(0, 0, 0, .2);
  animation: pop .2s ease; max-width: 74vw;
}
.toast.ok { background: rgba(30, 122, 75, .95); }
.toast.err { background: rgba(192, 69, 63, .95); }
.toast.gold { background: rgba(166, 105, 15, .95); }

/* ---------------- 其他通用 ---------------- */
.bar { height: 6px; border-radius: 99px; background: var(--line); overflow: hidden; }
.bar > i { display: block; height: 100%; border-radius: 99px; background: var(--brand); }
.bar > i.orange { background: var(--accent); }

.stat-row { display: flex; align-items: center; justify-content: space-between; padding: 9px 0; border-bottom: 1px dashed var(--line); }
.stat-row:last-child { border-bottom: 0; }
.stat-row .nm { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--text2); }
.dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.stat-row .vl { font-weight: 700; font-size: 14px; color: var(--brand-d); }

.note { padding: 12px 14px; border-radius: var(--r-sm); font-size: 12.5px; line-height: 1.75; }
.note.info { background: var(--brand-bg); color: #2B5A9E; border: 1px solid #CFE0F5; }
.note.warn { background: var(--gold-bg); color: #8A5D13; border: 1px solid #EFDCB4; }
.note.green { background: var(--ok-bg); color: #175F3B; border: 1px solid #C9E7D8; }
.note.red { background: var(--warn-bg); color: #9E3B36; border: 1px solid #EFC7C3; }

.split { height: 1px; background: var(--line); margin: 14px 0; }

/* 订单/内容卡片（竖列列表用） */
.mini-list { display: flex; flex-direction: column; gap: 12px; }
.mini {
  border: 1px solid var(--line); border-radius: var(--r); padding: 13px 15px;
  background: #fff; transition: box-shadow .14s, border-color .14s;
}
.mini:hover { border-color: var(--line2); box-shadow: var(--sh); }
.mini-h { display: flex; align-items: center; gap: 9px; margin-bottom: 8px; flex-wrap: wrap; }
.mini-h b { font-size: 13.5px; }
.mini-h .right { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.mini-sub { font-size: 12px; color: var(--sub); margin-bottom: 8px; }
.mini-foot { display: flex; align-items: center; gap: 8px; margin-top: 11px; padding-top: 11px; border-top: 1px dashed var(--line); flex-wrap: wrap; }
.mini-foot .right { margin-left: auto; display: flex; gap: 6px; }

/* 拖拽排序视觉 */
.dragging { opacity: .45; }
.over { outline: 2px dashed var(--brand-l); outline-offset: -2px; }

/* ============================================================
   板块与领域（按业务方向组织内容资产）
   ------------------------------------------------------------
   领域宫格里每个卡片整体可点（<a data-key>），点进去是 #domain?key=…
   未上架用**琥珀色 + 虚线边框**，不用红色：
   下架是正常运营动作，不是错误状态（与装修器的幽灵条同一套口径）。
   ============================================================ */
.domgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(244px, 1fr)); gap: 10px; }
.domcard {
  display: block; padding: 12px 13px; cursor: pointer;
  border: 1px solid var(--line2); border-radius: var(--r-sm);
  background: #FBFDFF; color: inherit; text-decoration: none;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.domcard:hover { border-color: var(--brand-l); box-shadow: 0 6px 16px rgba(27, 58, 99, .10); transform: translateY(-1px); }
.domcard-h { display: flex; align-items: center; gap: 8px; margin-bottom: 3px; }
.domcard-h b { font-size: 13.5px; color: var(--brand-d); }
.domcard-h em {
  margin-left: auto; font-style: normal; font-size: 11px; white-space: nowrap;
  padding: 1px 7px; border-radius: 99px;
}
.domcard-h em.ok { background: var(--ok-bg); color: var(--ok); }
.domcard-h em.off { background: var(--gold-bg); color: var(--gold); }
.domcard-sub {
  font-size: 11.5px; color: var(--sub); line-height: 1.6; min-height: 19px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.domcard-f { display: flex; align-items: center; gap: 5px; margin-top: 9px; flex-wrap: wrap; }
.domcard-n { margin-left: auto; font-size: 11px; }
.domcard.has-off { border-style: dashed; background: #FFFDF7; }

/* ============================================================
   收费设置页（PAGES.payment）
   只用在本页的三组件：收费模式段控 / 通道行 / 客户端预览
   ============================================================ */

/* ---- 收费模式段控：接缝式，选中填主蓝 ---- */
.pseg {
  display: inline-flex; flex-wrap: wrap; max-width: 100%;
  border: 1px solid var(--line2); border-radius: var(--r-sm);
  overflow: hidden; background: var(--cream);
}
.pseg button {
  appearance: none; border: 0; border-right: 1px solid var(--line2);
  background: transparent; color: var(--text2); font: inherit; font-size: 12.5px;
  padding: 8px 15px; cursor: pointer; white-space: nowrap; transition: .14s;
}
.pseg button:last-child { border-right: 0; }
.pseg button:hover { background: var(--brand-bg); color: var(--brand); }
.pseg button.on { background: var(--brand); color: #fff; font-weight: 600; }

/* ---- 缴费通道 / 生效范围：左说明右开关 ---- */
.pay-ch { display: flex; flex-direction: column; }
.pay-ch-row {
  display: flex; align-items: center; gap: 14px;
  padding: 11px 0; border-top: 1px solid var(--line);
}
.pay-ch-row:last-child { border-bottom: 1px solid var(--line); }
.pay-ch-l { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.pay-ch-l b { display: flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; }
.pay-ch-l .muted { font-size: 11.5px; line-height: 1.55; }
.pay-ch-r { flex: 0 0 auto; display: flex; align-items: center; }
.pay-ch-r .field { margin: 0; }
.pay-ch-r .flabel:empty { display: none; }

/* ---- 客户端预览：还原课程卡底部的按钮形态 ---- */
.pay-pv {
  display: flex; flex-direction: column; gap: 9px;
  padding: 13px; border: 1px dashed var(--line2);
  border-radius: var(--r-sm); background: var(--bg);
}
.pay-pv-row { display: flex; align-items: center; gap: 12px; }
.pay-pv-l { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 1px; }
.pay-pv-l b { font-weight: 600; font-size: 12.5px; color: var(--text); }
.pay-pv-l .muted { font-size: 11px; }
.pay-pv-btn {
  flex: 0 0 auto; min-width: 140px;
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 8px 14px; border-radius: 99px;
  background: var(--brand); color: #fff;
  font-size: 12.5px; font-weight: 600; text-align: center;
  box-shadow: 0 2px 8px rgba(48, 104, 184, .22);
}
.pay-pv-btn i {
  font-style: normal; font-size: 10px; font-weight: 400; opacity: .82;
  padding-left: 7px; border-left: 1px solid rgba(255, 255, 255, .38);
}
.pay-pv-btn.off {
  background: #fff; color: var(--sub); font-weight: 400;
  border: 1px solid var(--line2); box-shadow: none;
}
.pay-pv-btn.off i { display: none; }

@media (max-width: 760px) {
  .pay-ch-row { align-items: flex-start; }
  .pay-pv-row { flex-direction: column; align-items: stretch; gap: 8px; }
  .pay-pv-btn { min-width: 0; }
}

/* 滚动条 */
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-thumb { background: #C9D6E3; border-radius: 99px; border: 2px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: #AFC2D4; background-clip: content-box; }
::-webkit-scrollbar-track { background: transparent; }

/* 响应式：窄屏折叠侧栏文字 */
@media (max-width: 980px) {
  .side { width: 62px; }
  .side-brand { justify-content: center; padding: 14px 0; }
  .side-brand div { display: none; }
  #menu .grp { display: none; }
  #menu a { justify-content: center; padding: 11px 0; }
  #menu a .mtxt { display: none; }
  .side-foot .who { display: none; }
}

/* 2026-11-25：教练 / 内容 / 系统 三页合并后的页签条 */
.hub-tabs { margin: 0 0 12px; display: inline-flex; }
.hub-body { min-height: 220px; }
.hub-tabs button[disabled] { opacity: .4; cursor: not-allowed; }
