@scope (#page-clients) {
.page-header { display: none !important; }
#clientsContent { min-height: calc(100vh - 74px); background: #f5f7fb; }
#clientsContent .co-page { min-height: calc(100vh - 74px); }
.co-native-link { display: inline-flex; align-items: center; gap: 8px; min-width: 0; padding: 0; border: 0; color: inherit; background: transparent; font: inherit; text-align: left; text-decoration: none; cursor: pointer; }
.co-native-link:hover { color: #405fae; }
.co-customer-cell { width: 100%; }
.co-customer-name { display: flex; min-width: 0; flex-direction: column; gap: 3px; color: #33435d; font-size: 9px; font-weight: 700; }
.co-customer-name small { color: #9aa4b4; font-size: 7px; font-weight: 500; }
.co-phone-cell a, .co-city-cell { display: inline-flex; align-items: center; gap: 5px; color: #718097; font-size: 8px; }
.co-order-count { display: flex; flex-direction: column; gap: 3px; }
.co-order-count strong { color: #53617a; font-size: 10px; }
.co-order-count small { color: #9aa4b4; font-size: 7px; }
.co-native-chart { display: block; width: 100%; height: 100%; overflow: visible; }
.co-chart-point { transition: r .15s ease; }
.co-chart-point:hover { r: 6px; }
.co-chart-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 5px; color: #95a0b0; font-size: 8px; }
.co-chart-legend-dot { display: inline-block; width: 7px; height: 7px; margin-right: 5px; border-radius: 50%; background: #5875df; }
.co-duplicate-panel { margin: 16px 0; }
.co-local-note { display: flex; align-items: center; gap: 7px; padding: 9px 11px; border: 1px solid #e7eefb; border-radius: 8px; color: #7f8eb0; background: #f6f8fe; font-size: 8px; }
.co-local-note svg { flex: 0 0 auto; color: #728bd0; }
.co-table th button { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; color: inherit; background: transparent; font: inherit; font-weight: inherit; cursor: pointer; }
.co-table th button:hover { color: #4d69bc; }
.co-table td { vertical-align: middle; }
.co-rate-cell { display: inline-flex; min-width: 31px; justify-content: flex-end; color: #5874c6; font-size: 9px; font-weight: 730; }
.co-directory-panel { overflow: hidden; }
.co-card-order-link { width: 100%; }
@media (max-width: 620px) { .co-native-chart { min-height: 180px; } }/* Sawbly Clients intelligence workspace */
.co-page {
  --co-ink: #172033;
  --co-copy: #344158;
  --co-muted: #8792a5;
  --co-soft: #a0a9b8;
  --co-line: #e6eaf1;
  --co-indigo: #4d72e8;
  min-height: 100vh;
  color: var(--co-ink);
  background: #f5f7fb;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 12px;
}


.co-page *, .co-page *::before, .co-page *::after { box-sizing: border-box; }
.co-page button, .co-page input, .co-page select { font: inherit; }
.co-page a { color: inherit; text-decoration: none; }
.co-topbar { height: 64px; display: flex; align-items: center; gap: 18px; padding: 0 clamp(18px, 4vw, 54px); border-bottom: 1px solid #e7ebf2; background: rgba(255,255,255,.96); }
.co-back-link { display: inline-flex; align-items: center; gap: 8px; color: #6f7c92; font-size: 11px; font-weight: 680; transition: color .16s ease; }
.co-back-link:hover { color: #3558bc; }
.co-topbar-divider { width: 1px; height: 19px; background: #e8ebf1; }
.co-topbar-trail { display: flex; align-items: center; gap: 9px; color: #9aa4b4; font-size: 10px; }
.co-topbar-trail > span { color: #d0d5df; }
.co-topbar-trail strong { color: #56647b; font-weight: 730; }
.co-topbar-right { display: flex; align-items: center; gap: 9px; margin-left: auto; }
.co-local-pill { display: inline-flex; align-items: center; gap: 6px; margin-right: 9px; padding: 6px 9px; border: 1px solid #e7ebf2; border-radius: 20px; color: #8b96a8; background: #fbfcfe; font-size: 9px; font-weight: 630; }
.co-local-pill > span { width: 6px; height: 6px; border-radius: 50%; background: #41b785; box-shadow: 0 0 0 3px #e8f8f0; }
.co-topbar-avatar { display: grid; place-items: center; width: 31px; height: 31px; border-radius: 10px; color: #4a65b6; background: #e9edff; font-size: 9px; font-weight: 800; }
.co-topbar-user { display: flex; flex-direction: column; gap: 2px; color: #506078; font-size: 10px; font-weight: 700; }
.co-topbar-user small { color: #a1aaba; font-size: 8px; font-weight: 500; }
.co-content { width: min(1440px, 100%); margin: 0 auto; padding: 29px clamp(18px, 4vw, 54px) 42px; }
.co-hero { display: flex; align-items: center; justify-content: space-between; gap: 25px; margin-bottom: 17px; padding: 25px 28px; border: 1px solid #e5eaf3; border-radius: 17px; background: linear-gradient(112deg, #fff 0%, #fff 64%, #f3f6ff 100%); box-shadow: 0 8px 27px rgba(36,54,91,.035); }
.co-hero-copy { min-width: 0; }
.co-eyebrow { display: flex; align-items: center; gap: 7px; margin-bottom: 7px; color: #98a3b4; font-size: 9px; font-weight: 780; letter-spacing: .1em; text-transform: uppercase; }
.co-hero-copy .co-eyebrow svg { color: #7188ce; }
.co-hero h1 { margin: 0; color: #1b2941; font-size: clamp(25px, 3vw, 33px); font-weight: 770; letter-spacing: -1.25px; line-height: 1.15; }
.co-hero h1 em { color: #5572ce; font-style: normal; }
.co-hero-copy > p { max-width: 610px; margin: 8px 0 0; color: #7e8aa0; font-size: 11px; line-height: 1.55; }
.co-date-control { flex: 0 0 228px; display: flex; flex-direction: column; gap: 7px; padding: 13px 14px; border: 1px solid #e8ebf2; border-radius: 11px; background: rgba(255,255,255,.8); }
.co-date-control label { display: flex; align-items: center; gap: 7px; color: #738097; font-size: 9px; font-weight: 710; }
.co-date-control label svg { color: #778bd0; }
.co-date-control select { width: 100%; min-height: 32px; padding: 0 9px; border: 1px solid #e5e9f0; border-radius: 7px; outline: none; color: #35435c; background: #fff; font-size: 10px; font-weight: 650; }
.co-date-control select:focus, .co-filter-bar select:focus, .co-custom-range input:focus, .co-date-filter-row input:focus { border-color: #a6b8ef; box-shadow: 0 0 0 3px rgba(77,114,232,.09); }
.co-date-control small { color: #9ba5b4; font-size: 9px; }
.co-custom-range { display: flex; align-items: center; gap: 9px; width: fit-content; margin: -7px 0 14px auto; padding: 9px 12px; border: 1px solid #e6eaf2; border-radius: 9px; color: #8893a5; background: #fff; font-size: 9px; }
.co-custom-range label { display: flex; align-items: center; gap: 5px; }
.co-custom-range input, .co-date-filter-row input { height: 30px; padding: 0 8px; border: 1px solid #e5e9f0; border-radius: 7px; outline: none; color: #53617a; background: #fbfcfe; font-size: 9px; }
.co-metrics-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 10px; margin-bottom: 17px; }
.co-metric-card { display: flex; align-items: flex-start; gap: 10px; min-width: 0; min-height: 97px; padding: 14px 12px; border: 1px solid var(--co-line); border-radius: 12px; background: #fff; box-shadow: 0 3px 10px rgba(35,55,92,.022); transition: transform .16s ease, box-shadow .16s ease; }
.co-metric-card:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(35,55,92,.06); }
.co-metric-icon { display: grid; flex: 0 0 auto; place-items: center; width: 32px; height: 32px; border-radius: 10px; }
.co-tone-blue { color: #5577de; background: #edf1ff; }
.co-tone-violet { color: #8870ce; background: #f2edff; }
.co-tone-green { color: #25a777; background: #e8f7ef; }
.co-tone-amber { color: #c28b2d; background: #fff5df; }
.co-tone-indigo { color: #5a6fca; background: #edf0ff; }
.co-tone-teal { color: #249b91; background: #e8f7f5; }
.co-tone-rose { color: #c26d72; background: #fff0f0; }
.co-metric-copy { display: flex; flex-direction: column; min-width: 0; gap: 4px; }
.co-metric-label { display: flex; align-items: center; gap: 5px; color: #8490a3; font-size: 9px; font-weight: 660; line-height: 1.25; }
.co-help { display: inline-flex; flex: 0 0 auto; color: #aeb7c5; }
.co-metric-copy > strong { overflow: hidden; color: #26344d; font-size: clamp(15px, 1.55vw, 19px); font-weight: 780; letter-spacing: -.6px; line-height: 1.13; text-overflow: ellipsis; white-space: nowrap; }
.co-metric-copy > small { overflow: hidden; color: #9ba5b4; font-size: 8px; line-height: 1.35; text-overflow: ellipsis; }
.co-overview-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(320px, .88fr); gap: 15px; align-items: stretch; }
.co-panel { min-width: 0; padding: 19px; border: 1px solid var(--co-line); border-radius: 14px; background: #fff; box-shadow: 0 4px 14px rgba(35,55,92,.025); }
.co-panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 13px; margin-bottom: 14px; }
.co-panel-heading .co-eyebrow { margin-bottom: 5px; }
.co-panel-heading h2, .co-directory-heading h2, .co-section-title h2 { display: flex; align-items: center; gap: 8px; margin: 0; color: #27344c; font-size: 15px; font-weight: 760; letter-spacing: -.28px; }
.co-panel-heading p, .co-directory-heading > div > p, .co-section-title > div > p { margin: 5px 0 0; color: #929daf; font-size: 9px; line-height: 1.45; }
.co-subtle-tag { padding: 3px 6px; border-radius: 5px; color: #8794aa; background: #f2f4f8; font-size: 8px; font-weight: 750; letter-spacing: .03em; }
.co-chart-icon, .co-insight-icon { display: grid; flex: 0 0 auto; place-items: center; width: 32px; height: 32px; border-radius: 10px; color: #657ecb; background: #eff2ff; }
.co-chart-wrap { height: 221px; min-width: 0; }
.co-chart-tooltip { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; border: 1px solid #e5e9f1; border-radius: 9px; background: #fff; box-shadow: 0 7px 22px rgba(33,48,82,.11); }
.co-chart-tooltip span { color: #95a0b2; font-size: 9px; }
.co-chart-tooltip strong { color: #35445e; font-size: 12px; }
.co-chart-tooltip small { color: #99a3b2; font-size: 8px; }
.co-chart-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; gap: 8px; color: #9ea8b7; text-align: center; }
.co-chart-empty svg { color: #8295d5; }
.co-chart-empty strong { color: #64728a; font-size: 10px; }
.co-chart-empty span { font-size: 9px; }
.co-chart-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 6px; padding-top: 11px; border-top: 1px solid #f0f2f6; color: #939eae; font-size: 8px; }
.co-chart-foot > span { display: inline-flex; align-items: center; gap: 6px; }
.co-chart-foot small { color: #a3acb9; font-size: 8px; }
.co-chart-legend-dot { width: 7px; height: 7px; border-radius: 50%; background: #5d79df; }
.co-insights-column { display: flex; flex-direction: column; gap: 13px; min-width: 0; }
.co-insight-panel { flex: 1; padding: 16px 17px; }
.co-insight-panel .co-panel-heading { margin-bottom: 9px; }
.co-insight-blue { color: #6980d0; background: #f0f3ff; }
.co-insight-green { color: #35a981; background: #eaf8f1; }
.co-insight-summary { margin: 0 0 9px; color: #718098; font-size: 9px; line-height: 1.5; }
.co-insight-summary strong { color: #33435e; font-size: 11px; font-weight: 770; }
.co-insight-summary span { color: #96a1b1; }
.co-insight-list { display: flex; flex-direction: column; }
.co-insight-client { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 34px; border-top: 1px solid #f2f3f7; color: #a7b0be; }
.co-insight-link { display: flex; align-items: center; gap: 8px; min-width: 0; color: #46556e; transition: color .14s ease; }
.co-insight-link:hover { color: #4569c7; }
.co-insight-link > span:last-child { display: flex; flex-direction: column; gap: 2px; overflow: hidden; font-size: 9px; font-weight: 660; text-overflow: ellipsis; white-space: nowrap; }
.co-insight-link small { color: #a2abba; font-size: 8px; font-weight: 500; }
.co-insight-foot { display: block; margin-top: 8px; color: #a3adba; font-size: 8px; line-height: 1.4; }
.co-insight-empty { display: block; padding: 11px 2px; color: #9da7b6; font-size: 9px; }
.co-return-panel { padding-top: 13px; }
.co-return-panel .co-panel-heading { margin-bottom: 6px; }
.co-return-pills { display: flex; flex-wrap: wrap; gap: 6px; }
.co-return-link { display: inline-flex; }
.co-return-pill { display: inline-flex; align-items: center; gap: 5px; padding: 4px 7px 4px 4px; border: 1px solid #edf0f4; border-radius: 18px; color: #6e7a90; background: #fbfcfe; font-size: 8px; }
.co-return-pill b { display: grid; place-items: center; min-width: 15px; height: 15px; border-radius: 6px; color: #348f70; background: #eaf7f0; font-size: 8px; }
.co-top-section { margin: 25px 0 19px; }
.co-section-title { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 12px; }
.co-section-title .co-eyebrow { margin-bottom: 5px; }
.co-threshold-note { display: flex; align-items: flex-start; gap: 7px; max-width: 610px; padding: 8px 10px; border: 1px solid #e7ebf2; border-radius: 8px; color: #8c97a9; background: rgba(255,255,255,.75); font-size: 8px; line-height: 1.45; }
.co-threshold-note svg { flex: 0 0 auto; color: #7d8fc9; }
.co-rank-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 11px; }
.co-rank-card { min-width: 0; padding: 14px 14px 10px; border: 1px solid var(--co-line); border-radius: 12px; background: #fff; box-shadow: 0 3px 10px rgba(35,55,92,.02); }
.co-rank-heading { display: flex; align-items: center; gap: 9px; min-height: 33px; padding-bottom: 10px; border-bottom: 1px solid #f0f2f6; }
.co-rank-icon { display: grid; flex: 0 0 auto; place-items: center; width: 28px; height: 28px; border-radius: 8px; color: #6178c6; background: #eff2ff; }
.co-rank-heading h3 { margin: 0; color: #43516a; font-size: 10px; font-weight: 740; }
.co-rank-heading p { margin: 3px 0 0; color: #a0a9b7; font-size: 8px; }
.co-rank-list { margin: 0; padding: 0; list-style: none; }
.co-rank-list li { display: flex; align-items: center; gap: 7px; min-width: 0; min-height: 43px; border-bottom: 1px solid #f3f4f7; }
.co-rank-list li:last-child { border-bottom: 0; }
.co-rank-number { flex: 0 0 16px; color: #b1bac7; font-size: 8px; font-weight: 730; }
.co-rank-client { display: flex; align-items: center; gap: 7px; min-width: 0; flex: 1; }
.co-rank-name { display: flex; flex-direction: column; min-width: 0; gap: 2px; overflow: hidden; color: #506078; font-size: 8px; font-weight: 680; text-overflow: ellipsis; white-space: nowrap; }
.co-rank-name small { color: #a1aab7; font-size: 7px; font-weight: 500; }
.co-rank-value { flex: 0 0 auto; max-width: 43%; color: #596984; font-size: 8px; font-weight: 730; text-align: right; }
.co-rank-empty { padding: 15px 0; color: #9ca6b5; font-size: 9px; line-height: 1.5; }
.co-avatar { display: grid; flex: 0 0 auto; place-items: center; width: 34px; height: 34px; border-radius: 11px; color: #465fae; font-size: 10px; font-weight: 800; letter-spacing: -.02em; }
.co-avatar-small { width: 25px; height: 25px; border-radius: 8px; font-size: 8px; }
.co-badge { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 5px; width: fit-content; max-width: 100%; padding: 5px 7px; border: 1px solid transparent; border-radius: 7px; font-size: 8px; font-weight: 720; line-height: 1.1; white-space: nowrap; }
.co-segment-vip { color: #967329; border-color: #f0e5c5; background: #fff8e8; }
.co-segment-regular { color: #5072ca; border-color: #e0e8ff; background: #f0f3ff; }
.co-segment-loyal { color: #248762; border-color: #d8f0e4; background: #eaf8f1; }
.co-segment-new { color: #795cbd; border-color: #e9e1fa; background: #f5f1ff; }
.co-segment-occasional { color: #78869a; border-color: #e8ecf1; background: #f4f6f9; }
.co-review { font-weight: 650; }
.co-review-dot { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.co-review-reliable { color: #27845e; border-color: #d9efe3; background: #eaf8f1; }
.co-review-watch { color: #a97725; border-color: #f3e8ce; background: #fff7e7; }
.co-review-incident { color: #b65c5d; border-color: #f3dddc; background: #fff1f0; }
.co-review-unrated { color: #7d899c; border-color: #e7ebf1; background: #f3f5f8; }
.co-duplicate-panel { margin-bottom: 20px; padding-bottom: 13px; }
.co-duplicate-panel .co-panel-heading { margin-bottom: 13px; }
.co-heading-count { display: inline-grid; place-items: center; min-width: 20px; height: 20px; border-radius: 7px; color: #ab7928; background: #fff4df; font-size: 9px; }
.co-quiet-button, .co-link-button { display: inline-flex; align-items: center; gap: 5px; padding: 6px 3px; border: 0; color: #75839b; background: transparent; font-size: 9px; font-weight: 660; cursor: pointer; }
.co-quiet-button:hover, .co-link-button:hover { color: #4868bd; }
.co-chevron-up { transform: rotate(180deg); }
.co-duplicate-item { display: flex; align-items: flex-start; gap: 12px; padding: 13px 2px; border-top: 1px solid #f0f2f6; }
.co-duplicate-mark { display: grid; flex: 0 0 auto; place-items: center; width: 34px; height: 34px; border-radius: 10px; color: #bd8e3d; background: #fff6e6; }
.co-duplicate-main { flex: 1; min-width: 0; }
.co-duplicate-profiles { display: flex; align-items: center; gap: 15px; }
.co-duplicate-profiles > div { display: flex; flex-direction: column; min-width: 0; gap: 4px; }
.co-duplicate-profiles small { color: #9ba5b4; font-size: 8px; }
.co-duplicate-name, .co-duplicate-profiles strong { color: #46546d; font-size: 10px; font-weight: 730; }
.co-duplicate-name:hover { color: #4567bf; }
.co-duplicate-profiles span { overflow-wrap: anywhere; color: #748198; font-size: 9px; }
.co-duplicate-profiles em { color: #a4adba; font-size: 8px; font-style: normal; }
.co-duplicate-arrow { flex: 0 0 auto; color: #b8c1ce; }
.co-duplicate-main > p { display: flex; align-items: center; gap: 5px; margin: 8px 0 0; color: #a0a9b7; font-size: 8px; }
.co-duplicate-main > p svg { color: #9ba8c0; }
.co-duplicate-actions { display: flex; flex: 0 0 auto; flex-direction: column; align-items: flex-end; gap: 6px; min-width: 137px; }
.co-button { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 30px; padding: 0 9px; border: 1px solid transparent; border-radius: 7px; font-size: 8px; font-weight: 710; cursor: pointer; transition: background .15s ease, transform .15s ease; }
.co-button:hover { transform: translateY(-1px); }
.co-button-outline { border-color: #e1e7f3; color: #5e73bb; background: #fff; }
.co-button-outline:hover { background: #f5f7ff; }
.co-button-muted { border-color: #edf0f4; color: #78859a; background: #f7f8fa; }
.co-button-muted:hover { background: #eff2f7; }
.co-decision-label { display: inline-flex; align-items: center; gap: 5px; color: #328665; font-size: 8px; font-weight: 710; }
.co-decision-separate { color: #677895; }
.co-empty-inline { display: flex; align-items: center; gap: 11px; padding: 15px 4px; border-top: 1px solid #f0f2f6; color: #8494c6; }
.co-empty-inline > div { display: flex; flex-direction: column; gap: 4px; }
.co-empty-inline strong { color: #637189; font-size: 10px; }
.co-empty-inline span { color: #9ba5b4; font-size: 9px; }
.co-local-note { display: flex; align-items: flex-start; gap: 6px; margin-top: 8px; padding-top: 10px; border-top: 1px solid #f1f3f7; color: #929db0; font-size: 8px; line-height: 1.45; }
.co-local-note svg { flex: 0 0 auto; color: #8092c9; }
.co-directory-panel { padding: 20px 0 0; overflow: hidden; }
.co-directory-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; padding: 0 20px; }
.co-directory-heading .co-eyebrow { margin-bottom: 5px; }
.co-view-toggle { display: inline-flex; flex: 0 0 auto; padding: 3px; border: 1px solid #e7ebf2; border-radius: 8px; background: #f8f9fb; }
.co-view-toggle button { display: inline-flex; align-items: center; gap: 5px; min-height: 28px; padding: 0 9px; border: 0; border-radius: 6px; color: #8994a6; background: transparent; font-size: 8px; font-weight: 680; cursor: pointer; }
.co-view-toggle button.is-active { color: #4c67bc; background: #fff; box-shadow: 0 1px 4px rgba(32,49,85,.1); }
.co-filter-bar { display: flex; flex-wrap: wrap; gap: 7px; padding: 15px 20px 10px; }
.co-search { display: flex; flex: 1 1 220px; align-items: center; gap: 7px; min-width: 190px; height: 33px; padding: 0 9px; border: 1px solid #e6eaf1; border-radius: 8px; color: #9ba6b5; background: #fbfcfe; }
.co-search:focus-within { border-color: #a6b8ef; box-shadow: 0 0 0 3px rgba(77,114,232,.08); }
.co-search input { width: 100%; min-width: 0; border: 0; outline: 0; color: #41506a; background: transparent; font-size: 9px; }
.co-search input::placeholder { color: #a4adba; }
.co-search button { display: grid; place-items: center; padding: 3px; border: 0; color: #9aa5b4; background: transparent; cursor: pointer; }
.co-filter-bar select { flex: 0 1 auto; min-width: 112px; height: 33px; padding: 0 25px 0 8px; border: 1px solid #e6eaf1; border-radius: 8px; outline: 0; color: #647188; background: #fbfcfe; font-size: 8px; }
.co-date-filter-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; min-height: 43px; padding: 0 20px 11px; color: #8995a8; font-size: 8px; }
.co-date-filter-row > span:first-child { display: inline-flex; align-items: center; gap: 5px; margin-right: 3px; font-weight: 690; }
.co-date-filter-row > span:first-child svg { color: #8d9cc7; }
.co-date-filter-row label { display: inline-flex; align-items: center; gap: 5px; }
.co-date-filter-row input { height: 27px; padding: 0 6px; font-size: 8px; }
.co-clear-filters { display: inline-flex; align-items: center; gap: 4px; padding: 4px 3px; border: 0; color: #6780ce; background: transparent; font-size: 8px; font-weight: 660; cursor: pointer; }
.co-result-count { margin-left: auto; color: #929daf; font-size: 8px; }
.co-table-scroll { overflow-x: auto; border-top: 1px solid #edf0f4; }
.co-table { width: 100%; min-width: 1030px; border-collapse: collapse; text-align: left; }
.co-table th { height: 38px; padding: 0 11px; color: #929daf; background: #fbfcfe; font-size: 8px; font-weight: 690; white-space: nowrap; }
.co-table th:first-child, .co-table td:first-child { padding-left: 20px; }
.co-table th:last-child, .co-table td:last-child { padding-right: 20px; }
.co-table th button { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; color: inherit; background: transparent; font: inherit; cursor: pointer; }
.co-table th button:hover { color: #536dbb; }
.co-table th button svg { color: #b3bdca; }
.co-table td { height: 58px; padding: 8px 11px; border-top: 1px solid #f0f2f6; color: #526079; font-size: 9px; vertical-align: middle; }
.co-table tbody tr { transition: background .14s ease; }
.co-table tbody tr:hover { background: #fbfcff; }
.co-customer-cell { display: flex; align-items: center; gap: 9px; min-width: 150px; }
.co-customer-cell:hover .co-customer-name { color: #4969c3; }
.co-customer-name { display: flex; flex-direction: column; min-width: 0; gap: 3px; color: #43516a; font-size: 9px; font-weight: 730; line-height: 1.25; transition: color .14s ease; }
.co-customer-name small { color: #a2abba; font-size: 8px; font-weight: 510; }
.co-phone-cell a, .co-city-cell { display: inline-flex; align-items: center; gap: 5px; color: #6f7c92; font-size: 8px; white-space: nowrap; }
.co-phone-cell a svg { color: #8e9ac0; }
.co-phone-cell a:hover { color: #486bc3; }
.co-city-cell svg { flex: 0 0 auto; color: #a0aabd; }
.co-order-count { display: flex; flex-direction: column; gap: 4px; white-space: nowrap; }
.co-order-count strong { color: #46546d; font-size: 10px; font-weight: 760; }
.co-order-count small { color: #98a2b2; font-size: 7px; }
.co-value-cell { color: #41516b; font-size: 9px; font-weight: 740; white-space: nowrap; }
.co-date-cell { display: flex; flex-direction: column; gap: 4px; color: #64728a; font-size: 8px; white-space: nowrap; }
.co-last-order-link { display: inline-flex; align-items: center; gap: 3px; width: fit-content; color: #6380ce; font-size: 7px; font-weight: 650; }
.co-last-order-link:hover { color: #3457b5; text-decoration: underline; }
.co-card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 2px 20px 19px; }
.co-directory-card { min-width: 0; padding: 14px; border: 1px solid #e9edf3; border-radius: 11px; background: #fff; transition: transform .15s ease, box-shadow .15s ease; }
.co-directory-card:hover { transform: translateY(-2px); box-shadow: 0 8px 18px rgba(35,55,92,.06); }
.co-directory-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.co-directory-card-head .co-customer-cell { min-width: 0; }
.co-directory-card-head .co-customer-name { max-width: 175px; }
.co-card-contact { display: flex; flex-wrap: wrap; gap: 8px 13px; margin-top: 12px; padding: 10px 0; border-top: 1px solid #f1f3f6; border-bottom: 1px solid #f1f3f6; color: #77849a; font-size: 8px; }
.co-card-contact a, .co-card-contact > span { display: inline-flex; align-items: center; gap: 5px; }
.co-card-contact svg { color: #92a0bf; }
.co-card-contact a:hover { color: #496bc4; }
.co-card-stats { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 7px; padding: 10px 0; }
.co-card-stats > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.co-card-stats strong { overflow: hidden; color: #46546d; font-size: 11px; font-weight: 760; text-overflow: ellipsis; white-space: nowrap; }
.co-card-stats small { color: #9aa4b4; font-size: 7px; }
.co-card-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.co-card-bottom > span:last-child { color: #98a3b3; font-size: 7px; text-align: right; }
.co-card-order-link { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; padding-top: 9px; border-top: 1px solid #f1f3f6; color: #627bc8; font-size: 8px; font-weight: 680; }
.co-card-order-link:hover { color: #395bb9; }
.co-directory-empty { display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 40px 15px; border-top: 1px solid #edf0f4; color: #9aa5b4; text-align: center; }
.co-directory-empty > span { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 13px; color: #8396d2; background: #f0f3ff; }
.co-directory-empty strong { color: #586780; font-size: 11px; }
.co-directory-empty p { margin: 0; font-size: 9px; }
.co-directory-empty button { margin-top: 4px; padding: 7px 10px; border: 1px solid #e1e7f2; border-radius: 7px; color: #5d74c0; background: #fff; font-size: 8px; font-weight: 680; cursor: pointer; }
.co-directory-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 11px 20px; border-top: 1px solid #edf0f4; color: #9aa4b3; font-size: 8px; }
.co-directory-foot > span { display: inline-flex; align-items: center; gap: 5px; }
.co-directory-foot svg { color: #7d91cf; }
.co-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; padding: 0 2px; color: #99a4b3; font-size: 8px; }
.co-footer > span, .co-footer-link { display: inline-flex; align-items: center; gap: 6px; }
.co-footer > span svg { color: #8597ce; }
.co-footer-link { color: #7485bd; font-weight: 660; }
.co-footer-link:hover { color: #3d5db6; }
.co-page button:focus-visible, .co-page a:focus-visible, .co-page input:focus-visible, .co-page select:focus-visible { outline: 3px solid rgba(77,114,232,.23); outline-offset: 2px; }

@media (max-width: 1250px) {
  .co-metrics-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .co-metric-copy > strong { font-size: 18px; }
  .co-rank-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .co-overview-grid { grid-template-columns: minmax(0, 1.2fr) minmax(300px, .9fr); }
}
@media (min-width: 1251px) and (max-width: 1600px) {
  .co-metric-card { gap: 7px; padding-right: 8px; padding-left: 8px; }
  .co-metric-copy > strong { font-size: 16px; }
}
@media (max-width: 900px) {
  .co-overview-grid { grid-template-columns: 1fr; }
  .co-insights-column { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); }
  .co-directory-foot { align-items: flex-start; flex-direction: column; }
  .co-card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .co-section-title { align-items: flex-start; flex-direction: column; gap: 10px; }
  .co-threshold-note { max-width: none; }
}
@media (max-width: 620px) {
  .co-topbar { height: 57px; gap: 11px; padding: 0 15px; }
  .co-back-link { gap: 5px; font-size: 9px; }
  .co-topbar-divider { height: 16px; }
  .co-topbar-trail { gap: 6px; font-size: 9px; }
  .co-local-pill { margin-right: 0; padding: 5px 6px; font-size: 0; }
  .co-local-pill > span { width: 7px; height: 7px; }
  .co-topbar-avatar { width: 27px; height: 27px; }
  .co-topbar-user { display: none; }
  .co-content { padding: 18px 13px 30px; }
  .co-hero { align-items: stretch; flex-direction: column; gap: 15px; padding: 19px 17px; }
  .co-hero h1 { font-size: 26px; }
  .co-hero-copy > p { font-size: 10px; }
  .co-date-control { flex: auto; width: 100%; }
  .co-custom-range { margin: -5px 0 12px; flex-wrap: wrap; }
  .co-metrics-grid { grid-template-columns: repeat(2, minmax(0,1fr)); gap: 8px; }
  .co-metric-card { min-height: 85px; gap: 8px; padding: 11px 9px; }
  .co-metric-icon { width: 29px; height: 29px; border-radius: 9px; }
  .co-metric-icon svg { width: 15px; height: 15px; }
  .co-metric-copy > strong { font-size: 16px; }
  .co-metric-label { font-size: 8px; }
  .co-metric-copy > small { font-size: 7px; }
  .co-panel { padding: 15px; }
  .co-chart-wrap { height: 195px; }
  .co-chart-foot { align-items: flex-start; flex-direction: column; gap: 5px; }
  .co-insights-column { grid-template-columns: 1fr; }
  .co-rank-grid { grid-template-columns: 1fr; gap: 8px; }
  .co-rank-card { padding: 12px 13px 8px; }
  .co-threshold-note { font-size: 8px; }
  .co-duplicate-item { flex-wrap: wrap; gap: 9px; }
  .co-duplicate-main { flex-basis: calc(100% - 45px); }
  .co-duplicate-actions { flex-direction: row; align-items: center; justify-content: flex-end; width: 100%; min-width: 0; }
  .co-duplicate-profiles { gap: 8px; }
  .co-duplicate-profiles em { display: block; margin-top: 2px; }
  .co-directory-panel { padding-top: 15px; }
  .co-directory-heading { align-items: flex-start; flex-direction: column; padding: 0 14px; }
  .co-view-toggle { align-self: flex-end; margin-top: -2px; }
  .co-filter-bar { flex-direction: column; align-items: stretch; padding: 13px 14px 9px; }
  .co-search { flex-basis: auto; min-width: 0; }
  .co-filter-bar select { width: 100%; }
  .co-date-filter-row { align-items: flex-start; padding: 0 14px 11px; }
  .co-date-filter-row > span:first-child { width: 100%; }
  .co-date-filter-row label { flex: 1 1 auto; }
  .co-date-filter-row input { max-width: 100%; }
  .co-result-count { margin-left: auto; }
  .co-card-grid { grid-template-columns: 1fr; padding: 2px 13px 14px; }
  .co-directory-foot { padding: 10px 14px; line-height: 1.5; }
  .co-footer { align-items: flex-start; flex-direction: column; margin-top: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .co-page *, .co-page *::before, .co-page *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

.co-definitions { margin: -8px 0 16px; border: 1px solid #e7ebf2; border-radius: 10px; background: rgba(255,255,255,.72); }
.co-definitions summary { display: flex; align-items: center; gap: 7px; padding: 9px 12px; color: #75829a; font-size: 9px; font-weight: 690; cursor: pointer; list-style: none; }
.co-definitions summary::-webkit-details-marker { display: none; }
.co-definitions summary svg { color: #8293cb; }
.co-definitions[open] summary { border-bottom: 1px solid #edf0f4; }
.co-definitions > div { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 13px; padding: 11px 13px; }
.co-definitions p { margin: 0; color: #8792a4; font-size: 8px; line-height: 1.55; }
.co-definitions p strong { color: #576680; font-weight: 720; }
.co-rate-cell { display: inline-flex; min-width: 31px; justify-content: flex-end; color: #5874c6; font-size: 9px; font-weight: 730; }
.co-table { min-width: 1120px; }
/* Refined clients overview controls and directory hierarchy. */
.co-date-control { flex-basis: 284px; gap: 9px; padding: 16px 17px; border-color: #e0e6f1; border-radius: 14px; background: rgba(255,255,255,.92); box-shadow: 0 7px 20px rgba(42,61,101,.045); }
.co-date-control label { color: #657696; font-size: 11px; }
.co-date-control label svg { width: 17px; height: 17px; }
.co-date-control select { min-height: 39px; padding: 0 12px; border-radius: 9px; color: #273650; font-size: 12px; }
.co-date-control small { font-size: 10px; }
.co-rank-grid { gap: 14px; }
.co-rank-card { padding: 17px 17px 12px; border-radius: 14px; box-shadow: 0 4px 14px rgba(35,55,92,.035); }
.co-rank-heading { gap: 11px; min-height: 43px; padding-bottom: 12px; }
.co-rank-icon { width: 36px; height: 36px; border-radius: 11px; color: #5272d7; background: #eef2ff; }
.co-rank-icon svg { width: 19px; height: 19px; }
.co-rank-heading h3 { color: #34435e; font-size: 11px; }
.co-rank-heading p { font-size: 9px; }
.co-rank-list li { min-height: 53px; gap: 9px; }
.co-rank-number { flex-basis: 20px; font-size: 9px; }
.co-rank-name { font-size: 9px; }
.co-rank-name small { font-size: 8px; }
.co-rank-value { font-size: 9px; }
.co-directory-panel { border-radius: 17px; box-shadow: 0 7px 22px rgba(35,55,92,.035); }
.co-directory-heading { padding: 2px 24px 0; }
.co-directory-heading h2 { font-size: 18px; }
.co-directory-heading > div > p { max-width: 760px; margin-top: 7px; font-size: 10px; }
.co-view-toggle { padding: 4px; border-radius: 10px; }
.co-view-toggle button { min-height: 34px; padding: 0 12px; font-size: 9px; }
.co-filter-bar { gap: 9px; padding: 18px 24px 12px; }
.co-search, .co-filter-bar select { height: 39px; border-radius: 9px; }
.co-search { padding: 0 12px; }
.co-search input, .co-filter-bar select { font-size: 10px; }
.co-filter-bar select { min-width: 145px; padding-left: 11px; }
.co-date-filter-row { min-height: 49px; gap: 10px; padding: 0 24px 13px; font-size: 9px; }
.co-date-filter-row input { height: 33px; padding: 0 9px; font-size: 9px; }
.co-result-count { font-size: 9px; }
.co-table th { height: 46px; padding-right: 13px; padding-left: 13px; font-size: 9px; }
.co-table th:first-child, .co-table td:first-child { padding-left: 24px; }
.co-table th:last-child, .co-table td:last-child { padding-right: 24px; }
.co-table td { height: 68px; padding: 10px 13px; font-size: 10px; }
.co-customer-cell { gap: 11px; min-width: 175px; }
.co-customer-name { font-size: 10px; }
.co-customer-name small { font-size: 9px; }
.co-phone-cell a, .co-city-cell { font-size: 9px; }
.co-order-count strong, .co-value-cell { font-size: 11px; }
.co-order-count small { font-size: 8px; }
.co-date-cell { font-size: 9px; }
.co-card-grid { gap: 13px; padding: 4px 24px 23px; }
.co-directory-card { padding: 18px; border-color: #e4e9f2; border-radius: 14px; box-shadow: 0 3px 10px rgba(35,55,92,.018); }
.co-directory-card-head .co-customer-name { max-width: none; }
.co-card-contact { margin-top: 14px; padding: 12px 0; font-size: 9px; }
.co-card-stats { padding: 13px 0; }
.co-card-stats strong { font-size: 13px; }
.co-card-stats small, .co-card-bottom > span:last-child { font-size: 8px; }
.co-card-order-link { margin-top: 14px; padding-top: 12px; font-size: 9px; }
@media (max-width: 1250px) { .co-date-control { flex-basis: 260px; } .co-filter-bar select { min-width: 128px; } }
@media (max-width: 620px) {
  .co-date-control { flex-basis: auto; padding: 14px; }
  .co-rank-card { padding: 13px 14px 9px; }
  .co-directory-heading { padding: 0 14px; }
  .co-directory-heading h2 { font-size: 16px; }
  .co-filter-bar { gap: 8px; padding: 13px 14px 9px; }
  .co-search, .co-filter-bar select { height: 39px; }
  .co-date-filter-row { gap: 7px; padding: 0 14px 11px; }
  .co-table th:first-child, .co-table td:first-child { padding-left: 14px; }
  .co-table th:last-child, .co-table td:last-child { padding-right: 14px; }
  .co-table td { height: 62px; }
  .co-card-grid { gap: 10px; padding: 2px 13px 14px; }
  .co-directory-card { padding: 15px; }
}
/* Keep this light workspace legible under the dashboard-wide dark form theme. */
body.vm-upgrade #page-clients .co-page .co-filter-bar select,
body.vm-upgrade #page-clients .co-page .co-date-filter-row input {
  color: #53617a !important;
  background-color: #fbfcfe !important;
  border-color: #e5e9f0 !important;
  color-scheme: light;
}
body.vm-upgrade #page-clients .co-page select[data-co],
body.vm-upgrade #page-clients .co-page input[data-co="from"],
body.vm-upgrade #page-clients .co-page input[data-co="to"] {
  color: #53617a !important;
  background: #fbfcfe !important;
  border: 1px solid #e5e9f0 !important;
  color-scheme: light !important;
}
body.vm-upgrade #page-clients .co-page .co-search input {
  color: #41506a !important;
  background: transparent !important;
  border: 0 !important;
  color-scheme: light !important;
}
body.vm-upgrade #page-clients .co-page .co-table th { background-color: #fbfcfe !important; color: #77849a !important; }
body.vm-upgrade #page-clients .co-page .co-table td { color: #526079 !important; border-color: #edf0f4 !important; }
body.vm-upgrade #page-clients .co-page .co-filter-bar select:focus,
body.vm-upgrade #page-clients .co-page .co-date-filter-row input:focus { border-color: #a6b8ef !important; box-shadow: 0 0 0 3px rgba(77,114,232,.09) !important; }
@media (max-width: 620px) {
  .co-definitions > div { grid-template-columns: 1fr; gap: 7px; }
  .co-definitions { margin-top: -3px; }
}

}
/* Page-level exception to vm-pro's globally enforced dark input theme. */
#page-clients select[data-co],
#page-clients input[data-co="from"],
#page-clients input[data-co="to"] {
  color: #53617a !important;
  background: #fbfcfe !important;
  border: 1px solid #e5e9f0 !important;
  color-scheme: light !important;
}
#page-clients .co-search input { color: #41506a !important; background: transparent !important; border: 0 !important; }
body.vm-upgrade #page-clients .co-page .co-filter-bar select,
body.vm-upgrade #page-clients .co-page .co-date-filter-row input {
  color: #53617a !important;
  background-color: #fbfcfe !important;
  border-color: #e5e9f0 !important;
  color-scheme: light;
}
body.vm-upgrade #page-clients .co-page .co-table th { background-color: #fbfcfe !important; color: #77849a !important; }
body.vm-upgrade #page-clients .co-page .co-table td { color: #526079 !important; border-color: #edf0f4 !important; }
body.vm-upgrade #page-clients .co-page .co-filter-bar select:focus,
body.vm-upgrade #page-clients .co-page .co-date-filter-row input:focus { border-color: #a6b8ef !important; box-shadow: 0 0 0 3px rgba(77,114,232,.09) !important; }
/* High-specificity light controls for the client workspace, after global theme rules. */
body.vm-upgrade #page-clients .co-page select[data-co],
body.vm-upgrade #page-clients .co-page input[data-co="from"],
body.vm-upgrade #page-clients .co-page input[data-co="to"] {
  color: #53617a !important;
  background-color: #fbfcfe !important;
  border: 1px solid #e5e9f0 !important;
  color-scheme: light !important;
}
body.vm-upgrade #page-clients .co-page .co-search input[data-co="search"] {
  color: #41506a !important;
  background-color: transparent !important;
  border: 0 !important;
  color-scheme: light !important;
}
/* Native select rendering can retain the host dark appearance; force the light client controls. */
body.vm-upgrade #page-clients .co-page .co-date-control select[data-co="period"],
body.vm-upgrade #page-clients .co-page .co-filter-bar select[data-co],
body.vm-upgrade #page-clients .co-page .co-date-filter-row input[data-co] {
  -webkit-appearance: none !important;
  appearance: none !important;
  color: #35435c !important;
  background-color: #ffffff !important;
  border-color: #e5e9f0 !important;
  color-scheme: light !important;
}
/* Directory filters: use a light native-control surface inside the embedded CRM. */
#page-clients #clientsContent .co-page .co-filter-bar select[data-co] {
  -webkit-appearance: none !important;
  appearance: none !important;
  color: #53617a !important;
  background-color: #fff !important;
  border: 1px solid #e5e9f0 !important;
  color-scheme: light !important;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 14 14'%3E%3Cpath d='m3 5 4 4 4-4' fill='none' stroke='%2364758b' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
  background-repeat: no-repeat !important;
  background-position: right 9px center !important;
  background-size: 14px !important;
}

/* Filters in this dashboard are enhanced into .vm-select buttons; style the
   visible trigger as well as the hidden native select. */
body.vm-upgrade #page-clients #clientsContent .co-filter-bar .vm-select-trigger {
  color: #53617a !important;
  background: #fff !important;
  border: 1px solid #e5e9f0 !important;
  box-shadow: none !important;
}
body.vm-upgrade #page-clients #clientsContent .co-filter-bar .vm-select-trigger:hover,
body.vm-upgrade #page-clients #clientsContent .co-filter-bar .vm-select-trigger[aria-expanded="true"] {
  color: #35435c !important;
  background: #fbfcfe !important;
  border-color: #a6b8ef !important;
  box-shadow: 0 0 0 3px rgba(77, 114, 232, .09) !important;
}

/* Let the customer workspace use the full dashboard canvas. */
body.vm-upgrade #page-clients #clientsContent .co-content {
  width: 100% !important;
  max-width: none !important;
  margin-inline: 0 !important;
  padding-inline: clamp(16px, 2vw, 30px) !important;
}

/* Match the reference directory table's proportions and row rhythm. */
body.vm-upgrade #page-clients #clientsContent .co-table-scroll {
  overflow-x: auto;
}
body.vm-upgrade #page-clients #clientsContent .co-table {
  width: 100% !important;
  min-width: 1240px !important;
  table-layout: fixed;
}
body.vm-upgrade #page-clients #clientsContent .co-table th,
body.vm-upgrade #page-clients #clientsContent .co-table td {
  padding-inline: 16px !important;
}
body.vm-upgrade #page-clients #clientsContent .co-table th {
  height: 48px !important;
  font-size: 10px !important;
}
body.vm-upgrade #page-clients #clientsContent .co-table td {
  height: 70px !important;
  font-size: 11px !important;
  border-top-color: #edf0f4 !important;
}
body.vm-upgrade #page-clients #clientsContent .co-table td:first-child,
body.vm-upgrade #page-clients #clientsContent .co-table th:first-child { width: 19%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(2),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(2) { width: 16%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(3),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(3) { width: 10%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(4),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(4) { width: 11%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(5),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(5) { width: 10%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(6),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(6) { width: 9%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(7),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(7) { width: 13%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(8),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(8) { width: 11%; }
body.vm-upgrade #page-clients #clientsContent .co-table td:nth-child(9),
body.vm-upgrade #page-clients #clientsContent .co-table th:nth-child(9) { width: 11%; }

/* Theme bridge: keep the client workspace on the dashboard's active palette. */
body.vm-upgrade #page-clients #clientsContent {
  background: var(--bg) !important;
  color: var(--text) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page {
  --co-ink: var(--text);
  --co-copy: var(--text2);
  --co-muted: var(--text2);
  --co-soft: var(--muted);
  --co-line: var(--border);
  --co-indigo: var(--accent);
  color: var(--text) !important;
  background: var(--bg) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page :is(.co-hero,.co-metric-card,.co-panel,.co-rank-card,.co-directory-card,.co-chart-tooltip,.co-date-control,.co-local-pill,.co-view-toggle,.co-search,.co-filter-bar .vm-select-trigger,.co-date-filter-row input,.co-definitions,.co-table th) {
  background-color: var(--surface) !important;
  border-color: var(--border) !important;
  color: var(--text) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page :is(.co-hero,.co-date-control,.co-threshold-note) {
  background-image: none !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page :is(h1,h2,h3,.co-customer-name,.co-customer-name small,.co-panel-heading p,.co-directory-heading > div > p,.co-section-title > div > p,.co-eyebrow,.co-date-control label,.co-date-control > span,.co-insight-summary,.co-insight-foot,.co-rank-heading h3,.co-rank-heading p,.co-rank-name,.co-rank-name small,.co-rank-value,.co-rank-empty,.co-table th,.co-table td,.co-phone-cell a,.co-city-cell,.co-order-count strong,.co-order-count small,.co-date-cell,.co-directory-foot,.co-result-count,.co-date-filter-row,.co-date-filter-row label,.co-local-note,.co-local-note span,.co-search,.co-search input,.co-search input::placeholder,.co-filter-bar .vm-select-value,.co-filter-bar .vm-select-chevron,.co-view-toggle button,.co-view-toggle button.is-active,.co-threshold-note,.co-section-title,.co-chart-foot,.co-chart-foot small,.co-insight-empty,.co-empty,.co-footer) {
  color: var(--text) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page :is(.co-subtle-tag,.co-return-pill,.co-review-unrated,.co-segment-occasional,.co-button-muted,.co-date-filter-row input,.co-filter-bar .vm-select-trigger,.co-view-toggle,.co-view-toggle button.is-active,.co-local-note,.co-threshold-note,.co-search) {
  background-color: var(--surface2) !important;
  border-color: var(--border) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page :is(.co-table td,.co-table th,.co-rank-heading,.co-rank-list li,.co-insight-client,.co-chart-foot,.co-local-note,.co-directory-foot,.co-directory-panel,.co-date-filter-row,.co-directory-heading) {
  border-color: var(--border) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page :is(.co-segment-vip,.co-segment-regular,.co-segment-loyal,.co-segment-new,.co-segment-occasional,.co-review-reliable,.co-review-watch,.co-review-incident,.co-review-unrated,.co-tone-blue,.co-tone-violet,.co-tone-green,.co-tone-amber,.co-tone-indigo,.co-tone-teal,.co-tone-rose,.co-insight-blue,.co-insight-green,.co-chart-icon,.co-insight-icon,.co-rank-icon,.co-avatar,.co-heading-count) {
  background-color: color-mix(in srgb, var(--accent) 14%, var(--surface2)) !important;
  border-color: color-mix(in srgb, var(--accent) 30%, var(--border)) !important;
  color: var(--accent) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page :is(.co-hero h1 em,.co-chart-legend-dot,.co-rate-cell,.co-directory-panel a:hover,.co-table th button:hover,.co-clear-filters,.co-view-toggle button.is-active) {
  color: var(--accent) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page .co-table tbody tr:hover {
  background: color-mix(in srgb, var(--accent) 7%, var(--surface)) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page .co-filter-bar .vm-select-trigger:hover,
body.vm-upgrade #page-clients #clientsContent .co-page .co-filter-bar .vm-select-trigger[aria-expanded="true"] {
  background: var(--surface2) !important;
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--accent) 16%, transparent) !important;
}
body.vm-upgrade #page-clients #clientsContent .co-page .co-date-filter-row input[data-co] {
  color: var(--text) !important;
  background-color: var(--surface2) !important;
  border-color: var(--border) !important;
}

/* Orders Workspace already consumes dashboard variables; these surfaces were
   still pinned to white in its card, table, and toolbar rules. */
body.vm-upgrade #page-orders {
  background: var(--bg) !important;
  color: var(--text) !important;
}
body.vm-upgrade #page-orders :is(.orders-toolbar-header,.panel,.table-wrap,.orders-sheet-tabs-wrap,.vm-source,.filter-sel,#orders-search,.orders-filter-chip,.orders-empty,.empty) {
  background-color: var(--surface) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}
body.vm-upgrade #page-orders :is(thead th,.panel-header,.orders-sheet-tabs-wrap,.orders-toolbar-header) {
  background-color: var(--surface) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}
body.vm-upgrade #page-orders tbody tr {
  background: var(--surface) !important;
  border-color: var(--border) !important;
}
body.vm-upgrade #page-orders tbody tr:nth-child(even) {
  background: var(--surface2) !important;
}
body.vm-upgrade #page-orders tbody tr:hover {
  background: color-mix(in srgb, var(--accent) 10%, var(--surface2)) !important;
}
body.vm-upgrade #page-orders :is(td,th,.panel-title,.orders-toolbar-header label,.vm-order-date,.vm-order-city,.vm-order-phone,.vm-order-product,.vm-order-quantity,#orders-search::placeholder) {
  color: var(--text2) !important;
}
body.vm-upgrade #page-orders :is(.vm-order-number,.vm-order-total,.vm-order-customer,.panel h2) {
  color: var(--text) !important;
}
body.vm-upgrade #page-orders .orders-toolbar-header .vm-select-trigger:not(.vm-select-status .vm-select-trigger) {
  background: var(--surface2) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
}
