:root {
  --primary: #1664ff;
  --primary-dark: #0d55e0;
  --bg: #f4f6f9;
  --panel: #ffffff;
  --border: #e6e9ee;
  --text: #1f2329;
  --muted: #8a9099;
  --ok: #16a34a;
  --err: #dc2626;
  --sidebar-w: 230px;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0;
  font-family: "Microsoft YaHei", "PingFang SC", system-ui, -apple-system, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
}
.hidden { display: none !important; }
a { color: var(--primary); text-decoration: none; }

/* ============ 登录页 ============ */
.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #eef3fb 0%, #f7f9fc 100%);
  padding: 20px;
}
.login-card {
  width: 390px;
  background: #fff;
  border-radius: 14px;
  padding: 34px 32px;
  box-shadow: 0 10px 34px rgba(20, 40, 80, .10);
  border: 1px solid var(--border);
}
.login-card h1 { font-size: 21px; margin: 0 0 4px; font-weight: 600; }
.login-card .sub { color: var(--muted); font-size: 13px; margin-bottom: 26px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; color: #5b6169; margin-bottom: 6px; }
.field input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #d9dde3;
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color .15s;
  background: #fff;
  color: var(--text);
}
.field input:focus { border-color: var(--primary); }
.btn {
  width: 100%;
  padding: 11px;
  border: none;
  border-radius: 8px;
  background: var(--primary);
  color: #fff;
  font-size: 15px;
  font-family: inherit;
  cursor: pointer;
  transition: background .15s;
}
.btn:hover { background: var(--primary-dark); }
.btn:disabled { opacity: .6; cursor: not-allowed; }
.alert { margin-top: 14px; padding: 10px 12px; border-radius: 8px; font-size: 13px; display: none; }
.alert.err { display: block; background: #fef2f2; color: #b91c1c; border: 1px solid #fecaca; }
.hint { margin-top: 18px; font-size: 12px; color: var(--muted); text-align: center; line-height: 1.7; }

/* ============ 主布局 ============ */
.layout { display: flex; min-height: 100vh; }
.sidebar {
  width: var(--sidebar-w);
  background: #fff;
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; bottom: 0; left: 0;
  overflow-y: auto;
  z-index: 20;
}
.logo {
  padding: 18px 20px;
  font-size: 16px;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 9px;
  position: sticky;
  top: 0;
  background: #fff;
}
.logo .dotm { width: 9px; height: 9px; border-radius: 50%; background: var(--primary); flex: none; }
.logo .logo-ico { width: 24px; height: 24px; object-fit: contain; flex: none; }

.login-logo {
  display: block;
  width: 200px;
  max-width: 90%;
  height: auto;
  margin: 0 auto 14px;
}
.nav { flex: 1; padding: 8px 0 16px; }
.nav-group { padding: 14px 20px 6px; font-size: 12px; color: var(--muted); }
.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 20px;
  cursor: pointer;
  color: #3d444d;
  font-size: 14px;
  border-left: 3px solid transparent;
  user-select: none;
}
.nav-item:hover { background: #f6f8fb; }
.nav-item.active { background: #eef4ff; color: var(--primary); border-left-color: var(--primary); font-weight: 600; }
.nav-item .ico { width: 16px; text-align: center; opacity: .85; font-size: 13px; }
.sidebar-foot { padding: 12px 20px; font-size: 12px; color: var(--muted); border-top: 1px solid var(--border); }

.main { margin-left: var(--sidebar-w); flex: 1; display: flex; flex-direction: column; min-width: 0; }
.topbar {
  height: 58px;
  background: #fff;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  position: sticky;
  top: 0;
  z-index: 10;
  gap: 16px;
}
.topbar h2 { font-size: 16px; margin: 0; font-weight: 600; white-space: nowrap; }
.userbox { display: flex; align-items: center; gap: 12px; font-size: 13px; color: #5b6169; }
.avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600; flex: none;
}
.linkbtn { color: var(--muted); cursor: pointer; font-size: 13px; }
.linkbtn:hover { color: var(--err); }
.content { padding: 22px 24px 48px; }

/* ============ 卡片 / 统计 ============ */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(186px, 1fr)); gap: 14px; }
.stat { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 16px 18px; }
.stat .k { font-size: 13px; color: var(--muted); }
.stat .v { font-size: 24px; font-weight: 600; margin-top: 8px; font-variant-numeric: tabular-nums; }
.stat .v.small { font-size: 18px; }

.section { margin-top: 24px; }
.section h3 { font-size: 15px; margin: 0 0 12px; font-weight: 600; }

