.crm-toolbar,.crm-summary,.crm-view-switch,.crm-stage-tabs,.crm-detail-badges{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.crm-toolbar{justify-content:space-between;margin:18px 0 22px}.crm-stage-tabs{margin:0 0 20px;overflow-x:auto;flex-wrap:nowrap;padding-bottom:2px}.crm-tab{border:1px solid #e6e7e3;border-radius:9px;background:#fff;color:#697067;padding:9px 13px;white-space:nowrap;cursor:pointer;font:inherit;font-size:12px}.crm-tab.active{background:#ebede9;color:#242722;border-color:#ebede9;font-weight:600}.crm-tab span{color:#81877e;margin-left:2px}.crm-board{display:grid;grid-auto-columns:minmax(228px,1fr);grid-auto-flow:column;gap:14px;overflow-x:auto;padding-bottom:10px;scrollbar-color:#d8dbd5 transparent}.crm-column{background:#eeefeb;border-radius:10px;min-height:460px;padding:12px}.crm-column-head{display:flex;justify-content:space-between;align-items:center;font-size:12px;margin:2px 0 12px}.crm-column-head span{color:#73786e}.crm-column-stack{display:grid;align-content:start;gap:12px}.crm-column-empty{font-size:12px;color:#73786e;padding:12px;margin:0}.crm-opportunity{background:#fff;border:1px solid #e6e7e3;border-radius:10px;padding:14px;cursor:pointer;min-width:0;transition:border-color .15s,box-shadow .15s}.crm-opportunity:hover,.crm-opportunity:focus-visible{border-color:#aab5aa;box-shadow:0 3px 12px #2427220b;outline:none}.crm-card-top{display:flex;align-items:start;justify-content:space-between;gap:8px}.crm-card-top strong{font-size:13px;line-height:1.4}.crm-card-top .badge{font-size:10px;flex:none}.crm-card-demo{margin-top:12px}.crm-opportunity p{font-size:12px;line-height:1.5;margin:14px 0 10px}.crm-opportunity small{display:block;color:#73786e;font-size:11px}.crm-card-foot{border-top:1px solid #e6e7e3;margin-top:12px;padding-top:10px;display:flex;justify-content:space-between;color:#73786e;font-size:11px}.crm-list{display:grid;gap:12px;max-width:860px}.crm-list .crm-opportunity{display:grid;grid-template-columns:1fr auto;column-gap:10px}.crm-list .crm-card-demo,.crm-list .crm-opportunity p,.crm-list .crm-opportunity small,.crm-list .crm-card-foot{grid-column:1/-1}.crm-footnote{font-size:11px;color:#73786e;margin:12px 0 0}.crm-table td strong{display:block;font-weight:600}.crm-table td small{display:block;color:#73786e;margin-top:3px}.crm-table tbody tr[data-action]{cursor:pointer}.crm-table tbody tr[data-action]:hover{background:#f9faf8}.crm-table tbody tr[data-action]:focus-visible{outline:2px solid #267548;outline-offset:-2px}.crm-duo{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-top:20px}.crm-panel{padding:20px}.crm-panel h2{font-size:16px;margin:0 0 17px}.crm-line-link{width:100%;padding:12px 0;border:0;border-top:1px solid #e6e7e3;background:transparent;display:flex;align-items:center;justify-content:space-between;gap:12px;text-align:left;color:#242722;cursor:pointer;font:inherit}.crm-line-link>span:first-child{display:flex;align-items:center;gap:12px}.crm-line-link strong,.crm-line-link small{display:block}.crm-line-link strong{font-size:12px}.crm-line-link small{color:#73786e;font-size:11px;margin-top:4px}.crm-money-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;margin:0 0 22px}.crm-money-card{padding:18px;display:flex;flex-direction:column;gap:9px;min-height:124px}.crm-money-card>span{font-size:12px;color:#73786e}.crm-money-card strong{font-size:27px;letter-spacing:-.04em}.crm-money-card small{font-size:11px;color:#73786e}.crm-ledger-note{display:flex;align-items:center;gap:10px;color:#73786e;background:#eeefeb;border-radius:8px;padding:14px 16px;font-size:12px;margin:20px 0}.crm-timing{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px}.crm-timing>div{background:#f6f7f5;border-radius:8px;padding:12px;display:flex;flex-direction:column;gap:5px}.crm-timing small,.crm-timing span{font-size:11px;color:#73786e}.crm-timing strong{font-size:16px}.crm-detail-badges{margin:0 0 22px}.crm-detail-grid{display:grid;grid-template-columns:minmax(0,1.5fr) minmax(280px,.95fr);gap:18px;align-items:start}.crm-detail-side{display:grid;gap:18px}.crm-panel-head,.crm-progress-label,.crm-keyline{display:flex;align-items:center;justify-content:space-between;gap:12px}.crm-panel-head h2{margin:0}.crm-progress-label{font-size:12px;margin:20px 0 10px}.crm-progress-label span,.crm-keyline span{color:#73786e}.crm-progress{height:8px;background:#eeefeb;border-radius:20px;overflow:hidden;margin:0 0 14px}.crm-progress>span{display:block;background:#267548;height:100%;border-radius:20px}.crm-milestone{border-top:1px solid #e6e7e3;display:flex;align-items:center;justify-content:space-between;gap:12px;padding:15px 0}.crm-milestone label{display:flex;align-items:center;gap:12px;min-width:0;cursor:pointer}.crm-milestone input{width:17px;height:17px;accent-color:#267548;flex:none}.crm-milestone strong,.crm-milestone small{display:block}.crm-milestone strong{font-size:13px}.crm-milestone small{font-size:11px;color:#73786e;margin-top:4px}.crm-milestone input:checked+span strong{color:#267548}.crm-keyline{font-size:12px;margin:14px 0}.crm-detail-side .button{width:100%;justify-content:center;margin-top:12px}.crm-detail-side p{font-size:12px;line-height:1.6}.crm-detail-side a{font-size:12px;color:#267548}.crm-form-hint{font-size:11px;color:#73786e;align-self:end}.crm-receipts{border-bottom:1px solid #e6e7e3;margin-bottom:16px;padding-bottom:8px}.crm-receipts p{font-size:12px;color:#73786e}.crm-receipts .crm-keyline{margin:8px 0}
@media(max-width:1100px){.crm-money-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-board{grid-auto-columns:minmax(260px,38%)}.crm-detail-grid{grid-template-columns:1fr}.crm-detail-side{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:800px){.crm-board{display:grid;grid-auto-flow:row;grid-auto-columns:auto;grid-template-columns:1fr;overflow:visible}.crm-column,.crm-column-stack{display:contents}.crm-column-head,.crm-column-empty{display:none}.crm-duo{grid-template-columns:1fr}.crm-table{min-width:640px}.crm-detail-side{grid-template-columns:1fr}.crm-money-grid{gap:10px}.crm-money-card{min-height:105px;padding:14px}.crm-money-card strong{font-size:23px}.crm-timing{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:600px){.crm-toolbar{align-items:flex-start}.crm-summary{width:100%}.crm-stage-tabs{margin-top:14px}.crm-money-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-money-card strong{font-size:21px}.crm-timing{grid-template-columns:1fr 1fr}.crm-panel{padding:16px}.crm-progress-label{align-items:flex-start;flex-direction:column}.crm-list .crm-opportunity{padding:15px}}
@media(prefers-reduced-motion:reduce){.crm-opportunity{transition:none}}
.crm-site-link{display:flex;align-items:center;gap:8px;width:100%;margin-top:14px;padding:11px 12px;border:1px solid #e6e7e3;border-radius:8px;color:#242722!important;text-decoration:none;font-weight:600}.crm-site-link:hover,.crm-site-link:focus-visible{border-color:#267548;color:#267548!important;outline:none}
.crm-mobile-open{display:none}
@media(max-width:1279px){.crm-tab{min-height:44px}}
@media(max-width:600px){
  .crm-table-wrap{background:transparent;border:0;border-radius:0;box-shadow:none;overflow:visible}
  .crm-table{min-width:0!important;width:100%;border:0;background:transparent}
  .crm-table thead{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
  .crm-table tbody{display:grid;gap:12px}
  .crm-table tbody tr{display:block;background:#fff;border:1px solid #e6e7e3;border-radius:10px;padding:14px 15px;box-shadow:none}
  .crm-table tbody td{display:grid;grid-template-columns:104px minmax(0,1fr);align-items:center;gap:10px;width:100%;min-height:34px;padding:6px 0;border:0;text-align:left;font-size:12px;overflow-wrap:anywhere}
  .crm-table tbody td::before{content:attr(data-label);color:#73786e;font-size:11px;line-height:1.3}
  .crm-table tbody td:first-child{display:block;padding:0 0 10px;margin-bottom:7px;border-bottom:1px solid #e6e7e3}
  .crm-table tbody td:first-child::before{display:none}
  .crm-table tbody td:first-child strong{font-size:14px}
  .crm-table tbody td:last-child{display:block;margin-top:8px;padding:0}
  .crm-table tbody td:last-child::before{display:none}
  .crm-clients-table tbody td:last-child{display:flex;align-items:center;justify-content:flex-end;gap:8px;text-align:right;color:#267548;font-weight:600}
  .crm-mobile-open{display:inline}
  .crm-clients-table tbody td:last-child .icon{width:18px;height:18px}
  .crm-payments-table tbody td:last-child .button{width:100%;min-height:44px;justify-content:center}
}
.crm-payment-actions{display:flex;gap:6px;flex-wrap:wrap;align-items:center}
.crm-payments-table td[data-label="Milestone"] small{display:block;color:var(--muted,#6b756f);margin-top:3px}
.crm-payments-table td[data-label="Actions"]{min-width:170px}
/* CRM component hierarchy, adapted from public AlignUI table and filter patterns. */
.crm-workspace-toolbar{display:flex;align-items:center;gap:12px;margin:12px 0 14px;min-width:0}
.crm-search{display:flex;align-items:center;gap:9px;min-height:44px;width:min(360px,100%);padding:0 13px;border:1px solid var(--line);border-radius:10px;background:var(--surface);color:var(--muted)}
.crm-search:focus-within{border-color:var(--blue);box-shadow:0 0 0 3px var(--blue-soft)}
.crm-search input{min-width:0;width:100%;height:42px;border:0;outline:0;background:transparent;color:var(--ink)}
.crm-opportunity[hidden],.crm-column-empty[hidden],.crm-search-empty[hidden]{display:none!important}
.crm-due-count{font-size:12px;color:var(--muted);white-space:nowrap}
.crm-view-switch{margin-left:auto;display:flex;gap:2px;padding:3px;background:var(--soft);border-radius:10px;flex-wrap:nowrap}
.crm-view-switch button{display:inline-flex;align-items:center;justify-content:center;gap:7px;border:0;border-radius:7px;min-height:38px;min-width:80px;padding:0 10px;background:transparent;color:var(--muted);font-size:12px}
.crm-view-switch button[aria-pressed="true"]{background:#fff;color:var(--ink);box-shadow:0 1px 3px #24272215;font-weight:600}
.crm-stage-tabs{gap:4px;margin:0 0 16px;padding:0 0 2px;border-bottom:1px solid var(--line);scrollbar-width:thin}
.crm-tab{min-height:44px;padding:0 12px;border:0;border-bottom:2px solid transparent;border-radius:0;background:transparent;color:var(--muted);font-size:12px}
.crm-tab:hover{color:var(--ink);background:var(--canvas)}
.crm-tab.active{border-color:var(--blue);background:transparent;color:var(--ink)}
.crm-tab.active span{color:var(--blue)}
.crm-board{display:flex;gap:12px;width:100%;max-width:100%;min-width:0;overflow-x:auto;overscroll-behavior-inline:contain;scroll-snap-type:x proximity}
.crm-column{flex:0 0 260px;min-height:300px;background:var(--soft);border:1px solid var(--line);border-radius:12px;padding:10px;scroll-snap-align:start}
.crm-column-head{min-height:32px;margin:0 2px 9px;font-size:13px}
.crm-column-head span{display:grid;place-items:center;min-width:23px;height:23px;padding:0 5px;border-radius:7px;background:#fff;color:var(--muted);font-size:11px}
.crm-column-stack{gap:8px}
.crm-column-empty{padding:8px 4px}
.crm-opportunity{padding:13px;border-radius:9px;box-shadow:0 1px 2px #24272208}
.crm-card-top strong{font-size:13px;line-height:1.3;overflow-wrap:anywhere}
.crm-card-top .icon{color:var(--muted);flex:none}
.crm-next-action{margin:9px 0 10px!important;min-height:18px;color:var(--ink);font-size:12px!important;line-height:1.4!important}
.crm-card-meta{display:flex;align-items:center;gap:7px;flex-wrap:wrap}
.crm-card-meta .badge{font-size:10px}
.crm-follow-up{font-size:11px;color:var(--muted)}
.crm-follow-up.is-due{color:var(--amber);font-weight:600}
.crm-card-foot{align-items:center;margin-top:10px;padding-top:9px}
.crm-stage-control select{height:34px;max-width:122px;padding:0 6px;border:1px solid var(--line);border-radius:7px;background:#fff;color:var(--ink);font-size:11px}
.crm-stage-control select:focus-visible{outline:2px solid var(--blue)}
.crm-no-results{padding:22px;color:var(--muted);font-size:13px}
.crm-list{max-width:none;gap:7px}
.crm-list .crm-opportunity{display:grid;grid-template-columns:minmax(170px,1.3fr) minmax(140px,1.5fr) minmax(180px,1fr) minmax(140px,1fr);align-items:center;gap:12px}
.crm-list .crm-next-action,.crm-list .crm-card-meta,.crm-list .crm-card-foot{margin:0!important;grid-column:auto;border:0;padding:0}
.crm-list .crm-card-top .icon{display:none}
.crm-list .crm-card-foot{justify-content:flex-end;gap:10px}
.crm-list .crm-card-foot span{max-width:90px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.crm-table-wrap{border:1px solid var(--line);border-radius:12px;background:#fff;overflow-x:auto}
.crm-table{min-width:680px}
.crm-table thead{background:var(--canvas)}
.crm-table th{height:42px;color:var(--muted);font-size:11px;font-weight:600}
.crm-table td{height:64px;vertical-align:middle}
.crm-table td strong{font-size:13px}
.crm-table td small{font-size:11px}
.crm-table .crm-amount{font-weight:600;white-space:nowrap;font-variant-numeric:tabular-nums}
.crm-overdue strong{color:var(--amber)}
.crm-upcoming{margin-top:16px}
.crm-panel-head h2{margin:0}
.crm-line-link{min-height:54px}
.crm-line-date{display:flex;align-items:center;gap:8px;color:var(--muted);white-space:nowrap;font-size:12px}
.crm-money-grid{grid-template-columns:repeat(3,minmax(0,1fr));margin:0 0 18px}
.crm-money-card{min-height:104px;gap:5px}
.crm-money-card strong{font-size:24px;line-height:1.2}
.crm-money-card.has-overdue strong{color:var(--amber)}
.crm-ledger-note{background:transparent;padding:0;margin:12px 0;color:var(--muted);font-size:11px}
.crm-payment-actions{flex-wrap:nowrap}
.crm-payment-actions .button:first-child{color:var(--blue);border-color:#d7e2f1}
.crm-payment-actions .button{min-height:36px}
/* Keep the complete board inside the page at every viewport. */
.crm-stage-tabs{flex-wrap:wrap;overflow:visible}
.crm-board{display:grid;grid-auto-flow:row;grid-auto-columns:auto;grid-template-columns:repeat(auto-fit,minmax(min(100%,245px),1fr));align-items:start;overflow:visible;scroll-snap-type:none}
.crm-column{width:auto;min-width:0;min-height:200px;flex:auto}
@media(max-width:1279px){.crm-board{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-column{flex-basis:auto}}
@media(max-width:600px){.crm-board{grid-template-columns:1fr}.crm-column{flex-basis:auto;min-height:0}}
@media(max-width:1279px){.crm-view-switch button,.crm-stage-control select,.crm-payment-actions .button{min-height:44px}.crm-column{flex-basis:min(38%,300px)}}
@media(max-width:800px){.crm-column{flex-basis:68%}.crm-column,.crm-column-stack{display:block}.crm-column-head{display:flex}.crm-column-empty{display:block}.crm-column-stack{display:grid}.crm-list .crm-opportunity{grid-template-columns:1fr 1fr}.crm-list .crm-card-top,.crm-list .crm-next-action{grid-column:1/-1}.crm-money-grid{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media(max-width:600px){.crm-workspace-toolbar{flex-wrap:wrap}.crm-search{width:100%}.crm-due-count{order:2}.crm-view-switch{order:3}.crm-column{flex-basis:88%}.crm-list .crm-opportunity{display:block}.crm-list .crm-next-action{margin:9px 0 10px!important}.crm-list .crm-card-foot{margin-top:10px!important;padding-top:9px;justify-content:space-between}.crm-money-grid{grid-template-columns:1fr 1fr}.crm-money-card:last-child{grid-column:1/-1}.crm-money-card strong{font-size:22px}.crm-table{min-width:0}.crm-table tbody td{min-height:34px}.crm-table tbody td:first-child{min-height:44px}.crm-payment-actions{flex-wrap:wrap}.crm-payment-actions .button{flex:1}}
@media(max-width:800px){.crm-board{display:grid;grid-auto-flow:row;grid-template-columns:1fr}.crm-column,.crm-column-stack{display:block}.crm-column-head{display:flex}.crm-column-empty{display:block}.crm-column-stack{display:grid}.crm-column{min-height:0}}
