:root {
  color-scheme: light;
  --client-ink: #172c25;
  --client-muted: #6b7b73;
  --client-line: #dce7e0;
  --client-canvas: #f4f7f5;
  --client-surface: #ffffff;
  --client-brand: #145e43;
  --client-brand-dark: #0f4935;
  --client-green-soft: #e7f3ec;
  --client-amber: #b66d29;
  --client-amber-soft: #fff2de;
  --client-sidebar: 220px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
html { min-width: 320px; scroll-behavior: smooth; }
body { margin: 0; color: var(--client-ink); background: var(--client-canvas); font-size: 15px; line-height: 1.5; }
button, input, select { font: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }
button:disabled { cursor: wait; opacity: .6; }
button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid rgba(182,109,41,.35); outline-offset: 2px; }
[hidden] { display: none !important; }
.client-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; z-index: 80; left: 16px; top: 10px; transform: translateY(-150%); padding: 10px 14px; border-radius: 8px; color: var(--client-brand); background: white; box-shadow: 0 8px 20px rgba(16,50,37,.12); }
.skip-link:focus { transform: none; }
.client-shell { min-height: 100svh; display: grid; grid-template-columns: var(--client-sidebar) minmax(0, 1fr); }
.client-sidebar { position: sticky; top: 0; z-index: 20; display: flex; flex-direction: column; gap: 28px; height: 100svh; padding: 24px 15px 18px; color: #e9f4ee; background: #102a24; }
.client-brand { display: flex; align-items: center; gap: 11px; padding: 0 8px; }
.client-brand > div { display: grid; gap: 2px; }
.client-brand strong { color: white; font-size: 16px; }
.client-brand span:last-child { color: #9eb8ac; font-size: 12px; }
.client-brand-mark { display: grid; place-items: center; width: 39px; height: 39px; border-radius: 12px; color: #12392a; background: #dbf0e2; font-size: 20px; font-weight: 800; }
.client-nav { display: grid; gap: 5px; }
.client-nav button { display: grid; grid-template-columns: 24px 1fr; align-items: center; min-height: 46px; padding: 9px 12px; border: 0; border-radius: 10px; color: #aec2b8; background: transparent; text-align: left; font-weight: 650; }
.client-nav button span { color: #7da492; font-size: 20px; line-height: 1; }
.client-nav button:hover { color: white; background: rgba(255,255,255,.07); }
.client-nav button.active { color: white; background: #1b6249; box-shadow: inset 3px 0 0 #e1ad5b; }
.client-nav button.active span { color: #f5d18a; }
.client-sidebar-foot { display: flex; align-items: center; gap: 9px; margin-top: auto; padding: 14px 9px 0; border-top: 1px solid rgba(255,255,255,.13); }
.client-sidebar-foot div { display: grid; gap: 2px; }
.client-sidebar-foot strong { color: #deeee5; font-size: 12px; }
.client-sidebar-foot span:last-child { color: #91ab9e; font-size: 12px; }
.client-connection-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #d18d36; box-shadow: 0 0 0 4px rgba(209,141,54,.16); }
.client-main { min-width: 0; padding-bottom: 48px; }
.client-topbar { flex-wrap: wrap; position: sticky; top: 0; z-index: 15; display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 82px; padding: 14px clamp(20px, 4vw, 52px); border-bottom: 1px solid var(--client-line); background: rgba(244,247,245,.95); backdrop-filter: blur(12px); }
.client-heading { display: flex; flex: 1 1 auto; align-items: center; gap: 13px; min-width: 0; }
.client-heading > div { min-width: 0; }
.client-heading h1 { margin: 2px 0 0; color: #17362a; font-size: clamp(21px, 2.5vw, 28px); line-height: 1.2; letter-spacing: -.03em; }
.client-eyebrow { margin: 0; color: #6d7d74; font-size: 12px; font-weight: 800; letter-spacing: .06em; }
.client-menu { display: none; min-width: 44px; min-height: 44px; border: 0; border-radius: 9px; color: var(--client-brand); background: transparent; font-size: 22px; }
.client-top-actions { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.client-bridge-status { display: inline-flex; align-items: center; gap: 7px; color: #718078; font-size: 12px; white-space: nowrap; }
.client-status-light { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #c4873d; box-shadow: 0 0 0 4px #fff0d8; }
.client-toggle { display: inline-flex; align-items: center; gap: 7px; color: #607067; font-size: 12px; font-weight: 700; cursor: pointer; }
.client-toggle input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.client-toggle-track { position: relative; width: 34px; height: 20px; border-radius: 999px; background: #cbd5cf; transition: background-color .15s ease; }
.client-toggle-track::after { position: absolute; top: 3px; left: 3px; width: 14px; height: 14px; border-radius: 50%; background: white; box-shadow: 0 1px 3px rgba(0,0,0,.18); content: ''; transition: transform .15s ease; }
.client-toggle input:focus-visible + .client-toggle-track { outline: 3px solid rgba(182,109,41,.35); outline-offset: 2px; }
.client-toggle input:checked + .client-toggle-track { background: var(--client-brand); }
.client-toggle input:checked + .client-toggle-track::after { transform: translateX(14px); }
.client-view { width: min(100%, 1560px); margin: 0 auto; padding: 28px clamp(20px, 4vw, 52px) 0; }
.client-toolbar { display: grid; grid-template-columns: 150px minmax(230px, 360px) 1fr; align-items: end; gap: 16px; margin-bottom: 16px; padding: 15px 17px; border: 1px solid var(--client-line); border-radius: 14px; background: #fbfcfb; }
.client-toolbar label { display: grid; gap: 6px; color: #55665d; font-size: 12px; font-weight: 750; }
.client-toolbar input, .client-toolbar select { width: 100%; min-height: 40px; padding: 8px 11px; border: 1px solid #cad8d0; border-radius: 9px; color: var(--client-ink); background: white; }
.client-toolbar-note { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding-bottom: 10px; color: #78877f; font-size: 12px; }
.client-summary-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.client-summary-card { min-width: 0; padding: 17px 18px; border: 1px solid var(--client-line); border-radius: 14px; background: var(--client-surface); }
.client-summary-card span, .client-summary-card small { display: block; color: #718078; font-size: 12px; }
.client-summary-card strong { display: block; margin: 7px 0 2px; color: #1f5b42; font-size: 27px; line-height: 1.15; font-variant-numeric: tabular-nums; }
.client-summary-accent { border-color: #c3dfcf; background: #f8fcf9; }
.client-summary-warn strong { color: var(--client-amber); }
.client-workspace-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; align-items: start; gap: 16px; }
.client-number-panel, .client-side-card { border: 1px solid var(--client-line); border-radius: 16px; background: white; }
.client-number-panel { min-width: 0; padding: 20px; }
.client-panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 17px; }
.client-panel-heading h2, .client-side-card h2 { margin: 3px 0 0; color: #1d362a; font-size: 19px; letter-spacing: -.02em; }
.client-panel-heading p:last-child { margin: 5px 0 0; color: #7a8881; font-size: 12px; }
.client-legend { display: flex; gap: 13px; padding-top: 3px; color: #68766f; font-size: 12px; white-space: nowrap; }
.client-legend span { display: inline-flex; align-items: center; gap: 6px; }
.client-legend-dot { width: 9px; height: 9px; border-radius: 3px; }
.client-legend-dot.original { background: #cedbd3; }
.client-legend-dot.adjusted { background: #56a781; }
.client-number-grid { display: grid; grid-template-columns: repeat(4, minmax(180px, 1fr)); gap: 12px; }
.client-number-group { min-width: 0; overflow: hidden; border: 1px solid #e0e9e3; border-radius: 12px; background: #fcfdfc; }
.client-number-group > header { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; padding: 12px 12px 10px; border-bottom: 1px solid #e7ede9; }
.client-number-group > header strong { color: #254238; font-size: 14px; }
.client-number-group > header span { color: #87958d; font-size: 12px; }
.client-number-head, .client-number-row { display: grid; grid-template-columns: 30px 26px minmax(0,1fr) minmax(0,1fr); align-items: center; column-gap: 7px; padding: 0 9px; }
.client-number-head { min-height: 28px; color: #87958d; font-size: 12px; font-weight: 750; }
.client-number-head span:nth-last-child(-n+2) { text-align: right; }
.client-number-row { min-height: 42px; border-top: 1px solid #edf1ee; }
.client-number-row:focus-within { background: #f0f8f3; }
.client-number-badge { display: inline-grid; place-items: center; width: 28px; height: 25px; border-radius: 7px; color: #245c46; background: #e9f2ec; font: 700 12px/1 ui-monospace, SFMono-Regular, Menlo, monospace; }
.client-number-zodiac { color: #819087; font-size: 12px; }
.client-number-row input { width: 100%; min-height: 31px; padding: 5px 6px; border: 1px solid #d5e0d9; border-radius: 7px; color: #25382e; background: white; text-align: right; font-size: 13px; font-variant-numeric: tabular-nums; }
.client-number-row input[data-client-number-field="adjusted"] { border-color: #a8cfbc; background: #f7fcf8; }
.client-number-row input:focus { border-color: var(--client-brand); outline: 0; box-shadow: 0 0 0 2px rgba(20,94,67,.12); }
.client-side-stack { display: grid; gap: 12px; min-width: 0; }
.client-side-card { padding: 18px; }
.client-side-card > header { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.client-pill { display: inline-flex; align-items: center; min-height: 26px; padding: 4px 8px; border-radius: 999px; font-size: 12px; font-weight: 750; }
.client-pill.muted { color: #766139; background: #fff3d8; }
.client-empty-state { display: grid; justify-items: center; gap: 7px; padding: 30px 8px 12px; text-align: center; }
.client-empty-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; color: #8b9c92; background: #f0f5f2; font-size: 25px; }
.client-empty-state strong { color: #375245; font-size: 14px; }
.client-empty-state p { max-width: 220px; margin: 0; color: #87958d; font-size: 12px; line-height: 1.55; }
.client-tip-card { color: #65766d; font-size: 12px; }
.client-tip-card strong { color: #364d40; font-size: 13px; }
.client-tip-card ol { display: grid; gap: 8px; margin: 11px 0 0; padding-left: 19px; }
.client-tip-card li::marker { color: #5c9a7b; font-weight: 800; }
.client-button { min-height: 40px; padding: 8px 14px; border: 1px solid transparent; border-radius: 9px; font-size: 13px; font-weight: 750; transition: background-color .15s ease, border-color .15s ease, transform .15s ease; }
.client-button:active { transform: translateY(1px); }
.client-button-primary { color: white; background: var(--client-brand); }
.client-button-primary:hover { background: var(--client-brand-dark); }
.client-button-muted { border-color: #d0ddd5; color: #44574c; background: white; }
.client-button-muted:hover, .client-button-outline:hover { border-color: #9eb8a8; background: #f2f8f4; }
.client-button-outline { border-color: #bad2c3; color: #276a4d; background: #f7fcf8; }
.client-empty-state .client-button { margin-top: 7px; min-height: 38px; }
.client-action-bar { position: sticky; bottom: 16px; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 16px; padding: 14px 17px; border: 1px solid #c6ddd0; border-radius: 14px; background: rgba(247,252,248,.96); box-shadow: 0 14px 35px rgba(24,65,45,.12); backdrop-filter: blur(10px); }
.client-action-bar > div:first-child { display: grid; gap: 2px; min-width: 0; }
.client-action-bar strong { color: #204b36; font-size: 13px; }
.client-action-bar span { color: #718078; font-size: 12px; }
.client-action-bar > div:last-child { display: flex; gap: 8px; flex-shrink: 0; }
.client-placeholder-view { min-height: 500px; display: grid; place-content: center; justify-items: center; gap: 8px; text-align: center; }
.client-placeholder-icon { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 16px; color: #5a9275; background: #e7f3eb; font-size: 28px; }
.client-placeholder-view h2 { margin: 5px 0 0; font-size: 22px; }
.client-placeholder-view p { max-width: 420px; margin: 0; color: var(--client-muted); }
.client-toast { position: fixed; right: 24px; bottom: 24px; z-index: 70; max-width: min(360px, calc(100% - 48px)); padding: 12px 15px; border-radius: 10px; color: white; background: #173e2e; box-shadow: 0 15px 35px rgba(11,48,32,.23); font-size: 13px; font-weight: 700; }

@media (max-width: 1180px) {
  .client-number-grid { grid-template-columns: repeat(2, minmax(220px, 1fr)); }
}
@media (max-width: 920px) {
  .client-shell { display: block; }
  .client-sidebar { position: fixed; left: 0; width: min(82vw, 280px); transform: translateX(-105%); transition: transform .2s ease; box-shadow: 24px 0 50px rgba(0,0,0,.24); }
  .client-page.nav-open .client-sidebar { transform: none; }
  .client-menu { display: inline-grid; place-items: center; }
  .client-topbar { min-height: 74px; }
  .client-bridge-status { display: none; }
  .client-workspace-layout { grid-template-columns: 1fr; }
  .client-side-stack { grid-template-columns: minmax(0, 1.3fr) minmax(180px, .7fr); align-items: start; }
}
@media (max-width: 620px) {
  .client-topbar { align-items: flex-start; gap: 8px 12px; padding: 13px 15px; }
  .client-top-actions { width: 100%; justify-content: flex-end; }
  .client-top-actions { gap: 8px; }
  .client-toggle span:last-child { display: none; }
  .client-view { padding: 20px 14px 0; }
  .client-toolbar { grid-template-columns: 1fr; gap: 12px; }
  .client-toolbar-note { justify-content: flex-start; padding-bottom: 0; }
  .client-summary-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 9px; }
  .client-summary-card { padding: 14px; }
  .client-summary-card strong { font-size: 24px; }
  .client-panel-heading { flex-direction: column; gap: 9px; }
  .client-number-panel { padding: 14px 11px; }
  .client-number-grid { grid-template-columns: 1fr; }
  .client-side-stack { grid-template-columns: 1fr; }
  .client-action-bar { align-items: stretch; flex-direction: column; gap: 12px; bottom: max(8px, env(safe-area-inset-bottom)); }
  .client-action-bar > div:last-child { display: grid; grid-template-columns: 1fr 1fr; }
  .client-action-bar > div:last-child .client-button:last-child { grid-column: 1 / -1; }
  .client-action-bar .client-button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

.client-card { border: 1px solid var(--client-line); border-radius: 16px; background: var(--client-surface); }
.client-hero-row, .client-page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.client-section-title, .client-page-heading h2 { margin: 5px 0 0; color: #17362a; font-size: clamp(24px, 3vw, 34px); letter-spacing: -.04em; line-height: 1.15; }
.client-section-copy, .client-page-heading p:last-child { margin: 7px 0 0; color: var(--client-muted); font-size: 14px; }
.client-hero-actions, .client-page-actions { display: flex; gap: 8px; flex-shrink: 0; }
.client-dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(290px, .65fr); gap: 16px; margin-bottom: 16px; }
.client-card { padding: 20px; }
.client-card-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 16px; }
.client-card-heading h2, .client-card-heading h3 { margin: 3px 0 0; color: #1d362a; font-size: 19px; letter-spacing: -.02em; }
.client-card-heading h3 { font-size: 17px; }
.client-text-button { padding: 3px 0; border: 0; color: #277252; background: transparent; font-size: 13px; font-weight: 750; white-space: nowrap; }
.client-text-button:hover { color: #0f4935; text-decoration: underline; }
.client-queue-list { display: grid; gap: 8px; }
.client-queue-item { display: grid; grid-template-columns: 9px minmax(0, 1fr) auto; align-items: center; gap: 10px; width: 100%; padding: 12px 10px; border: 1px solid #edf1ee; border-radius: 10px; color: inherit; background: #fbfdfb; text-align: left; }
.client-queue-item:hover { border-color: #b9d5c4; background: #f5fbf7; }
.client-queue-item > span:nth-child(2) { display: grid; min-width: 0; gap: 2px; }
.client-queue-item strong, .client-queue-item small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.client-queue-item strong { color: #2c4739; font-size: 13px; }
.client-queue-item small { color: #84928a; font-size: 12px; }
.client-queue-item em { color: #8c6938; font-size: 12px; font-style: normal; font-weight: 750; }
.client-queue-status { width: 8px; height: 8px; border-radius: 50%; background: #d39a4c; box-shadow: 0 0 0 4px #fff3dd; }
.client-queue-status.warning { background: #c76755; box-shadow: 0 0 0 4px #fde6e0; }
.client-queue-status.done { background: #5ca57b; box-shadow: 0 0 0 4px #e4f4e9; }
.client-progress { display: grid; gap: 9px; margin: 3px 0 18px; }
.client-progress > div:first-child { display: flex; justify-content: space-between; color: #6d7d74; font-size: 12px; }
.client-progress strong { color: #1d5c42; font-size: 13px; }
.client-progress-track { height: 8px; overflow: hidden; border-radius: 999px; background: #e9f1ec; }
.client-progress-track i { display: block; height: 100%; border-radius: inherit; background: #58a47c; }
.client-focus-list { display: grid; gap: 6px; }
.client-focus-list button { display: grid; grid-template-columns: 32px minmax(0, 1fr) 16px; align-items: center; gap: 9px; width: 100%; padding: 9px 5px; border: 0; color: inherit; background: transparent; text-align: left; }
.client-focus-list button:hover { border-radius: 9px; background: #f4f8f5; }
.client-focus-list button > span:nth-child(2) { display: grid; gap: 2px; }
.client-focus-list strong { color: #345344; font-size: 13px; }
.client-focus-list small { color: #87958d; font-size: 12px; }
.client-focus-list b { color: #9aaca1; font-size: 20px; font-weight: 500; }
.client-focus-icon, .client-tool-icon { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 9px; color: #397c5b; background: #e6f3eb; font-size: 17px; }
.client-focus-icon.amber, .client-tool-icon.amber { color: #a66c2b; background: #fff0da; }
.client-focus-icon.blue, .client-tool-icon.blue { color: #4d789b; background: #e8f1f7; }
.client-mini-table { display: grid; gap: 7px; }
.client-mini-row { display: grid; grid-template-columns: minmax(0, 1fr) auto 74px; align-items: center; gap: 12px; padding: 11px 4px; border-top: 1px solid #edf1ee; }
.client-mini-row > div { display: grid; gap: 2px; min-width: 0; }
.client-mini-row strong, .client-mini-row span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.client-mini-row strong { color: #2c4739; font-size: 13px; }
.client-mini-row > div span { color: #87958d; font-size: 12px; }
.client-mini-row > b { color: #2f6d50; font-size: 14px; text-align: right; }
.client-pill.success { color: #2c7650; background: #e5f5ea; }
.client-pill.warning { color: #a45140; background: #fde9e3; }
.client-pill.info { color: #356d91; background: #e7f1f8; }
.client-page-heading { align-items: center; }
.client-filter-bar { display: flex; align-items: end; gap: 12px; margin-bottom: 16px; padding: 13px 15px; border: 1px solid var(--client-line); border-radius: 13px; background: #fbfcfb; }
.client-filter-bar label { display: grid; gap: 6px; min-width: 140px; color: #627269; font-size: 12px; font-weight: 750; }
.client-filter-bar label input, .client-filter-bar label select { min-height: 38px; padding: 7px 10px; border: 1px solid #cad8d0; border-radius: 8px; color: var(--client-ink); background: white; }
.client-filter-bar .client-search-field { flex: 1; min-width: 180px; }
.client-inbox-list { display: grid; gap: 12px; }
.client-inbox-item { padding: 18px; border: 1px solid var(--client-line); border-radius: 15px; background: white; }
.client-inbox-item > header { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 13px; }
.client-inbox-item > header > div { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.client-inbox-source { color: #2b4739; font-size: 14px; font-weight: 800; }
.client-inbox-time { color: #8a988f; font-size: 12px; }
.client-message-compare { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.client-message-compare > div { min-width: 0; padding: 12px; border-radius: 10px; background: #f7faf8; }
.client-message-compare > div > span { color: #829188; font-size: 12px; font-weight: 750; }
.client-message-compare pre, .client-message-compare p { min-height: 44px; margin: 7px 0 0; color: #364d40; font: 13px/1.65 inherit; white-space: pre-wrap; }
.client-message-compare p { color: #296a4c; }
.client-inbox-item > footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 13px; }
.client-inbox-item > footer .client-button { min-height: 34px; padding: 6px 11px; font-size: 12px; }
.client-order-table-card { padding: 0; overflow: hidden; }
.client-order-table-wrap { overflow-x: auto; }
.client-order-table { width: 100%; min-width: 900px; border-collapse: collapse; }
.client-order-table th, .client-order-table td { padding: 14px 15px; border-bottom: 1px solid #edf1ee; text-align: left; vertical-align: top; }
.client-order-table th { color: #809087; background: #f7faf8; font-size: 12px; font-weight: 800; white-space: nowrap; }
.client-order-table td { color: #40574b; font-size: 13px; }
.client-order-table td > strong, .client-order-table td > small { display: block; }
.client-order-table td > strong { color: #2a493a; font-size: 12px; }
.client-order-table td > small { margin-top: 4px; color: #8a988f; font-size: 12px; }
.client-order-table td:nth-child(3) { min-width: 260px; max-width: 390px; line-height: 1.6; }
.client-money, .client-profit { color: #2c7550 !important; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.client-mobile-order-list { display: none; }
.client-inline-empty { min-height: 170px; }
.client-settlement-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); gap: 16px; margin-bottom: 16px; }
.client-result-card, .client-settlement-summary { min-width: 0; }
.client-result-inputs { display: grid; grid-template-columns: minmax(0, 1fr) 160px; gap: 12px; }
.client-result-inputs label { display: grid; gap: 6px; color: #617269; font-size: 12px; font-weight: 750; }
.client-result-inputs input { min-height: 42px; padding: 8px 11px; border: 1px solid #cad8d0; border-radius: 9px; color: var(--client-ink); background: #fff; }
.client-result-actions { display: flex; gap: 8px; margin-top: 16px; }
.client-settlement-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.client-settlement-metrics > div { padding: 13px 10px; border-radius: 10px; background: #f6faf7; }
.client-settlement-metrics span { display: block; color: #7e8d84; font-size: 12px; }
.client-settlement-metrics strong { display: block; margin-top: 6px; color: #286c4c; font-size: 20px; }
.client-muted-note { margin: 16px 0 0; color: #87958d; font-size: 12px; line-height: 1.6; }
.client-history-list { display: grid; gap: 0; padding: 0 20px; }
.client-history-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid #edf1ee; }
.client-history-row:last-child { border-bottom: 0; }
.client-history-row > div { display: grid; gap: 4px; }
.client-history-row strong { color: #2c4739; font-size: 14px; }
.client-history-row div span { color: #87958d; font-size: 12px; }
.client-tools-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.client-tool-card { min-height: 220px; }
.client-tool-card h3 { margin: 17px 0 6px; color: #2c4739; font-size: 17px; }
.client-tool-card p { min-height: 48px; margin: 0 0 16px; color: #7c8b82; font-size: 13px; line-height: 1.65; }
.client-tool-icon { width: 40px; height: 40px; font-size: 21px; }
.client-mobile-order { display: grid; gap: 9px; padding: 14px; border-bottom: 1px solid #edf1ee; }
.client-mobile-order header, .client-mobile-order > div { display: flex; justify-content: space-between; gap: 10px; align-items: center; }
.client-mobile-order header strong { color: #2c4739; font-size: 13px; }
.client-mobile-order p, .client-mobile-order > div span { margin: 0; color: #87958d; font-size: 12px; }
.client-mobile-order > div strong { color: #2c7550; }
@media (max-width: 920px) {
  .client-dashboard-grid, .client-settlement-grid { grid-template-columns: 1fr; }
  .client-tools-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 620px) {
  .client-hero-row, .client-page-heading { align-items: flex-start; flex-direction: column; gap: 12px; }
  .client-hero-actions, .client-page-actions { width: 100%; }
  .client-hero-actions .client-button, .client-page-actions .client-button { flex: 1; }
  .client-dashboard-grid { gap: 12px; }
  .client-card { padding: 15px; }
  .client-filter-bar { align-items: stretch; flex-direction: column; }
  .client-filter-bar label, .client-filter-bar .client-search-field { width: 100%; min-width: 0; }
  .client-message-compare { grid-template-columns: 1fr; }
  .client-inbox-item > footer { justify-content: stretch; }
  .client-inbox-item > footer .client-button { flex: 1; }
  .client-result-inputs { grid-template-columns: 1fr; }
  .client-history-row { grid-template-columns: minmax(0, 1fr) auto; }
  .client-history-row .client-text-button { grid-column: 2; grid-row: 1 / span 2; }
  .client-tools-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .client-order-table-wrap { display: none; }
  .client-mobile-order-list { display: block; }
}

.client-preview-modal[hidden] { display: none; }
.client-preview-modal { position: fixed; inset: 0; z-index: 30; display: grid; place-items: center; padding: 24px; }
.client-preview-backdrop { position: absolute; inset: 0; background: rgba(15, 31, 25, .42); }
.client-preview-dialog { position: relative; z-index: 1; width: min(720px, 100%); border: 1px solid var(--client-line); border-radius: 16px; background: var(--client-surface); box-shadow: 0 24px 80px rgba(15, 31, 25, .22); }
.client-preview-dialog > header { display: flex; align-items: flex-start; justify-content: space-between; padding: 22px 24px 16px; border-bottom: 1px solid var(--client-line); }
.client-preview-dialog h2 { margin: 4px 0 0; color: var(--client-ink); font-size: 22px; }
.client-icon-button { display: grid; width: 32px; height: 32px; place-items: center; border: 1px solid var(--client-line); border-radius: 50%; color: var(--client-muted); background: transparent; font-size: 22px; line-height: 1; cursor: pointer; }
.client-preview-body { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; padding: 22px 24px; }
.client-preview-body > div { min-width: 0; padding: 16px; border: 1px solid var(--client-line); border-radius: 10px; background: var(--client-canvas); }
.client-preview-body span { display: block; margin-bottom: 10px; color: var(--client-muted); font-size: 12px; }
.client-preview-body pre, .client-preview-body p { margin: 0; color: var(--client-ink); white-space: pre-wrap; word-break: break-word; font: inherit; line-height: 1.75; }
.client-preview-dialog > footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 24px 20px; border-top: 1px solid var(--client-line); color: var(--client-muted); font-size: 12px; }
@media (max-width: 620px) {
  .client-preview-modal { padding: 12px; }
  .client-preview-body { grid-template-columns: 1fr; padding: 16px; }
  .client-preview-dialog > header, .client-preview-dialog > footer { padding-left: 16px; padding-right: 16px; }
  .client-preview-dialog > footer { align-items: stretch; flex-direction: column; }
}


/* Reference layout: the user front end opens as a dense adjustment workspace. */
.client-page { background: #f7f8f8; }
.client-sidebar { gap: 22px; padding: 28px 12px 18px; color: #27322f; background: #f0f1f1; border-right: 1px solid #d7dada; box-shadow: none; }
.client-brand { padding: 0 12px; }
.client-brand strong { color: #1d2523; font-size: 16px; }
.client-brand span:last-child { color: #87908c; }
.client-brand-mark { width: 35px; height: 35px; border-radius: 0; color: #222b28; background: transparent; font-size: 24px; }
.client-nav { gap: 2px; }
.client-nav button { min-height: 43px; padding: 8px 14px; border-radius: 3px; color: #303a37; font-weight: 500; }
.client-nav button span { color: #222a28; font-size: 21px; }
.client-nav button:hover { color: #1d5d43; background: #e5e8e7; }
.client-nav button.active { color: #29825b; background: #e4f2ea; box-shadow: inset 3px 0 0 #43a874; font-weight: 700; }
.client-nav button.active span { color: #29825b; }
.client-sidebar-foot { padding: 14px 12px 0; border-top-color: #d6d9d8; }
.client-sidebar-foot strong { color: #4c5a54; }
.client-sidebar-foot span:last-child { color: #8a9590; }
.client-main { background: #fff; }
.client-topbar { min-height: 48px; padding: 0 18px; border-bottom: 1px solid #d9dddb; background: #fff; box-shadow: none; }
.client-heading h1 { color: #252e2b; font-size: 18px; letter-spacing: 0; }
.client-eyebrow { color: #68746e; letter-spacing: 0; }
.client-top-actions { gap: 9px; }
.client-top-actions .client-button { min-height: 30px; padding: 4px 10px; border-radius: 3px; }
.client-toggle-track { width: 30px; height: 18px; }
.client-toggle-track::after { width: 12px; height: 12px; }
.client-toggle input:checked + .client-toggle-track::after { transform: translateX(12px); }
.client-view[data-client-panel="adjustment"] { width: 100%; max-width: none; padding: 0 14px 12px; }
.client-view[data-client-panel="adjustment"] .client-page-heading { display: none; }
.client-view[data-client-panel="adjustment"] .client-toolbar { grid-template-columns: 180px minmax(220px, 310px) 1fr; margin: 0 -14px; padding: 7px 14px; border: 0; border-bottom: 1px solid #cfd5d2; border-radius: 0; background: #f8f9f9; }
.client-view[data-client-panel="adjustment"] .client-toolbar label { display: flex; align-items: center; gap: 7px; color: #3e4944; font-weight: 500; }
.client-view[data-client-panel="adjustment"] .client-toolbar label span { white-space: nowrap; }
.client-view[data-client-panel="adjustment"] .client-toolbar input,
.client-view[data-client-panel="adjustment"] .client-toolbar select { min-height: 30px; padding: 3px 7px; border-color: #bcc6c1; border-radius: 2px; font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-toolbar-note { justify-content: flex-end; padding-bottom: 0; color: #76817b; }
.client-view[data-client-panel="adjustment"] > .client-summary-grid { display: none; }
.client-view[data-client-panel="adjustment"] .client-workspace-layout { grid-template-columns: 285px minmax(0, 1fr); gap: 0; align-items: stretch; margin: 0 -14px; }
.client-view[data-client-panel="adjustment"] .client-slip-panel { display: flex; min-height: 500px; flex-direction: column; padding: 0; border-width: 0 1px 0 0; border-radius: 0; background: #fff; }
.client-slip-panel { min-width: 0; }
.client-slip-panel > header { display: flex; align-items: flex-start; justify-content: space-between; padding: 7px 12px; border-bottom: 1px solid #d9dddb; }
.client-slip-panel h2 { margin: 1px 0 0; color: #303936; font-size: 15px; font-weight: 600; }
.client-slip-tabs { display: grid; grid-template-columns: 1.2fr 1fr 1fr .65fr; padding: 0 8px; border-bottom: 1px solid #d9dddb; background: #f3f5f4; }
.client-slip-tabs span { padding: 6px 4px; color: #52605a; border-right: 1px solid #d9dddb; font-size: 12px; text-align: center; }
.client-slip-tabs span:last-child { border-right: 0; }
.client-slip-list { display: grid; gap: 0; }
.client-slip-row { display: grid; grid-template-columns: 1fr 1.35fr auto; gap: 7px; align-items: center; padding: 9px 10px; border: 0; border-bottom: 1px solid #eef0ef; color: #35413b; background: #fff; text-align: left; font-size: 12px; }
.client-slip-row:hover, .client-slip-row.active { background: #f0f8f3; }
.client-slip-row span, .client-slip-row b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.client-slip-row b { color: #53635b; font-weight: 500; }
.client-slip-row em { color: #8d6b3d; font-size: 12px; font-style: normal; white-space: nowrap; }
.client-slip-empty { display: grid; place-content: center; justify-items: center; flex: 1; min-height: 190px; border-top: 1px dashed #dce1de; color: #9aa49f; text-align: center; }
.client-slip-empty span { display: grid; place-items: center; width: 30px; height: 30px; border: 1px dashed #b7c0bb; border-radius: 50%; font-size: 20px; }
.client-slip-empty p { margin: 8px 0 0; font-size: 12px; line-height: 1.6; }
.client-view[data-client-panel="adjustment"] .client-number-panel { min-width: 0; padding: 0 8px 0 12px; border: 0; border-radius: 0; }
.client-view[data-client-panel="adjustment"] .client-panel-heading { align-items: center; margin: 0; min-height: 42px; padding: 0 4px; border-bottom: 1px solid #d9dddb; }
.client-view[data-client-panel="adjustment"] .client-panel-heading h2 { margin: 0; color: #333d39; font-size: 15px; font-weight: 600; }
.client-view[data-client-panel="adjustment"] .client-panel-heading .client-eyebrow { display: none; }
.client-view[data-client-panel="adjustment"] .client-legend { padding-top: 0; font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-number-grid { grid-template-columns: repeat(4, minmax(150px, 1fr)); gap: 10px; padding-top: 8px; }
.client-view[data-client-panel="adjustment"] .client-number-group { border-color: #d8ddda; border-radius: 0; background: #fff; }
.client-view[data-client-panel="adjustment"] .client-number-group > header { padding: 6px 8px; border-bottom-color: #d8ddda; background: #f6f8f7; }
.client-view[data-client-panel="adjustment"] .client-number-group > header strong { color: #3d4944; font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-number-group > header span { font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-number-head, .client-view[data-client-panel="adjustment"] .client-number-row { grid-template-columns: 28px 22px minmax(0,1fr) minmax(0,1fr); column-gap: 4px; padding: 0 6px; }
.client-view[data-client-panel="adjustment"] .client-number-head { min-height: 24px; color: #65736c; font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-number-row { min-height: 30px; border-top-color: #edf0ee; }
.client-view[data-client-panel="adjustment"] .client-number-badge { width: 25px; height: 21px; border-radius: 0; color: #4e6b5b; background: transparent; font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-number-zodiac { color: #67766e; font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-number-row input { min-height: 23px; padding: 2px 4px; border-color: #aeb8b3; border-radius: 1px; font-size: 12px; }
.client-view[data-client-panel="adjustment"] .client-number-row input[data-client-number-field="adjusted"] { border-color: #aeb8b3; background: #fff; }
.client-view[data-client-panel="adjustment"] .client-side-stack { display: none; }
.client-view[data-client-panel="adjustment"] .client-target-stats { display: grid; grid-template-columns: 1fr 1fr; margin: 8px -14px 0; border-top: 1px solid #aeb7b2; border-bottom: 1px solid #aeb7b2; }
.client-target-stats { background: #fff; }
.client-target-stats > div { display: grid; grid-template-columns: 96px 100px 1fr; align-items: center; min-height: 34px; padding: 0 12px; border-right: 1px solid #aeb7b2; }
.client-target-stats > div:last-child { border-right: 0; }
.client-target-stats span { color: #52615a; font-size: 12px; }
.client-target-stats strong { color: #2d3d35; font-size: 13px; font-weight: 500; }
.client-target-stats small { color: #849089; font-size: 12px; }
.client-target-stats small b { color: #9a746a; font-weight: 500; }
.client-view[data-client-panel="adjustment"] .client-action-bar { position: static; margin: 0 -14px; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: #fff; }
.client-view[data-client-panel="adjustment"] .client-action-bar > div:first-child { display: none; }
.client-view[data-client-panel="adjustment"] .client-action-bar > div:last-child { display: grid; grid-template-columns: repeat(5, 1fr); width: 100%; gap: 0; }
.client-view[data-client-panel="adjustment"] .client-action-bar .client-button { min-height: 31px; border-width: 0 1px 1px 0; border-color: #c5ccc8; border-radius: 0; color: #4b5952; background: #fafbfb; font-size: 12px; font-weight: 500; }
.client-view[data-client-panel="adjustment"] .client-action-bar .client-button-primary { color: #2d5e47; background: #f0f7f2; }
@media (max-width: 1100px) {
  .client-view[data-client-panel="adjustment"] .client-workspace-layout { grid-template-columns: 240px minmax(0, 1fr); }
  .client-view[data-client-panel="adjustment"] .client-number-grid { grid-template-columns: repeat(2, minmax(160px, 1fr)); }
}
@media (max-width: 720px) {
  .client-sidebar { background: #f0f1f1; }
  .client-view[data-client-panel="adjustment"] .client-toolbar { grid-template-columns: 1fr; gap: 5px; }
  .client-view[data-client-panel="adjustment"] .client-toolbar-note { justify-content: flex-start; }
  .client-view[data-client-panel="adjustment"] .client-workspace-layout { grid-template-columns: 1fr; }
  .client-view[data-client-panel="adjustment"] .client-slip-panel { min-height: 200px; max-height: 245px; }
  .client-view[data-client-panel="adjustment"] .client-number-panel { padding-left: 0; }
  .client-view[data-client-panel="adjustment"] .client-number-grid { grid-template-columns: repeat(2, minmax(145px, 1fr)); padding-top: 6px; }
  .client-target-stats > div { grid-template-columns: 80px 60px 1fr; padding: 0 6px; }
  .client-target-stats small { font-size: 12px; }
}
