:root { color-scheme: light; font-family: Inter, "PingFang SC", "Microsoft YaHei", sans-serif; color: #17212b; background: #f4f6f8; }
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: #f4f6f8; }
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 232px 1fr; }
.sidebar { background: #151d25; color: #fff; padding: 24px 16px; display: flex; flex-direction: column; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 8px 28px; }
.brand-mark { width: 34px; height: 34px; display: inline-grid; place-items: center; background: #25a56a; color: #fff; font-size: 13px; font-weight: 800; border-radius: 6px; }
.brand strong, .brand small, .sidebar-footer strong, .sidebar-footer small { display: block; }
.brand small, .sidebar-footer small { color: #93a1ad; margin-top: 4px; font-size: 11px; }
.mobile-nav-bar { display: none; }
nav { display: grid; gap: 4px; }
nav .nav-group-label { margin: 14px 12px 2px; color: #6f808c; font-size: 10px; font-weight: 800; letter-spacing: .08em; }
nav a { color: #b9c3cc; padding: 10px 12px; text-decoration: none; border-radius: 6px; font-size: 14px; }
nav a small { color: #7f909b; font-size: 10px; margin-left: 4px; }
nav a:hover, nav a.active { color: #fff; background: #24313c; }
.sidebar-footer { margin-top: auto; border-top: 1px solid #2a3640; padding: 18px 8px 0; display: flex; gap: 10px; align-items: center; }
.avatar { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: #dcefe6; color: #167a4a; font-weight: 700; }
.content { min-width: 0; padding: 38px 48px; max-width: 1380px; width: 100%; }
header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 26px; }
.eyebrow { color: #6b7782; font-size: 12px; margin: 0 0 7px; text-transform: uppercase; }
h1 { font-size: 28px; margin: 0; letter-spacing: 0; }
.mode { background: #e7f4ed; color: #18794e; padding: 7px 10px; border-radius: 6px; font-size: 12px; font-weight: 700; }
.status-band { display: flex; gap: 14px; align-items: flex-start; padding: 18px 20px; background: #fff8df; border-left: 4px solid #e4ab22; }
.status-band p { margin: 5px 0 0; color: #5e6872; font-size: 14px; }
.status-icon { width: 23px; height: 23px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: #e4ab22; color: #fff; font-weight: 700; }
.metric-grid { margin-top: 22px; display: grid; grid-template-columns: repeat(4, minmax(150px, 1fr)); gap: 1px; background: #dfe4e8; border: 1px solid #dfe4e8; }
.metric-grid article { background: #fff; padding: 20px; min-height: 124px; }
.metric-grid .primary-metric { border-top: 3px solid #188754; }
.risk-grid { margin-top: 18px; display: grid; grid-template-columns: repeat(4, minmax(150px, 1fr)); gap: 1px; background: #dfe4e8; border: 1px solid #dfe4e8; }
.risk-grid article { background: #fff; padding: 16px; min-height: 106px; }
.risk-grid span, .risk-grid small { display: block; color: #6b7782; font-size: 12px; }
.risk-grid strong { display: block; margin: 10px 0 6px; font-size: 18px; }
.metric-grid span, .metric-grid small { display: block; color: #6b7782; font-size: 13px; }
.metric-grid strong { display: block; margin: 13px 0 8px; font-size: 24px; }
.plain-section { margin-top: 22px; padding: 24px 0; border-top: 1px solid #d7dde2; }
.plain-section h2 { margin: 0 0 8px; font-size: 18px; }
.plain-section p { color: #6b7782; margin: 0; }
.plain-section p + p { margin-top: 8px; }
.provider-warning { margin-top: 18px; padding: 12px 16px; display: flex; justify-content: space-between; gap: 12px; background: #fff; border-left: 4px solid #b84a4a; color: #7a2525; font-size: 13px; }
.reconciliation-banner { margin-top: 18px; padding: 16px 18px; background: #fff; display: flex; justify-content: space-between; align-items: center; border-left: 4px solid #188754; }
.reconciliation-banner.needs-review { border-left-color: #d48a13; background: #fffaf0; }
.reconciliation-banner p { margin: 4px 0 0; color: #66727c; }
.reconciliation-banner a { color: #176b4b; font-weight: 700; text-decoration: none; }
.data-row { display: grid; grid-template-columns: minmax(260px, 1fr) auto; gap: 6px 18px; padding: 14px 0; border-bottom: 1px solid #e1e5e8; }
.data-row span { font-size: 12px; font-weight: 800; color: #9a5b00; }
.data-row small { grid-column: 1 / -1; color: #69757f; }
.section-note { margin-bottom: 12px !important; }
.build-footer { margin-top: 36px; padding-top: 16px; border-top: 1px solid #d9dfe3; color: #7b858e; font-size: 11px; }
.build-footer strong { color: #216e50; letter-spacing: 0; }.preview-badge { display: inline-flex; padding: 5px 8px; border: 1px solid #88b9a4; border-radius: 4px; background: #edf7f2; color: #176847; font-size: 10px; font-weight: 800; }
.login-body { display: grid; place-items: center; background: #eef2f4; padding: 24px; }
.login-shell { width: min(780px, 100%); display: grid; grid-template-columns: 1fr 1fr; background: #fff; box-shadow: 0 18px 55px rgba(28, 44, 56, .12); }
.login-brand { background: #151d25; color: #fff; padding: 54px 42px; }
.login-brand h1 { margin-top: 24px; font-size: 34px; }
.login-brand p:last-child { color: #aab6bf; line-height: 1.7; }
.login-form { padding: 54px 42px; display: grid; align-content: center; gap: 18px; }
.login-form label { display: grid; gap: 7px; color: #49545e; font-size: 13px; }
.login-form input { width: 100%; padding: 12px; border: 1px solid #cbd3da; border-radius: 5px; font: inherit; }
.login-form button { padding: 12px 16px; border: 0; border-radius: 5px; background: #188754; color: #fff; font-weight: 700; cursor: pointer; }
.form-error { min-height: 18px; margin: 0; color: #bd2c2c; font-size: 13px; }
.inbox-workbench { margin-top: 8px; }
.inbox-heading { display: flex; justify-content: space-between; gap: 24px; align-items: flex-start; padding: 4px 0 22px; }
.heading-status { display: flex; align-items: center; gap: 8px; }.data-freshness { border: 1px solid #b8dfc9; background: #eef9f2; color: #197149; padding: 8px 11px; border-radius: 6px; font-size: 11px; font-weight: 800; white-space: nowrap; }.data-freshness.is-stale { border-color: #e6c99b; background: #fff8e8; color: #96600d; }
.inbox-heading h2 { margin: 0; font-size: 28px; letter-spacing: 0; }
.inbox-subtitle { margin: 8px 0 0; color: #687580; font-size: 13px; }
.verified-chip { border: 1px solid #b8dfc9; background: #eef9f2; color: #197149; padding: 8px 11px; border-radius: 6px; font-size: 11px; font-weight: 800; white-space: nowrap; }
.inbox-summary { display: grid; grid-template-columns: repeat(4, minmax(130px, 1fr)); gap: 10px; margin-bottom: 16px; }
.summary-card { min-height: 92px; padding: 14px 16px; background: #fff; border: 1px solid #dbe2e7; border-top: 3px solid #9aa8b2; border-radius: 6px; }
.summary-card span, .summary-card small { display: block; color: #64727d; font-size: 12px; }
.summary-card strong { display: block; margin: 7px 0 2px; font-size: 27px; line-height: 1; }
.summary-card.pending { border-top-color: #188754; }.summary-card.pending strong { color: #147345; }
.summary-card.confirmed { border-top-color: #8ba99a; }.summary-card.confirmed strong { color: #4b6c5b; }
.summary-card.rejected { border-top-color: #c35c55; }.summary-card.rejected strong { color: #a43c37; }
.summary-card.attention { border-top-color: #d18a1c; }.summary-card.attention strong { color: #a26308; }
.inbox-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 11px 13px; background: #1b2731; color: #fff; border-radius: 6px 6px 0 0; }
.transaction-filter-form { display: flex; flex-wrap: wrap; align-items: end; gap: 10px; margin: 14px 0; padding: 12px; border: 1px solid var(--line, #d9e0e5); border-radius: 6px; background: #f7f9fa; }
.transaction-filter-form label { display: grid; gap: 4px; color: #596772; font-size: 12px; }
.transaction-filter-form input, .transaction-filter-form select { min-height: 34px; border: 1px solid #cbd5dc; border-radius: 4px; padding: 5px 8px; background: #fff; }
.muted-badge { color: #697780; font-size: 12px; }
.portfolio-lot-workbench { display: grid; gap: 16px; }
.strategy-lot-summary { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; padding: 12px; border-top: 1px solid var(--line, #d9e0e5); }
.strategy-lot-summary em { color: #9a5b22; font-style: normal; }
.toolbar-selection, .toolbar-actions, .select-all { display: flex; align-items: center; gap: 10px; }
.select-all { font-size: 13px; font-weight: 700; cursor: pointer; }.select-all input, .activity-main > input { width: 16px; height: 16px; accent-color: #1d9a63; }
.selected-count { color: #b8c5cd; font-size: 12px; }.toolbar-actions { flex-wrap: wrap; justify-content: flex-end; }
.button { border: 1px solid transparent; border-radius: 5px; padding: 8px 11px; font: inherit; font-size: 12px; font-weight: 800; cursor: pointer; transition: background .15s, border-color .15s; }
.button-primary { background: #28a56e; color: #fff; }.button-primary:hover { background: #1c8b5b; }
.button-secondary { background: transparent; border-color: #d17b72; color: #ffd4cf; }.button-secondary:hover { background: #512f32; }
.button-quiet { background: #2a3945; border-color: #44545f; color: #dce6eb; }.button-quiet:hover { background: #344855; }
.button-danger-quiet { color: #9b3c37; background: #fff; border-color: #e6b8b3; }.button-danger-quiet:hover { background: #fff1ef; }
.inbox-message { min-width: 90px; color: #c8d5dc; font-size: 12px; }.inbox-message[data-state="error"] { color: #ffb6ad; }
.inbox-summary-line { padding: 9px 13px; border: 1px solid #dbe2e7; border-top: 0; color: #64727d; background: #f8fafb; font-size: 12px; }
.activity-group { margin-top: 20px; }.group-heading { display: flex; align-items: baseline; justify-content: space-between; margin: 0 0 8px; }.group-heading h3 { margin: 0; font-size: 16px; }.group-heading span { color: #89959e; font-size: 10px; letter-spacing: .04em; }
.activity-card { padding: 15px 16px; background: #fff; border: 1px solid #dbe2e7; border-radius: 6px; margin-bottom: 8px; }.activity-card:hover { border-color: #a9c9b7; box-shadow: 0 2px 8px rgba(31, 54, 66, .06); }
.activity-main { display: grid; grid-template-columns: 20px minmax(0, 1fr) auto; gap: 12px; align-items: center; }.activity-title strong { display: block; font-size: 17px; letter-spacing: .01em; }.activity-title span { display: block; margin-top: 4px; color: #687580; font-size: 12px; }.status-badge { display: inline-flex; align-items: center; gap: 7px; border-radius: 12px; padding: 5px 9px; font-size: 12px; font-weight: 800; white-space: nowrap; }.status-badge small { font-size: 9px; font-weight: 600; opacity: .7; }.status-pending { background: #e7f6ee; color: #167449; }.status-attention { background: #fff0e2; color: #9b5c0a; }.activity-detail { display: flex; flex-wrap: wrap; gap: 7px 18px; margin: 13px 0 0 32px; color: #52616c; font-size: 12px; }.activity-detail span + span { position: relative; }.activity-detail span + span::before { content: ""; width: 3px; height: 3px; background: #aeb9c0; border-radius: 50%; position: absolute; left: -10px; top: 6px; }.activity-actions { display: flex; justify-content: flex-end; margin-top: 12px; }.activity-actions form { display: flex; gap: 7px; }.activity-card-attention { background: #fffaf4; border-color: #eedbc5; }.activity-placeholder { width: 16px; height: 16px; display: block; }.empty-state { display: flex; align-items: baseline; gap: 12px; padding: 22px 16px; background: #f8fafb; border: 1px dashed #cdd7dd; border-radius: 6px; color: #687580; }.empty-state strong { color: #33434e; font-size: 13px; }.empty-state span { font-size: 12px; }
.confirmed-section { margin-top: 20px; border-top: 1px solid #dbe2e7; }.confirmed-section summary { display: flex; align-items: center; gap: 10px; padding: 14px 2px; color: #33434e; cursor: pointer; list-style: none; }.confirmed-section summary::-webkit-details-marker { display: none; }.confirmed-section summary span { font-weight: 800; }.confirmed-section summary small { color: #8a969e; font-size: 10px; }.confirmed-section summary b { margin-left: auto; color: #587363; font-size: 11px; }.confirmed-list { border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }.confirmed-row { display: flex; justify-content: space-between; gap: 12px; padding: 11px 14px; border-bottom: 1px solid #edf0f2; font-size: 12px; }.confirmed-row:last-child { border-bottom: 0; }.confirmed-row span, .empty-inline { color: #71808a; }.empty-inline { padding: 14px; margin: 0; font-size: 12px; }.security-note { display: block; margin-top: 8px; color: #7b858e; }
.header-status { display: flex; align-items: center; gap: 8px; }.page-subtitle { display: block; margin-top: 5px; color: #71808a; font-size: 12px; }.compact-verified { border: 1px solid #c7dfd0; border-radius: 5px; padding: 6px 9px; color: #23724b; background: #f0f8f3; font-size: 11px; font-weight: 700; }.allocation-section, .portfolio-section { margin-top: 22px; }.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 16px; margin-bottom: 10px; }.section-heading h2 { margin: 0; font-size: 18px; }.section-heading span, .section-heading small { color: #75838d; font-size: 12px; }.allocation-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }.allocation-card { min-height: 130px; padding: 14px; border: 1px solid #dbe2e7; border-top: 3px solid #8da99a; border-radius: 6px; background: #fff; }.allocation-card strong, .allocation-card small, .allocation-card em { display: block; }.allocation-card strong { margin-top: 5px; font-size: 14px; }.allocation-card small { color: #7a8790; font-size: 11px; }.allocation-card b { display: block; margin: 8px 0; font-size: 25px; color: #1b7450; }.allocation-card em { color: #6d7b84; font-size: 11px; font-style: normal; }.allocation-code { color: #83919a; font-size: 10px; font-weight: 800; letter-spacing: .06em; }.allocation-swing { border-top-color: #8d9fc1; }.allocation-options { border-top-color: #c18a45; }.allocation-cash { border-top-color: #94a09d; }.portfolio-workbench, .positions-workbench { margin-top: 8px; }.page-lead { margin: 0 0 18px; color: #5f6e78; }.portfolio-asset-list { display: grid; gap: 8px; }.portfolio-asset { display: grid; grid-template-columns: minmax(180px, 1fr) auto auto; gap: 8px 16px; align-items: center; padding: 13px 15px; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }.portfolio-asset small { grid-column: 1 / -1; color: #71808a; }.bucket-badge { padding: 4px 8px; border-radius: 10px; background: #edf4ef; color: #337251; font-size: 11px; }.portfolio-note { padding: 14px 16px; border: 1px dashed #cdd7dd; border-radius: 6px; background: #f8fafb; color: #61717b; }.positions-list { display: grid; gap: 8px; }.position-card { display: grid; grid-template-columns: minmax(180px, 1.6fr) repeat(4, minmax(110px, 1fr)); gap: 14px; align-items: center; padding: 14px 16px; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }.position-card strong, .position-card span, .position-card b, .position-card small { display: block; }.position-card strong { font-size: 17px; }.position-card span, .position-card small { margin-top: 4px; color: #71808a; font-size: 11px; }.position-card b { font-size: 12px; color: #354c59; }
.account-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }.account-card { padding: 14px 16px; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }.account-card strong, .account-card span { display: block; }.account-card strong { font-size: 18px; }.account-card span { color: #71808a; font-size: 12px; margin-top: 3px; }.account-card p { margin: 10px 0 0; color: #4f606b; font-size: 12px; }.transaction-filters { display: flex; gap: 8px; margin-bottom: 10px; color: #71808a; font-size: 12px; }.transaction-filters span { padding: 7px 10px; border: 1px solid #dbe2e7; border-radius: 5px; background: #fff; }.transaction-list { display: grid; gap: 8px; }.transaction-row { display: grid; grid-template-columns: 1.4fr 1fr 1fr auto; gap: 14px; align-items: center; padding: 14px 16px; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }.transaction-row strong, .transaction-row span, .transaction-row b, .transaction-row small { display: block; }.transaction-row span, .transaction-row small { margin-top: 4px; color: #71808a; font-size: 11px; }.transaction-row select { padding: 7px; border: 1px solid #cbd5da; border-radius: 5px; }.transaction-row form { display: flex; gap: 6px; align-items: center; }
.transaction-facts { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-top: 10px; padding-top: 10px; border-top: 1px dashed #e0e6ea; }
.transaction-facts span { margin-top: 0; color: #6d7b84; font-size: 11px; word-break: break-all; }
.investment-overview { margin: 8px 0 24px; }
.overview-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.overview-metric { min-height: 138px; padding: 18px; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }
.overview-metric span, .overview-metric strong, .overview-metric small { display: block; }
.overview-metric span { color: #52636d; font-size: 12px; font-weight: 700; }
.overview-metric strong { margin: 18px 0 10px; color: #173e32; font-size: 25px; }
.overview-metric small { color: #71808a; line-height: 1.5; }
.overview-metric.primary-metric { border-top: 3px solid #257251; }
.account-details-secondary { margin: 18px 0; border-top: 1px solid #dbe2e7; border-bottom: 1px solid #dbe2e7; }
.account-details-secondary > summary { padding: 14px 2px; color: #41535e; cursor: pointer; font-weight: 700; }
.account-details-secondary > summary small { margin-left: 8px; color: #7a8790; font-weight: 400; }
.account-details-secondary .account-grid { padding: 0 0 14px; }
.account-meta { color: #8a969d !important; font-size: 10px !important; font-weight: 400; }
.positions-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; }
.positions-heading h2 { margin-bottom: 0; }
.positions-heading p { margin: 0; color: #587363; font-size: 12px; font-weight: 700; }
.spread-sort-toolbar { display: flex; align-items: end; gap: 10px; margin: 12px 0 14px; padding: 11px 12px; border: 1px solid #dbe2e7; border-radius: 6px; background: #f8fafb; }
.spread-sort-toolbar label { display: grid; gap: 4px; color: #687580; font-size: 11px; }
.spread-sort-toolbar select { min-width: 170px; padding: 7px 28px 7px 9px; border: 1px solid #cbd5da; border-radius: 5px; color: #253943; background: #fff; font: inherit; }
.spread-sort-toolbar label:nth-child(2) select { min-width: 96px; }
.bucket-summary { display: grid; grid-template-columns: minmax(150px, .8fr) 2fr auto; gap: 18px; align-items: center; padding: 16px; border: 1px solid #dbe2e7; border-left: 3px solid #c18a45; border-radius: 6px; background: #fff; }
.bucket-summary strong, .bucket-summary span { display: block; }.bucket-summary span { margin-top: 4px; color: #71808a; font-size: 11px; }.bucket-summary dl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 0; }.bucket-summary dl div { padding-left: 12px; border-left: 1px solid #e2e7ea; }.bucket-summary dt { color: #71808a; font-size: 11px; }.bucket-summary dd { margin: 5px 0 0; font-size: 15px; font-weight: 800; }.bucket-summary a { color: #176b4b; font-size: 12px; font-weight: 800; text-decoration: none; white-space: nowrap; }
.transaction-tabs { display: flex; gap: 4px; margin: 4px 0 16px; border-bottom: 1px solid #d6dde2; }.transaction-tabs a { padding: 10px 16px; color: #687580; text-decoration: none; font-size: 13px; font-weight: 800; border-bottom: 3px solid transparent; }.transaction-tabs a.active { color: #176b4b; border-bottom-color: #25a56a; }
.cash-flow-notice { display: flex; justify-content: space-between; gap: 16px; margin-bottom: 12px; padding: 12px 14px; border-left: 3px solid #749786; background: #eef4f1; }.cash-flow-notice span { color: #61717b; font-size: 12px; }.cash-flow-list { display: grid; gap: 8px; }.cash-flow-row { display: grid; grid-template-columns: 1.2fr .8fr 1fr; gap: 16px; align-items: center; padding: 14px 16px; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }.cash-flow-row strong, .cash-flow-row span, .cash-flow-row b, .cash-flow-row small { display: block; }.cash-flow-row span, .cash-flow-row small { margin-top: 4px; color: #71808a; font-size: 11px; }.cash-flow-row b { color: #24483d; font-size: 17px; }
.performance-workbench { margin-top: 8px; }.performance-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }.performance-grid article, .performance-breakdown article { padding: 18px; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }.performance-grid article.current { border-top: 3px solid #257251; }.performance-grid span, .performance-grid strong, .performance-grid small, .performance-breakdown span, .performance-breakdown b, .performance-breakdown small { display: block; }.performance-grid span, .performance-breakdown span { color: #52636d; font-size: 12px; font-weight: 700; }.performance-grid strong { margin: 14px 0 9px; font-size: 25px; }.performance-grid small, .performance-breakdown small { color: #71808a; line-height: 1.5; }.performance-breakdown { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 10px; }.performance-breakdown b { margin: 10px 0 7px; font-size: 19px; }.performance-note { margin: 16px 0 0; padding: 12px 14px; color: #687580; font-size: 12px; border: 1px dashed #cdd7dd; background: #f8fafb; }
.allocation-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }.allocation-ident { min-width: 0; }.allocation-ident strong { margin-top: 3px; font-size: 14px; }.allocation-hero { flex: 0 0 auto; display: grid; gap: 7px; margin-left: auto; text-align: right; }.hero-label { display: block; color: #7b878f; font-size: 10px; letter-spacing: .02em; }.allocation-card .hero-value { display: block; margin: 1px 0 0; font-size: 24px; line-height: 1.08; font-weight: 800; color: #1b7450; font-variant-numeric: tabular-nums; white-space: nowrap; }.allocation-card .hero-ratio { color: #263b45; }.hero-target { display: block; margin-top: 1px; color: #71808a; font-size: 10px; white-space: nowrap; }.deployment-metrics { display: grid; grid-template-columns: 1fr 1fr; gap: 9px 12px; margin: 0; padding-top: 10px; border-top: 1px solid #e4e9ec; }.deployment-metrics dt { color: #7b878f; font-size: 10px; }.deployment-metrics dd { margin: 3px 0 0; color: #314751; font-size: 12px; font-weight: 800; }.decision-status { display: inline-block !important; margin-top: 12px; padding: 4px 7px; border-radius: 4px; font-size: 11px; font-weight: 800; }.status-unknown { color: #65727a; background: #edf0f2; }
.capacity-gauge { position: relative; height: 10px; margin: 9px 0 13px; overflow: visible; border: 1px solid #ccd5da; border-radius: 2px; background: #e9edef; }.capacity-fill { width: var(--fill); max-width: 100%; height: 100%; background: #2d9a68; }.target-marker { position: absolute; top: -4px; right: -1px; width: 2px; height: 16px; background: #344b55; }.gauge-near .capacity-fill, .gauge-over .capacity-fill { background: #d18a2b; }.gauge-unknown .capacity-fill { width: 0; }.over-segment { position: absolute; top: -21px; right: 0; color: #a76618; font-size: 10px; font-weight: 800; }.confirmation-link { display: block; margin-top: 8px; color: #176b4b; font-size: 10px; font-weight: 800; text-decoration: none; }
.capacity-gauge .capacity-fill { position: absolute; left: 0; width: var(--normal); max-width: none; }
.capacity-gauge .capacity-overfill { position: absolute; left: var(--marker); width: var(--over); height: 100%; background: #b63d3d; }
.capacity-gauge .target-marker { right: auto; left: var(--marker); }
.capacity-gauge .over-segment { right: 0; color: #a33838; }
.capacity-usage { color: #324a54; font-size: 12px; font-weight: 800; }
.capital-quality { display: block; margin-top: 10px; color: #71808a; font-size: 10px; }
.spread-terminal-header, .spread-terminal-row { display: grid; grid-template-columns: minmax(150px,1.25fr) minmax(115px,1fr) minmax(125px,1fr) minmax(110px,.9fr) minmax(110px,.9fr) minmax(105px,.85fr) minmax(90px,.7fr); gap: 10px; align-items: center; }.spread-terminal-header { position: sticky; top: 0; z-index: 2; padding: 9px 12px; border: 1px solid #d6dee3; background: #eef2f4; color: #65737c; font-size: 10px; font-weight: 800; }.spread-terminal-header a { color: inherit; text-decoration: none; }.spread-terminal-list { border: 1px solid #d6dee3; border-top: 0; }.spread-terminal-row { padding: 10px 12px; border-bottom: 1px solid #e4e9ec; background: #fff; }.spread-terminal-row:last-child { border-bottom: 0; }.spread-terminal-row b, .spread-terminal-row strong, .spread-terminal-row small { display: block; }.spread-terminal-row b { color: #2e424c; font-size: 12px; }.spread-terminal-row small { margin-top: 3px; color: #7a878f; font-size: 10px; }.spread-identity strong { color: #172f3a; font-size: 19px; line-height: 1; }.spread-identity b { margin-top: 4px; font-size: 13px; }.pnl-cell strong { font-size: 17px; }.profit strong, .profit b { color: #18754c; }.loss strong, .loss b { color: #b13b3b; }.neutral strong { color: #33464f; }.spread-terminal-row details { grid-column: 1 / -1; padding-top: 4px; }.spread-terminal-row summary { color: #66757e; font-size: 10px; cursor: pointer; }.spread-detail-meta { margin-top: 7px; padding: 8px 10px; background: #f7f9fa; }.spread-detail-meta p { margin: 4px 0; color: #596a74; font-size: 10px; }
.performance-livebar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 12px 0; padding: 10px 12px; border-left: 3px solid #6d9180; background: #f0f4f2; }.performance-livebar b, .performance-livebar span { display: block; }.performance-livebar b { font-size: 12px; }.performance-livebar span { margin-top: 3px; color: #71808a; font-size: 10px; }.performance-ledger-grid { display: grid; grid-template-columns: minmax(0,1.15fr) minmax(0,.85fr); gap: 12px; }.closed-trades-panel, .open-positions-panel { padding: 16px; border: 1px solid #dbe2e7; background: #fff; }.performance-filter-form { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 8px; }.performance-filter-form label { color: #687580; font-size: 10px; }.performance-filter-form input, .performance-filter-form select { width: 100%; margin-top: 4px; padding: 7px; border: 1px solid #cbd5da; border-radius: 4px; background: #fff; }.performance-filter-form .button { align-self: end; }.review-contract-banner { margin: 12px 0; padding: 10px; border-left: 3px solid #c58a38; background: #fff7e9; }.review-contract-banner b, .review-contract-banner span { display: block; }.review-contract-banner b { color: #8a5b19; font-size: 10px; }.review-contract-banner span { margin-top: 3px; color: #75664e; font-size: 10px; }.closed-trade-contract { padding: 14px; border: 1px dashed #cbd4da; background: #f8fafb; }.closed-trade-contract strong { font-size: 15px; }.closed-trade-contract p { margin: 7px 0; color: #63717a; font-size: 11px; }.closed-trade-contract small { display: block; margin-top: 8px; color: #7b878e; }.open-positions-panel h3 { margin: 14px 0 7px; color: #5c6b74; font-size: 11px; text-transform: uppercase; }.open-performance-row { display: grid; grid-template-columns: 1.3fr .8fr .8fr; gap: 8px; padding: 10px 0; border-top: 1px solid #e3e8eb; }.open-performance-row strong, .open-performance-row b, .open-performance-row small { display: block; }.open-performance-row small { margin-top: 3px; color: #7b878f; font-size: 10px; }.cash-flow-direction strong { color: #344b55; font-size: 15px; }.cash-flow-amount b { font-size: 20px; }
.closed-trade-header, .closed-trade-row { display: grid; grid-template-columns: 1.25fr 1fr .55fr 1fr .55fr .9fr .6fr; gap: 8px; align-items: center; }.closed-trade-header { padding: 8px; background: #eef2f4; color: #687780; font-size: 9px; font-weight: 800; }.closed-trade-row { padding: 9px 8px; border-bottom: 1px solid #e3e8eb; }.closed-trade-row strong, .closed-trade-row b, .closed-trade-row small { display: block; }.closed-trade-row small { color: #7b878f; font-size: 9px; }.closed-trades-pending { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px; border-left: 3px solid #c58a38; background: #fff8ed; }.closed-trades-pending strong, .closed-trades-pending span { display: block; }.closed-trades-pending span { margin-top: 4px; color: #74664f; font-size: 10px; }.performance-filter-details { margin-top: 10px; border-top: 1px solid #e2e7ea; }.performance-filter-details summary { padding: 10px 0; color: #596a74; font-size: 11px; cursor: pointer; }.performance-filter-form.compact { grid-template-columns: repeat(3,minmax(0,1fr)); padding: 10px; background: #f7f9fa; }.ai-review-note { margin-top: 10px; padding: 10px; border: 1px dashed #cbd5da; }.ai-review-note b, .ai-review-note span { display: block; }.ai-review-note span { margin-top: 3px; color: #74818a; font-size: 10px; }.history-result-title { color: #325f4d; font-size: 12px; font-weight: 800; }
.confirmation-center { display: grid; gap: 14px; }.confirmation-summary { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }.confirmation-summary article { padding: 14px 16px; border: 1px solid #dbe2e7; background: #fff; }.confirmation-summary span, .confirmation-summary strong { display: block; }.confirmation-summary span { color: #687780; font-size: 11px; }.confirmation-summary strong { margin-top: 7px; font-size: 24px; }.confirmation-panel { padding: 16px; border: 1px solid #dbe2e7; background: #fff; }.confirmation-list, .historical-scope-list { display: grid; gap: 6px; margin-bottom: 12px; }.confirmation-row { display: grid; grid-template-columns: 24px minmax(160px,1fr) 90px 150px 80px; gap: 10px; align-items: center; padding: 10px; border-bottom: 1px solid #e3e8eb; }.confirmation-row strong, .confirmation-row span, .confirmation-row small, .confirmation-row b { display: block; }.confirmation-row span, .confirmation-row small { color: #76838b; font-size: 10px; }.confirmation-row select { padding: 7px; border: 1px solid #cbd5da; background: #fff; }.confirmation-state { padding: 4px 6px; text-align: center; background: #eef1f2; }.confirmation-state.confirmed { color: #18754c; background: #edf6f1; }.unlock-path { margin-bottom: 10px; padding: 11px; border-left: 3px solid #708f80; background: #f1f5f3; }.unlock-path b, .unlock-path span { display: block; }.unlock-path span { margin-top: 4px; color: #65747c; font-size: 10px; }.select-all-row { display: block; margin-bottom: 8px; color: #53656f; font-size: 11px; }.historical-scope-row { display: grid; grid-template-columns: 24px 90px 1fr auto; gap: 10px; align-items: center; padding: 8px 10px; border-bottom: 1px solid #e5eaed; font-size: 11px; }.historical-scope-row.absolute-deny { color: #78858d; background: #f2f4f5; }.ownership-equation { display: grid; grid-template-columns: repeat(3,auto 1fr); gap: 8px; align-items: baseline; padding: 14px; background: #f7f9fa; }.ownership-equation strong { font-size: 20px; }.ownership-equation span { color: #71808a; font-size: 10px; }.ownership-confirm-form .button { margin-top: 10px; }.confirmation-safety { padding: 14px; border-left: 3px solid #555f66; background: #edf0f2; }.confirmation-safety strong, .confirmation-safety span { display: block; }.confirmation-safety span { margin-top: 5px; color: #68757d; font-size: 10px; }.positions-list .position-card { grid-template-columns: minmax(140px,1.2fr) repeat(6,minmax(80px,1fr)); }
.historical-scope-row > small { grid-column: 3 / -1; color: #74818a; font-size: 9px; }.realized-progress { display: grid; grid-template-columns: minmax(220px,1fr) 2fr; gap: 16px; padding: 14px 16px; border-left: 3px solid #c58a38; background: #fff8ed; }.realized-progress strong, .realized-progress span { display: block; }.realized-progress span { margin-top: 4px; color: #74664f; font-size: 10px; }.realized-progress dl { display: grid; grid-template-columns: repeat(5,1fr); gap: 8px; margin: 0; }.realized-progress dl div { padding-left: 9px; border-left: 1px solid #e2cfad; }.realized-progress dt { color: #76684f; font-size: 9px; }.realized-progress dd { margin: 5px 0 0; font-size: 16px; font-weight: 800; }.settings-workbench { display: grid; gap: 14px; }.settings-form, .token-create-form { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; padding: 18px; border: 1px solid #dbe2e7; background: #fff; }.settings-form label, .token-create-form > label { display: grid; gap: 5px; color: #62717a; font-size: 10px; font-weight: 700; }.settings-form input, .settings-form select, .settings-form textarea, .token-create-form input { width: 100%; padding: 9px; border: 1px solid #cbd5da; border-radius: 4px; background: #fff; font: inherit; }.settings-form .wide { grid-column: 1 / -1; }.settings-warning { padding: 10px; background: #f1f4f5; color: #66747c; font-size: 10px; }.capital-current { padding: 18px; border-top: 3px solid #2a8b62; background: #fff; }.capital-current span, .capital-current strong, .capital-current small { display: block; }.capital-current strong { margin: 6px 0; font-size: 28px; }.capital-current small { color: #71808a; }.token-create-form fieldset { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; margin: 0; padding: 12px; border: 1px solid #dbe2e7; }.token-create-form fieldset label { font-size: 10px; }.one-time-token { padding: 14px; border-left: 3px solid #d18a2b; background: #fff8ed; }.one-time-token strong, .one-time-token code, .one-time-token span { display: block; }.one-time-token code { margin: 8px 0; overflow-wrap: anywhere; font-size: 13px; }.one-time-token span { color: #74664f; font-size: 10px; }.token-table { border: 1px solid #dbe2e7; background: #fff; }.token-row { display: grid; grid-template-columns: 1fr 1fr 2fr 1.2fr .7fr auto; gap: 10px; align-items: center; padding: 10px 12px; border-bottom: 1px solid #e3e8eb; font-size: 10px; }.token-row code, .token-row span { overflow-wrap: anywhere; }.token-head { background: #eef2f4; color: #65747c; font-weight: 800; }
.spread-terminal-header, .spread-terminal-row { grid-template-columns: minmax(0,1.3fr) repeat(2,minmax(0,1fr)) repeat(3,minmax(0,.9fr)) minmax(0,.7fr); }
.token-actions { display: flex; gap: 4px; flex-wrap: wrap; }.token-actions form { margin: 0; }.token-actions .button { padding: 5px 7px; font-size: 9px; }
@media (min-width: 1024px) { .spread-sort-toolbar { display: none; }.allocation-card { min-height: 245px; } }
@media (max-width: 820px) {
  .app-shell { width: 100%; min-width: 0; grid-template-columns: minmax(0, 1fr); }
  .sidebar { min-width: 0; position: relative; z-index: 20; padding: 12px 16px; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; }
  .brand { padding: 0; }
  .brand small { display: none; }
  .mobile-nav-bar { display: flex; align-items: center; gap: 12px; }
  .mobile-current-page { color: #d9e2e8; font-size: 13px; font-weight: 700; white-space: nowrap; }
  .mobile-nav-toggle { width: 44px; height: 44px; display: grid; place-content: center; gap: 4px; border: 1px solid #40505c; border-radius: 6px; background: #202c35; cursor: pointer; }
  .mobile-nav-toggle span { width: 18px; height: 2px; display: block; background: #fff; }
  nav { position: absolute; top: 68px; left: 12px; right: 12px; display: none; grid-template-columns: 1fr 1fr; gap: 6px; padding: 12px; background: #17212a; border: 1px solid #34434e; border-radius: 6px; box-shadow: 0 14px 30px rgba(0, 0, 0, .24); }
  .sidebar.nav-open nav { display: grid; }
  nav .nav-group-label { grid-column: 1 / -1; margin: 8px 8px 0; }
  nav a { min-height: 44px; display: flex; align-items: center; padding: 10px 12px; font-size: 14px; }
  nav a.active { box-shadow: inset 3px 0 #25a56a; }
  .sidebar-footer { display: none; }
  .content { min-width: 0; padding: 22px 16px; }
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .overview-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .risk-grid { grid-template-columns: repeat(2, 1fr); }
  .inbox-summary { grid-template-columns: repeat(2, 1fr); }.inbox-heading, .inbox-toolbar { align-items: flex-start; flex-direction: column; }.toolbar-actions { justify-content: flex-start; }.activity-main { grid-template-columns: 20px minmax(0, 1fr); }.status-badge { grid-column: 2; justify-self: start; }.activity-detail { margin-left: 0; }.activity-actions { justify-content: flex-start; }
  .allocation-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }.section-heading { align-items: flex-start; flex-direction: column; }.portfolio-asset, .position-card { grid-template-columns: 1fr 1fr; }.position-card > div:first-child { grid-column: 1 / -1; }
  .overview-metric { min-height: 112px; padding: 14px; }
  .overview-metric strong { margin: 12px 0 7px; font-size: 21px; }
  .overview-metric:not(.primary-metric) small { color: #87929a; }
  .allocation-card { min-height: 108px; padding: 12px; }
  .allocation-card b { margin: 6px 0; font-size: 22px; }
  .portfolio-section { margin-top: 16px; }
  .portfolio-asset { padding: 11px 12px; }
  .position-card { gap: 10px 12px; padding: 12px; }
  .transaction-filter-form { display: grid; grid-template-columns: 1fr 1fr; align-items: end; }
  .transaction-filter-form label, .transaction-filter-form input, .transaction-filter-form select { width: 100%; min-width: 0; }
  .transaction-row { grid-template-columns: 1fr; gap: 10px; padding: 12px; }
  .transaction-row form { flex-wrap: wrap; }
  .activity-card { padding: 12px; }
  .activity-actions .button { min-height: 40px; }
  .bucket-summary { grid-template-columns: 1fr; gap: 12px; }
  .bucket-summary dl { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .bucket-summary dl div { padding-left: 8px; }
  .cash-flow-notice { align-items: flex-start; flex-direction: column; }
  .cash-flow-row { grid-template-columns: 1fr 1fr; padding: 12px; }.cash-flow-row > div:last-child { grid-column: 1 / -1; }
  .performance-grid { grid-template-columns: 1fr; }.performance-breakdown { grid-template-columns: 1fr 1fr; }
  .spread-terminal-header { display: none; }.spread-terminal-list { border: 0; display: grid; gap: 8px; }.spread-terminal-row { grid-template-columns: 1fr 1fr; gap: 10px 12px; padding: 12px; border: 1px solid #dbe2e7; border-radius: 6px; }.spread-identity { grid-column: 1 / -1; }.pnl-cell strong { font-size: 18px; }.performance-ledger-grid { grid-template-columns: 1fr; }.performance-filter-form { grid-template-columns: 1fr 1fr; }.performance-livebar { align-items: flex-start; }.deployment-metrics { grid-template-columns: 1fr; }.allocation-card { min-height: 218px; }
  .closed-trade-header { display: none; }.closed-trade-row { grid-template-columns: 1fr 1fr; }.closed-trades-pending { align-items: flex-start; flex-direction: column; }.performance-filter-form.compact { grid-template-columns: 1fr 1fr; }.confirmation-summary { grid-template-columns: repeat(3,minmax(0,1fr)); }.confirmation-panel { padding: 12px; }.confirmation-row { grid-template-columns: 24px 1fr auto; }.confirmation-row > div:first-of-type { min-width: 0; }.confirmation-row select { grid-column: 2; }.confirmation-state { grid-column: 3; grid-row: 1 / 3; }.historical-scope-row { grid-template-columns: 24px 70px 1fr; }.historical-scope-row b { grid-column: 2 / -1; }.ownership-equation { grid-template-columns: 1fr 1fr; }.positions-list .position-card { grid-template-columns: 1fr 1fr; }
  .realized-progress { grid-template-columns: 1fr; }.realized-progress dl { grid-template-columns: 1fr 1fr; }.settings-form, .token-create-form { grid-template-columns: 1fr; padding: 12px; }.settings-form .wide { grid-column: auto; }.token-create-form fieldset { grid-template-columns: 1fr; }.token-row, .token-head { grid-template-columns: 1fr 1fr; }.token-row > :nth-child(3), .token-row > :nth-child(4) { grid-column: 1 / -1; }.header-status { gap: 5px; }.preview-badge { font-size: 9px; }
  .account-grid { grid-template-columns: 1fr; }
  .positions-heading { align-items: flex-start; flex-direction: column; gap: 4px; }
  .spread-sort-toolbar { display: grid; grid-template-columns: minmax(0, 1fr) minmax(100px, .55fr); align-items: end; }
  .spread-sort-toolbar label, .spread-sort-toolbar select { width: 100%; min-width: 0; }
  .spread-sort-toolbar .button { grid-column: 1 / -1; }
  .login-shell { grid-template-columns: 1fr; }
  .login-brand, .login-form { padding: 34px 28px; }
}
@media (max-width: 440px) {
  .metric-grid, .risk-grid { grid-template-columns: 1fr; }
  .overview-grid, .allocation-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .overview-metric small { font-size: 10px; }
  .allocation-card strong { font-size: 13px; }
  .allocation-card em { font-size: 10px; }
  .bucket-summary dl { grid-template-columns: 1fr; }.bucket-summary dl div { padding: 7px 0; border-left: 0; border-top: 1px solid #e2e7ea; }
  .performance-breakdown { grid-template-columns: 1fr; }
}

/* ---------------------------------------------------------------- V-WB-P1
   股票「平仓 / 加仓」交易意图 UI。配色沿用 Portal 既有浅色主题。 */
.auto-trading-note { display: inline-flex; margin-left: 6px; padding: 3px 7px; border: 1px solid #d8c59a; border-radius: 4px; background: #fdf8ec; color: #8a6420; font-size: 11px; font-weight: 700; }
.positions-list .position-card .position-actions { display: flex; flex-direction: column; gap: 5px; }
.positions-list .position-card .position-actions .button { min-height: 30px; padding: 5px 9px; font-size: 11px; }
.positions-list .position-card .button[disabled] { opacity: .45; cursor: not-allowed; }
.positions-list .position-card .position-detail,
.positions-list .position-card .position-strategy-action { grid-column: 1 / -1; }
.position-detail { margin-top: 6px; padding-top: 8px; border-top: 1px dashed #dde4e8; }
.position-detail summary { color: #5d6d77; font-size: 11px; font-weight: 700; cursor: pointer; }
.position-trade-table { width: 100%; margin-top: 10px; border-collapse: collapse; font-size: 11px; }
.position-trade-table th, .position-trade-table td { padding: 7px 9px; border-bottom: 1px solid #e5eaed; text-align: left; }
.position-trade-table th { background: #f6f8f9; color: #65737c; font-size: 10px; font-weight: 800; }
.position-trade-modal { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 22px; background: rgba(18, 28, 36, .48); }
.position-trade-modal[hidden] { display: none; }
body.modal-open { overflow: hidden; }
.position-trade-form { width: min(560px, 100%); max-height: 90vh; overflow: auto; padding: 24px 26px; border-radius: 8px; background: #fff; box-shadow: 0 22px 60px rgba(18, 28, 36, .28); display: grid; gap: 14px; }
.position-trade-form h3 { margin: 0; font-size: 19px; }
.position-trade-form .pt-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 16px; margin: 0; padding: 14px; background: #f6f8f9; border-radius: 6px; }
.position-trade-form .pt-summary dt { color: #71808a; font-size: 10px; font-weight: 800; }
.position-trade-form .pt-summary dd { margin: 4px 0 0; color: #22323c; font-size: 13px; font-weight: 700; }
.position-trade-form label { display: grid; gap: 6px; color: #49545e; font-size: 12px; font-weight: 700; }
.position-trade-form input, .position-trade-form select { width: 100%; padding: 10px; border: 1px solid #cbd3da; border-radius: 5px; font: inherit; }
.position-trade-form .pt-note { margin: 0; color: #6b7782; font-size: 11px; line-height: 1.6; }
.position-trade-form .pt-note[data-state="error"] { color: #b13b3b; font-weight: 700; }
.position-trade-form .pt-buttons { display: flex; gap: 10px; justify-content: flex-end; }
@media (max-width: 900px) {
  .position-trade-form .pt-summary { grid-template-columns: 1fr; }
  .positions-list .position-card .position-actions { flex-direction: row; flex-wrap: wrap; }
}

/* ---------------------------------------------------------------- V-WB-P2/P3/P4
   四仓资金总览 + 股票/期权生命周期。沿用 Portal 既有的浅色主题与边框色。
   盈亏配色遵循中国大陆习惯：**涨红跌绿**（数字本身始终带 +/- 号，不依赖颜色区分）。 */
.sleeve-overview .sleeve-figures { margin-top: 18px; display: grid; grid-template-columns: repeat(4, minmax(150px, 1fr)); gap: 1px; background: #dfe4e8; border: 1px solid #dfe4e8; }
.sleeve-figure { background: #fff; padding: 18px 20px; min-height: 112px; }
.sleeve-figure.primary-metric { border-top: 3px solid #188754; }
.sleeve-figure span, .sleeve-figure small { display: block; color: #6b7782; font-size: 12px; }
.sleeve-figure strong { display: block; margin: 12px 0 7px; font-size: 23px; }
.sleeve-overview .sleeve-grid { margin-top: 18px; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.sleeve-card { display: grid; gap: 4px; padding: 18px; border: 1px solid #dbe1e6; border-top: 4px solid #98a4ae; border-radius: 6px; background: #fff; color: inherit; text-decoration: none; transition: box-shadow .15s ease, transform .15s ease; }
.sleeve-card:hover { box-shadow: 0 10px 26px rgba(18, 28, 36, .13); transform: translateY(-2px); }
.sleeve-card.sleeve-core { border-top-color: #2f6f9f; }
.sleeve-card.sleeve-swing { border-top-color: #7a5bb5; }
.sleeve-card.sleeve-options { border-top-color: #c08b1e; }
.sleeve-card.sleeve-cash { border-top-color: #188754; }
.sleeve-card-head { display: flex; justify-content: space-between; align-items: baseline; }
.sleeve-code { font-size: 11px; font-weight: 800; letter-spacing: .07em; color: #40525f; }
.sleeve-target { font-size: 11px; font-weight: 700; color: #71808a; }
.sleeve-label { font-size: 16px; }
.sleeve-subtitle { color: #87929a; font-size: 11px; }
.sleeve-metrics { margin: 10px 0 0; padding: 10px 0 0; border-top: 1px solid #eaeef1; display: grid; gap: 7px; }
.sleeve-metrics > div { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.sleeve-metrics dt { color: #71808a; font-size: 11px; }
.sleeve-metrics dd { margin: 0; font-size: 12.5px; font-weight: 700; text-align: right; }
.sleeve-card-foot { margin-top: 10px; padding-top: 9px; border-top: 1px solid #eaeef1; display: flex; justify-content: space-between; align-items: center; gap: 8px; color: #71808a; font-size: 10.5px; }
.sleeve-card-foot b { color: #176b4b; font-size: 11px; }
.is-gain { color: #b8342a; }
.is-loss { color: #1c8f5a; }
.is-over { color: #a8700f; }
.is-under { color: #4a6b86; }
.lifecycle-summary { margin-top: 12px; padding: 14px; border: 1px solid #e3e8ec; border-radius: 6px; background: #f9fbfc; }
.lifecycle-summary > dl { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0; }
.lifecycle-summary > dl > div { min-width: 0; }
.lifecycle-summary dt { color: #71808a; font-size: 10.5px; font-weight: 800; }
.lifecycle-summary dd { margin: 5px 0 0; color: #22323c; font-size: 14px; font-weight: 700; }
.lifecycle-summary .metric-note { margin: 10px 0 0; color: #87929a; font-size: 10.5px; }
.lifecycle-badge { display: inline-block; margin-left: 6px; padding: 2px 6px; border: 1px solid #d8c59a; border-radius: 4px; background: #fdf8ec; color: #8a6420; font-size: 10px; font-weight: 700; }
.lifecycle-badge.is-open { border-color: #bcd6c6; background: #f2faf6; color: #176b4b; }
@media (max-width: 900px) {
  .sleeve-overview .sleeve-figures { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sleeve-overview .sleeve-grid { grid-template-columns: 1fr; }
  .lifecycle-summary > dl { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.spread-terminal-row .option-actions { display: grid; gap: 5px; align-content: start; }
.spread-terminal-row .option-actions .button { min-height: 30px; padding: 5px 9px; font-size: 11px; }
.spread-terminal-row .option-actions .button[disabled] { opacity: .45; cursor: not-allowed; }
.spread-terminal-row .option-actions small { color: #87929a; font-size: 10px; }
.closed-option-lifecycles .spread-terminal-list { margin-top: 12px; }
@media (max-width: 900px) { .spread-terminal-row .option-actions .button { width: 100%; } }

/* ================================================================= V-WB-NEXT
   股票「退出计划 Exit Plan」区块（§一）。淡底 + 左侧色条，与主表单区隔开；
   Entry / TP / SL / Potential Profit / Risk / Reward-Risk 用两列网格展示。 */
.pt-exit-plan{border:1px solid #d9e0e5;border-left:4px solid #4b6cb7;border-radius:6px;
  background:#f7f9fc;padding:12px 14px;margin:10px 0}
.pt-exit-plan[hidden]{display:none}
.pt-exit-plan legend{font-weight:600;color:#18212b;padding:0 6px}
.pt-exit-note{margin:4px 0 8px;font-size:12px;color:#5b6672;line-height:1.5}
.pt-exit-note[data-state="error"]{color:#b8342a;font-weight:600}
.pt-exit-fields{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.pt-exit-metrics{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;margin:10px 0 0}
.pt-exit-metrics>div{background:#fff;border:1px solid #e4e9ef;border-radius:5px;padding:8px 10px}
.pt-exit-metrics dt{font-size:11px;color:#6b7681;margin:0 0 2px}
.pt-exit-metrics dd{margin:0;font-size:13px;font-weight:600;color:#18212b;word-break:break-word}
.pt-exit-metrics dd.is-gain{color:#b8342a}
.pt-exit-metrics dd.is-loss{color:#1c8f5a}
@media (max-width:720px){.pt-exit-fields,.pt-exit-metrics{grid-template-columns:1fr}}

/* 持仓卡上的退出计划摘要（V-WB-NEXT §一/§二）。 */
.position-exit-plans{display:flex;flex-direction:column;gap:6px;margin:8px 0 0}
.exit-plan-chip{background:#f7f9fc;border-left:3px solid #4b6cb7;border-radius:4px;
  padding:6px 10px;display:flex;flex-direction:column;gap:2px}
.exit-plan-chip strong{font-size:12px;color:#18212b}
.exit-plan-chip span{font-size:12px;color:#3f4a55}
.exit-plan-chip small{font-size:11px;color:#6b7681}
.preview-exit-plan{margin:10px 0;padding:10px 12px;background:#f7f9fc;border-left:4px solid #4b6cb7;
  border-radius:5px;display:flex;flex-direction:column;gap:6px}
.preview-exit-plan strong{font-size:13px;color:#18212b}
.preview-exit-plan span{font-size:12px;color:#3f4a55}
.preview-exit-plan dl{margin:0;display:flex;flex-wrap:wrap;gap:6px 16px;font-size:12px;color:#18212b}
.preview-exit-plan small{font-size:11px;color:#6b7681}

/* ===================================================================
   Performance 页面紧凑化（§B1/B2/B12/B14）
   纯粹是"同一批数字怎么排版"的问题：一行一笔、字号统一小一级、
   允许横向滚动、表头可排序。不改变任何数值口径。
   ------------------------------------------------------------------
   配色：本页按用户在本轮的明确要求，**盈利=绿、亏损=红**（与站内其它页面
   沿用的"涨红跌绿"相反）。两处集中在下面这两个变量，要回退只需改这两行。
   =================================================================== */
.perf-compact { --perf-profit: #1c8f5a; --perf-loss: #b8342a; --perf-neutral: #6b7782; }
.perf-compact .perf-gain { color: var(--perf-profit); }
.perf-compact .perf-loss { color: var(--perf-loss); }
.perf-compact .perf-neutral { color: var(--perf-neutral); }

.perf-compact .section-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.perf-head-actions { display: flex; align-items: center; gap: 10px; flex: 0 0 auto; }
.perf-engine { font-size: 11px; color: #6b7782; background: #eef2f4; padding: 4px 8px; border-radius: 4px; }
.perf-inline-note { margin: 8px 0 0; font-size: 11.5px; color: #6b7782; line-height: 1.5; }
.perf-inline-note code { background: #eef2f4; padding: 1px 5px; border-radius: 3px; font-size: 11px; }
.perf-counts { display: flex; gap: 10px; font-size: 11.5px; color: #6b7782; flex: 0 0 auto; }
.perf-counts span { background: #eef2f4; padding: 3px 8px; border-radius: 4px; }
.perf-subhead { margin: 14px 0 5px; font-size: 13px; display: flex; align-items: baseline; gap: 10px; }
.perf-subhead small { font-weight: 400; font-size: 10.5px; color: #6b7782; }

/* ---- §B1 顶部 6 卡：一行、矮、字小 ---- */
.perf-cards { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px;
  background: #dfe4e8; border: 1px solid #dfe4e8; margin-top: 14px; }
.perf-cards .perf-card { background: #fff; padding: 7px 10px; min-height: 0; display: block; }
.perf-cards .perf-card span { display: block; font-size: 10.5px; color: #6b7782; }
.perf-cards .perf-card strong { display: block; font-size: 16px; margin: 2px 0 0; line-height: 1.15;
  font-variant-numeric: tabular-nums; }
.perf-cards .perf-card small { display: block; font-size: 9.5px; color: #8b959e; }
@media (max-width: 1180px) { .perf-cards { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---- R37 #307 顶部已实现收益的唯一公式（默认展开，逐项可验算） ---- */
.perf-formula { margin-top: 12px; background: #fff; border: 1px solid #e1e5e8; padding: 10px 14px; }
.perf-formula > summary { cursor: pointer; font-size: 12.5px; font-weight: 700; color: #17212b; }
.perf-formula-table { border-collapse: collapse; width: 100%; font-size: 11.5px; margin-top: 8px; }
.perf-formula-table th, .perf-formula-table td { padding: 4px 8px; text-align: center;
  border-bottom: 1px solid #edf0f2; }
.perf-formula-table thead th { background: #f0f4f2; font-size: 10.5px; color: #5d6870; }
.perf-formula-table td.perf-align-left, .perf-formula-table th.perf-align-left { text-align: left; }
.perf-formula-table .num { font-variant-numeric: tabular-nums; }
.perf-formula-table td small { display: block; font-size: 9.5px; color: #8b959e; font-weight: 400; }
.perf-formula-sign { width: 28px; color: #6b7782; font-weight: 700; }
.perf-formula-table tbody tr.perf-formula-subtotal td { background: #f7f9f8; border-top: 1px dashed #cbd8d2; }
.perf-formula-table tbody tr.perf-formula-result td { background: #eff4f1; font-weight: 700;
  border-top: 2px solid #cbd8d2; border-bottom: none; }
.perf-formula-note { margin: 8px 0 0; font-size: 11px; color: #5d6870; line-height: 1.7; }
.perf-formula-note b { color: #17212b; }

/* ---- §B14 表格：字号小一级、行紧凑、可横向滚动 ---- */
.perf-table-wrap { overflow-x: auto; margin-top: 6px; border: 1px solid #e1e5e8; background: #fff; }
.perf-table { border-collapse: collapse; width: 100%; font-size: 11px; }
.perf-table.perf-table-wide { min-width: 1180px; }
.perf-table.perf-table-mid { min-width: 960px; }
.perf-table th, .perf-table td { padding: 4px 8px; text-align: center; white-space: nowrap;
  border-bottom: 1px solid #edf0f2; vertical-align: middle; line-height: 1.35; }
.perf-table thead th { position: sticky; top: 0; background: #f6f8f9; font-size: 10px;
  color: #5d6870; font-weight: 700; border-bottom: 1px solid #d7dde2; }
.perf-table[data-datatable] thead th { cursor: pointer; user-select: none; }
.perf-table[data-datatable] thead th::after { content: ""; margin-left: 5px; color: #b3bcc3; font-size: 9px; }
.perf-table[data-datatable] thead th[data-sort-dir="asc"]::after { content: "▲"; color: #188754; }
.perf-table[data-datatable] thead th[data-sort-dir="desc"]::after { content: "▼"; color: #188754; }
.perf-table tbody tr:nth-child(even) { background: #fbfcfc; }
.perf-table tbody tr:hover { background: #f3f8f5; }
/* §五（本轮）：全页面统一 —— 文字列左对齐、数值列居中、日期居中、操作居中。
   行内不再出现「同一数值列右对齐 / 居中混用」；表头与内容同规则，因此不会错位。 */
.perf-table .num { text-align: center; font-variant-numeric: tabular-nums; }
.perf-table td small { display: block; font-size: 9.5px; color: #8b959e; }
.perf-table th[data-sort-type="number"], .perf-table th[data-sort-type="date"],
.perf-table td.perf-date { text-align: center; }
/* 文字列恒左对齐（公司名 / 仓位 / 策略 / 凭证 / 标记） */
.perf-table th.perf-align-left, .perf-table td.perf-align-left { text-align: left; }
/* 生命周期列固定宽度，最后一列不漂出容器 */
.perf-col-life { width: 104px; min-width: 104px; text-align: center; }
.perf-table td.perf-col-life, .perf-table th.perf-col-life { text-align: center; }
/* 操作列（查看详情 / 平仓 / 加仓 / 两腿详情 / 平仓整组）居中 */
.perf-table td.perf-actions, .perf-table th:last-child, .perf-table td:last-child {
  text-align: center; }
.perf-table th:last-child, .perf-table td:last-child { padding-right: 10px; }
.perf-sleeves-table { min-width: 1180px; }
.perf-sleeves-table td.perf-sleeve-cell { width: 168px; }
.perf-basis-table { min-width: 760px; }
/* §五 / §六：明细表底部小计行 —— 参与展示，但不参与排序 / 筛选 */
.perf-table tbody tr.perf-subtotal { background: #eff4f1 !important; }
.perf-table tbody tr.perf-subtotal:hover { background: #e6efea !important; }
.perf-table tbody tr.perf-subtotal td { border-top: 2px solid #cbd8d2; font-weight: 700;
  border-bottom: none; }
.perf-table tbody tr.perf-subtotal td small { font-weight: 400; }
.perf-name { font-weight: 600; }
.perf-sleeve-cell a { text-decoration: none; color: inherit; }
.perf-sleeve-cell a:hover b { color: #176b4b; }
.perf-sleeve-cell small { display: block; font-size: 10px; color: #8b959e; font-weight: 400; }
.perf-confirm { font-size: 10px; color: #7a5a1f; }
.perf-detail-link { color: #176b4b; font-weight: 600; text-decoration: none; white-space: nowrap; }
.perf-actions a { color: #176b4b; text-decoration: none; margin-right: 8px; font-size: 11px; }
.perf-empty td { color: #8b959e; font-size: 11.5px; padding: 14px 8px; }
.perf-legs summary { cursor: pointer; color: #176b4b; font-size: 11px; }
.perf-legs ul { margin: 6px 0 0; padding-left: 16px; font-size: 10.5px; color: #5d6870; line-height: 1.7; }

/* ---- R37 #305 部分实现的逐批（lot）明细：展开行，不参与筛选 / 计数 / 排序 ---- */
.perf-table tbody tr.perf-lot-row > td { background: #f7f9fa; text-align: left;
  border-top: 1px dashed #d7dde2; padding: 10px 14px; white-space: normal; }
.perf-lot-block { margin: 0 0 12px; }
.perf-lot-block:last-of-type { margin-bottom: 6px; }
.perf-lot-head { margin: 0 0 6px; font-size: 11.5px; color: #2c3a45; }
.perf-lot-head b { color: #17212b; }
.perf-lot-table { border-collapse: collapse; width: 100%; font-size: 10.5px;
  background: #fff; border: 1px solid #e1e5e8; }
.perf-lot-table th, .perf-lot-table td { padding: 3px 8px; text-align: center;
  border-bottom: 1px solid #edf0f2; white-space: nowrap; }
.perf-lot-table thead th { background: #f0f4f2; font-size: 10px; color: #5d6870; font-weight: 700; }
.perf-lot-table td.perf-align-left, .perf-lot-table th.perf-align-left { text-align: left; }
.perf-lot-table code { font-size: 10px; color: #3b4a56; background: #f1f4f6;
  padding: 1px 5px; border-radius: 3px; }
.perf-lot-table tbody tr.perf-lot-sub td { background: #eff4f1; font-weight: 700;
  border-top: 1px solid #cbd8d2; border-bottom: none; }
.perf-lot-link { margin: 6px 0 0; font-size: 11px; color: #4a5865; }
.perf-lot-link code { font-size: 10px; background: #eaf1ec; color: #176b4b;
  padding: 1px 5px; border-radius: 3px; }
.perf-lot-foot { margin: 4px 0 0; font-size: 11px; color: #5d6870; }
.perf-lot-foot b { color: #17212b; }
.perf-lot-table tbody tr.perf-lot-warn td { background: #fdf6e3; color: #7a5a1f;
  text-align: left; white-space: normal; line-height: 1.6; }

/* ---- §B12 筛选 chips ---- */
.perf-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin: 8px 0 2px; }
.perf-chips-label { font-size: 10.5px; color: #8b959e; margin-right: 3px; }
.perf-chip { border: 1px solid #d7dde2; background: #fff; color: #4c565e; font-size: 11px;
  padding: 3px 9px; border-radius: 11px; cursor: pointer; line-height: 1.5; }
.perf-chip:hover { border-color: #188754; color: #176b4b; }
.perf-chip.is-active { background: #188754; border-color: #188754; color: #fff; font-weight: 600; }

/* ---- §B2 计算口径折叠区 ---- */
.perf-basis { margin-top: 10px; border: 1px solid #e1e5e8; background: #fbfcfc; padding: 8px 12px; }
.perf-basis > summary { cursor: pointer; font-size: 12px; font-weight: 700; color: #176b4b; }
.perf-basis h4 { margin: 12px 0 4px; font-size: 11.5px; color: #4c565e; }
.perf-basis-list { margin: 8px 0 0; display: grid; gap: 5px; }
.perf-basis-list div { display: grid; grid-template-columns: minmax(150px, 200px) 1fr; gap: 10px; font-size: 11px; }
.perf-basis-list dt { color: #5d6870; font-weight: 700; }
.perf-basis-list dd { margin: 0; color: #6b7782; line-height: 1.55; }
.perf-bridge-line { font-size: 11px; color: #5d6870; margin: 6px 0 0; }

/* ============================================================
   Dashboard 首页（本轮 §一~§十九）：摘要 / 状态 / 导航 / 风险
   视觉原则沿用 Performance：小字号、紧凑行高、少留白、横向滚动。
   配色作用域：盈利绿 / 亏损红（与 .perf-compact 同一套语义，站内既有
   .is-gain/.is-loss 的"涨红跌绿"语义不参与本区域）。
   ============================================================ */
.dash-compact { --dash-profit: #1c8f5a; --dash-loss: #b8342a; --dash-neutral: #6b7782;
  --dash-line: #e1e5e8; }
.dash-compact .dash-gain { color: var(--dash-profit); }
.dash-compact .dash-loss { color: var(--dash-loss); }
.dash-compact .dash-neutral { color: var(--dash-neutral); }

/* ---- §十九 数据新鲜度（很轻的一条） ---- */
.dash-freshness { display: flex; align-items: center; gap: 8px; font-size: 11px;
  padding: 4px 10px; border: 1px solid var(--dash-line); background: #fff; margin-bottom: 8px;
  color: #5d6870; }
.dash-freshness-dot { width: 7px; height: 7px; border-radius: 50%; background: #b8342a; flex: 0 0 auto; }
.dash-freshness.is-live .dash-freshness-dot { background: #1c8f5a; box-shadow: 0 0 0 2px rgba(28, 143, 90, .15); }
.dash-freshness.is-stale .dash-freshness-dot { background: #d08700; }
.dash-freshness-line { font-weight: 700; color: #2d363c; }
.dash-freshness-note { color: #8b959e; }

/* ---- 区块骨架 ---- */
.dash-block { margin: 0 0 10px; border: 1px solid var(--dash-line); background: #fff; }
.dash-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  padding: 6px 10px; border-bottom: 1px solid var(--dash-line); background: #f7f9fa; }
.dash-head h2 { margin: 0; font-size: 12.5px; color: #22303a; }
.dash-head h2 small { font-weight: 400; font-size: 10px; color: #8b959e; margin-left: 4px; }
.dash-head-note { font-size: 10px; color: #8b959e; text-align: right; line-height: 1.45; }
.dash-sub-head { display: flex; align-items: baseline; justify-content: space-between;
  font-size: 11.5px; color: #22303a; padding: 5px 8px; background: #fbfcfc;
  border-bottom: 1px solid var(--dash-line); }
.dash-sub-head small { color: #8b959e; font-weight: 400; }
.dash-more { font-size: 10.5px; color: #176b4b; text-decoration: none; white-space: nowrap; }
.dash-more:hover { text-decoration: underline; }
.dash-foot-note { margin: 0; padding: 4px 10px 6px; font-size: 10px; color: #8b959e; line-height: 1.5; }
.dash-foot-note a { color: #176b4b; }
.dash-clear { margin: 0; padding: 8px 10px; font-size: 11.5px; color: #4c565e; }

/* ---- §二 顶部账户总览：一行 6 项 ---- */
.dash-metrics { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 1px;
  background: var(--dash-line); }
.dash-metrics-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.dash-metric { background: #fff; padding: 7px 11px; min-width: 0; }
.dash-metric-label { display: block; font-size: 10.5px; color: #6b7782; white-space: nowrap;
  overflow: hidden; text-overflow: ellipsis; }
.dash-metric-label small { color: #9aa4ad; font-size: 9.5px; }
.dash-metric-value { display: block; font-size: 20px; font-weight: 700; line-height: 1.15;
  margin: 3px 0 1px; letter-spacing: -.3px; font-variant-numeric: tabular-nums; }
.dash-metric-note { display: block; font-size: 9.5px; color: #8b959e; }
@media (max-width: 1180px) { .dash-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---- §三~§九 四仓卡：整卡即导航入口 ---- */
.dash-sleeves { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1px;
  background: var(--dash-line); }
.dash-sleeve { display: block; background: #fff; padding: 8px 11px 0; text-decoration: none;
  color: inherit; border-top: 3px solid #d7dde2; transition: background .12s ease; }
.dash-sleeve:hover { background: #f4f9f6; }
.dash-sleeve-core { border-top-color: #1c5fd0; }
.dash-sleeve-swing { border-top-color: #188754; }
.dash-sleeve-options { border-top-color: #a25a1c; }
.dash-sleeve-cash { border-top-color: #6b7782; }
.dash-sleeve-head { display: flex; align-items: baseline; justify-content: space-between; gap: 6px; }
.dash-sleeve-code { font-size: 10.5px; font-weight: 700; letter-spacing: .6px; color: #4c565e; }
.dash-sleeve-target { font-size: 10px; color: #8b959e; }
.dash-sleeve-name { display: block; font-size: 13px; color: #1f2933; margin: 2px 0 0; }
.dash-sleeve-sub { display: block; font-size: 9.5px; color: #9aa4ad; }
.dash-sleeve-metrics { margin: 6px 0 0; display: grid; gap: 2px; }
.dash-sleeve-metrics div { display: flex; align-items: baseline; justify-content: space-between;
  gap: 8px; font-size: 11px; border-bottom: 1px dashed #eef1f3; padding-bottom: 1px; }
.dash-sleeve-metrics dt { color: #6b7782; }
.dash-sleeve-metrics dd { margin: 0; font-weight: 600; font-variant-numeric: tabular-nums; color: #22303a; }
.dash-sleeve-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
  margin: 7px -11px 0; padding: 4px 11px; background: #f7f9fa;
  border-top: 1px solid var(--dash-line); font-size: 10px; color: #8b959e; }
.dash-sleeve-foot b { margin-left: auto; color: #176b4b; }
.dash-sleeve-flag { color: #a25a1c; }
@media (max-width: 1180px) { .dash-sleeves { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---- §十一 持仓摘要：两列 ---- */
.dash-two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1px;
  background: var(--dash-line); }
.dash-col { background: #fff; min-width: 0; }
.dash-table { min-width: 100%; }
@media (max-width: 1180px) { .dash-two-col { grid-template-columns: minmax(0, 1fr); } }

/* ---- §十二 风险 / 注意事项 ---- */
.dash-risk { list-style: none; margin: 0; padding: 0; }
.dash-risk-item { display: grid; grid-template-columns: minmax(140px, 220px) 1fr auto;
  align-items: baseline; gap: 10px; padding: 5px 10px; font-size: 11px;
  border-bottom: 1px solid #f0f3f5; }
.dash-risk-item:last-child { border-bottom: 0; }
.dash-risk-item strong { color: #22303a; }
.dash-risk-item span { color: #6b7782; }
.dash-risk-item a { color: #176b4b; font-size: 10.5px; text-decoration: none; white-space: nowrap; }
.dash-risk-item a:hover { text-decoration: underline; }
.dash-risk-item.sev-high { border-left: 3px solid #b8342a; }
.dash-risk-item.sev-medium { border-left: 3px solid #d08700; }
.dash-risk-item.sev-low { border-left: 3px solid #8b959e; }

/* ---- §十三 待办 + §十四 快捷入口 ---- */
.dash-todos { display: flex; flex-wrap: wrap; gap: 6px; padding: 7px 10px 0; }
.dash-todo { display: inline-flex; align-items: baseline; gap: 6px; padding: 4px 10px;
  border: 1px solid #d7dde2; border-radius: 3px; background: #fff; text-decoration: none;
  font-size: 11px; color: #4c565e; }
.dash-todo:hover { border-color: #188754; color: #176b4b; }
.dash-todo strong { font-size: 14px; color: #b8342a; font-variant-numeric: tabular-nums; }
.dash-links { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px 10px; margin-top: 4px;
  border-top: 1px solid var(--dash-line); }
.dash-links a { font-size: 10.5px; padding: 3px 10px; border: 1px solid #d7dde2; border-radius: 11px;
  color: #4c565e; text-decoration: none; background: #fff; }
.dash-links a:hover { border-color: #188754; color: #176b4b; }

/* ---- 口径说明折叠区 ---- */
.dash-basis { margin: 0; }
.dash-basis-table { min-width: 760px; }
.dash-basis code { background: #f2f4f8; border-radius: 3px; padding: 0 3px;
  font: 10px/1.5 "Cascadia Mono", Consolas, monospace; }

/* ============================================================ #
   r16 单页主工作台 / Single Page Trading Dashboard（§一~§四 / §七 / §十五 / §廿八）
   —— 全部作用域在 .dash-single-page 内，不污染其它页面
   ============================================================ # */

/* ---- §三 长页骨架：紧凑、少留白 ---- */
.dash-single-page { display: block; }
.dash-single-page .dash-block { margin: 0 0 8px; scroll-margin-top: 12px; }
.dash-single-page .dash-section { position: relative; }

/* ---- §三 分区头（替代旧的 .dash-head） ---- */
.dash-section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px;
  padding: 6px 11px; border-bottom: 1px solid var(--dash-line); background: #f8fafb; }
.dash-section-title { display: flex; align-items: baseline; gap: 8px; min-width: 0; flex-wrap: wrap; }
.dash-section-title h2 { margin: 0; font-size: 12.5px; color: #22303a; }
.dash-section-sub { font-size: 10px; color: #8b959e; }
.dash-section-tools { display: flex; align-items: center; gap: 6px; flex: 0 0 auto; }
.dash-refresh { font-size: 10.5px; padding: 2px 9px; border: 1px solid #d7dde2; border-radius: 3px;
  background: #fff; color: #4c565e; cursor: pointer; }
.dash-refresh:hover { border-color: #188754; color: #176b4b; }
.dash-refresh[disabled] { opacity: .5; cursor: default; }
.dash-more { font-size: 10.5px; padding: 2px 9px; border: 1px solid #d7dde2; border-radius: 3px;
  color: #4c565e; text-decoration: none; background: #fff; white-space: nowrap; }
.dash-more:hover { border-color: #188754; color: #176b4b; }

/* ---- §四 右侧紧凑浮动导航（点击只滚动，不加载页面） ---- */
.dash-floatnav { position: fixed; top: 92px; right: 10px; z-index: 30; width: 92px;
  display: flex; flex-direction: column; gap: 1px; padding: 5px 4px; border: 1px solid var(--dash-line);
  border-radius: 4px; background: rgba(255, 255, 255, .96); box-shadow: 0 2px 8px rgba(23, 33, 43, .08);
  font-size: 10.5px; }
.dash-floatnav-title { font-size: 9.5px; color: #9aa4ad; padding: 1px 3px 3px; letter-spacing: .5px; }
.dash-floatnav-link { display: block; padding: 3px 6px; border-radius: 3px; color: #4c565e;
  text-decoration: none; line-height: 1.25; }
.dash-floatnav-link:hover { background: #eef4f1; color: #176b4b; }
.dash-floatnav-link.is-active { background: #188754; color: #fff; font-weight: 600; }
.dash-floatnav-top { margin-top: 3px; border-top: 1px solid #eef1f3; color: #8b959e; }
@media (max-width: 1420px) { .dash-floatnav { display: none; } }
@media (max-width: 1420px) { .dash-single-page { } }

/* ---- §十九 §廿四 新鲜度条：Broker LIVE + 更新时间 + 刷新全部 + 聚合口径 ---- */
.dash-freshness-note { color: #8b959e; white-space: nowrap; }
.dash-freshness-agg { margin-left: auto; color: #6b7782; white-space: nowrap; }
.dash-freshness-agg b { color: #22303a; font-variant-numeric: tabular-nums; }
.dash-refresh-all { font-size: 10.5px; padding: 2px 9px; border: 1px solid #cfd8dd; border-radius: 3px;
  background: #fff; color: #176b4b; font-weight: 600; cursor: pointer; }
.dash-refresh-all:hover { background: #eef7f2; }
.dash-refresh-all[disabled] { opacity: .5; cursor: default; }
.dash-refresh-state { font-size: 10px; color: #8b959e; min-width: 68px; }

/* ---- §七 每张主表上方：独立筛选 chips + 独立排序下拉 + 行数 ---- */
.dash-table-block { border-top: 1px solid var(--dash-line); }
.dash-table-block:first-of-type { border-top: 0; }
.dash-filterbar { display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
  padding: 5px 10px 4px; background: #fcfdfd; }
.dash-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.dash-chip { border: 1px solid #d7dde2; background: #fff; color: #4c565e; font-size: 10.5px;
  padding: 2px 9px; border-radius: 11px; cursor: pointer; line-height: 1.5; }
.dash-chip:hover { border-color: #188754; color: #176b4b; }
.dash-chip.is-active { background: #188754; border-color: #188754; color: #fff; font-weight: 600; }
.dash-sort { display: inline-flex; align-items: center; gap: 4px; font-size: 10.5px; color: #8b959e; }
.dash-sort select { font-size: 10.5px; padding: 2px 4px; border: 1px solid #d7dde2; border-radius: 3px;
  background: #fff; color: #4c565e; max-width: 190px; }
.dash-symbol-filter { margin-left: auto; }
.dash-rowcount { font-size: 10px; color: #9aa4ad; font-variant-numeric: tabular-nums; }

/* ---- §五 §九 §十七 小计条 + 脚注 ---- */
.dash-subtotal-strip { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px;
  padding: 5px 11px; border-bottom: 1px solid var(--dash-line); background: #f6f9f8; font-size: 11px; color: #5d6870; }
.dash-subtotal-strip b { font-size: 13px; font-variant-numeric: tabular-nums; color: #22303a; }
.dash-subtotal-strip small { font-size: 9.5px; color: #9aa4ad; }
.dash-subtotal-note { color: #a25a1c; font-size: 10.5px; }
.dash-foot-note { margin: 0; padding: 5px 11px 7px; font-size: 10px; color: #8b959e; line-height: 1.6;
  border-top: 1px solid #f0f3f5; }
.dash-muted { font-size: 10px; color: #b3bcc3; }
.dash-clear { margin: 0; padding: 10px 11px; font-size: 11px; color: #1c8f5a; }

/* ---- §十 三仓收益表现：整行可点（页内定位） ---- */
.dash-compact .dash-row-link { cursor: pointer; }
.dash-compact .dash-row-link:hover { background: #eef7f2 !important; }
.dash-compact .dash-row-link:focus { outline: 2px solid #188754; outline-offset: -2px; }

/* ---- §十 资金口径 8 项：4 列 ---- */
.dash-metrics-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1180px) { .dash-metrics-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---- §十二 风险 / 待办：两列 ---- */
.dash-risk-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1px;
  background: var(--dash-line); }
.dash-risk-col { background: #fff; min-width: 0; }
.dash-mini-title { margin: 0; padding: 5px 11px 3px; font-size: 11px; color: #22303a; }
.dash-mini-title small { font-weight: 400; font-size: 9.5px; color: #9aa4ad; }
@media (max-width: 1180px) { .dash-risk-grid { grid-template-columns: minmax(0, 1fr); } }

/* ---- §十三~§十六 资金往来：备注列 + 附件列 + 凭证缩略图 ---- */
.dash-note-cell { max-width: 340px; white-space: normal !important; text-align: left !important;
  line-height: 1.5; font-size: 10.5px; }
.dash-original { display: block; font-size: 9.5px; color: #9aa4ad; }
.dash-attach-cell { white-space: nowrap; }
.dash-evidence { display: inline-block; text-align: left; }
.dash-evidence > summary { cursor: pointer; color: #176b4b; font-size: 10.5px; list-style: none; }
.dash-evidence > summary::-webkit-details-marker { display: none; }
.dash-evidence > summary::before { content: "▸ "; color: #8b959e; }
.dash-evidence[open] > summary::before { content: "▾ "; }
.dash-evidence-list { display: flex; flex-direction: column; gap: 6px; margin: 6px 0 4px;
  padding: 6px; border: 1px solid var(--dash-line); border-radius: 3px; background: #fbfcfc; }
.dash-evidence-item { margin: 0; display: flex; flex-direction: column; gap: 2px; font-size: 10.5px; }
.dash-evidence-item a { color: #176b4b; text-decoration: none; word-break: break-all; }
.dash-evidence-item a:hover { text-decoration: underline; }
.dash-evidence-item small { font-size: 9.5px; color: #9aa4ad; }
.dash-evidence-thumb { display: block; max-width: 220px; max-height: 150px; border: 1px solid var(--dash-line);
  border-radius: 3px; background: #fff; }
.dash-attach-upload { margin-top: 3px; font-size: 10px; padding: 2px 8px; border: 1px dashed #cfd8dd;
  border-radius: 3px; background: #fff; color: #6b7782; cursor: pointer; }
.dash-attach-upload:hover { border-color: #188754; color: #176b4b; }

/* ---- §二十四 局部刷新时的轻微视觉反馈 ---- */
.dash-section.is-refreshing { opacity: .55; }
.dash-section.is-focused { box-shadow: 0 0 0 2px rgba(24, 135, 84, .35); }

/* ---- §二十 左侧导航精简：兼容入口降权 ---- */
#primary-navigation .nav-group-label em { font-style: normal; font-weight: 400;
  font-size: 9.5px; color: #b3bcc3; margin-left: 4px; }
#primary-navigation a.nav-compat { opacity: .72; font-size: 12px; }
#primary-navigation a.nav-compat small { color: #b3bcc3; }
#primary-navigation a.nav-compat:hover { opacity: 1; }
#primary-navigation a.nav-compat.active { opacity: 1; }
#primary-navigation a.nav-primary-trade { font-weight: 600; }

/* ============================================================ #
   r17 四仓配置进度卡 / 资金口径分层 / 上传凭证识别上账 / 三操作弹窗
   （§一~§十五）—— 全部限定在 .dash-compact 页面作用域，不影响其它页面。
   ============================================================ */

/* ---- §一 四仓卡：右上角 hero（当前比例 + 当前资本，同字号）+ 容量使用进度条 ---- */
.dash-sleeve-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.dash-sleeve-ident { min-width: 0; }
.dash-sleeve-hero { flex: 0 0 auto; display: grid; gap: 5px; margin-left: auto; text-align: right; }
.dash-hero-label { display: block; font-size: 9px; color: #8b959e; letter-spacing: .02em; }
.dash-hero-value { display: block; font-size: 22px; line-height: 1.05; font-weight: 700; color: #22303a;
  font-variant-numeric: tabular-nums; white-space: nowrap; }
.dash-hero-target { display: block; font-size: 9.5px; color: #8b959e; white-space: nowrap; }

.dash-sleeve-progress { margin: 0 0 4px; }
.dash-sleeve-progress-track { position: relative; height: 6px; border-radius: 3px;
  background: #eef1f3; overflow: hidden; }
.dash-sleeve-progress-normal { position: absolute; left: 0; top: 0; bottom: 0; background: #188754;
  border-radius: 3px 0 0 3px; transition: width .25s ease; }
.dash-sleeve-progress-over { position: absolute; top: 0; bottom: 0; background: #c9862b;
  transition: width .25s ease; }
.dash-sleeve-progress-marker { position: absolute; top: -2px; bottom: -2px; width: 2px;
  background: #4c565e; }
.dash-sleeve-progress[data-gauge-state="OVER"] .dash-sleeve-progress-normal { background: #c9862b; }
.dash-sleeve-progress[data-gauge-state="UNKNOWN"] .dash-sleeve-progress-track { background: #f2f4f5; }
.dash-sleeve-progress-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 7px;
  margin-top: 3px; font-size: 9.5px; color: #8b959e; }
.dash-sleeve-progress-label { color: #6b7782; }
.dash-sleeve-progress-dev { margin-left: auto; font-variant-numeric: tabular-nums; }

/* ---- §四 §五 资金台账：资本口径徽标 + 分层标签 ---- */
.dash-basis-cell { white-space: nowrap; }
.dash-basis-tag { display: inline-block; padding: 1px 6px; border-radius: 9px; font-size: 9.5px;
  font-weight: 600; border: 1px solid transparent; }
.dash-basis-tag-contribution { color: #14603f; background: #e8f5ee; border-color: #bfe3ce; }
.dash-basis-tag-non_contribution { color: #6b7782; background: #f2f4f5; border-color: #dfe4e7; }
.dash-basis-tag-adjustment { color: #8a5a12; background: #fdf3e3; border-color: #efd9b0; }
.dash-basis-cell small { display: block; margin-top: 2px; }
.dash-note-cell { max-width: 30ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-original { color: #9aa4ad; font-size: 10px; }
.dash-exit-plan { display: inline-block; padding: 1px 6px; border-radius: 3px; font-size: 10px;
  background: #fdf3e3; border: 1px solid #efd9b0; color: #8a5a12; }

/* ---- §七 上传凭证 / 识别上账 入口条 ---- */
.dash-intake-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
  padding: 7px 11px; border-bottom: 1px solid var(--dash-line); background: #f8fbf9; }
.dash-intake-upload { font-size: 11px; font-weight: 600; padding: 4px 12px; border-radius: 4px;
  border: 1px solid #188754; background: #fff; color: #176b4b; cursor: pointer; }
.dash-intake-upload:hover { background: #eef7f2; }
.dash-intake-upload:disabled { opacity: .55; cursor: progress; }
.dash-intake-note { font-size: 10px; color: #8b959e; flex: 1 1 240px; }
.dash-intake-type { font-size: 10.5px; padding: 3px 6px; border: 1px solid #dfe4e7;
  border-radius: 4px; background: #fff; color: #4c565e; }
#intake-queue { font-size: 10px; color: #6b7782; }

/* ---- §十三 §十四 §十五 三套弹窗（各自独立 DOM） ---- */
.dash-modal { position: fixed; inset: 0; z-index: 60; display: flex; align-items: flex-start;
  justify-content: center; padding: 5vh 16px 16px; background: rgba(23, 33, 43, .42);
  overflow-y: auto; }
.dash-modal[hidden] { display: none; }
.dash-modal-card { width: 100%; max-width: 460px; background: #fff; border-radius: 8px;
  box-shadow: 0 18px 44px rgba(23, 33, 43, .22); padding: 14px 16px 16px; }
.dash-modal-wide .dash-modal-card { max-width: 880px; }
.dash-modal-head { display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-bottom: 10px; }
.dash-modal-head h3 { margin: 0; font-size: 14px; color: #1f2933; }
.dash-modal-close { border: 0; background: transparent; font-size: 20px; line-height: 1;
  color: #8b959e; cursor: pointer; padding: 0 4px; }
.dash-modal-close:hover { color: #22303a; }
.dash-modal-summary { margin: 0 0 10px; padding: 8px 10px; background: #f7f9fa;
  border: 1px solid var(--dash-line); border-radius: 5px; display: grid; gap: 3px; }
.dash-modal-summary div { display: flex; justify-content: space-between; gap: 10px; font-size: 11px; }
.dash-modal-summary dt { color: #6b7782; }
.dash-modal-summary dd { margin: 0; font-weight: 600; color: #22303a; font-variant-numeric: tabular-nums; }
/* §B1：紧凑摘要（两列网格，标签 + 值同行内联） */
.dash-modal-summary.dash-modal-summary-compact { grid-template-columns: 1fr 1fr; gap: 4px 12px; }
.dash-modal-summary.dash-modal-summary-compact .dash-sum { display: flex; align-items: baseline; gap: 6px; font-size: 11px; }
.dash-modal-summary.dash-modal-summary-compact .dash-sum b { color: #6b7782; font-weight: 500; flex: 0 0 auto; }
.dash-modal-summary.dash-modal-summary-compact .dash-sum i { font-style: normal; font-weight: 600; color: #22303a; font-variant-numeric: tabular-nums; }
.dash-modal-summary.dash-modal-summary-compact .dash-sum-wide { grid-column: 1 / -1; }
/* §B2：止盈 / 止损分区卡片（实时显示触发价 / 距当前价 / 预计盈亏 / 收益率） */
.dash-modal-basis { margin: 4px 0 8px; background: #f3f7fb; border: 1px solid #d8e6f2; border-radius: 5px;
  padding: 5px 8px; font-size: 10.5px; color: #2c4a63; }
.dash-modal-basis b { font-weight: 600; }
.dash-plan-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 6px 0 8px; }
.dash-plan-card { border: 1px solid var(--dash-line); border-radius: 6px; padding: 8px 10px; background: #fff; }
.dash-plan-card-tp { border-top: 3px solid #188754; }
.dash-plan-card-sl { border-top: 3px solid #b8342a; }
.dash-plan-card-title { margin: 0 0 6px; font-size: 11.5px; font-weight: 700; }
.dash-plan-card-tp .dash-plan-card-title { color: #188754; }
.dash-plan-card-sl .dash-plan-card-title { color: #b8342a; }
.dash-plan-card-dl { margin: 0; display: grid; gap: 3px; }
.dash-plan-card-dl div { display: flex; justify-content: space-between; gap: 8px; font-size: 10.5px; }
.dash-plan-card-dl dt { color: #6b7782; margin: 0; }
.dash-plan-card-dl dd { margin: 0; font-weight: 600; color: #22303a; font-variant-numeric: tabular-nums; }
.dash-modal-card label { display: flex; align-items: center; justify-content: space-between;
  gap: 10px; margin-bottom: 7px; font-size: 11px; color: #4c565e; }
.dash-modal-card label > span { flex: 0 0 auto; }
.dash-modal-card input, .dash-modal-card select { flex: 1 1 auto; min-width: 0; font-size: 11.5px;
  padding: 4px 7px; border: 1px solid #dfe4e7; border-radius: 4px; background: #fff; color: #22303a; }
.dash-modal-card input:focus, .dash-modal-card select:focus { outline: 2px solid rgba(24,135,84,.28);
  border-color: #188754; }
.dash-modal-exit { border: 1px solid var(--dash-line); border-radius: 5px; padding: 6px 10px 4px;
  margin: 4px 0 8px; }
.dash-modal-exit legend { font-size: 10.5px; color: #6b7782; padding: 0 4px; }
.dash-modal-note { margin: 4px 0 8px; font-size: 10px; color: #8b959e; line-height: 1.55; }
.dash-modal-hint { display: block; margin: -2px 0 8px; font-size: 10px; color: #8b959e; line-height: 1.55; }
.dash-modal-hint b { color: #4c565e; }
.dash-modal-hint code { background: #f2f4f5; border-radius: 3px; padding: 0 3px; }
.dash-modal-note[data-state="error"] { color: #b8342a; }
.dash-modal-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 10px; }
.dash-modal-foot .button { font-size: 11.5px; padding: 5px 14px; }

/* 表格内的三操作链接 / 按钮：视觉一致，但「查看详情」是 <a>、交易是 <button> */
.dash-act { font-size: 10.5px; padding: 1px 7px; margin-right: 4px; border-radius: 3px;
  border: 1px solid #d6dde2; background: #fff; color: #35706b; cursor: pointer;
  text-decoration: none; display: inline-block; }
.dash-act:hover { border-color: #188754; color: #176b4b; background: #f4f9f6; }
.dash-act[disabled] { opacity: .45; cursor: not-allowed; }

/* ---- R35 第三批：期权本地平仓目标徽标（仅元数据，未向券商挂单） ---- */
.dash-local-target { font-size: 10px; padding: 1px 6px; margin-left: 2px; border-radius: 3px;
  border: 1px solid #cdd7e0; background: #eef3f8; color: #2f6f9f; vertical-align: middle; }
.dash-local-target-reached { border-color: #efd9b0; background: #fdf3e3; color: #8a5a0c; }

/* ---- §七 §八 §九 上传凭证识别上账弹窗 ---- */
.dash-intake-status { font-size: 10px; font-weight: 400; color: #8b959e; margin-left: 6px; }
.dash-intake-dup { margin: 0 0 10px; padding: 7px 10px; border-radius: 5px; font-size: 11px;
  background: #fdf3e3; border: 1px solid #efd9b0; color: #7a4f0c; }
.dash-intake-dup[hidden] { display: none; }
.dash-intake-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; }
.dash-intake-preview { margin: 0; }
.dash-intake-preview img { display: block; max-width: 100%; max-height: 460px; border-radius: 5px;
  border: 1px solid var(--dash-line); background: #f7f9fa; }
.dash-intake-preview figcaption { margin-top: 5px; font-size: 10px; color: #8b959e; word-break: break-all; }
.dash-intake-form { min-width: 0; }
.dash-intake-wide { display: block !important; }
.dash-intake-wide input { width: 100%; }
.dash-intake-dup-confirm { background: #fdf3e3; padding: 5px 8px; border-radius: 4px; }
.dash-intake-dup-confirm[hidden] { display: none; }
@media (max-width: 780px) { .dash-intake-body { grid-template-columns: minmax(0, 1fr); } }

/* ===== r20 Phase 1：REAL / SIMULATE 视觉隔离（Trade Approvals + 执行历史） =====
   涨红跌绿不变；这里的红色只表示「真实券商」，与盈亏涨跌无关。 */
.env-badge { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 9px;
  font-size: 11px; font-weight: 600; letter-spacing: .3px; vertical-align: middle; }
.env-badge-real { background: #fdecea; color: #b3261e; border: 1px solid #f2b8b5; }
.env-badge-sim { background: #eef1f3; color: #5a6b76; border: 1px solid #d7dee3; }
.review-card-real { border-left: 4px solid #b3261e; background: #fffafa; }
.real-warning { margin: 10px 0 6px; padding: 8px 10px; border-radius: 5px;
  background: #fdecea; border: 1px solid #f2b8b5; color: #8c1d18; font-size: 12px; line-height: 1.7; }
.execution-history-table { width: 100%; font-size: 12px; }
.execution-history-table td, .execution-history-table th { white-space: nowrap; }
.exec-row-real td { background: #fffafa; }
.exec-row-sim td { color: #5a6b76; }
/* R25 §九：券商拒单原因必须贴在状态旁边，且不能被 nowrap 截断。 */
.exec-reject { color: #8c1d18; font-size: 10px; white-space: normal; display: inline-block;
  max-width: 320px; line-height: 1.5; }

/* R23 §二：已平仓股票闭环的归属确认表格（12 列 + 单条/批量裁定）。
   进度条铁律不涉及本区；配色沿用全局 .is-gain/.is-loss（涨红跌绿）。 */
.cycle-counts { color: #65747c; font-size: 11px; }
.cycle-counts b { color: #223039; font-size: 15px; }
.cycle-table { display: grid; gap: 0; margin-bottom: 12px; border: 1px solid #e0e6ea; background: #fff; }
.cycle-row { display: grid; grid-template-columns: 26px 88px 88px 54px 62px repeat(5, minmax(72px,1fr)) minmax(120px,1.3fr) minmax(88px,0.9fr) auto; gap: 8px; align-items: center; padding: 8px 10px; border-bottom: 1px solid #e9edef; font-size: 11px; }
.cycle-row:last-child { border-bottom: 0; }
.cycle-row.cycle-head { background: #eef2f4; color: #65747c; font-size: 10px; font-weight: 700; }
.cycle-row .num { text-align: right; font-variant-numeric: tabular-nums; }
.cycle-row small { color: #74818a; font-size: 9px; }
.cycle-actions { display: flex; gap: 5px; }
.cycle-actions .button { padding: 5px 8px; font-size: 10px; white-space: nowrap; }
.cycle-batch { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding: 11px 12px; background: #f6f8f9; font-size: 11px; }
.cycle-batch small { padding: 0; background: none; color: #74818a; font-size: 10px; }
.cycle-batch select { padding: 7px; border: 1px solid #cbd5da; background: #fff; }
@media (max-width: 1100px) { .cycle-row { grid-template-columns: 26px 1fr 1fr 60px; }.cycle-row > span:nth-child(n+5) { display: none; } }

/* ============================================================ #
   R24 Dashboard 首页第二轮精修
   §一 账户总览 4 项 · §三 资金配置进度条对齐 Portfolio ·
   §五~§七 股票表 · §八~§十四 期权表（中文化 / 腿 / 盈亏平衡价 / 小计跟随筛选）
   配色仍在 .dash-compact 作用域内：盈利绿 --dash-profit / 亏损红 --dash-loss。
   ============================================================ */

/* ---- §一 实时总资产不可用时的显式标注（绝不用 $0 冒充真实值） ---- */
.dash-unavailable { font-size: 9.5px; font-weight: 700; letter-spacing: .04em; color: #a25a1c; }

/* ---- §三 资金配置：容量使用 + 超配徽标（进度条上方一行，服务端直出） ---- */
.dash-gauge-head { display: flex; align-items: baseline; justify-content: space-between;
  gap: 8px; margin: 7px 0 0; }
.dash-capacity-usage { font-size: 10px; font-weight: 700; color: #4c565e;
  font-variant-numeric: tabular-nums; }
.dash-over-badge { font-size: 10px; font-weight: 800; color: var(--dash-loss);
  white-space: nowrap; font-variant-numeric: tabular-nums; }
/* 进度条复用 Portfolio 同款结构（--normal / --over / --marker 均为服务端内联直出） */
.dash-compact .dash-sleeve .capacity-gauge { height: 8px; margin: 4px 0 9px; border-radius: 2px; }
.dash-compact .dash-sleeve .capacity-gauge .capacity-fill { background: var(--dash-profit); }
.dash-compact .dash-sleeve .capacity-gauge .capacity-overfill { background: var(--dash-loss); }
.dash-compact .dash-sleeve .capacity-gauge .target-marker { background: #4c565e; }
.dash-compact .dash-sleeve .capacity-gauge.gauge-unknown { background: #f2f4f5; }
.dash-compact .dash-sleeve .capacity-gauge.gauge-unknown .capacity-fill { width: 0; }
.dash-compact .dash-sleeve:hover .capacity-gauge { background: #e4ebee; }

/* ---- §五 股票表：价格 / 成本 合并列 ---- */
.dash-price { font-weight: 600; font-variant-numeric: tabular-nums; }
.dash-cost { color: #8b959e; font-weight: 400; }

/* ---- §六 §十四 小计行改到 <tfoot>（原样式只覆盖 tbody，这里补上） ---- */
.perf-table tfoot tr.perf-subtotal td { background: #eff4f1; border-top: 2px solid #cbd8d2;
  border-bottom: none; font-weight: 700; font-variant-numeric: tabular-nums; }
.perf-table tfoot tr.perf-subtotal td:first-child { text-align: left; }
.perf-table tfoot tr.perf-subtotal td small { display: block; font-weight: 400; color: #8b959e;
  font-size: 9.5px; }

/* ---- §七 止盈 / 止损（只显示当前有效 Exit Plan） ---- */
.dash-exit-levels { display: inline-flex; align-items: baseline; gap: 6px;
  font-variant-numeric: tabular-nums; white-space: nowrap; }
.dash-tp { color: var(--dash-profit); font-weight: 700; }
.dash-sl { color: var(--dash-loss); font-weight: 700; }

/* ---- §八 §九 期权表：中文策略名为主标签，英文只作次级灰色说明；价差腿紧凑写法 ---- */
.dash-strategy-zh { display: block; font-weight: 600; color: #22303a; }
.dash-strategy-en { display: block; font-size: 9.5px; color: #9aa4ad; font-weight: 400; }
.dash-legs { font-weight: 600; color: #4c565e; font-variant-numeric: tabular-nums;
  white-space: nowrap; }

/* ---- §十 期权表列多：横向滚动，不删关键字段 ---- */
.dash-compact .dash-table-block[data-dash-table="option-open"] .perf-table-wrap { overflow-x: auto; }

/* ===================================================================
   R32 持仓生命周期工作台（Positions Lifecycle Workbench）
   宽表 + 横向滚动（§三十六）；筛选 / 排序 / 小计纯前端。
   =================================================================== */
.positions-lifecycle-workspace { margin-top: 8px; }
.positions-lifecycle-workspace .section-heading small { white-space: nowrap; }

.lc-toolbar { margin: 10px 0 14px; padding: 10px 12px; border: 1px solid #dbe2e7; border-radius: 6px; background: #f8fafb; }
.lc-chips { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; }
.lc-chip { border: 1px solid #d7dde2; background: #fff; color: #4c565e; font-size: 11px;
  padding: 3px 10px; border-radius: 11px; cursor: pointer; line-height: 1.5; }
.lc-chip:hover { border-color: #188754; color: #176b4b; }
.lc-chip.is-active { background: #188754; border-color: #188754; color: #fff; font-weight: 600; }
.lc-selects { display: flex; flex-wrap: wrap; align-items: end; gap: 8px 12px; margin-top: 9px; }
.lc-selects label { display: grid; gap: 3px; font-size: 10.5px; color: #68757d; }
.lc-selects select, .lc-selects input { padding: 5px 7px; border: 1px solid #cbd5da; border-radius: 4px;
  background: #fff; font-size: 11px; color: #2e424c; min-width: 110px; }
.lc-selects .button { min-height: 28px; }

.lc-block { margin-top: 16px; }
.lc-block[hidden] { display: none; }
.lc-block .section-heading h3 { margin: 0; font-size: 15px; }
.lc-block .section-heading small { color: #75838d; font-size: 11px; }
.lc-scroll { overflow-x: auto; border: 1px solid #dbe2e7; border-radius: 6px; background: #fff; }
.lc-table { width: 100%; min-width: 1180px; margin-top: 0; border-collapse: collapse; font-size: 11.5px; }
#lc-option-table { min-width: 1780px; }
.lc-table th, .lc-table td { padding: 7px 9px; border-bottom: 1px solid #e5eaed; text-align: left; vertical-align: top; }
.lc-table th { position: sticky; top: 0; z-index: 1; background: #f6f8f9; color: #65737c; font-size: 10px; font-weight: 800; white-space: nowrap; }
.lc-table tbody tr.lc-row:hover { background: #f4f8f6; }
.lc-table tbody tr.lc-row[hidden] { display: none; }
.lc-table td b { display: block; color: #172f3a; font-size: 12px; }
.lc-table td small { display: block; margin-top: 2px; color: #7a878f; font-size: 10px; }
.lc-table td strong { color: #172f3a; }
.lc-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 10px; word-break: break-all; }
.lc-actions { white-space: nowrap; }
.lc-actions .button { min-height: 26px; margin: 1px 3px 1px 0; padding: 3px 8px; font-size: 10.5px; }
.lc-actions .button[disabled] { opacity: .45; cursor: not-allowed; }

.lc-status { display: inline-block; padding: 2px 7px; border-radius: 4px; font-size: 10px; font-weight: 700; white-space: nowrap; }
.lc-status.is-pending { border: 1px solid #d8c59a; background: #fdf8ec; color: #8a6420; }
.lc-status.is-partial { border: 1px solid #b9cfe4; background: #eef5fb; color: #2b5f8a; }
.lc-status.is-cancelled { border: 1px solid #d5dbe0; background: #f2f4f5; color: #5d6a72; }
.lc-status.is-rejected { border: 1px solid #e3b9b9; background: #fdf1f1; color: #a33b3b; }
.lc-status.is-review { border: 1px solid #e0c9a8; background: #fdf6ec; color: #96632a; }
.lc-status.is-open { border: 1px solid #bcd6c6; background: #f2faf6; color: #176b4b; }
.lc-status.is-partial_closed { border: 1px solid #b9cfe4; background: #eef5fb; color: #2b5f8a; }
.lc-status.is-closed { border: 1px solid #d5dbe0; background: #f2f4f5; color: #5d6a72; }

/* R35 第一批-3：归属确认度标记 —— 历史事实保留，但不冒充本人持仓 */
.lc-ownership-flag { display: inline-block; margin-right: 5px; padding: 2px 7px; border-radius: 4px; font-size: 10px; font-weight: 700; white-space: nowrap; border: 1px solid #e3b9b9; background: #fdf1f1; color: #a33b3b; }
.lc-ownership-flag.is-soft { border: 1px solid #d8c59a; background: #fdf8ec; color: #8a6420; }
.lc-ownership-note { display: block; margin-top: 3px; color: #8a6420; font-size: 10px; line-height: 1.5; max-width: 220px; }

.lc-subtotal td { background: #eff4f1; border-top: 2px solid #cbd8d2; font-weight: 700; font-size: 11px; }
.lc-subtotal td small { font-weight: 400; }
.lc-empty td { padding: 18px 12px; color: #68757d; text-align: center; }
.lc-detail-row td { background: #f7f9fa; padding: 10px 12px; }
.lc-detail-row[hidden] { display: none; }
.lc-detail-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 6px 14px; margin: 0 0 8px; }
.lc-detail-grid > div { display: grid; gap: 2px; }
.lc-detail-grid dt { color: #7a878f; font-size: 10px; }
.lc-detail-grid dd { margin: 0; color: #2e424c; font-size: 11px; word-break: break-all; }
.lc-detail-grid dd small { display: block; color: #8b959e; font-size: 9.5px; }
.lc-sub-table { min-width: 900px; margin-top: 6px; font-size: 10.5px; }
.lc-sub-table th { position: static; }
.lc-legs { margin-top: 6px; }
.lc-legs-title { margin: 8px 0 2px; font-size: 11px; font-weight: 700; color: #4c565e; }

@media (max-width: 900px) {
  .lc-selects { gap: 6px 8px; }
  .lc-selects select, .lc-selects input { min-width: 96px; }
}

/* ============================================================
   R35 第二批：按笔归仓（首页原地展开账户 / 买入批次）
   ============================================================ */
.dash-expand-row > td { background: #f4f8f6; padding: 10px 14px; }
.dash-expand-row[hidden] { display: none; }
.dash-batch-expand { display: grid; gap: 8px; }
.dash-expand-title { margin: 0; font-size: 12px; font-weight: 700; color: #2e424c; }
.dash-batch-table { width: 100%; border-collapse: collapse; font-size: 11px; background: #fff; }
.dash-batch-table th, .dash-batch-table td { border: 1px solid #dde5e1; padding: 5px 7px; text-align: left; vertical-align: top; }
.dash-batch-table th { background: #eef3f1; font-size: 10px; color: #4c565e; white-space: nowrap; }
.dash-batch-detail-row td { background: #fbfdfc; }
.dash-batch-detail-row[hidden] { display: none; }
.dash-bucket-badge { display: inline-block; padding: 1px 6px; border-radius: 3px; font-size: 10px; font-weight: 700; border: 1px solid #c8d6cf; background: #eef3f1; color: #35505c; }
.dash-bucket-editor { display: grid; gap: 6px; padding: 8px 10px; border: 1px dashed #b9c9c0; background: #fbfdfc; }
.dash-bucket-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.dash-bucket-form select { min-width: 220px; padding: 4px 6px; font-size: 11px; }
.dash-batch-history { margin: 4px 0 0; padding-left: 18px; font-size: 10.5px; color: #4c565e; }
.dash-batch-history li { margin-bottom: 2px; }
.dash-act.dash-batch-expand { white-space: nowrap; }
/* R36 #296B：持仓页「调整归仓」入口 + 弹窗面板 */
.xp-bucket-btn { margin-top: 6px; width: 100%; }
.xp-bucket-panel { display: grid; gap: 8px; }
.xp-bucket-panel .dash-bucket-editor { margin-top: 4px; }
.lc-history-toggle-wrap { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 10px 0 4px; }
.lc-history-toggle-wrap small { color: #8b959e; font-size: 10.5px; line-height: 1.5; }

/* ---- R37 #311 成交完整性核对 ---- */
.dash-completeness { margin-top: 18px; border: 1px solid #d7dde2; background: #fff; }
.dash-completeness-verdict { margin: 10px 12px 0; padding: 8px 11px; font-size: 12px;
  border-left: 4px solid #6b7782; background: #f6f8f9; color: #2c3a45; }
.dash-completeness-verdict.is-ok { border-left-color: #188754; background: #f0f7f3; }
.dash-completeness-verdict.is-gap { border-left-color: #b8342a; background: #fdf3f2; }
.dash-completeness-verdict.is-pending { border-left-color: #e4ab22; background: #fff8df; }
.dash-completeness-verdict.is-unknown { border-left-color: #6b7782; background: #f1f4f6; }
.dash-completeness-note { margin: 6px 12px 0; font-size: 10.5px; color: #6b7782; line-height: 1.7; }
.dash-completeness-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px; background: #dfe4e8; margin: 10px 12px 0; border: 1px solid #dfe4e8; }
.dash-completeness-grid article { background: #fff; padding: 9px 11px; }
.dash-completeness-grid span { display: block; font-size: 10.5px; color: #6b7782; }
.dash-completeness-grid strong { display: block; margin: 4px 0 3px; font-size: 13px;
  font-variant-numeric: tabular-nums; }
.dash-completeness-grid small { display: block; font-size: 9.5px; color: #8b959e; line-height: 1.6; }
@media (max-width: 1180px) { .dash-completeness-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.dash-completeness-table { border-collapse: collapse; width: calc(100% - 24px); margin: 10px 12px 0;
  font-size: 10.5px; }
.dash-completeness-table caption { text-align: left; font-size: 10.5px; color: #6b7782;
  padding: 0 0 4px; }
.dash-completeness-table th, .dash-completeness-table td { padding: 3px 7px; text-align: center;
  border-bottom: 1px solid #edf0f2; white-space: nowrap; }
.dash-completeness-table thead th { background: #f0f4f2; font-size: 9.5px; color: #5d6870; }
.dash-completeness-table .num { font-variant-numeric: tabular-nums; }
.dash-completeness-table code { font-size: 9.5px; background: #f1f4f6; padding: 1px 4px;
  border-radius: 3px; color: #3b4a56; }
.dash-completeness-symbols, .dash-completeness-reason { text-align: left; white-space: normal;
  font-size: 10px; color: #5d6870; }
.dash-completeness-table tr.dash-completeness-not_user_owned td { background: #fbfcfc; color: #8b959e; }
.dash-completeness-table tr.dash-completeness-pending_review td { background: #fff8df; }
.dash-completeness-table tr.dash-completeness-truly_missing td { background: #fdf3f2; }
.dash-completeness-groups { margin: 10px 12px 12px; border: 1px solid #e1e5e8; background: #fbfcfc; }
.dash-completeness-groups > summary { cursor: pointer; padding: 7px 11px; font-size: 11.5px;
  font-weight: 700; color: #22303a; }
.dash-completeness-groups .dash-completeness-table { width: 100%; margin: 0 0 8px; }

/* R403-M M2：保证金确认（弹窗 + 审批卡）与 LEVEL5 阻断提示 */
.pt-margin-confirm { border: 1px solid #c9a227; background: #fffdf5; margin: 10px 0; padding: 8px 12px; }
.pt-margin-confirm > legend { font-weight: 700; color: #7a5c00; padding: 0 6px; }
.pt-margin-summary { display: grid; grid-template-columns: repeat(3, minmax(120px, 1fr)); gap: 4px 14px; margin: 6px 0; }
.pt-margin-summary div { display: flex; gap: 6px; }
.pt-margin-summary dt { color: #6b7680; font-size: 12px; }
.pt-margin-summary dd { margin: 0; font-weight: 600; font-size: 12.5px; }
.pt-margin-warn { color: #8a6d00; font-size: 12.5px; margin: 4px 0; }
.pt-margin-blocked { color: #a12622; background: #fdf3f2; border: 1px solid #e5b7b3;
  padding: 6px 9px; font-size: 12.5px; font-weight: 600; margin: 6px 0; }
.pt-margin-check { display: block; margin: 5px 0; font-size: 13px; }
.mc-status { color: #6b7680; font-size: 12px; margin: 4px 0 0; }

/* R403-N：最终提交确认摘要 + REAL 警示 + 真实执行结果横幅 */
/* 注意：`[hidden]` 的 UA `display:none` 会被上面的 `display:grid` 覆盖，
   因此必须显式声明 hidden 态，否则「隐藏」的摘要仍会显示成空壳。 */
.pt-confirm-summary[hidden], .pt-confirm-warning[hidden] { display: none !important; }
.pt-confirm-summary { display: grid; grid-template-columns: repeat(2, minmax(140px, 1fr));
  gap: 4px 16px; margin: 10px 0 6px; padding: 8px 12px; border: 1px solid #b9c6cf;
  background: #f4f8fa; }
.pt-confirm-summary div { display: flex; gap: 6px; }
.pt-confirm-summary dt { color: #5d6870; font-size: 12px; }
.pt-confirm-summary dd { margin: 0; font-weight: 700; font-size: 13px; color: #1d2b36; }
.pt-confirm-warning { color: #8a1f1a; background: #fdf3f2; border: 1px solid #e5b7b3;
  padding: 7px 10px; font-size: 12.5px; font-weight: 600; margin: 4px 0 8px; }
.reconciliation-banner-real { border-color: #c0392b; background: #fdf3f2; }
.reconciliation-banner-real strong { color: #8a1f1a; }

/* R404-4：CASH 卡分账户直显（不折叠） */
.dash-cash-accounts-direct { margin: 8px 0 0; padding: 8px 10px; border: 1px dashed #c7d2da;
  border-radius: 8px; background: #f7fafc; display: grid; gap: 3px; }
.dash-cash-accounts-direct .dash-cash-line { margin: 0; font-size: 12.5px; color: #22303a; }
.dash-cash-accounts-direct .dash-cash-total b { font-size: 14px; }
.dash-cash-accounts-direct .dash-neutral { color: #8a6d1a; font-weight: 600; }

/* R404-5：批量移仓条 */
.dash-bulk-bar { margin: 10px 0 6px; padding: 8px 10px; border: 1px solid #d5dee5; border-radius: 8px; }
.dash-bulk-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 4px 0 8px; }
.dash-bulk-controls select { font-size: 12.5px; padding: 3px 6px; }
.dash-bulk-out { display: grid; gap: 4px; }
.dash-bulk-preview-table { font-size: 12px; margin: 4px 0; }
.dash-bulk-preview-table th, .dash-bulk-preview-table td { padding: 3px 8px; }
.dash-bulk-status { border-top: 1px dashed #c7d2da; margin-top: 6px; padding-top: 6px; }

/* ===== R404.2 当前持仓策略分配 / 冲突裁决 ===== */
.alloc-target-table .alloc-input { width: 84px; padding: 4px 6px; border-radius: 6px;
  border: 1px solid var(--line, rgba(0,0,0,.15)); background: transparent; color: inherit; }
.alloc-target-result { display: block; margin-top: 4px; font-size: 12px; }
.alloc-target-result.is-error { color: #b42318; }
.alloc-target-result.is-ok { color: #067647; }
.alloc-conflict-actions { display: inline-flex; gap: 6px; flex-wrap: wrap; margin-left: 8px; }
.alloc-conflict-result { font-size: 12px; }
.alloc-slot { display: block; }
.alloc-needs-confirm { display: block; color: #b54708; }
.btn-mini { padding: 2px 8px; font-size: 12px; border-radius: 6px; cursor: pointer;
  border: 1px solid var(--line, rgba(0,0,0,.15)); background: transparent; color: inherit; }

/* R424 unified P/L: green profit, red loss, neutral zero. CSP-safe classes. */
.is-gain,.dash-gain,.perf-gain,.profit strong,.profit b {color:#1c8f5a !important}
.is-loss,.dash-loss,.perf-loss,.loss strong,.loss b {color:#b8342a !important}
.xp-pnl-gain {color:#1c8f5a !important}
.xp-pnl-loss {color:#b8342a !important}
.xp-pnl-zero {color:#6b7782 !important}

/* Underlying move compared with its own opening snapshot, not P/L sign. */
.xp-stock-up{color:#1c8f5a !important}.xp-stock-down{color:#b8342a !important}.xp-stock-neutral{color:#6b7782 !important}

/* R424.2 compact decision card, isolated to the option modal. */
#dash-spread-modal {padding:16px;align-items:center}
#dash-spread-modal .dash-modal-card {box-sizing:border-box;margin:0;width:min(1040px,calc(100vw - 32px));max-width:1040px;max-height:calc(100vh - 32px);display:flex;flex-direction:column;overflow:hidden;padding:16px 20px;font-size:12px}
#dash-spread-modal .dash-modal-head {flex:0 0 auto;margin-bottom:10px}
#dash-spread-modal .dash-modal-head h3 {font-size:18px;margin:0}
#dash-spread-modal .r424-scroll-body {min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:0 5px 0 0}
#dash-spread-modal .dash-modal-summary {display:grid;grid-template-columns:1fr 1fr;gap:5px 24px;padding:8px 12px;margin:0 0 10px}
#dash-spread-modal .dash-modal-summary div {font-size:12px;align-items:baseline;min-width:0}
#dash-spread-modal .dash-modal-summary dt {white-space:normal}
#dash-spread-modal .dash-modal-summary dd {white-space:nowrap}
#dash-spread-modal .r424-scroll-body>.dash-modal-summary:first-child>div:first-child {grid-column:1/-1}
#dash-spread-modal label {margin:6px 0 10px;gap:15px}
#dash-spread-modal input {font-size:13px;padding:7px 10px}
#dash-spread-modal .dash-modal-hint {font-size:11px;margin:7px 0;line-height:1.45}
#dash-spread-modal .dash-modal-note {font-size:11px;margin:6px 0;line-height:1.45}
#dash-spread-modal details {font-size:12px;margin:6px 0 10px}
#dash-spread-modal details p {margin:7px 0;line-height:1.5}
#dash-spread-modal .dash-modal-foot {flex:0 0 auto;margin-top:10px;padding-top:10px;border-top:1px solid #e4e9ec;background:#fff}
#dash-spread-modal .dash-modal-foot .button {font-size:13px;padding:8px 18px}
@media(max-width:640px){
 #dash-spread-modal {padding:8px}
 #dash-spread-modal .dash-modal-card {width:calc(100vw - 16px);max-height:calc(100vh - 16px);padding:12px}
 #dash-spread-modal .dash-modal-summary {grid-template-columns:1fr;gap:5px}
 #dash-spread-modal label {flex-direction:column;align-items:stretch;gap:5px}
 #dash-spread-modal .dash-modal-summary dd {white-space:normal;text-align:right}
}

/* Readable adjacent label/value pairs; never stretch them to opposite edges. */
#dash-spread-modal .dash-modal-summary {grid-template-columns:repeat(2,minmax(0,1fr));gap:6px 20px}
#dash-spread-modal .dash-modal-summary>div {display:flex;justify-content:flex-start;gap:10px;padding:3px 0;line-height:1.5}
#dash-spread-modal .dash-modal-summary dt {flex:0 0 144px;font-size:13px;color:#657581}
#dash-spread-modal .dash-modal-summary dd {margin:0;text-align:left;font-size:13px;font-weight:600;white-space:normal;overflow-wrap:anywhere}
#dash-spread-modal .r424-scroll-body>.dash-modal-summary:first-child>div:first-child dt {flex-basis:48px}
#dash-spread-modal .r424-analysis {padding:10px 12px;margin:0 0 8px;border:1px solid #dde5e9;border-radius:8px;background:#fff}
#dash-spread-modal .r424-analysis h4 {font-size:14px;margin:0 0 6px}
#dash-spread-modal .r424-analysis p {font-size:12px;line-height:1.65;margin:5px 0}
#dash-spread-modal label {justify-content:flex-start}
#dash-spread-modal label input {width:180px;max-width:100%}
@media(max-width:720px){
 #dash-spread-modal .dash-modal-summary {grid-template-columns:1fr}
 #dash-spread-modal .dash-modal-summary dt {flex-basis:144px}
 #dash-spread-modal .dash-modal-summary dd {text-align:left}
}
/* Content-width labels keep each value next to its own label. */
#dash-spread-modal .dash-modal-summary dt {flex:0 1 auto}
#dash-spread-modal .dash-modal-summary dd {flex:0 1 auto}
#dash-spread-modal .r424-scroll-body>.dash-modal-summary:first-child>div:first-child dt {flex-basis:auto}

/* R433：四仓恒等式自检 + 现金/融资口径说明 */
.allocation-identity { margin-top: 10px; padding: 12px 14px; border: 1px solid #dbe2e7; border-left: 3px solid #8da99a; border-radius: 6px; background: #fbfcfc; }
.allocation-identity[data-allocation-identity="mismatch"] { border-left-color: #c0562f; background: #fdf7f4; }
.allocation-identity[data-allocation-identity="unknown"] { border-left-color: #c1a04a; background: #fdfbf4; }
.allocation-identity .identity-head { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: baseline; }
.allocation-identity .identity-head strong { font-size: 13px; color: #2c3e46; }
.allocation-identity .identity-head span { color: #5f6e78; font-size: 12px; }
.allocation-identity[data-allocation-identity="mismatch"] .identity-head span { color: #a8451f; font-weight: 600; }
.allocation-identity .identity-parts { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 9px 0 6px; padding: 0; list-style: none; }
.allocation-identity .identity-parts li { display: flex; flex-direction: column; gap: 2px; }
.allocation-identity .identity-parts span { color: #7a8790; font-size: 11px; }
.allocation-identity .identity-parts b { color: #1f3b45; font-size: 14px; }
.allocation-identity .identity-parts small { color: #93a0a8; font-size: 10px; }
.allocation-identity .identity-formula { display: block; color: #83919a; font-size: 10px; line-height: 1.5; }
.financing-note { margin-top: 8px; }
