#page-orders-workspace{padding:0!important;min-width:0;max-width:100%}.crm-shell{--ink:#edf2ff;--muted:#8d9fbc;color:var(--ink);font-family:Inter,Cairo,sans-serif;background:radial-gradient(ellipse at 12% 0,rgba(103,49,225,.09),transparent 40%),#050e1a;padding:24px;min-height:85vh;max-width:100%;box-sizing:border-box}.crm-shell *{box-sizing:border-box}.crm-shell h1{font-size:28px;letter-spacing:-.8px;margin:7px 0}.crm-shell h2{font-size:16px;margin:0 0 20px}.crm-shell p{line-height:1.7}.crm-shell small{display:block;font-size:11px;line-height:1.7;color:var(--muted)}.crm-shell button,.crm-shell input,.crm-shell select,.crm-shell textarea{font:inherit;color:var(--ink);background:#0c1729;border:1px solid #20314d;border-radius:8px;padding:10px 12px;max-width:100%;min-width:0}.crm-shell button{cursor:pointer;font-size:12px;font-weight:600;transition:background .15s,border .15s}.crm-shell button:hover{background:#192442;border-color:#8353ef}.crm-shell button:disabled{opacity:.4;cursor:not-allowed}.crm-shell :focus-visible{outline:2px solid #ab86ff;outline-offset:3px}.crm-shell a{color:#0cdda9;font-size:11px;text-decoration:none}.crm-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;margin:22px 0}.crm-heading>button{background:linear-gradient(120deg,#8243ff,#5b29e7);border-color:#945bff;min-height:44px}.crm-heading p{margin:4px 0;color:var(--muted);font-size:13px}.crm-eyebrow{color:#a68bcf;letter-spacing:2px;font-size:10px}.crm-stats{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:12px;margin:24px 0}.crm-stats>div{border:1px solid #1b2940;border-radius:12px;padding:18px 12px;background:linear-gradient(140deg,#11172b,#07131f);display:flex;gap:12px;align-items:center;min-width:0}.crm-stats strong{font-size:24px;display:block;line-height:1.3}.crm-stat-icon{color:var(--accent);background:color-mix(in srgb,var(--accent),transparent 85%);padding:12px;border-radius:10px;font-size:24px}.crm-toolbar{display:flex;flex-wrap:wrap;gap:10px;align-items:end;margin:18px 0}.crm-toolbar label{font-size:10px;color:var(--muted);display:flex;flex-direction:column;gap:5px;min-width:100px;max-width:180px}.crm-toolbar>input{flex:1 1 240px;min-height:40px}.crm-toolbar input[type=checkbox]{width:16px;height:16px}.crm-toolbar label:has([type=checkbox]){flex-direction:row;align-items:center;min-height:40px}.crm-toolbar select{width:100%;font-size:11px}.crm-results{display:flex;justify-content:space-between;align-items:center;color:var(--muted);font-size:12px;margin:18px 0}.crm-results button{margin-left:5px}.crm-board{display:flex;overflow-x:auto;gap:12px;align-items:stretch;scroll-snap-type:x proximity;padding-bottom:14px;max-width:100%;scrollbar-color:#574576 #0b1324}.crm-column{flex:0 0 246px;min-width:0;border:1px solid color-mix(in srgb,var(--accent),transparent 48%);border-radius:12px;background:linear-gradient(180deg,color-mix(in srgb,var(--accent),transparent 90%),#070e1b 160px);overflow:hidden;scroll-snap-align:start}.crm-column>header{display:flex;gap:12px;align-items:center;padding:17px 12px;min-height:88px;background:color-mix(in srgb,var(--accent),transparent 94%);border-bottom:1px solid #1e2b43}.crm-column>header strong{font-size:12px}.crm-column>header small{color:#d3dbee;margin-top:6px}.crm-count{background:var(--accent);color:white;border-radius:7px;padding:8px;font-weight:700;min-width:30px;text-align:center}.crm-cards{height:calc(100vh - 440px);min-height:350px;overflow-y:auto;padding:8px;scrollbar-width:thin;scrollbar-color:#314361 transparent}.crm-card{border:1px solid #22304b;border-radius:9px;background:linear-gradient(125deg,#111c2e,#0b1423);padding:11px;margin-bottom:9px;box-shadow:0 4px 12px #0002;transition:border-color .15s,transform .15s}.crm-card:hover{border-color:#77639c;transform:translateY(-1px)}.crm-card-top{display:flex;justify-content:space-between;align-items:center;gap:5px;margin-bottom:12px}.crm-card-top button{border:0;background:none;padding:0;font-size:11px;overflow-wrap:anywhere;text-align:left}.crm-card time{font-size:9px;color:#778bb0;max-width:70px;text-align:right}.crm-product{display:flex;align-items:center;gap:10px;margin-bottom:12px;min-width:0}.crm-product>div{min-width:0}.crm-product strong{font-size:11px;line-height:1.6;display:block;overflow-wrap:anywhere}.crm-photo{width:48px;height:58px;object-fit:contain;background:#e5e6e9;border-radius:6px;flex-shrink:0}.crm-placeholder{display:grid;place-items:center;background:#19233b;color:#6c7a99;font-size:28px}.crm-card>button{padding:0;background:none;border:0;font-size:11px;margin-bottom:4px;text-align:left}.crm-card footer{display:flex;align-items:center;justify-content:space-between;gap:5px;margin:10px 0}.crm-badge{font-size:10px;padding:5px 8px;border-radius:6px;background:#40247766;color:#c5a3ff;display:inline-block;overflow-wrap:anywhere}.crm-warning{color:#e3b45f!important}.crm-empty{text-align:center;padding:60px 16px;color:#637496;font-size:28px}.crm-empty p{font-size:13px;color:#b2bdd0}.crm-list{display:grid;grid-template-columns:repeat(auto-fill,minmax(230px,1fr));gap:12px}.crm-local{padding:10px 14px;border:1px solid #28324b;border-radius:8px;color:#95a2bb;font-size:11px;background:#10182a}.crm-alert{padding:15px;background:#50202b;color:#ffc6d0;border-radius:8px;margin-bottom:10px}.crm-breadcrumb{display:flex;gap:8px;align-items:center;color:var(--muted);font-size:12px;margin-bottom:20px;flex-wrap:wrap}.crm-profile{display:flex;gap:20px;align-items:center;padding:24px;border:1px solid #1c2b43;border-radius:12px;background:linear-gradient(110deg,#10152b,#071420);margin-bottom:20px;flex-wrap:wrap}.crm-profile>div:nth-child(2){flex:1;min-width:0;overflow-wrap:anywhere}.crm-profile p{font-size:12px;color:#b3c0d9;margin:8px 0}.crm-avatar{background:linear-gradient(140deg,#934dff,#4d24e8);width:70px;height:70px;border-radius:50%;display:grid;place-items:center;font-size:24px;font-weight:700}.crm-detail-grid{display:grid;grid-template-columns:minmax(0,2fr) minmax(260px,1fr);gap:20px}.crm-detail-grid>*,.crm-panel{min-width:0}.crm-panel{padding:22px;border:1px solid #1c2b43;border-radius:11px;background:linear-gradient(120deg,#0a1422,#070f1b);margin-bottom:18px;overflow-wrap:anywhere}.crm-panel p{font-size:12px;color:#a8b8d2}.crm-panel form{display:grid;gap:10px}.crm-panel textarea{resize:vertical;min-height:85px;width:100%}.crm-panel form button{background:#6634dd}.crm-panel label{display:grid;gap:8px;font-size:12px;margin:18px 0}.crm-muted{color:var(--muted)}.crm-event{display:flex;gap:12px;padding:18px 0;border-bottom:1px solid #172339;font-size:12px}.crm-event p{white-space:pre-wrap}.crm-dot{height:9px;width:9px;flex-shrink:0;border-radius:50%;background:#915cff;margin-top:5px}.crm-address{padding:18px;background:#101831;border:1px solid #332357;border-radius:9px;margin:10px 0;font-size:12px}.crm-product-large .crm-photo{width:100px;height:120px}.crm-history>div{display:flex;align-items:center;gap:14px;padding:16px 0;border-bottom:1px solid #19263c;flex-wrap:wrap;font-size:12px}.crm-history>div>div{flex:1;min-width:100px}.crm-existing-link{color:inherit!important;font:inherit!important;background:none!important;border:0!important;cursor:pointer;text-align:inherit}.crm-shell:has(.crm-profile) .crm-stats{grid-template-columns:repeat(4,minmax(0,1fr))}
@media(min-width:1750px){.crm-column{flex-basis:calc((100% - 72px)/7)}}
@media(max-width:1200px){.crm-stats{grid-template-columns:repeat(4,minmax(0,1fr))}.crm-stat-icon{display:none}.crm-detail-grid{grid-template-columns:minmax(0,1.6fr) minmax(240px,1fr)}}
@media(max-width:768px){.crm-shell{padding:16px}.crm-detail-grid{grid-template-columns:1fr}.crm-stats{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-shell:has(.crm-profile) .crm-stats{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-heading h1{font-size:23px}.crm-column{flex-basis:280px}.crm-toolbar label{flex:1 1 110px}.crm-profile{padding:18px;gap:14px}.crm-heading{align-items:flex-start;flex-wrap:wrap}.crm-cards{height:60vh}.crm-panel{padding:16px}.crm-profile h1{font-size:24px}.crm-stats strong{font-size:22px}}
@media(max-width:430px){.crm-shell{padding:12px}.crm-column{flex-basis:calc(100vw - 60px)}.crm-stats{gap:8px}.crm-stats>div{padding:14px 10px}.crm-shell button{min-height:40px}.crm-card-top button,.crm-card>button{min-height:30px}.crm-toolbar label{max-width:none}.crm-profile{display:block}.crm-avatar{margin-bottom:15px}.crm-results{gap:8px;flex-wrap:wrap}.crm-history>div{gap:10px}.crm-product-large .crm-photo{width:70px;height:90px}}
@media(prefers-reduced-motion:reduce){.crm-shell *{transition:none!important;animation:none!important;scroll-behavior:auto!important}}
.crm-shell,.crm-shell *{font-family:Inter,"Segoe UI",sans-serif!important}.crm-shell p,.crm-shell small,.crm-shell time,.crm-shell label,.crm-shell input,.crm-shell textarea{font-weight:400!important}.crm-comment{padding:15px 0;border-bottom:1px solid #1c2a40;font-size:12px}.crm-comment p{white-space:pre-wrap}.crm-comment button{margin-right:6px;margin-top:8px}.crm-shell .crm-product-photo-edit{display:none}
.crm-tabs{display:flex;gap:8px;overflow-x:auto;margin:12px 0 22px;padding-bottom:5px;max-width:100%}.crm-tabs button{flex-shrink:0;background:#10182b}.crm-tabs button:first-child{background:#4e238a;border-bottom-color:#a35dff}.crm-panel{scroll-margin-top:20px}.crm-panel summary{font-size:12px;color:#c4a3ff;cursor:pointer;margin:16px 0}
.crm-internal-badge{font-size:9px!important;color:#00c99a!important;display:block!important;line-height:1.5!important}
.crm-skeleton{display:flex;gap:14px;overflow:hidden;margin-top:25px}.crm-skeleton>div{height:360px;flex:1;min-width:200px;border-radius:12px;background:linear-gradient(110deg,#111a2c,#19233c,#111a2c);background-size:200% 100%;animation:crm-loading 1.4s ease infinite}@keyframes crm-loading{to{background-position:-200% 0}}
#page-orders-workspace{padding:0!important;gap:0!important;min-width:0;max-width:100%}
body:has(#page-orders-workspace.active) .sidebar{width:184px}
body:has(#page-orders-workspace.active) .main{margin-left:184px}
body:has(#page-orders-workspace.active) .topbar{display:none}
body:has(#page-orders-workspace.active) .crm-shell{padding:16px 20px 22px;min-height:100vh;background:radial-gradient(ellipse at 12% 0,rgba(103,49,225,.07),transparent 40%),#050e1a}
.crm-shell{--ink:#edf2ff;--muted:#8d9fbc;color:var(--ink);font-family:Inter,"Segoe UI",sans-serif}
.crm-local{display:none}
.crm-heading{margin:0 0 15px;min-height:49px;gap:16px;flex-wrap:nowrap}
.crm-title{display:flex;align-items:center;gap:14px;min-width:220px}
.crm-heading-icon{width:48px;height:48px;border-radius:12px;background:#171a37;color:#a986ff;display:grid;place-items:center;font-size:25px;border:1px solid #29264e}
.crm-heading h1{font-size:22px;margin:0;letter-spacing:-.5px}
.crm-heading p{font-size:11px;margin:3px 0 0}
.crm-heading-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;min-width:0;flex:1}
.crm-range{display:flex;align-items:center;gap:7px;white-space:nowrap;border:1px solid #20314d;background:#0a1423;border-radius:8px;padding:0 9px;height:42px;color:#dbe4f5;font-size:11px}
.crm-range input{width:17px;padding:0;border:0;background:transparent;color:transparent;opacity:.8}
.crm-search{width:min(29vw,380px);height:42px;font-size:11px!important}
.crm-heading-actions>.crm-heading-actions,.crm-heading-actions>button{background:linear-gradient(120deg,#8243ff,#5b29e7)!important;border-color:#945bff!important;white-space:nowrap;height:42px}
.crm-order-stats{grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin:14px 0 15px}
.crm-order-stats>div{padding:12px 11px;gap:10px;border-radius:10px;min-height:88px}
.crm-order-stats .crm-stat-icon{font-size:19px;padding:10px;border-radius:10px}
.crm-order-stats strong{font-size:21px}
.crm-order-stats small{font-size:10px}
.crm-board-filters{display:flex;flex-wrap:nowrap;align-items:center;gap:8px;margin:0 0 10px;padding:0}
.crm-board-filters>label{min-width:0;max-width:190px;flex:1 1 125px}
.crm-board-filters>label>select{height:36px;padding:7px 9px;font-size:10px}
.crm-board-filters>button{height:36px;padding:7px 10px;white-space:nowrap;font-size:10px}
.crm-board-filters .crm-extra-filters{display:contents}
.crm-board-filters .crm-extra-filters label{min-width:115px}
.crm-board-filters .crm-extra-filters input[type=date]{padding:7px}
.crm-board-filters .crm-check{display:flex;flex-direction:row;align-items:center;gap:5px;min-height:34px;white-space:nowrap}
.crm-board-filters input[type=checkbox]{width:15px;height:15px;padding:0}
.crm-results{margin:0 0 8px;font-size:10px}
.crm-view-switch button{height:32px;padding:6px 12px}
.crm-view-switch button[data-crm=board]{background:#582bdf;border-color:#8255f2}
.crm-board{gap:10px;padding-bottom:13px;height:calc(100vh - 300px);min-height:440px;scrollbar-width:thin}
.crm-column{flex:0 0 clamp(190px,calc((100vw - 244px)/6),218px);border-radius:10px}
.crm-column>header{min-height:66px;padding:9px;gap:8px}
.crm-column>header strong{font-size:11px}
.crm-column>header small{font-size:10px;margin-top:3px;color:#d3dbee}
.crm-column>header>[data-crm=new]{margin-left:auto;padding:5px 8px;background:color-mix(in srgb,var(--accent),transparent 76%);border:0;font-size:16px}
.crm-count{padding:7px;min-width:29px;font-size:11px}
.crm-cards{height:100%;min-height:0;padding:7px}
.crm-card{padding:8px;margin-bottom:7px;border-radius:8px;background:linear-gradient(135deg,#101b2e,#0b1423)}
.crm-card-top{margin-bottom:7px;min-height:17px}
.crm-card-top button{font-size:10px;min-height:0}
.crm-card-top time{font-size:9px}
.crm-card-top a{font-size:14px;font-weight:700}
.crm-product{gap:8px;margin-bottom:6px;align-items:flex-start}
.crm-photo{width:43px;height:53px}
.crm-product strong{font-size:10px;line-height:1.35}
.crm-product small{font-size:9px;line-height:1.45}
.crm-card-contact button{font-size:10px;font-weight:650;min-height:0;margin:0;padding:0}
.crm-card-contact small{font-size:9px;line-height:1.35}
.crm-card footer{margin:6px 0 0}
.crm-card footer .crm-badge{padding:4px 7px;font-size:9px}
.crm-card-actions{display:flex;align-items:center;gap:8px}
.crm-card-actions small{display:inline!important;font-size:9px}
.crm-card-actions strong{font-size:10px;white-space:nowrap}
.crm-card .crm-warning{font-size:9px}
.crm-empty{padding:24px 8px;font-size:20px}
.crm-profile-layout{display:grid;grid-template-columns:minmax(300px,1.12fr) minmax(270px,.94fr) minmax(245px,.9fr);gap:12px;align-items:stretch;margin-bottom:12px}
.crm-profile{padding:13px 12px;margin:0;gap:14px;flex-wrap:nowrap;min-width:0;border-radius:10px}
.crm-avatar{width:68px;height:68px;flex:0 0 68px;font-size:22px}
.crm-profile-copy{min-width:0;flex:1;overflow-wrap:anywhere}
.crm-profile h1{font-size:23px;margin:0 0 5px}
.crm-profile p{font-size:11px;line-height:1.4;margin:5px 0}
.crm-profile-copy>small{font-size:10px}
.crm-profile-copy .crm-badge{margin-bottom:2px;padding:4px 8px}
.crm-client-stats{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin:0}
.crm-client-stats>div{display:block;padding:10px 8px;border-radius:9px}
.crm-client-stats .crm-stat-icon{display:grid;width:38px;height:38px;font-size:18px;padding:8px;margin-bottom:8px}
.crm-client-stats strong{font-size:19px}
.crm-client-stats small{font-size:10px}
.crm-client-summary{margin:0;padding:10px 12px;display:flex;flex-direction:column;justify-content:space-between}
.crm-summary-head,.crm-summary-foot{display:flex;align-items:center;justify-content:space-between;gap:8px}
.crm-summary-head>div,.crm-summary-foot>span{display:grid;gap:5px}
.crm-summary-head small,.crm-summary-foot small{font-size:10px}
.crm-summary-head strong{font-size:14px;color:#ffbd4a;white-space:nowrap}
.crm-summary-foot strong{font-size:11px;font-weight:500}
.crm-summary-foot a{padding:9px;background:#101c31;border:1px solid #263754;border-radius:8px}
.crm-tabs{gap:0;margin:0 0 12px;padding:0;border-radius:8px;background:#0b1524}
.crm-tabs button{border:0;border-bottom:2px solid transparent;border-radius:0;padding:11px 15px;background:transparent;white-space:nowrap;font-size:11px}
.crm-tabs button:first-child{background:#15162f;color:#fff;border-bottom:2px solid #a44dff}
.crm-client-grid{grid-template-columns:minmax(0,2.2fr) minmax(300px,1fr);gap:14px;align-items:start}
.crm-panel{padding:14px;margin-bottom:12px;border-radius:10px}
.crm-panel h2{font-size:14px;margin:0}
.crm-panel-title{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:10px}
.crm-panel-title>button,.crm-panel-title select{padding:7px 10px;font-size:10px}
.crm-history>div{display:grid;grid-template-columns:30px minmax(112px,.75fr) minmax(155px,1.45fr) minmax(78px,.6fr) 88px 30px;gap:9px;padding:9px 0;flex-wrap:nowrap;font-size:10px;min-height:67px}
.crm-history>div>.crm-photo{width:43px;height:53px}
.crm-history>div>div{flex:initial;min-width:0}
.crm-history>div>div:nth-of-type(2){display:grid;gap:2px}
.crm-history>div>div:nth-of-type(2) strong{font-size:10px}
.crm-history>div>div:nth-of-type(2) small{font-size:9px}
.crm-history>div>button{padding:5px;font-size:9px;white-space:nowrap}
.crm-history>div>.crm-badge{padding:4px 6px;font-size:9px}
.crm-lower-grid{display:grid;grid-template-columns:minmax(245px,.92fr) minmax(285px,1.08fr);gap:12px;align-items:start}
.crm-info-list{display:grid;grid-template-columns:110px minmax(0,1fr);gap:12px 7px;font-size:11px;margin:16px 0 0}
.crm-info-list dt{color:var(--muted)}
.crm-info-list dd{margin:0;overflow-wrap:anywhere}
.crm-address{display:flex;align-items:center;gap:10px;padding:12px;margin:8px 0;font-size:11px}
.crm-address-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:50%;background:#30205d;color:#bf8bff;font-size:17px;flex-shrink:0}
.crm-address>div{min-width:0;flex:1}
.crm-address strong{color:#c680ff}
.crm-address p{margin:4px 0 0;font-size:10px;line-height:1.5}
.crm-address.is-primary{background:linear-gradient(120deg,#19123c,#10162b);border-color:#7141d3}
.crm-evaluation .crm-review-status{padding:12px;border:1px solid #087353;border-radius:8px;background:#032921;display:grid;gap:4px;margin:8px 0}
.crm-review-status strong{color:#00d5a0;font-size:11px}
.crm-review-status small{font-size:10px}
.crm-evaluation form{gap:7px}
.crm-evaluation form textarea{min-height:55px}
.crm-comment{padding:10px 0}
.crm-comment p,.crm-event p{font-size:10px;margin:4px 0;line-height:1.45}
.crm-comment>small,.crm-event small{font-size:9px}
.crm-event{padding:10px 0;gap:8px}
.crm-mini-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.crm-mini-stats>div{padding:10px;border:1px solid #1b2940;border-radius:8px;background:#0b1524}
.crm-mini-stats strong{display:block;font-size:15px}
.crm-mini-stats small{font-size:9px}
.crm-client-grid .crm-board-filters{display:flex}
.crm-client-grid .crm-board-filters>label{flex:1 1 110px}
.crm-shell:has(.crm-profile)>.crm-local{display:none}
@media(max-width:1200px){
 body:has(#page-orders-workspace.active) .sidebar{width:184px}
 body:has(#page-orders-workspace.active) .main{margin-left:184px}
 .crm-shell{padding:14px}
 .crm-order-stats{grid-template-columns:repeat(3,minmax(0,1fr))}
 .crm-heading{align-items:flex-start;flex-wrap:wrap}
 .crm-heading-actions{flex-wrap:wrap}
 .crm-profile-layout{grid-template-columns:minmax(290px,1.2fr) minmax(240px,1fr)}
 .crm-client-summary{grid-column:1/-1;min-height:92px}
 .crm-profile{min-height:140px}
 .crm-client-grid{grid-template-columns:minmax(0,1.8fr) minmax(260px,1fr)}
 .crm-history>div{grid-template-columns:30px minmax(100px,.7fr) minmax(140px,1.4fr) 78px 72px 30px;gap:6px}
 .crm-board{height:calc(100vh - 360px)}
}
@media(max-width:992px){
 body:has(#page-orders-workspace.active) .sidebar{width:270px}
 body:has(#page-orders-workspace.active) .main{margin-left:0}
 body:has(#page-orders-workspace.active) .topbar{display:grid}
 .crm-heading{flex-wrap:wrap}
 .crm-heading-actions{flex-wrap:wrap;justify-content:flex-start}
 .crm-search{width:min(55vw,400px)}
 .crm-board-filters{flex-wrap:wrap}
 .crm-board-filters>label{flex:1 1 125px}
 .crm-board-filters>button{flex:0 0 auto}
 .crm-profile-layout{grid-template-columns:1fr 1fr}
 .crm-client-grid{grid-template-columns:1fr}
 .crm-lower-grid{grid-template-columns:1fr 1fr}
 .crm-board{height:calc(100vh - 380px)}
}
@media(max-width:768px){
 .crm-shell{padding:12px!important}
 .crm-order-stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .crm-order-stats>div{min-height:72px;padding:9px}
 .crm-order-stats .crm-stat-icon{display:grid}
 .crm-board-filters{flex-wrap:wrap}
 .crm-board-filters>label{flex:1 1 135px;max-width:none}
 .crm-board-filters .crm-extra-filters{display:contents}
 .crm-extra-filters label{flex:1 1 120px}
 .crm-heading-actions{width:100%;display:grid;grid-template-columns:1fr 1fr}
 .crm-range{grid-column:1/-1}
 .crm-search{width:100%;grid-column:1/-1}
 .crm-heading-actions>button{grid-column:1/-1}
 .crm-column{flex-basis:280px}
 .crm-board{height:62vh;min-height:380px}
 .crm-profile-layout{grid-template-columns:1fr}
 .crm-profile{min-height:0}
 .crm-client-summary{grid-column:auto}
 .crm-tabs button{padding:10px 12px}
 .crm-history>div{grid-template-columns:34px minmax(75px,.65fr) minmax(120px,1.35fr) 65px 55px;gap:5px}
 .crm-history>div>[data-crm=order]:last-child{display:none}
 .crm-history>div>.crm-photo{width:38px;height:48px}
 .crm-lower-grid{grid-template-columns:1fr}
 .crm-detail-grid{grid-template-columns:1fr}
 .crm-panel{padding:12px}
 .crm-heading h1{font-size:20px}
}
@media(max-width:430px){
 .crm-heading-actions{grid-template-columns:1fr}
 .crm-range,.crm-search,.crm-heading-actions>button{grid-column:auto}
 .crm-heading-icon{width:40px;height:40px}
 .crm-history>div{grid-template-columns:30px minmax(70px,.7fr) minmax(110px,1.3fr) 55px}
 .crm-history>div>.crm-badge{display:none}
 .crm-history>div>strong{font-size:9px}
 .crm-profile{padding:12px}
 .crm-client-stats>div{padding:9px 6px}
 .crm-info-list{grid-template-columns:90px minmax(0,1fr)}
}
/* Orders board refresh: keep the toolbar compact and give each status a readable lane. */
body:has(#page-orders-workspace.active) .sidebar{width:184px}
body:has(#page-orders-workspace.active) .main{margin-left:184px}
body:has(#page-orders-workspace.active) .crm-shell{padding:12px 18px 18px;min-height:100vh;display:flex;flex-direction:column;gap:8px}
body:has(#page-orders-workspace.active) .crm-heading{min-height:42px;margin:0;gap:14px}
body:has(#page-orders-workspace.active) .crm-heading-icon{display:none}
body:has(#page-orders-workspace.active) .crm-title{min-width:180px;gap:0}
body:has(#page-orders-workspace.active) .crm-heading h1{font-size:19px}
body:has(#page-orders-workspace.active) .crm-heading p{display:none}
body:has(#page-orders-workspace.active) .crm-heading-actions{gap:8px}
body:has(#page-orders-workspace.active) .crm-search{height:36px;width:min(29vw,350px)}
body:has(#page-orders-workspace.active) .crm-range{height:36px;min-width:185px;font-size:10px}
body:has(#page-orders-workspace.active) .crm-heading-actions>button{height:36px;min-height:36px;padding:6px 10px}
body:has(#page-orders-workspace.active) .crm-order-stats{display:none}
body:has(#page-orders-workspace.active) .crm-board-filters{margin:0;gap:7px}
body:has(#page-orders-workspace.active) .crm-board-filters>label{flex:0 1 148px;max-width:148px}
body:has(#page-orders-workspace.active) .crm-board-filters>label>select{height:32px;padding:5px 8px}
body:has(#page-orders-workspace.active) .crm-board-filters>button{height:32px;padding:5px 9px}
body:has(#page-orders-workspace.active) .crm-results{margin:0;font-size:10px;min-height:22px}
body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 164px);min-height:420px;flex:1;gap:12px;padding-bottom:12px;scroll-snap-type:x mandatory;overscroll-behavior-x:contain}
body:has(#page-orders-workspace.active) .crm-column{flex:0 0 clamp(290px,23vw,340px);border:1px solid #202c43;border-radius:10px;background:#090f1b;scroll-snap-align:start;transition:border-color .16s,background .16s}
body:has(#page-orders-workspace.active) .crm-column>header{position:sticky;top:0;z-index:2;min-height:62px;padding:10px 12px;background:color-mix(in srgb,var(--accent),#0b1423 90%);border-bottom:1px solid #1c2940}
body:has(#page-orders-workspace.active) .crm-column>header strong{font-size:12px}
body:has(#page-orders-workspace.active) .crm-column>header small{font-size:9px;color:#8d9fbc}
body:has(#page-orders-workspace.active) .crm-count{padding:5px 7px;min-width:26px;background:color-mix(in srgb,var(--accent),#0b1423 70%);font-size:10px}
body:has(#page-orders-workspace.active) .crm-cards{height:calc(100% - 62px);min-height:0;padding:10px;overscroll-behavior-y:contain}
body:has(#page-orders-workspace.active) .crm-card{position:relative;padding:10px 11px;margin-bottom:8px;border-radius:9px;background:#101a2a;box-shadow:0 2px 8px #0002;cursor:grab;user-select:none}
body:has(#page-orders-workspace.active) .crm-card:active{cursor:grabbing}
body:has(#page-orders-workspace.active) .crm-card.is-dragging{opacity:.55;transform:scale(.98);box-shadow:0 12px 28px #0008}
body:has(#page-orders-workspace.active) .crm-column.is-drop-target{border-color:var(--accent);background:color-mix(in srgb,var(--accent),#080e19 94%)}
body:has(#page-orders-workspace.active) .crm-column.is-drop-target>header{background:color-mix(in srgb,var(--accent),#101728 82%)}
body:has(#page-orders-workspace.active) .crm-card-top{margin-bottom:7px}
body:has(#page-orders-workspace.active) .crm-card .crm-order-link{max-width:65%;font-size:11px}
body:has(#page-orders-workspace.active) .crm-card-top time{max-width:88px}
body:has(#page-orders-workspace.active) .crm-card-top a{font-size:12px}
body:has(#page-orders-workspace.active) .crm-product{align-items:center;margin-bottom:7px}
body:has(#page-orders-workspace.active) .crm-photo{width:44px;height:50px}
body:has(#page-orders-workspace.active) .crm-product strong{font-size:11px;line-height:1.35}
body:has(#page-orders-workspace.active) .crm-product small{font-size:9px;line-height:1.35}
body:has(#page-orders-workspace.active) .crm-card-contact{display:flex;align-items:center;gap:7px;min-width:0}
body:has(#page-orders-workspace.active) .crm-card-contact button{font-size:10px;white-space:nowrap;max-width:58%;overflow:hidden;text-overflow:ellipsis}
body:has(#page-orders-workspace.active) .crm-card-contact small{font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body:has(#page-orders-workspace.active) .crm-card footer{margin:7px 0 0;padding-top:7px;border-top:1px solid #1c2940}
body:has(#page-orders-workspace.active) .crm-card-state{font-size:9px;color:#95a8c5;max-width:58%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
body:has(#page-orders-workspace.active) .crm-card footer .crm-card-actions strong{font-size:10px}
body:has(#page-orders-workspace.active) .crm-mobile-stage{display:none}
body:has(#page-orders-workspace.active) .crm-stale{padding:7px 10px;border:1px solid #68552d;border-radius:7px;background:#241e12;color:#e7cb87;font-size:10px}
body:has(#page-orders-workspace.active) .crm-stale button{padding:3px 7px;margin-left:8px;font-size:10px}
@media(max-width:1200px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 178px)}body:has(#page-orders-workspace.active) .crm-column{flex-basis:310px}}
@media(max-width:992px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 218px)}body:has(#page-orders-workspace.active) .crm-heading{flex-wrap:wrap}body:has(#page-orders-workspace.active) .crm-heading-actions{display:flex;width:auto;margin-left:auto}body:has(#page-orders-workspace.active) .crm-search{width:min(34vw,300px)}}
@media(max-width:768px){body:has(#page-orders-workspace.active) .crm-shell{padding:10px!important;gap:7px}body:has(#page-orders-workspace.active) .crm-heading{display:flex;align-items:center;flex-wrap:wrap}body:has(#page-orders-workspace.active) .crm-heading-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;width:100%;margin:0}body:has(#page-orders-workspace.active) .crm-range{display:none}body:has(#page-orders-workspace.active) .crm-search{width:100%;height:36px}body:has(#page-orders-workspace.active) .crm-heading-actions>button{grid-column:auto;height:36px}body:has(#page-orders-workspace.active) .crm-board-filters>label{flex:1 1 120px;max-width:none}body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 202px);min-height:380px}body:has(#page-orders-workspace.active) .crm-column{flex-basis:min(86vw,360px)}body:has(#page-orders-workspace.active) .crm-mobile-stage{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:8px;margin-top:7px;color:#8d9fbc;font-size:9px}body:has(#page-orders-workspace.active) .crm-mobile-stage select{height:30px;padding:4px 8px;font-size:10px}}
@media(max-width:430px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100dvh - 230px);min-height:330px}body:has(#page-orders-workspace.active) .crm-column{flex-basis:calc(100vw - 32px)}body:has(#page-orders-workspace.active) .crm-board-filters{gap:5px}body:has(#page-orders-workspace.active) .crm-board-filters>label{flex-basis:calc(50% - 5px)}body:has(#page-orders-workspace.active) .crm-board-filters>button{flex:1}body:has(#page-orders-workspace.active) .crm-results{min-height:20px}}
@media(prefers-reduced-motion:reduce){body:has(#page-orders-workspace.active) .crm-column,body:has(#page-orders-workspace.active) .crm-card{transition:none}}
@media(max-width:1450px) and (min-width:1201px){body:has(#page-orders-workspace.active) .sidebar{width:220px}body:has(#page-orders-workspace.active) .main{margin-left:220px}}
#page-orders-workspace.active{padding:0!important;overflow:hidden;min-width:0;max-width:100%}
.manus-orders-host{width:100%;height:100vh;min-height:100vh;background:#f5f7fb;overflow:hidden}
.manus-orders-frame{display:block;width:100%;height:100%;min-height:100vh;border:0;background:#f5f7fb}
.manus-bridge-error{position:fixed;z-index:20;right:16px;bottom:16px;max-width:320px;padding:10px 13px;border:1px solid #efc1c1;border-radius:9px;background:#fff7f6;color:#a74949;box-shadow:0 8px 24px #1d2a3c20;font:12px/1.4 Inter,Arial,sans-serif}
#page-orders-workspace .crm-alert{display:none}
.crm-history>div{grid-template-columns:44px minmax(112px,.8fr) minmax(150px,1.35fr) minmax(90px,.7fr) 72px 92px}
.crm-history>div>.crm-photo{grid-column:1;grid-row:1;object-fit:contain}
.crm-history>div>div:nth-of-type(1){grid-column:2;grid-row:1;min-width:0}
.crm-history>div>div:nth-of-type(2){grid-column:3;grid-row:1;min-width:0}
.crm-history>div>.crm-badge{grid-column:4;grid-row:1}
.crm-history>div>strong{grid-column:5;grid-row:1;white-space:nowrap}
.crm-history>div>[data-crm=order]:last-child{grid-column:6;grid-row:1;min-height:32px}
.crm-client-grid>.crm-detail-grid>div:first-child{min-width:0}
.crm-client-grid aside{min-width:0}
@media(max-width:1200px){.crm-history>div{grid-template-columns:40px minmax(95px,.75fr) minmax(125px,1.25fr) 82px 68px 78px}}
@media(max-width:768px){.crm-history>div{grid-template-columns:40px minmax(85px,.75fr) minmax(125px,1.25fr) 70px 64px}.crm-history>div>[data-crm=order]:last-child{display:none}}
#page-orders-workspace .crm-shell>.crm-alert{display:none}
#page-orders-workspace .crm-shell>.crm-alert[role=alert]{display:block}
.crm-range{min-width:220px;position:relative}
.crm-range input{position:absolute;right:8px;width:20px;height:24px;cursor:pointer}
.crm-range input[data-filter=from]{right:32px}
.crm-range input[data-filter=to]{right:7px}
.crm-range input::-webkit-calendar-picker-indicator{opacity:.65;cursor:pointer}
.crm-client-summary .crm-summary-head>div{min-width:0}
.crm-client-summary .crm-summary-head strong{white-space:normal}
.crm-card .crm-order-link{border:0;background:none;padding:0;color:#edf2ff;font-size:10px;font-weight:700;line-height:1.2;text-align:left;overflow-wrap:anywhere;cursor:pointer;flex:1;min-width:0}
.crm-card .crm-card-top .crm-order-link{min-height:0}
.crm-column>header>div{flex:1;min-width:0}
.crm-column>header strong{overflow-wrap:anywhere}
.crm-history>div{grid-template-columns:44px minmax(112px,.8fr) minmax(150px,1.35fr) minmax(90px,.7fr) 72px 92px}
.crm-history>div>.crm-photo{grid-column:1;grid-row:1;object-fit:contain}
.crm-history>div>div:nth-of-type(1){grid-column:2;grid-row:1;min-width:0}
.crm-history>div>div:nth-of-type(2){grid-column:3;grid-row:1;min-width:0}
.crm-history>div>.crm-badge{grid-column:4;grid-row:1}
.crm-history>div>strong{grid-column:5;grid-row:1;white-space:nowrap}
.crm-history>div>[data-crm=order]:last-child{grid-column:6;grid-row:1;min-height:32px;padding:7px 8px}
.crm-client-grid .crm-history{min-width:0;overflow-x:auto}
.crm-profile-copy>p span{margin-left:5px}
.crm-summary-head>button{padding:5px 9px}
.crm-board{min-height:420px}
.crm-range{min-width:220px;position:relative}
.crm-range input{position:absolute;right:8px;width:20px;height:24px;cursor:pointer}
.crm-range input[data-filter=from]{right:32px}
.crm-range input[data-filter=to]{right:7px}
.crm-range input::-webkit-calendar-picker-indicator{opacity:.65;cursor:pointer}
.crm-client-summary .crm-summary-head>div{min-width:0}
.crm-client-summary .crm-summary-head strong{white-space:normal}
@media(max-width:1200px){.crm-history>div{grid-template-columns:40px minmax(95px,.75fr) minmax(125px,1.25fr) 82px 68px 78px}}
@media(max-width:768px){.crm-history>div{grid-template-columns:40px minmax(85px,.75fr) minmax(125px,1.25fr) 70px 64px}.crm-history>div>[data-crm=order]:last-child{display:none}}
#page-orders-workspace .crm-shell>.crm-alert{display:none!important}
#page-orders-workspace .crm-shell>.crm-alert[role=alert]{display:block!important}
.crm-card .crm-card-top .crm-order-link{flex:1 1 auto;width:auto;max-width:52%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crm-card .crm-card-top time{flex:0 0 auto;max-width:50px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crm-card .crm-card-top a{flex:0 0 22px;text-align:right;white-space:nowrap}
.crm-profile-layout{grid-template-columns:minmax(280px,1.12fr) minmax(270px,.94fr) minmax(220px,.9fr)}
@media(max-width:1200px){.crm-profile-layout{grid-template-columns:minmax(250px,1.1fr) minmax(230px,1fr)}.crm-client-summary{grid-column:1/-1}}
@media(min-width:1201px) and (max-width:1400px){.crm-profile-layout{grid-template-columns:minmax(250px,1.05fr) minmax(240px,.95fr) minmax(205px,.85fr)}.crm-profile{gap:9px;padding:12px}.crm-avatar{width:58px;height:58px;flex-basis:58px}.crm-profile h1{font-size:20px}}
/* Clients page heading only. */
#page-clients .vm-original-page-title{display:none!important}
#page-clients .page-header:has(>.vm-workspace-heading){align-items:flex-end;min-height:104px;margin:0 0 8px;padding:4px 0 20px;border-bottom:1px solid rgba(150,165,190,.18)}
#page-clients .vm-workspace-heading{width:100%;color:var(--text)}
#page-clients .vm-workspace-meta{display:flex;align-items:center;gap:12px;margin-bottom:10px;font:500 10px Inter,"Segoe UI",sans-serif;color:var(--muted)}
#page-clients .vm-workspace-live{display:inline-flex;align-items:center;gap:7px;color:#29b783;font-weight:650}
#page-clients .vm-workspace-live i{width:6px;height:6px;border-radius:50%;background:#32c48d;box-shadow:0 0 0 3px rgba(50,196,141,.12)}
#page-clients .vm-workspace-date{padding-left:12px;border-left:1px solid var(--border2)}
#page-clients .vm-workspace-heading h1{margin:0;color:var(--text);font:400 32px/1.2 Inter,"Segoe UI",sans-serif;letter-spacing:-1.1px}
#page-clients .vm-workspace-heading p{margin:5px 0 0;color:var(--text2);font:400 12px/1.5 Inter,"Segoe UI",sans-serif}
#page-clients .page-header:has(>.vm-workspace-heading)>.clients-page-actions{align-self:flex-end}
@media(max-width:600px){#page-clients .page-header:has(>.vm-workspace-heading){min-height:96px;padding-bottom:16px}#page-clients .vm-workspace-heading h1{font-size:26px}#page-clients .vm-workspace-heading p{font-size:11px}#page-clients .vm-workspace-meta{font-size:9px}}

@scope (#page-client-details) {
/* Client 360 styling from the Manus module, scoped to existing client details. */
.crm-shell:has(.crm-profile){--client-ink:#172033;--client-muted:#8792a5;--client-line:#e7ebf2;color:var(--client-ink);background:#f5f7fb!important;padding:20px 24px!important;font-family:Inter,"Segoe UI",sans-serif}.crm-shell:has(.crm-profile) .crm-breadcrumb{color:#8c97a9;margin-bottom:14px}.crm-shell:has(.crm-profile) .crm-breadcrumb button{background:#fff!important;border:1px solid var(--client-line)!important;color:#53627b!important}.crm-profile-layout{grid-template-columns:minmax(280px,1.1fr) minmax(290px,1fr) minmax(235px,.9fr);gap:12px}.crm-shell:has(.crm-profile) .crm-profile,.crm-shell:has(.crm-profile) .crm-panel,.crm-shell:has(.crm-profile) .crm-stats>div{background:#fff!important;color:#172033;border:1px solid #e7ebf2!important;box-shadow:0 6px 24px #22365f08;border-radius:14px}.crm-shell:has(.crm-profile) .crm-profile{padding:20px;gap:16px}.crm-shell:has(.crm-profile) .crm-avatar{background:#e7edff;color:#4563bb;border-radius:20px;width:68px;height:68px;flex-basis:68px}.crm-shell:has(.crm-profile) .crm-profile h1,.crm-shell:has(.crm-profile) .crm-panel h2{color:#172033}.crm-shell:has(.crm-profile) .crm-profile p,.crm-shell:has(.crm-profile) .crm-panel p,.crm-shell:has(.crm-profile) .crm-muted{color:#66738a}.crm-shell:has(.crm-profile) .crm-profile small,.crm-shell:has(.crm-profile) .crm-panel small{color:#8994a7}.crm-shell:has(.crm-profile) .crm-badge{background:#edf2ff;color:#4d67b5}.crm-shell:has(.crm-profile) .crm-stats>div{padding:15px 12px}.crm-shell:has(.crm-profile) .crm-stats strong{color:#172033}.crm-shell:has(.crm-profile) .crm-stats small{color:#8490a4}.crm-shell:has(.crm-profile) .crm-client-summary{display:flex;flex-direction:column;justify-content:space-between;padding:16px}.crm-shell:has(.crm-profile) .crm-tabs{margin:14px 0 18px}.crm-shell:has(.crm-profile) .crm-tabs button{background:#fff!important;border:1px solid #e7ebf2!important;color:#63718a!important;border-radius:8px}.crm-shell:has(.crm-profile) .crm-tabs button:first-child{background:#edf2ff!important;color:#4663b8!important}.crm-shell:has(.crm-profile) .crm-detail-grid{gap:14px}.crm-shell:has(.crm-profile) .crm-panel{padding:18px;margin-bottom:14px}.crm-shell:has(.crm-profile) .crm-panel-title{display:flex;align-items:center;justify-content:space-between;gap:10px}.crm-shell:has(.crm-profile) .crm-panel select,.crm-shell:has(.crm-profile) .crm-panel textarea,.crm-shell:has(.crm-profile) .crm-panel input{background:#fff;color:#344155;border:1px solid #e1e6ef;border-radius:8px}.crm-shell:has(.crm-profile) .crm-panel form button,.crm-shell:has(.crm-profile) .crm-panel button{background:#4d69bc;color:white;border-color:#4d69bc}.crm-shell:has(.crm-profile) .crm-history>div,.crm-shell:has(.crm-profile) .crm-comment,.crm-shell:has(.crm-profile) .crm-event{border-color:#edf0f5}.crm-shell:has(.crm-profile) .crm-history>div{color:#344155}.crm-shell:has(.crm-profile) .crm-history>div small,.crm-shell:has(.crm-profile) .crm-comment small{color:#8994a7}.crm-shell:has(.crm-profile) .crm-history>div .crm-photo{border-radius:8px}.crm-shell:has(.crm-profile) .crm-address{background:#f7f8fb;border:1px solid #e7ebf2;color:#536178}.crm-shell:has(.crm-profile) .crm-review-status{background:#f7f9fc;border:1px solid #e7ebf2;border-radius:10px;padding:12px}.crm-shell:has(.crm-profile) .crm-review-status strong{color:#435fba}.crm-shell:has(.crm-profile) .crm-info-list dt{color:#8994a7}.crm-shell:has(.crm-profile) .crm-info-list dd{color:#344155}.crm-shell:has(.crm-profile) .crm-client-grid{grid-template-columns:minmax(0,1.8fr) minmax(280px,1fr)}
@media(max-width:1100px){.crm-profile-layout{grid-template-columns:minmax(260px,1fr) minmax(260px,1fr)}.crm-shell:has(.crm-profile) .crm-client-summary{grid-column:1/-1;min-height:90px}}
@media(max-width:768px){.crm-shell:has(.crm-profile){padding:12px!important}.crm-profile-layout,.crm-shell:has(.crm-profile) .crm-client-grid{grid-template-columns:1fr}.crm-shell:has(.crm-profile) .crm-client-summary{grid-column:auto}.crm-shell:has(.crm-profile) .crm-profile{align-items:flex-start;padding:16px}.crm-shell:has(.crm-profile) .crm-panel{padding:14px}}

}
@scope (#page-client-details) {
/* Manus Client 360 reference styling, scoped to the existing client detail view. */
.client-page{--client-ink:#172033;--client-muted:#8792a5;--client-line:#e7ebf2;--client-indigo:#4d72e8;color:var(--client-ink);background:#f5f7fb;border-radius:14px;min-height:100vh;font-family:Inter,"Segoe UI",sans-serif}.client-page *{box-sizing:border-box}.client-topbar{height:54px;display:flex;align-items:center;gap:18px;padding:0 22px;background:#fff;border-bottom:1px solid var(--client-line);border-radius:14px 14px 0 0}.client-topbar button{background:transparent!important;color:#68758d!important;border:0!important;padding:6px 0!important}.client-topbar-trail{font-size:11px;color:#8994a7}.client-topbar-user{margin-left:auto;color:#98a2b2;font-size:10px}.client-content{max-width:1450px;margin:auto;padding:20px 24px 40px}.client-breadcrumb{font-size:10px;color:#9ba5b5;margin-bottom:14px}.client-breadcrumb span{padding:0 8px;color:#cbd1dc}.client-breadcrumb strong{color:#58657b}.client-hero{display:flex;align-items:center;justify-content:space-between;gap:22px;padding:22px 24px;background:linear-gradient(112deg,#fff,#f8faff);border:1px solid var(--client-line);border-radius:16px;box-shadow:0 8px 26px #22365f09}.client-hero-person{display:flex;align-items:center;gap:17px;min-width:0}.client-avatar-large{display:grid;place-items:center;flex:0 0 68px;width:68px;height:68px;border-radius:21px;background:#e7edff;color:#4563bb;font-size:20px;font-weight:780}.client-eyebrow{color:#8490a4;font-size:9px;font-weight:700;letter-spacing:.09em}.client-hero h1{margin:5px 0 8px;font-size:25px;letter-spacing:-.04em;color:#172033}.client-hero-meta{display:flex;gap:16px;flex-wrap:wrap;color:#68758d;font-size:11px}.client-hero-actions{display:flex;gap:8px;margin-top:12px}.client-hero-actions a,.client-call{display:inline-flex;align-items:center;padding:7px 11px;border:1px solid #e5eaf2;border-radius:8px;color:#51617b;background:#fff;font-size:10px;text-decoration:none}.client-assessment{display:grid;gap:7px;justify-items:end;max-width:220px}.client-assessment small,.client-assessment span{font-size:9px;color:#8994a7}.client-assessment strong{padding:7px 11px;border-radius:20px;background:#edf3ff;color:#4263bd;font-size:11px}.client-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:14px 0}.client-metrics article{display:grid;gap:7px;padding:14px 16px;background:#fff;border:1px solid var(--client-line);border-radius:12px}.client-metrics small{font-size:10px;color:#8490a4}.client-metrics strong{font-size:22px;color:#172033}.client-metrics span{font-size:9px;color:#97a1b0}.client-layout{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(285px,.9fr);align-items:start;gap:14px}.client-card{margin-bottom:14px;padding:18px;background:#fff;border:1px solid var(--client-line);border-radius:13px;box-shadow:0 5px 20px #22365f06;scroll-margin-top:15px}.client-card-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:13px}.client-card-head small{color:#8b96a8;font-size:9px;font-weight:700;letter-spacing:.08em}.client-card h2{margin:4px 0 0;color:#1e293b;font-size:17px}.client-card h2 span{color:#8490a4;font-size:11px}.client-card h3{margin:16px 0 8px;color:#536178;font-size:11px}.client-order-row{display:grid;grid-template-columns:42px minmax(0,1fr) auto auto auto;align-items:center;gap:11px;padding:11px 0;border-top:1px solid #eef0f4}.client-order-thumb .crm-photo{width:40px;height:44px;border-radius:8px;background:#f2f4f8}.client-order-copy{display:grid;gap:3px;min-width:0}.client-order-copy strong,.client-order-copy b{color:#344155;font-size:10px}.client-order-copy small{color:#8994a7;font-size:9px}.client-order-copy strong small{margin-left:8px;font-weight:400}.client-order-status{padding:5px 8px;border-radius:16px;background:color-mix(in srgb,var(--tone) 12%,white);color:var(--tone);font-size:9px;white-space:nowrap}.client-order-total{font-size:10px;color:#344155;white-space:nowrap}.client-order-row button{background:#f2f5ff!important;color:#526db3!important;border:1px solid #e4eafb!important;padding:6px 8px!important;font-size:9px!important;white-space:nowrap}.client-info-grid{display:grid;grid-template-columns:minmax(130px,.65fr) minmax(0,1fr);gap:10px;margin:0}.client-info-grid dt{color:#8994a7;font-size:10px}.client-info-grid dd{margin:0;color:#344155;font-size:10px;font-weight:600;overflow-wrap:anywhere}.client-address{padding:9px 10px;background:#f7f8fb;border-radius:8px;color:#536178;font-size:10px}.client-review{display:grid;gap:5px;padding:10px 0;border-top:1px solid #eef0f4}.client-review strong{color:#52617a;font-size:10px}.client-review small,.client-private{color:#8994a7;font-size:9px}.client-card form{display:grid;gap:8px}.client-card form label{display:grid;gap:5px;margin:4px 0;color:#657188;font-size:10px}.client-card form input,.client-card form select,.client-card form textarea{width:100%;padding:9px 10px;border:1px solid #e1e6ef;border-radius:8px;background:#fff;color:#344155;font:inherit;font-size:10px}.client-card form textarea{min-height:75px;resize:vertical}.client-card form button{width:max-content;max-width:100%;background:#4d69bc!important;border:0!important;border-radius:8px;color:#fff!important;padding:9px 12px!important;font-size:10px!important}.client-card .crm-comment{padding:10px 0;border-bottom:1px solid #eef0f4;color:#536178}.client-card .crm-comment p{color:#536178;font-size:10px}.client-card .crm-comment small{display:block;margin-top:4px;color:#8994a7;font-size:9px}.client-card .crm-event{border-color:#eef0f4;color:#536178}.client-card .crm-event p{color:#657188}.client-empty,.client-card>p{color:#8994a7;font-size:10px}
@media(max-width:900px){.client-layout{grid-template-columns:1fr}.client-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.client-assessment{justify-items:start}}
@media(max-width:600px){.client-content{padding:14px 10px 28px}.client-topbar{padding:0 12px}.client-topbar-user{display:none}.client-hero{align-items:flex-start;flex-direction:column;padding:16px}.client-hero h1{font-size:21px}.client-avatar-large{width:54px;height:54px;flex-basis:54px;border-radius:17px}.client-order-row{grid-template-columns:36px minmax(0,1fr) auto;gap:8px}.client-order-thumb .crm-photo{width:34px;height:38px}.client-order-status{grid-column:2;justify-self:start}.client-order-total{grid-column:3;grid-row:2}.client-order-row button{grid-column:3;grid-row:1}.client-metrics article{padding:12px}.client-metrics strong{font-size:19px}.client-card{padding:14px}}
}

.crm-shell,.crm-shell *{font-family:Inter,"Segoe UI",sans-serif!important}.crm-shell p,.crm-shell small,.crm-shell time,.crm-shell label,.crm-shell input,.crm-shell textarea{font-weight:400!important}.crm-comment{padding:15px 0;border-bottom:1px solid #1c2a40;font-size:12px}.crm-comment p{white-space:pre-wrap}.crm-comment button{margin-right:6px;margin-top:8px}.crm-shell .crm-product-photo-edit{display:none}
.crm-tabs{display:flex;gap:8px;overflow-x:auto;margin:12px 0 22px;padding-bottom:5px;max-width:100%}.crm-tabs button{flex-shrink:0;background:#10182b}.crm-tabs button:first-child{background:#4e238a;border-bottom-color:#a35dff}.crm-panel{scroll-margin-top:20px}.crm-panel summary{font-size:12px;color:#c4a3ff;cursor:pointer;margin:16px 0}
.crm-internal-badge{font-size:9px!important;color:#00c99a!important;display:block!important;line-height:1.5!important}
.crm-skeleton{display:flex;gap:14px;overflow:hidden;margin-top:25px}.crm-skeleton>div{height:360px;flex:1;min-width:200px;border-radius:12px;background:linear-gradient(110deg,#111a2c,#19233c,#111a2c);background-size:200% 100%;animation:crm-loading 1.4s ease infinite}@keyframes crm-loading{to{background-position:-200% 0}}
#page-orders-workspace{padding:0!important;gap:0!important;min-width:0;max-width:100%}
body:has(#page-orders-workspace.active) .sidebar{width:184px}
body:has(#page-orders-workspace.active) .main{margin-left:184px}
body:has(#page-orders-workspace.active) .topbar{display:none}
body:has(#page-orders-workspace.active) .crm-shell{padding:16px 20px 22px;min-height:100vh;background:radial-gradient(ellipse at 12% 0,rgba(103,49,225,.07),transparent 40%),#050e1a}
.crm-shell{--ink:#edf2ff;--muted:#8d9fbc;color:var(--ink);font-family:Inter,"Segoe UI",sans-serif}
.crm-local{display:none}
.crm-heading{margin:0 0 15px;min-height:49px;gap:16px;flex-wrap:nowrap}
.crm-title{display:flex;align-items:center;gap:14px;min-width:220px}
.crm-heading-icon{width:48px;height:48px;border-radius:12px;background:#171a37;color:#a986ff;display:grid;place-items:center;font-size:25px;border:1px solid #29264e}
.crm-heading h1{font-size:22px;margin:0;letter-spacing:-.5px}
.crm-heading p{font-size:11px;margin:3px 0 0}
.crm-heading-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;min-width:0;flex:1}
.crm-range{display:flex;align-items:center;gap:7px;white-space:nowrap;border:1px solid #20314d;background:#0a1423;border-radius:8px;padding:0 9px;height:42px;color:#dbe4f5;font-size:11px}
.crm-range input{width:17px;padding:0;border:0;background:transparent;color:transparent;opacity:.8}
.crm-search{width:min(29vw,380px);height:42px;font-size:11px!important}
.crm-heading-actions>.crm-heading-actions,.crm-heading-actions>button{background:linear-gradient(120deg,#8243ff,#5b29e7)!important;border-color:#945bff!important;white-space:nowrap;height:42px}
.crm-order-stats{grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin:14px 0 15px}
.crm-order-stats>div{padding:12px 11px;gap:10px;border-radius:10px;min-height:88px}
.crm-order-stats .crm-stat-icon{font-size:19px;padding:10px;border-radius:10px}
.crm-order-stats strong{font-size:21px}
.crm-order-stats small{font-size:10px}
.crm-board-filters{display:flex;flex-wrap:nowrap;align-items:center;gap:8px;margin:0 0 10px;padding:0}
.crm-board-filters>label{min-width:0;max-width:190px;flex:1 1 125px}
.crm-board-filters>label>select{height:36px;padding:7px 9px;font-size:10px}
.crm-board-filters>button{height:36px;padding:7px 10px;white-space:nowrap;font-size:10px}
.crm-board-filters .crm-extra-filters{display:contents}
.crm-board-filters .crm-extra-filters label{min-width:115px}
.crm-board-filters .crm-extra-filters input[type=date]{padding:7px}
.crm-board-filters .crm-check{display:flex;flex-direction:row;align-items:center;gap:5px;min-height:34px;white-space:nowrap}
.crm-board-filters input[type=checkbox]{width:15px;height:15px;padding:0}
.crm-results{margin:0 0 8px;font-size:10px}
.crm-view-switch button{height:32px;padding:6px 12px}
.crm-view-switch button[data-crm=board]{background:#582bdf;border-color:#8255f2}
.crm-board{gap:10px;padding-bottom:13px;height:calc(100vh - 300px);min-height:440px;scrollbar-width:thin}
.crm-column{flex:0 0 clamp(190px,calc((100vw - 244px)/6),218px);border-radius:10px}
.crm-column>header{min-height:66px;padding:9px;gap:8px}
.crm-column>header strong{font-size:11px}
.crm-column>header small{font-size:10px;margin-top:3px;color:#d3dbee}
.crm-column>header>[data-crm=new]{margin-left:auto;padding:5px 8px;background:color-mix(in srgb,var(--accent),transparent 76%);border:0;font-size:16px}
.crm-count{padding:7px;min-width:29px;font-size:11px}
.crm-cards{height:100%;min-height:0;padding:7px}
.crm-card{padding:8px;margin-bottom:7px;border-radius:8px;background:linear-gradient(135deg,#101b2e,#0b1423)}
.crm-card-top{margin-bottom:7px;min-height:17px}
.crm-card-top button{font-size:10px;min-height:0}
.crm-card-top time{font-size:9px}
.crm-card-top a{font-size:14px;font-weight:700}
.crm-product{gap:8px;margin-bottom:6px;align-items:flex-start}
.crm-photo{width:43px;height:53px}
.crm-product strong{font-size:10px;line-height:1.35}
.crm-product small{font-size:9px;line-height:1.45}
.crm-card-contact button{font-size:10px;font-weight:650;min-height:0;margin:0;padding:0}
.crm-card-contact small{font-size:9px;line-height:1.35}
.crm-card footer{margin:6px 0 0}
.crm-card footer .crm-badge{padding:4px 7px;font-size:9px}
.crm-card-actions{display:flex;align-items:center;gap:8px}
.crm-card-actions small{display:inline!important;font-size:9px}
.crm-card-actions strong{font-size:10px;white-space:nowrap}
.crm-card .crm-warning{font-size:9px}
.crm-empty{padding:24px 8px;font-size:20px}
.crm-profile-layout{display:grid;grid-template-columns:minmax(300px,1.12fr) minmax(270px,.94fr) minmax(245px,.9fr);gap:12px;align-items:stretch;margin-bottom:12px}
.crm-profile{padding:13px 12px;margin:0;gap:14px;flex-wrap:nowrap;min-width:0;border-radius:10px}
.crm-avatar{width:68px;height:68px;flex:0 0 68px;font-size:22px}
.crm-profile-copy{min-width:0;flex:1;overflow-wrap:anywhere}
.crm-profile h1{font-size:23px;margin:0 0 5px}
.crm-profile p{font-size:11px;line-height:1.4;margin:5px 0}
.crm-profile-copy>small{font-size:10px}
.crm-profile-copy .crm-badge{margin-bottom:2px;padding:4px 8px}
.crm-client-stats{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin:0}
.crm-client-stats>div{display:block;padding:10px 8px;border-radius:9px}
.crm-client-stats .crm-stat-icon{display:grid;width:38px;height:38px;font-size:18px;padding:8px;margin-bottom:8px}
.crm-client-stats strong{font-size:19px}
.crm-client-stats small{font-size:10px}
.crm-client-summary{margin:0;padding:10px 12px;display:flex;flex-direction:column;justify-content:space-between}
.crm-summary-head,.crm-summary-foot{display:flex;align-items:center;justify-content:space-between;gap:8px}
.crm-summary-head>div,.crm-summary-foot>span{display:grid;gap:5px}
.crm-summary-head small,.crm-summary-foot small{font-size:10px}
.crm-summary-head strong{font-size:14px;color:#ffbd4a;white-space:nowrap}
.crm-summary-foot strong{font-size:11px;font-weight:500}
.crm-summary-foot a{padding:9px;background:#101c31;border:1px solid #263754;border-radius:8px}
.crm-tabs{gap:0;margin:0 0 12px;padding:0;border-radius:8px;background:#0b1524}
.crm-tabs button{border:0;border-bottom:2px solid transparent;border-radius:0;padding:11px 15px;background:transparent;white-space:nowrap;font-size:11px}
.crm-tabs button:first-child{background:#15162f;color:#fff;border-bottom:2px solid #a44dff}
.crm-client-grid{grid-template-columns:minmax(0,2.2fr) minmax(300px,1fr);gap:14px;align-items:start}
.crm-panel{padding:14px;margin-bottom:12px;border-radius:10px}
.crm-panel h2{font-size:14px;margin:0}
.crm-panel-title{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:10px}
.crm-panel-title>button,.crm-panel-title select{padding:7px 10px;font-size:10px}
.crm-history>div{display:grid;grid-template-columns:30px minmax(112px,.75fr) minmax(155px,1.45fr) minmax(78px,.6fr) 88px 30px;gap:9px;padding:9px 0;flex-wrap:nowrap;font-size:10px;min-height:67px}
.crm-history>div>.crm-photo{width:43px;height:53px}
.crm-history>div>div{flex:initial;min-width:0}
.crm-history>div>div:nth-of-type(2){display:grid;gap:2px}
.crm-history>div>div:nth-of-type(2) strong{font-size:10px}
.crm-history>div>div:nth-of-type(2) small{font-size:9px}
.crm-history>div>button{padding:5px;font-size:9px;white-space:nowrap}
.crm-history>div>.crm-badge{padding:4px 6px;font-size:9px}
.crm-lower-grid{display:grid;grid-template-columns:minmax(245px,.92fr) minmax(285px,1.08fr);gap:12px;align-items:start}
.crm-info-list{display:grid;grid-template-columns:110px minmax(0,1fr);gap:12px 7px;font-size:11px;margin:16px 0 0}
.crm-info-list dt{color:var(--muted)}
.crm-info-list dd{margin:0;overflow-wrap:anywhere}
.crm-address{display:flex;align-items:center;gap:10px;padding:12px;margin:8px 0;font-size:11px}
.crm-address-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:50%;background:#30205d;color:#bf8bff;font-size:17px;flex-shrink:0}
.crm-address>div{min-width:0;flex:1}
.crm-address strong{color:#c680ff}
.crm-address p{margin:4px 0 0;font-size:10px;line-height:1.5}
.crm-address.is-primary{background:linear-gradient(120deg,#19123c,#10162b);border-color:#7141d3}
.crm-evaluation .crm-review-status{padding:12px;border:1px solid #087353;border-radius:8px;background:#032921;display:grid;gap:4px;margin:8px 0}
.crm-review-status strong{color:#00d5a0;font-size:11px}
.crm-review-status small{font-size:10px}
.crm-evaluation form{gap:7px}
.crm-evaluation form textarea{min-height:55px}
.crm-comment{padding:10px 0}
.crm-comment p,.crm-event p{font-size:10px;margin:4px 0;line-height:1.45}
.crm-comment>small,.crm-event small{font-size:9px}
.crm-event{padding:10px 0;gap:8px}
.crm-mini-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.crm-mini-stats>div{padding:10px;border:1px solid #1b2940;border-radius:8px;background:#0b1524}
.crm-mini-stats strong{display:block;font-size:15px}
.crm-mini-stats small{font-size:9px}
.crm-client-grid .crm-board-filters{display:flex}
.crm-client-grid .crm-board-filters>label{flex:1 1 110px}
.crm-shell:has(.crm-profile)>.crm-local{display:none}
@media(max-width:1200px){
 body:has(#page-orders-workspace.active) .sidebar{width:184px}
 body:has(#page-orders-workspace.active) .main{margin-left:184px}
 .crm-shell{padding:14px}
 .crm-order-stats{grid-template-columns:repeat(3,minmax(0,1fr))}
 .crm-heading{align-items:flex-start;flex-wrap:wrap}
 .crm-heading-actions{flex-wrap:wrap}
 .crm-profile-layout{grid-template-columns:minmax(290px,1.2fr) minmax(240px,1fr)}
 .crm-client-summary{grid-column:1/-1;min-height:92px}
 .crm-profile{min-height:140px}
 .crm-client-grid{grid-template-columns:minmax(0,1.8fr) minmax(260px,1fr)}
 .crm-history>div{grid-template-columns:30px minmax(100px,.7fr) minmax(140px,1.4fr) 78px 72px 30px;gap:6px}
 .crm-board{height:calc(100vh - 360px)}
}
@media(max-width:992px){
 body:has(#page-orders-workspace.active) .sidebar{width:270px}
 body:has(#page-orders-workspace.active) .main{margin-left:0}
 body:has(#page-orders-workspace.active) .topbar{display:grid}
 .crm-heading{flex-wrap:wrap}
 .crm-heading-actions{flex-wrap:wrap;justify-content:flex-start}
 .crm-search{width:min(55vw,400px)}
 .crm-board-filters{flex-wrap:wrap}
 .crm-board-filters>label{flex:1 1 125px}
 .crm-board-filters>button{flex:0 0 auto}
 .crm-profile-layout{grid-template-columns:1fr 1fr}
 .crm-client-grid{grid-template-columns:1fr}
 .crm-lower-grid{grid-template-columns:1fr 1fr}
 .crm-board{height:calc(100vh - 380px)}
}
@media(max-width:768px){
 .crm-shell{padding:12px!important}
 .crm-order-stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .crm-order-stats>div{min-height:72px;padding:9px}
 .crm-order-stats .crm-stat-icon{display:grid}
 .crm-board-filters{flex-wrap:wrap}
 .crm-board-filters>label{flex:1 1 135px;max-width:none}
 .crm-board-filters .crm-extra-filters{display:contents}
 .crm-extra-filters label{flex:1 1 120px}
 .crm-heading-actions{width:100%;display:grid;grid-template-columns:1fr 1fr}
 .crm-range{grid-column:1/-1}
 .crm-search{width:100%;grid-column:1/-1}
 .crm-heading-actions>button{grid-column:1/-1}
 .crm-column{flex-basis:280px}
 .crm-board{height:62vh;min-height:380px}
 .crm-profile-layout{grid-template-columns:1fr}
 .crm-profile{min-height:0}
 .crm-client-summary{grid-column:auto}
 .crm-tabs button{padding:10px 12px}
 .crm-history>div{grid-template-columns:34px minmax(75px,.65fr) minmax(120px,1.35fr) 65px 55px;gap:5px}
 .crm-history>div>[data-crm=order]:last-child{display:none}
 .crm-history>div>.crm-photo{width:38px;height:48px}
 .crm-lower-grid{grid-template-columns:1fr}
 .crm-detail-grid{grid-template-columns:1fr}
 .crm-panel{padding:12px}
 .crm-heading h1{font-size:20px}
}
@media(max-width:430px){
 .crm-heading-actions{grid-template-columns:1fr}
 .crm-range,.crm-search,.crm-heading-actions>button{grid-column:auto}
 .crm-heading-icon{width:40px;height:40px}
 .crm-history>div{grid-template-columns:30px minmax(70px,.7fr) minmax(110px,1.3fr) 55px}
 .crm-history>div>.crm-badge{display:none}
 .crm-history>div>strong{font-size:9px}
 .crm-profile{padding:12px}
 .crm-client-stats>div{padding:9px 6px}
 .crm-info-list{grid-template-columns:90px minmax(0,1fr)}
}
/* Orders board refresh: keep the toolbar compact and give each status a readable lane. */
body:has(#page-orders-workspace.active) .sidebar{width:184px}
body:has(#page-orders-workspace.active) .main{margin-left:184px}
body:has(#page-orders-workspace.active) .crm-shell{padding:12px 18px 18px;min-height:100vh;display:flex;flex-direction:column;gap:8px}
body:has(#page-orders-workspace.active) .crm-heading{min-height:42px;margin:0;gap:14px}
body:has(#page-orders-workspace.active) .crm-heading-icon{display:none}
body:has(#page-orders-workspace.active) .crm-title{min-width:180px;gap:0}
body:has(#page-orders-workspace.active) .crm-heading h1{font-size:19px}
body:has(#page-orders-workspace.active) .crm-heading p{display:none}
body:has(#page-orders-workspace.active) .crm-heading-actions{gap:8px}
body:has(#page-orders-workspace.active) .crm-search{height:36px;width:min(29vw,350px)}
body:has(#page-orders-workspace.active) .crm-range{height:36px;min-width:185px;font-size:10px}
body:has(#page-orders-workspace.active) .crm-heading-actions>button{height:36px;min-height:36px;padding:6px 10px}
body:has(#page-orders-workspace.active) .crm-order-stats{display:none}
body:has(#page-orders-workspace.active) .crm-board-filters{margin:0;gap:7px}
body:has(#page-orders-workspace.active) .crm-board-filters>label{flex:0 1 148px;max-width:148px}
body:has(#page-orders-workspace.active) .crm-board-filters>label>select{height:32px;padding:5px 8px}
body:has(#page-orders-workspace.active) .crm-board-filters>button{height:32px;padding:5px 9px}
body:has(#page-orders-workspace.active) .crm-results{margin:0;font-size:10px;min-height:22px}
body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 164px);min-height:420px;flex:1;gap:12px;padding-bottom:12px;scroll-snap-type:x mandatory;overscroll-behavior-x:contain}
body:has(#page-orders-workspace.active) .crm-column{flex:0 0 clamp(290px,23vw,340px);border:1px solid #202c43;border-radius:10px;background:#090f1b;scroll-snap-align:start;transition:border-color .16s,background .16s}
body:has(#page-orders-workspace.active) .crm-column>header{position:sticky;top:0;z-index:2;min-height:62px;padding:10px 12px;background:color-mix(in srgb,var(--accent),#0b1423 90%);border-bottom:1px solid #1c2940}
body:has(#page-orders-workspace.active) .crm-column>header strong{font-size:12px}
body:has(#page-orders-workspace.active) .crm-column>header small{font-size:9px;color:#8d9fbc}
body:has(#page-orders-workspace.active) .crm-count{padding:5px 7px;min-width:26px;background:color-mix(in srgb,var(--accent),#0b1423 70%);font-size:10px}
body:has(#page-orders-workspace.active) .crm-cards{height:calc(100% - 62px);min-height:0;padding:10px;overscroll-behavior-y:contain}
body:has(#page-orders-workspace.active) .crm-card{position:relative;padding:10px 11px;margin-bottom:8px;border-radius:9px;background:#101a2a;box-shadow:0 2px 8px #0002;cursor:grab;user-select:none}
body:has(#page-orders-workspace.active) .crm-card:active{cursor:grabbing}
body:has(#page-orders-workspace.active) .crm-card.is-dragging{opacity:.55;transform:scale(.98);box-shadow:0 12px 28px #0008}
body:has(#page-orders-workspace.active) .crm-column.is-drop-target{border-color:var(--accent);background:color-mix(in srgb,var(--accent),#080e19 94%)}
body:has(#page-orders-workspace.active) .crm-column.is-drop-target>header{background:color-mix(in srgb,var(--accent),#101728 82%)}
body:has(#page-orders-workspace.active) .crm-card-top{margin-bottom:7px}
body:has(#page-orders-workspace.active) .crm-card .crm-order-link{max-width:65%;font-size:11px}
body:has(#page-orders-workspace.active) .crm-card-top time{max-width:88px}
body:has(#page-orders-workspace.active) .crm-card-top a{font-size:12px}
body:has(#page-orders-workspace.active) .crm-product{align-items:center;margin-bottom:7px}
body:has(#page-orders-workspace.active) .crm-photo{width:44px;height:50px}
body:has(#page-orders-workspace.active) .crm-product strong{font-size:11px;line-height:1.35}
body:has(#page-orders-workspace.active) .crm-product small{font-size:9px;line-height:1.35}
body:has(#page-orders-workspace.active) .crm-card-contact{display:flex;align-items:center;gap:7px;min-width:0}
body:has(#page-orders-workspace.active) .crm-card-contact button{font-size:10px;white-space:nowrap;max-width:58%;overflow:hidden;text-overflow:ellipsis}
body:has(#page-orders-workspace.active) .crm-card-contact small{font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body:has(#page-orders-workspace.active) .crm-card footer{margin:7px 0 0;padding-top:7px;border-top:1px solid #1c2940}
body:has(#page-orders-workspace.active) .crm-card-state{font-size:9px;color:#95a8c5;max-width:58%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
body:has(#page-orders-workspace.active) .crm-card footer .crm-card-actions strong{font-size:10px}
body:has(#page-orders-workspace.active) .crm-mobile-stage{display:none}
body:has(#page-orders-workspace.active) .crm-stale{padding:7px 10px;border:1px solid #68552d;border-radius:7px;background:#241e12;color:#e7cb87;font-size:10px}
body:has(#page-orders-workspace.active) .crm-stale button{padding:3px 7px;margin-left:8px;font-size:10px}
@media(max-width:1200px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 178px)}body:has(#page-orders-workspace.active) .crm-column{flex-basis:310px}}
@media(max-width:992px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 218px)}body:has(#page-orders-workspace.active) .crm-heading{flex-wrap:wrap}body:has(#page-orders-workspace.active) .crm-heading-actions{display:flex;width:auto;margin-left:auto}body:has(#page-orders-workspace.active) .crm-search{width:min(34vw,300px)}}
@media(max-width:768px){body:has(#page-orders-workspace.active) .crm-shell{padding:10px!important;gap:7px}body:has(#page-orders-workspace.active) .crm-heading{display:flex;align-items:center;flex-wrap:wrap}body:has(#page-orders-workspace.active) .crm-heading-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;width:100%;margin:0}body:has(#page-orders-workspace.active) .crm-range{display:none}body:has(#page-orders-workspace.active) .crm-search{width:100%;height:36px}body:has(#page-orders-workspace.active) .crm-heading-actions>button{grid-column:auto;height:36px}body:has(#page-orders-workspace.active) .crm-board-filters>label{flex:1 1 120px;max-width:none}body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 202px);min-height:380px}body:has(#page-orders-workspace.active) .crm-column{flex-basis:min(86vw,360px)}body:has(#page-orders-workspace.active) .crm-mobile-stage{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:8px;margin-top:7px;color:#8d9fbc;font-size:9px}body:has(#page-orders-workspace.active) .crm-mobile-stage select{height:30px;padding:4px 8px;font-size:10px}}
@media(max-width:430px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100dvh - 230px);min-height:330px}body:has(#page-orders-workspace.active) .crm-column{flex-basis:calc(100vw - 32px)}body:has(#page-orders-workspace.active) .crm-board-filters{gap:5px}body:has(#page-orders-workspace.active) .crm-board-filters>label{flex-basis:calc(50% - 5px)}body:has(#page-orders-workspace.active) .crm-board-filters>button{flex:1}body:has(#page-orders-workspace.active) .crm-results{min-height:20px}}
@media(prefers-reduced-motion:reduce){body:has(#page-orders-workspace.active) .crm-column,body:has(#page-orders-workspace.active) .crm-card{transition:none}}
@media(max-width:1450px) and (min-width:1201px){body:has(#page-orders-workspace.active) .sidebar{width:220px}body:has(#page-orders-workspace.active) .main{margin-left:220px}}
#page-orders-workspace.active{padding:0!important;overflow:hidden;min-width:0;max-width:100%}
.manus-orders-host{width:100%;height:100vh;min-height:100vh;background:#f5f7fb;overflow:hidden}
.manus-orders-frame{display:block;width:100%;height:100%;min-height:100vh;border:0;background:#f5f7fb}
.manus-bridge-error{position:fixed;z-index:20;right:16px;bottom:16px;max-width:320px;padding:10px 13px;border:1px solid #efc1c1;border-radius:9px;background:#fff7f6;color:#a74949;box-shadow:0 8px 24px #1d2a3c20;font:12px/1.4 Inter,Arial,sans-serif}
#page-orders-workspace .crm-alert{display:none}
.crm-history>div{grid-template-columns:44px minmax(112px,.8fr) minmax(150px,1.35fr) minmax(90px,.7fr) 72px 92px}
.crm-history>div>.crm-photo{grid-column:1;grid-row:1;object-fit:contain}
.crm-history>div>div:nth-of-type(1){grid-column:2;grid-row:1;min-width:0}
.crm-history>div>div:nth-of-type(2){grid-column:3;grid-row:1;min-width:0}
.crm-history>div>.crm-badge{grid-column:4;grid-row:1}
.crm-history>div>strong{grid-column:5;grid-row:1;white-space:nowrap}
.crm-history>div>[data-crm=order]:last-child{grid-column:6;grid-row:1;min-height:32px}
.crm-client-grid>.crm-detail-grid>div:first-child{min-width:0}
.crm-client-grid aside{min-width:0}
@media(max-width:1200px){.crm-history>div{grid-template-columns:40px minmax(95px,.75fr) minmax(125px,1.25fr) 82px 68px 78px}}
@media(max-width:768px){.crm-history>div{grid-template-columns:40px minmax(85px,.75fr) minmax(125px,1.25fr) 70px 64px}.crm-history>div>[data-crm=order]:last-child{display:none}}
#page-orders-workspace .crm-shell>.crm-alert{display:none}
#page-orders-workspace .crm-shell>.crm-alert[role=alert]{display:block}
.crm-range{min-width:220px;position:relative}
.crm-range input{position:absolute;right:8px;width:20px;height:24px;cursor:pointer}
.crm-range input[data-filter=from]{right:32px}
.crm-range input[data-filter=to]{right:7px}
.crm-range input::-webkit-calendar-picker-indicator{opacity:.65;cursor:pointer}
.crm-client-summary .crm-summary-head>div{min-width:0}
.crm-client-summary .crm-summary-head strong{white-space:normal}
.crm-card .crm-order-link{border:0;background:none;padding:0;color:#edf2ff;font-size:10px;font-weight:700;line-height:1.2;text-align:left;overflow-wrap:anywhere;cursor:pointer;flex:1;min-width:0}
.crm-card .crm-card-top .crm-order-link{min-height:0}
.crm-column>header>div{flex:1;min-width:0}
.crm-column>header strong{overflow-wrap:anywhere}
.crm-history>div{grid-template-columns:44px minmax(112px,.8fr) minmax(150px,1.35fr) minmax(90px,.7fr) 72px 92px}
.crm-history>div>.crm-photo{grid-column:1;grid-row:1;object-fit:contain}
.crm-history>div>div:nth-of-type(1){grid-column:2;grid-row:1;min-width:0}
.crm-history>div>div:nth-of-type(2){grid-column:3;grid-row:1;min-width:0}
.crm-history>div>.crm-badge{grid-column:4;grid-row:1}
.crm-history>div>strong{grid-column:5;grid-row:1;white-space:nowrap}
.crm-history>div>[data-crm=order]:last-child{grid-column:6;grid-row:1;min-height:32px;padding:7px 8px}
.crm-client-grid .crm-history{min-width:0;overflow-x:auto}
.crm-profile-copy>p span{margin-left:5px}
.crm-summary-head>button{padding:5px 9px}
.crm-board{min-height:420px}
.crm-range{min-width:220px;position:relative}
.crm-range input{position:absolute;right:8px;width:20px;height:24px;cursor:pointer}
.crm-range input[data-filter=from]{right:32px}
.crm-range input[data-filter=to]{right:7px}
.crm-range input::-webkit-calendar-picker-indicator{opacity:.65;cursor:pointer}
.crm-client-summary .crm-summary-head>div{min-width:0}
.crm-client-summary .crm-summary-head strong{white-space:normal}
@media(max-width:1200px){.crm-history>div{grid-template-columns:40px minmax(95px,.75fr) minmax(125px,1.25fr) 82px 68px 78px}}
@media(max-width:768px){.crm-history>div{grid-template-columns:40px minmax(85px,.75fr) minmax(125px,1.25fr) 70px 64px}.crm-history>div>[data-crm=order]:last-child{display:none}}
#page-orders-workspace .crm-shell>.crm-alert{display:none!important}
#page-orders-workspace .crm-shell>.crm-alert[role=alert]{display:block!important}
.crm-card .crm-card-top .crm-order-link{flex:1 1 auto;width:auto;max-width:52%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crm-card .crm-card-top time{flex:0 0 auto;max-width:50px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crm-card .crm-card-top a{flex:0 0 22px;text-align:right;white-space:nowrap}
.crm-profile-layout{grid-template-columns:minmax(280px,1.12fr) minmax(270px,.94fr) minmax(220px,.9fr)}
@media(max-width:1200px){.crm-profile-layout{grid-template-columns:minmax(250px,1.1fr) minmax(230px,1fr)}.crm-client-summary{grid-column:1/-1}}
@media(min-width:1201px) and (max-width:1400px){.crm-profile-layout{grid-template-columns:minmax(250px,1.05fr) minmax(240px,.95fr) minmax(205px,.85fr)}.crm-profile{gap:9px;padding:12px}.crm-avatar{width:58px;height:58px;flex-basis:58px}.crm-profile h1{font-size:20px}}

.crm-shell:has(.crm-profile) .crm-tabs{background:transparent!important}.crm-shell:has(.crm-profile) .crm-mini-stats>div{background:#f7f9fc!important;border:1px solid #e9edf4!important;border-radius:10px;color:#344155!important}.crm-shell:has(.crm-profile) .crm-mini-stats strong{color:#243148!important}.crm-shell:has(.crm-profile) .crm-mini-stats small{color:#8994a7!important}.crm-shell:has(.crm-profile) .crm-tabs button:hover{background:#edf2ff!important}
/* Manus Client 360 reference styling, scoped to the existing client detail view. */
.client-page{--client-ink:#172033;--client-muted:#8792a5;--client-line:#e7ebf2;--client-indigo:#4d72e8;color:var(--client-ink);background:#f5f7fb;border-radius:14px;min-height:100vh;font-family:Inter,"Segoe UI",sans-serif}.client-page *{box-sizing:border-box}.client-topbar{height:54px;display:flex;align-items:center;gap:18px;padding:0 22px;background:#fff;border-bottom:1px solid var(--client-line);border-radius:14px 14px 0 0}.client-topbar button{background:transparent!important;color:#68758d!important;border:0!important;padding:6px 0!important}.client-topbar-trail{font-size:11px;color:#8994a7}.client-topbar-user{margin-left:auto;color:#98a2b2;font-size:10px}.client-content{max-width:1450px;margin:auto;padding:20px 24px 40px}.client-breadcrumb{font-size:10px;color:#9ba5b5;margin-bottom:14px}.client-breadcrumb span{padding:0 8px;color:#cbd1dc}.client-breadcrumb strong{color:#58657b}.client-hero{display:flex;align-items:center;justify-content:space-between;gap:22px;padding:22px 24px;background:linear-gradient(112deg,#fff,#f8faff);border:1px solid var(--client-line);border-radius:16px;box-shadow:0 8px 26px #22365f09}.client-hero-person{display:flex;align-items:center;gap:17px;min-width:0}.client-avatar-large{display:grid;place-items:center;flex:0 0 68px;width:68px;height:68px;border-radius:21px;background:#e7edff;color:#4563bb;font-size:20px;font-weight:780}.client-eyebrow{color:#8490a4;font-size:9px;font-weight:700;letter-spacing:.09em}.client-hero h1{margin:5px 0 8px;font-size:25px;letter-spacing:-.04em;color:#172033}.client-hero-meta{display:flex;gap:16px;flex-wrap:wrap;color:#68758d;font-size:11px}.client-hero-actions{display:flex;gap:8px;margin-top:12px}.client-hero-actions a,.client-call{display:inline-flex;align-items:center;padding:7px 11px;border:1px solid #e5eaf2;border-radius:8px;color:#51617b;background:#fff;font-size:10px;text-decoration:none}.client-assessment{display:grid;gap:7px;justify-items:end;max-width:220px}.client-assessment small,.client-assessment span{font-size:9px;color:#8994a7}.client-assessment strong{padding:7px 11px;border-radius:20px;background:#edf3ff;color:#4263bd;font-size:11px}.client-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:14px 0}.client-metrics article{display:grid;gap:7px;padding:14px 16px;background:#fff;border:1px solid var(--client-line);border-radius:12px}.client-metrics small{font-size:10px;color:#8490a4}.client-metrics strong{font-size:22px;color:#172033}.client-metrics span{font-size:9px;color:#97a1b0}.client-layout{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(285px,.9fr);align-items:start;gap:14px}.client-card{margin-bottom:14px;padding:18px;background:#fff;border:1px solid var(--client-line);border-radius:13px;box-shadow:0 5px 20px #22365f06;scroll-margin-top:15px}.client-card-head{display:flex;align-items:center;justify-content:space-between;margin-bottom:13px}.client-card-head small{color:#8b96a8;font-size:9px;font-weight:700;letter-spacing:.08em}.client-card h2{margin:4px 0 0;color:#1e293b;font-size:17px}.client-card h2 span{color:#8490a4;font-size:11px}.client-card h3{margin:16px 0 8px;color:#536178;font-size:11px}.client-order-row{display:grid;grid-template-columns:42px minmax(0,1fr) auto auto auto;align-items:center;gap:11px;padding:11px 0;border-top:1px solid #eef0f4}.client-order-thumb .crm-photo{width:40px;height:44px;border-radius:8px;background:#f2f4f8}.client-order-copy{display:grid;gap:3px;min-width:0}.client-order-copy strong,.client-order-copy b{color:#344155;font-size:10px}.client-order-copy small{color:#8994a7;font-size:9px}.client-order-copy strong small{margin-left:8px;font-weight:400}.client-order-status{padding:5px 8px;border-radius:16px;background:color-mix(in srgb,var(--tone) 12%,white);color:var(--tone);font-size:9px;white-space:nowrap}.client-order-total{font-size:10px;color:#344155;white-space:nowrap}.client-order-row button{background:#f2f5ff!important;color:#526db3!important;border:1px solid #e4eafb!important;padding:6px 8px!important;font-size:9px!important;white-space:nowrap}.client-info-grid{display:grid;grid-template-columns:minmax(130px,.65fr) minmax(0,1fr);gap:10px;margin:0}.client-info-grid dt{color:#8994a7;font-size:10px}.client-info-grid dd{margin:0;color:#344155;font-size:10px;font-weight:600;overflow-wrap:anywhere}.client-address{padding:9px 10px;background:#f7f8fb;border-radius:8px;color:#536178;font-size:10px}.client-review{display:grid;gap:5px;padding:10px 0;border-top:1px solid #eef0f4}.client-review strong{color:#52617a;font-size:10px}.client-review small,.client-private{color:#8994a7;font-size:9px}.client-card form{display:grid;gap:8px}.client-card form label{display:grid;gap:5px;margin:4px 0;color:#657188;font-size:10px}.client-card form input,.client-card form select,.client-card form textarea{width:100%;padding:9px 10px;border:1px solid #e1e6ef;border-radius:8px;background:#fff;color:#344155;font:inherit;font-size:10px}.client-card form textarea{min-height:75px;resize:vertical}.client-card form button{width:max-content;max-width:100%;background:#4d69bc!important;border:0!important;border-radius:8px;color:#fff!important;padding:9px 12px!important;font-size:10px!important}.client-card .crm-comment{padding:10px 0;border-bottom:1px solid #eef0f4;color:#536178}.client-card .crm-comment p{color:#536178;font-size:10px}.client-card .crm-comment small{display:block;margin-top:4px;color:#8994a7;font-size:9px}.client-card .crm-event{border-color:#eef0f4;color:#536178}.client-card .crm-event p{color:#657188}.client-empty,.client-card>p{color:#8994a7;font-size:10px}
@media(max-width:900px){.client-layout{grid-template-columns:1fr}.client-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.client-assessment{justify-items:start}}
@media(max-width:600px){.client-content{padding:14px 10px 28px}.client-topbar{padding:0 12px}.client-topbar-user{display:none}.client-hero{align-items:flex-start;flex-direction:column;padding:16px}.client-hero h1{font-size:21px}.client-avatar-large{width:54px;height:54px;flex-basis:54px;border-radius:17px}.client-order-row{grid-template-columns:36px minmax(0,1fr) auto;gap:8px}.client-order-thumb .crm-photo{width:34px;height:38px}.client-order-status{grid-column:2;justify-self:start}.client-order-total{grid-column:3;grid-row:2}.client-order-row button{grid-column:3;grid-row:1}.client-metrics article{padding:12px}.client-metrics strong{font-size:19px}.client-card{padding:14px}}
.crm-shell,.crm-shell *{font-family:Inter,"Segoe UI",sans-serif!important}.crm-shell p,.crm-shell small,.crm-shell time,.crm-shell label,.crm-shell input,.crm-shell textarea{font-weight:400!important}.crm-comment{padding:15px 0;border-bottom:1px solid #1c2a40;font-size:12px}.crm-comment p{white-space:pre-wrap}.crm-comment button{margin-right:6px;margin-top:8px}.crm-shell .crm-product-photo-edit{display:none}
.crm-tabs{display:flex;gap:8px;overflow-x:auto;margin:12px 0 22px;padding-bottom:5px;max-width:100%}.crm-tabs button{flex-shrink:0;background:#10182b}.crm-tabs button:first-child{background:#4e238a;border-bottom-color:#a35dff}.crm-panel{scroll-margin-top:20px}.crm-panel summary{font-size:12px;color:#c4a3ff;cursor:pointer;margin:16px 0}
.crm-internal-badge{font-size:9px!important;color:#00c99a!important;display:block!important;line-height:1.5!important}
.crm-skeleton{display:flex;gap:14px;overflow:hidden;margin-top:25px}.crm-skeleton>div{height:360px;flex:1;min-width:200px;border-radius:12px;background:linear-gradient(110deg,#111a2c,#19233c,#111a2c);background-size:200% 100%;animation:crm-loading 1.4s ease infinite}@keyframes crm-loading{to{background-position:-200% 0}}
#page-orders-workspace{padding:0!important;gap:0!important;min-width:0;max-width:100%}
body:has(#page-orders-workspace.active) .sidebar{width:184px}
body:has(#page-orders-workspace.active) .main{margin-left:184px}
body:has(#page-orders-workspace.active) .topbar{display:none}
body:has(#page-orders-workspace.active) .crm-shell{padding:16px 20px 22px;min-height:100vh;background:radial-gradient(ellipse at 12% 0,rgba(103,49,225,.07),transparent 40%),#050e1a}
.crm-shell{--ink:#edf2ff;--muted:#8d9fbc;color:var(--ink);font-family:Inter,"Segoe UI",sans-serif}
.crm-local{display:none}
.crm-heading{margin:0 0 15px;min-height:49px;gap:16px;flex-wrap:nowrap}
.crm-title{display:flex;align-items:center;gap:14px;min-width:220px}
.crm-heading-icon{width:48px;height:48px;border-radius:12px;background:#171a37;color:#a986ff;display:grid;place-items:center;font-size:25px;border:1px solid #29264e}
.crm-heading h1{font-size:22px;margin:0;letter-spacing:-.5px}
.crm-heading p{font-size:11px;margin:3px 0 0}
.crm-heading-actions{display:flex;align-items:center;justify-content:flex-end;gap:10px;min-width:0;flex:1}
.crm-range{display:flex;align-items:center;gap:7px;white-space:nowrap;border:1px solid #20314d;background:#0a1423;border-radius:8px;padding:0 9px;height:42px;color:#dbe4f5;font-size:11px}
.crm-range input{width:17px;padding:0;border:0;background:transparent;color:transparent;opacity:.8}
.crm-search{width:min(29vw,380px);height:42px;font-size:11px!important}
.crm-heading-actions>.crm-heading-actions,.crm-heading-actions>button{background:linear-gradient(120deg,#8243ff,#5b29e7)!important;border-color:#945bff!important;white-space:nowrap;height:42px}
.crm-order-stats{grid-template-columns:repeat(6,minmax(0,1fr));gap:10px;margin:14px 0 15px}
.crm-order-stats>div{padding:12px 11px;gap:10px;border-radius:10px;min-height:88px}
.crm-order-stats .crm-stat-icon{font-size:19px;padding:10px;border-radius:10px}
.crm-order-stats strong{font-size:21px}
.crm-order-stats small{font-size:10px}
.crm-board-filters{display:flex;flex-wrap:nowrap;align-items:center;gap:8px;margin:0 0 10px;padding:0}
.crm-board-filters>label{min-width:0;max-width:190px;flex:1 1 125px}
.crm-board-filters>label>select{height:36px;padding:7px 9px;font-size:10px}
.crm-board-filters>button{height:36px;padding:7px 10px;white-space:nowrap;font-size:10px}
.crm-board-filters .crm-extra-filters{display:contents}
.crm-board-filters .crm-extra-filters label{min-width:115px}
.crm-board-filters .crm-extra-filters input[type=date]{padding:7px}
.crm-board-filters .crm-check{display:flex;flex-direction:row;align-items:center;gap:5px;min-height:34px;white-space:nowrap}
.crm-board-filters input[type=checkbox]{width:15px;height:15px;padding:0}
.crm-results{margin:0 0 8px;font-size:10px}
.crm-view-switch button{height:32px;padding:6px 12px}
.crm-view-switch button[data-crm=board]{background:#582bdf;border-color:#8255f2}
.crm-board{gap:10px;padding-bottom:13px;height:calc(100vh - 300px);min-height:440px;scrollbar-width:thin}
.crm-column{flex:0 0 clamp(190px,calc((100vw - 244px)/6),218px);border-radius:10px}
.crm-column>header{min-height:66px;padding:9px;gap:8px}
.crm-column>header strong{font-size:11px}
.crm-column>header small{font-size:10px;margin-top:3px;color:#d3dbee}
.crm-column>header>[data-crm=new]{margin-left:auto;padding:5px 8px;background:color-mix(in srgb,var(--accent),transparent 76%);border:0;font-size:16px}
.crm-count{padding:7px;min-width:29px;font-size:11px}
.crm-cards{height:100%;min-height:0;padding:7px}
.crm-card{padding:8px;margin-bottom:7px;border-radius:8px;background:linear-gradient(135deg,#101b2e,#0b1423)}
.crm-card-top{margin-bottom:7px;min-height:17px}
.crm-card-top button{font-size:10px;min-height:0}
.crm-card-top time{font-size:9px}
.crm-card-top a{font-size:14px;font-weight:700}
.crm-product{gap:8px;margin-bottom:6px;align-items:flex-start}
.crm-photo{width:43px;height:53px}
.crm-product strong{font-size:10px;line-height:1.35}
.crm-product small{font-size:9px;line-height:1.45}
.crm-card-contact button{font-size:10px;font-weight:650;min-height:0;margin:0;padding:0}
.crm-card-contact small{font-size:9px;line-height:1.35}
.crm-card footer{margin:6px 0 0}
.crm-card footer .crm-badge{padding:4px 7px;font-size:9px}
.crm-card-actions{display:flex;align-items:center;gap:8px}
.crm-card-actions small{display:inline!important;font-size:9px}
.crm-card-actions strong{font-size:10px;white-space:nowrap}
.crm-card .crm-warning{font-size:9px}
.crm-empty{padding:24px 8px;font-size:20px}
.crm-profile-layout{display:grid;grid-template-columns:minmax(300px,1.12fr) minmax(270px,.94fr) minmax(245px,.9fr);gap:12px;align-items:stretch;margin-bottom:12px}
.crm-profile{padding:13px 12px;margin:0;gap:14px;flex-wrap:nowrap;min-width:0;border-radius:10px}
.crm-avatar{width:68px;height:68px;flex:0 0 68px;font-size:22px}
.crm-profile-copy{min-width:0;flex:1;overflow-wrap:anywhere}
.crm-profile h1{font-size:23px;margin:0 0 5px}
.crm-profile p{font-size:11px;line-height:1.4;margin:5px 0}
.crm-profile-copy>small{font-size:10px}
.crm-profile-copy .crm-badge{margin-bottom:2px;padding:4px 8px}
.crm-client-stats{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;margin:0}
.crm-client-stats>div{display:block;padding:10px 8px;border-radius:9px}
.crm-client-stats .crm-stat-icon{display:grid;width:38px;height:38px;font-size:18px;padding:8px;margin-bottom:8px}
.crm-client-stats strong{font-size:19px}
.crm-client-stats small{font-size:10px}
.crm-client-summary{margin:0;padding:10px 12px;display:flex;flex-direction:column;justify-content:space-between}
.crm-summary-head,.crm-summary-foot{display:flex;align-items:center;justify-content:space-between;gap:8px}
.crm-summary-head>div,.crm-summary-foot>span{display:grid;gap:5px}
.crm-summary-head small,.crm-summary-foot small{font-size:10px}
.crm-summary-head strong{font-size:14px;color:#ffbd4a;white-space:nowrap}
.crm-summary-foot strong{font-size:11px;font-weight:500}
.crm-summary-foot a{padding:9px;background:#101c31;border:1px solid #263754;border-radius:8px}
.crm-tabs{gap:0;margin:0 0 12px;padding:0;border-radius:8px;background:#0b1524}
.crm-tabs button{border:0;border-bottom:2px solid transparent;border-radius:0;padding:11px 15px;background:transparent;white-space:nowrap;font-size:11px}
.crm-tabs button:first-child{background:#15162f;color:#fff;border-bottom:2px solid #a44dff}
.crm-client-grid{grid-template-columns:minmax(0,2.2fr) minmax(300px,1fr);gap:14px;align-items:start}
.crm-panel{padding:14px;margin-bottom:12px;border-radius:10px}
.crm-panel h2{font-size:14px;margin:0}
.crm-panel-title{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-bottom:10px}
.crm-panel-title>button,.crm-panel-title select{padding:7px 10px;font-size:10px}
.crm-history>div{display:grid;grid-template-columns:30px minmax(112px,.75fr) minmax(155px,1.45fr) minmax(78px,.6fr) 88px 30px;gap:9px;padding:9px 0;flex-wrap:nowrap;font-size:10px;min-height:67px}
.crm-history>div>.crm-photo{width:43px;height:53px}
.crm-history>div>div{flex:initial;min-width:0}
.crm-history>div>div:nth-of-type(2){display:grid;gap:2px}
.crm-history>div>div:nth-of-type(2) strong{font-size:10px}
.crm-history>div>div:nth-of-type(2) small{font-size:9px}
.crm-history>div>button{padding:5px;font-size:9px;white-space:nowrap}
.crm-history>div>.crm-badge{padding:4px 6px;font-size:9px}
.crm-lower-grid{display:grid;grid-template-columns:minmax(245px,.92fr) minmax(285px,1.08fr);gap:12px;align-items:start}
.crm-info-list{display:grid;grid-template-columns:110px minmax(0,1fr);gap:12px 7px;font-size:11px;margin:16px 0 0}
.crm-info-list dt{color:var(--muted)}
.crm-info-list dd{margin:0;overflow-wrap:anywhere}
.crm-address{display:flex;align-items:center;gap:10px;padding:12px;margin:8px 0;font-size:11px}
.crm-address-icon{display:grid;place-items:center;width:36px;height:36px;border-radius:50%;background:#30205d;color:#bf8bff;font-size:17px;flex-shrink:0}
.crm-address>div{min-width:0;flex:1}
.crm-address strong{color:#c680ff}
.crm-address p{margin:4px 0 0;font-size:10px;line-height:1.5}
.crm-address.is-primary{background:linear-gradient(120deg,#19123c,#10162b);border-color:#7141d3}
.crm-evaluation .crm-review-status{padding:12px;border:1px solid #087353;border-radius:8px;background:#032921;display:grid;gap:4px;margin:8px 0}
.crm-review-status strong{color:#00d5a0;font-size:11px}
.crm-review-status small{font-size:10px}
.crm-evaluation form{gap:7px}
.crm-evaluation form textarea{min-height:55px}
.crm-comment{padding:10px 0}
.crm-comment p,.crm-event p{font-size:10px;margin:4px 0;line-height:1.45}
.crm-comment>small,.crm-event small{font-size:9px}
.crm-event{padding:10px 0;gap:8px}
.crm-mini-stats{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.crm-mini-stats>div{padding:10px;border:1px solid #1b2940;border-radius:8px;background:#0b1524}
.crm-mini-stats strong{display:block;font-size:15px}
.crm-mini-stats small{font-size:9px}
.crm-client-grid .crm-board-filters{display:flex}
.crm-client-grid .crm-board-filters>label{flex:1 1 110px}
.crm-shell:has(.crm-profile)>.crm-local{display:none}
@media(max-width:1200px){
 body:has(#page-orders-workspace.active) .sidebar{width:184px}
 body:has(#page-orders-workspace.active) .main{margin-left:184px}
 .crm-shell{padding:14px}
 .crm-order-stats{grid-template-columns:repeat(3,minmax(0,1fr))}
 .crm-heading{align-items:flex-start;flex-wrap:wrap}
 .crm-heading-actions{flex-wrap:wrap}
 .crm-profile-layout{grid-template-columns:minmax(290px,1.2fr) minmax(240px,1fr)}
 .crm-client-summary{grid-column:1/-1;min-height:92px}
 .crm-profile{min-height:140px}
 .crm-client-grid{grid-template-columns:minmax(0,1.8fr) minmax(260px,1fr)}
 .crm-history>div{grid-template-columns:30px minmax(100px,.7fr) minmax(140px,1.4fr) 78px 72px 30px;gap:6px}
 .crm-board{height:calc(100vh - 360px)}
}
@media(max-width:992px){
 body:has(#page-orders-workspace.active) .sidebar{width:270px}
 body:has(#page-orders-workspace.active) .main{margin-left:0}
 body:has(#page-orders-workspace.active) .topbar{display:grid}
 .crm-heading{flex-wrap:wrap}
 .crm-heading-actions{flex-wrap:wrap;justify-content:flex-start}
 .crm-search{width:min(55vw,400px)}
 .crm-board-filters{flex-wrap:wrap}
 .crm-board-filters>label{flex:1 1 125px}
 .crm-board-filters>button{flex:0 0 auto}
 .crm-profile-layout{grid-template-columns:1fr 1fr}
 .crm-client-grid{grid-template-columns:1fr}
 .crm-lower-grid{grid-template-columns:1fr 1fr}
 .crm-board{height:calc(100vh - 380px)}
}
@media(max-width:768px){
 .crm-shell{padding:12px!important}
 .crm-order-stats{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 .crm-order-stats>div{min-height:72px;padding:9px}
 .crm-order-stats .crm-stat-icon{display:grid}
 .crm-board-filters{flex-wrap:wrap}
 .crm-board-filters>label{flex:1 1 135px;max-width:none}
 .crm-board-filters .crm-extra-filters{display:contents}
 .crm-extra-filters label{flex:1 1 120px}
 .crm-heading-actions{width:100%;display:grid;grid-template-columns:1fr 1fr}
 .crm-range{grid-column:1/-1}
 .crm-search{width:100%;grid-column:1/-1}
 .crm-heading-actions>button{grid-column:1/-1}
 .crm-column{flex-basis:280px}
 .crm-board{height:62vh;min-height:380px}
 .crm-profile-layout{grid-template-columns:1fr}
 .crm-profile{min-height:0}
 .crm-client-summary{grid-column:auto}
 .crm-tabs button{padding:10px 12px}
 .crm-history>div{grid-template-columns:34px minmax(75px,.65fr) minmax(120px,1.35fr) 65px 55px;gap:5px}
 .crm-history>div>[data-crm=order]:last-child{display:none}
 .crm-history>div>.crm-photo{width:38px;height:48px}
 .crm-lower-grid{grid-template-columns:1fr}
 .crm-detail-grid{grid-template-columns:1fr}
 .crm-panel{padding:12px}
 .crm-heading h1{font-size:20px}
}
@media(max-width:430px){
 .crm-heading-actions{grid-template-columns:1fr}
 .crm-range,.crm-search,.crm-heading-actions>button{grid-column:auto}
 .crm-heading-icon{width:40px;height:40px}
 .crm-history>div{grid-template-columns:30px minmax(70px,.7fr) minmax(110px,1.3fr) 55px}
 .crm-history>div>.crm-badge{display:none}
 .crm-history>div>strong{font-size:9px}
 .crm-profile{padding:12px}
 .crm-client-stats>div{padding:9px 6px}
 .crm-info-list{grid-template-columns:90px minmax(0,1fr)}
}
/* Orders board refresh: keep the toolbar compact and give each status a readable lane. */
body:has(#page-orders-workspace.active) .sidebar{width:184px}
body:has(#page-orders-workspace.active) .main{margin-left:184px}
body:has(#page-orders-workspace.active) .crm-shell{padding:12px 18px 18px;min-height:100vh;display:flex;flex-direction:column;gap:8px}
body:has(#page-orders-workspace.active) .crm-heading{min-height:42px;margin:0;gap:14px}
body:has(#page-orders-workspace.active) .crm-heading-icon{display:none}
body:has(#page-orders-workspace.active) .crm-title{min-width:180px;gap:0}
body:has(#page-orders-workspace.active) .crm-heading h1{font-size:19px}
body:has(#page-orders-workspace.active) .crm-heading p{display:none}
body:has(#page-orders-workspace.active) .crm-heading-actions{gap:8px}
body:has(#page-orders-workspace.active) .crm-search{height:36px;width:min(29vw,350px)}
body:has(#page-orders-workspace.active) .crm-range{height:36px;min-width:185px;font-size:10px}
body:has(#page-orders-workspace.active) .crm-heading-actions>button{height:36px;min-height:36px;padding:6px 10px}
body:has(#page-orders-workspace.active) .crm-order-stats{display:none}
body:has(#page-orders-workspace.active) .crm-board-filters{margin:0;gap:7px}
body:has(#page-orders-workspace.active) .crm-board-filters>label{flex:0 1 148px;max-width:148px}
body:has(#page-orders-workspace.active) .crm-board-filters>label>select{height:32px;padding:5px 8px}
body:has(#page-orders-workspace.active) .crm-board-filters>button{height:32px;padding:5px 9px}
body:has(#page-orders-workspace.active) .crm-results{margin:0;font-size:10px;min-height:22px}
body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 164px);min-height:420px;flex:1;gap:12px;padding-bottom:12px;scroll-snap-type:x mandatory;overscroll-behavior-x:contain}
body:has(#page-orders-workspace.active) .crm-column{flex:0 0 clamp(290px,23vw,340px);border:1px solid #202c43;border-radius:10px;background:#090f1b;scroll-snap-align:start;transition:border-color .16s,background .16s}
body:has(#page-orders-workspace.active) .crm-column>header{position:sticky;top:0;z-index:2;min-height:62px;padding:10px 12px;background:color-mix(in srgb,var(--accent),#0b1423 90%);border-bottom:1px solid #1c2940}
body:has(#page-orders-workspace.active) .crm-column>header strong{font-size:12px}
body:has(#page-orders-workspace.active) .crm-column>header small{font-size:9px;color:#8d9fbc}
body:has(#page-orders-workspace.active) .crm-count{padding:5px 7px;min-width:26px;background:color-mix(in srgb,var(--accent),#0b1423 70%);font-size:10px}
body:has(#page-orders-workspace.active) .crm-cards{height:calc(100% - 62px);min-height:0;padding:10px;overscroll-behavior-y:contain}
body:has(#page-orders-workspace.active) .crm-card{position:relative;padding:10px 11px;margin-bottom:8px;border-radius:9px;background:#101a2a;box-shadow:0 2px 8px #0002;cursor:grab;user-select:none}
body:has(#page-orders-workspace.active) .crm-card:active{cursor:grabbing}
body:has(#page-orders-workspace.active) .crm-card.is-dragging{opacity:.55;transform:scale(.98);box-shadow:0 12px 28px #0008}
body:has(#page-orders-workspace.active) .crm-column.is-drop-target{border-color:var(--accent);background:color-mix(in srgb,var(--accent),#080e19 94%)}
body:has(#page-orders-workspace.active) .crm-column.is-drop-target>header{background:color-mix(in srgb,var(--accent),#101728 82%)}
body:has(#page-orders-workspace.active) .crm-card-top{margin-bottom:7px}
body:has(#page-orders-workspace.active) .crm-card .crm-order-link{max-width:65%;font-size:11px}
body:has(#page-orders-workspace.active) .crm-card-top time{max-width:88px}
body:has(#page-orders-workspace.active) .crm-card-top a{font-size:12px}
body:has(#page-orders-workspace.active) .crm-product{align-items:center;margin-bottom:7px}
body:has(#page-orders-workspace.active) .crm-photo{width:44px;height:50px}
body:has(#page-orders-workspace.active) .crm-product strong{font-size:11px;line-height:1.35}
body:has(#page-orders-workspace.active) .crm-product small{font-size:9px;line-height:1.35}
body:has(#page-orders-workspace.active) .crm-card-contact{display:flex;align-items:center;gap:7px;min-width:0}
body:has(#page-orders-workspace.active) .crm-card-contact button{font-size:10px;white-space:nowrap;max-width:58%;overflow:hidden;text-overflow:ellipsis}
body:has(#page-orders-workspace.active) .crm-card-contact small{font-size:9px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
body:has(#page-orders-workspace.active) .crm-card footer{margin:7px 0 0;padding-top:7px;border-top:1px solid #1c2940}
body:has(#page-orders-workspace.active) .crm-card-state{font-size:9px;color:#95a8c5;max-width:58%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
body:has(#page-orders-workspace.active) .crm-card footer .crm-card-actions strong{font-size:10px}
body:has(#page-orders-workspace.active) .crm-mobile-stage{display:none}
body:has(#page-orders-workspace.active) .crm-stale{padding:7px 10px;border:1px solid #68552d;border-radius:7px;background:#241e12;color:#e7cb87;font-size:10px}
body:has(#page-orders-workspace.active) .crm-stale button{padding:3px 7px;margin-left:8px;font-size:10px}
@media(max-width:1200px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 178px)}body:has(#page-orders-workspace.active) .crm-column{flex-basis:310px}}
@media(max-width:992px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 218px)}body:has(#page-orders-workspace.active) .crm-heading{flex-wrap:wrap}body:has(#page-orders-workspace.active) .crm-heading-actions{display:flex;width:auto;margin-left:auto}body:has(#page-orders-workspace.active) .crm-search{width:min(34vw,300px)}}
@media(max-width:768px){body:has(#page-orders-workspace.active) .crm-shell{padding:10px!important;gap:7px}body:has(#page-orders-workspace.active) .crm-heading{display:flex;align-items:center;flex-wrap:wrap}body:has(#page-orders-workspace.active) .crm-heading-actions{display:grid;grid-template-columns:minmax(0,1fr) auto;width:100%;margin:0}body:has(#page-orders-workspace.active) .crm-range{display:none}body:has(#page-orders-workspace.active) .crm-search{width:100%;height:36px}body:has(#page-orders-workspace.active) .crm-heading-actions>button{grid-column:auto;height:36px}body:has(#page-orders-workspace.active) .crm-board-filters>label{flex:1 1 120px;max-width:none}body:has(#page-orders-workspace.active) .crm-board{height:calc(100vh - 202px);min-height:380px}body:has(#page-orders-workspace.active) .crm-column{flex-basis:min(86vw,360px)}body:has(#page-orders-workspace.active) .crm-mobile-stage{display:grid;grid-template-columns:auto minmax(0,1fr);align-items:center;gap:8px;margin-top:7px;color:#8d9fbc;font-size:9px}body:has(#page-orders-workspace.active) .crm-mobile-stage select{height:30px;padding:4px 8px;font-size:10px}}
@media(max-width:430px){body:has(#page-orders-workspace.active) .crm-board{height:calc(100dvh - 230px);min-height:330px}body:has(#page-orders-workspace.active) .crm-column{flex-basis:calc(100vw - 32px)}body:has(#page-orders-workspace.active) .crm-board-filters{gap:5px}body:has(#page-orders-workspace.active) .crm-board-filters>label{flex-basis:calc(50% - 5px)}body:has(#page-orders-workspace.active) .crm-board-filters>button{flex:1}body:has(#page-orders-workspace.active) .crm-results{min-height:20px}}
@media(prefers-reduced-motion:reduce){body:has(#page-orders-workspace.active) .crm-column,body:has(#page-orders-workspace.active) .crm-card{transition:none}}
@media(max-width:1450px) and (min-width:1201px){body:has(#page-orders-workspace.active) .sidebar{width:220px}body:has(#page-orders-workspace.active) .main{margin-left:220px}}
#page-orders-workspace.active{padding:0!important;overflow:hidden;min-width:0;max-width:100%}
.manus-orders-host{width:100%;height:100vh;min-height:100vh;background:#f5f7fb;overflow:hidden}
.manus-orders-frame{display:block;width:100%;height:100%;min-height:100vh;border:0;background:#f5f7fb}
.manus-bridge-error{position:fixed;z-index:20;right:16px;bottom:16px;max-width:320px;padding:10px 13px;border:1px solid #efc1c1;border-radius:9px;background:#fff7f6;color:#a74949;box-shadow:0 8px 24px #1d2a3c20;font:12px/1.4 Inter,Arial,sans-serif}
#page-orders-workspace .crm-alert{display:none}
.crm-history>div{grid-template-columns:44px minmax(112px,.8fr) minmax(150px,1.35fr) minmax(90px,.7fr) 72px 92px}
.crm-history>div>.crm-photo{grid-column:1;grid-row:1;object-fit:contain}
.crm-history>div>div:nth-of-type(1){grid-column:2;grid-row:1;min-width:0}
.crm-history>div>div:nth-of-type(2){grid-column:3;grid-row:1;min-width:0}
.crm-history>div>.crm-badge{grid-column:4;grid-row:1}
.crm-history>div>strong{grid-column:5;grid-row:1;white-space:nowrap}
.crm-history>div>[data-crm=order]:last-child{grid-column:6;grid-row:1;min-height:32px}
.crm-client-grid>.crm-detail-grid>div:first-child{min-width:0}
.crm-client-grid aside{min-width:0}
@media(max-width:1200px){.crm-history>div{grid-template-columns:40px minmax(95px,.75fr) minmax(125px,1.25fr) 82px 68px 78px}}
@media(max-width:768px){.crm-history>div{grid-template-columns:40px minmax(85px,.75fr) minmax(125px,1.25fr) 70px 64px}.crm-history>div>[data-crm=order]:last-child{display:none}}
#page-orders-workspace .crm-shell>.crm-alert{display:none}
#page-orders-workspace .crm-shell>.crm-alert[role=alert]{display:block}
.crm-range{min-width:220px;position:relative}
.crm-range input{position:absolute;right:8px;width:20px;height:24px;cursor:pointer}
.crm-range input[data-filter=from]{right:32px}
.crm-range input[data-filter=to]{right:7px}
.crm-range input::-webkit-calendar-picker-indicator{opacity:.65;cursor:pointer}
.crm-client-summary .crm-summary-head>div{min-width:0}
.crm-client-summary .crm-summary-head strong{white-space:normal}
.crm-card .crm-order-link{border:0;background:none;padding:0;color:#edf2ff;font-size:10px;font-weight:700;line-height:1.2;text-align:left;overflow-wrap:anywhere;cursor:pointer;flex:1;min-width:0}
.crm-card .crm-card-top .crm-order-link{min-height:0}
.crm-column>header>div{flex:1;min-width:0}
.crm-column>header strong{overflow-wrap:anywhere}
.crm-history>div{grid-template-columns:44px minmax(112px,.8fr) minmax(150px,1.35fr) minmax(90px,.7fr) 72px 92px}
.crm-history>div>.crm-photo{grid-column:1;grid-row:1;object-fit:contain}
.crm-history>div>div:nth-of-type(1){grid-column:2;grid-row:1;min-width:0}
.crm-history>div>div:nth-of-type(2){grid-column:3;grid-row:1;min-width:0}
.crm-history>div>.crm-badge{grid-column:4;grid-row:1}
.crm-history>div>strong{grid-column:5;grid-row:1;white-space:nowrap}
.crm-history>div>[data-crm=order]:last-child{grid-column:6;grid-row:1;min-height:32px;padding:7px 8px}
.crm-client-grid .crm-history{min-width:0;overflow-x:auto}
.crm-profile-copy>p span{margin-left:5px}
.crm-summary-head>button{padding:5px 9px}
.crm-board{min-height:420px}
.crm-range{min-width:220px;position:relative}
.crm-range input{position:absolute;right:8px;width:20px;height:24px;cursor:pointer}
.crm-range input[data-filter=from]{right:32px}
.crm-range input[data-filter=to]{right:7px}
.crm-range input::-webkit-calendar-picker-indicator{opacity:.65;cursor:pointer}
.crm-client-summary .crm-summary-head>div{min-width:0}
.crm-client-summary .crm-summary-head strong{white-space:normal}
@media(max-width:1200px){.crm-history>div{grid-template-columns:40px minmax(95px,.75fr) minmax(125px,1.25fr) 82px 68px 78px}}
@media(max-width:768px){.crm-history>div{grid-template-columns:40px minmax(85px,.75fr) minmax(125px,1.25fr) 70px 64px}.crm-history>div>[data-crm=order]:last-child{display:none}}
#page-orders-workspace .crm-shell>.crm-alert{display:none!important}
#page-orders-workspace .crm-shell>.crm-alert[role=alert]{display:block!important}
.crm-card .crm-card-top .crm-order-link{flex:1 1 auto;width:auto;max-width:52%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crm-card .crm-card-top time{flex:0 0 auto;max-width:50px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crm-card .crm-card-top a{flex:0 0 22px;text-align:right;white-space:nowrap}
.crm-profile-layout{grid-template-columns:minmax(280px,1.12fr) minmax(270px,.94fr) minmax(220px,.9fr)}
@media(max-width:1200px){.crm-profile-layout{grid-template-columns:minmax(250px,1.1fr) minmax(230px,1fr)}.crm-client-summary{grid-column:1/-1}}
@media(min-width:1201px) and (max-width:1400px){.crm-profile-layout{grid-template-columns:minmax(250px,1.05fr) minmax(240px,.95fr) minmax(205px,.85fr)}.crm-profile{gap:9px;padding:12px}.crm-avatar{width:58px;height:58px;flex-basis:58px}.crm-profile h1{font-size:20px}}
@scope (#page-client-details) {
@media(max-width:768px){.crm-shell:has(.crm-profile) .crm-profile-layout{grid-template-columns:1fr!important}.crm-shell:has(.crm-profile) .crm-client-summary{grid-column:auto!important}.crm-shell:has(.crm-profile) .crm-profile{grid-column:1/-1}.crm-shell:has(.crm-profile) .crm-client-stats{grid-template-columns:repeat(3,minmax(0,1fr))}.crm-shell:has(.crm-profile) .crm-history>div{grid-template-columns:36px minmax(0,1fr) 70px;gap:7px}.crm-shell:has(.crm-profile) .crm-history>div>[data-crm=order]:last-child{display:none}}
.client-repeat-insight{display:flex;align-items:center;gap:12px;margin:0 0 15px;padding:13px 15px;background:#f9fbff;border:1px solid #e8edf5;border-radius:12px}.client-repeat-icon{display:grid;place-items:center;width:34px;height:34px;border-radius:10px;background:#edf2ff;color:#506fca;font-size:18px}.client-repeat-insight div{display:grid;gap:3px}.client-repeat-insight strong{font-size:11px;color:#354259}.client-repeat-insight div span,.client-repeat-insight>small{font-size:9px;color:#8b96a8}.client-repeat-insight>small{margin-left:auto}.client-product-thumb .crm-photo{width:44px;height:52px;object-fit:cover;border-radius:8px;background:#f1f3f7}.client-order-primary{display:grid;gap:3px;min-width:0}.client-order-id{display:flex;align-items:center;gap:9px;color:#4e6387;font-size:10px;font-weight:700}.client-order-date{font-size:9px;font-weight:400;color:#8994a7}.client-order-primary>strong{color:#344155;font-size:10px}.client-order-primary>small,.client-order-agent{color:#8994a7;font-size:9px}.client-order-agent{max-width:90px;overflow-wrap:anywhere}.client-order-row button{background:#f2f5ff!important;color:#526db3!important;border:1px solid #e4eafb!important;padding:6px 8px!important;font-size:9px!important;white-space:nowrap}.client-history-heading{display:flex;justify-content:space-between;padding:14px 0 8px;border-bottom:1px solid #eef0f4;color:#657188;font-size:10px}.client-history-heading span{display:grid;place-items:center;width:20px;height:20px;border-radius:7px;background:#f0f3fa;color:#6d7b92}.client-review-entry{display:grid;gap:5px;padding:10px 0;border-bottom:1px solid #eef0f4}.client-review-entry strong{color:#52617a;font-size:10px}.client-review-entry small{color:#8994a7;font-size:9px}.client-private-note,.client-bottom-note{display:block;margin-top:12px;padding:9px 10px;border-radius:8px;background:#f7f9fc;color:#8994a7;font-size:9px;line-height:1.5}.client-bottom-note{margin:12px 0 0;text-align:center;letter-spacing:.08em}
@media(max-width:900px){.client-layout{grid-template-columns:1fr}.client-assessment{justify-items:start}.client-repeat-insight>small{display:none}}
@media(max-width:600px){.client-content{padding:14px 10px 78px}.client-hero{align-items:flex-start;flex-direction:column;padding:16px}.client-hero-person{align-items:flex-start}.client-hero h1{font-size:21px}.client-avatar-large{width:54px;height:54px;flex-basis:54px;border-radius:17px}.client-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.client-order-row{grid-template-columns:36px minmax(0,1fr) auto;gap:8px}.client-product-thumb .crm-photo{width:34px;height:38px}.client-order-status{grid-column:2;justify-self:start}.client-order-total{grid-column:3;grid-row:2}.client-order-agent{display:none}.client-order-row button{grid-column:3;grid-row:1}.client-card{padding:14px}.client-repeat-insight{padding:10px 12px}}
.client-topbar-user button{padding:6px 9px!important;border:1px solid #dbe4f2!important;border-radius:8px!important;background:#f5f8ff!important;color:#4d69bc!important;font-size:9px!important}

}

body:has(#page-client-details.active) .main>.topbar{display:none!important}

/* Manus Client 360 design, scoped to ValueMart Client Details. */
@scope (#page-client-details) {
/* Sawbly client CRM detail page */
.client-page {
  --client-ink: #172033;
  --client-muted: #8792a5;
  --client-line: #e7ebf2;
  --client-indigo: #4d72e8;
  min-height: 100vh;
  color: var(--client-ink);
  background: #f5f7fb;
  font-family:
    Inter,
    ui-sans-serif,
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
}
.client-topbar {
  height: 66px;
  display: flex;
  align-items: center;
  gap: 25px;
  padding: 0 clamp(18px, 4vw, 54px);
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--client-line);
}
.client-back-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #68758d;
  font-size: 12px;
  font-weight: 680;
  transition: color 0.16s ease;
}
.client-back-link:hover {
  color: #344e9d;
}
.client-topbar-trail {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #a0a9b7;
  font-size: 11px;
}
.client-topbar-trail strong {
  color: #54627a;
  font-weight: 700;
}
.client-slash {
  color: #d2d7df;
}
.client-topbar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
}
.client-user-label {
  color: #9ba5b5;
  font-size: 10px;
}
.client-avatar {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  color: #3e5db2;
  font-weight: 780;
  letter-spacing: -0.03em;
}
.client-avatar-small {
  width: 31px;
  height: 31px;
  border-radius: 10px;
  background: #e7edff;
  font-size: 10px;
}
.client-content {
  width: min(1380px, 100%);
  margin: 0 auto;
  padding: 28px clamp(18px, 4vw, 54px) 44px;
}
.client-breadcrumb {
  display: flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: #9ba5b5;
  font-size: 10px;
}
.client-breadcrumb span:nth-child(2) {
  color: #cbd1dc;
}
.client-breadcrumb strong {
  color: #58657b;
  font-weight: 680;
}
.client-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
  padding: 25px 28px;
  border: 1px solid #e6eaf2;
  border-radius: 17px;
  background: linear-gradient(112deg, #fff 0%, #fff 70%, #f8faff 100%);
  box-shadow: 0 8px 26px rgba(34, 54, 95, 0.035);
}
.client-hero-person {
  display: flex;
  align-items: center;
  gap: 19px;
  min-width: 0;
}
.client-avatar-large {
  width: 74px;
  height: 74px;
  border: 4px solid rgba(255, 255, 255, 0.9);
  border-radius: 23px;
  box-shadow: 0 4px 13px rgba(50, 70, 110, 0.1);
  color: #3e5db2;
  font-size: 22px;
}
.client-hero-copy {
  min-width: 0;
}
.client-kicker {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #9ba5b6;
  font-size: 9px;
  font-weight: 770;
  letter-spacing: 0.11em;
}
.client-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #35b47e;
  box-shadow: 0 0 0 3px #e5f8ee;
}
.client-id-chip {
  padding: 5px 8px;
  border: 1px solid #e7ebf4;
  border-radius: 6px;
  background: #fbfcfe;
  color: #7f8aa0;
  font-size: 9px;
  letter-spacing: 0.02em;
}
.client-hero h1 {
  margin: 8px 0 7px;
  color: #172033;
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 760;
  letter-spacing: -1.25px;
  line-height: 1.08;
}
.client-hero-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #7e899d;
  font-size: 11px;
}
.client-hero-meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.client-hero-meta svg {
  color: #9aa6ba;
}
.client-meta-divider {
  width: 1px;
  height: 13px;
  background: #e2e6ee;
}
.client-hero-assessment {
  min-width: 212px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  padding: 4px 0 4px 22px;
  border-left: 1px solid #edf0f5;
}
.client-section-label {
  color: #9ba5b5;
  font-size: 9px;
  font-weight: 730;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}
.client-hero-assessment small {
  color: #9ca6b5;
  font-size: 9px;
  text-align: right;
}
.client-assessment-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  width: fit-content;
  padding: 7px 10px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 740;
  white-space: nowrap;
}
.client-assessment-indicator {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.assessment-reliable {
  color: #20835d;
  background: #eaf8f1;
  border-color: #d8f0e3;
}
.assessment-watch {
  color: #a9751e;
  background: #fff6e5;
  border-color: #f5e9ca;
}
.assessment-incident {
  color: #b55555;
  background: #fff0ef;
  border-color: #f6ddda;
}
.assessment-unrated {
  color: #78859a;
  background: #f1f4f8;
  border-color: #e7ebf1;
}
.client-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}
.client-metric-card {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  min-height: 91px;
  padding: 16px;
  border: 1px solid var(--client-line);
  border-radius: 13px;
  background: #fff;
  box-shadow: 0 3px 10px rgba(35, 55, 92, 0.02);
}
.client-metric-icon {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 11px;
}
.metric-indigo {
  color: #5576e4;
  background: #eef2ff;
}
.metric-green {
  color: #2aab79;
  background: #e9f8f0;
}
.metric-amber {
  color: #cb963b;
  background: #fff6e3;
}
.metric-purple {
  color: #8970ce;
  background: #f1edff;
}
.client-metric-card > div {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 4px;
}
.client-metric-card > div > span {
  color: #8b96a8;
  font-size: 10px;
  font-weight: 630;
}
.client-metric-card strong {
  overflow: hidden;
  color: #26334b;
  font-size: 20px;
  font-weight: 760;
  letter-spacing: -0.6px;
  line-height: 1.05;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.client-spend-card strong {
  font-size: 17px;
}
.client-metric-card small {
  overflow: hidden;
  color: #a0a9b7;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.client-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(310px, 0.88fr);
  gap: 17px;
  align-items: start;
}
.client-main-column,
.client-side-column {
  display: flex;
  flex-direction: column;
  gap: 17px;
  min-width: 0;
}
.client-card {
  min-width: 0;
  padding: 21px;
  border: 1px solid var(--client-line);
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 14px rgba(35, 55, 92, 0.025);
}
.client-card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.client-eyebrow {
  display: block;
  margin-bottom: 5px;
  color: #9aa4b3;
  font-size: 9px;
  font-weight: 770;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.client-card-heading h2 {
  margin: 0;
  color: #27344c;
  font-size: 15px;
  font-weight: 750;
  letter-spacing: -0.25px;
}
.client-heading-icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  color: #6b80c0;
  background: #f0f3fb;
}
.client-info-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 26px;
  row-gap: 20px;
}
.client-info-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}
.client-info-item > span {
  color: #98a2b2;
  font-size: 9px;
  font-weight: 650;
}
.client-info-item > strong,
.client-info-item > a {
  display: flex;
  align-items: center;
  gap: 5px;
  overflow-wrap: anywhere;
  color: #354158;
  font-size: 11px;
  font-weight: 680;
}
.client-info-item > a {
  width: fit-content;
  color: #4568c4;
  transition: color 0.15s ease;
}
.client-info-item > a:hover {
  color: #2649aa;
  text-decoration: underline;
}
.client-info-item svg {
  flex: 0 0 auto;
  color: #8d9ab1;
}
.client-address-item {
  grid-column: 1 / -1;
  padding-top: 15px;
  border-top: 1px solid #eff1f5;
}
.client-orders-card {
  padding-bottom: 10px;
}
.client-count-badge {
  display: inline-grid;
  place-items: center;
  min-width: 20px;
  height: 19px;
  margin-left: 5px;
  padding: 0 5px;
  border-radius: 6px;
  color: #5270ce;
  background: #edf1ff;
  font-size: 9px;
  vertical-align: 2px;
}
.client-order-list {
  display: flex;
  flex-direction: column;
}
.client-order-row {
  display: grid;
  grid-template-columns:
    35px minmax(130px, 1fr) auto minmax(72px, 0.42fr)
    auto 14px;
  align-items: center;
  gap: 12px;
  min-width: 0;
  padding: 13px 5px;
  border-top: 1px solid #f0f2f6;
  transition:
    background 0.16s ease,
    transform 0.16s ease;
}
.client-order-row:hover {
  background: #fafbff;
  transform: translateX(2px);
}
.client-order-row:focus-visible,
.client-back-link:focus-visible,
.client-button:focus-visible,
.client-comment-actions button:focus-visible,
.client-text-button:focus-visible {
  outline: 3px solid rgba(77, 114, 232, 0.25);
  outline-offset: 2px;
}
.client-order-icon {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
}
.order-green {
  color: #29a876;
  background: #e8f7ef;
}
.order-blue {
  color: #5375dd;
  background: #edf1ff;
}
.order-amber {
  color: #bf8a2d;
  background: #fff5df;
}
.order-red {
  color: #cf6665;
  background: #fff0ee;
}
.order-purple {
  color: #866acb;
  background: #f1edff;
}
.client-order-primary {
  display: flex;
  flex-direction: column;
  min-width: 0;
  gap: 3px;
}
.client-order-id {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #63718a;
  font-size: 9px;
  font-weight: 760;
}
.client-order-date {
  color: #a2abba;
  font-size: 9px;
  font-weight: 500;
}
.client-order-primary strong {
  overflow: hidden;
  color: #354158;
  font-size: 10px;
  font-weight: 690;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.client-order-primary small {
  overflow: hidden;
  color: #9aa4b3;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.client-order-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  width: fit-content;
  padding: 5px 7px;
  border-radius: 6px;
  font-size: 8px;
  font-weight: 730;
  white-space: nowrap;
}
.status-green {
  color: #27865f;
  background: #eaf7f0;
}
.status-blue {
  color: #5071d0;
  background: #eef2ff;
}
.status-amber {
  color: #a97726;
  background: #fff6e4;
}
.status-red {
  color: #b85b5b;
  background: #fff0ef;
}
.status-purple {
  color: #7c65b6;
  background: #f1edff;
}
.client-order-agent {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow: hidden;
  color: #78859a;
  font-size: 9px;
  white-space: nowrap;
}
.client-mini-avatar {
  display: inline-grid;
  flex: 0 0 auto;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 7px;
  color: #5571c6;
  background: #edf1ff;
  font-size: 7px;
  font-weight: 800;
}
.client-order-total {
  color: #354158;
  font-size: 10px;
  font-weight: 740;
  white-space: nowrap;
}
.client-order-arrow {
  color: #b4bdca;
  transition:
    color 0.15s ease,
    transform 0.15s ease;
}
.client-order-row:hover .client-order-arrow {
  color: #5576dc;
  transform: translate(1px, -1px);
}
.client-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 35px 15px 40px;
  color: #a1aaba;
  text-align: center;
}
.client-empty-state svg {
  color: #8ca1dc;
}
.client-empty-state strong {
  color: #526078;
  font-size: 11px;
}
.client-empty-state span {
  font-size: 10px;
}
.client-card-description {
  margin: -8px 0 16px;
  color: #909bad;
  font-size: 10px;
  line-height: 1.55;
}
.client-review-form,
.client-comment-form {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 8px;
}
.client-review-form label,
.client-comment-form > label {
  margin-top: 2px;
  color: #647188;
  font-size: 9px;
  font-weight: 690;
}
.client-review-form label span {
  color: #a7afbd;
  font-weight: 500;
}
.client-review-form select,
.client-review-form textarea,
.client-comment-form textarea,
.client-edit-comment textarea {
  width: 100%;
  border: 1px solid #e3e8f0;
  border-radius: 8px;
  outline: none;
  color: #39465e;
  background: #fbfcfe;
  font: inherit;
  font-size: 10px;
  transition:
    border-color 0.16s ease,
    box-shadow 0.16s ease,
    background 0.16s ease;
}
.client-review-form select {
  height: 36px;
  padding: 0 10px;
}
.client-review-form textarea,
.client-comment-form textarea,
.client-edit-comment textarea {
  min-height: 72px;
  padding: 10px;
  resize: vertical;
  line-height: 1.5;
}
.client-review-form textarea::placeholder,
.client-comment-form textarea::placeholder {
  color: #a9b2c0;
}
.client-review-form select:focus,
.client-review-form textarea:focus,
.client-comment-form textarea:focus,
.client-edit-comment textarea:focus {
  border-color: #9fb2f3;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(77, 114, 232, 0.09);
}
.client-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 35px;
  padding: 0 12px;
  border: 0;
  border-radius: 8px;
  font: inherit;
  font-size: 10px;
  font-weight: 710;
  transition:
    background 0.16s ease,
    transform 0.16s ease,
    box-shadow 0.16s ease;
}
.client-button-primary {
  color: #fff;
  background: #304b91;
  box-shadow: 0 4px 10px rgba(48, 75, 145, 0.14);
}
.client-button-primary:hover:not(:disabled) {
  background: #263f80;
  transform: translateY(-1px);
}
.client-button:disabled {
  cursor: not-allowed;
  opacity: 0.5;
}
.client-history-heading {
  display: flex;
  justify-content: space-between;
  margin: 20px 0 8px;
  padding-top: 14px;
  border-top: 1px solid #eff1f5;
  color: #647188;
  font-size: 9px;
  font-weight: 720;
}
.client-history-heading span:last-child {
  color: #8b96a9;
}
.client-review-history {
  display: flex;
  flex-direction: column;
}
.client-review-entry {
  padding: 11px 0;
  border-top: 1px solid #f0f2f5;
}
.client-review-entry:first-child {
  border-top: 0;
}
.client-review-entry-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 7px;
}
.client-review-entry .client-assessment-pill {
  padding: 5px 7px;
  font-size: 8px;
}
.client-review-entry .client-assessment-indicator {
  width: 5px;
  height: 5px;
}
.client-review-entry time {
  color: #a2abba;
  font-size: 8px;
  text-align: right;
}
.client-review-author {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 8px;
  color: #738097;
  font-size: 9px;
}
.client-review-entry p {
  margin: 8px 0 0 26px;
  color: #7f8ba0;
  font-size: 9px;
  line-height: 1.55;
}
.client-inline-empty {
  padding: 14px 4px;
  color: #9ca6b5;
  font-size: 9px;
  line-height: 1.5;
}
.client-private-note {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin: 14px -2px 0;
  padding: 10px;
  border: 1px solid #e7eefb;
  border-radius: 8px;
  color: #7f8eb0;
  background: #f6f8fe;
  font-size: 8px;
  line-height: 1.5;
}
.client-private-note svg {
  flex: 0 0 auto;
  margin-top: 1px;
  color: #728bd0;
}
.client-private-note strong {
  color: #5b6eaa;
}
.client-comment-form {
  margin-bottom: 15px;
}
.client-comments-list {
  display: flex;
  flex-direction: column;
}
.client-comment-entry {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 13px 0;
  border-top: 1px solid #eff1f5;
}
.client-comment-avatar {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 27px;
  height: 27px;
  border-radius: 9px;
  color: #536fc3;
  background: #eaf0ff;
  font-size: 8px;
  font-weight: 800;
}
.client-comment-body {
  flex: 1;
  min-width: 0;
}
.client-comment-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 7px;
}
.client-comment-meta strong {
  color: #49566d;
  font-size: 9px;
  font-weight: 730;
}
.client-comment-meta time {
  color: #a1aab8;
  font-size: 8px;
  text-align: right;
}
.client-comment-body > p {
  margin: 7px 0 0;
  color: #748198;
  font-size: 9px;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.client-comment-actions {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}
.client-comment-actions button,
.client-text-button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 0;
  color: #8b96a8;
  background: transparent;
  font: inherit;
  font-size: 8px;
  font-weight: 650;
  transition: color 0.15s ease;
}
.client-comment-actions button:hover {
  color: #4768bd;
}
.client-comment-actions button:last-child:hover {
  color: #c15f5f;
}
.client-edit-comment {
  margin-top: 9px;
}
.client-edit-comment textarea {
  min-height: 64px;
}
.client-edit-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 6px;
}
.client-text-save {
  color: #4567bf;
}
.client-bottom-note {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 17px;
  padding: 12px 14px;
  border: 1px solid #e5eaf3;
  border-radius: 10px;
  color: #8793a7;
  background: rgba(255, 255, 255, 0.68);
  font-size: 9px;
  line-height: 1.5;
}
.client-bottom-note svg {
  flex: 0 0 auto;
  color: #7188cb;
}
.client-feedback {
  position: fixed;
  right: 18px;
  bottom: 17px;
  z-index: 5;
  max-width: min(420px, calc(100vw - 36px));
  padding: 0;
  color: #327d5d;
  background: #eaf8f0;
  border-radius: 9px;
  font-size: 10px;
  box-shadow: 0 6px 22px rgba(36, 71, 60, 0.08);
}
.client-feedback:not(:empty) {
  padding: 11px 14px;
  border: 1px solid #d8efe2;
}
.client-not-found {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
}
.client-empty-icon {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin-bottom: 18px;
  border-radius: 17px;
  color: #657fc7;
  background: #eaf0ff;
}
.client-not-found .client-eyebrow {
  margin-bottom: 7px;
}
.client-not-found h1 {
  margin: 0;
  font-size: 27px;
  letter-spacing: -0.8px;
}
.client-not-found p {
  max-width: 360px;
  margin: 9px 0 19px;
  color: #8a95a7;
  font-size: 12px;
  line-height: 1.5;
}
.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;
}

@media (max-width: 1060px) {
  .client-layout {
    grid-template-columns: minmax(0, 1.25fr) minmax(290px, 0.9fr);
    gap: 13px;
  }
  .client-order-row {
    grid-template-columns: 32px minmax(100px, 1fr) auto auto 14px;
    gap: 8px;
  }
  .client-order-agent {
    display: none;
  }
  .client-metric-card {
    gap: 9px;
    padding: 13px 12px;
  }
  .client-metric-icon {
    width: 32px;
    height: 32px;
  }
}
@media (max-width: 800px) {
  .client-content {
    padding-top: 21px;
  }
  .client-hero {
    align-items: flex-start;
    padding: 21px;
  }
  .client-hero-assessment {
    min-width: 175px;
  }
  .client-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .client-layout {
    grid-template-columns: 1fr;
  }
  .client-side-column {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
  .client-card {
    padding: 18px;
  }
}
@media (max-width: 580px) {
  .client-topbar {
    height: 58px;
    gap: 12px;
    padding: 0 16px;
  }
  .client-topbar-trail {
    gap: 6px;
    font-size: 9px;
  }
  .client-user-label {
    display: none;
  }
  .client-content {
    padding: 18px 14px 32px;
  }
  .client-breadcrumb {
    margin-bottom: 13px;
    font-size: 9px;
  }
  .client-hero {
    flex-direction: column;
    gap: 18px;
    margin-bottom: 13px;
    padding: 17px;
    border-radius: 14px;
  }
  .client-hero-person {
    gap: 13px;
  }
  .client-avatar-large {
    width: 58px;
    height: 58px;
    border-width: 3px;
    border-radius: 18px;
    font-size: 18px;
  }
  .client-kicker {
    gap: 6px;
    font-size: 8px;
  }
  .client-id-chip {
    padding: 4px 6px;
    font-size: 8px;
  }
  .client-hero h1 {
    margin: 7px 0;
    font-size: 24px;
    letter-spacing: -0.85px;
  }
  .client-hero-meta {
    align-items: flex-start;
    flex-direction: column;
    gap: 5px;
    font-size: 10px;
  }
  .client-meta-divider {
    display: none !important;
  }
  .client-hero-assessment {
    align-items: flex-start;
    width: 100%;
    min-width: 0;
    padding: 12px 0 0;
    border-top: 1px solid #edf0f5;
    border-left: 0;
  }
  .client-hero-assessment small {
    text-align: left;
  }
  .client-metrics {
    gap: 8px;
    margin-bottom: 13px;
  }
  .client-metric-card {
    min-height: 79px;
    gap: 8px;
    padding: 11px 9px;
    border-radius: 11px;
  }
  .client-metric-icon {
    width: 29px;
    height: 29px;
    border-radius: 9px;
  }
  .client-metric-icon svg {
    width: 15px;
    height: 15px;
  }
  .client-metric-card > div > span {
    font-size: 9px;
  }
  .client-metric-card strong {
    font-size: 17px;
  }
  .client-spend-card strong {
    font-size: 14px;
  }
  .client-metric-card small {
    font-size: 8px;
  }
  .client-main-column,
  .client-side-column {
    gap: 12px;
  }
  .client-side-column {
    display: flex;
  }
  .client-card {
    padding: 16px 14px;
    border-radius: 12px;
  }
  .client-card-heading {
    margin-bottom: 15px;
  }
  .client-info-grid {
    column-gap: 12px;
    row-gap: 16px;
  }
  .client-info-item > strong,
  .client-info-item > a {
    font-size: 10px;
  }
  .client-order-row {
    grid-template-columns: 30px minmax(0, 1fr) auto;
    gap: 8px;
    padding: 12px 1px;
  }
  .client-order-icon {
    width: 29px;
    height: 29px;
  }
  .client-order-status {
    grid-column: 2;
    grid-row: 2;
    margin-top: -2px;
  }
  .client-order-primary {
    grid-column: 2;
    grid-row: 1;
  }
  .client-order-primary strong {
    font-size: 9px;
  }
  .client-order-total {
    grid-column: 3;
    grid-row: 1 / span 2;
    align-self: center;
    font-size: 9px;
  }
  .client-order-arrow {
    display: none;
  }
  .client-order-date {
    font-size: 8px;
  }
  .client-order-status {
    font-size: 7px;
  }
  .client-order-status svg {
    width: 10px;
    height: 10px;
  }
  .client-order-agent {
    display: none;
  }
  .client-bottom-note {
    align-items: flex-start;
    margin-top: 12px;
    padding: 10px;
    font-size: 8px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .client-page *,
  .client-page *::before,
  .client-page *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* Client 360° profile extensions */
.client-breadcrumb a {
  color: #8b96a8;
}
.client-breadcrumb a:hover {
  color: #4568c4;
}
.client-hero {
  align-items: center;
}
.client-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 13px;
}
.client-button-soft {
  color: #425b9e;
  background: #eef2ff;
}
.client-button-soft:hover {
  background: #e3eaff;
}
.client-button-whatsapp {
  color: #21865d;
  background: #eaf8f0;
}
.client-button-whatsapp:hover {
  background: #dff4e8;
}
.client-segment-strip {
  display: flex;
  align-items: center;
  gap: 11px;
  min-height: 42px;
  margin: -7px 0 13px;
  padding: 7px 12px;
  border: 1px solid #e7ebf2;
  border-radius: 10px;
  background: #fff;
}
.client-segment-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
  padding: 6px 9px;
  border: 1px solid transparent;
  border-radius: 7px;
  font-size: 9px;
  font-weight: 760;
}
.segment-vip {
  color: #8b671d;
  background: #fff6df;
  border-color: #f4e8c2;
}
.segment-regular,
.segment-loyal {
  color: #267d5b;
  background: #eaf8f0;
  border-color: #d9f0e3;
}
.segment-new {
  color: #4c68bc;
  background: #eef2ff;
  border-color: #e0e7ff;
}
.segment-occasional {
  color: #718096;
  background: #f2f4f7;
  border-color: #e8ebf0;
}
.client-segment-explainer {
  color: #8e99aa;
  font-size: 9px;
}
.client-objective-label {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-left: auto;
  color: #79869c;
  font-size: 8px;
  white-space: nowrap;
}
.client-objective-label svg {
  color: #5d7ac9;
}
.client-repeat-insight {
  display: flex;
  align-items: center;
  gap: 11px;
  margin: -7px 0 19px;
  padding: 11px 14px;
  border: 1px solid #e5ebf6;
  border-radius: 11px;
  background: linear-gradient(100deg, #f8faff, #fff);
}
.client-repeat-icon {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  color: #647dc5;
  background: #edf1ff;
}
.client-repeat-insight > div {
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.client-repeat-insight strong {
  color: #4b5870;
  font-size: 10px;
}
.client-repeat-insight > div span {
  color: #78859a;
  font-size: 9px;
}
.client-repeat-insight > small {
  margin-left: auto;
  color: #a0a9b7;
  font-size: 8px;
}
.client-info-item > span small {
  font-size: inherit;
  font-weight: 500;
}
.client-address-item {
  padding-top: 15px;
}
.client-address-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
  margin: 2px 0 0;
  padding: 0;
  list-style: none;
}
.client-address-list li {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  color: #47546b;
  font-size: 10px;
  line-height: 1.5;
}
.client-address-list li svg {
  flex: 0 0 auto;
  margin-top: 1px;
  color: #8d9ab1;
}
.client-address-list li em {
  flex: 0 0 auto;
  padding: 2px 5px;
  border-radius: 5px;
  color: #6f81b8;
  background: #f0f3fb;
  font-size: 7px;
  font-style: normal;
}
.client-product-thumb {
  display: block;
  width: 46px;
  height: 46px;
  overflow: hidden;
  border: 1px solid #edf0f4;
  border-radius: 10px;
  background: #f6f7fa;
}
.client-product-thumb img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.client-order-row {
  grid-template-columns:
    46px minmax(130px, 1fr) auto minmax(72px, 0.42fr)
    auto auto;
}
.client-order-details-link {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  color: #6c7fb9;
  font-size: 8px;
  font-weight: 680;
  white-space: nowrap;
}
.client-order-row:hover .client-order-details-link {
  color: #3e5fac;
}
.client-review-form select,
.client-comment-form select {
  height: 35px;
  padding: 0 9px;
  border: 1px solid #e3e8f0;
  border-radius: 8px;
  outline: none;
  color: #39465e;
  background: #fbfcfe;
  font: inherit;
  font-size: 9px;
}
.client-review-form select:focus,
.client-comment-form select:focus {
  border-color: #9fb2f3;
  box-shadow: 0 0 0 3px rgba(77, 114, 232, 0.09);
}
.client-select-label {
  margin: 2px 0 -3px;
  color: #647188;
  font-size: 9px;
  font-weight: 690;
}
.client-select-label span {
  color: #a7afbd;
  font-weight: 500;
}
.client-important-toggle {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #6e7890;
  font-size: 9px;
}
.client-important-toggle input {
  width: 14px;
  height: 14px;
  accent-color: #506dc3;
}
.client-related-link {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  margin: 7px 0 0 26px;
  color: #6d80bb;
  font-size: 8px;
  font-weight: 670;
}
.client-comment-body .client-related-link {
  margin-left: 0;
}
.client-related-link:hover {
  color: #405da8;
  text-decoration: underline;
}
.client-important-tag {
  display: inline-flex;
  margin-left: 6px;
  padding: 2px 5px;
  border-radius: 5px;
  color: #a27122;
  background: #fff5df;
  font-size: 7px;
  font-weight: 720;
  vertical-align: 1px;
}
.comment-important {
  margin: 5px -8px;
  padding: 11px 8px;
  border: 1px solid #f4ebd5;
  border-radius: 8px;
  background: #fffdf8;
}
.client-activity-list {
  display: flex;
  flex-direction: column;
}
.client-activity-item {
  position: relative;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr);
  gap: 10px;
  padding: 1px 0 16px;
}
.client-activity-item:not(:last-child)::before {
  position: absolute;
  top: 25px;
  bottom: 0;
  left: 12px;
  width: 1px;
  background: #e9edf3;
  content: "";
}
.client-activity-marker {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border: 1px solid #e8edf5;
  border-radius: 8px;
  color: #7185c2;
  background: #f3f5fb;
}
.activity-delivery .client-activity-marker {
  color: #2a9b70;
  background: #ecf8f1;
  border-color: #dff1e7;
}
.activity-cancel .client-activity-marker {
  color: #c06464;
  background: #fff1ef;
  border-color: #f6e2df;
}
.activity-callback .client-activity-marker {
  color: #b98936;
  background: #fff7e8;
  border-color: #f4ead2;
}
.activity-important .client-activity-marker {
  color: #a87625;
  background: #fff6e2;
  border-color: #f3e7c8;
}
.client-activity-content {
  min-width: 0;
  padding: 3px 0 0;
}
.client-activity-title {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 9px;
}
.client-activity-title strong {
  color: #48556d;
  font-size: 9px;
  font-weight: 720;
}
.client-activity-title time {
  flex: 0 0 auto;
  color: #a0a9b7;
  font-size: 8px;
  text-align: right;
}
.client-activity-content > p {
  margin: 5px 0 0;
  color: #78859a;
  font-size: 9px;
  line-height: 1.5;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.client-activity-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 6px;
  color: #9aa4b3;
  font-size: 8px;
}
.client-activity-meta a {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  color: #6d80bb;
}
.client-activity-meta a:hover {
  color: #405da8;
}
.client-activity-item:last-child {
  padding-bottom: 0;
}

@media (max-width: 1060px) {
  .client-order-row {
    grid-template-columns: 40px minmax(100px, 1fr) auto auto auto;
  }
  .client-order-details-link {
    display: none;
  }
}
@media (max-width: 800px) {
  .client-hero {
    align-items: center;
  }
  .client-segment-strip {
    flex-wrap: wrap;
  }
  .client-objective-label {
    margin-left: 0;
  }
}
@media (max-width: 580px) {
  .client-hero-actions {
    gap: 6px;
    margin-top: 10px;
  }
  .client-hero-actions .client-button {
    min-height: 32px;
    padding: 0 9px;
    font-size: 9px;
  }
  .client-segment-strip {
    gap: 7px;
    margin-top: 0;
    padding: 8px;
  }
  .client-segment-explainer {
    flex-basis: 100%;
    line-height: 1.4;
  }
  .client-objective-label {
    font-size: 7px;
  }
  .client-repeat-insight {
    flex-wrap: wrap;
    margin-bottom: 13px;
    padding: 10px;
  }
  .client-repeat-insight > small {
    flex-basis: 100%;
    margin-left: 43px;
  }
  .client-address-list li {
    font-size: 9px;
  }
  .client-order-row {
    grid-template-columns: 34px minmax(0, 1fr) auto;
  }
  .client-product-thumb {
    width: 34px;
    height: 34px;
    border-radius: 8px;
  }
  .client-order-details-link {
    display: inline-flex;
    grid-column: 3;
    grid-row: 2;
    justify-self: end;
    font-size: 7px;
  }
  .client-order-total {
    grid-column: 3;
    grid-row: 1;
    align-self: start;
  }
  .client-order-status {
    grid-column: 2;
    grid-row: 2;
  }
  .client-order-primary {
    grid-column: 2;
    grid-row: 1;
  }
  .client-order-row {
    row-gap: 7px;
  }
  .client-activity-title {
    flex-direction: column;
    gap: 3px;
  }
  .client-activity-title time {
    text-align: left;
  }
}

.activity-return .client-activity-marker {
  color: #866acb;
  background: #f3efff;
  border-color: #e8e0fb;
}

}

/* ValueMart-only integration guard and native control alignment. */
#page-client-details .crm-shell:has(.client-page){padding:0!important;background:#f5f7fb!important;color:#172033!important;min-height:100vh}
#page-client-details .crm-shell:has(.client-page)>.crm-local{display:none!important}
#page-client-details .crm-shell:has(.client-page)>.crm-alert{margin:12px auto 0;max-width:1510px}
#page-client-details .client-data-unavailable{max-width:1510px;margin:12px auto 0;padding:12px 16px;display:flex;flex-direction:column;gap:4px;background:#fff4e5;border:1px solid #f3d5a4;border-radius:12px;color:#7a4b0c;font-size:12px}
#page-client-details .client-order-row{width:100%;font-family:inherit;text-align:left;color:inherit;background:transparent!important;border:0!important;border-bottom:1px solid #edf0f5!important;border-radius:0!important;box-shadow:none!important;cursor:pointer}
#page-client-details .client-order-row:hover{background:#f8faff!important}
#page-client-details .client-order-row .crm-photo{width:54px;height:54px;object-fit:cover;border-radius:12px}
#page-client-details .client-order-row .crm-btn{white-space:nowrap}
#page-client-details .client-unavailable-inline{padding:10px 12px;background:#fff4e5;border-radius:9px;color:#7a4b0c;font-size:11px}
#page-client-details .client-address-unavailable{color:#8792a5;font-style:italic}
#page-client-details .client-history-heading{display:flex;align-items:center;justify-content:space-between}
#page-client-details .client-review-entry,#page-client-details .client-comment-entry{min-width:0}
#page-client-details .client-comment-actions{display:flex;gap:6px;margin-top:8px}
#page-client-details .client-comment-actions button{border:0;background:transparent;color:#637493;font:inherit;font-size:11px;cursor:pointer}
#page-client-details .client-review-form button,.client-comment-form button{font:inherit;cursor:pointer}
#page-client-details .client-review-form button:disabled,.client-comment-form button:disabled{opacity:.55;cursor:not-allowed}
#page-client-details .client-product-thumb .crm-photo{width:100%;height:100%;object-fit:cover;border-radius:inherit}


#page-client-details .client-activity-content>.crm-btn{display:inline-flex;align-items:center;justify-content:center;margin-top:5px;padding:7px 11px!important;border:1px solid #e4eafb!important;border-radius:8px!important;background:#eef2ff!important;color:#425b9e!important;font-size:10px!important;font-weight:650}
#page-client-details .client-activity-content>.crm-btn:hover{background:#e3eaff!important}
#page-client-details .client-comment-actions .crm-btn{padding:4px 7px!important;border:1px solid #e7ebf2!important;border-radius:7px!important;background:#f8faff!important;color:#637493!important;font-size:9px!important}
#page-client-details .client-comment-actions .crm-btn:hover{background:#eef2ff!important}

/* Client 360 reference details: isolated to the existing client page. */
#page-client-details .client-page{background:#f3f6fb;color:#182b4a}
#page-client-details .client-content{max-width:1660px;padding:26px 30px 48px}
#page-client-details .client-hero{padding:32px 36px;border-radius:20px;border-color:#dfe7f3;background:linear-gradient(110deg,#fff 60%,#f8faff)}
#page-client-details .client-avatar-large{width:88px;height:88px;flex-basis:88px;border:4px solid #fff;border-radius:25px;box-shadow:0 6px 18px #23375d16;background:#dfe9ff;font-size:27px}
#page-client-details .client-hero h1{font-size:40px;line-height:1.1;font-weight:750;letter-spacing:-.04em;color:#12223d;margin:8px 0}
#page-client-details .client-hero-meta span,#page-client-details .client-hero-actions a{display:inline-flex;align-items:center;gap:7px}
#page-client-details .client-hero-meta svg,#page-client-details .client-hero-actions svg{width:16px;height:16px;flex:none}
#page-client-details .client-hero-actions a{min-height:42px;padding:0 15px;border:0;border-radius:10px;font-size:12px;font-weight:700}
#page-client-details .client-hero-actions .client-button-soft{background:#edf2ff;color:#3b5db1}
#page-client-details .client-hero-actions .client-button-whatsapp{background:#e8f8ef;color:#16804f}
#page-client-details .client-hero-assessment{border-left:1px solid #e4eaf3;padding-left:35px;min-width:200px}
#page-client-details .client-segment-strip,#page-client-details .client-repeat-insight{border:1px solid #dfe7f3;border-radius:12px;background:#fff}
#page-client-details .client-metrics{gap:14px;margin:16px 0}
#page-client-details .client-metric-card{display:flex;align-items:center;gap:14px;padding:20px;border:1px solid #dfe7f3;border-radius:15px;background:#fff;min-height:110px}
#page-client-details .client-metric-icon,#page-client-details .client-heading-icon,#page-client-details .client-repeat-icon{display:grid;place-items:center;flex:none;width:44px;height:44px;border-radius:13px}
#page-client-details .client-metric-icon svg,#page-client-details .client-heading-icon svg,#page-client-details .client-repeat-icon svg{width:21px;height:21px}
#page-client-details .client-metric-card>div{display:grid;gap:4px;min-width:0}
#page-client-details .client-metric-card>div>span{font-size:12px;color:#8798b1;font-weight:600}
#page-client-details .client-metric-card strong{font-size:23px;line-height:1.1;color:#172b4d}
#page-client-details .client-metric-card small{font-size:10px;color:#98a9c0}
#page-client-details .client-layout{grid-template-columns:minmax(0,1.75fr) minmax(320px,1fr);gap:18px}
#page-client-details .client-card{padding:25px;border:1px solid #dfe7f3;border-radius:17px;box-shadow:0 5px 24px #263e6b08;margin-bottom:18px}
#page-client-details .client-card-heading h2{font-size:19px;color:#152a4a;letter-spacing:-.025em}
#page-client-details .client-heading-icon{background:#eef3fc;color:#708bc5}
#page-client-details .client-review-form button,#page-client-details .client-comment-form button{width:100%;justify-content:center;background:#304e95!important;color:#fff!important;min-height:43px;border-radius:10px!important;font-size:11px!important;font-weight:700}
#page-client-details .client-review-form select,#page-client-details .client-review-form textarea,#page-client-details .client-comment-form textarea{background:#f9fafc;border:1px solid #dce5f1;border-radius:10px;padding:12px;color:#263e62}
#page-client-details .client-comments-list{margin-top:20px;border-top:1px solid #edf1f6;padding-top:8px}
#page-client-details .client-order-row{min-height:78px;gap:14px}
#page-client-details .client-order-row .crm-btn{background:transparent!important;border:0!important;color:#4a67b3!important}
#page-client-details .client-private-note{background:#f2f6fd;border:1px solid #e1eafa;color:#8196bb}
@media(max-width:750px){#page-client-details .client-content{padding:16px 12px 70px}#page-client-details .client-hero{padding:20px;gap:18px}#page-client-details .client-hero h1{font-size:27px}#page-client-details .client-avatar-large{width:60px;height:60px;flex-basis:60px;font-size:20px}#page-client-details .client-hero-assessment{border-left:0;padding-left:0;min-width:0}#page-client-details .client-layout{grid-template-columns:1fr}#page-client-details .client-metric-card{padding:12px;min-height:96px;gap:9px}#page-client-details .client-metric-icon{width:36px;height:36px}#page-client-details .client-card{padding:16px}}

/* Client review controls and activity links. */
#page-client-details .client-review-form .vm-select-trigger{display:flex!important;align-items:center!important;justify-content:space-between!important;width:100%!important;min-height:44px!important;padding:0 14px!important;border:1px solid #dce5f1!important;border-radius:10px!important;background:#f9fafc!important;color:#263e62!important;text-align:left!important;box-shadow:none!important;font-size:11px!important;font-weight:400!important}
#page-client-details .client-review-form .vm-select-trigger:disabled{opacity:.7!important;color:#65758e!important;cursor:not-allowed}
#page-client-details .client-review-form .vm-select-chevron{border-color:#405577!important}
#page-client-details .client-review-form .vm-select-menu{background:#fff!important;color:#263e62!important;border:1px solid #dce5f1!important}
#page-client-details .client-review-form .vm-select-menu button{width:100%!important;min-height:34px!important;justify-content:flex-start!important;background:#fff!important;color:#263e62!important;box-shadow:none!important;text-align:left!important}
#page-client-details .client-review-form .vm-select-menu button:hover,#page-client-details .client-review-form .vm-select-menu button[aria-selected=true]{background:#edf2ff!important}
#page-client-details .client-activity-marker svg{width:17px;height:17px;display:block}
#page-client-details .activity-confirmed .client-activity-marker{background:#e6f7ee;color:#19a86a;border-color:#d5f0e2}
#page-client-details .activity-cancelled .client-activity-marker{background:#fff0ef;color:#dd6670;border-color:#f9dedd}
#page-client-details .activity-returned .client-activity-marker{background:#f2edff;color:#9675dc;border-color:#e8ddff}
#page-client-details .client-activity-content>.crm-btn{display:inline-block!important;width:auto!important;min-height:0!important;margin-top:6px!important;padding:0!important;border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important;color:#5271b8!important;font-size:10px!important;font-weight:600!important;text-align:left!important}
#page-client-details .client-activity-content>.crm-btn:hover{text-decoration:underline;background:transparent!important}

/* Keep Orders Workspace inside the same Dashboard shell as every other page. */
@media (min-width: 993px) {
  body:has(#page-orders-workspace.active) .sidebar { width: 260px; }
  body:has(#page-orders-workspace.active) .main { margin-left: 260px; }
  body.vm-sidebar-collapsed:has(#page-orders-workspace.active) .sidebar { width: 76px; }
  body.vm-sidebar-collapsed:has(#page-orders-workspace.active) .main { margin-left: 76px; }
  body:has(#page-orders-workspace.active) .topbar { display: none !important; }
  #page-orders-workspace.active { flex: 1 1 auto; height: 100dvh; min-height: 0; }
  #page-orders-workspace .manus-orders-host { height: 100%; min-height: 0; }
  #page-orders-workspace .manus-orders-frame { height: 100%; min-height: 0; }
}
@media (max-width: 992px) {
  body:has(#page-orders-workspace.active) .sidebar { width: 270px; }
  body:has(#page-orders-workspace.active) .main { margin-left: 0; }
  body:has(#page-orders-workspace.active) .topbar { display: none !important; }
  #page-orders-workspace.active { flex: 1 1 auto; height: 100dvh; min-height: 0; }
  #page-orders-workspace .manus-orders-host { height: 100%; min-height: 0; }
  #page-orders-workspace .manus-orders-frame { height: 100%; min-height: 0; }
}

/* Let Client Details use the full dashboard content area without outer page gutters. */
#page-client-details.active {
  flex: 1 1 auto;
  width: 100%;
  min-width: 0;
  max-width: none;
  padding: 0 !important;
  gap: 0 !important;
}
#page-client-details .client-page {
  width: 100%;
  min-width: 0;
  max-width: none;
  margin: 0;
  border-radius: 0;
}
#page-client-details .client-content {
  width: 100%;
  max-width: 1660px;
  padding-top: 20px;
}

/* Client Details owns its full content column; discard the dashboard page inset. */
body.vm-upgrade #page-client-details.page.active {
  display: flex !important;
  flex: 1 1 auto !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0 !important;
  padding: 0 !important;
  gap: 0 !important;
  box-sizing: border-box !important;
}
body.vm-upgrade #page-client-details > .client-page {
  flex: 1 1 auto !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  margin: -16px -20px !important;
  border-radius: 0 !important;
}
body.vm-upgrade #page-client-details .client-content {
  width: 100% !important;
  max-width: none !important;
  margin: 0 auto !important;
  padding: 20px 30px 48px !important;
  box-sizing: border-box !important;
}
@media (max-width: 750px) {
  body.vm-upgrade #page-client-details .client-content {
    padding: 16px 12px 70px !important;
  }
}


/* Keep the CRM and Orders Workspace controls in the active dashboard theme. */
body.vm-upgrade .crm-shell {
  --ink:var(--text);
  --muted:var(--text2);
  color:var(--text)!important;
  background:radial-gradient(ellipse at 12% 0,color-mix(in srgb,var(--accent) 9%,transparent),transparent 42%),var(--bg)!important;
}
body.vm-upgrade .crm-shell :is(.crm-local,.crm-card,.crm-stats>div,.crm-panel,.crm-profile,.crm-address,.crm-range,.crm-shell button,.crm-shell input,.crm-shell select,.crm-shell textarea) {
  color:var(--text)!important;
  background-color:var(--surface)!important;
  border-color:var(--border)!important;
}
body.vm-upgrade .crm-shell :is(.crm-heading-icon,.crm-avatar,.crm-profile,.crm-card,.crm-panel,.crm-address) {
  border-color:var(--border)!important;
}
body.vm-upgrade .crm-shell :is(.crm-heading>button,.crm-primary,.crm-panel form button,.crm-shell button.primary-button) {
  color:var(--vm-accent-text,#102b23)!important;
  background:linear-gradient(135deg,var(--accent),color-mix(in srgb,var(--accent) 78%,var(--surface)))!important;
  border-color:color-mix(in srgb,var(--accent) 62%,var(--border))!important;
}
body.vm-upgrade .crm-shell .crm-shell button:hover,
body.vm-upgrade .crm-shell button:hover { border-color:var(--accent)!important; }
body.vm-upgrade .crm-shell :is(.crm-order-link,.crm-existing-link,.crm-card>button) { color:var(--accent)!important; }
body.vm-upgrade .crm-shell :is(.crm-heading-icon,.crm-stat-icon,.crm-count,.crm-avatar) { color:var(--accent)!important; }
body.vm-upgrade .crm-shell :focus-visible { outline-color:var(--accent)!important; }
