.crm-workspace .head-actions{display:flex;gap:8px;flex-wrap:wrap}
.crm-overview{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin:20px 0}
.crm-kpi{text-align:left;background:#fff;border:1px solid #e2e8f2;border-radius:12px;padding:20px;cursor:pointer;color:#26374d}
.crm-kpi small{color:#77869b;font-size:13px;display:block}.crm-kpi strong{display:block;font-size:27px;margin-top:10px}.crm-kpi:hover{border-color:#adc4fa}
.crm-section-tabs{display:flex;gap:6px;border-bottom:1px solid #e2e8f2;margin:0 0 16px;overflow:auto}
.crm-section-tabs button{flex-shrink:0;border:0;border-bottom:3px solid transparent;background:transparent;padding:13px 16px;color:#738198;font:inherit;cursor:pointer}
.crm-section-tabs button.active{border-color:#246bfd;color:#246bfd;font-weight:600}.crm-section-tabs span{margin-left:7px;font-size:12px;border-radius:12px;padding:2px 6px;background:#eaf0fb}
.crm-filters{display:flex;align-items:center;gap:10px;flex-wrap:wrap;padding:16px}.crm-filters input,.crm-filters select{height:39px;border:1px solid #dce4ef;background:#fff;border-radius:7px;padding:0 10px;color:#35465e;font:inherit;font-size:13px;min-width:100px;max-width:100%}
.crm-filters #crmSearch{flex:1;min-width:230px}.crm-date-filter{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.crm-date-filter small{color:#7e8da2;font-size:12px}.crm-date-filter input{width:140px}
.crm-list-bar{display:flex;justify-content:space-between;align-items:center;padding:0 16px 14px;color:#7e8da2;font-size:13px}
.crm-table{min-width:1120px}.crm-table td{vertical-align:middle}.crm-table td small{display:block;color:#8a98aa;font-size:12px;margin-top:5px;max-width:240px;white-space:normal}.crm-table th{white-space:nowrap}.crm-table td:nth-child(2){max-width:240px;overflow-wrap:anywhere}
.crm-name{border:0;background:none;padding:0;color:#246bfd;font:inherit;font-weight:600;cursor:pointer;text-align:left;overflow-wrap:anywhere}.crm-row-actions{display:flex;gap:5px;flex-wrap:wrap;max-width:240px}.crm-row-actions button{padding:6px 9px;white-space:nowrap;font-size:12px}
.crm-empty{text-align:center;padding:48px 16px!important;color:#8594a8}.crm-overdue{color:#c44747;font-weight:600}
@media(min-width:761px) and (max-width:1250px){
  .crm-workspace .crm-track-table{min-width:0;table-layout:fixed;width:100%}
  .crm-workspace .crm-track-table :is(th,td){padding:12px 7px;white-space:normal;overflow-wrap:anywhere}
  .crm-track-table th:nth-child(1){width:10%}.crm-track-table th:nth-child(2){width:14%}.crm-track-table th:nth-child(3){width:10%}.crm-track-table th:nth-child(4){width:10%}.crm-track-table th:nth-child(5){width:12%}.crm-track-table th:nth-child(6){width:12%}.crm-track-table th:nth-child(7){width:13%}.crm-track-table th:nth-child(8){width:8%}.crm-track-table th:nth-child(9){width:11%}
  .crm-track-table :is(.status,.crm-name,.crm-row-actions button){white-space:normal;overflow-wrap:anywhere;max-width:100%}
  .crm-track-table .crm-row-actions button{padding:6px;height:auto;min-height:30px;line-height:1.4}
}
.crm-task-list{padding:0 16px}.crm-task{display:grid;grid-template-columns:1fr 220px 130px;align-items:center;gap:16px;border-top:1px solid #ecf0f5;padding:20px 4px}.crm-task h3{font-size:15px;display:inline;margin-left:14px}.crm-task p{margin:10px 0 0;color:#7a889d}.crm-task small{display:block;color:#7a889d;margin-top:5px}
.crm-entry-form{max-width:1180px;margin:0 auto}.crm-entry-form section{margin:16px 0;padding:24px}.crm-entry-form h2{font-size:16px;margin:0 0 20px}.crm-entry-head{display:flex;justify-content:space-between;align-items:center}.crm-entry-form .field-grid{grid-template-columns:repeat(3,minmax(0,1fr))}.crm-entry-form .span-all{grid-column:1/-1}.crm-entry-form input,.crm-entry-form textarea,.crm-entry-form select{font:inherit;font-size:14px}.crm-customer-summary{grid-column:span 2;display:flex;gap:12px;align-items:center;flex-wrap:wrap;color:#8290a3;font-size:13px}.crm-customer-summary b{color:#293c54;font-size:15px}
.crm-entry-actions{display:flex;justify-content:flex-end;gap:10px;background:#fff;border:1px solid #e1e8f2;border-radius:12px;padding:16px;margin-top:20px}.crm-form-error{color:#c74747;min-height:20px;font-size:13px}
.crm-refresh-link{align-self:flex-start;border:0;background:transparent;color:#246bfd;font-size:12px;padding:6px 0;cursor:pointer}.crm-entry-actions{flex-wrap:wrap}
.crm-sample-image{display:flex;align-items:center;gap:12px;margin-top:16px}.crm-sample-image img{max-width:220px;max-height:160px;object-fit:contain;border-radius:8px;border:1px solid #e1e8f2}.crm-history{background:#fff;border:1px solid #e1e8f2;border-radius:12px;padding:20px;color:#607087}.crm-history summary{cursor:pointer;font-weight:600}.crm-history>div,.crm-log{border-top:1px solid #edf0f5;padding:16px 0}.crm-history p,.crm-log p{white-space:pre-wrap;overflow-wrap:anywhere}.crm-log small,.crm-history small{display:block;color:#8a97a9}.crm-export-fields{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;padding:15px 0}.crm-export-fields label{display:flex;align-items:center;gap:8px;font-size:14px}.crm-export-fields input{width:auto}
.crm-profile .profile-metrics{grid-template-columns:repeat(6,minmax(0,1fr))}.crm-profile .profile-metrics strong{font-size:19px}.crm-profile-note{margin-top:25px;padding-top:20px;border-top:1px solid #edf0f5}.crm-profile-note p{white-space:pre-wrap}.crm-quick-actions button{width:100%;margin:5px 0}.crm-profile~.tabs{overflow:auto;white-space:nowrap}.crm-workspace button:disabled{opacity:.45;cursor:not-allowed}
@media(max-width:1100px){.crm-entry-form .field-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-customer-summary{grid-column:span 1}.crm-profile .profile-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:650px){.crm-overview{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}.crm-kpi{padding:14px}.crm-section-tabs button{padding:12px 10px}.crm-entry-form .field-grid{grid-template-columns:1fr}.crm-entry-form section{padding:18px}.crm-task{grid-template-columns:1fr;gap:12px}.crm-export-fields{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-filters #crmSearch{min-width:100%;flex:auto}.crm-profile .profile-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}
.crm-customer-table{min-width:1140px}.crm-customer-table td:first-child{min-width:190px;max-width:270px}.crm-customer-table td:last-child{min-width:188px}.crm-customer-table .crm-row-actions{max-width:230px;align-items:center}.crm-sale{color:#246bfd!important;border-color:#bcd0fb!important;background:#f4f8ff!important}
.crm-phone{color:#52677f;text-decoration:none}.crm-phone:hover{text-decoration:underline}.crm-muted{color:#7a889d;font-size:13px}.crm-cleared{color:#087d62;font-weight:600}.crm-due-link{border:0;background:#fff1f0;color:#bd3434;font:inherit;font-weight:700;padding:6px 9px;border-radius:6px;cursor:pointer;white-space:nowrap}.crm-customer-table .crm-due-label{color:#a44343}.crm-customer-table .crm-search-match{color:#285da9;background:#f0f5ff;padding:4px 7px;border-radius:4px}.crm-customer-table .crm-customer-meta{font-size:11px}
.crm-actions-more{flex-basis:100%;font-size:12px}.crm-actions-more summary{color:#75859b;cursor:pointer;list-style:none;padding:5px 8px;width:fit-content}.crm-actions-more summary::after{content:' ▾'}.crm-actions-more[open] summary::after{content:' ▴'}.crm-actions-more>div{display:flex;gap:5px;flex-wrap:wrap;padding-top:4px}.crm-actions-more[open]{padding:3px 0;background:#f6f8fc;border-radius:6px}
.crm-history-toolbar{display:flex;align-items:center;gap:12px;margin:20px 0 12px}.crm-history-toolbar input{flex:1;min-width:0;border:1px solid #dce4ef;border-radius:8px;padding:11px 12px;font:inherit}.crm-history-toolbar span{font-size:12px;color:#7a889d;white-space:nowrap}.crm-history-selection{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.crm-history-selection span{color:#52677f;font-size:13px}.crm-history-selection .primary-btn{margin-left:auto}.crm-history-product{display:grid;grid-template-columns:24px 116px minmax(0,1fr) auto;gap:16px;align-items:center;border:1px solid #e1e8f2;padding:16px;border-radius:10px;margin:12px 0;background:#fff}.crm-history-product.is-selected{border-color:#81a9fa;background:#f7faff}.crm-history-check{display:flex;align-items:center;justify-content:center}.crm-history-check input{width:18px;height:18px;accent-color:#246bfd}.crm-history-photo{padding:0;border:1px solid #e1e8f2;background:#f6f8fc;border-radius:7px;height:92px;overflow:hidden;cursor:zoom-in}.crm-history-photo img{width:100%;height:100%;object-fit:contain}.crm-history-photo span{color:#8594a8;font-size:12px}.crm-history-photo:disabled{cursor:default}.crm-history-info{min-width:0;overflow-wrap:anywhere}.crm-history-info>b{font-size:15px;color:#26374d}.crm-history-info p{color:#52677f;font-size:13px;margin:6px 0}.crm-history-info>small{color:#7a889d;font-size:12px}.crm-history-price{display:block;color:#26374d;font-weight:600;font-size:13px;margin-top:8px}.crm-history-price small{font-size:11px;font-weight:400;color:#8a97a9;margin-left:7px}.crm-repeat-note{padding:12px 16px;margin:12px 0;border:1px solid #bdd1fb;border-radius:8px;background:#f0f6ff;color:#285da9;font-size:13px}
.crm-outstanding-summary{display:flex;gap:15px;align-items:baseline}.crm-outstanding-summary strong{font-size:25px;color:#bd3434}.crm-outstanding-summary span{color:#7a889d}.crm-outstanding-list article{display:grid;grid-template-columns:minmax(150px,1fr) repeat(3,auto);gap:18px;align-items:center;padding:16px 0;border-top:1px solid #e1e8f2}.crm-outstanding-list small{display:block;color:#7a889d;font-size:12px;margin:5px 0}.crm-outstanding-list b{font-size:14px}
/* PC customer workbench: fewer columns, explicit actions and stable inner scroll. */
@media screen and (min-width:761px){
  .crm-workspace{min-width:0}.crm-workspace .orders-card{overflow:hidden}.crm-workspace .table-wrap{max-width:100%;overflow:auto}
  .crm-workspace .crm-customer-table{width:100%;min-width:940px}.crm-customer-table td:first-child{min-width:170px}.crm-customer-table td:last-child{min-width:220px}.crm-customer-table .crm-row-actions{max-width:240px}
  .crm-workspace .crm-filters{gap:10px;background:#fff}.crm-workspace .crm-overview{gap:12px;margin:16px 0}.crm-workspace .crm-kpi{padding:15px 18px;border-radius:10px}.crm-workspace .crm-kpi strong{font-size:25px;margin-top:6px}
  .crm-contact-summary{max-width:190px!important;display:-webkit-box!important;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;line-height:1.5}
  .crm-task{grid-template-columns:minmax(0,1fr) 175px 190px}.crm-workspace .crm-section-tabs button{padding:12px 20px}
}
.crm-focus-chip{border:1px solid #bcd0fb;background:#eff5ff;color:#246bfd;border-radius:16px;padding:6px 10px;cursor:pointer;white-space:nowrap}
@media screen and (min-width:761px) and (max-width:1250px){
  .crm-workspace .crm-customer-table{min-width:0;table-layout:fixed}
  .crm-workspace .crm-customer-table :is(th,td){min-width:0;max-width:none;padding:12px 8px;white-space:normal;overflow-wrap:anywhere}
  .crm-customer-table th:nth-child(1){width:18%}.crm-customer-table th:nth-child(2){width:13%}.crm-customer-table th:nth-child(3){width:16%}.crm-customer-table th:nth-child(4){width:18%}.crm-customer-table th:nth-child(5){width:10%}.crm-customer-table th:nth-child(6){width:25%}
  .crm-workspace .crm-customer-table .crm-row-actions{max-width:none;gap:5px}.crm-workspace .crm-customer-table .crm-row-actions button{padding:6px 8px}
}
.crm-sample-thumb{display:block;border:1px solid #dce4ef;background:#fff;border-radius:7px;width:96px;height:68px;padding:3px;margin-bottom:6px;cursor:zoom-in}.crm-sample-thumb img{width:100%;height:100%;object-fit:contain}
.crm-duplicate-hint{font-size:13px;color:#a86710;background:#fff8e9;border-radius:7px;padding:10px;line-height:1.6}.crm-duplicate-hint:empty{display:none}
.crm-quote-card{display:flex;align-items:center;gap:18px;flex-wrap:wrap;padding:18px 0;border-bottom:1px solid #e2e8f2}.crm-quote-card>div:first-child{flex:1;min-width:170px}.crm-quote-card small,.crm-quote-card strong{display:block;margin-top:7px}.crm-quote-card small{color:#7a889d;font-size:12px}.crm-quote-images{display:flex;gap:6px}.crm-quote-images img{width:70px;height:60px;object-fit:contain;border:1px solid #dce4ef;border-radius:5px}.crm-customer-meta .status{font-size:11px;padding:3px 7px}
@media(max-width:760px){#content .crm-overview{grid-template-columns:repeat(4,minmax(0,1fr));gap:6px;margin:12px 0}#content .crm-kpi{padding:10px 7px;border-radius:9px}#content .crm-kpi small{font-size:11px;line-height:1.35;min-height:30px}#content .crm-kpi strong{font-size:22px;margin-top:4px}.crm-customer-table .mobile-record-card>td[data-mobile-role="actions"]{grid-row:2;padding-top:4px!important;padding-bottom:10px!important;border-bottom:1px solid #edf0f5}.crm-customer-table .mobile-record-card .crm-row-actions .crm-actions-more{flex-basis:auto}.crm-customer-table .mobile-record-card .crm-actions-more[open]{flex-basis:100%}}
@media(max-width:760px){.crm-customer-table .crm-row-actions{max-width:none;width:100%}.crm-customer-table td:first-child,.crm-customer-table td:last-child{min-width:0;max-width:none}.crm-customer-table .crm-row-actions>button{flex:1;min-height:42px;font-size:13px}.crm-customer-table .crm-phone{display:inline-block;padding:4px 0}.crm-history-toolbar{flex-wrap:wrap}.crm-history-toolbar input{flex-basis:100%}.crm-history-selection .primary-btn{flex-basis:100%;margin:0;min-height:44px}.crm-history-product{grid-template-columns:22px 82px minmax(0,1fr);gap:10px;padding:12px}.crm-history-photo{height:82px}.crm-history-product>button:last-child{grid-column:2/-1;min-height:42px}.crm-history-info p{font-size:12px}.crm-history-price small{display:block;margin:4px 0 0}.crm-outstanding-list article{grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.crm-outstanding-list article>div:first-child{grid-column:1/-1}.crm-outstanding-summary{flex-wrap:wrap;gap:8px}}
