:root {
  font-family: "Segoe UI", "Microsoft YaHei", Arial, sans-serif;
  color: #24344b;
  background: #edf1f7;
  font-size: 14px;
  letter-spacing: 0;
  --ink: #24344b;
  --muted: #78869a;
  --line: #e0e6ef;
  --blue: #235fc1;
  --rail: #163f84;
}
* { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
#root { min-height: 100vh; display: flex; flex-direction: column; }
.copyright { margin-top: auto; padding: 18px 20px; text-align: center; font-size: 11px; line-height: 1.7; color: #78869a; background: #edf1f7; overflow-wrap: anywhere; }
.login-shell { display: flex; flex-direction: column; }
.shell { flex: 1; }
.row-choice { display: flex; flex-direction: row; align-items: center; justify-content: center; gap: 8px; color: inherit; font-size: inherit; cursor: pointer; }
.row-choice input { margin: 0; flex-shrink: 0; height: 17px; padding: 0; }
.row-choice span { min-width: 24px; }
.results-actions { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 10px; }
.selection-count { font-size: 12px; color: #31598f; }
.selected-row td { background: #e8f0ff; }
button, input, select, textarea { font: inherit; letter-spacing: 0; }
button { display: inline-flex; align-items: center; justify-content: center; gap: 7px; min-height: 36px; padding: 7px 12px; color: var(--ink); background: white; border: 1px solid #d8e0eb; border-radius: 4px; cursor: pointer; white-space: nowrap; }
button:hover:not(:disabled) { background: #f0f5fd; border-color: #a9bfdf; }
button:disabled { cursor: default; opacity: .45; }
button:focus-visible, a:focus-visible { outline: 3px solid #f1b24b; outline-offset: 2px; }
input, select, textarea { width: 100%; min-width: 0; min-height: 37px; padding: 7px 10px; color: var(--ink); background: white; border: 1px solid #d6deea; border-radius: 4px; }
input:focus, select:focus { outline: 2px solid #d2e3ff; border-color: var(--blue); }
input[type=checkbox] { width: 17px; min-height: 17px; accent-color: var(--blue); }
label { display: flex; flex-direction: column; gap: 7px; min-width: 0; color: #65758c; font-size: 12px; }
svg { width: 17px; height: 17px; flex-shrink: 0; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 23px; font-weight: 650; line-height: 1.35; }
h2 { font-size: 18px; line-height: 1.4; }
small { font-size: 12px; color: var(--muted); }
.primary { color: white; background: var(--blue); border-color: var(--blue); }
.primary:hover:not(:disabled) { background: #1a4e9f; border-color: #1a4e9f; }
.icon { width: 35px; height: 35px; padding: 0; }
.topbar { position: sticky; top: 0; z-index: 50; display: grid; grid-template-columns: 230px minmax(0,1fr) auto; align-items: center; height: 76px; background: white; border-bottom: 1px solid var(--line); box-shadow: 0 2px 8px #1c397405; padding-right: 25px; }
.brand { display: flex; align-items: center; gap: 9px; height: 76px; width: 230px; padding: 13px 15px; border-right: 1px solid var(--line); }
.brand-logo { width: 94px; height: 38px; object-fit: contain; flex-shrink: 0; }
.brand strong { font-size: 16px; color: #11447d; white-space: nowrap; }
.brand small { display: block; font-size: 9px; margin-top: 4px; color: #71849f; }
.workspace-heading { display: flex; align-items: center; gap: 9px; padding-left: 26px; color: #6b7c96; font-size: 13px; }
.workspace-heading svg { color: #2b62b3; }
.top-actions { display: flex; align-items: center; gap: 11px; }
.language { display: flex; border: 1px solid var(--line); border-radius: 4px; overflow: hidden; flex-shrink: 0; }
.language button { border: 0; border-radius: 0; font-size: 12px; min-height: 30px; padding: 5px 9px; }
.language .selected { color: #2456a4; background: #eaf1fc; font-weight: 650; }
.divider { width: 1px; height: 24px; background: var(--line); margin: 0 3px; }
.identity { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.identity>span { max-width: 145px; overflow: hidden; text-overflow: ellipsis; }
.avatar { display: grid; place-items: center; width: 31px; height: 31px; background: #fff1de; color: #b97923; border-radius: 50%; font-size: 11px; font-weight: 700; }
.shell { display: grid; grid-template-columns: 230px minmax(0,1fr); min-height: calc(100vh - 76px); background: var(--rail); }
.sidebar { display: flex; flex-direction: column; gap: 6px; position: sticky; top: 76px; align-self: start; height: calc(100vh - 76px); padding: 25px 13px 18px; overflow: auto; background: var(--rail); color: white; }
.nav-label { color: #a5bde3; font-size: 10px; padding: 0 13px; margin: 1px 0 11px; }
.nav-item { justify-content: flex-start; gap: 11px; flex-shrink: 0; padding: 11px 13px; min-height: 43px; width: 100%; background: none; border: 0; color: #d9e7ff; border-radius: 4px; font-size: 13px; }
.nav-item:hover:not(:disabled) { color: white; background: #245399; }
.nav-item.active { background: #285bb0; color: white; font-weight: 600; }
.nav-item svg { width: 18px; height: 18px; opacity: .85; }
.nav-item .nav-chevron { margin-left: auto; width: 13px; height: 13px; transform: rotate(90deg); }
.member-navigation { margin: 2px 0 10px; padding: 9px 0 7px; border-left: 1px solid #456aa0; margin-left: 22px; }
.member-nav-label { color: #a9bfdf; font-size: 10px; padding: 0 18px 8px; }
.member-link { justify-content: flex-start; gap: 10px; flex-wrap: wrap; width: 100%; min-height: 37px; color: #d4e3fa; background: none; border: 0; border-radius: 0 4px 4px 0; padding: 8px 17px; font-size: 13px; }
.member-link:hover:not(:disabled) { background: #245399; color: white; }
.member-link.active { background: #f1f5ff; color: #204c99; font-weight: 700; box-shadow: inset 3px 0 #f2a144; }
.member-link.active:hover { background: #f1f5ff; color: #204c99; }
.member-link small { display: block; width: 100%; padding-left: 16px; color: inherit; font-weight: 400; overflow-wrap: anywhere; white-space: normal; }
.member-name { flex: 1; min-width: 0; overflow-wrap: anywhere; white-space: normal; text-align: left; }
.member-node { width: 5px; height: 5px; background: currentColor; border-radius: 50%; opacity: .7; flex-shrink: 0; }
.nav-separator { height: 1px; background: #42649b; margin: 14px 12px; flex-shrink: 0; }
.side-bottom { margin-top: auto; color: #c1d3ee; border-top: 1px solid #42649b; padding: 20px 12px 0; font-size: 11px; line-height: 1.7; }
.side-bottom small { display: block; color: #a5bde3; margin-top: 4px; font-size: 10px; }
.dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 7px; background: #65d9c4; }
.main { min-width: 0; padding: 24px 26px 30px; background: #edf1f7; }
.page-title { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 21px; }
.eyebrow { display: flex; align-items: center; gap: 9px; font-size: 10px; color: #8794a8; margin-bottom: 6px; }
.eyebrow span { color: #a8b3c3; }
.heading-line { display: flex; align-items: center; gap: 13px; flex-wrap: wrap; }
.current-member { display: flex; align-items: center; gap: 6px; border-left: 1px solid #c6d2e3; padding-left: 13px; color: #2b5ba5; font-size: 14px; font-weight: 600; }
.current-member svg { width: 14px; height: 14px; }
.current-member { max-width: 100%; min-width: 0; }
.current-member > span { min-width: 0; overflow-wrap: anywhere; }
.title-actions { display: flex; align-items: center; gap: 12px; }
.metrics { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 16px; margin-bottom: 22px; }
.metric { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 105px; padding: 18px 19px; border-radius: 5px; color: white; position: relative; overflow: hidden; }
.metric.blue { background: #2c74ce; }
.metric.orange { background: #df8a24; }
.metric.teal { background: #159b99; }
.metric.rose { background: #b25481; }
.metric-copy { min-width: 0; position: relative; z-index: 1; }
.metric-copy>span { display: block; font-size: 12px; line-height: 1.5; color: #fff; }
.metric-value { display: flex; align-items: baseline; flex-wrap: wrap; column-gap: 7px; margin-top: 9px; }
.metric-value strong { font-size: 29px; line-height: 1.1; font-weight: 600; overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
.metric-value small { color: #fff; opacity: .9; font-size: 11px; }
.metric-icon { width: 40px; height: 40px; opacity: .3; flex-shrink: 0; }
.filters { background: #fff; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 18px 18px 19px; }
.filter-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 15px 16px; align-items: end; }
.warehouse-filters .filter-grid { grid-template-columns: minmax(180px,1.2fr) minmax(290px,1.5fr) auto; }
.date-pair { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; grid-column: span 2; }
.warehouse-filters .date-pair { grid-column: auto; }
.filter-actions { display: flex; justify-content: flex-end; gap: 8px; align-items: end; min-height: 37px; }
.filter-actions>button { min-height: 37px; }
.filter-actions>button:first-child { width: 37px; padding: 0; }
.all-filters .filter-actions { grid-column: 1 / -1; }
#results { margin-top: 20px; background: white; }
.results-meta { display: flex; align-items: center; justify-content: space-between; gap: 14px; min-height: 57px; padding: 14px 17px; border: 1px solid var(--line); border-bottom: 0; }
.results-label { display: flex; align-items: center; gap: 8px; color: #244c86; }
.results-label svg { width: 15px; height: 15px; }
.results-label strong { font-size: 14px; font-weight: 600; }
.count { display: inline-block; color: #637694; background: #eef3fb; padding: 2px 7px; font-size: 11px; border-radius: 3px; min-width: 24px; text-align: center; }
.freshness { display: flex; align-items: center; gap: 6px; color: #8794a7; font-size: 11px; }
.freshness svg { width: 13px; height: 13px; color: #31a18b; }
.table-wrap { overflow: auto; position: relative; max-height: 58vh; border: 1px solid #dce4ef; background: white; scrollbar-color: #bfcbde #edf1f6; scrollbar-width: thin; }
table { width: 100%; border-collapse: separate; border-spacing: 0; text-align: left; font-size: 12px; }
th { position: sticky; top: 0; z-index: 2; padding: 12px 11px; min-width: 76px; color: #3a557c; background: #eef3fb; border-bottom: 1px solid #d6e0ee; border-right: 1px solid #dce5f1; font-weight: 600; white-space: nowrap; }
td { padding: 10px 11px; min-width: 76px; line-height: 1.5; border-bottom: 1px solid #e6ebf3; border-right: 1px solid #e8edf4; vertical-align: middle; }
tr:last-child td { border-bottom: 0; }
th:last-child, td:last-child { border-right: 0; }
tbody tr:nth-child(even) { background: #f9fbfe; }
tbody tr:hover { background: #f1f6ff; }
.row-number { position: sticky; left: 0; width: 85px; min-width: 85px; max-width: 85px; text-align: center; color: #59759f; background: #f6f9fd; z-index: 1; border-right: 1px solid #d6e0ee; font-variant-numeric: tabular-nums; }
th.row-number { z-index: 3; background: #e8effa; }
td.product { min-width: 160px; max-width: 225px; overflow-wrap: anywhere; }
.numeric { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.nowrap { white-space: nowrap; }
.tracking { min-height: 24px; padding: 0; border: 0; background: none; color: #225db7; font-size: 12px; justify-content: flex-start; }
.tracking:hover:not(:disabled) { background: none; border: 0; text-decoration: underline; }
.tracking svg { width: 12px; height: 12px; color: #96a8c4; }
.badge { display: inline-block; padding: 3px 7px; border-radius: 3px; font-size: 11px; color: #18826e; background: #e8f5ef; white-space: nowrap; }
.badge.blue { color: #2c63a7; background: #eaf1fc; }
.badge.amber { color: #a17124; background: #fff2de; }
.state-row>td { padding: 0; border-right: 0; background: white; }
.empty { position: sticky; left: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; width: min(100%,calc(100vw - 284px)); min-height: 290px; padding: 30px 20px; gap: 11px; text-align: center; color: #8190a5; }
.empty>svg { width: 34px; height: 34px; color: #a5b8d4; margin-bottom: 4px; }
.empty strong { color: #62748f; font-size: 13px; font-weight: 600; }
.empty p { max-width: 430px; line-height: 1.7; font-size: 12px; }
.empty.error>svg { color: #d59051; }
.empty button { margin-top: 6px; }
.page-summary { display: flex; align-items: center; flex-wrap: wrap; gap: 13px 26px; padding: 15px 18px; min-height: 53px; border: 1px solid #dce4ef; border-top: 0; background: #f6f9fe; font-size: 12px; }
.page-summary>strong { color: #31598f; font-weight: 600; }
.page-summary>span { display: inline-flex; gap: 7px; align-items: center; color: #7b889d; }
.page-summary svg { width: 14px; height: 14px; color: #829bc0; }
.page-summary b { color: #34527c; font-weight: 650; font-size: 14px; font-variant-numeric: tabular-nums; }
.summary-warning { margin-left: auto; color: #a5742f; }
.table-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 17px; border: 1px solid var(--line); border-top: 0; font-size: 11px; color: #8591a4; }
.pager { display: flex; align-items: center; gap: 7px; }
.pager input { width: 52px; min-height: 31px; padding: 4px; text-align: center; }
.pager .icon { width: 30px; height: 31px; }
.notice { display: flex; align-items: center; gap: 9px; padding: 12px 17px; color: #967039; background: #fff5e4; font-size: 12px; line-height: 1.6; }
.spin { animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.section-title { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 15px; }
.admin-table { max-height: none; }
.admin-table th, .admin-table td { padding: 13px 16px; }
.admin-table td:last-child { white-space: nowrap; }
.admin-table .icon { width: 30px; height: 30px; }
.admin-section { border-top: 1px solid #d8e0ec; padding-top: 25px; margin-top: 29px; }
.members-inline { display: flex; gap: 5px; flex-wrap: wrap; }
.members-inline span { background: #eef3fb; color: #536f99; padding: 3px 7px; border-radius: 3px; font-size: 11px; }
.muted { color: var(--muted); }
.login-shell { min-height: 100vh; background: #f0f3f8; }
.login-shell .topbar { display: flex; justify-content: space-between; }
.login-shell .brand { border-right: 0; }
.login-main { max-width: 420px; margin: 72px auto 40px; padding: 0 24px; }
.login-emblem { display: grid; place-items: center; width: 48px; height: 48px; background: #e1eafa; color: #2c5ca5; border-radius: 6px; margin-bottom: 20px; }
.login-emblem svg { width: 25px; height: 25px; }
.login-main h1 { color: #214c85; font-size: 28px; }
.login-main .subtitle { color: #78879c; font-size: 13px; margin: 11px 0 29px; }
.login-form { display: flex; flex-direction: column; gap: 20px; }
.login-form input { min-height: 44px; }
.login-form .primary { min-height: 43px; }
.form-error { color: #b64b43; font-size: 12px; line-height: 1.6; }
.login-footer { display: flex; align-items: center; gap: 7px; color: #94a0b2; border-top: 1px solid #dce3ee; margin-top: 28px; padding-top: 18px; font-size: 11px; }
dialog { width: min(520px,calc(100vw - 32px)); max-height: 90vh; padding: 0; border: 1px solid var(--line); border-radius: 6px; color: var(--ink); box-shadow: 0 18px 70px #142e5c25; }
dialog::backdrop { background: #182f5766; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 20px 23px; border-bottom: 1px solid var(--line); }
.modal-form { display: flex; flex-direction: column; gap: 17px; padding: 23px; }
.modal-actions { display: flex; justify-content: flex-end; gap: 9px; padding-top: 17px; border-top: 1px solid var(--line); }
.check-row { flex-direction: row; align-items: center; gap: 9px; font-size: 13px; color: var(--ink); min-height: 27px; }
.grants { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 9px; background: #f2f6fc; padding: 13px; border-radius: 4px; }
.field-title { font-size: 12px; color: var(--muted); margin-bottom: 8px; }
#toast { display: none; position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); max-width: calc(100vw - 32px); background: #234774; color: white; border-radius: 5px; padding: 12px 18px; font-size: 13px; z-index: 3000; box-shadow: 0 4px 16px #142e5c25; }
#toast.visible { display: block; }
.viewer-container { z-index: 4000!important; }
.viewer-title { font-size: 13px; color: white; }
.photo-list { display: none; }
@media(min-width:1700px) {
  .main { padding-left: 34px; padding-right: 34px; }
  .all-filters .filter-grid { grid-template-columns: repeat(5,minmax(0,1fr)); }
  .all-filters .filter-actions { grid-column: 1 / -1; }
}
@media(max-width:1150px) {
  .topbar { grid-template-columns: 205px minmax(0,1fr) auto; padding-right: 20px; }
  .brand { width: 205px; padding: 13px 12px; gap: 7px; }
  .brand-logo { width: 80px; }
  .brand strong { font-size: 15px; }
  .workspace-heading { padding-left: 20px; font-size: 12px; }
  .shell { grid-template-columns: 205px minmax(0,1fr); }
  .main { padding: 22px 20px; }
  .identity>span { max-width: 85px; }
  .top-actions { gap: 7px; }
  .metrics { gap: 11px; }
  .metric { padding: 17px 13px; min-height: 98px; }
  .metric-icon { display: none; }
  .metric-value strong { font-size: 25px; }
  .filter-grid { grid-template-columns: repeat(3,minmax(0,1fr)); }
  .all-filters .filter-actions { grid-column: 1 / -1; }
  .warehouse-filters .filter-grid { grid-template-columns: minmax(140px,1fr) minmax(250px,1.5fr); }
  .warehouse-filters .filter-actions { grid-column: 1 / -1; }
  .empty { width: min(100%,calc(100vw - 247px)); }
}
@media(max-width:760px) {
  .topbar { height: 66px; grid-template-columns: minmax(0,1fr) auto; padding-right: 12px; }
  .brand { width: auto; border-right: 0; height: 66px; padding: 10px 12px; gap: 7px; }
  .brand-logo { width: 75px; height: 32px; }
  .brand strong { font-size: 14px; }
  .brand small { font-size: 8px; }
  .workspace-heading, .top-actions .identity, .top-actions .divider { display: none; }
  .top-actions { gap: 5px; }
  .top-actions .icon { width: 29px; height: 31px; }
  .language button { padding: 5px 7px; font-size: 11px; min-height: 29px; }
  .shell { grid-template-columns: 138px minmax(0,1fr); min-height: calc(100vh - 66px); }
  .sidebar { top: 66px; height: calc(100vh - 66px); padding: 19px 8px 14px; }
  .nav-label { padding: 0 7px; margin-bottom: 7px; font-size: 9px; }
  .nav-item { gap: 7px; padding: 10px 7px; min-height: 42px; white-space: normal; text-align: left; line-height: 1.4; font-size: 12px; }
  .nav-item svg { width: 15px; height: 15px; }
  .nav-item .nav-chevron { display: none; }
  .member-navigation { margin-left: 13px; }
  .member-nav-label { padding: 0 9px 6px; font-size: 8px; }
  .member-link { padding: 9px 10px; font-size: 12px; min-height: 36px; }
  .member-link small { font-size: 9px; }
  .nav-separator { margin: 10px 6px; }
  .side-bottom { padding: 15px 5px 0; font-size: 9px; }
  .main { padding: 18px 14px 24px; }
  h1 { font-size: 21px; }
  .eyebrow { font-size: 9px; }
  .page-title { align-items: flex-start; margin-bottom: 17px; }
  .heading-line { gap: 8px; }
  .current-member { font-size: 12px; padding-left: 8px; }
  .title-actions .muted { display: none; }
  .title-actions .icon { width: 30px; height: 32px; }
  .metrics { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; margin-bottom: 17px; }
  .metric { min-height: 88px; padding: 13px; }
  .metric-copy>span { font-size: 11px; }
  .metric-value { margin-top: 7px; gap: 5px; }
  .metric-value strong { font-size: 23px; }
  .metric-value small { font-size: 10px; }
  .filters { padding: 15px 13px; }
  .filter-grid, .warehouse-filters .filter-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px 11px; }
  .warehouse-filters .filter-grid>label { grid-column: 1 / -1; }
  .warehouse-filters .date-pair { grid-column: span 2; }
  .all-filters .filter-actions { grid-column: 1 / -1; }
  .date-pair { gap: 9px; }
  .results-meta { align-items: flex-start; padding: 13px 12px; gap: 8px; flex-wrap: wrap; }
  .freshness { font-size: 10px; flex-wrap: wrap; line-height: 1.6; }
  .results-label strong { font-size: 13px; }
  .empty { min-height: 260px; width: min(100%,calc(100vw - 168px)); padding: 28px 15px; }
  .table-wrap { max-height: 60vh; }
  .page-summary { gap: 12px 17px; padding: 13px; }
  .page-summary>strong { width: 100%; }
  .page-summary>span { font-size: 11px; }
  .page-summary b { font-size: 13px; }
  .summary-warning { margin: 0; }
  .table-footer { align-items: flex-start; flex-wrap: wrap; padding: 13px 12px; line-height: 1.6; }
  .pager { flex-wrap: wrap; gap: 5px; }
  .pager input { width: 42px; }
  .pager .icon { width: 27px; }
  .section-title { align-items: flex-start; flex-wrap: wrap; }
  .section-title h2 { font-size: 17px; }
  .login-shell .brand { width: auto; }
  .login-main { margin-top: 54px; }
}
@media(max-width:480px) {
  .brand-logo { width: 60px; }
  .brand strong { font-size: 12px; }
  .brand small { font-size: 7px; }
  .brand { padding-left: 9px; gap: 6px; }
  .shell { grid-template-columns: 109px minmax(0,1fr); }
  .sidebar { padding-left: 5px; padding-right: 5px; }
  .nav-item { font-size: 10px; gap: 5px; padding-left: 5px; padding-right: 5px; }
  .nav-item svg { width: 13px; height: 13px; }
  .member-nav-label { font-size: 7px; padding-left: 7px; }
  .member-link { font-size: 11px; padding: 9px 8px; gap: 7px; }
  .main { padding-left: 10px; padding-right: 10px; }
  .empty { width: min(100%,calc(100vw - 131px)); }
  h1 { font-size: 19px; }
  .heading-line { display: block; }
  .current-member { margin-top: 7px; padding: 0; border: 0; }
  .metric { padding: 11px 9px; }
  .metric-copy>span { font-size: 10px; }
  .metric-value strong { font-size: 20px; }
  .metric-value small { font-size: 9px; }
  .filters { padding: 13px 10px; }
  .filter-grid, .warehouse-filters .filter-grid { grid-template-columns: minmax(0,1fr); }
  .warehouse-filters .date-pair, .date-pair { grid-column: auto; grid-template-columns: minmax(0,1fr); }
  .all-filters .filter-actions, .warehouse-filters .filter-actions { grid-column: auto; }
  .top-actions { gap: 4px; }
  .top-actions .icon { width: 26px; }
  .language button { padding: 5px 6px; font-size: 10px; }
}
@media(prefers-reduced-motion:reduce) {
  * { animation: none!important; scroll-behavior: auto!important; }
}