.panel { background: #fff; border: 1px solid var(--border); border-radius: 12px; overflow: hidden; }
.toolbar {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px; border-bottom: 1px solid var(--border); flex-wrap: wrap;
}
.toolbar input[type=search] {
  padding: 8px 12px; border: 1px solid #d9dde3; border-radius: 8px;
  font-size: 13px; font-family: inherit; outline: none; min-width: 220px;
  background: #fff; color: var(--text);
}
.toolbar input[type=search]:focus { border-color: var(--primary); }
.toolbar .grow { flex: 1; }
.count { font-size: 13px; color: var(--muted); white-space: nowrap; }
.iconbtn {
  padding: 8px 14px; border: 1px solid #d9dde3; background: #fff; border-radius: 8px;
  font-size: 13px; font-family: inherit; cursor: pointer; color: var(--text);
}
.iconbtn:hover { border-color: #b9c0c9; }

/* ============ 表格 ============ */
.table-scroll { max-height: calc(100vh - 300px); overflow: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td {
  padding: 10px 14px; text-align: left; border-bottom: 1px solid #f0f2f5;
  white-space: nowrap; max-width: 360px; overflow: hidden; text-overflow: ellipsis;
}
th { background: #fafbfc; color: #5b6169; font-weight: 600; font-size: 12px; position: sticky; top: 0; z-index: 1; }
tbody tr:hover { background: #f9fbff; }
td.num { font-variant-numeric: tabular-nums; text-align: right; }
.empty { padding: 56px 20px; text-align: center; color: var(--muted); font-size: 14px; }
.empty .big { font-size: 30px; display: block; margin-bottom: 10px; opacity: .35; }
.loading { padding: 44px; text-align: center; color: var(--muted); font-size: 14px; }

.tag {
  display: inline-block; padding: 2px 9px; border-radius: 20px;
  font-size: 12px; background: #eef1f5; color: #5b6169;
}
.tag.ok { background: #e8f7ee; color: #15803d; }
.tag.warn { background: #fef6e7; color: #b45309; }
.tag.err { background: #fdecec; color: #b91c1c; }
.tag.info { background: #eaf1ff; color: #1d4ed8; }

.pager {
  display: flex; align-items: center; justify-content: flex-end; gap: 8px;
  padding: 12px 16px; border-top: 1px solid var(--border);
  font-size: 13px; color: #5b6169;
}
.pager button {
  padding: 6px 12px; border: 1px solid #d9dde3; background: #fff;
  border-radius: 6px; cursor: pointer; font-family: inherit; font-size: 13px; color: var(--text);
}
.pager button:disabled { opacity: .45; cursor: not-allowed; }

/* ============ 键值展示 ============ */
.kv { display: grid; grid-template-columns: 210px 1fr; font-size: 13px; }
.kv .k { padding: 11px 16px; color: var(--muted); border-bottom: 1px solid #f0f2f5; background: #fafbfc; }
.kv .v { padding: 11px 16px; border-bottom: 1px solid #f0f2f5; word-break: break-all; }

/* 服务状态列表 */
.svc-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.svc {
  display: flex; align-items: center; gap: 10px;
  background: #fff; border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px;
}
.svc .dot { width: 9px; height: 9px; border-radius: 50%; background: #c9ced6; flex: none; }
.svc .dot.on { background: var(--ok); }
.svc .dot.off { background: var(--err); }
.svc .name { font-size: 14px; font-weight: 600; }
.svc .meta { font-size: 12px; color: var(--muted); margin-top: 3px; }

/* ============ 行内操作按钮 ============ */
button.mini {
  padding: 3px 10px;
  margin-right: 6px;
  font-size: 12px;
  font-family: inherit;
  border: 1px solid #d9dde3;
  background: #fff;
  color: var(--primary);
  border-radius: 6px;
  cursor: pointer;
}
button.mini:hover { border-color: var(--primary); background: #f5f8ff; }
button.mini.danger { color: var(--err); }
button.mini.danger:hover { border-color: var(--err); background: #fff5f5; }
.iconbtn.primary { background: var(--primary); border-color: var(--primary); color: #fff; }
.iconbtn.primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }

/* ============ 弹窗 ============ */
.modal-mask {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(17, 24, 39, .45);
  display: flex; align-items: flex-start; justify-content: center;
  padding: 56px 16px;
  overflow-y: auto;
}
.modal {
  width: 100%; max-width: 560px;
  background: #fff; border-radius: 12px;
  box-shadow: 0 18px 50px rgba(15, 30, 60, .28);
  overflow: hidden;
}
.modal-head {
  padding: 16px 20px; font-size: 15px; font-weight: 600;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.modal-head .close { cursor: pointer; color: var(--muted); font-size: 15px; padding: 0 4px; }
.modal-head .close:hover { color: var(--err); }

.form-body { padding: 18px 20px; max-height: 62vh; overflow-y: auto; }
.form-row { margin-bottom: 14px; }
.form-row.actions { margin-top: 6px; }
.form-row label { display: block; font-size: 13px; color: #5b6169; margin-bottom: 6px; }
.form-row input[type=text],
.form-row input[type=number],
.form-row input[type=date],
.form-row input[type=datetime-local],
.form-row select,
.form-row textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid #d9dde3;
  border-radius: 8px;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  background: #fff;
  color: var(--text);
  box-sizing: border-box;
}
.form-row input:focus, .form-row select:focus, .form-row textarea:focus { border-color: var(--primary); }
.form-row textarea { resize: vertical; }
.form-row .tip { font-size: 12px; color: var(--muted); margin-top: 5px; }

.modal-foot {
  padding: 14px 20px; border-top: 1px solid var(--border);
  display: flex; justify-content: flex-end; gap: 10px; background: #fafbfc;
}

/* ============ 提示条 ============ */
.toast {
  position: fixed; top: 24px; left: 50%; transform: translate(-50%, -12px);
  background: #111827; color: #fff;
  padding: 11px 20px; border-radius: 9px; font-size: 13px;
  opacity: 0; transition: opacity .25s, transform .25s;
  z-index: 200; box-shadow: 0 8px 24px rgba(0, 0, 0, .22);
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.err { background: var(--err); }

/* ============ 利润明细页标签（结算导入 / 系统核算） ============ */
.ptab {
  display: inline-block; padding: 5px 14px; margin-left: 2px;
  font-size: 12.5px; color: var(--muted, #6b7280);
  border: 1px solid var(--border, #d9dde3); border-radius: 999px;
  cursor: pointer; user-select: none; line-height: 1.4;
  transition: background .15s, color .15s, border-color .15s;
}
.ptab:hover { color: var(--primary, #1a56db); border-color: var(--primary, #1a56db); }
.ptab.on {
  background: var(--primary, #1a56db); color: #fff;
  border-color: var(--primary, #1a56db); font-weight: 600;
}
/* Settlement report retains the full source worksheet column order. */
.settlement-head { margin-bottom: 14px; }
.settlement-hint { margin: 0; padding: 0 16px 12px; color: #8a9099; font-size: 13px; }
.settlement-filters { flex-wrap: wrap; }
.settlement-filters select, .settlement-filters input { padding: 7px 10px; border: 1px solid #d9dde3; border-radius: 6px; font: inherit; background: #fff; }
.settlement-filters label { display: flex; align-items: center; gap: 8px; color: #626976; font-size: 13px; }
.settlement-summary { margin-bottom: 14px; padding: 16px; }
.settlement-summary .cards { margin-top: 12px; }
.settlement-table { max-height: 620px; }
.settlement-table th { position: sticky; top: 0; z-index: 2; background: #f8f9fb; }
.settlement-table th:first-child, .settlement-table td:first-child { position: sticky; left: 0; background: #fff; z-index: 1; min-width: 190px; border-right: 1px solid #edf0f4; }
.settlement-table th:first-child { z-index: 3; background: #f8f9fb; }
.settlement-number { text-align: right; font-variant-numeric: tabular-nums; }
#s-error { color: #d14343; padding: 0 16px 12px; font-size: 13px; }

/* Business workspace theme: shared by every admin module. */
:root {
  --primary: #245b83;
  --primary-dark: #174566;
  --bg: #f2f4f7;
  --border: #e3e8ee;
  --text: #203247;
  --muted: #78889b;
  --sidebar-w: 244px;
}
body { font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; -webkit-font-smoothing: antialiased; background: radial-gradient(ellipse at 100% 0, #e8eef5 0, transparent 45%), var(--bg); }
button, input, select, textarea { font-family: inherit; }
.sidebar { background: linear-gradient(165deg, #152d42, #102233 75%); border-right: 0; color: #fff; overflow: hidden; box-shadow: 4px 0 24px #12283d0c; }
.logo { min-height: 88px; padding: 22px 24px; background: #152d42; border-bottom: 1px solid #ffffff12; gap: 12px; flex-shrink: 0; letter-spacing: .6px; z-index: 2; }
.logo .logo-ico { width: 34px; height: 34px; background: #fff; padding: 4px; border-radius: 10px; }
#logo-text { font-size: 18px; color: #f4f7fc; }
.brand-caption { display: block; font-size: 9px; font-weight: 500; color: #94acbe; letter-spacing: 1.6px; margin-top: 3px; }
.nav { overflow-y: auto; padding: 10px 12px 22px; scrollbar-width: thin; scrollbar-color: #476074 transparent; }
.nav-group { padding: 20px 14px 8px; font-size: 15px; font-weight: 600; letter-spacing: .5px; color: #b7c9d9; }
.nav-item { position: relative; padding: 10px 14px; margin: 3px 0; min-height: 40px; border: 0; border-radius: 7px; gap: 12px; color: #bdccda; font-size: 13px; transition: background .18s, color .18s; }
.nav-item .ico { width: 20px; font-size: 16px; color: #89a2b8; }
.nav-item:hover { background: #ffffff09; color: #fff; }
.nav-item.active { background: linear-gradient(90deg, #2d526c, #24465e); color: #fff; box-shadow: inset 0 0 0 1px #ffffff0b; }
.nav-item.active::before { content: ""; position: absolute; left: 0; width: 3px; height: 18px; border-radius: 3px; background: #d9b97b; }
.nav-item.active .ico { color: #e2c58c; }
.sidebar-foot { flex-shrink: 0; border-top-color: #ffffff12; color: #829aae; background: #102233; font-size: 11px; line-height: 1.8; padding: 14px 24px; }
.topbar { height: 88px; padding: 0 32px; background: #ffffffed; backdrop-filter: blur(14px); border-bottom: 1px solid #dde5ec; }
.page-heading { min-width: 0; }
.workspace-caption { display: block; font-size: 11px; color: #8b99a8; letter-spacing: 1px; margin-bottom: 5px; }
.topbar h2 { font-size: 21px; color: #203247; font-weight: 650; letter-spacing: .5px; }
.userbox { gap: 12px; color: #566b80; }
.avatar { height: 36px; width: 36px; border-radius: 11px; background: #e9eff5; color: #245b83; border: 1px solid #dbe4ed; }
.linkbtn { padding-left: 16px; border-left: 1px solid var(--border); font-size: 12px; }
.content { padding: 28px 32px 48px; max-width: 1920px; width: 100%; margin: 0 auto; }
.panel { border-radius: 12px; box-shadow: 0 4px 20px #20324704; }
.toolbar { padding: 18px 22px; gap: 10px; min-height: 72px; }
.toolbar b { color: #253d53; font-weight: 650; }
.toolbar .count { font-size: 12px; }
.toolbar input[type=search] { min-width: 180px; width: 220px; background: #f7f9fb; padding: 10px 13px; border-color: #e1e7ed; }
.iconbtn { padding: 9px 14px; border-color: #dce4eb; border-radius: 7px; font-size: 12px; color: #476078; transition: background .18s, border-color .18s; }
.iconbtn:hover { background: #f1f5f8; border-color: #9cafbe; }
.iconbtn.primary { box-shadow: 0 3px 8px #245b8318; }
.cards { gap: 16px; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
.stat { position: relative; padding: 22px; border-radius: 10px; background: linear-gradient(135deg, #fff, #f8fafc); border-color: #e2e8ef; }
.stat::before { content: ""; display: block; width: 24px; height: 3px; background: #b9cddd; border-radius: 3px; margin-bottom: 16px; }
.stat:nth-child(3n)::before { background: #ccb27d; }
.stat .k { font-size: 12px; color: #718398; }
.stat .v { font-size: 28px; font-weight: 650; letter-spacing: -.7px; color: #1f425e; margin-top: 10px; }
.section { margin-top: 24px; }
.section h3 { color: #304b62; font-size: 15px; }
th { background: #f4f7fa; color: #697d90; padding: 14px 16px; font-size: 11px; border-bottom: 1px solid #e3eaf0; }
td { padding: 15px 16px; color: #41556a; border-bottom-color: #edf1f5; font-size: 12px; font-variant-numeric: tabular-nums; }
tbody tr:nth-child(even) { background: #fbfcfd; }
tbody tr:hover { background: #f0f5f9; }
.table-scroll { scrollbar-width: thin; scrollbar-color: #bbc9d5 #f4f7fa; }
.tag { border-radius: 5px; padding: 3px 9px; background: #edf2f6; color: #657b8f; font-size: 11px; }
.pager { padding: 16px 22px; background: #fcfdfe; color: #7b8b9c; font-size: 12px; }
.pager button { border-color: #e0e7ed; padding: 7px 12px; }
.ptab { border-radius: 6px; padding: 7px 12px; font-size: 12px; border-color: transparent; background: #f2f5f8; color: #73879a; }
.ptab.on { background: #e7eff5; color: #245b83; border-color: #cedde8; }
.empty { padding: 44px 24px; color: #8a9bac; font-size: 13px; }
.empty::before { content: ""; display: block; width: 34px; height: 28px; margin: 0 auto 14px; border: 1.5px solid #bdcbd7; border-radius: 5px; background: repeating-linear-gradient(0deg, transparent 0 7px, #dce5ed 7px 8px); }
.svc { border-radius: 10px; box-shadow: 0 3px 16px #20324704; }
.modal { border-radius: 14px; box-shadow: 0 24px 80px #10223340; }
.modal-mask { background: #10223380; backdrop-filter: blur(4px); }
.modal-head { padding: 20px 24px; color: #253d53; }
.form-body { padding: 22px 24px; }
input:focus-visible, select:focus-visible, textarea:focus-visible, button:focus-visible, .ptab:focus-visible { outline: 2px solid #5e8dad; outline-offset: 3px; }
.login-wrap { background: radial-gradient(ellipse at 20% 20%, #294b65 0, transparent 55%), linear-gradient(140deg, #102233, #18374f); }
.login-card { width: 420px; padding: 40px 36px; border-radius: 16px; border-top: 3px solid #c4a46b; box-shadow: 0 24px 80px #0004; }
.login-card h1 { color: #253d53; text-align: center; font-size: 20px; }
.login-card .sub { text-align: center; margin-top: 8px; font-size: 12px; }
.login-card .btn { background: #245b83; }
@media (max-width: 1280px) { :root { --sidebar-w: 220px; } .content { padding: 24px; } .topbar { padding: 0 24px; } .toolbar { gap: 8px; padding: 16px; } }
@media (max-width: 760px) { :root { --sidebar-w: 180px; } .logo { padding: 20px 14px; gap: 8px; } #logo-text { font-size: 16px; } .brand-caption { font-size: 8px; letter-spacing: .5px; } .nav { padding: 8px; } .nav-item { padding: 10px; gap: 8px; } .content { padding: 16px 12px; } .topbar { height: 76px; padding: 0 16px; } .topbar h2 { font-size: 18px; } .userbox { gap: 8px; } #who { max-width: 100px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .workspace-caption { letter-spacing: 0; } .cards { grid-template-columns: 1fr; } .toolbar .grow { display: none; } .toolbar input[type=search] { width: 100%; min-width: 0; } .sidebar-foot { padding: 12px; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; } }

.profit-views { display: flex; gap: 24px; margin: 20px 32px 0; border-bottom: 1px solid var(--border); }
.profit-view { padding: 12px 4px; border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); cursor: pointer; font: inherit; font-weight: 500; }
.profit-view:hover { color: var(--primary); }
.profit-view.active { color: var(--primary); border-bottom-color: var(--primary); font-weight: 600; }
@media (max-width: 1280px) { .profit-views { margin-left: 24px; margin-right: 24px; } }
@media (max-width: 760px) { .profit-views { margin-left: 12px; margin-right: 12px; } }
/* Personal commerce platform and country-site preferences. */
.settings-panel { max-width: 1080px; }
.settings-intro { padding: 18px 22px 6px; color: var(--muted); }
.settings-account { padding: 0 22px 18px; font-size: 13px; color: var(--muted); }
.settings-table select { width: 100%; min-width: 180px; padding: 9px 12px; border: 1px solid var(--border); border-radius: 6px; background: #fff; font: inherit; color: var(--text); }
.settings-table label { display: flex; align-items: center; gap: 6px; }
.settings-table input[type=radio] { accent-color: var(--primary); }
.settings-message { padding: 14px 22px; min-height: 48px; color: var(--ok); }
.settings-message.error { color: var(--err); }

/* Readable business tables across profit and settlement reports. */
.table-scroll table {
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 14px;
  line-height: 1.6;
}
.table-scroll th {
  padding: 16px 20px;
  background: #edf3f8;
  color: #425d75;
  font-size: 13px;
  font-weight: 600;
  border-bottom: 1px solid #d8e3ec;
  box-shadow: inset 0 1px 0 #fff;
}
.table-scroll th + th { border-left: 1px solid #e2eaf1; }
.table-scroll td {
  padding: 17px 20px;
  color: #334d63;
  font-size: 14px;
  border-bottom: 1px solid #e8eef4;
  font-variant-numeric: tabular-nums lining-nums;
}
.table-scroll tbody tr { background: #fff; transition: background .15s; }
.table-scroll tbody tr:nth-child(even) { background: #f7fafd; }
.table-scroll tbody tr:hover { background: #eaf2f8; }
.table-scroll td.num, .table-scroll td.settlement-number {
  color: #24475f;
  font-weight: 500;
  text-align: right;
}
.table-scroll .tag {
  padding: 4px 11px;
  border: 1px solid #dce7ef;
  border-radius: 6px;
  background: #eaf1f7;
  color: #496d88;
  font-size: 12px;
  font-weight: 500;
}
.table-scroll .tag.ok { background: #e8f7ee; border-color: #cdebd9; color: #15803d; }
.table-scroll .tag.warn { background: #fef6e7; border-color: #f1e2be; color: #b45309; }
.table-scroll .tag.err { background: #fdecec; border-color: #f5d4d4; color: #b91c1c; }
.table-scroll .tag.info { background: #eaf1ff; border-color: #d5e1fa; color: #1d4ed8; }
.table-scroll { scrollbar-color: #a8bdce #eef3f7; scrollbar-width: auto; }
.table-scroll::-webkit-scrollbar { height: 10px; width: 10px; }
.table-scroll::-webkit-scrollbar-track { background: #eef3f7; }
.table-scroll::-webkit-scrollbar-thumb { background: #a8bdce; border: 2px solid #eef3f7; border-radius: 8px; }
.table-scroll::-webkit-scrollbar-thumb:hover { background: #819fb5; }
.panel > .toolbar { min-height: 76px; }
.panel > .toolbar > b { font-size: 16px !important; }
.panel .ptab { padding: 8px 15px; font-size: 13px; }
.panel .toolbar input[type=search] { font-size: 14px; background: #f7f9fc; }
.panel .count, .panel .pager { font-size: 13px; color: #718499; }
.panel .pager { padding: 18px 22px; }
.settlement-table th, .settlement-table th:first-child { background: #edf3f8; }
.settlement-table tbody tr:nth-child(even) td:first-child { background: #f7fafd; }
.settlement-table tbody tr:hover td:first-child { background: #eaf2f8; }
@media (prefers-reduced-motion: reduce) { .table-scroll tbody tr { transition: none; } }

/* SeaEngine Academy: independent tutorials and guided practice. */
.academy-intro { margin: 0 0 24px; }
.academy-intro > span { color: #947544; font-size: 11px; letter-spacing: 2px; font-weight: 600; }
.academy-intro h1 { margin: 8px 0; font-size: 28px; color: #203d55; }
.academy-intro p, .academy-muted { color: #728599; font-size: 14px; line-height: 1.8; }
.academy-hero { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 28px 32px; border-radius: 12px; color: #fff; background: linear-gradient(120deg, #19354c, #2e5875); border-top: 3px solid #c6a76d; margin-bottom: 22px; }
.academy-hero h2 { font-size: 22px; margin: 0 0 12px; }
.academy-hero p { color: #c8d7e4; line-height: 1.9; margin: 0; }
.academy-hero .iconbtn { background: #e4c992; color: #263b4b; border-color: #e4c992; flex-shrink: 0; }
.academy-split { display: grid; grid-template-columns: 1.15fr 1fr; gap: 22px; margin-bottom: 24px; align-items: start; }
.academy-split > .panel, .academy-split > section > .panel { padding: 26px; }
.academy-split > section > .panel + .panel { margin-top: 20px; }
.academy h2 { font-size: 18px; margin-top: 0; }
.academy h3 { color: #304f67; font-size: 16px; }
.academy-step { padding: 18px 0; border-bottom: 1px solid #e7edf3; font-size: 14px; line-height: 1.9; color: #536b7f; }
.academy-step b { color: #245b83; }
.academy-steps { margin-bottom: 22px; }
.academy-notice { background: #f7f3eb; padding: 14px 16px; color: #7b633d; font-size: 13px; line-height: 1.8; border-radius: 8px; }
.academy-lessons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; padding: 24px; }
.academy-lesson { padding: 22px; border: 1px solid #e3eaf0; border-radius: 10px; background: #fafcfe; }
.academy-lesson p { font-size: 14px; line-height: 1.95; color: #526a7e; margin-bottom: 0; }
@media (max-width: 1100px) { .academy-split { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .academy-hero { flex-direction: column; align-items: flex-start; padding: 22px; } .academy-lessons { grid-template-columns: 1fr; padding: 16px; } }
.academy-template-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.academy-template { padding: 28px; display: flex; flex-direction: column; align-items: flex-start; }
.academy-template h2 { margin: 18px 0 8px; color: #24475f; }
.academy-template > p { color: #637b90; line-height: 1.8; }
.academy-template-fields { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.academy-template-fields span { background: #eff4f8; color: #4d6a80; padding: 5px 9px; font-size: 12px; border-radius: 5px; }
.academy-template-actions { display: flex; gap: 10px; margin-top: auto; padding-top: 16px; }
.academy-reading { padding: 28px; margin-top: 24px; }
@media (max-width: 1000px) { .academy-template-grid { grid-template-columns: 1fr; } }
.management-grid { display:grid;grid-template-columns:minmax(0,1.3fr) minmax(320px,.8fr);gap:24px;align-items:start; }
.management-form { padding:26px; }
.management-form h2 {font-size:18px;margin-top:0;}
.management-form label {display:block;font-size:13px;color:#536c82;margin-bottom:16px;}
.management-form input,.management-form select,.management-form textarea {display:block;width:100%;margin-top:7px;padding:10px 12px;border:1px solid #dbe4ed;border-radius:7px;background:#fff;color:#243f54;font:inherit;}
.management-form small {display:block;color:#8494a5;margin-top:7px;line-height:1.7;}
.management-actions {display:flex;gap:10px;}
.mini.danger {color:#b42318;border-color:#f2c2bf;}
.academy-material-list {display:grid;gap:16px;}
.material-body {white-space:pre-wrap;}
@media(max-width:1100px){.management-grid{grid-template-columns:1fr;}}
.erp-mapping {display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:16px;margin:22px 0;}

.management-upload-progress {margin-top:16px;color:#285d7c;font-size:13px;overflow-wrap:anywhere;}
.management-upload-progress progress {display:block;width:100%;height:10px;margin-top:8px;accent-color:#285d7c;}

.document-preview{width:min(1100px,94vw);height:88vh;padding:0;border:0;border-radius:12px}.document-preview::backdrop{background:#10243499}.document-preview-toolbar{display:flex;align-items:center;justify-content:space-between;padding:12px 20px;border-bottom:1px solid #e1e8ef}.document-preview-body{height:calc(100% - 65px);overflow:auto}.document-preview-body iframe{width:100%;height:100%;border:0}

.iconbtn.danger {color:#b42318;border-color:#f2c2bf;}
.iconbtn.danger:hover {background:#fff5f5;}

/* 文件夹下拉面板：拖拽移动 + 右键新建子文件夹 */
#manage-folder-panel{position:fixed;z-index:1200;width:max-content;max-width:360px;overflow:auto;background:#fff;border:1px solid #dbe4ed;border-radius:9px;box-shadow:0 10px 28px rgba(15,40,80,.14);padding:5px}
#manage-folder-panel .fp-row{display:flex;align-items:center;gap:7px;padding:7px 9px;border-radius:6px;font-size:13.5px;color:var(--text);cursor:grab;white-space:nowrap;user-select:none}
#manage-folder-panel .fp-row:hover{background:#f2f6fc}
#manage-folder-panel .fp-row.fp-special{cursor:pointer}
#manage-folder-panel .fp-row.fp-current{background:#eaf1fd}
#manage-folder-panel .fp-row.fp-over{background:#eaf1fd;outline:1.5px dashed var(--primary)}
#manage-folder-panel .fp-grip{color:#b3bcc7;flex:none;font-size:12px;cursor:grab}
#manage-folder-panel .fp-rootdrop{position:fixed;display:none;padding:8px 9px;border:1.5px dashed var(--primary);border-radius:6px;color:var(--primary);font-size:12.5px;text-align:center;background:#f0f5ff;cursor:pointer;z-index:1300;box-shadow:0 6px 18px rgba(15,40,80,.14)}
#manage-folder-panel .fp-rootdrop.fp-over{background:#dfe9ff}
#manage-folder-panel.fp-dragging .fp-rootdrop{display:block}
#manage-folder-menu{position:fixed;z-index:2000;background:#fff;border:1px solid var(--border);border-radius:8px;box-shadow:0 8px 24px rgba(15,40,80,.16);padding:4px;min-width:150px}
#manage-folder-menu button{display:block;width:100%;text-align:left;padding:8px 12px;border:0;background:none;border-radius:5px;font-size:13.5px;color:var(--text);cursor:pointer}
#manage-folder-menu button:hover{background:#f0f4fa}
/* Published course catalog — scoped to the learner's page. */
.course-library{--course-ink:#203e4a;--course-muted:#7b8f9b;--course-teal:#28685f;color:var(--course-ink);max-width:1680px;margin:0 auto;padding-bottom:28px}
.course-hero{position:relative;overflow:hidden;display:grid;grid-template-columns:minmax(0,1fr) 310px;gap:28px;border-radius:22px;padding:38px 42px 26px;background:linear-gradient(112deg,#e6f0ec 0%,#f2f5eb 60%,#e7eee5 100%);border:1px solid #dce8e0;box-shadow:0 8px 24px #1b423606;margin-bottom:28px}
.course-eyebrow{display:block;color:#487c70;font-size:11px;font-weight:700;letter-spacing:2px;margin-bottom:14px}.course-hero h1{font-size:clamp(24px,2.1vw,34px);font-weight:750;letter-spacing:1px;margin:0 0 12px;color:#1d4942}.course-hero p{font-size:14px;line-height:1.8;color:#6b887e;margin:0 0 24px}
.course-search{display:flex;align-items:center;gap:12px;max-width:600px;background:#ffffffeb;border:1px solid #d8e4dd;padding:0 16px;border-radius:12px;box-shadow:0 4px 12px #31504405}.course-search>span{font-size:27px;color:#5c8175}.course-search input{background:transparent;border:0;outline:0;width:100%;min-width:0;padding:16px 0;font-size:14px;color:#264c44;box-shadow:none}.course-search:focus-within{outline:2px solid #6b9d8c;outline-offset:2px}.course-search kbd{font-family:inherit;font-size:11px;white-space:nowrap;color:#8a9c93;border:1px solid #e1e9e3;border-radius:5px;padding:3px 6px}
.course-hero-stats{grid-column:1/-1;display:flex;gap:34px;align-items:center;padding-top:21px;margin-top:2px;border-top:1px solid #ceded266;color:#789081;font-size:12px}.course-hero-stats b{font-size:19px;color:#305c4e;margin-right:5px;font-weight:650}
.course-hero-art{position:relative;align-self:center;height:190px}.course-art-orbit{position:absolute;width:240px;height:240px;border:1px solid #bfd2c680;border-radius:50%;top:-20px;left:30px}.course-art-orbit:after{content:'';position:absolute;inset:24px;border-radius:50%;border:1px dashed #bfd2c6}.course-art-book{position:absolute;inset:5px 55px 10px 65px;padding:22px;border-radius:6px 18px 18px 6px;transform:rotate(-10deg);background:linear-gradient(135deg,#315e52,#173c33);border-left:7px solid #7a998b;box-shadow:14px 18px 20px #21433320;color:#ecf1da;display:flex;flex-direction:column;justify-content:space-between}.course-art-book span{font-size:9px;letter-spacing:3px;color:#bdcfb9}.course-art-book b{font-family:Georgia,'Songti SC',serif;font-size:26px;letter-spacing:4px}.course-art-book i{font-size:8px;font-style:normal;letter-spacing:2px;color:#c4d2ba}.course-art-chip{position:absolute;right:10px;bottom:2px;transform:rotate(5deg);padding:11px 18px;border-radius:9px;background:#ffffffcf;font-size:11px;color:#6c8573;box-shadow:0 8px 15px #274e3310}
.course-workspace{display:grid;grid-template-columns:255px minmax(0,1fr);gap:28px;align-items:start}.course-directory{background:#fff;border:1px solid #e5ebea;border-radius:16px;padding:23px 12px 18px;position:sticky;top:20px;box-shadow:0 6px 20px #182b3303}.course-directory-heading{padding:0 10px 20px;display:flex;justify-content:space-between;align-items:center}.course-directory-heading b{font-size:15px}.course-directory-heading span{font-size:10px;color:#97a6ad}.course-directory nav{max-height:65vh;overflow:auto;scrollbar-width:thin}.course-folder{border:0;background:transparent;display:flex;align-items:center;gap:9px;width:100%;padding:12px 10px 12px calc(10px + var(--depth,0)*12px);font-family:inherit;font-size:12px;text-align:left;border-radius:9px;color:#75858c;cursor:pointer;margin:3px 0;min-height:42px}.course-folder>span:nth-child(2){flex:1;line-height:1.6;overflow-wrap:anywhere}.course-folder small{font-size:10px;color:#99a8ad}.course-folder-icon{color:#91a79f;font-size:17px}.course-folder:hover{background:#f6f9f7}.course-folder.active{background:#eaf3ee;color:#2f6b52;font-weight:650}.course-folder.active small{background:#d5e7db;color:#4d7d61;padding:2px 6px;border-radius:5px}.course-folder-branch{position:relative}.course-folder-branch>summary{position:absolute;left:0;top:14px;width:10px;font-size:9px;color:#8ba69a;cursor:pointer}.course-folder-branch>.course-folder{padding-left:calc(15px + var(--depth,0)*12px)}.course-directory-note{font-size:10px;line-height:1.9;color:#a1afb4;border-top:1px solid #eff2f2;margin:18px 10px 0;padding-top:15px}
.course-main{min-width:0}.course-results-heading{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:4px 0 18px}.course-breadcrumb{display:block;font-size:11px;color:#93a3ab;margin-bottom:8px;overflow-wrap:anywhere}.course-results-heading h2{font-size:22px;margin:0;color:#263f4d}.course-result-count{font-size:12px;color:#8b9da6;white-space:nowrap}.course-filter-row{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:25px;border-bottom:1px solid #e1e8ec;padding-bottom:16px}.course-types{display:flex;flex-wrap:wrap;gap:5px}.course-types button{border:0;padding:9px 14px;background:transparent;border-radius:8px;font-family:inherit;font-size:12px;color:#7e929c;cursor:pointer}.course-types button.active{background:#264e4d;color:#fff;box-shadow:0 3px 8px #22494815}.course-order-note{font-size:10px;color:#a2afb7;white-space:nowrap}
.course-section{margin-bottom:28px}.course-section-heading{display:flex;gap:12px;align-items:center;justify-content:space-between;margin-bottom:13px}.course-section-heading h3{font-size:13px;line-height:1.6;margin:0;color:#5e7682;overflow-wrap:anywhere}.course-section-heading>span{font-size:10px;color:#99aab1;white-space:nowrap}.course-card-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(100%,250px),1fr));gap:18px}.course-card{background:#fff;border:1px solid #e2e9eb;border-radius:14px;overflow:hidden;box-shadow:0 3px 12px #29424c04;transition:box-shadow .2s,transform .2s}.course-card:hover{transform:translateY(-3px);box-shadow:0 12px 24px #29424c0c}.course-cover{height:114px;position:relative;overflow:hidden;padding:18px 20px;background:linear-gradient(120deg,#e8eff0,#d9e6e6);color:#487674}.course-cover.is-document{background:linear-gradient(120deg,#f3eee1,#eae1ce);color:#9e8860}.course-cover:after{content:'';position:absolute;right:-20px;top:-45px;width:180px;height:180px;border:1px solid #fff8;border-radius:50%;box-shadow:0 0 0 22px #ffffff20,0 0 0 44px #ffffff15}.course-cover-label{font-size:9px;letter-spacing:2px;position:relative;z-index:1}.course-cover-symbol{position:absolute;right:28px;top:24px;font-size:45px;line-height:1;color:#618e8770;z-index:1}.is-document .course-cover-symbol{color:#a08c6570}.course-cover-caption{position:absolute;left:20px;bottom:19px;font-size:11px;letter-spacing:2px}.course-card-content{padding:18px 20px 15px}.course-card-category{display:block;color:#8faaa0;font-size:10px;white-space:nowrap;text-overflow:ellipsis;overflow:hidden;margin-bottom:8px}.course-card-content h3{font-size:15px;line-height:1.65;min-height:48px;color:#2c4855;margin:0 0 12px;overflow-wrap:anywhere}.course-card-description{color:#91a0a7;font-size:11px;line-height:1.8;margin:0 0 12px;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}.course-resources{border-top:1px solid #eff3f3;padding-top:7px}.course-resource{display:flex;align-items:center;justify-content:space-between;gap:6px;padding:7px 0;min-height:35px}.course-resource>span{font-size:10px;color:#93a1a8}.course-resource>div{display:flex;gap:9px;align-items:center}.course-resource button{font-family:inherit;cursor:pointer}.course-start{font-size:11px;background:#edf4ef;border:0;border-radius:6px;padding:7px 11px;color:#3b725a}.course-start:hover{background:#dfede4}.course-start span{margin-left:5px}.course-download,.course-text{font-size:10px;border:0;background:none;color:#8498a2;padding:5px 0}.course-download:hover,.course-text:hover{color:#326653}.course-resource button:disabled{opacity:.5;cursor:wait}
.course-empty{text-align:center;border:1px dashed #dce5e5;border-radius:16px;padding:65px 24px;background:#ffffff80}.course-empty>span{font-size:45px;color:#9eb8ad}.course-empty h3{font-size:18px;margin:15px 0 10px}.course-empty p{color:#93a2aa;font-size:13px;line-height:1.8;margin-bottom:22px}.course-action-error{color:#b42318;background:#fff3f1;padding:12px 16px;border-radius:10px;font-size:13px}.course-text-dialog{width:min(850px,92vw);max-height:85vh;overflow:auto;padding:30px;border:0;border-radius:16px}.course-text-dialog .material-body{line-height:1.9;white-space:pre-wrap;overflow-wrap:anywhere}.course-library button:focus-visible{outline:2px solid #3b8063;outline-offset:2px}
@media(min-width:1600px){.course-card-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:1050px){.course-workspace{grid-template-columns:210px minmax(0,1fr);gap:20px}.course-hero{padding:30px;grid-template-columns:minmax(0,1fr) 230px}.course-art-book{inset:5px 35px 10px 30px}.course-art-orbit{left:0}.course-order-note{display:none}}
@media(max-width:760px){.course-hero{grid-template-columns:1fr;padding:25px 22px;gap:10px;border-radius:16px}.course-hero-art{display:none}.course-hero-stats{gap:20px}.course-workspace{grid-template-columns:1fr;gap:22px}.course-directory{position:static}.course-directory nav{max-height:240px}.course-directory-note{display:none}.course-results-heading h2{font-size:20px}.course-card-grid{grid-template-columns:repeat(auto-fill,minmax(min(100%,250px),1fr))}.course-types button{padding:8px 12px}.course-search kbd{display:none}.course-section-heading h3{font-size:12px}}
@media(prefers-reduced-motion:reduce){.course-card{transition:none}.course-card:hover{transform:none}}
@media(max-width:760px){.course-hero h1{font-size:22px;letter-spacing:0;text-wrap:balance}}
/* Stronger contrast and clearer typography for the course catalog. */
.course-library{--course-ink:#173b43;--course-muted:#536775;--course-teal:#1d6552;font-family:'Microsoft YaHei UI','Microsoft YaHei','PingFang SC',system-ui,sans-serif}
.course-hero{background:linear-gradient(112deg,#d4e8df 0%,#e8edda 60%,#ccdfd2 100%);border-color:#b8d0bf}
.course-eyebrow{color:#295e4e;font-size:12px}.course-hero h1{color:#123f33;font-weight:800}.course-hero p{color:#3d6555;font-size:15px}.course-search input{color:#244b40;font-size:15px}.course-search input::placeholder{color:#586e64;opacity:1}.course-search kbd{color:#4d6659}.course-hero-stats{color:#476351;font-size:13px;border-top-color:#a8c2af}.course-hero-stats b{color:#204f3d;font-weight:750}.course-art-chip{color:#395b46;background:#fffffff0}
.course-directory,.course-card{border-color:#cfded7;box-shadow:0 5px 18px #203f3a09}.course-directory-heading b{font-size:17px;color:#183e36}.course-directory-heading span{font-size:12px;color:#587063}.course-folder{color:#465f58;font-size:14px;font-weight:500}.course-folder-icon{color:#527968}.course-folder small{color:#586e65;font-size:12px}.course-folder.active{color:#164f39;background:#d9ecdf;font-weight:700}.course-folder.active small{color:#204e36;background:#bddac6}.course-folder:hover{background:#edf4ee}.course-folder-branch>summary{color:#406955}.course-directory-note{color:#607467;font-size:12px;border-color:#dce7df}
.course-breadcrumb,.course-result-count{color:#586e79;font-size:13px}.course-results-heading h2{color:#183e48;font-weight:750}.course-types button{color:#485f68;font-size:14px;font-weight:550}.course-types button.active{background:#1c5b49;color:#fff;font-weight:650}.course-order-note{color:#5a707b;font-size:12px}.course-filter-row{border-color:#cfdce0}.course-section-heading h3{color:#304e59;font-size:15px;font-weight:700}.course-section-heading>span{color:#5b727b;font-size:12px}
.course-cover{background:linear-gradient(120deg,#bed9d1,#98c5b7);color:#235b4b}.course-cover.is-document{background:linear-gradient(120deg,#e6d6b3,#d4bc8b);color:#664a1d}.course-cover-label{font-size:11px;font-weight:650}.course-cover-caption{font-size:12px;font-weight:600}.course-cover-symbol{color:#397462b3}.is-document .course-cover-symbol{color:#806331b3}.course-card-category{color:#496b5b;font-size:12px}.course-card-content h3{color:#173c48;font-size:17px;font-weight:750;line-height:1.65}.course-card-description{color:#526974;font-size:13px}.course-resources{border-color:#dce6e2}.course-resource>span{color:#536b77;font-size:12px}.course-start{background:#246750;color:#fff;font-size:13px;font-weight:600;padding:8px 13px}.course-start:hover{background:#174e3a}.course-download,.course-text{color:#365a69;font-size:12px;font-weight:550}.course-download:hover,.course-text:hover{color:#154c36}.course-empty p{color:#526b75;font-size:14px}
@media(max-width:760px){.course-section-heading h3{font-size:14px}.course-card-content h3{font-size:17px}.course-folder{font-size:13px}.course-types button{font-size:13px}}
.course-player{width:min(1000px,92vw);max-height:90vh;overflow:auto;padding:20px;border:0;border-radius:16px;background:#fff;color:#203e4a;box-shadow:0 20px 80px #132b3c40}.course-player::backdrop{background:#102434b3}.course-player-heading{display:flex;justify-content:space-between;align-items:center;gap:12px}.course-player-status{font-size:14px;line-height:1.7;color:#43615c;margin:14px 0}.course-player-status.error{color:#b42318}.course-player video{display:block;width:100%;max-height:65vh;background:#101e22;border-radius:8px}.course-player video[hidden]{display:none}.course-player-retry{margin-top:14px}
.course-player video{aspect-ratio:16/9;object-fit:contain;min-height:220px;height:auto}
