:root {
  --navy-950: #101d2e;
  --navy-900: #16263a;
  --navy-800: #21344c;
  --ink: #172335;
  --muted: #69778a;
  --line: #e2e7ed;
  --line-soft: #edf0f4;
  --surface: #ffffff;
  --background: #f3f5f7;
  --teal: #087d75;
  --teal-dark: #08675f;
  --teal-soft: #e9f5f2;
  --amber: #a66a13;
  --amber-soft: #fff5e5;
  --red: #c73f45;
  --red-soft: #fff0f0;
  --blue-soft: #edf3fa;
  --shadow: 0 3px 14px rgba(20, 35, 52, .045);
  --radius: 12px;
}

* { box-sizing: border-box; }
html { color-scheme: light; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--background);
  font-family: "Segoe UI", "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
button, input, select, textarea { font: inherit; }
button, input, select { outline: none; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, summary:focus-visible {
  outline: 3px solid rgba(8, 125, 117, .18);
  outline-offset: 2px;
}
svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

.topbar { background: var(--navy-950); color: #fff; border-bottom: 1px solid rgba(255,255,255,.07); }
.topbar-inner { max-width: 1720px; height: 70px; margin: 0 auto; padding: 0 28px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; min-width: 260px; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border: 1px solid rgba(255,255,255,.28); border-radius: 9px; color: #bce4dc; font-size: 19px; font-weight: 700; }
.brand strong { display: block; font-size: 16px; letter-spacing: .04em; }
.brand div span { display: block; margin-top: 3px; color: #8f9eb0; font-size: 8px; letter-spacing: .16em; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.privacy-badge { display: inline-flex; align-items: center; gap: 7px; margin-right: 8px; color: #a9b6c5; font-size: 12px; }
.privacy-badge i { width: 6px; height: 6px; border-radius: 50%; background: #5ab5a4; box-shadow: 0 0 0 3px rgba(90,181,164,.12); }
.button { min-height: 36px; padding: 8px 14px; display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid transparent; border-radius: 7px; font-weight: 600; font-size: 13px; transition: background .16s, border-color .16s, transform .16s; }
.button:active { transform: translateY(1px); }
.button:disabled { cursor: not-allowed; opacity: .45; }
.button-ghost { color: #d6dee7; border-color: #3b4a5d; background: transparent; }
.button-ghost:hover { background: rgba(255,255,255,.07); }
.button-primary { color: #fff; border-color: var(--teal); background: var(--teal); }
.button-primary:hover { background: var(--teal-dark); border-color: var(--teal-dark); }
.button-secondary { color: var(--ink); border-color: #ccd5df; background: #fff; }
.button-secondary:hover { background: #f5f7f9; }

.page-shell { max-width: 1720px; margin: 0 auto; padding: 30px 28px 40px; }
.page-heading { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; margin-bottom: 24px; }
.eyebrow { color: var(--teal); font-size: 10px; font-weight: 700; letter-spacing: .17em; }
h1, h2, h3, p { margin: 0; }
h1 { margin-top: 7px; font-size: 27px; line-height: 1.3; letter-spacing: -.02em; font-weight: 700; }
.page-heading p { margin-top: 8px; color: var(--muted); font-size: 13px; }
.source-chip { min-width: 270px; padding: 11px 14px; border-left: 3px solid var(--teal); background: #eaf0f1; border-radius: 0 7px 7px 0; }
.source-chip-label { display: block; margin-bottom: 4px; color: var(--muted); font-size: 10px; }
.source-chip strong { display: block; font-size: 13px; }
.source-chip > span:last-child { display: block; margin-top: 4px; color: #647483; font-size: 11px; }

.kpi-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi-card { min-width: 0; padding: 19px 20px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.kpi-featured { border-top: 3px solid var(--navy-800); padding-top: 17px; }
.kpi-label { display: flex; justify-content: space-between; align-items: center; gap: 8px; color: #566578; font-size: 12px; }
.kpi-label em { padding: 2px 6px; border-radius: 4px; background: var(--blue-soft); color: #426184; font-size: 9px; font-style: normal; font-weight: 600; }
.kpi-label em.neutral { color: #667487; background: #f0f2f5; }
.kpi-label em.teal { color: var(--teal); background: var(--teal-soft); }
.kpi-label em.amber { color: var(--amber); background: var(--amber-soft); }
.kpi-value { display: block; margin: 11px 0 13px; overflow: hidden; color: #14243a; font-family: "Segoe UI", Arial, sans-serif; font-size: clamp(24px, 2vw, 31px); line-height: 1.1; letter-spacing: -.035em; text-overflow: ellipsis; white-space: nowrap; font-variant-numeric: tabular-nums; }
.kpi-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #8390a0; font-size: 11px; }
.kpi-foot b { color: #5e6d7e; font-weight: 600; font-variant-numeric: tabular-nums; }
.kpi-foot b.positive, .positive { color: var(--teal); }
.kpi-foot b.negative, .negative { color: var(--red); }
.rate-track { position: relative; height: 5px; margin: -3px 0 11px; border-radius: 5px; background: #edf0f2; }
.rate-track i { display: block; height: 100%; width: 0; border-radius: 5px; background: var(--teal); transition: width .25s; }
.rate-track span { position: absolute; top: -3px; width: 2px; height: 11px; background: var(--amber); }

.workspace-grid { display: grid; grid-template-columns: 280px minmax(0, 1fr); align-items: start; gap: 18px; }
.card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.control-panel { padding: 20px; }
.panel-heading { display: flex; align-items: center; gap: 11px; }
.panel-heading h2 { font-size: 16px; line-height: 1.3; }
.panel-heading p { margin-top: 4px; color: var(--muted); font-size: 11px; }
.section-number { display: grid; place-items: center; flex: 0 0 auto; width: 29px; height: 29px; border: 1px solid #d7dfe6; border-radius: 6px; color: #607286; font-family: Consolas, monospace; font-size: 11px; }
.control-section { padding: 19px 0; border-bottom: 1px solid var(--line-soft); }
.control-section h3 { margin-bottom: 12px; color: #38495d; font-size: 12px; }
.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.field { display: block; margin-bottom: 11px; }
.field:last-child { margin-bottom: 0; }
.field > span { display: flex; justify-content: space-between; margin-bottom: 6px; color: #6e7c8d; font-size: 11px; }
.field small { color: #9aa5b2; font-size: 10px; }
.field input, select, .search-box input { width: 100%; border: 1px solid #d7dfe7; border-radius: 6px; background: #fff; color: var(--ink); transition: border-color .15s, box-shadow .15s; }
.field input { height: 35px; padding: 6px 9px; font-variant-numeric: tabular-nums; }
.field input:focus, select:focus, .search-box input:focus, textarea:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(8,125,117,.08); }
.input-suffix { position: relative; }
.input-suffix input { padding-right: 32px; }
.input-suffix i { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); color: #8995a3; font-size: 11px; font-style: normal; pointer-events: none; }
.section-title-row { display: flex; justify-content: space-between; align-items: center; }
.mini-tag { padding: 2px 6px; border-radius: 4px; background: #f0f3f5; color: #7d8996; font-size: 9px; }
.mode-switch { display: grid; grid-template-columns: 1fr 1fr; padding: 3px; border-radius: 7px; background: #edf0f3; }
.mode-switch label { position: relative; cursor: pointer; }
.mode-switch input { position: absolute; opacity: 0; pointer-events: none; }
.mode-switch span { display: block; padding: 7px 5px; border-radius: 5px; color: #758293; text-align: center; font-size: 12px; }
.mode-switch input:checked + span { background: #fff; color: var(--navy-800); box-shadow: 0 1px 4px rgba(19,35,52,.12); font-weight: 600; }
.mode-description { min-height: 32px; margin: 10px 0 12px; color: #7a8795; font-size: 11px; line-height: 1.5; }
.target-field { margin-top: 2px; }
.target-range { width: 100%; height: 4px; margin: 6px 0 0; appearance: none; border-radius: 4px; background: #dde5e8; accent-color: var(--teal); }
.target-range::-webkit-slider-thumb { width: 14px; height: 14px; appearance: none; border: 3px solid #fff; border-radius: 50%; background: var(--teal); box-shadow: 0 0 0 1px var(--teal); cursor: pointer; }
.range-labels { display: flex; justify-content: space-between; margin-top: 7px; color: #a0aab5; font-size: 9px; }
.switch-section { padding-bottom: 12px; }
.switch-row { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 16px; cursor: pointer; }
.switch-row strong { display: block; color: #3c4b5c; font-size: 12px; font-weight: 600; }
.switch-row small { display: block; margin-top: 4px; color: #8a96a4; font-size: 10px; }
.switch-row input { position: absolute; right: 0; opacity: 0; }
.switch-row > i { position: relative; flex: 0 0 auto; width: 32px; height: 18px; border-radius: 20px; background: #cfd6dd; transition: background .18s; }
.switch-row > i::after { content: ""; position: absolute; top: 3px; left: 3px; width: 12px; height: 12px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.18); transition: transform .18s; }
.switch-row input:checked + i { background: var(--teal); }
.switch-row input:checked + i::after { transform: translateX(14px); }
.switch-row input:focus-visible + i { outline: 3px solid rgba(8,125,117,.18); outline-offset: 2px; }
.solver-box { margin-top: 16px; padding: 12px; border: 1px solid #d9e9e6; border-radius: 7px; background: #f1f8f6; }
.solver-box > div { display: flex; align-items: center; gap: 7px; }
.solver-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--teal); }
.solver-box strong { color: var(--teal-dark); font-size: 11px; }
.solver-box p { margin-top: 6px; color: #638079; font-size: 10px; line-height: 1.55; }
.solver-box.warning { border-color: #efdcbf; background: #fff8ec; }
.solver-box.warning .solver-dot { background: var(--amber); }
.solver-box.warning strong { color: var(--amber); }
.solver-box.warning p { color: #94764c; }
.panel-note { display: flex; align-items: flex-start; gap: 8px; margin-top: 16px; color: #8491a0; }
.panel-note svg { flex: 0 0 auto; width: 15px; height: 15px; margin-top: 1px; }
.panel-note p { font-size: 10px; line-height: 1.65; }

.content-column { min-width: 0; }
.table-card { overflow: hidden; }
.table-toolbar { position: relative; min-height: 75px; padding: 17px 18px; display: flex; justify-content: space-between; align-items: center; gap: 16px; border-bottom: 1px solid var(--line-soft); }
.panel-heading.compact .section-number { width: 27px; height: 27px; }
.table-tools { display: flex; align-items: center; gap: 8px; }
.filter-toggle { height: 34px; padding: 0 12px; white-space: nowrap; font-size: 11px; }
.filter-panel { position: absolute; right: 18px; top: 62px; z-index: 30; display: flex; align-items: flex-end; gap: 12px; padding: 12px 14px; border: 1px solid #e3e8ee; border-radius: 10px; background: #fff; box-shadow: 0 12px 28px rgba(22, 38, 58, .14); }
.filter-panel[hidden] { display: none; }
.filter-panel label { display: flex; flex-direction: column; gap: 4px; color: #748191; font-size: 10px; }
.filter-panel select { width: 130px; height: 32px; font-size: 11px; }
.filter-panel .button { height: 32px; padding: 0 10px; font-size: 11px; }
.table-tools { flex-wrap: wrap; }
.position-tier-box summary { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #33424f; font-size: 12px; font-weight: 600; cursor: pointer; list-style: none; }
.position-tier-box summary::-webkit-details-marker { display: none; }
.position-tier-box summary small { color: #98a4b1; font-size: 10px; font-weight: 400; }
.position-tier-list { display: flex; flex-direction: column; gap: 6px; max-height: 210px; margin-top: 10px; overflow-y: auto; padding-right: 2px; }
.position-tier-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.position-tier-row > span { min-width: 0; overflow: hidden; color: #5a6879; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.position-tier-row select { flex: 0 0 auto; width: 118px; height: 28px; font-size: 11px; }
.type-badge.tier { border-color: #dde5ec; background: #f4f7fa; color: #5a6879; }
.type-badge.full-rate { border-color: #bfe3d5; background: #e9f7f1; color: #16795c; }
th.filterable { white-space: nowrap; }
.th-filter { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; margin-left: 4px; padding: 0; border: 1px solid transparent; border-radius: 3px; background: transparent; color: #98a4b1; cursor: pointer; vertical-align: middle; }
.th-filter svg { width: 10px; height: 10px; fill: currentColor; }
.th-filter:hover { border-color: #d7e0e8; color: #33424f; }
.th-filter.active { border-color: #13907a; background: #e9f7f1; color: #0f7f61; }
.header-filter-popover { position: fixed; z-index: 60; width: 208px; padding: 10px; border: 1px solid #dde5ec; border-radius: 10px; background: #fff; box-shadow: 0 12px 30px rgba(22, 42, 62, .14); }
.popover-title { margin-bottom: 6px; color: #33424f; font-size: 11px; font-weight: 600; }
.popover-options { display: flex; flex-direction: column; gap: 2px; max-height: 248px; overflow-y: auto; }
.popover-option { padding: 7px 9px; border: 0; border-radius: 6px; background: transparent; color: #5a6879; font-size: 11px; text-align: left; cursor: pointer; }
.popover-option:hover { background: #f2f6f9; color: #1d2b38; }
.popover-option.active { background: #e9f7f1; color: #0f7f61; font-weight: 600; }
.tier-cell { padding-top: 4px; padding-bottom: 4px; white-space: nowrap; }
.tier-cell .tier-select { width: auto; max-width: 100px; vertical-align: middle; }
.tier-select { min-width: 86px; height: 26px; padding: 0 4px; border: 1px solid #dde5ec; border-radius: 6px; background: #fff; color: #33424f; font-size: 11px; cursor: pointer; }
.tier-select:focus { border-color: #13907a; outline: none; }
.tier-edit { width: 22px; height: 22px; margin-left: 3px; padding: 0; border: 1px solid #dde5ec; border-radius: 5px; background: #fff; color: #5a6879; font-size: 10px; line-height: 1; cursor: pointer; vertical-align: middle; }
.tier-edit:hover { border-color: #13907a; color: #0f7f61; }
.custom-base-dialog { position: fixed; inset: 0; z-index: 80; display: flex; align-items: center; justify-content: center; padding: 20px; background: rgba(16, 28, 40, .35); }
.custom-base-dialog[hidden] { display: none; }
.dialog-card { width: 300px; max-width: 100%; padding: 18px; border-radius: 12px; background: #fff; box-shadow: 0 20px 50px rgba(16, 32, 48, .24); }
.dialog-title { margin-bottom: 12px; color: #1d2b38; font-size: 14px; font-weight: 600; }
.dialog-hint { margin: 8px 0 14px; color: #8b98a6; font-size: 10px; line-height: 1.6; }
.dialog-actions { display: flex; justify-content: flex-end; gap: 8px; }
td.position-cell { max-width: 150px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.search-box { position: relative; display: block; }
.search-box svg { position: absolute; top: 9px; left: 9px; width: 15px; height: 15px; color: #8b98a6; }
.search-box input { width: 180px; height: 34px; padding: 6px 9px 6px 31px; font-size: 11px; }
select { width: 125px; height: 34px; padding: 5px 25px 5px 9px; color: #5a6879; font-size: 11px; }
.validation-bar { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--line-soft); background: #fafbfc; }
.validation-bar > div { min-width: 0; padding: 10px 13px; display: flex; align-items: center; gap: 6px; border-right: 1px solid var(--line-soft); white-space: nowrap; }
.validation-bar > div:last-child { border-right: 0; }
.validation-bar i { flex: 0 0 auto; width: 6px; height: 6px; border-radius: 50%; background: var(--teal); }
.validation-bar span { color: #7b8794; font-size: 10px; }
.validation-bar strong { margin-left: auto; overflow: hidden; color: #46645f; font-size: 10px; font-weight: 600; text-overflow: ellipsis; }
.validation-bar .warning i { background: var(--amber); }
.validation-bar .warning strong { color: var(--amber); }
.validation-bar .danger i { background: var(--red); }
.validation-bar .danger strong { color: var(--red); }
.table-scroll { position: relative; max-height: 660px; overflow: auto; scrollbar-color: #c3ced7 #f4f6f8; scrollbar-width: thin; }
table { width: 100%; min-width: 2080px; border-collapse: separate; border-spacing: 0; color: #465569; font-size: 11px; font-variant-numeric: tabular-nums; }
th, td { padding: 9px 11px; border-bottom: 1px solid var(--line-soft); background: #fff; text-align: left; white-space: nowrap; }
thead th { position: sticky; z-index: 4; }
.group-row th { top: 0; height: 34px; padding-top: 7px; padding-bottom: 7px; color: #617185; background: #f4f6f8; border-bottom: 1px solid #dfe5eb; font-size: 10px; font-weight: 600; letter-spacing: .04em; }
.group-row .group-raw { color: #5c6f85; background: #eef2f6; }
.group-row .group-pre { color: #776440; background: #f8f3e9; }
.group-row .group-new { color: #286a64; background: #eaf4f2; }
.column-row th { top: 34px; z-index: 5; height: 39px; color: #758292; background: #fbfcfd; border-bottom: 1px solid #dfe5eb; font-size: 10px; font-weight: 500; }
.column-row th.highlight { color: var(--teal); background: #f0f8f6; }
th.number, td.number { text-align: right; }
tbody tr:hover td { background: #f8fafb; }
tbody tr.annualized-row td:first-child { box-shadow: inset 2px 0 #c69a4c; }
tbody tr.issue-row td { background: #fffdf8; }
tbody tr.negative-row td { background: #fff7f7; }
tbody tr.negative-row:hover td { background: #fff2f2; }
td { height: 46px; }
td.sticky-name, th.sticky-name { position: sticky; left: 0; z-index: 3; min-width: 96px; border-right: 1px solid #e7ebef; box-shadow: 5px 0 7px -7px rgba(20,35,52,.35); }
thead th.sticky-name { z-index: 7; background: #f7f9fa; }
.person-name { color: #25384c; font-weight: 600; }
.person-meta { display: block; margin-top: 2px; color: #96a1ad; font-size: 9px; font-weight: 400; }
.type-badge { display: inline-flex; align-items: center; padding: 2px 6px; border-radius: 4px; background: #f0f2f4; color: #748191; font-size: 9px; }
.type-badge.new { color: #946518; background: #fff3df; }
.type-badge.full-rate { margin-left: 4px; color: #1d6f68; background: #e4f4ef; font-weight: 600; }
.type-badge.tier { margin-left: 4px; color: #5a6b7d; background: #eef2f7; }
.base-cell { color: #1d6f68; background: #f4faf8 !important; font-weight: 600; }
.muted-cell { color: #8b96a2; }
.warning-text { color: var(--amber); }
.danger-text { color: var(--red); font-weight: 600; }
.cell-note { display: inline-block; margin-left: 4px; color: var(--amber); cursor: help; font-size: 10px; }
.amount-sub { display: block; margin-top: 2px; color: #98a4b1; font-size: 9px; font-weight: 400; white-space: nowrap; }
td.base-cell .amount-sub, tfoot .amount-sub { color: #93a5a1; }
tfoot td { position: sticky; bottom: 0; z-index: 3; height: 42px; color: #3e5064; background: #f3f6f8; border-top: 1px solid #dbe3e9; border-bottom: 0; font-weight: 600; }
tfoot td.sticky-name { z-index: 4; background: #f3f6f8; }
.empty-state { padding: 50px 20px; color: #8b96a2; text-align: center; }
.table-footer { min-height: 41px; padding: 11px 17px; display: flex; align-items: center; justify-content: space-between; gap: 15px; color: #8c98a5; background: #fbfcfd; font-size: 10px; }
.legend { display: flex; align-items: center; gap: 14px; }
.legend span { display: flex; align-items: center; gap: 5px; }
.legend i { width: 7px; height: 7px; border-radius: 2px; }
.legend-new { background: #d4aa67; }
.legend-warning { background: #f2d8aa; }
.legend-danger { background: #edb6b8; }
.notes-card { margin-top: 14px; overflow: hidden; }
.notes-card summary { padding: 15px 18px; display: flex; align-items: center; gap: 12px; cursor: pointer; list-style: none; }
.notes-card summary::-webkit-details-marker { display: none; }
.notes-card summary::after { content: "+"; margin-left: auto; color: #8693a1; font-size: 18px; font-weight: 300; }
.notes-card[open] summary::after { content: "−"; }
.notes-card summary span { color: #44566b; font-size: 12px; font-weight: 600; }
.notes-card summary small { color: #929da9; font-size: 10px; }
.notes-content { padding: 0 18px 18px; display: grid; grid-template-columns: 1fr 1fr; gap: 28px; border-top: 1px solid var(--line-soft); }
.notes-content > div { padding-top: 16px; }
.notes-content h3 { margin-bottom: 9px; color: #4f6072; font-size: 11px; }
.notes-content ul { margin: 0; padding-left: 16px; color: #7a8794; font-size: 10px; line-height: 1.8; }
.notes-content b { color: #566779; }
.page-footer { padding: 0 28px 25px; color: #929ca8; text-align: center; font-size: 10px; }

.import-dialog { width: min(820px, calc(100vw - 32px)); max-height: calc(100vh - 40px); padding: 0; overflow: hidden; border: 0; border-radius: 14px; color: var(--ink); background: #fff; box-shadow: 0 24px 70px rgba(9,24,40,.26); }
.import-dialog::backdrop { background: rgba(12,25,39,.56); backdrop-filter: blur(2px); }
.dialog-header { padding: 22px 24px 18px; display: flex; justify-content: space-between; gap: 20px; border-bottom: 1px solid var(--line-soft); }
.dialog-header h2 { margin-top: 5px; font-size: 20px; }
.dialog-header p { margin-top: 6px; color: var(--muted); font-size: 11px; }
.icon-button { width: 32px; height: 32px; border: 0; border-radius: 6px; color: #7f8c9a; background: #f2f4f6; font-size: 22px; line-height: 1; }
.icon-button:hover { background: #e8ecef; }
.dialog-body { padding: 19px 24px; overflow: auto; }
.import-options { display: flex; align-items: center; gap: 18px; margin-bottom: 12px; }
.import-options .field { flex: 0 0 160px; margin: 0; }
.import-tip { color: #7e8b99; font-size: 11px; line-height: 1.6; }
#pasteInput { width: 100%; height: 240px; padding: 12px; resize: vertical; border: 1px solid #d6dfe7; border-radius: 7px; color: #35485c; background: #fbfcfd; font-family: Consolas, "Microsoft YaHei", monospace; font-size: 11px; line-height: 1.6; }
.parse-report { max-height: 180px; margin-top: 12px; padding: 12px; overflow: auto; border-radius: 7px; background: #f3f6f8; color: #657587; font-size: 11px; line-height: 1.7; }
.parse-report .report-title { margin-bottom: 5px; color: #2d4c48; font-weight: 600; }
.parse-report .mapping-list { color: #55716c; }
.parse-report .report-warning { margin-top: 6px; color: var(--amber); }
.parse-report .report-error { color: var(--red); }
.muted { color: #8d99a6; }
.dialog-footer { padding: 15px 24px; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-top: 1px solid var(--line-soft); background: #fafbfc; }
.dialog-footer > span { color: #8995a2; font-size: 10px; }
.dialog-footer > div { display: flex; gap: 8px; }
.toast { position: fixed; right: 24px; bottom: 24px; z-index: 100; max-width: 380px; padding: 12px 16px; border-radius: 8px; color: #fff; background: var(--navy-900); box-shadow: 0 10px 35px rgba(16,29,46,.22); font-size: 12px; line-height: 1.5; opacity: 0; transform: translateY(12px); pointer-events: none; transition: opacity .2s, transform .2s; }
.toast.show { opacity: 1; transform: translateY(0); }
.toast.error { background: #a6383e; }

@media (max-width: 1250px) {
  .privacy-badge { display: none; }
  .workspace-grid { grid-template-columns: 250px minmax(0, 1fr); }
  .control-panel { padding: 16px; }
  .table-toolbar { align-items: flex-start; flex-direction: column; }
  .table-tools { width: 100%; }
  .search-box { flex: 1; }
  .search-box input { width: 100%; }
  .validation-bar { grid-template-columns: 1fr 1fr; }
  .validation-bar > div:nth-child(2) { border-right: 0; }
  .validation-bar > div:nth-child(-n+2) { border-bottom: 1px solid var(--line-soft); }
}
@media (max-width: 900px) {
  .topbar-inner { height: auto; min-height: 66px; padding: 12px 18px; }
  .brand { min-width: 0; }
  .brand div span { display: none; }
  .topbar-actions #resetData { display: none; }
  .page-shell { padding: 22px 18px 30px; }
  .page-heading { align-items: flex-start; flex-direction: column; gap: 16px; }
  .source-chip { width: 100%; }
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .workspace-grid { grid-template-columns: 1fr; }
  .control-panel { display: grid; grid-template-columns: 1fr 1fr; gap: 0 24px; }
  .control-panel > .panel-heading, .control-panel > .solver-box, .control-panel > .panel-note { grid-column: 1 / -1; }
  .control-section:nth-of-type(2) { border-bottom: 1px solid var(--line-soft); }
  .notes-content { grid-template-columns: 1fr; gap: 0; }
}
@media (max-width: 600px) {
  .brand strong { font-size: 14px; }
  .brand-mark { width: 32px; height: 32px; }
  .topbar-actions .button { padding: 7px 10px; font-size: 11px; }
  h1 { font-size: 23px; }
  .kpi-grid { grid-template-columns: 1fr; }
  .control-panel { display: block; }
  .table-tools { align-items: stretch; flex-direction: column; }
  select { width: 100%; }
  .validation-bar { grid-template-columns: 1fr; }
  .validation-bar > div { border-right: 0; border-bottom: 1px solid var(--line-soft); }
  .table-footer { align-items: flex-start; flex-direction: column; }
  .legend { flex-wrap: wrap; gap: 8px 12px; }
  .dialog-header, .dialog-body, .dialog-footer { padding-left: 16px; padding-right: 16px; }
  .import-options { align-items: flex-start; flex-direction: column; }
  .import-options .field { width: 100%; flex-basis: auto; }
  .dialog-footer { align-items: flex-start; flex-direction: column; }
  .dialog-footer > div { width: 100%; }
  .dialog-footer .button { flex: 1; }
}
