:root {
  --teal: #069a91;
  --teal-dark: #087f78;
  --teal-line: #5bb5b0;
  --pale: #ffffe6;
  --gray-bg: #f2f5f7;
  --gray-cell: #eef2f5;
  --red: #bf262b;
  --red-dark: #9e171c;
  --blue: #113dff;
  --text: #333;
  --border: #70b9b5;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-width: 1180px; background: #fff; color: var(--text); font-family: "Microsoft YaHei", Arial, sans-serif; font-size: 14px; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
.app { min-height: 100vh; }

/* 登录 */
.login-view { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: #eef2f2; }
.login-window { width: 720px; border: 1px solid #d3e8e6; background: #fff; box-shadow: 0 15px 45px rgba(0,0,0,.28); }
.login-banner { height: 96px; display: flex; align-items: center; gap: 22px; padding: 0 34px; background: var(--teal); color: #fff; }
.login-logo { color: #fff700; font-size: 38px; font-weight: 700; letter-spacing: 2px; }
.login-banner h1 { margin: 0 0 6px; font-size: 27px; }
.login-banner p { margin: 0; color: #e2fffc; }
.login-body { display: grid; grid-template-columns: 1fr 320px; gap: 26px; padding: 30px; }
.login-notice { border: 1px solid #badfdd; background: #f6ffff; padding: 18px; line-height: 1.8; }
.login-notice b { display: block; color: var(--teal-dark); font-size: 17px; }
.login-notice span { display: block; color: #0b4d49; font-weight: 700; margin: 9px 0; }
.login-notice p { margin: 0; color: #626262; }
.login-footer { padding: 10px 18px; border-top: 1px solid #ddd; background: #f5f5f5; color: #777; text-align: center; font-size: 12px; }
.login-actions { text-align: center; margin-top: 12px; }

/* 头部 */
.legacy-header { position: relative; height: 81px; background: var(--teal); color: #fff; border-bottom: 1px solid #0b7771; padding-left: 132px; }
.identity-box { position: absolute; left: 0; top: 0; width: 128px; height: 80px; text-align: center; padding-top: 5px; line-height: 1.3; }
.identity-box b, .identity-box strong, .identity-box a { display: block; }
.identity-box b { font-size: 16px; }
.identity-box strong { font-size: 15px; margin-top: 2px; }
.identity-box a { color: #ffff00; text-decoration: none; font-weight: 700; margin-top: 2px; }
.brand-box { position: absolute; left: 135px; top: 0; color: #ffff00; font-size: 25px; line-height: 31px; }
.header-message { position: absolute; left: 245px; top: 4px; right: 500px; height: 25px; overflow: hidden; white-space: nowrap; font-weight: 700; }
.header-message span { display: inline-block; min-width: 100%; animation: marquee 28s linear infinite; }
@keyframes marquee { from { transform: translateX(30%); } to { transform: translateX(-100%); } }
.countdown-box { position: absolute; top: 3px; right: 10px; display: flex; gap: 14px; color: #ffff00; font-size: 12px; white-space: nowrap; }
.legacy-nav { position: absolute; left: 128px; right: 0; bottom: 0; height: 41px; display: flex; align-items: end; gap: 3px; padding-left: 8px; }
.legacy-nav button { height: 35px; min-width: 88px; padding: 0 15px; border: 1px solid #edf8f7; border-bottom: none; background: #f6f6f6; color: #3e3e3e; font-size: 16px; font-weight: 700; border-radius: 4px 4px 0 0; }
.legacy-nav button:hover, .legacy-nav button.active { background: #fffad0; color: #333; }

.breadcrumb-bar { min-height: 38px; margin: 12px 8px 8px; border: 1px solid #87c2bd; background: var(--pale); display: flex; align-items: center; justify-content: space-between; padding: 0 28px; font-size: 16px; }
.breadcrumb-bar b { color: red; font-weight: 500; }
.context-links { font-weight: 700; }
.context-links button { border: none; background: transparent; padding: 0 3px; font-weight: 700; color: #444; }
.context-links button.active { color: red; }
.context-links button:disabled { color: #aaa; cursor: not-allowed; }
.context-links .sep { margin: 0 2px; color: #777; }

.workspace { padding: 0 8px 30px; }
.panel { display: none; }
.panel.active { display: block; }
.section-title { min-height: 38px; background: var(--teal); color: #fff; font-weight: 700; font-size: 17px; padding: 7px 8px; border: 1px solid var(--teal-dark); }
.title-row { display: flex; justify-content: space-between; align-items: center; }
.title-row > span:last-child { color: #fff; font-size: 13px; font-weight: 400; }

/* 表单 */
.search-strip { min-height: 48px; border: 1px solid var(--border); border-top: none; background: #fff; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 8px 14px; }
.search-strip label { white-space: nowrap; display: inline-flex; align-items: center; gap: 5px; }
.search-strip input, .search-strip select, .legacy-form input, .legacy-form select, .profile-table input { height: 30px; border: 1px solid #b9c3cb; background: #fff; padding: 2px 7px; min-width: 128px; }
.search-strip input[type="date"] { width: 150px; }
.search-strip input[type="datetime-local"] { width: 235px; }
.search-strip input[type="radio"], .search-strip input[type="checkbox"] { min-width: auto; width: 18px; height: 18px; accent-color: #1976e9; }
.short-input { width: 108px !important; min-width: 108px !important; }
.radio-group { display: inline-flex; gap: 10px; align-items: center; }
.radio-group label { font-weight: 700; }
.compact-search { min-height: 42px; }
.dense-filter { gap: 8px 12px; }
.red-button, .gray-button, .link-button { border-radius: 4px; min-height: 31px; padding: 4px 17px; font-weight: 700; }
.red-button { border: 1px solid var(--red-dark); color: #fff; background: #a9363a; }
.red-button:hover { background: #922d31; }
.red-button:disabled { opacity: .55; cursor: not-allowed; }
.gray-button { border: 1px solid #aeb6bc; color: #333; background: #f2f4f5; }
.link-button { border: none; color: #113dff; background: transparent; padding-left: 4px; padding-right: 4px; }
.link-button.strong { font-size: 16px; color: red; }
.small { min-height: 29px; padding: 3px 14px; }

/* 表格 */
.table-scroll { overflow: auto; border-left: 1px solid var(--border); border-right: 1px solid var(--border); }
.wide-table table { min-width: 1740px; }
.legacy-table { width: 100%; border-collapse: collapse; table-layout: auto; }
.legacy-table th, .legacy-table td { border-right: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 8px 8px; text-align: center; vertical-align: middle; white-space: nowrap; }
.legacy-table th:last-child, .legacy-table td:last-child { border-right: none; }
.legacy-table thead th { background: var(--teal); color: #fff; font-size: 16px; font-weight: 700; }
.legacy-table tbody td { background: #fff; }
.legacy-table tbody tr:nth-child(odd) td { background: var(--gray-cell); }
.legacy-table tfoot td { background: #b7dfdf; font-weight: 700; }
.legacy-table.compact th, .legacy-table.compact td { padding: 7px 7px; }
.legacy-table .left { text-align: left; white-space: normal; }
.legacy-table .red { color: red; }
.legacy-table .blue { color: #153bff; }
.legacy-table .green { color: green; }
.legacy-table .muted { color: #999; }
.legacy-table .positive { color: #d90000; font-weight: 700; }
.legacy-table .negative { color: #007b1d; font-weight: 700; }
.legacy-table .empty-row { text-align: left; color: #666; background: #fff !important; }
.legacy-table .actions { display: flex; gap: 8px; justify-content: center; }
.legacy-table .actions button { border: none; background: transparent; color: #1544ff; padding: 0; }
.account-table td:nth-child(2) { min-width: 180px; line-height: 1.7; }
.account-table td:nth-child(10) { min-width: 220px; }
.report-table-wrap { border-top: 1px solid var(--border); }
.report-table thead th { color: #222; background: #eee; }
.report-table thead .group-yellow { background: #ffd268; }
.report-table thead .group-pink { background: #f8cae1; }
.report-table thead .group-orange { background: #ffdda9; }
.draw-table th, .draw-table td { height: 50px; }
.ball { display: inline-flex; width: 38px; height: 38px; align-items: center; justify-content: center; border-radius: 50%; color: #fff; font-size: 20px; font-weight: 700; background: #365d8d; box-shadow: inset 0 1px 3px rgba(255,255,255,.8); }
.ball.red-ball { background: #a94145; }

.info-box, .warning-box, .settings-note { margin: 12px 0; padding: 10px 14px; border: 1px solid #95c8c4; background: #f4ffff; line-height: 1.8; }
.warning-box { border-color: #e4b56a; background: #fff9df; }
.summary-strip { margin-top: 10px; padding: 10px 14px; border-top: 1px solid #a3d000; color: #555; }
.account-info-line { min-height: 42px; display: flex; gap: 24px; align-items: center; padding: 7px 34px; border-bottom: 1px solid var(--border); color: #555; }
.account-info-line span:first-child { color: #0b36ff; }
.orange-text { color: #ff7900; }
.red-text { color: red; }
.green-text { color: green; }

/* 规则 */
.rules-page { border: 1px solid var(--border); padding: 22px 36px 40px; background: #fff; line-height: 1.9; }
.rules-page h2 { text-align: center; color: #176b66; margin: 4px 0 24px; }
.rule-block { border-bottom: 1px dashed #b7cfcd; padding: 8px 0 14px; }
.rule-block h3 { color: var(--teal-dark); margin: 0 0 5px; }
.rule-block p { margin: 0; }

/* 设置 */
.settings-tabs { min-height: 42px; display: flex; justify-content: flex-end; align-items: center; gap: 0; border: 1px solid #a4c9c6; background: var(--pale); padding-right: 16px; margin-bottom: 50px; }
.settings-tabs button { border: none; background: transparent; padding: 0 7px; font-weight: 700; color: #444; border-right: 1px solid #888; }
.settings-tabs button:last-child { border-right: none; }
.settings-tabs button.active { color: red; }
.settings-section { display: none; }
.settings-section.active { display: block; }
.profile-table { width: 100%; border-collapse: collapse; }
.profile-table th, .profile-table td { border: 1px solid var(--border); padding: 8px 12px; background: #eef2f4; }
.profile-table th { width: 15%; text-align: right; font-weight: 400; }
.profile-table td { width: 35%; }
.profile-table input { width: 240px; background: #f8f8f8; }
.password-form { width: 520px; margin: 32px auto; border: 1px solid var(--border); padding: 28px; background: #f9ffff; }
.password-form > label { margin-bottom: 14px; }
.password-form > div:last-child { text-align: center; margin-top: 18px; }
.empty-settings { margin: 40px auto; width: 650px; text-align: center; border: 1px solid #b4d5d2; background: #f7ffff; padding: 35px; line-height: 1.8; }

/* 通用表单 */
.legacy-form { display: flex; flex-direction: column; gap: 13px; }
.legacy-form label { display: flex; align-items: center; }
.legacy-form label > span:first-child { width: 116px; text-align: right; padding-right: 8px; }
.legacy-form input { flex: 1; }
.input-with-button { display: flex; gap: 7px; flex: 1; }
.input-with-button input { min-width: 0; }
.message { min-height: 22px; color: #c11; text-align: center; }
.message.success { color: green; }

/* 弹层 */
.overlay { position: fixed; inset: 0; z-index: 1000; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,.55); }
.dialog { width: 780px; max-height: 90vh; background: #fff; border: 3px solid var(--teal); box-shadow: 0 15px 50px rgba(0,0,0,.35); }
.small-dialog { width: 520px; }
.dialog-title { min-height: 44px; padding: 9px 15px; background: var(--teal); color: #fff; font-size: 19px; font-weight: 700; }
.dialog-title.warning { background: #b12429; }
.dialog-tip { margin: 15px; padding: 10px 12px; background: #fff7d9; border: 1px solid #e5ca74; line-height: 1.7; }
.dialog-actions { display: flex; justify-content: center; gap: 16px; padding: 15px; }
.rules-scroll { margin: 18px; padding: 5px 15px; height: 430px; overflow: auto; border: 1px solid #b7d8d5; line-height: 1.8; }
.rules-scroll h3 { color: var(--teal-dark); margin-bottom: 4px; }
.rules-scroll p { margin-top: 0; }
.agree-line { display: block; margin: 0 22px; padding: 10px; background: #fffbe4; border: 1px solid #e7d887; }
.credential-form, .modal-form { padding: 18px 28px 4px; }
.created-result { margin: 8px 0; padding: 12px; border: 1px solid #8abf8a; background: #f1fff1; text-align: center; }
.created-result p { margin: 6px 0; }

/* 状态 */
.status-tag { display: inline-block; min-width: 48px; padding: 2px 7px; border-radius: 3px; color: #fff; font-size: 12px; }
.status-active { background: #299250; }
.status-disabled { background: #a8242a; }
.status-pending { background: #d28911; }
.status-neutral { background: #777; }
.toast { position: fixed; right: 20px; bottom: 20px; z-index: 2000; min-width: 260px; max-width: 520px; padding: 13px 18px; background: #126b65; color: #fff; border-radius: 4px; box-shadow: 0 5px 20px rgba(0,0,0,.3); }
.toast.error { background: #a32025; }
code { font-family: Consolas, monospace; }

/* 下级管理内部页面切换 */
.account-subview { min-height: 420px; }
.account-inline-page { background: #fff; }
.account-page-card { width: 100%; min-height: 420px; background: #fff; border: 1px solid var(--teal); box-shadow: none; }
.account-inline-page .wide-dialog, .account-inline-page .huge-dialog { width: 100%; max-height: none; height: auto; }
.account-inline-page .subordinate-edit-dialog { max-height: none; }
.account-inline-page .dialog-scroll { overflow: visible; }
.account-inline-page .edit-settings-scroll { max-height: 520px; }
.account-inline-page .subordinate-view-dialog { min-height: 680px; display: flex; flex-direction: column; }
.account-inline-page .view-content { min-height: 470px; max-height: calc(100vh - 300px); }
.account-page-title { display: flex; align-items: center; justify-content: flex-start; gap: 14px; }
.account-page-title > span { flex: 1; }
.account-back-button { min-height: 29px; padding: 3px 12px; border: 1px solid rgba(255,255,255,.78); border-radius: 3px; background: rgba(255,255,255,.13); color: #fff; font-weight: 700; cursor: pointer; }
.account-back-button:hover { background: rgba(255,255,255,.25); }
.account-path-line { padding: 10px 14px; border: 1px solid #aed1ce; border-top: none; background: #f4ffff; line-height: 1.6; }
.account-children-summary { padding: 10px 14px; border-left: 1px solid #d0dfdd; border-right: 1px solid #d0dfdd; background: #fff; color: #555; }
.account-table .account-drill-button { white-space: nowrap; }

/* 下级管理增强 */
.wide-dialog { width: min(1320px, calc(100vw - 36px)); }
.huge-dialog { width: min(1540px, calc(100vw - 24px)); height: min(920px, calc(100vh - 24px)); display: flex; flex-direction: column; }
.dialog-scroll { overflow: auto; padding: 14px 16px 0; }
.subordinate-edit-dialog { max-height: 94vh; display: flex; flex-direction: column; }
.subordinate-edit-dialog .dialog-scroll { flex: 1; }
.edit-basic-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 22px; padding: 16px; border: 1px solid var(--border); border-top: none; background: #f8fbfb; }
.edit-basic-grid label { display: flex; align-items: center; gap: 8px; }
.edit-basic-grid label > span:first-child { width: 92px; text-align: right; white-space: nowrap; }
.edit-basic-grid input, .edit-basic-grid select { height: 32px; min-width: 0; flex: 1; border: 1px solid #b9c3cb; padding: 3px 7px; background: #fff; }
.development-block { margin: 14px 0; padding: 13px 16px; border: 1px solid #c7c7c7; background: #efefef; color: #777; }
.development-block > div:first-child { display: flex; align-items: center; gap: 10px; font-size: 16px; }
.development-badge { display: inline-block; padding: 2px 9px; border-radius: 10px; background: #aaa; color: #fff; font-size: 12px; }
.development-fields { display: flex; flex-wrap: wrap; gap: 12px 24px; margin: 12px 0 8px; }
.development-fields label { display: inline-flex; align-items: center; gap: 6px; }
.development-fields input, .development-fields select { height: 30px; width: 150px; color: #8a8a8a; border: 1px solid #c8c8c8; background: #dedede; }
.development-block p { margin: 6px 0 0; }
.settings-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 22px; padding: 10px 14px; border: 1px solid var(--border); border-top: none; background: #fbffff; }
.settings-toolbar label { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; }
.settings-toolbar input[type="checkbox"] { width: 17px; height: 17px; accent-color: #177c73; }
.settings-toolbar span { margin-left: auto; color: #8a4d00; }
.edit-settings-scroll { max-height: 430px; border-top: none; }
.edit-settings-table { min-width: 1120px; }
.edit-settings-table th { position: sticky; top: 0; z-index: 2; }
.edit-settings-table input, .edit-settings-table select { height: 28px; min-width: 96px; max-width: 145px; border: 1px solid #aebcc3; padding: 2px 6px; text-align: right; background: #fff; }
.edit-settings-table select { min-width: 78px; text-align: center; }
.edit-settings-table .readonly-value { color: #555; font-weight: 700; }
.edit-settings-table .limit-hint { display: block; margin-top: 3px; color: #d13a31; font-size: 11px; font-weight: 400; }
.edit-settings-table .input-invalid { border-color: #d2232a; background: #fff0f0; }
.settings-help { margin: 10px 0 0; padding: 9px 12px; border: 1px solid #e3cf85; background: #fffbe4; color: #665614; line-height: 1.7; }

.parent-info-card { margin: 18px 24px 4px; border: 1px solid #b9d4d1; background: #fbffff; padding: 18px 24px; line-height: 2; }
.parent-info-card dl { display: grid; grid-template-columns: 105px 1fr; margin: 0; }
.parent-info-card dt { text-align: right; padding-right: 12px; color: #666; }
.parent-info-card dd { margin: 0; font-weight: 700; }

.subordinate-view-dialog .dialog-title { flex: 0 0 auto; }
.dialog-close-x { border: none; background: transparent; color: #fff; font-size: 27px; line-height: 1; padding: 0 5px; cursor: pointer; }
.view-tabs { flex: 0 0 auto; display: flex; gap: 8px; padding: 10px 14px; border-bottom: 1px solid #87c2bd; background: #effbf9; }
.view-tabs button { min-width: 112px; height: 34px; border: 1px solid #aab8b7; border-radius: 3px; background: #f3f5f5; font-weight: 700; color: #333; }
.view-tabs button.active { border-color: #087b72; background: var(--teal); color: #fff; }
.view-tabs button.disabled-feature { color: #9b9b9b; background: #e2e2e2; border-color: #c6c6c6; }
.view-toolbar { flex: 0 0 auto; min-height: 48px; display: flex; align-items: center; flex-wrap: wrap; gap: 9px 14px; padding: 8px 14px; border-bottom: 1px solid #b7d4d1; background: #fff; }
.view-toolbar label { display: inline-flex; align-items: center; gap: 5px; white-space: nowrap; }
.view-toolbar input, .view-toolbar select { height: 30px; border: 1px solid #b8c4c9; padding: 2px 6px; }
.view-toolbar .mode-buttons { display: inline-flex; gap: 6px; }
.view-toolbar .mode-buttons button { min-height: 30px; border: 1px solid #aeb7bc; background: #f6f6f6; padding: 3px 12px; font-weight: 700; }
.view-toolbar .mode-buttons button.active { border-color: #087b72; background: #e1fffa; color: #006b62; }
.view-content { flex: 1 1 auto; min-height: 0; overflow: auto; padding: 12px 14px; background: #fff; }
.view-loading, .feature-development { margin: 40px auto; max-width: 720px; padding: 30px; border: 1px solid #c7c7c7; background: #f1f1f1; color: #777; text-align: center; line-height: 1.9; }
.feature-development b { display: block; margin-bottom: 8px; font-size: 20px; color: #777; }
.view-order-table { min-width: 1480px; }
.view-report-table { min-width: 1060px; }
.view-summary { margin: 0 0 10px; padding: 9px 13px; border: 1px solid #a9cfcb; background: #f3ffff; line-height: 1.6; }
.board-summary { display: flex; gap: 22px; align-items: center; margin-bottom: 10px; padding: 10px 14px; border: 1px solid #a9cfcb; background: #f4ffff; }
.board-summary .development-text { color: #999; }
.goods-board-grid { display: grid; grid-template-columns: repeat(8, minmax(118px, 1fr)); gap: 6px; padding-bottom: 12px; }
.goods-board-cell { min-height: 82px; border: 1px solid #b9d1cf; background: #fff; }
.goods-board-cell:nth-child(odd) { background: #f8fbfb; }
.goods-board-number { display: flex; align-items: center; gap: 6px; padding: 5px 7px; border-bottom: 1px solid #d2e1df; color: #007a70; font-size: 16px; font-weight: 700; }
.goods-board-number::before { content: ''; width: 18px; height: 18px; border: 1px solid #9dc5c1; border-radius: 50%; background: #effaf8; }
.goods-board-lines { padding: 5px 8px; font-size: 12px; line-height: 1.55; color: #666; }
.goods-board-lines div { display: flex; justify-content: space-between; gap: 8px; }
.goods-board-lines .pending { color: #aaa; }
.goods-board-lines .amount { color: #bd1f23; font-weight: 700; }

@media (max-width: 1100px) {
  .edit-basic-grid { grid-template-columns: 1fr; }
  .goods-board-grid { grid-template-columns: repeat(5, minmax(118px, 1fr)); }
}

.parent-info-card .direct-parent-mark { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 9px; background: #e3f7f4; color: #087b72; font-size: 11px; font-weight: 700; }


/* 管理端视觉优化：克制、扁平、紧凑 */
:root {
  --teal: #2f6f6b;
  --teal-dark: #245a57;
  --teal-line: #8fb5b2;
  --pale: #f7f8f5;
  --gray-bg: #f4f6f7;
  --gray-cell: #fafbfb;
  --red: #a9363a;
  --red-dark: #8e2d31;
  --blue: #2d5f89;
  --text: #2d3436;
  --border: #d7dfdf;
}
html, body { background: #f4f6f7; font-size: 13px; line-height: 1.45; }
button, input, select, textarea { font-size: 13px; }

.login-view { background: #eef2f2; }
.login-window { width: 680px; border: 0; border-top: 4px solid var(--teal); box-shadow: 0 12px 34px rgba(30,55,54,.16); }
.login-banner { height: 82px; padding: 0 28px; gap: 18px; background: #2f6f6b; }
.login-logo { color: #fff; font-size: 30px; }
.login-banner h1 { font-size: 23px; }
.login-banner p { color: #dbe9e8; }
.login-body { grid-template-columns: 1fr 300px; gap: 22px; padding: 24px 26px; }
.login-notice { border: 0; border-left: 3px solid #87aaa7; background: #f6f8f8; padding: 15px 17px; }
.login-notice b { font-size: 15px; }

.legacy-header { height: 72px; padding-left: 120px; background: #2f6f6b; border-bottom: 0; box-shadow: 0 2px 7px rgba(25,55,53,.16); }
.identity-box { width: 116px; height: 71px; padding-top: 5px; border-right: 1px solid rgba(255,255,255,.16); }
.identity-box b { font-size: 14px; }
.identity-box strong { font-size: 13px; }
.identity-box a { color: #e4efee; font-weight: 500; }
.brand-box { left: 126px; color: #fff; font-size: 20px; line-height: 28px; }
.header-message { left: 205px; top: 5px; right: 470px; height: 22px; color: #e7f0ef; font-weight: 500; }
.countdown-box { top: 5px; color: #eef5f4; font-size: 11px; }
.legacy-nav { left: 116px; height: 38px; gap: 1px; padding-left: 8px; }
.legacy-nav button { height: 31px; min-width: 69px; padding: 0 10px; border: 0; border-bottom: 3px solid transparent; border-radius: 0; background: transparent; color: #e8f0ef; font-size: 13px; font-weight: 600; }
.legacy-nav button:hover { background: rgba(255,255,255,.08); color: #fff; }
.legacy-nav button.active { background: #fff; color: #2c5552; border-bottom-color: #fff; }

.breadcrumb-bar { min-height: 34px; margin: 10px 12px 8px; border: 0; border-bottom: 1px solid #d7dfdf; background: transparent; padding: 0 8px; font-size: 13px; }
.breadcrumb-bar b { color: #8b3034; font-weight: 600; }
.context-links { font-weight: 500; }
.context-links button { color: #4d5c5b; font-weight: 500; }
.context-links button.active { color: #8b3034; }
.workspace { padding: 0 12px 24px; }

.section-title { min-height: 34px; padding: 7px 10px 6px; border: 0; border-bottom: 2px solid #6b9693; background: #fff; color: #2d4f4c; font-size: 14px; font-weight: 650; }
.title-row > span:last-child { color: #70807f; font-size: 12px; }
.search-strip { min-height: 42px; border: 0; border-bottom: 1px solid #dce3e3; background: #fff; gap: 7px 12px; padding: 7px 10px; box-shadow: 0 1px 2px rgba(40,65,63,.04); }
.search-strip input, .search-strip select, .legacy-form input, .legacy-form select, .profile-table input { height: 27px; min-width: 116px; padding: 2px 6px; border: 1px solid #c9d2d2; border-radius: 2px; }
.search-strip input[type="date"] { width: 138px; }
.search-strip input[type="datetime-local"] { width: 205px; }
.search-strip input[type="radio"], .search-strip input[type="checkbox"] { width: 15px; height: 15px; }
.radio-group { gap: 8px; }
.radio-group label { font-weight: 550; }
.red-button, .gray-button, .link-button { min-height: 27px; padding: 3px 12px; border-radius: 2px; font-weight: 600; }
.red-button { border: 1px solid #8e2d31; background: #a9363a; }
.red-button:hover { background: #8e2d31; }
.gray-button { border: 1px solid #c3cccc; background: #f3f5f5; }
.link-button { color: #315f87; }
.link-button.strong { font-size: 13px; color: #8b3034; }
.small { min-height: 26px; padding: 2px 10px; }

.table-scroll { border: 0; background: #fff; }
.legacy-table th, .legacy-table td { border-right: 0; border-bottom: 1px solid #e2e7e7; padding: 6px 7px; }
.legacy-table thead th { background: #496f6c; color: #fff; font-size: 13px; font-weight: 600; }
.legacy-table tbody tr:nth-child(odd) td { background: #fafbfb; }
.legacy-table tbody tr:hover td { background: #f2f6f5; }
.legacy-table tfoot td { background: #e7efee; }
.legacy-table.compact th, .legacy-table.compact td { padding: 5px 6px; }
.legacy-table .actions { gap: 7px; }
.legacy-table .actions button { color: #315f87; }
.report-table thead th { background: #e9eeee; }
.report-table thead .group-yellow, .report-table thead .group-pink, .report-table thead .group-orange { background: #e5ebeb; }
.ball { width: 32px; height: 32px; font-size: 16px; box-shadow: none; }
.info-box, .warning-box, .settings-note { border: 0; border-left: 3px solid #95aaa8; background: #f8f9f9; padding: 8px 11px; line-height: 1.65; }
.warning-box { border-left-color: #b99c64; background: #fbf8ef; }
.account-info-line { min-height: 38px; gap: 20px; padding: 6px 18px; border-bottom-color: #dce3e3; background: #fff; }

.dialog { border: 0; border-top: 4px solid var(--teal); box-shadow: 0 16px 42px rgba(28,52,50,.22); }
.dialog-title { min-height: 38px; padding: 8px 13px; background: #2f6f6b; font-size: 15px; }
.dialog-title.warning { background: #8e3438; }
.dialog-actions { gap: 12px; padding: 11px; }
.rules-scroll { height: 390px; border: 0; border-left: 2px solid #c5d5d3; background: #fafbfb; }
.account-page-card { border: 0; border-top: 3px solid #6b9693; }
.account-back-button { min-height: 25px; padding: 2px 9px; border: 0; border-radius: 2px; background: rgba(255,255,255,.12); }
.account-path-line { border: 0; border-bottom: 1px solid #dce3e3; background: #f7f9f9; padding: 8px 12px; }
.account-children-summary { border: 0; border-bottom: 1px solid #e2e7e7; padding: 8px 12px; }
.edit-basic-grid { gap: 8px 18px; padding: 12px; border: 0; border-bottom: 1px solid #dce3e3; background: #f8f9f9; }
.edit-basic-grid input, .edit-basic-grid select { height: 28px; }
.development-block { border: 0; border-left: 3px solid #bbb; padding: 10px 13px; }
.settings-toolbar { border: 0; border-bottom: 1px solid #dce3e3; padding: 8px 11px; }
.settings-help { border: 0; border-left: 3px solid #b7a773; padding: 8px 10px; }
.view-tabs { gap: 2px; padding: 7px 10px; border-bottom-color: #d7dfdf; background: #f6f8f8; }
.view-tabs button { min-width: 94px; height: 29px; border: 0; border-bottom: 2px solid transparent; border-radius: 0; background: transparent; font-weight: 600; }
.view-tabs button.active { border: 0; border-bottom: 2px solid #2f6f6b; background: transparent; color: #245a57; }
.view-toolbar { min-height: 40px; gap: 7px 11px; padding: 6px 10px; }
.view-toolbar input, .view-toolbar select { height: 27px; }
.view-content { padding: 10px; }
.view-summary, .board-summary { border: 0; border-left: 3px solid #8ba8a5; background: #f7f9f9; padding: 8px 11px; }
.goods-board-grid { gap: 7px; }
.goods-board-cell { border: 0; border-top: 2px solid #9db9b6; box-shadow: 0 1px 3px rgba(42,70,68,.10); }
.goods-board-number { border-bottom-color: #e3e8e8; }

/* 总货盘 */
.total-board-filter { position: sticky; top: 0; z-index: 4; }
.total-board-inline-pagination { min-height: 0; margin-left: auto; padding: 0; border: 0; background: transparent; }
.total-board-inline-pagination button { min-width: 58px; }
.total-board-summary { display: flex; flex-wrap: wrap; gap: 8px 22px; align-items: center; min-height: 42px; padding: 8px 10px; background: #fff; border-bottom: 1px solid #dce3e3; color: #566260; }
.total-board-summary span { white-space: nowrap; }
.total-board-summary b { margin-left: 3px; color: #263f3d; }
.total-board-help { padding: 7px 10px; border-bottom: 1px solid #e4e9e9; background: #f8f9f9; color: #77817f; font-size: 12px; }
.total-board-grid { display: grid; grid-template-columns: repeat(10, minmax(108px, 1fr)); gap: 6px; padding: 8px 0 22px; }
.total-board-card { min-height: 78px; overflow: hidden; background: #fff; border: 1px solid #e0e7e6; border-top: 2px solid #8aa9a6; border-radius: 3px; box-shadow: 0 1px 2px rgba(38,62,60,.06); content-visibility: auto; contain-intrinsic-size: 78px; transition: border-color .15s ease, box-shadow .15s ease; }
.total-board-card:hover { border-color: #c6d5d3; box-shadow: 0 2px 7px rgba(38,62,60,.10); }
.total-board-card.is-editing { border-color: #7da49f; box-shadow: 0 2px 8px rgba(38,62,60,.13); }
.total-board-card header { display: flex; align-items: center; justify-content: center; min-height: 37px; padding: 1px 4px; border-bottom: 1px solid #e8edec; background: #fbfcfc; }
.total-board-number { appearance: none; display: inline-flex; align-items: center; justify-content: center; min-width: 0; margin: 0; padding: 5px 9px; border: 0; border-radius: 4px; background: transparent; color: #176c65; font-family: Consolas, "Microsoft YaHei", sans-serif; font-size: 22px; font-weight: 800; line-height: 1; letter-spacing: 1px; font-variant-numeric: tabular-nums; }
button.total-board-number { cursor: pointer; }
button.total-board-number:hover,
button.total-board-number:focus-visible { background: #edf5f4; color: #0f5d57; outline: none; }
.total-board-number.is-static { cursor: default; }
.total-board-values { padding: 3px 7px 5px; }
.total-board-stat { min-width: 0; display: grid; grid-template-columns: 30px minmax(0, 1fr); align-items: center; gap: 5px; min-height: 21px; padding: 0; }
.total-board-values span { color: #81908e; font-size: 10px; line-height: 1; }
.total-board-values b { min-width: 0; overflow: hidden; color: #253f3d; font-size: 12px; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; text-overflow: ellipsis; white-space: nowrap; }
.total-board-block-stat { position: relative; }
.total-board-block-input { width: 100%; min-width: 0; height: 21px; box-sizing: border-box; padding: 0 5px; border: 1px solid #7fa39f; border-radius: 3px; background: #fff; color: #203d3a; font-size: 12px; font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.total-board-block-input:focus { outline: 2px solid rgba(77,136,130,.16); border-color: #4d8882; }
.total-board-block-input.is-saving { opacity: .55; }
.total-board-empty { grid-column: 1 / -1; padding: 44px 20px; background: #fff; color: #77817f; text-align: center; }
.total-board-summary .positive,
.total-board-card .positive { color: #8e3438; font-weight: 650; }
.total-board-summary .negative,
.total-board-card .negative { color: #28705d; font-weight: 650; }

@media (max-width: 1350px) {
  .total-board-grid { grid-template-columns: repeat(8, minmax(104px, 1fr)); }
  .goods-board-grid { grid-template-columns: repeat(6, minmax(126px, 1fr)); }
}

@media (max-width: 980px) {
  .total-board-grid { grid-template-columns: repeat(5, minmax(104px, 1fr)); }
  .goods-board-grid { grid-template-columns: repeat(4, minmax(126px, 1fr)); }
  .total-board-inline-pagination { width: 100%; margin-left: 0; justify-content: flex-end; }
}

@media (max-width: 680px) {
  .total-board-grid { grid-template-columns: repeat(2, minmax(126px, 1fr)); }
  .goods-board-grid { grid-template-columns: repeat(2, minmax(126px, 1fr)); }
}

/* 分级报表：按当前账号视角动态展示并支持逐级下钻 */
.report-drill-bar {
  min-height: 38px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  padding: 7px 10px;
  border-top: 1px solid #d6e1df;
  border-bottom: 1px solid #d6e1df;
  background: #f7faf9;
}
.report-drill-label { font-weight: 700; color: #315f5c; }
.report-drill-bar button {
  border: 0;
  background: transparent;
  color: #174ec7;
  padding: 2px 3px;
  cursor: pointer;
}
.report-drill-bar button:disabled { color: #222; font-weight: 700; cursor: default; }
.report-drill-sep { color: #879694; }
.report-drill-bar .report-root-button {
  margin-left: 8px;
  padding: 3px 9px;
  border: 1px solid #9eb9b6;
  border-radius: 2px;
  background: #fff;
  color: #315f5c;
}
.report-drill-tip { margin-left: auto; color: #777; font-size: 12px; }
.report-account-link {
  border: 0;
  background: transparent;
  color: #174ec7;
  padding: 0;
  cursor: pointer;
  font: inherit;
}
.report-account-link:hover { text-decoration: underline; }
.report-table { min-width: 1320px; }
.report-table thead .report-row-role { background: #e7eceb; color: #222; }
.report-table thead .report-role-member { background: #ffd268; color: #2a2a2a; }
.report-table thead .report-role-agent { background: #ffdda9; color: #2a2a2a; }
.report-table thead .report-role-shareholder { background: #f8cae1; color: #2a2a2a; }
.report-table thead .report-role-director { background: #cfdff4; color: #2a2a2a; }
@media (max-width: 900px) {
  .report-drill-tip { width: 100%; margin-left: 0; }
}

.report-drill-warning {
  margin-left: auto;
  color: #b12f35;
  font-size: 12px;
  font-weight: 700;
}
@media (max-width: 900px) {
  .report-drill-warning { width: 100%; margin-left: 0; }
}



/* 越级管理：独立于下级管理面板 */
.cross-info-line { margin-bottom: 10px; }
.cross-account-table { min-width: 1420px; }
.cross-account-table td:nth-child(2) { min-width: 170px; }
.cross-account-table td:nth-child(4) { min-width: 250px; }
.cross-path-cell { line-height: 1.65; color: #526362; }
#crossChildrenSummary .red-button { margin-left: 12px; }
.actions.wrap { flex-wrap: wrap; justify-content: center; gap: 5px; }

/* 子账号管理 */
.subaccount-page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 14px; }
.subaccount-page-head .section-title { margin-bottom: 7px; }
.subaccount-page-head p { margin: 0; color: #607170; line-height: 1.7; }
.subaccount-readonly-tip { min-width: 280px; padding: 12px 16px; border: 1px solid #9fc7c2; border-radius: 8px; background: #effaf8; color: #285c57; line-height: 1.6; }
.subaccount-layout { display: grid; grid-template-columns: minmax(420px, .9fr) minmax(620px, 1.4fr); align-items: start; gap: 16px; }
.subaccount-card { overflow: hidden; border: 1px solid #d7e1df; border-radius: 10px; background: #fff; box-shadow: 0 3px 12px rgba(31, 74, 70, .07); }
.subaccount-card-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; padding: 13px 16px; border-bottom: 1px solid #dce6e4; background: linear-gradient(180deg, #f8fcfb, #eef6f4); }
.subaccount-card-title b { color: #214f4b; font-size: 15px; }
.subaccount-card-title span { color: #73817f; font-size: 12px; }
.subaccount-form { padding: 16px; }
.subaccount-field-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.subaccount-field-grid > label { display: grid; gap: 6px; color: #405452; font-weight: 700; }
.subaccount-field-grid input { width: 100%; min-height: 36px; border: 1px solid #bdcbc9; border-radius: 6px; padding: 7px 9px; background: #fff; }
.subaccount-password-field { grid-column: 1 / -1; }
.subaccount-password-field .input-with-button { width: 100%; }
.subaccount-password-field .input-with-button input { flex: 1; }
.permission-fieldset { margin: 16px 0 10px; padding: 12px; border: 1px solid #cbd9d7; border-radius: 8px; background: #fafdfc; display: grid; grid-template-columns: repeat(2, minmax(190px, 1fr)); gap: 9px; }
.permission-fieldset legend { padding: 0 8px; color: #294f4c; font-weight: 700; }
.permission-fieldset legend small { color: #8a9695; font-weight: 400; }
.permission-fieldset > label { display: flex; align-items: flex-start; gap: 9px; min-height: 58px; padding: 10px; border: 1px solid #e0e8e7; border-radius: 7px; background: #fff; cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.permission-fieldset > label:hover { border-color: #87b8b2; box-shadow: 0 2px 8px rgba(61, 121, 114, .08); }
.permission-fieldset input { width: auto; margin-top: 3px; }
.permission-fieldset label > span { display: grid; gap: 3px; }
.permission-fieldset label b { color: #334c49; }
.permission-fieldset label small { color: #7a8886; line-height: 1.45; }
.subaccount-submit-row { display: flex; justify-content: flex-end; margin-top: 10px; }
.subaccount-created-result { border-radius: 7px; }
.subaccount-list-card .table-scroll { max-height: 610px; }
.subaccount-table { min-width: 900px; }
.subaccount-table td { vertical-align: top; }
.subaccount-table input[data-sub-name], .subaccount-table select[data-sub-status] { min-height: 32px; border: 1px solid #bdcbc9; border-radius: 5px; padding: 5px 7px; }
.permission-list { display: grid; grid-template-columns: repeat(2, minmax(120px, 1fr)); gap: 5px 8px; min-width: 290px; text-align: left; }
.permission-list label { display: flex; align-items: center; gap: 5px; padding: 3px 4px; border-radius: 4px; }
.permission-list label:hover { background: #f0f7f6; }
.permission-list input { width: auto; }
@media (max-width: 1180px) { .subaccount-layout { grid-template-columns: 1fr; } }
@media (max-width: 760px) {
  .subaccount-page-head { flex-direction: column; }
  .subaccount-readonly-tip { min-width: 0; width: 100%; }
  .subaccount-field-grid, .permission-fieldset { grid-template-columns: 1fr; }
  .subaccount-password-field { grid-column: auto; }
}

/* 更换线路弹窗 */
.management-line-dialog { overflow: hidden; }
.management-line-tip { padding: 12px 16px 6px; color: #5d666c; font-size: 13px; }
.management-line-list { display: grid; gap: 10px; padding: 10px 16px 4px; }
.management-line-card {
  width: 100%; min-height: 64px; display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 10px 13px; border: 1px solid #b8c7c5; background: #fff; cursor: pointer; text-align: left;
}
.management-line-card:hover { border-color: #2f6f6b; background: #f2f8f7; }
.management-line-card.active { border: 2px solid #2f6f6b; background: #edf6f5; }
.management-line-card span { min-width: 0; }
.management-line-card strong { display: block; color: #243332; font-size: 15px; }
.management-line-card small { display: block; margin-top: 4px; color: #75807f; overflow-wrap: anywhere; }
.management-line-card b { flex: 0 0 auto; color: #18764f; font-size: 14px; }
.management-line-card b.slow { color: #b36a00; }
.management-line-card b.bad { color: #aa2d35; }
.management-line-status { min-height: 26px; padding: 5px 16px 0; color: #73807e; font-size: 12px; }
.management-line-empty { padding: 20px; border: 1px dashed #b8c7c5; color: #73807e; text-align: center; }


/* 启动线路选择：白底页面只保留一个线路框，登录页暂不显示。 */
body.startup-line-selecting {
  background: #fff !important;
}
body.startup-line-selecting #loginView,
body.startup-line-selecting #homeView {
  display: none !important;
}
body.startup-line-selecting #lineModal {
  background: #fff !important;
}
body.startup-line-selecting #lineModal .management-line-dialog {
  width: min(640px, calc(100vw - 40px));
  max-height: calc(100vh - 40px);
  border: 1px solid #303030;
  box-shadow: none;
  background: #fff;
}
body.startup-line-selecting #lineModal .dialog-title {
  min-height: 0;
  padding: 9px 12px;
  border-bottom: 1px solid #777;
  background: #fff;
  color: #111;
  font-size: 16px;
}
body.startup-line-selecting #lineModal .management-line-tip {
  padding: 9px 12px 7px;
  color: #222;
}
body.startup-line-selecting #lineModal .management-line-list {
  gap: 0;
  padding: 0 8px;
}
body.startup-line-selecting #lineModal .management-line-card {
  min-height: 44px;
  margin-top: -1px;
  padding: 7px 10px;
  border-color: #888;
  background: #fff;
}
body.startup-line-selecting #lineModal .management-line-card:first-child {
  margin-top: 0;
}
body.startup-line-selecting #lineModal .management-line-card strong {
  color: #0665c9;
  font-size: 14px;
}
body.startup-line-selecting #lineModal .management-line-card small {
  margin-top: 2px;
  color: #333;
}
body.startup-line-selecting #lineModal .management-line-card b {
  color: #111;
}
body.startup-line-selecting #lineModal .management-line-status {
  min-height: 26px;
  padding: 7px 12px 8px;
  color: #222;
}
body.startup-line-selecting #lineModal .dialog-actions {
  display: none;
}

/* ========================================================================
   2026-08-22 管理端最终整理：全局彩种切换 / 清爽头部 / 分页货盘
   仅作用于 management 页面，不影响 member / player。
   ======================================================================== */
.management-header {
  position: static !important;
  height: auto !important;
  min-height: 86px;
  padding: 0 !important;
  background: #2f6f6b !important;
  color: #fff;
  box-shadow: 0 2px 7px rgba(25,55,53,.16);
}
.management-header-top {
  min-height: 45px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 6px 12px;
  border-bottom: 1px solid rgba(255,255,255,.14);
}
.management-game-switch {
  flex: 0 0 auto;
  display: inline-flex;
  overflow: hidden;
  height: 34px;
  border: 1px solid rgba(255,255,255,.75);
  border-radius: 5px;
}
.management-game-switch-btn {
  min-width: 72px;
  height: 32px;
  padding: 0 13px;
  border: 0;
  border-right: 1px solid rgba(255,255,255,.35);
  background: #287b76;
  color: #fff;
  font-weight: 800;
  font-size: 14px;
}
.management-game-switch-btn:last-child { border-right: 0; }
.management-game-switch-btn.is-active { background: #fff3a6; color: #263937; }
.management-game-switch-btn:hover:not(.is-active) { background: #358b85; }
.management-header .brand-box {
  position: static !important;
  flex: 0 0 auto;
  height: auto !important;
  width: auto !important;
  line-height: 1 !important;
  color: #fff !important;
  font-size: 20px !important;
  font-weight: 800;
  letter-spacing: .5px;
}
.management-header .identity-box {
  position: static !important;
  flex: 0 0 auto;
  width: auto !important;
  height: 32px !important;
  padding: 0 12px !important;
  border: 0 !important;
  border-left: 1px solid rgba(255,255,255,.18) !important;
  display: flex !important;
  align-items: center;
  gap: 8px;
  text-align: left !important;
  line-height: 1 !important;
}
.management-header .identity-box span,
.management-header .identity-box strong,
.management-header .identity-box a { display: inline !important; margin: 0 !important; }
.management-header .identity-box span { color: #d6e8e6; font-size: 12px; }
.management-header .identity-box strong { color: #fff; font-size: 14px; }
.management-header .identity-box a { color: #fff0a4 !important; font-size: 12px; text-decoration: none; font-weight: 600 !important; }
.header-market-box {
  flex: 0 0 auto;
  min-height: 32px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 11px;
  border-radius: 4px;
  background: rgba(0,0,0,.10);
  white-space: nowrap;
  font-size: 12px;
}
.header-market-box > span:first-child { font-weight: 800; color: #fff3a6; }
.header-market-box b { color: #fff; font-variant-numeric: tabular-nums; }
.management-header .header-message {
  position: static !important;
  flex: 1 1 auto;
  min-width: 160px;
  height: auto !important;
  overflow: hidden;
  color: #d7e6e4 !important;
  font-size: 12px;
  font-weight: 400 !important;
  white-space: nowrap;
  text-align: right;
}
.management-header .header-message span { animation: none !important; min-width: 0 !important; }
.management-header .legacy-nav {
  position: static !important;
  min-height: 40px;
  height: auto !important;
  display: flex !important;
  flex-wrap: wrap;
  align-items: stretch !important;
  gap: 0 !important;
  padding: 0 8px !important;
  overflow: visible;
}
.management-header .legacy-nav button {
  min-width: 74px !important;
  height: 40px !important;
  padding: 0 12px !important;
  border: 0 !important;
  border-bottom: 3px solid transparent !important;
  border-radius: 0 !important;
  background: transparent !important;
  color: #e8f0ef !important;
  font-size: 13px !important;
  font-weight: 650 !important;
}
.management-header .legacy-nav button:hover { background: rgba(255,255,255,.08) !important; color: #fff !important; }
.management-header .legacy-nav button.active { background: #fff !important; color: #2c5552 !important; border-bottom-color: #fff !important; }

.current-game-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 9px;
  border: 1px solid #b8ccca;
  border-radius: 3px;
  background: #f4f8f7;
  color: #50615f;
  white-space: nowrap;
}
.current-game-chip b { margin-left: 4px; color: #245d59; }
.tiny-input { width: 76px !important; min-width: 76px !important; }
.board-risk-message {
  padding: 7px 10px;
  border-bottom: 1px solid #dde5e4;
  background: #f7faf9;
  color: #697876;
  font-size: 12px;
}
.board-risk-message.error { color: #9a3137; background: #fff6f6; }
.board-risk-message.ok { color: #246d58; background: #f3fbf7; }
.total-board-table-wrap { padding: 0 0 18px; background: #fff; overflow: auto; }
.total-board-table { min-width: 1160px; }
.total-board-table td.number-cell { font-family: Consolas, "Microsoft YaHei", sans-serif; font-size: 15px; font-weight: 800; color: #276761; }
.risk-badge { display: inline-block; min-width: 46px; padding: 2px 6px; border-radius: 10px; font-size: 11px; font-weight: 700; }
.risk-badge.low { background: #edf7f2; color: #28705d; }
.risk-badge.medium { background: #fff6dd; color: #94640c; }
.risk-badge.high { background: #fff0e7; color: #a65521; }
.risk-badge.critical { background: #fdebed; color: #a12e38; }
.board-pagination {
  min-height: 42px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  border-bottom: 1px solid #dce4e3;
  background: #fff;
}
.board-pagination button {
  min-width: 76px;
  height: 28px;
  padding: 0 8px;
  border: 1px solid #b9c8c6;
  border-radius: 3px;
  background: #fff;
  color: #365653;
  font-size: 12px;
}
.board-pagination button:hover { border-color: #67948f; background: #f1f7f6; }
.board-pagination button:disabled { opacity: .45; cursor: default; background: #f5f7f7; }
.board-pagination .page-ellipsis { padding: 0 2px; color: #7c8987; }
.board-pagination button.active { border-color: #2f6f6b; background: #2f6f6b; color: #fff; font-weight: 700; }
.board-pagination .page-note { margin-left: 5px; color: #71807e; font-size: 12px; }
.total-board-summary { position: static !important; }
.total-board-filter { position: static !important; }

@media (max-width: 1280px) {
  .management-header-top { gap: 8px; padding-left: 8px; padding-right: 8px; }
  .management-header .header-message { display: none; }
  .management-header .legacy-nav button { min-width: 68px !important; padding: 0 9px !important; }
}

/* 2026-08-22 管理端内容区收口：筛选、标题、表格统一对齐 */
#homeView .breadcrumb-bar {
  min-height: 42px;
  height: auto;
  padding: 8px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-sizing: border-box;
}
#homeView .workspace {
  padding: 10px 14px 28px;
  box-sizing: border-box;
}
#homeView .panel {
  border: 1px solid #d8e1e0;
  background: #fff;
  box-shadow: 0 1px 2px rgba(28,61,58,.04);
}
#homeView .section-title {
  min-height: 36px;
  height: auto;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  box-sizing: border-box;
  border-bottom: 1px solid #d8e1e0;
  background: #f8faf9;
  color: #294d49;
}
#homeView .section-title.title-row { justify-content: space-between; gap: 12px; }
#homeView .search-strip {
  min-height: 48px;
  height: auto;
  padding: 9px 12px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  box-sizing: border-box;
  border-bottom: 1px solid #d8e1e0;
  background: #fff;
}
#homeView .search-strip label {
  margin: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}
#homeView .search-strip input,
#homeView .search-strip select,
#homeView .search-strip button {
  margin: 0;
  box-sizing: border-box;
}
#homeView .info-box,
#homeView .summary-strip,
#homeView .report-drill-bar { margin: 0; }
#homeView .table-scroll { width: 100%; box-sizing: border-box; }
#homeView .legacy-table { margin: 0; border-collapse: collapse; }
#homeView .legacy-table th { white-space: nowrap; }
#homeView .legacy-table td { vertical-align: middle; }
#homeView .total-board-summary {
  min-height: 44px;
  padding: 8px 10px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 16px;
  box-sizing: border-box;
  border-bottom: 1px solid #dce4e3;
  background: #fbfcfc;
}
#homeView .total-board-summary span { white-space: nowrap; }
#homeView .total-board-help {
  padding: 7px 10px;
  border-bottom: 1px solid #dce4e3;
  background: #f6f9f8;
  color: #657572;
  line-height: 1.55;
}
@media (max-width: 900px) {
  .management-header-top { align-items: flex-start; flex-wrap: wrap; }
  .management-header .identity-box { border-left: 0 !important; padding-left: 0 !important; }
  .header-market-box { order: 5; width: 100%; box-sizing: border-box; }
  #homeView .breadcrumb-bar { align-items: flex-start; flex-direction: column; }
}

/* 2026-08-23 管理端轻量排版：左侧彩种区独立，占满左上角；账号与首个导航垂直对齐。 */
.management-header {
  position: relative !important;
  min-height: 86px !important;
  overflow: hidden;
}
.management-header-top {
  min-height: 46px;
  margin-left: 152px;
  padding: 6px 0 !important;
  gap: 0;
}
.management-game-switch {
  position: absolute;
  z-index: 2;
  left: 8px;
  top: 6px;
  bottom: 6px;
  width: 136px;
  height: auto;
  display: grid;
  grid-template-rows: 1fr 1fr;
  border: 1px solid rgba(255,255,255,.68);
  border-radius: 3px;
  background: rgba(0,0,0,.08);
}
.management-game-switch-btn {
  width: 100%;
  min-width: 0;
  height: auto;
  min-height: 0;
  padding: 0 10px;
  border: 0;
  border-bottom: 1px solid rgba(255,255,255,.22);
  border-right: 0;
  border-radius: 0;
  font-size: 14px;
  letter-spacing: .5px;
}
.management-game-switch-btn:last-child { border-bottom: 0; }
.management-header .identity-box {
  flex: 0 0 116px;
  width: 116px !important;
  padding: 0 8px !important;
  border-left: 0 !important;
  border-right: 1px solid rgba(255,255,255,.16) !important;
  justify-content: center;
  gap: 6px;
  text-align: center !important;
}
.header-market-box {
  margin-left: 10px;
  padding: 0 10px;
}
.management-header .legacy-nav {
  margin-left: 152px;
  padding: 0 !important;
}
.management-header .legacy-nav button:first-child {
  flex: 0 0 116px;
  width: 116px;
}

/* 账表面板只保留必要标题、筛选和表格，贴近参考图的紧凑信息密度。 */
#totalGoodsPanel,
#contributionPanel,
#categoryPanel,
#reportPanel {
  border: 0 !important;
  box-shadow: none !important;
}
#totalGoodsPanel > .section-title,
#contributionPanel > .section-title,
#categoryPanel > .section-title,
#reportPanel > .section-title {
  min-height: 32px !important;
  padding: 6px 9px !important;
  border: 0 !important;
  background: #2f7b76 !important;
  color: #fff !important;
  font-size: 13px !important;
}
#totalGoodsPanel > .search-strip,
#contributionPanel > .search-strip,
#categoryPanel > .search-strip,
#reportPanel > .search-strip {
  min-height: 40px !important;
  padding: 6px 9px !important;
  gap: 6px 12px !important;
  border: 1px solid #d5dfde !important;
  border-top: 0 !important;
  box-shadow: none !important;
}
#totalGoodsPanel > .search-strip:first-child {
  border-top: 1px solid #d5dfde !important;
}
#totalGoodsPanel .legacy-table th,
#contributionPanel .legacy-table th,
#categoryPanel .legacy-table th {
  background: #2f7b76;
}
#reportPanel .report-drill-bar,
#reportPanel .summary-strip {
  padding-top: 7px;
  padding-bottom: 7px;
}

@media (max-width: 1280px) {
  .management-header-top { margin-left: 152px; padding-left: 0 !important; padding-right: 0 !important; }
  .management-header .legacy-nav { margin-left: 152px; }
}

/* 2026-08-23：管理端按参考页收敛为直接的传统表格布局 */
.breadcrumb-bar {
  min-height: 34px;
  margin: 10px 8px 8px;
  padding: 0 12px;
  border: 1px solid var(--border);
  background: var(--pale);
}
.section-title {
  min-height: 32px;
  padding: 6px 8px;
  border: 1px solid var(--teal-dark);
  background: var(--teal);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
}
.title-row > span:last-child { color: #fff; }
.search-strip {
  min-height: 40px;
  padding: 6px 9px;
  border: 1px solid var(--border);
  border-top: none;
  background: #fff;
  box-shadow: none;
}
.table-scroll {
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  background: #fff;
}
.legacy-table th,
.legacy-table td {
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 6px 7px;
}
.legacy-table th:last-child,
.legacy-table td:last-child { border-right: none; }
.legacy-table thead th {
  background: var(--teal);
  color: #fff;
  font-size: 13px;
  font-weight: 700;
}
.legacy-table tbody tr:nth-child(odd) td { background: var(--gray-cell); }
.legacy-table tbody tr:hover td { background: inherit; }

/* 设置：不再重复一排内部页签；水位直接并入基本资料 */
#settingsBasic > .profile-table { margin-bottom: 0; }
.own-water-basic-block { margin-top: 12px; }
.simple-water-toolbar {
  min-height: 40px;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 9px;
  border: 1px solid var(--border);
  background: #fff;
}
.simple-water-toolbar label { display: inline-flex; align-items: center; gap: 5px; font-weight: 700; }
.simple-water-toolbar input[type="checkbox"] { width: 16px; height: 16px; margin: 0; accent-color: var(--teal-dark); }
.simple-water-toolbar select { height: 27px; min-width: 90px; border: 1px solid #b9c3cb; background: #fff; }
.own-water-table-scroll { border-top: none; }
.own-water-table { min-width: 760px; }
.own-water-table td:first-child { text-align: left; min-width: 190px; }
.own-water-table select { height: 27px; min-width: 82px; border: 1px solid #b9c3cb; background: #fff; text-align: center; }
.own-water-table .readonly-value { color: #444; font-weight: 600; }
.compact-message { min-height: 18px; padding-top: 3px; font-size: 12px; }

/* 越级/下级管理列表页只保留查询 + 表格，避免重复概览和同名标题 */
#crossLevelPanel .account-subview,
#accountsPanel .account-subview { min-height: 0; }
.cross-info-line { margin-bottom: 0; }

/* 管理端占成：0-10成输入，不再沿用旧“开发中”灰态 */
.share-config-block {
  border-left-color: var(--teal-dark);
  background: #f8fbfb;
  color: #333;
}
.share-config-block .development-badge { background: var(--teal-dark); }
.share-config-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px 22px;
  margin: 12px 0 8px;
}
.share-config-grid label { display: grid; grid-template-columns: 100px minmax(100px, 160px) 1fr; align-items: center; gap: 8px; }
.share-config-grid label > span { text-align: right; white-space: nowrap; font-weight: 700; }
.share-config-grid input { height: 30px; min-width: 0; border: 1px solid #b9c3cb; background: #fff; padding: 3px 7px; }
.share-config-grid input:disabled { background: #eceff1; color: #888; }
.share-config-grid small { color: #6a7479; line-height: 1.35; }

/* 设置-基本资料：同玩法只显示一行；“同”直接跟在列名右侧 */
.own-water-table { min-width: 860px; }
.own-water-table th { white-space: nowrap; }
.header-sync { display: inline-flex; align-items: center; gap: 2px; margin-left: 5px; font-size: 12px; font-weight: 600; cursor: pointer; }
.header-sync input { width: 14px; height: 14px; margin: 0; accent-color: var(--teal-dark); vertical-align: middle; }
.play-group-name b { display: inline-block; min-width: 70px; }
.play-group-name small { display: inline-block; margin-left: 8px; color: #788287; font-weight: 400; }
.blocked-amount-input { width: 96px; height: 27px; border: 1px solid #b9c3cb; background: #fff; padding: 2px 6px; text-align: right; }

@media (max-width: 760px) {
  .share-config-grid { grid-template-columns: 1fr; }
  .share-config-grid label { grid-template-columns: 96px minmax(90px, 140px) 1fr; }
}

/* 2026-08-24 设置页按用户参考图调整：上方基本资料 + 类别树形分组。仅作用于管理端。 */
#settingsBasic.legacy-settings-reference {
  background: #fff;
}
#settingsBasic .settings-info-panel { margin: 0 0 12px; }
#settingsBasic .settings-info-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
#settingsBasic .settings-collapse-mark {
  color: #d8ffff;
  font-size: 13px;
  line-height: 1;
}
#settingsBasic .settings-info-content {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 6px 7px;
  border: 1px solid var(--border);
  border-top: 0;
  background: #fff;
  color: #111;
}
#settingsBasic .settings-info-content b { font-weight: 400; }

#settingsBasic .settings-reference-profile {
  width: 100%;
  table-layout: fixed;
  margin: 0;
  border-collapse: collapse;
}
#settingsBasic .settings-reference-profile th,
#settingsBasic .settings-reference-profile td {
  height: 38px;
  padding: 4px 6px;
  border: 1px solid var(--border);
  background: #f2f3f3;
  vertical-align: middle;
}
#settingsBasic .settings-reference-profile th {
  width: 10%;
  text-align: left;
  font-weight: 400;
  color: #111;
}
#settingsBasic .settings-reference-profile td { width: 40%; }
#settingsBasic .settings-reference-profile input {
  width: 210px;
  max-width: calc(100% - 8px);
  height: 26px;
  padding: 2px 5px;
  border: 1px solid #b8bfc2;
  background: #f6f6f6;
  color: #111;
  border-radius: 0;
}
#settingsBasic .settings-credit-cell { white-space: nowrap; }
#settingsBasic .settings-credit-cell input { width: 210px; }
#settingsBasic .settings-credit-cell button {
  margin-left: 6px;
  height: 27px;
  vertical-align: middle;
}
#settingsBasic .verification-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 68px;
  height: 30px;
  padding: 0 10px;
  border: 1px solid #a41717;
  border-radius: 5px;
  background: linear-gradient(#dc5b5b, #b41515);
  box-shadow: inset 0 0 0 2px rgba(255,255,255,.18);
  color: #fff;
  font-size: 14px;
  line-height: 1;
}
#settingsBasic .settings-profile-submit {
  display: flex;
  justify-content: center;
  padding: 11px 0 10px;
}
#settingsBasic .settings-profile-submit .red-button { min-width: 54px; }

#settingsBasic .own-water-basic-block { margin-top: 0; }
#settingsBasic .own-water-table-scroll {
  border: 1px solid var(--border);
  overflow: auto;
}
#settingsBasic .own-water-table {
  min-width: 980px;
  table-layout: auto;
  border-collapse: collapse;
}
#settingsBasic .own-water-table th,
#settingsBasic .own-water-table td {
  border-right: 1px solid var(--border) !important;
  border-bottom: 1px solid var(--border) !important;
  padding: 7px 6px;
  background: #eef2f4 !important;
  color: #111;
}
#settingsBasic .own-water-table thead th {
  background: var(--teal) !important;
  color: #fff !important;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
}
#settingsBasic .own-water-table tr:last-child td { border-bottom: 0 !important; }
#settingsBasic .own-water-table th:last-child,
#settingsBasic .own-water-table td:last-child { border-right: 0 !important; }
#settingsBasic .own-water-table .play-tree-toggle,
#settingsBasic .own-water-table .play-tree-spacer {
  width: 26px;
  min-width: 26px;
  max-width: 26px;
  padding-left: 5px;
  padding-right: 5px;
  text-align: center;
}
#settingsBasic .own-water-table .play-tree-toggle {
  color: #c9e9e7;
  font-size: 12px;
}
#settingsBasic .own-water-table .play-group-heading {
  min-width: 180px;
  text-align: left;
  color: #0000ee;
  text-decoration: underline;
  font-weight: 400;
}
#settingsBasic .own-water-table .play-group-fill { background: #eef2f4 !important; }
#settingsBasic .own-water-table .play-category-name {
  min-width: 180px;
  text-align: left;
  font-weight: 400;
}
#settingsBasic .own-water-table .play-category-row td:not(.play-tree-spacer):not(.play-category-name) {
  text-align: left;
}
#settingsBasic .own-water-table select,
#settingsBasic .own-water-table .blocked-amount-input {
  height: 27px;
  border: 1px solid #9da7aa;
  background: #fff;
  border-radius: 0;
}
#settingsBasic .own-water-table .blocked-amount-input {
  width: 195px;
  max-width: 100%;
  text-align: left;
}
#settingsBasic .own-water-table .readonly-value { font-weight: 400; }
#settingsBasic .header-sync {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-left: 4px;
  color: #fff;
  font-size: 12px;
  font-weight: 600;
  vertical-align: middle;
}
#settingsBasic .header-sync input {
  width: 14px;
  height: 14px;
  margin: 0;
}
#settingsBasic .settings-save-toolbar {
  justify-content: center;
  border-top: 0;
}
.breadcrumb-bar .breadcrumb-arrows { color: #d30000; }

@media (max-width: 1100px) {
  #settingsBasic .settings-reference-profile input { width: 170px; }
  #settingsBasic .settings-reference-profile th { width: 13%; }
  #settingsBasic .settings-reference-profile td { width: 37%; }
}

/* 2026-08-24 下级管理：按旧版参考图精简为信息提示 / 模式查询 / 直属列表。 */
.subordinate-list-simple .account-reference-box {
  margin: 0 0 12px;
  border: 1px solid var(--border);
  background: #fff;
}
.subordinate-list-simple .account-reference-title {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 6px 8px;
  background: var(--teal);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
}
.subordinate-list-simple .account-reference-content {
  min-height: 40px;
  display: flex;
  align-items: center;
  padding: 7px 30px;
  line-height: 1.6;
}
.subordinate-list-simple .account-mode-query { display: block; }
.subordinate-list-simple .account-mode-content { justify-content: flex-end; }
.subordinate-list-simple .account-mode-content label { display: inline-flex; align-items: center; gap: 6px; }
.subordinate-list-simple .account-mode-content select {
  height: 30px;
  min-width: 82px;
  border: 1px solid #b9c3cb;
  background: #f7f7f7;
  padding: 2px 6px;
}
.subordinate-list-table-wrap { border-top: 1px solid var(--border); }
.subordinate-list-table td:nth-child(2) { min-width: 150px; line-height: 1.45; }
.subordinate-list-table td:nth-child(3) { min-width: 90px; }
.subordinate-list-table td:nth-child(4) { min-width: 220px; }
.subordinate-list-table td:nth-child(5) { min-width: 120px; }
.subordinate-list-table td:nth-child(6) { min-width: 145px; }
.subordinate-list-table td:nth-child(7) { min-width: 90px; }
.subordinate-list-table td:nth-child(8) { min-width: 120px; }
.subordinate-list-table td:nth-child(10) { min-width: 220px; }
.subordinate-list-table .account-edit-link { font-weight: 500; text-decoration: none; }
.subordinate-list-table .account-edit-link:hover { text-decoration: underline; }
.subordinate-list-table .share-summary-cell { line-height: 1.7; }
.subordinate-list-table .share-summary-cell b { font-weight: 500; }
.subordinate-list-table .subordinate-actions { gap: 6px; white-space: nowrap; }
.subordinate-list-table .action-sep { color: #777; }

/* 下级编辑页：只保留当前彩种的一行拦货占成，股东看“股东 / 总代理上限”，代理只显示“代理”。 */
.subordinate-edit-basic-grid { padding-top: 12px; padding-bottom: 12px; }
.subordinate-share-block { margin: 10px 0; padding: 10px 14px; }
.subordinate-share-block > div:first-child { font-size: 15px; }
.subordinate-share-grid { display: block; margin: 8px 0 5px; }
.subordinate-share-grid .subordinate-share-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px 16px;
  min-height: 34px;
}
.subordinate-share-grid .share-parent-reading,
.subordinate-share-grid .share-child-reading {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.subordinate-share-grid .share-parent-reading > b,
.subordinate-share-grid .share-child-reading > b { font-weight: 700; }
.subordinate-share-grid .share-parent-reading > strong { min-width: 24px; font-weight: 500; }
.subordinate-share-grid .share-parent-reading select,
.subordinate-share-grid .share-child-reading select,
.subordinate-share-grid .share-child-reading input {
  width: 76px;
  height: 28px;
  border: 1px solid #b9c3cb;
  background: #fff;
  padding: 2px 6px;
  text-align: center;
}
.subordinate-share-grid small { color: #666; }
.subordinate-share-block p { line-height: 1.65; }
body[data-management-game="lucky5"] .subordinate-share-grid .share-game-ao5 { display: none !important; }
body[data-management-game="ao5"] .subordinate-share-grid .share-game-lucky5 { display: none !important; }

/* 下级管理 > 修改：玩法参数由下级自行维护，上级只调整赚水。 */
.subordinate-readonly-settings-table .readonly-value {
  color: #222;
  font-weight: 400;
  text-align: left;
}
.subordinate-readonly-settings-table .play-group-row .play-group-heading {
  text-align: left;
  color: #0000ee;
  text-decoration: underline;
  font-weight: 400;
  background: #eef2f4;
}
.subordinate-readonly-settings-table td,
.subordinate-readonly-settings-table th {
  white-space: nowrap;
}
.subordinate-readonly-settings-table .play-group-row .play-group-fill { background: #eef2f4; }

/* 2026-08-25：分类账按月 / 日 / 期三种旧版账页结构重排，沿用管理端青绿色主题。 */
#categoryPanel .category-ledger-toolbar {
  min-height: 38px !important;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 5px 8px !important;
}
.category-ledger-left,
.category-month-actions,
.category-issue-range,
.category-period-select {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  white-space: nowrap;
}
.category-ledger-left { min-width: 0; }
.category-ledger-left > strong { font-size: 14px; }
.category-month-actions { margin-left: 8px; }
.category-month-actions button,
.category-ledger-toolbar .category-total-link {
  border: 0;
  background: transparent;
}
.category-month-actions button {
  padding: 0 2px;
  color: #fff6a2;
  font-weight: 700;
}
.category-month-actions button:hover,
.category-month-actions button.active { color: #fff; text-decoration: underline; }
.category-issue-range { margin-left: auto; }
.category-issue-range select,
.category-period-select select {
  height: 27px;
  min-width: 128px;
  padding: 1px 6px;
  border: 1px solid #d4e7e5;
  background: #fff;
  color: #222;
}
.category-issue-range b { color: #fff; font-size: 16px; }
.category-period-select { color: #fff; font-weight: 700; }

.category-drill-bar {
  min-height: 34px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  padding: 5px 9px;
  border: 1px solid var(--border);
  border-top: 0;
  background: var(--pale);
}
.category-drill-label { color: var(--teal-dark); font-weight: 700; }
.category-drill-bar button,
.category-date-link,
.category-account-link,
.category-total-link {
  border: 0;
  background: transparent;
  padding: 0;
  color: var(--blue);
  font-weight: 700;
}
.category-drill-bar button:hover:not(:disabled),
.category-date-link:hover,
.category-account-link:hover,
.category-total-link:hover { text-decoration: underline; }
.category-drill-bar button:disabled { color: #333; cursor: default; }
.category-root-button { margin-right: 2px; }
.category-drill-sep { color: #8a9997; }
.category-drill-date { margin-left: 8px; color: #555; font-weight: 700; }

.category-ledger-table-wrap { border-top: 0; }
.category-ledger-table { min-width: 900px; }
.category-ledger-table th:first-child { min-width: 150px; }
.category-ledger-table th:nth-child(2) { min-width: 170px; }
.category-ledger-table .category-grand-total td { font-weight: 700; }
.category-ledger-table .category-grand-total td:first-child { color: var(--red); }
.category-total-link { display: inline-flex; align-items: center; gap: 5px; }
.category-expand-icon { color: var(--teal-dark); font-size: 15px; line-height: 1; }
.category-ledger-table .category-detail-row td {
  background: #e8f4f3 !important;
  font-weight: 600;
}
.category-ledger-table .category-detail-row td:nth-child(2) { color: #333; }
.category-detail-indent { display: inline-block; margin-right: 7px; color: var(--teal-dark); }

@media (max-width: 1280px) {
  #categoryPanel .category-ledger-toolbar { flex-wrap: wrap; }
  .category-issue-range { margin-left: 0; }
}
.category-ledger-table tbody tr.category-row-expanded > td { background: #f3fbfa !important; }

/* 2026-08-25 报表页精简：路径放进“位置”，去掉重复的“当前查看”和摘要条，保持旧式报表布局。 */
#homeView #reportPanel {
  border: 0;
  box-shadow: none;
}
#homeView #reportPanel .report-title-row {
  min-height: 40px;
  padding: 6px 8px;
  border: 1px solid var(--teal-dark);
  background: var(--teal) !important;
  color: #fff !important;
  font-size: 15px;
  font-weight: 700;
}
#homeView #reportPanel .report-title-row > span { color: #fff; }
#homeView #reportPanel .report-print-button {
  border: 0;
  background: transparent;
  color: #fff;
  padding: 0 12px;
  font-weight: 700;
  cursor: pointer;
}
#homeView #reportPanel .report-print-button:hover { text-decoration: underline; }
#homeView #reportPanel .report-filter-strip {
  min-height: 36px;
  padding: 4px 8px;
  gap: 6px 10px;
  border: 1px solid var(--border);
  border-top: 0;
  background: #fff;
  font-size: 12px;
}
#homeView #reportPanel .report-filter-strip input {
  height: 26px;
  width: 136px;
  min-width: 136px;
  padding: 1px 5px;
}
#homeView #reportPanel .report-filter-strip .small {
  min-height: 26px;
  padding: 2px 10px;
  border-radius: 1px;
}
#homeView #reportPanel .report-drill-bar,
#homeView #reportPanel .summary-strip {
  display: none !important;
}
#homeView #reportPanel .report-table-wrap { border-top: 0; }
#homeView #reportPanel .report-table {
  min-width: 1080px;
  font-size: 13px;
}
#homeView #reportPanel .report-table th,
#homeView #reportPanel .report-table td {
  height: 38px;
  padding: 5px 6px;
  color: #000;
  font-weight: 400;
}
#homeView #reportPanel .report-table thead th {
  font-size: 14px;
  font-weight: 400;
}
#homeView #reportPanel .report-table thead .report-row-role {
  background: #efefef;
}
#homeView #reportPanel .report-table tbody tr:nth-child(odd) td,
#homeView #reportPanel .report-table tbody tr:nth-child(even) td {
  background: #fff;
}
#homeView #reportPanel .report-table tbody td:first-child {
  background: #f7f7f7 !important;
  text-align: left;
}
#homeView #reportPanel .report-table tbody td.report-data-member { background: #ffd268 !important; }
#homeView #reportPanel .report-table tbody td.report-data-agent { background: #ffdda9 !important; }
#homeView #reportPanel .report-table tbody td.report-data-shareholder { background: #f8cae1 !important; }
#homeView #reportPanel .report-table tbody td.report-data-director { background: #dce7f4 !important; }
#homeView #reportPanel .report-table .positive,
#homeView #reportPanel .report-table .negative { color: #000; font-weight: 400; }
#homeView #reportPanel .report-table tfoot td {
  background: #b7dfdf !important;
  color: #000;
  font-weight: 700;
}
#homeView #reportPanel .report-account-link {
  color: #111;
  font-weight: 400;
  text-decoration: none;
}
#homeView #reportPanel .report-account-link:hover { text-decoration: underline; }
#homeView #reportPanel .report-latest-issue { color: #e00000; font-weight: 700; }
#homeView #reportPanel .report-row-index { color: #003cff; font-weight: 700; margin-right: 2px; }
#homeView #reportPanel .report-account-text { color: #111; }

#homeView .breadcrumb-bar #breadcrumb .report-location-base,
#homeView .breadcrumb-bar #breadcrumb .report-location-mode { color: #e00000; }
#homeView .breadcrumb-bar #breadcrumb .report-location-sep { color: #e00000; font-weight: 400; }
#homeView .breadcrumb-bar #breadcrumb .report-location-account,
#homeView .breadcrumb-bar #breadcrumb .report-location-issue { color: #003cff; font-weight: 500; }
#homeView .breadcrumb-bar #breadcrumb .report-breadcrumb-link {
  border: 0;
  background: transparent;
  color: #003cff;
  padding: 0;
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}
#homeView .breadcrumb-bar #breadcrumb .report-breadcrumb-link:hover { text-decoration: underline; }

@media print {
  #homeView .management-header,
  #homeView .breadcrumb-bar,
  #homeView #reportPanel .report-filter-strip,
  #homeView #reportPanel .report-print-button,
  #homeView .toast { display: none !important; }
  #homeView .workspace { padding: 0 !important; }
  #homeView .panel { display: none !important; }
  #homeView #reportPanel { display: block !important; border: 0 !important; }
  #homeView #reportPanel .table-scroll { overflow: visible !important; }
  #homeView #reportPanel .report-table { min-width: 0 !important; width: 100% !important; }
}
#homeView #reportPanel .report-title-actions {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

/* 会员报表：沿用旧式报表的紧凑分页，不占用摘要栏。 */
#homeView #reportPanel .report-member-pagination {
  padding: 7px 4px 4px;
  text-align: center;
  font-size: 13px;
  color: #111;
  white-space: nowrap;
}
#homeView #reportPanel .report-member-pagination.hidden { display: none !important; }
#homeView #reportPanel .report-member-pagination button {
  margin-left: 5px;
  padding: 1px 5px;
  border: 0;
  background: transparent;
  color: #001a8d;
  cursor: pointer;
  font-size: 13px;
}
#homeView #reportPanel .report-member-pagination button:disabled { color: #999; cursor: default; }
#homeView #reportPanel .report-member-pagination input {
  width: 44px;
  height: 22px;
  margin-left: 6px;
  padding: 0 3px;
  border: 1px solid #aaa;
  text-align: center;
}
#homeView #reportPanel .report-table td.report-bet-number { text-align: center; }
#homeView #reportPanel .report-table td.report-bet-number b { font-weight: 700; }

/* 2026-08-25：贡献度按参考页使用“日期 + 下级账号 + 占成”九列表格，仅作用于贡献度面板。 */
#homeView #contributionPanel .contribution-reference-table {
  min-width: 1120px;
}
#homeView #contributionPanel .contribution-reference-table thead th {
  background: #eeeeee !important;
  color: #222 !important;
  font-weight: 400;
  font-size: 14px;
  border-right: 1px solid #8fb6b3;
}
#homeView #contributionPanel .contribution-reference-table tbody td {
  background: #fff !important;
  border-right: 1px solid #8fb6b3;
}
#homeView #contributionPanel .contribution-reference-table tfoot td {
  background: #ffff99 !important;
  color: #e00000;
  border-right: 1px solid #8fb6b3;
}
#homeView #contributionPanel .contribution-account-link,
#homeView .contribution-breadcrumb-link {
  border: 0;
  background: transparent;
  color: #153bff;
  padding: 0;
  cursor: pointer;
  font: inherit;
}
#homeView #contributionPanel .contribution-account-link:hover,
#homeView .contribution-breadcrumb-link:hover {
  text-decoration: underline;
}

/* 2026-08-25：贡献度日期范围按参考图改为“上月 / 本月 / 当天 / 全部”，全部仅覆盖上月 + 本月。 */
#homeView #contributionPanel > .contribution-period-strip {
  min-height: 36px;
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 5px 8px 4px;
  border: 0;
  border-bottom: 2px solid #159b91;
  background: #fff;
  box-shadow: none;
}
#homeView #contributionPanel > .contribution-period-strip [data-contribution-range] {
  border: 0;
  background: transparent;
  padding: 0;
  color: #0000ee;
  font: 400 14px/1.5 Arial, "Microsoft YaHei", sans-serif;
  cursor: pointer;
}
#homeView #contributionPanel > .contribution-period-strip [data-contribution-range]:hover {
  text-decoration: underline;
}
#homeView #contributionPanel > .contribution-period-strip [data-contribution-range].active {
  color: #ff0000;
}
#homeView #contributionPanel > .contribution-period-strip .contribution-download-button {
  margin-left: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: #0000ee;
  font-size: 12px;
  cursor: pointer;
}
#homeView #contributionPanel > .contribution-period-strip .contribution-download-button:hover {
  text-decoration: underline;
}


/* 越级操作 / 下级管理：严格按用户提供的旧版流程图复刻结构；仅沿用本站配色。 */
#crossLevelPanel,
#accountsPanel { border: 0 !important; box-shadow: none !important; }

#crossLevelPanel .account-reference-box,
#accountsPanel .account-reference-box,
#homeView .account-create-page .account-reference-box,
#crossLevelPanel .edit-info-box,
#accountsPanel .edit-info-box {
  margin: 0 0 12px;
  border: 1px solid var(--border);
  background: #fff;
}
#crossLevelPanel .account-reference-title,
#accountsPanel .account-reference-title,
#homeView .account-create-page .account-reference-title,
#crossLevelPanel .edit-info-box .account-reference-title,
#accountsPanel .edit-info-box .account-reference-title {
  min-height: 38px;
  display: flex;
  align-items: center;
  padding: 6px 8px;
  border: 0;
  background: var(--teal);
  color: #fff;
  font-size: 16px;
  font-weight: 700;
}
#crossLevelPanel .account-reference-content,
#accountsPanel .account-reference-content,
#homeView .account-create-page .account-reference-content,
#crossLevelPanel .edit-info-box .account-reference-content,
#accountsPanel .edit-info-box .account-reference-content {
  min-height: 40px;
  display: flex;
  align-items: center;
  padding: 7px 30px;
  line-height: 1.6;
}

/* 越级操作的“级别查询”与参考图一致：账号、代号在左，资金模式靠右。 */
#crossLevelPanel .account-level-content {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 0;
  min-height: 42px;
}
#crossLevelPanel .account-level-content > label {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border-right: 1px solid var(--border);
  white-space: nowrap;
}
#crossLevelPanel .account-level-content > label:first-child { border-left: 0; }
#crossLevelPanel .account-level-content input {
  width: 120px;
  height: 29px;
  border: 1px solid #aeb8bd;
  background: #fff;
  padding: 2px 6px;
}
#crossLevelPanel .account-level-content .red-button { margin-left: 7px; }
#crossLevelPanel .level-query-spacer { flex: 1 1 auto; }
#crossLevelPanel .account-level-content > label:last-of-type {
  margin-left: 8px;
  border-left: 1px solid var(--border);
  border-right: 0;
}
#crossLevelPanel .account-level-content select,
#accountsPanel .account-mode-content select {
  height: 29px;
  min-width: 72px;
  border: 1px solid #b9c3cb;
  background: #f5f5f5;
  padding: 2px 5px;
}

/* 下级管理仍是同一张旧版列表；它不提供逐级下钻创建。 */
#accountsPanel .account-mode-content {
  min-height: 42px;
  justify-content: flex-end;
  padding: 0;
}
#accountsPanel .account-mode-content > label {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 8px;
  border-left: 1px solid var(--border);
}

#crossLevelPanel .subordinate-list-table-wrap,
#accountsPanel .subordinate-list-table-wrap { border-top: 1px solid var(--border); }
#crossLevelPanel .subordinate-list-table th,
#accountsPanel .subordinate-list-table th { text-align: left; }
#crossLevelPanel .subordinate-list-table td,
#accountsPanel .subordinate-list-table td { text-align: left; }
#crossLevelPanel .subordinate-list-table td:first-child,
#accountsPanel .subordinate-list-table td:first-child { width: 48px; }
#crossLevelPanel .subordinate-list-table .actions,
#accountsPanel .subordinate-list-table .actions { justify-content: flex-start; }
#crossLevelPanel .cross-account-link,
#accountsPanel .account-edit-link { color: #0000ee; font-weight: 400; text-decoration: none; }
#crossLevelPanel .cross-account-link:hover,
#accountsPanel .account-edit-link:hover { text-decoration: underline; }

/* 新增下级：信息提示 -> 新增角色 -> 账号/密码/密码规则 -> 底部提交。 */
#homeView .account-create-page { min-height: 0; background: #fff; }
#homeView .account-create-page .create-info-box { margin-bottom: 12px; }
#homeView .account-create-page .create-form-box { margin: 0; }
#homeView .account-create-page .create-form-box > .account-reference-title { margin: 0; }
#homeView .create-reference-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
}
#homeView .create-reference-table th,
#homeView .create-reference-table td {
  border: 1px solid var(--border);
  border-top: 0;
  padding: 6px;
  background: #fff;
  text-align: left;
  vertical-align: middle;
}
#homeView .create-reference-table th {
  width: 135px;
  font-weight: 400;
}
#homeView .create-reference-table input {
  width: 210px;
  height: 29px;
  border: 1px solid #9fa8ad;
  background: #fff;
  padding: 2px 6px;
}
#homeView .create-reference-table .password-rules-row th { vertical-align: middle; }
#homeView .password-rules-reference {
  min-height: 145px;
  color: #0000ee;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.45;
}
#homeView .create-submit-row {
  display: flex;
  justify-content: center;
  padding: 12px 0 22px;
}
#homeView .account-create-page .message { padding-left: 140px; }

/* 保存成功：保持在新增页上方的居中提示框，确认后才回列表。 */
#saveSuccessModal {
  background: rgba(0,0,0,.28);
  align-items: center;
  justify-content: center;
}
#saveSuccessModal:not(.hidden) { display: flex; }
.save-success-dialog {
  width: 438px;
  min-height: 245px;
  background: #fff;
  border-radius: 4px;
  box-shadow: 0 12px 34px rgba(0,0,0,.28);
  overflow: hidden;
}
.save-success-title {
  height: 52px;
  display: flex;
  align-items: center;
  padding: 0 13px;
  border-bottom: 1px solid #d8dde0;
  font-size: 20px;
}
.save-success-body {
  min-height: 112px;
  padding: 16px 13px;
  font-size: 16px;
}
.save-success-actions {
  display: flex;
  justify-content: center;
  padding: 12px 0 18px;
}

/* 编辑页：按参考图直接铺在内容区，不再出现额外返回卡片；浏览器后退负责后退。 */
#editModal > .account-page-card > .account-page-title { display: none !important; }
#crossEditModal .dialog-actions .cross-subview-back,
#editModal .dialog-actions .account-subview-back { display: none !important; }
#crossEditModal .account-page-card,
#editModal .account-page-card { border: 0 !important; }
#crossEditModal .dialog-scroll,
#editModal .dialog-scroll { padding: 0 !important; }
#crossEditModal .edit-info-box,
#editModal .edit-info-box { margin-bottom: 12px; }
#crossEditModal .section-title,
#editModal .section-title {
  min-height: 38px !important;
  padding: 6px 8px !important;
  border: 1px solid var(--teal-dark) !important;
  background: var(--teal) !important;
  color: #fff !important;
  font-size: 16px !important;
}
#crossEditModal .reference-edit-grid,
#editModal .reference-edit-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-top: 0;
  background: #fff;
}
#crossEditModal .reference-edit-grid > label,
#editModal .reference-edit-grid > label {
  min-height: 37px;
  display: grid;
  grid-template-columns: 195px minmax(0, 1fr);
  gap: 0;
  margin: 0;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  background: #fff;
}
#crossEditModal .reference-edit-grid > label:nth-child(even),
#editModal .reference-edit-grid > label:nth-child(even) { border-right: 0; }
#crossEditModal .reference-edit-grid > label > span:first-child,
#editModal .reference-edit-grid > label > span:first-child {
  width: auto;
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 5px 7px;
  border-right: 1px solid var(--border);
  background: var(--gray-cell);
  text-align: left;
}
#crossEditModal .reference-edit-grid input,
#crossEditModal .reference-edit-grid select,
#editModal .reference-edit-grid input,
#editModal .reference-edit-grid select {
  width: 200px;
  max-width: calc(100% - 12px);
  height: 28px;
  margin: 4px 6px;
  flex: none;
  border: 1px solid #aeb8bd;
  background: #fff;
}
#crossEditModal .reference-edit-grid .input-with-button,
#editModal .reference-edit-grid .input-with-button {
  display: flex;
  align-items: center;
  min-width: 0;
}
#crossEditModal .reference-edit-grid .input-with-button input,
#editModal .reference-edit-grid .input-with-button input { width: 200px; }

#crossEditModal .subordinate-share-block,
#editModal .subordinate-share-block {
  margin: 0;
  padding: 7px 8px;
  border: 1px solid var(--border);
  border-top: 0;
  background: #fff;
  color: #111;
}
#crossEditModal .subordinate-share-grid,
#editModal .subordinate-share-grid { margin: 0 0 3px; }
#crossEditModal .subordinate-share-block p,
#editModal .subordinate-share-block p { margin: 3px 0 0 195px; }
#crossEditModal .edit-settings-scroll,
#editModal .edit-settings-scroll {
  max-height: none !important;
  border-top: 0;
}
#crossEditModal .subordinate-readonly-settings-table th,
#editModal .subordinate-readonly-settings-table th { font-size: 14px; }
#crossEditModal .subordinate-readonly-settings-table td,
#editModal .subordinate-readonly-settings-table td { text-align: left; }
#crossEditModal .dialog-actions,
#editModal .dialog-actions {
  justify-content: center;
  border-top: 0;
  background: #fff;
  padding: 12px 0 22px;
}

/* 2026-08-26 编辑页排版修正：按 编辑1/编辑2 参考图的比例和顺序排列。 */
#crossEditModal .edit-info-box .account-reference-title,
#editModal .edit-info-box .account-reference-title {
  height: 30px;
  min-height: 30px;
  padding: 0 6px;
  font-size: 14px;
}
#crossEditModal .edit-info-box .account-reference-content,
#editModal .edit-info-box .account-reference-content {
  min-height: 31px;
  padding: 4px 48px;
  font-size: 13px;
}
#crossEditModal .edit-info-box,
#editModal .edit-info-box { margin-bottom: 10px; }
#crossEditModal .section-title:not(.title-row),
#editModal .section-title:not(.title-row) {
  min-height: 30px !important;
  height: 30px;
  padding: 4px 5px !important;
  font-size: 14px !important;
}
#crossEditModal .reference-edit-grid,
#editModal .reference-edit-grid {
  grid-template-columns: 55% 45%;
}
#crossEditModal .reference-edit-grid > label,
#editModal .reference-edit-grid > label {
  min-height: 30px;
  height: 30px;
  grid-template-columns: 166px minmax(0, 1fr);
  font-size: 13px;
}
#crossEditModal .reference-edit-grid > label > span:first-child,
#editModal .reference-edit-grid > label > span:first-child {
  min-height: 29px;
  height: 29px;
  padding: 3px 5px;
}
#crossEditModal .reference-edit-grid input,
#crossEditModal .reference-edit-grid select,
#editModal .reference-edit-grid input,
#editModal .reference-edit-grid select {
  width: 168px;
  height: 22px;
  margin: 3px 6px;
  padding: 1px 5px;
  font-size: 13px;
}
#crossEditModal .reference-edit-grid .input-with-button input,
#editModal .reference-edit-grid .input-with-button input { width: 168px; }
#crossEditModal .reference-edit-grid .input-with-button .small,
#editModal .reference-edit-grid .input-with-button .small {
  min-height: 22px;
  height: 22px;
  padding: 1px 10px;
  font-size: 12px;
}

/* “拦货占成上限”是资料表中的整行，不再单独撑成一块。 */
#crossEditModal .subordinate-share-block,
#editModal .subordinate-share-block {
  display: grid;
  grid-template-columns: 166px minmax(0, 1fr);
  margin: 0;
  padding: 0;
  min-height: 42px;
  font-size: 13px;
}
#crossEditModal .subordinate-share-block > div:first-child,
#editModal .subordinate-share-block > div:first-child {
  grid-column: 1;
  grid-row: 1 / span 2;
  display: flex;
  align-items: center;
  padding: 4px 5px;
  border-right: 1px solid var(--border);
  background: var(--gray-cell);
  font-size: 13px;
}
#crossEditModal .subordinate-share-grid,
#editModal .subordinate-share-grid {
  grid-column: 2;
  margin: 0;
  padding: 3px 8px 0;
}
#crossEditModal .subordinate-share-grid .subordinate-share-row,
#editModal .subordinate-share-grid .subordinate-share-row {
  min-height: 22px;
  gap: 4px 10px;
}
#crossEditModal .subordinate-share-grid .share-parent-reading,
#crossEditModal .subordinate-share-grid .share-child-reading,
#editModal .subordinate-share-grid .share-parent-reading,
#editModal .subordinate-share-grid .share-child-reading { gap: 3px; }
#crossEditModal .subordinate-share-grid .share-parent-reading select,
#crossEditModal .subordinate-share-grid .share-child-reading select,
#crossEditModal .subordinate-share-grid .share-child-reading input,
#editModal .subordinate-share-grid .share-parent-reading select,
#editModal .subordinate-share-grid .share-child-reading select,
#editModal .subordinate-share-grid .share-child-reading input {
  width: 46px;
  height: 22px;
  padding: 1px 4px;
}
#crossEditModal .subordinate-share-grid small,
#editModal .subordinate-share-grid small { font-size: 12px; }
#crossEditModal .subordinate-share-block p,
#editModal .subordinate-share-block p {
  grid-column: 2;
  margin: 0 !important;
  padding: 0 8px 4px;
  line-height: 1.35;
  font-size: 12px;
}

/* 参考图中占成行后直接是“剩余额度”一行；隐藏赚水放在同一行右侧。 */
#crossEditModal .reference-edit-grid-tail,
#editModal .reference-edit-grid-tail { border-top: 0; }

/* 编辑1/编辑2没有额外的“玩法设置”横条，直接接玩法表头。 */
#crossEditModal .section-title.title-row,
#editModal .section-title.title-row { display: none !important; }
#crossEditModal .edit-settings-scroll,
#editModal .edit-settings-scroll { border-top: 1px solid var(--border); }
#crossEditModal .subordinate-readonly-settings-table th,
#editModal .subordinate-readonly-settings-table th {
  padding-top: 5px;
  padding-bottom: 5px;
  font-size: 13px;
}
#crossEditModal .subordinate-readonly-settings-table td,
#editModal .subordinate-readonly-settings-table td {
  padding-top: 4px;
  padding-bottom: 4px;
  font-size: 13px;
}

/* 2026-08-26：管理端截图排版微调。 */
/* 1) 期号与封盘倒计时固定到顶部右侧，避免挤压左侧账号与线路区域。 */
.management-header-top .identity-box { order: 1; }
.management-header-top .header-message {
  order: 2;
  flex: 1 1 auto;
  min-width: 0;
}
.management-header-top .header-market-box {
  order: 3;
  margin-left: auto;
  margin-right: 10px;
}

/* 2) 顶部身份区强制横排：总监  admin1  更换线路。 */
.management-header .identity-box {
  flex: 0 0 auto !important;
  width: auto !important;
  min-width: max-content;
  justify-content: flex-start !important;
  white-space: nowrap !important;
  padding-left: 10px !important;
  padding-right: 10px !important;
}
.management-header .identity-box span,
.management-header .identity-box strong,
.management-header .identity-box a {
  display: inline-block !important;
  white-space: nowrap !important;
  writing-mode: horizontal-tb !important;
  word-break: keep-all !important;
}

/* 3) 下级管理 / 越级操作编辑页：“水位（同□）”复选框收紧。 */
#crossEditModal .subordinate-readonly-settings-table .header-sync,
#editModal .subordinate-readonly-settings-table .header-sync {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-left: 4px;
  white-space: nowrap;
}
#crossEditModal .subordinate-readonly-settings-table .header-sync input[type="checkbox"],
#editModal .subordinate-readonly-settings-table .header-sync input[type="checkbox"] {
  width: 14px !important;
  min-width: 14px !important;
  max-width: 14px !important;
  height: 14px !important;
  min-height: 14px !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* 4) 分类账：月份快捷项和右侧期号选择放到同一条白底栏。 */
#categoryPanel .category-ledger-toolbar {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  align-items: center;
  gap: 0 !important;
  min-height: 38px !important;
  padding: 0 !important;
  border: 0 !important;
  border-bottom: 2px solid #159b91 !important;
  background: #fff !important;
  color: #222 !important;
}
#categoryPanel .category-ledger-left {
  grid-column: 1 !important;
  width: 100%;
  min-height: 36px;
  padding: 5px 8px 4px;
  gap: 7px;
  border-bottom: 0 !important;
  background: #fff !important;
  color: #222;
}
#categoryPanel .category-ledger-left > strong {
  color: #222;
  font-size: 14px;
}
#categoryPanel .category-month-actions { margin-left: 6px; }
#categoryPanel .category-month-actions button {
  padding: 0 2px;
  color: #0000ee;
  font-weight: 400;
}
#categoryPanel .category-month-actions button:hover { color: #0000ee; }
#categoryPanel .category-month-actions button.active { color: #ff0000; }
#categoryPanel .category-month-actions > span { color: #222; }
#categoryPanel .category-issue-range,
#categoryPanel .category-period-select {
  grid-column: 2 !important;
  min-height: 36px;
  margin-left: 0;
  padding: 4px 8px 4px 12px;
  justify-self: end;
  background: #fff !important;
  color: #222 !important;
}
#categoryPanel .category-issue-range b { color: #222 !important; }

/* 5) 总货明细：标题/日期摘要移到筛选栏上方，使用独立白底栏。 */
#totalGoodsPanel > .total-goods-heading {
  min-height: 36px !important;
  padding: 5px 9px !important;
  border: 0 !important;
  border-bottom: 2px solid #159b91 !important;
  background: #fff !important;
  color: #222 !important;
}
#totalGoodsPanel > .total-goods-heading > span,
#totalGoodsPanel > .total-goods-heading > span:last-child {
  color: #222 !important;
}
#totalGoodsPanel > .total-goods-heading + .search-strip {
  border-top: 0 !important;
}

/* 总监专用：设置-基本资料赔率模式 */
.director-odds-mode-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 38px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-bottom: 0;
  background: #f7f9fa;
  font-size: 13px;
}
.director-odds-mode-title { font-weight: 700; color: #222; }
.director-mode-option { display: inline-flex; align-items: center; gap: 5px; cursor: pointer; white-space: nowrap; }
.director-mode-option input { margin: 0; accent-color: var(--teal-dark); }
.director-odds-mode-hint { color: #68747a; font-size: 12px; }
.locked-water-input {
  width: 70px;
  height: 27px;
  border: 1px solid #c8d0d5;
  background: #eef1f3;
  color: #777;
  text-align: center;
}
.director-manual-odds-input {
  width: 150px;
  max-width: 100%;
  height: 27px;
  border: 1px solid #b9c3cb;
  background: #fff;
  padding: 2px 6px;
  text-align: center;
}
.own-water-table .input-invalid { border-color: #d2232a !important; background: #fff0f0 !important; }
@media (max-width: 760px) {
  .director-odds-mode-bar { flex-wrap: wrap; gap: 8px 12px; }
  .director-odds-mode-hint { width: 100%; }
}

/* 总监大盘 */
.market-dashboard-panel { min-width: 0; }
.market-dashboard-updated { font-size: 12px; font-weight: 400; color: #d8ffff; }
.market-dashboard-filter { align-items: center; }
.market-live-dot { display: inline-flex; align-items: center; gap: 6px; color: #607078; font-size: 12px; }
.market-live-dot i { width: 7px; height: 7px; border-radius: 50%; background: #2f9d62; box-shadow: 0 0 0 3px rgba(47,157,98,.12); }
.market-odds-control { margin: 10px 0; border: 1px solid #cfd8dc; background: #fbfcfc; }
.market-odds-control-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 10px; border-bottom: 1px solid #dfe5e8; background: #f2f6f7; }
.market-odds-control-head > div { display: flex; align-items: baseline; flex-wrap: wrap; gap: 9px; }
.market-odds-control-head b { color: #253239; }
.market-odds-control-head small { color: #68767c; }
.market-odds-approved-tools { padding: 9px 10px 10px; }
.market-odds-mode-row, .market-odds-input-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 12px; }
.market-odds-mode-row { padding-bottom: 8px; border-bottom: 1px dashed #d8dfe2; margin-bottom: 8px; }
.market-odds-mode-row label { display: inline-flex; align-items: center; gap: 5px; }
.market-odds-input-row label { display: inline-flex; align-items: center; gap: 5px; }
.market-odds-input-row input, .market-odds-input-row select { min-height: 29px; border: 1px solid #bfc9cd; background: #fff; padding: 4px 7px; }
#marketOddsNumber { width: 94px; text-transform: uppercase; }
#marketOddsManualValue { width: 104px; }
.market-odds-input-row > span { display: inline-flex; gap: 5px; align-items: center; padding: 4px 7px; background: #fff; border: 1px solid #e0e5e7; white-space: nowrap; }
.market-odds-input-row > span b { color: #b1272c; }
.market-odds-risk-hint { margin-top: 7px; color: #68757b; font-size: 12px; line-height: 1.55; }
.admin-odds-approval { margin-top: 14px; border-top: 1px solid #dfe5e8; padding-top: 8px; }
.admin-odds-approval .table-subline { display: block; margin-top: 2px; color: #7c878c; font-weight: 400; }
.market-kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin: 10px 0; }
.market-kpi-card { min-width: 0; border: 1px solid var(--border); background: #fff; padding: 10px 12px; }
.market-kpi-card > span { display: block; color: #68747a; font-size: 12px; }
.market-kpi-card > b { display: block; margin: 4px 0 2px; color: #1e2c32; font-size: 21px; line-height: 1.2; overflow: hidden; text-overflow: ellipsis; }
.market-kpi-card > small { color: #7a858a; font-size: 11px; }
.market-kpi-card.is-risk { border-color: #d9a1a3; background: #fff8f8; }
.market-dashboard-grid { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 10px; align-items: start; }
.market-card { min-width: 0; border: 1px solid var(--border); background: #fff; }
.market-card-title { min-height: 36px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 7px 9px; border-bottom: 1px solid var(--border); background: #f6f8f9; }
.market-card-title span { font-weight: 700; }
.market-card-title small { color: #748087; }
.market-exposure-table { min-width: 930px; }
.market-exposure-table td { vertical-align: middle; }
.market-row-label { display: block; margin-top: 2px; color: #7a858a; font-weight: 400; white-space: nowrap; }
.market-status { display: inline-block; min-width: 62px; padding: 2px 5px; border-radius: 2px; text-align: center; font-size: 11px; white-space: nowrap; }
.market-status.normal { background: #e9f5ef; color: #24754c; }
.market-status.caution { background: #fff4d7; color: #8b6300; }
.market-status.warning { background: #fff0df; color: #a35400; }
.market-status.danger { background: #fde8e8; color: #b2292d; font-weight: 700; }
.market-status.neutral { background: #eef1f3; color: #5f6b71; }
.market-risk-summary { padding: 10px; }
.market-risk-line { display: flex; justify-content: space-between; gap: 12px; padding: 8px 0; border-bottom: 1px solid #edf0f2; font-size: 12px; }
.market-risk-line:last-child { border-bottom: 0; }
.market-risk-line span { color: #667279; }
.market-risk-line b { color: #253239; text-align: right; }
.market-risk-meter { height: 7px; margin: 0 0 7px; background: #e8ecee; overflow: hidden; }
.market-risk-meter i { display: block; height: 100%; background: var(--teal-dark); }
.market-risk-text { color: #6d787e; font-size: 12px; line-height: 1.55; padding-top: 8px; }
.market-dashboard-note { margin-top: 10px; }
@media (max-width: 980px) {
  .market-kpi-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .market-dashboard-grid { grid-template-columns: 1fr; }
  .market-risk-card { order: -1; }
}
@media (max-width: 580px) {
  .market-kpi-grid { grid-template-columns: 1fr; }
  .market-odds-control-head { align-items: flex-start; }
  .market-odds-input-row > span { width: 100%; justify-content: space-between; }
}

/* 总货明细：日期/期号靠右，400行分页 */
#totalGoodsFilter .total-goods-period-spacer { flex: 1 1 24px; min-width: 24px; }
.total-goods-pagination { justify-content: flex-end; padding: 8px 10px; border: 1px solid var(--border); border-top: 0; background: #fff; }
@media (max-width: 900px) {
  #totalGoodsFilter .total-goods-period-spacer { flex-basis: 100%; height: 0; min-width: 100%; }
}

/* 2026-08-26 总货明细：按参考图回归传统单表布局，去掉复杂信息层级。 */
#totalGoodsPanel.total-goods-simple-panel {
  border: 0 !important;
  box-shadow: none !important;
  background: #fff;
}
#totalGoodsPanel .total-goods-topbar {
  height: 39px;
  margin-bottom: 7px;
  background: var(--teal);
  border: 1px solid var(--teal-dark);
}
#totalGoodsPanel > .total-goods-simple-filter {
  min-height: 42px !important;
  padding: 6px 6px !important;
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  gap: 8px 18px !important;
  border: 1px solid var(--border) !important;
  background: #fff !important;
  box-shadow: none !important;
  overflow-x: auto;
}
#totalGoodsPanel .total-goods-simple-filter label {
  gap: 7px !important;
  color: #111;
  font-size: 14px;
  font-weight: 400;
}
#totalGoodsPanel .total-goods-simple-filter input,
#totalGoodsPanel .total-goods-simple-filter select {
  height: 27px !important;
  min-width: 0 !important;
  border: 1px solid #9e9e9e !important;
  border-radius: 0 !important;
  background: #fff !important;
  padding: 2px 5px !important;
}
#totalGoodsPanel .total-goods-query-input { width: 119px !important; }
#totalGoodsPanel .total-goods-list-select { width: 58px !important; }
#totalGoodsPanel .total-goods-range-input { width: 81px !important; }
#totalGoodsPanel .total-current-label { gap: 6px !important; }
#totalGoodsPanel .total-current-label input[type="checkbox"] {
  width: 15px !important;
  height: 15px !important;
  margin: 0 !important;
}
#totalGoodsPanel .total-goods-filter-spacer { flex: 1 0 24px; }
#totalGoodsPanel .total-goods-download {
  color: #0000ee !important;
  font-weight: 400 !important;
  white-space: nowrap;
}
#totalGoodsPanel > .total-goods-heading {
  min-height: 39px !important;
  margin-top: 10px;
  padding: 5px 6px !important;
  border: 1px solid var(--teal-dark) !important;
  border-bottom: 0 !important;
  background: var(--teal) !important;
  color: #fff !important;
  font-size: 14px !important;
}
#totalGoodsPanel > .total-goods-heading > span:first-child {
  color: #fff !important;
  font-weight: 700 !important;
}
#totalGoodsPanel .total-goods-period-inline {
  display: inline-flex;
  align-items: center;
  gap: 18px;
  color: #fff !important;
  font-size: 14px !important;
  font-weight: 700 !important;
}
#totalGoodsPanel .total-goods-period-inline label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
#totalGoodsPanel .total-goods-period-inline input,
#totalGoodsPanel .total-goods-period-inline select {
  height: 28px;
  border: 1px solid #9e9e9e;
  border-radius: 0;
  background: #fff;
  color: #111;
  padding: 2px 5px;
}
#totalGoodsPanel .total-goods-period-inline input[type="date"] { width: 145px; }
#totalGoodsPanel .total-goods-period-inline select { width: 155px; }
#totalGoodsPanel .total-goods-table-wrap {
  border: 1px solid var(--border) !important;
  border-top: 0 !important;
  overflow: auto;
}
#totalGoodsPanel .total-goods-simple-table { min-width: 1540px; }
#totalGoodsPanel .total-goods-simple-table th,
#totalGoodsPanel .total-goods-simple-table td {
  height: 38px;
  padding: 5px 6px !important;
  border-right: 1px solid var(--border) !important;
  border-bottom: 1px solid var(--border) !important;
  text-align: left;
  font-size: 14px;
  white-space: nowrap;
}
#totalGoodsPanel .total-goods-simple-table thead th {
  height: 47px;
  background: #eeeeee !important;
  color: #111 !important;
  font-size: 16px !important;
  font-weight: 400 !important;
  text-align: left !important;
}
#totalGoodsPanel .total-goods-simple-table tbody td,
#totalGoodsPanel .total-goods-simple-table tbody tr:nth-child(odd) td {
  background: #fff !important;
}
#totalGoodsPanel .total-goods-simple-table tbody .empty-row {
  color: #111;
  text-align: left !important;
}
#totalGoodsPanel .total-goods-simple-table tfoot td {
  height: 39px;
  background: #ffff99 !important;
  color: #111;
  font-weight: 400;
  text-align: center;
}
#totalGoodsPanel .total-goods-simple-table tfoot .total-goods-total-label {
  color: red !important;
  font-weight: 700 !important;
}
#totalGoodsPanel .total-goods-simple-table th:nth-child(1) { min-width: 155px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(2) { min-width: 125px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(3) { min-width: 155px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(4) { min-width: 95px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(5) { min-width: 125px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(6) { min-width: 76px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(7) { min-width: 120px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(n+8):nth-child(-n+12) { min-width: 106px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(13) { min-width: 105px; }
#totalGoodsPanel .total-goods-simple-table th:nth-child(14) { min-width: 92px; }
#totalGoodsPanel > .total-goods-pagination {
  min-height: 44px;
  padding: 6px 0 !important;
  display: flex;
  align-items: center;
  justify-content: center !important;
  gap: 10px;
  border: 0 !important;
  background: #fff !important;
  color: #111;
  font-size: 14px;
}
#totalGoodsPanel .total-goods-pagination button {
  min-width: 0;
  height: auto;
  padding: 0;
  border: 0;
  background: transparent;
  color: #0000ee;
  font-size: 14px;
}
#totalGoodsPanel .total-goods-pagination button:disabled {
  color: #777;
  opacity: .55;
  cursor: default;
}
#totalGoodsPanel .total-goods-pagination .total-goods-page-input {
  width: 46px;
  height: 30px;
  border: 1px solid #b7b7b7;
  background: #fff;
  text-align: center;
}
#totalGoodsPanel .total-goods-pagination .total-goods-go-button {
  width: 39px;
  height: 30px;
  padding: 0 5px;
  border-radius: 6px;
  background: #353b47;
  color: #fff;
  font-weight: 700;
}

@media print {
  body * { visibility: hidden !important; }
  #totalGoodsPanel,
  #totalGoodsPanel * { visibility: visible !important; }
  #totalGoodsPanel { position: absolute; left: 0; top: 0; width: 100%; }
  #totalGoodsPanel .total-goods-topbar,
  #totalGoodsPanel .total-goods-simple-filter,
  #totalGoodsPanel .total-goods-pagination { display: none !important; }
  #totalGoodsPanel .total-goods-table-wrap { overflow: visible !important; }
  #totalGoodsPanel .total-goods-simple-table { min-width: 0 !important; width: 100% !important; }
}

/* 2026-08-27：主管理员“操作功能”与全局公告。 */
.management-announcement-box {
  display: flex;
  align-items: center;
  min-height: 28px;
  border-radius: 3px;
  background: rgba(0,0,0,.12);
  padding: 0 10px;
  color: #fff4a6 !important;
}
.management-announcement-box marquee {
  width: 100%;
  color: #fff4a6;
  font-weight: 700;
  line-height: 26px;
}
.admin-operations-panel { padding-bottom: 24px; }
.admin-operations-warning {
  margin: 10px 0 14px;
  padding: 10px 12px;
  border: 1px solid #d99c93;
  background: #fff3f1;
  color: #8a2018;
  font-weight: 700;
  line-height: 1.6;
}
.admin-operation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.admin-operation-card {
  border: 1px solid #b8c8c6;
  background: #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
  padding: 14px;
}
.admin-announcement-card { grid-column: 1 / -1; }
.admin-operation-card-title {
  margin: -14px -14px 12px;
  padding: 8px 12px;
  background: #e7f0ef;
  border-bottom: 1px solid #b8c8c6;
  color: #225b57;
  font-weight: 800;
}
.admin-operation-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 34px;
  border-bottom: 1px dotted #d7dfde;
}
.admin-operation-status-row b { color: #8d1e16; }
.admin-operation-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.admin-operation-field {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.admin-operation-field input,
.admin-announcement-card textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid #aebcba;
  background: #fff;
  padding: 7px 8px;
  font: inherit;
}
.admin-operation-field input[readonly] { background: #f3f5f5; font-weight: 700; }
.admin-operation-confirm {
  display: block;
  margin: 10px 0 12px;
  color: #7c2b25;
  font-weight: 700;
  line-height: 1.5;
}
.admin-operation-hint { margin-bottom: 8px; color: #52615f; }
#announcementCounter { margin-left: auto; color: #667; font-size: 12px; }
#manualDrawBtn:disabled { opacity: .55; cursor: not-allowed; }
@media (max-width: 980px) {
  .admin-operation-grid { grid-template-columns: 1fr; }
  .admin-announcement-card { grid-column: auto; }
}

/* 2026-08-28：总货明细会员层级与表头密度 */
#totalGoodsPanel .total-goods-simple-table thead th {
  font-size: 11px !important;
  line-height: 1.25;
  padding-top: 5px !important;
  padding-bottom: 5px !important;
}
.total-goods-member-link {
  appearance: none;
  border: 0;
  background: transparent;
  padding: 0;
  color: #1d5f8a;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.total-goods-member-link:hover { color: #8b3034; }
.total-goods-member-name { font-weight: 700; color: #2e4e4b; }

/* 2026-08-28：总货明细二级结构 + 单屏表格。文字稍微放大，并统一水平居中。 */
#totalGoodsPanel .total-goods-table-wrap {
  width: 100% !important;
  overflow-x: hidden !important;
  overflow-y: visible !important;
}
#totalGoodsPanel .total-goods-simple-table {
  width: 100% !important;
  min-width: 0 !important;
  table-layout: fixed !important;
  font-size: 12px !important;
}
#totalGoodsPanel .total-goods-simple-table th,
#totalGoodsPanel .total-goods-simple-table td {
  box-sizing: border-box;
  padding: 5px 2px !important;
  font-size: 12px !important;
  line-height: 1.25 !important;
  text-align: center !important;
  vertical-align: middle !important;
  white-space: nowrap !important;
}
#totalGoodsPanel .total-goods-simple-table thead th {
  font-size: 12px !important;
  font-weight: 600 !important;
  letter-spacing: 0;
  text-align: center !important;
}
#totalGoodsPanel .total-goods-simple-table tbody td,
#totalGoodsPanel .total-goods-simple-table tfoot td,
#totalGoodsPanel .total-goods-simple-table td.left,
#totalGoodsPanel .total-goods-simple-table td.total-goods-number {
  text-align: center !important;
  white-space: nowrap !important;
}
#totalGoodsPanel .total-goods-simple-table td:nth-child(1) code {
  font-size: 11px !important;
  letter-spacing: -0.1px;
}
#totalGoodsPanel .total-goods-simple-table td:nth-child(3) {
  font-size: 11px !important;
  letter-spacing: 0;
}
#totalGoodsPanel .total-goods-simple-table .total-goods-member-link,
#totalGoodsPanel .total-goods-simple-table .total-goods-member-name {
  font-size: 12px !important;
}
