:root{--ink:#192a25;--muted:#77827d;--line:#e5ebe7;--paper:#f5f7f5;--white:#fff;--green:#174b3b;--green2:#246b51;--mint:#e5f3eb;--blue:#eaf1fb;--gold:#fff4d9;--rose:#fae9e8;--shadow:0 8px 28px rgba(27,54,43,.045)}*{box-sizing:border-box}body{margin:0;background:var(--paper);color:var(--ink);font:14px/1.5 Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}a{color:inherit;text-decoration:none}button,input,select,textarea{font:inherit}button,a,input,select,textarea{outline-color:#7ab89b}h1,h2,h3,p{margin-top:0}h1{font-size:30px;line-height:1.2;letter-spacing:-.8px;margin-bottom:8px}h2{font-size:16px;letter-spacing:-.2px;margin:0}h3{font-size:16px;margin-bottom:5px}.muted{color:var(--muted)}.small{font-size:12px}.tiny{font-size:11px}.eyebrow{font-size:10px;font-weight:800;letter-spacing:1.5px;color:#648071;margin:0 0 8px}.topbar{height:68px;background:#fff;border-bottom:1px solid var(--line);display:flex;align-items:center;padding:0 max(24px,calc((100vw - 1380px)/2));gap:42px;position:sticky;top:0;z-index:5}.brand{display:flex;align-items:center;gap:9px;font-size:17px;font-weight:800;white-space:nowrap}.brand-mark{height:31px;width:31px;border-radius:10px;background:var(--green);color:#fff;display:grid;place-items:center;font-size:17px}.brand-light{font-weight:500;color:#658074}.main-nav{display:flex;align-items:center;gap:24px;height:100%;flex:1}.main-nav a{color:#697770;font-size:13px;height:100%;display:flex;align-items:center;border-bottom:2px solid transparent}.main-nav a:hover{color:var(--green);border-color:#8fbca6}.user-menu{display:flex;align-items:center;gap:9px;white-space:nowrap}.user-dot{height:29px;width:29px;border-radius:50%;background:#e0eee5;color:var(--green);font-weight:700;display:grid;place-items:center}.user-name{font-size:12px;font-weight:600}.link-button{border:0;background:none;color:#66766d;padding:5px 7px;cursor:pointer;font-size:12px}.link-button:hover{color:var(--green)}.page{max-width:1380px;margin:0 auto;padding:34px 28px 60px;min-height:calc(100vh - 105px)}.page-heading{display:flex;align-items:center;justify-content:space-between;gap:18px;margin-bottom:25px}.page-heading .muted{margin:0}.heading-actions{display:flex;gap:9px;flex-wrap:wrap}.btn{display:inline-flex;align-items:center;justify-content:center;gap:7px;padding:10px 15px;border:1px solid transparent;border-radius:9px;font-size:12px;font-weight:700;cursor:pointer;white-space:nowrap}.btn.primary{background:var(--green);color:white}.btn.primary:hover{background:#0f3b2e}.btn.secondary{background:#fff;border-color:#dfe7e1;color:#34483d}.btn:disabled{opacity:.45;cursor:not-allowed}.full{width:100%;padding:12px}.stats-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin-bottom:22px}.stat-card{background:#fff;border:1px solid var(--line);border-radius:14px;padding:19px 20px;box-shadow:var(--shadow);display:grid;grid-template-columns:34px 1fr;align-items:center;column-gap:11px}.stat-icon{width:34px;height:34px;border-radius:10px;display:grid;place-items:center;font-weight:800;font-size:13px}.sage{background:var(--mint);color:#286c4e}.blue{background:var(--blue);color:#406ba8}.gold{background:var(--gold);color:#986e18;font-size:10px}.rose{background:var(--rose);color:#b25c59}.stat-label{font-size:12px;color:#69766f}.stat-card strong{grid-column:1/-1;font-size:25px;letter-spacing:-.8px;margin:12px 0 4px}.stat-card .money{font-size:21px}.stat-card a,.stat-foot{grid-column:1/-1;font-size:11px;color:#6b8d7a}.stat-card a:hover{color:var(--green)}.content-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:20px}.panel{background:#fff;border:1px solid var(--line);border-radius:14px;padding:20px;box-shadow:var(--shadow);min-width:0}.panel-head{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:17px}.panel-head p{font-size:12px;margin:4px 0 0}.text-link{font-size:12px;color:var(--green2);font-weight:700;white-space:nowrap}.task-row{display:flex;align-items:center;gap:11px;padding:12px 0;border-bottom:1px solid #eef1ef;min-width:0}.task-row:last-child{border-bottom:0}.check-btn{height:18px;width:18px;border:1.5px solid #cbd5ce;border-radius:6px;background:#fff;cursor:pointer;flex:none;display:grid;place-items:center;padding:0}.check-btn:hover{border-color:var(--green2)}.check-btn.checked{background:var(--green2);border-color:var(--green2)}.check-btn.checked:after{content:'✓';font-size:12px;color:#fff}.task-main{display:flex;flex-direction:column;gap:3px;min-width:0;flex:1}.item-title{font-weight:700;font-size:12px;overflow:hidden;text-overflow:ellipsis}.task-meta{display:flex;align-items:flex-end;flex-direction:column;gap:3px;flex:none}.priority{font-size:10px;font-weight:700;border-radius:5px;padding:3px 6px;background:#f0f2f0;color:#637067;white-space:nowrap}.priority.high{background:#fff0d8;color:#946315}.priority.urgent{background:#fce7e5;color:#a53f3a}.priority.low{background:#edf3ef;color:#698074}.due{font-size:10px;color:#7c8981}.overdue{color:#bd4944!important;font-weight:700}.add-row{display:block;padding:13px 0 0;color:var(--green2);font-weight:700;font-size:12px}.deal-list{display:flex;flex-direction:column}.deal-row{display:flex;align-items:center;gap:10px;padding:13px 0;border-bottom:1px solid #eef1ef;min-width:0}.deal-row:last-child{border-bottom:0}.deal-avatar{width:34px;height:34px;border-radius:10px;background:#e9f2ec;color:#356b4d;display:grid;place-items:center;font-weight:800;flex:none}.deal-main{display:flex;flex-direction:column;gap:3px;min-width:0;flex:1}.deal-main strong{font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.deal-value{display:flex;flex-direction:column;align-items:flex-end;font-size:12px;font-weight:700;gap:4px;white-space:nowrap}.stage-pill,.count-pill{font-size:10px;font-weight:600;border-radius:5px;background:#f0f4f1;color:#65756a;padding:3px 6px;white-space:nowrap}.empty-state{text-align:center;padding:35px 15px;color:var(--muted)}.empty-state>span{font-size:24px;color:#7da18b}.empty-state h3{color:var(--ink);margin-top:8px}.empty-state p{font-size:12px;margin-bottom:12px}.search-bar{display:flex;gap:9px;align-items:center;margin-bottom:18px}.search-bar input{flex:1}.table-wrap{overflow-x:auto}table{width:100%;border-collapse:collapse;text-align:left;white-space:nowrap}th{font-size:10px;letter-spacing:.7px;text-transform:uppercase;color:#849087;background:#fafbfa;padding:12px;font-weight:800}td{border-top:1px solid #edf1ee;padding:12px;font-size:12px;color:#526057}td strong{color:#23352b}td small{display:block;color:#849087;font-size:10px;margin-top:3px}.person-cell{display:flex;align-items:center;gap:9px;min-width:175px}.avatar{height:32px;width:32px;border-radius:10px;background:#e8f1eb;color:#316447;display:grid;place-items:center;font-weight:800;flex:none}.large-avatar{height:54px;width:54px;font-size:21px;border-radius:15px}.person-heading{display:flex;align-items:center;gap:14px}.person-heading h1{margin-bottom:5px}.breadcrumb{font-size:12px;color:#869188;margin-bottom:17px}.breadcrumb a{color:var(--green2)}.detail-grid{align-items:start}.stack{display:flex;flex-direction:column;gap:18px}.detail-fields{display:grid;grid-template-columns:1fr 1fr;gap:18px;padding:5px 0 15px}.detail-fields>div{display:flex;flex-direction:column;gap:4px;min-width:0}.detail-fields small{font-size:11px;color:#869188}.detail-fields strong{font-size:12px;overflow-wrap:anywhere}.notes-box{padding:13px;background:#f7f9f7;border-radius:8px;font-size:12px;white-space:pre-wrap;overflow-wrap:anywhere}.empty-inline{font-size:12px;padding:12px 0}.timeline{margin-top:18px;border-top:1px solid #eef1ef;padding-top:6px}.timeline-item{display:flex;gap:10px;padding:12px 0}.timeline-dot{width:8px;height:8px;border-radius:50%;background:#76a78a;margin-top:6px;flex:none}.timeline-item p{font-size:12px;margin:0 0 4px;white-space:pre-wrap;overflow-wrap:anywhere}.timeline-item small{font-size:10px;color:#8a958e}.message-mini{border-radius:9px;background:#f2f6f3;padding:10px;margin:10px 0;max-width:95%}.message-mini.outbound{margin-left:auto;background:#e5f3e9}.message-mini small{color:#77847c;font-size:10px}.message-mini p{font-size:12px;margin:4px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}.form-panel{max-width:900px}.form-stack{display:flex;flex-direction:column;gap:15px}.form-grid{display:grid;grid-template-columns:1fr 1fr;gap:17px}.form-grid label,.form-stack label{display:flex;flex-direction:column;gap:7px;font-size:12px;font-weight:700;color:#3d4e44;min-width:0}.span-2{grid-column:1/-1}input,select,textarea{width:100%;border:1px solid #dce5de;border-radius:8px;background:#fff;color:var(--ink);padding:10px 11px;font-size:12px;min-width:0}input:focus,select:focus,textarea:focus{border-color:#83b79a;box-shadow:0 0 0 3px #e5f3e9;outline:0}textarea{resize:vertical;line-height:1.5}.form-actions{display:flex;gap:9px;padding-top:6px}.field-help{font-size:10px;color:#849087;font-weight:400}.pipeline-grid{display:grid;grid-template-columns:repeat(6,minmax(190px,1fr));gap:12px;overflow-x:auto;padding-bottom:12px;align-items:start}.pipeline-column{background:#eef2ef;border:1px solid #e4eae5;border-radius:12px;padding:10px;min-height:260px}.pipeline-title{display:flex;align-items:center;gap:7px;font-size:11px;margin:3px 0 12px}.pipeline-title .count-pill{margin-left:auto}.stage-dot{width:8px;height:8px;border-radius:50%;background:#6f9c7e}.stage-2{background:#6893c3}.stage-3{background:#c69b47}.stage-4{background:#9a83c5}.stage-5{background:#3c9b69}.stage-6{background:#c7746d}.pipeline-cards{display:flex;flex-direction:column;gap:9px}.pipeline-card{display:block;background:#fff;border:1px solid #e6ebe7;border-radius:9px;padding:12px;box-shadow:0 2px 5px #253e2d08}.pipeline-card:hover{border-color:#b8d2c0;transform:translateY(-1px)}.pipeline-card-top{display:flex;justify-content:space-between;gap:6px}.pipeline-card>strong{display:block;font-size:12px;margin:8px 0;overflow-wrap:anywhere}.card-menu{color:#91a097}.pipeline-value{font-size:14px;font-weight:800}.quote-ref{font-size:10px;color:#688071;margin-top:5px}.pipeline-card-bottom{display:flex;align-items:center;gap:5px;border-top:1px solid #eef1ef;padding-top:10px;margin-top:11px}.owner-avatar{width:21px;height:21px;border-radius:50%;background:#e6f0e9;display:grid;place-items:center;color:#3e7654;font-size:10px;font-weight:800}.pipeline-card-bottom .muted:last-child{margin-left:auto}.pipeline-add{display:block;text-align:center;color:#728279;padding:9px;font-size:11px}.filter-tabs{display:flex;gap:20px;border-bottom:1px solid #e9eeea;margin:-4px 0 15px}.filter-tabs a{padding:9px 2px 12px;font-size:12px;color:#7c8981;border-bottom:2px solid transparent}.filter-tabs a.active{color:var(--green);border-color:var(--green);font-weight:800}.task-cell{display:flex;align-items:center;gap:10px}.task-cell a{display:block;white-space:normal;min-width:180px}.status-pill{display:inline-flex;align-items:center;font-size:10px;font-weight:700;padding:4px 7px;border-radius:6px;background:#f0f3f1;color:#68776d;white-space:nowrap}.status-pill.done,.status-pill.connected{background:#e3f4e9;color:#287248}.status-pill.pending{background:#fff2d8;color:#8c681e}.status-pill.open{background:#edf2fa;color:#52719a}.notice{padding:15px 17px;border:1px solid #f0ddb2;border-radius:11px;background:#fff8e8;margin:-5px 0 20px;color:#715c2e}.notice strong{font-size:13px}.notice p{font-size:12px;margin:5px 0 0;line-height:1.6}.wa-grid{grid-template-columns:minmax(270px,.8fr) minmax(0,1.2fr);align-items:start}.conversation-list{display:flex;flex-direction:column}.conversation-item{display:flex;gap:10px;padding:13px 0;border-bottom:1px solid #edf1ee}.conversation-item:last-child{border-bottom:0}.conversation-avatar{width:34px;height:34px;border-radius:50%;background:#e5f0e8;color:#356849;font-weight:800;display:grid;place-items:center;flex:none}.conversation-content{min-width:0;flex:1}.conversation-top{display:flex;justify-content:space-between;gap:10px}.conversation-top strong{font-size:12px}.conversation-content p{font-size:12px;margin:5px 0;white-space:pre-wrap;overflow-wrap:anywhere}.conversation-content small{font-size:10px}.team-grid{grid-template-columns:minmax(250px,.7fr) minmax(0,1.3fr);align-items:start}.team-row{display:flex;align-items:center;gap:10px;padding:12px 0;border-bottom:1px solid #eef1ef}.team-row:last-child{border:0}.team-person{display:flex;flex-direction:column;flex:1;min-width:0}.team-person strong{font-size:12px}.team-person small{font-size:10px;color:#829087}.settings-panel{max-width:850px}.settings-panel h2{margin:20px 0 8px}.settings-panel h2:first-child{margin-top:0}.settings-panel p,.settings-panel li{font-size:12px;color:#5d6b62;line-height:1.8}.settings-panel code{background:#eef2ef;border-radius:4px;padding:2px 4px;font-size:11px}.settings-panel ul{padding-left:20px}.error-panel{text-align:center;max-width:480px;margin:70px auto}.error-mark{height:40px;width:40px;border-radius:50%;display:grid;place-items:center;background:#fff0d8;color:#946315;font-size:20px;margin:0 auto 15px}.flash-stack{display:flex;flex-direction:column;gap:8px;margin-bottom:17px}.flash{padding:11px 14px;border-radius:9px;font-size:12px;border:1px solid #d9e9de;background:#eaf6ee;color:#2c6a43}.flash.error{background:#fff0ef;border-color:#f1d2d0;color:#9b3d39}.footer{text-align:center;color:#a1aaa3;font-size:10px;padding:15px 10px 25px}.login-page{display:grid;place-items:center;min-height:calc(100vh - 110px)}.login-card{width:min(100%,390px);background:#fff;border:1px solid var(--line);border-radius:17px;padding:32px;box-shadow:0 16px 45px #1e3a2b0c}.big-brand{margin-bottom:30px}.login-card h1{font-size:26px}.login-card>p{font-size:12px;margin-bottom:23px}.login-card .tiny{margin:20px 0 0;text-align:center}.login-card .form-stack{gap:17px}
@media(max-width:1050px){.topbar{gap:22px}.main-nav{gap:15px}.stats-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.content-grid{grid-template-columns:1fr}.pipeline-grid{grid-template-columns:repeat(6,205px)}.wa-grid,.team-grid{grid-template-columns:1fr}}@media(max-width:720px){.topbar{height:auto;min-height:62px;flex-wrap:wrap;padding:12px 16px;gap:10px}.brand{margin-right:auto}.user-name{display:none}.main-nav{order:3;flex-basis:100%;overflow-x:auto;gap:22px;height:36px}.main-nav a{font-size:12px;flex:none}.page{padding:25px 14px 45px}.page-heading{align-items:flex-start;flex-direction:column;margin-bottom:19px}.page-heading h1{font-size:27px}.heading-actions{width:100%}.stats-grid{gap:10px}.stat-card{padding:14px;grid-template-columns:29px 1fr;column-gap:8px}.stat-icon{width:29px;height:29px}.stat-card strong{font-size:22px}.stat-card .money{font-size:17px}.panel{padding:15px;border-radius:12px}.form-grid{grid-template-columns:1fr;gap:14px}.span-2{grid-column:auto}.form-actions{flex-wrap:wrap}.detail-fields{gap:13px}.person-heading{align-items:flex-start}.search-bar{flex-wrap:wrap}.search-bar input{flex-basis:100%}.search-bar .btn{flex:1}.pipeline-grid{grid-template-columns:repeat(6,195px)}.task-meta .priority{font-size:9px}.due{max-width:92px;text-align:right;overflow-wrap:anywhere}.deal-value{font-size:11px}.team-row{flex-wrap:wrap}.team-person{min-width:100px}.login-card{padding:25px}.login-page{min-height:calc(100vh - 150px)}.wa-grid .panel{padding:14px}}@media(max-width:380px){.stats-grid{grid-template-columns:1fr}.stat-card{grid-template-columns:34px 1fr}.stat-card strong{grid-column:2;grid-row:1/3;margin:0}.stat-card a,.stat-foot{grid-column:1/-1}.page-heading .btn{padding:9px 11px}}
/* SalesDesk pipeline refresh */
.filters{display:flex;align-items:end;gap:12px;flex-wrap:wrap;margin-bottom:18px;padding:14px 16px}.filters label{display:flex;flex-direction:column;gap:5px;min-width:155px;flex:1;font-size:11px;font-weight:700;color:#3d4e44}.filters .btn{height:37px}.chart-grid{display:grid;grid-template-columns:minmax(0,1.2fr) minmax(0,.8fr);gap:18px;margin-bottom:18px}.line-chart{display:flex;align-items:stretch;gap:10px;height:130px;padding-top:12px}.line-chart svg{width:100%;height:110px;overflow:visible}.chart-y{display:flex;flex-direction:column;justify-content:space-between;font-size:10px;color:#89958d;padding:0 0 9px}.chart-labels{display:flex;justify-content:space-between;color:#89958d;font-size:9px;padding-left:23px;gap:5px}.chart-labels span{overflow:hidden}.pie-layout{display:grid;grid-template-columns:150px minmax(0,1fr);gap:14px;align-items:center}.pie-chart{width:145px;height:145px;border-radius:50%;background:conic-gradient(#2b8059 0 14%,#4d8db7 14% 28%,#c59b45 28% 42%,#8a76b7 42% 56%,#ce8151 56% 70%,#be6660 70% 84%,#6c9a7e 84% 92%,#b7c5bc 92% 100%);display:grid;place-items:center;position:relative}.pie-chart:before{content:"";position:absolute;width:82px;height:82px;background:#fff;border-radius:50%}.pie-chart>span{position:relative;z-index:1;font-weight:800;font-size:23px;text-align:center}.pie-chart small{display:block;font-size:10px;font-weight:500;color:#7d8981}.pie-legend{display:flex;flex-direction:column;gap:6px;max-height:180px;overflow:auto}.pie-legend>div{display:grid;grid-template-columns:8px minmax(0,1fr) 20px;gap:6px;align-items:center;font-size:10px;color:#617066}.pie-legend strong{text-align:right;color:#293b30}.legend-dot{width:8px;height:8px;border-radius:50%;background:#2b8059}.legend-2{background:#4d8db7}.legend-3{background:#c59b45}.legend-4{background:#8a76b7}.legend-5{background:#ce8151}.legend-6{background:#be6660}.legend-7{background:#6c9a7e}.legend-8{background:#b7c5bc}.bar-track{width:100%;height:7px;background:#eef2ef;border-radius:99px;overflow:hidden;min-width:60px}.bar-track span{display:block;height:100%;border-radius:99px;background:#4b966d}.stage-summary{margin-bottom:18px}.deal-editor-layout{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:18px;align-items:start}.deal-editor-main{min-width:0}.wide-panel{max-width:none}.current-stage{display:flex;flex-wrap:wrap;align-items:center;gap:10px;padding:12px 14px;border-radius:10px;background:#edf4ef;border:1px solid #e0ebe2}.current-stage strong{color:#246b51;font-size:13px}.current-stage .tiny{margin-left:auto}.stage-section{border:1px solid #e3eae5;border-radius:10px;background:#fff;overflow:hidden}.stage-section summary,.history-details summary{padding:14px 15px;font-size:13px;font-weight:800;cursor:pointer;background:#f9fbf9;list-style-position:inside}.stage-section[open] summary{border-bottom:1px solid #e9efeb;margin-bottom:15px}.stage-section .form-grid{padding:0 15px 16px}.inline-input{display:flex;gap:7px;align-items:center}.inline-input select{flex:1}.btn.compact{white-space:nowrap;padding:8px 10px;font-size:11px}.customer-pane{position:sticky;top:86px;background:#fff;border:1px solid #dfe8e1;border-radius:14px;padding:18px;box-shadow:0 12px 32px #183a2812}.customer-pane[hidden]{display:none}.pane-head{display:flex;align-items:flex-start;justify-content:space-between;gap:10px}.pane-head h2{margin:0 0 8px}.close-pane{border:0;background:#eef3ef;border-radius:8px;font-size:22px;line-height:1;padding:4px 9px;cursor:pointer}.customer-pane .form-stack{margin-top:15px}.upload-form{display:flex;gap:10px;align-items:center;flex-wrap:wrap}.upload-form input{flex:1;min-width:180px}.attachment-list{display:flex;flex-direction:column;gap:9px;margin-top:15px}.attachment-list a{font-size:12px;color:#286849;overflow-wrap:anywhere}.attachment-list small{color:#88948c;margin-left:7px}.history-details{margin-top:18px;border-top:1px solid #edf1ee;padding-top:10px}.history-details summary{border-radius:8px}.value-difference{padding:12px;background:#f7f9f7;border-radius:8px;display:flex;flex-direction:column;gap:5px;font-size:11px}.value-difference strong{font-size:14px}.positive{color:#23814b}.negative{color:#bf3939}.revamped-kanban{grid-template-columns:repeat(8,minmax(205px,1fr))}.revamped-kanban .pipeline-card a{display:block}.revamped-kanban .pipeline-card{cursor:grab}.revamped-kanban .pipeline-card:active{cursor:grabbing}.pipeline-card.dragging{opacity:.4}.drop-zone{min-height:205px;border-radius:8px;transition:background .12s,box-shadow .12s}.drop-zone.drag-over{background:#dceee2;box-shadow:inset 0 0 0 2px #75aa88}.pipeline-column{min-width:0}.pipeline-title strong{font-size:11px}.stage-1{background:#64748b}.stage-2{background:#0f766e}.stage-3{background:#2563eb}.stage-4{background:#7c3aed}.stage-5{background:#a16207}.stage-6{background:#c2410c}.stage-7{background:#15803d}.stage-8{background:#b91c1c}
@media(max-width:1050px){.chart-grid{grid-template-columns:1fr}.deal-editor-layout{grid-template-columns:1fr}.customer-pane{position:relative;top:auto;order:-1}.revamped-kanban{grid-template-columns:repeat(8,205px)}}@media(max-width:720px){.filters{align-items:stretch}.filters label{min-width:100%}.filters .btn{flex:1}.pie-layout{grid-template-columns:120px minmax(0,1fr);gap:10px}.pie-chart{width:115px;height:115px}.pie-chart:before{width:65px;height:65px}.pie-chart>span{font-size:19px}.chart-grid{gap:12px}.current-stage .tiny{margin-left:0;flex-basis:100%}.inline-input{align-items:stretch}.upload-form{align-items:stretch;flex-direction:column}.upload-form input{width:100%}}
/* SalesDesk v3 requested workflow and compact 4-by-2 Kanban */
.stat-label-large{font-size:15px;font-weight:800;color:#263b30;letter-spacing:-.2px}
.stage-section{margin-bottom:12px}.stage-section.future-stage{display:none}
.revamped-kanban{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;overflow:visible;width:100%}
.revamped-kanban .pipeline-column{min-width:0;max-width:100%}.revamped-kanban .pipeline-cards{min-width:0;overflow:visible}.revamped-kanban .pipeline-card{min-width:0;max-width:100%;overflow-wrap:anywhere}.revamped-kanban .pipeline-card>a{padding:12px}.revamped-kanban .pipeline-card .kanban-deal-title{display:block;font-size:13px;line-height:1.35;margin:5px 0 8px;overflow-wrap:anywhere}.revamped-kanban .pipeline-title{display:flex;align-items:center;gap:6px;min-height:40px}.revamped-kanban .pipeline-title strong{font-size:12px;line-height:1.25;flex:1}.revamped-kanban .pipeline-value{font-size:13px;margin:7px 0}.revamped-kanban .quote-ref{white-space:normal;overflow-wrap:anywhere}.card-badges{display:flex;flex-wrap:wrap;gap:5px;margin:8px 0 2px}.mini-status{display:inline-flex;align-items:center;max-width:100%;border-radius:5px;padding:4px 6px;font-size:9px;font-weight:800;line-height:1.25;overflow-wrap:anywhere}.customer-type{background:#edf2fa;color:#526c95}.source-tag{background:#f0f3f1;color:#53655a}.attention-low{background:#e8f2ff;color:#2863a6}.attention-normal{background:#edf4ee;color:#32714e}.attention-high{background:#fff0e7;color:#bd4c21}.status-orange{background:#fff0d8;color:#a45b08}.status-blue{background:#e7f0ff;color:#245ba7}.status-green{background:#e3f6e9;color:#197344}.status-red{background:#ffebeb;color:#b52828}.status-purple{background:#f0e9ff;color:#7041aa}.location-tag{background:#edf4ef;color:#31694c}.priority-low{background:#e7f1ff;color:#2e66aa}.priority-normal{background:#edf4ee;color:#32714e}.priority-high{background:#fff0d8;color:#a45b08}.priority-urgent{background:#ffe6e6;color:#b52121}
@media(max-width:1100px){.revamped-kanban{grid-template-columns:repeat(2,minmax(0,1fr))}.revamped-kanban .pipeline-column{min-width:0}.revamped-kanban .pipeline-card{min-width:0}}
@media(max-width:620px){.revamped-kanban{grid-template-columns:minmax(0,1fr);gap:12px}.revamped-kanban .pipeline-title strong{font-size:13px}.revamped-kanban .pipeline-card-bottom{flex-wrap:wrap}}

/* Reliable drag handle: separate from the card's navigation link. */
.drag-handle{position:absolute;top:7px;right:7px;z-index:3;border:1px solid #dce6de;background:#f4f8f5;color:#526b5b;border-radius:6px;width:25px;height:25px;line-height:1;font-size:18px;cursor:grab;touch-action:none}.drag-handle:active{cursor:grabbing}.pipeline-card{position:relative;padding-top:28px}.pipeline-card .drag-handle{display:grid;place-items:center}.revamped-kanban .pipeline-card>a{padding-top:5px}.revamped-kanban .pipeline-column{min-width:0}
@media(min-width:1101px){.revamped-kanban{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:1100px){.revamped-kanban{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:620px){.revamped-kanban{grid-template-columns:minmax(0,1fr)}}

/* Customer metadata is read from the selected customer record, never re-entered on a deal. */
.customer-record-summary{display:flex;flex-wrap:wrap;gap:8px 18px;align-items:center;padding:10px 12px;border:1px solid var(--border,#dbe4dc);border-radius:10px;background:var(--surface-soft,#f7faf8);font-size:12px;color:var(--muted,#64748b)}
.customer-record-summary strong{color:var(--text,#1f2937);font-weight:650}

/* SalesDesk CRM v6: compact 4-by-2 pipeline with card-level Move To menu and deal age. */
.revamped-kanban{grid-template-columns:repeat(4,minmax(0,1fr));gap:14px;overflow:visible}
.revamped-kanban .pipeline-column{min-width:0;width:100%}
.revamped-kanban .pipeline-cards{min-width:0;overflow:visible}
.revamped-kanban .pipeline-card{padding-top:35px}
.revamped-kanban .pipeline-card>a{padding-top:4px}
.revamped-kanban .pipeline-card .drag-handle{right:auto;left:7px;top:7px;width:25px;height:25px}
.move-stage{position:absolute;top:7px;left:38px;z-index:4;width:calc(100% - 75px);max-width:145px;height:25px;padding:2px 5px;border:1px solid #dce6de;border-radius:6px;background:#f7faf8;color:#365447;font-size:10px;font-weight:700;cursor:pointer}
.age-pill{display:inline-flex;align-items:center;white-space:nowrap;border-radius:5px;background:#edf4ef;color:#32714e;padding:3px 6px;font-size:10px;font-weight:800;margin-left:auto}
.revamped-kanban .pipeline-card-bottom{gap:6px;flex-wrap:wrap}
@media(max-width:1100px){.revamped-kanban{grid-template-columns:repeat(2,minmax(0,1fr));overflow:visible}}
@media(max-width:620px){.revamped-kanban{grid-template-columns:minmax(0,1fr);gap:12px}.revamped-kanban .pipeline-title strong{font-size:13px}.revamped-kanban .pipeline-card-bottom{flex-wrap:wrap}}

/* SalesDesk v6 visual refresh inspired by Twenty CRM */
:root{--paper:#f7f8fa;--white:#fff;--ink:#222b38;--muted:#727d8c;--line:#e5e8ee;--green:#4b67d1;--green2:#3e58bd;--mint:#edf1ff;--shadow:0 2px 8px rgba(24,39,75,.045);--chart-grid:#e5e8ee}
html[data-theme="dark"]{color-scheme:dark;--ink:#e6e9ef;--muted:#9aa4b2;--line:#303744;--paper:#171a21;--white:#20242d;--green:#8ba4ff;--green2:#a3b6ff;--mint:#29334f;--blue:#29384f;--gold:#413927;--rose:#432e35;--shadow:0 3px 12px rgba(0,0,0,.22);--chart-grid:#3a414e}
html[data-theme="dark"] body{background:var(--paper);color:var(--ink)}
html[data-theme="dark"] .topbar,html[data-theme="dark"] .panel,html[data-theme="dark"] .stat-card,html[data-theme="dark"] .pipeline-column,html[data-theme="dark"] .pipeline-card,html[data-theme="dark"] .customer-pane{background:var(--white);color:var(--ink);border-color:var(--line)}
html[data-theme="dark"] input,html[data-theme="dark"] select,html[data-theme="dark"] textarea{background:#191d25;color:var(--ink);border-color:var(--line)}
html[data-theme="dark"] table th,html[data-theme="dark"] table td,html[data-theme="dark"] .stage-section,html[data-theme="dark"] .pipeline-title,html[data-theme="dark"] .pipeline-card-bottom{border-color:var(--line)}
html[data-theme="dark"] .btn.secondary,html[data-theme="dark"] .period-switch{background:#292e39;color:var(--ink);border-color:var(--line)}
html[data-theme="dark"] .person-cell small,html[data-theme="dark"] .deal-row,html[data-theme="dark"] .main-nav a{color:var(--muted)}
.theme-toggle{display:inline-flex;align-items:center;gap:6px;border:1px solid var(--line);background:var(--white);color:var(--ink);border-radius:9px;padding:7px 10px;font-size:12px;cursor:pointer;white-space:nowrap}
.period-toolbar{display:flex;align-items:center;justify-content:flex-end;gap:14px;margin:0 0 18px}.period-label{font-size:12px;color:var(--muted);font-weight:650}.period-switch{display:inline-flex;gap:3px;border:1px solid var(--line);background:var(--white);padding:3px;border-radius:11px}.period-switch button{border:0;background:transparent;color:var(--muted);padding:7px 13px;border-radius:8px;font-size:12px;font-weight:650;cursor:pointer}.period-switch button.active{background:#e8edff;color:#3e58bd}.sales-value-charts{margin-bottom:20px}.month-labels{justify-content:space-between;gap:3px}.month-labels span{font-size:10px}.closed-value-green{color:#169b62;font-weight:750}.card-controls{position:absolute;top:9px;right:9px;display:flex;align-items:center;gap:4px;z-index:2}.pipeline-card{position:relative}.drag-handle{cursor:grab}.move-stage{max-width:118px;min-width:0;padding:4px 5px;border:1px solid var(--line);border-radius:7px;background:var(--white);color:var(--muted);font-size:10px}.pipeline-card>a{display:block;padding-top:22px}.kanban-deal-title{display:block;font-size:15px;line-height:1.35;font-weight:750;letter-spacing:-.15px;padding-right:4px}.pipeline-title strong{font-size:15px;letter-spacing:-.1px}.count-pill{font-size:12px;font-weight:750;min-width:25px}.card-inline-meta{display:flex;align-items:center;gap:5px;flex-wrap:wrap;margin-top:7px}.deal-type-tag{background:#f0f1f4;color:#596273}.assignee-tag{max-width:100%;overflow-wrap:anywhere}.customer-phone{font-size:11px;color:var(--ink);font-weight:600;overflow-wrap:anywhere}.pipeline-card-bottom{display:flex;align-items:center;flex-wrap:wrap;gap:7px}.pipeline-card-bottom .age-pill{margin-left:auto}.priority-urgent{background:#fee2e2;color:#b91c1c}.priority-high{background:#ffedd5;color:#c2410c}.priority-normal{background:#eef2ff;color:#4b5fbd}.priority-low{background:#eef2f6;color:#64748b}.page-heading h1{font-size:32px}
html[data-theme="dark"] .period-switch button.active{background:#38466b;color:#dbe3ff}html[data-theme="dark"] .deal-type-tag{background:#303642;color:#c0c8d4}html[data-theme="dark"] .customer-phone{color:var(--ink)}html[data-theme="dark"] .priority-urgent{background:#512b34;color:#ffc4ca}html[data-theme="dark"] .priority-high{background:#4b3524;color:#ffd4a3}html[data-theme="dark"] .priority-normal{background:#303954;color:#c6d0ff}html[data-theme="dark"] .priority-low{background:#303642;color:#c0c8d4}
@media(max-width:1000px){.topbar{gap:16px;padding:0 16px}.main-nav{gap:12px}.user-name{display:none}.theme-toggle{padding:6px}.theme-toggle #theme-label{display:none}}
@media(max-width:620px){.period-toolbar{justify-content:space-between}.period-switch button{padding:7px 9px}.month-labels span:nth-child(even){display:none}.card-controls{right:6px}.move-stage{max-width:100px}.kanban-deal-title{font-size:14px}}

.kanban-title-row{display:flex;align-items:flex-start;gap:7px;justify-content:space-between}.kanban-title-row .kanban-deal-title{flex:1;min-width:0}.kanban-title-row .mini-status{flex-shrink:0;margin-top:1px}

/* SalesDesk v6.1: richer, consistent CRM palette and predictable layouts. */
:root{--paper:#f4f6fb;--white:#ffffff;--ink:#182230;--muted:#647184;--line:#dce3ee;--green:#3659d9;--green2:#2848bf;--mint:#e4eaff;--blue:#e2efff;--gold:#fff0c2;--rose:#ffe3e7;--shadow:0 5px 18px rgba(28,43,75,.075);--chart-grid:#d9e1ee;--accent:#3659d9;--surface-soft:#f1f5ff}
body{background:var(--paper);color:var(--ink)}
.topbar{background:var(--white);border-color:var(--line);box-shadow:0 2px 12px rgba(25,40,75,.04)}
.brand-mark{background:linear-gradient(135deg,#466bff,#7549e8);box-shadow:0 4px 10px #466bff38}
.brand-light{color:#5267b8}.main-nav a{color:#566276}.main-nav a:hover{color:#3659d9;border-color:#536fff}
.btn.primary{background:linear-gradient(135deg,#4166ed,#6045d8);box-shadow:0 3px 9px #465de52c}.btn.primary:hover{background:linear-gradient(135deg,#3154d7,#4c32c3)}
.stat-card,.panel{border-color:#dce3ee;box-shadow:var(--shadow)}.stat-card{border-top:3px solid #536fff}.stat-card:nth-child(2){border-top-color:#11a7a0}.stat-card:nth-child(3){border-top-color:#e7a126}.stat-card:nth-child(4){border-top-color:#e45e7b}
.stat-icon.sage{background:#d9f8ec;color:#087d61}.stat-icon.blue{background:#dbeafe;color:#2458d3}.stat-icon.gold{background:#ffedba;color:#9b5b00}.stat-icon.rose{background:#ffe0e7;color:#c02655}
.stat-label-large{color:#27364b}.stat-card a,.text-link{color:#3659d9}.stat-card a:hover,.text-link:hover{color:#203ca7}
.chart-grid.sales-value-charts{grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}
.sales-value-charts>.panel{min-width:0;overflow:hidden}
.line-chart{min-width:0;gap:8px}.line-chart svg{display:block;flex:1;min-width:0;width:0;overflow:visible}.chart-y{flex:0 0 32px}.month-labels{padding-left:40px;min-width:0}.month-labels span{white-space:nowrap;font-size:10px}
.period-toolbar{justify-content:flex-start;align-items:center;flex-wrap:wrap;padding:12px 14px;border:1px solid var(--line);border-radius:13px;background:var(--white);box-shadow:0 3px 12px rgba(28,43,75,.04)}
.period-label{color:#44516a}.period-switch{background:#eef2fa;border-color:#d8e0ef}.period-switch button{color:#566276}.period-switch button.active{background:#3659d9;color:#fff;box-shadow:0 2px 6px #3659d933}.period-switch button:hover:not(.active){background:#e1e8f8;color:#273b7b}
.custom-range-fields{display:flex;align-items:end;gap:9px;flex-wrap:wrap}.custom-range-fields[hidden]{display:none}.custom-range-fields label{display:flex;flex-direction:column;gap:4px;color:var(--muted);font-size:11px;font-weight:700}.custom-range-fields input{min-height:35px;padding:7px 9px;border:1px solid var(--line);border-radius:8px;background:var(--white);color:var(--ink)}
/* Keep card controls inside the card, aligned in a dedicated toolbar row. */
.revamped-kanban .pipeline-card{padding:10px!important;cursor:default;border:1px solid #dce3ee;border-top:3px solid #9aaeff;border-radius:12px;background:#fff;box-shadow:0 3px 10px rgba(30,46,83,.055);overflow:hidden;transition:transform .14s,box-shadow .14s,border-color .14s}
.revamped-kanban .pipeline-card:hover{transform:translateY(-2px);box-shadow:0 8px 20px rgba(30,46,83,.12);border-color:#a8b7f4}
.revamped-kanban .pipeline-card>a{display:block;padding:0!important}.card-controls{position:static!important;display:flex;align-items:center;gap:7px;width:100%;margin:0 0 9px;z-index:auto}.pipeline-card .drag-handle{position:static!important;display:grid;place-items:center;flex:0 0 30px;width:30px;height:30px;border:1px solid #ccd7f2;border-radius:8px;background:#eef2ff;color:#3659d9;font-size:19px;line-height:1;cursor:grab}.pipeline-card .drag-handle:hover{background:#dfe6ff}.move-stage-label{display:flex;align-items:center;gap:6px;min-width:0;flex:1;color:#66738a;font-size:10px;font-weight:750}.move-stage{position:static!important;display:block;width:100%;max-width:none!important;min-width:0;height:30px;padding:4px 7px;border:1px solid #d6deee;border-radius:8px;background:#f7f9ff;color:#34445f;font-size:11px;font-weight:700;cursor:pointer}
.pipeline-card-top{display:flex;align-items:flex-start;justify-content:space-between;gap:8px;margin-bottom:5px}.customer-heading{display:flex;flex-direction:column;gap:2px;min-width:0}.customer-heading strong{font-size:12px;line-height:1.35;font-weight:800;overflow-wrap:anywhere}.customer-heading small{font-size:11px;line-height:1.35;color:#65748a;overflow-wrap:anywhere}.card-menu{color:#7182a1;font-size:14px;flex:0 0 auto}.kanban-title-row{margin-top:5px}.revamped-kanban .pipeline-card .kanban-deal-title{font-size:14px;color:#202d42;margin:5px 0 7px}.revamped-kanban .pipeline-value{font-size:14px;color:#273eaa;font-weight:850}.card-badges{align-items:center;gap:6px;margin:8px 0 3px}.mini-status{font-size:10px;padding:5px 7px;border-radius:7px;font-weight:800;border:1px solid transparent}.customer-type{background:#e0ecff;color:#174db5;border-color:#c4d8ff}.source-tag{background:#d9f7ed;color:#08785e;border-color:#b5ebda}.attention-low{background:#dbeafe;color:#1d4ed8}.attention-normal{background:#d7f5e8;color:#087b55}.attention-high{background:#ffe2d0;color:#b83e12}.status-orange{background:#ffedc2;color:#965000;border-color:#ffdf8a}.status-blue{background:#dbeafe;color:#1e40af;border-color:#bdd5ff}.status-green{background:#d1fae5;color:#066b48;border-color:#a7f3d0}.status-red{background:#ffe0e3;color:#b4233b;border-color:#ffc2cb}.status-purple{background:#eee2ff;color:#6b21a8;border-color:#ddc5ff}.location-tag{background:#d7f7ed;color:#08785e;border-color:#b5ebda}.drawing-assignee{background:#e0e7ff;color:#3730a3;border-color:#c7d2fe}.quotation-assignee{background:#cffafe;color:#155e75;border-color:#a5f3fc}.priority-low{background:#dbeafe;color:#1d4ed8;border-color:#bfdbfe}.priority-normal{background:#d1fae5;color:#047857;border-color:#a7f3d0}.priority-high{background:#ffedd5;color:#c2410c;border-color:#fed7aa}.priority-urgent{background:#ffe0e3;color:#b4233b;border-color:#ffc2cb}
.age-pill{display:inline-flex;align-items:center;white-space:nowrap;border-radius:7px;background:#e0e7ff;color:#3730a3;border:1px solid #c7d2fe;padding:5px 7px;font-size:10px;font-weight:850;margin-left:0}.pipeline-card-bottom{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin-top:10px;padding-top:8px;border-top:1px solid #e7ebf3}.pipeline-card-bottom .created-date{margin-left:auto;font-size:10px}.revamped-kanban .pipeline-card-bottom .owner-avatar{background:#dbeafe;color:#1d4ed8}.pipeline-card.dragging{opacity:.45;transform:rotate(-1deg)}.drop-zone.drag-over{background:#e4eaff;box-shadow:inset 0 0 0 2px #536fff}.pipeline-add{display:flex;align-items:center;justify-content:center;min-height:38px;margin-top:7px;border:1px dashed #aebce1;border-radius:9px;color:#3659d9;font-size:12px;font-weight:750;background:#f7f8ff}.pipeline-add:hover{background:#e9edff}
/* Consistent, high-contrast dark mode across the entire application. */
html[data-theme="dark"]{color-scheme:dark;--paper:#101522;--white:#191f2e;--ink:#edf2ff;--muted:#a3aec3;--line:#303b52;--green:#8ca6ff;--green2:#a8b8ff;--mint:#25334d;--blue:#263754;--gold:#493923;--rose:#482b3a;--shadow:0 6px 22px rgba(0,0,0,.24);--chart-grid:#3a4660;--accent:#8ca6ff;--surface-soft:#1c2639}
html[data-theme="dark"] body{background:var(--paper);color:var(--ink)}
html[data-theme="dark"] .topbar,html[data-theme="dark"] .panel,html[data-theme="dark"] .stat-card,html[data-theme="dark"] .pipeline-column,html[data-theme="dark"] .pipeline-card,html[data-theme="dark"] .customer-pane,html[data-theme="dark"] .period-toolbar{background:var(--white);color:var(--ink);border-color:var(--line);box-shadow:var(--shadow)}
html[data-theme="dark"] .main-nav a,html[data-theme="dark"] .link-button,html[data-theme="dark"] .brand-light{color:#a9b6d0}html[data-theme="dark"] .main-nav a:hover{color:#b8c6ff;border-color:#8199ff}html[data-theme="dark"] .stat-label-large,html[data-theme="dark"] .stat-card strong,html[data-theme="dark"] .kanban-deal-title,html[data-theme="dark"] .customer-heading strong{color:#f0f4ff}html[data-theme="dark"] .customer-heading small,html[data-theme="dark"] .muted,html[data-theme="dark"] .period-label{color:#a6b1c8}
html[data-theme="dark"] input,html[data-theme="dark"] select,html[data-theme="dark"] textarea,html[data-theme="dark"] .custom-range-fields input{background:#111827;color:#edf2ff;border-color:#3b4760}html[data-theme="dark"] .btn.secondary{background:#252d40;color:#e4eaff;border-color:#3b4760}html[data-theme="dark"] .period-switch{background:#111827;border-color:#3b4760}html[data-theme="dark"] .period-switch button{color:#aab6d0}html[data-theme="dark"] .period-switch button.active{background:#536fff;color:#fff}html[data-theme="dark"] .period-switch button:hover:not(.active){background:#28344e;color:#edf2ff}
html[data-theme="dark"] .pipeline-card{background:#1b2334!important;border-color:#34425f!important;border-top-color:#7088ff!important}html[data-theme="dark"] .pipeline-card:hover{border-color:#7088ff!important}html[data-theme="dark"] .move-stage{background:#121a2a;color:#dce5ff;border-color:#3b4967}html[data-theme="dark"] .drag-handle{background:#273456!important;color:#c9d4ff!important;border-color:#485b89!important}html[data-theme="dark"] .pipeline-card-bottom{border-color:#34405a}html[data-theme="dark"] .pipeline-add{background:#1c2740;color:#b9c8ff;border-color:#4c5f91}html[data-theme="dark"] .drop-zone.drag-over{background:#24324f;box-shadow:inset 0 0 0 2px #8199ff}
html[data-theme="dark"] .customer-type{background:#233c66;color:#c4dcff;border-color:#35558a}html[data-theme="dark"] .source-tag{background:#174c48;color:#a8f4e5;border-color:#236d65}html[data-theme="dark"] .attention-low,html[data-theme="dark"] .priority-low{background:#233b63;color:#c4dcff;border-color:#35558a}html[data-theme="dark"] .attention-normal,html[data-theme="dark"] .priority-normal{background:#17483d;color:#a8f5d5;border-color:#236b59}html[data-theme="dark"] .attention-high,html[data-theme="dark"] .priority-high{background:#55351f;color:#ffd2a5;border-color:#7b4b2a}html[data-theme="dark"] .priority-urgent,html[data-theme="dark"] .status-red{background:#532636;color:#ffc1ce;border-color:#7b354c}html[data-theme="dark"] .status-orange{background:#4b391e;color:#ffdf9d;border-color:#765625}html[data-theme="dark"] .status-blue{background:#223a62;color:#c8ddff;border-color:#35558b}html[data-theme="dark"] .status-green{background:#17483d;color:#a8f5d5;border-color:#236b59}html[data-theme="dark"] .status-purple{background:#3d2b5a;color:#e4ccff;border-color:#62458c}html[data-theme="dark"] .location-tag{background:#174c48;color:#a8f4e5;border-color:#236d65}html[data-theme="dark"] .drawing-assignee{background:#302c65;color:#d5d0ff;border-color:#514b9a}html[data-theme="dark"] .quotation-assignee{background:#164854;color:#b3f4ff;border-color:#237184}html[data-theme="dark"] .age-pill{background:#28345c;color:#d3dcff;border-color:#4a5b94}
html[data-theme="dark"] .stage-section,html[data-theme="dark"] .stage-section summary,html[data-theme="dark"] .history-details summary,html[data-theme="dark"] .value-difference,html[data-theme="dark"] .customer-record-summary{background:#1b2334;color:var(--ink);border-color:var(--line)}html[data-theme="dark"] table th,html[data-theme="dark"] table td,html[data-theme="dark"] .deal-row,html[data-theme="dark"] .task-row{border-color:var(--line)}html[data-theme="dark"] .pie-chart:before{background:var(--white)}html[data-theme="dark"] .pie-legend>div,html[data-theme="dark"] .pie-legend strong{color:#d9e2f5}html[data-theme="dark"] .bar-track{background:#303b52}html[data-theme="dark"] .chart-grid line{stroke:var(--chart-grid)}html[data-theme="dark"] .theme-toggle{background:#252d40;color:#eaf0ff;border-color:#3b4760}html[data-theme="dark"] .theme-toggle:hover{background:#303b54}
.theme-toggle{border-color:var(--line);background:var(--white);color:var(--ink);font-weight:750}.theme-toggle:hover{border-color:#8298f7;background:#eef2ff}
@media(max-width:1050px){.chart-grid.sales-value-charts{grid-template-columns:minmax(0,1fr)}}
@media(max-width:720px){.period-toolbar{align-items:flex-start;gap:8px}.period-switch{max-width:100%;flex-wrap:wrap}.custom-range-fields{width:100%}.custom-range-fields label{flex:1;min-width:130px}.custom-range-fields input{width:100%}.month-labels span{font-size:9px}.revamped-kanban .pipeline-card{padding:10px!important}}

html[data-theme="dark"] .login-card,html[data-theme="dark"] .empty-state,html[data-theme="dark"] .empty-inline,html[data-theme="dark"] .notes-box,html[data-theme="dark"] .message-mini,html[data-theme="dark"] .search-bar,html[data-theme="dark"] .filters,html[data-theme="dark"] .flash,html[data-theme="dark"] .value-difference,html[data-theme="dark"] .notes-box,html[data-theme="dark"] .table-wrap{background:#1b2334;color:#e8efff;border-color:#303b52}
html[data-theme="dark"] .stage-pill{background:#2c3854;color:#d9e3ff}html[data-theme="dark"] .deal-value,html[data-theme="dark"] .stat-foot,html[data-theme="dark"] .detail-fields small,html[data-theme="dark"] .person-cell small{color:#a9b6d0}html[data-theme="dark"] .eyebrow{color:#9caeff}html[data-theme="dark"] .current-stage{background:#1b3a38;border-color:#285e58}html[data-theme="dark"] .current-stage strong{color:#a8f5df}html[data-theme="dark"] .btn.secondary:hover{background:#303b54}

/* v6.2 readability and card alignment refinements */
.period-toolbar{justify-content:flex-start;gap:12px}
.period-select{min-width:170px;min-height:38px;padding:8px 34px 8px 11px;border:1px solid #cbd5ee;border-radius:9px;background:#f7f8ff;color:#273b7b;font-weight:750;font-size:12px;cursor:pointer}
html[data-theme="dark"] .period-select{background:#111827;color:#edf2ff;border-color:#3b4760}
html[data-theme="dark"] .stage-summary table td,html[data-theme="dark"] .stage-summary table td strong{color:#edf2ff!important}
html[data-theme="dark"] .person-cell strong,html[data-theme="dark"] .person-heading h1,html[data-theme="dark"] .customer-record-summary strong{color:#f0f4ff!important}
html[data-theme="dark"] .person-cell small,html[data-theme="dark"] .customer-record-summary{color:#c4cee2!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card .kanban-deal-title{color:#f0f4ff!important}
html[data-theme="dark"] .pipeline-card-top .customer-heading strong{color:#f0f4ff!important}
/* Keep legacy green/mint customer accents consistent with the blue-violet CRM palette. */
.avatar,.deal-avatar,.user-dot{background:#e1e8ff;color:#3659d9}
.closed-value-green{color:#16a36a}
html[data-theme="dark"] .avatar,html[data-theme="dark"] .deal-avatar,html[data-theme="dark"] .user-dot{background:#273456;color:#c9d4ff}
.pipeline-title .count-pill{display:grid;place-items:center;flex:0 0 28px;width:28px;height:28px;min-width:28px;padding:0;text-align:center;line-height:1;border-radius:8px;background:#e4e9ff;color:#304ed0;font-variant-numeric:tabular-nums}
html[data-theme="dark"] .pipeline-title .count-pill{background:#273456;color:#e0e7ff}
.card-controls{gap:5px;white-space:nowrap}
.pipeline-card .drag-handle{flex:0 0 28px;width:28px;height:30px;padding:0;line-height:30px;text-align:center;font-size:18px;place-items:center;align-content:center;justify-content:center}
.move-stage-label{gap:4px;flex:1 1 auto;white-space:nowrap;overflow:visible;font-size:10px}
.move-stage-label>span{flex:0 0 auto;white-space:nowrap}
.move-stage{flex:1 1 92px;min-width:92px;width:92px;max-width:92px;padding:4px 5px;font-size:10px;white-space:nowrap}
.revamped-kanban .pipeline-card .kanban-deal-title{font-size:16px;line-height:1.3}
.pipeline-card-top .customer-heading strong{font-size:13px}
.pipeline-value{margin-bottom:1px}
.closed-potential-value{font-size:10px;line-height:1.3;font-weight:700;color:#697a99;margin-top:-1px;margin-bottom:5px}
html[data-theme="dark"] .closed-potential-value{color:#b5c2df}
.pipeline-card-bottom{display:flex;align-items:center;flex-wrap:wrap;gap:5px 7px;margin-top:9px;padding-top:8px;font-size:11px;color:#66738a}
.pipeline-card-bottom .owner-avatar{width:20px;height:20px;flex:0 0 20px;font-size:10px;display:grid;place-items:center;border-radius:6px}
.pipeline-card-bottom .owner-name{font-size:11.5px;font-weight:750;color:#52627e}
.pipeline-card-bottom .created-date,.pipeline-card-bottom .deal-age-meta{font-size:10.5px;font-weight:550;color:#66738a;white-space:nowrap}
.pipeline-card-bottom .created-date{margin-left:0}
html[data-theme="dark"] .pipeline-card-bottom,html[data-theme="dark"] .pipeline-card-bottom .owner-name,html[data-theme="dark"] .pipeline-card-bottom .created-date,html[data-theme="dark"] .pipeline-card-bottom .deal-age-meta{color:#c4cee2}
.card-stage-number{font-size:10px;font-weight:700;letter-spacing:.2px;color:#7180a2;text-align:right;padding:1px 4px 6px}
html[data-theme="dark"] .card-stage-number{color:#aab9df}
@media(max-width:720px){.period-select{max-width:100%;width:100%}.pipeline-card-bottom{gap:5px}.move-stage{min-width:88px;width:88px;max-width:88px}}

/* SalesDesk v6.3: distinct date-range controls, blue-violet cards, aligned metadata. */
.reporting-controls{display:grid;grid-template-columns:minmax(250px,max-content) minmax(360px,1fr);gap:12px;align-items:stretch;margin:0 0 20px}
.period-toolbar,.custom-range-toolbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:0;padding:12px 14px;border:1px solid var(--line);border-radius:12px;background:var(--white);box-shadow:0 3px 12px rgba(28,43,75,.04)}
.period-toolbar .period-select{min-width:150px;max-width:180px}
.custom-range-toolbar .period-label{white-space:nowrap;margin-right:2px}
.custom-range-toolbar label{display:flex;align-items:center;gap:7px;color:var(--muted);font-size:11px;font-weight:700;white-space:nowrap}
.custom-range-toolbar input{width:155px;min-height:38px}
.custom-range-toolbar .btn{min-height:38px}
html[data-theme="dark"] .period-toolbar,html[data-theme="dark"] .custom-range-toolbar{background:var(--white);border-color:var(--line)}
/* Use neutral slate and indigo rather than the legacy mint-tinted Kanban surface. */
.revamped-kanban .pipeline-column{background:#edf0f8;border-color:#d7deed;border-radius:13px}
.revamped-kanban .pipeline-card{background:#fff;border:1px solid #dce3f1;border-top:3px solid #778df2;box-shadow:0 3px 9px rgba(34,49,91,.07)}
.revamped-kanban .pipeline-card:hover{background:#fbfcff;border-color:#8a9df4}
.revamped-kanban .pipeline-value{color:#344fc5;font-size:15px;font-weight:850;letter-spacing:-.1px;overflow-wrap:anywhere}
.revamped-kanban .closed-potential-value{font-size:11px;line-height:1.3;font-weight:650;color:#66738b;margin-top:-1px;margin-bottom:5px}
.revamped-kanban .closed-potential-value s{text-decoration-thickness:1.5px;text-decoration-color:#9aa6bd}
.revamped-kanban .pipeline-card-bottom{display:flex;flex-direction:column;align-items:stretch;gap:7px;margin-top:10px;padding-top:9px;border-top:1px solid #e2e7f2}
.revamped-kanban .owner-meta{display:flex;align-items:center;gap:7px;min-width:0}
.revamped-kanban .owner-meta .owner-name{min-width:0;overflow-wrap:anywhere;font-size:11.5px;font-weight:750;color:#52627e}
.revamped-kanban .deal-meta{display:flex;justify-content:flex-end;align-items:center;gap:10px;flex-wrap:wrap;width:100%;text-align:right;font-size:11px;line-height:1.4}
.revamped-kanban .pipeline-card-bottom .created-date,.revamped-kanban .pipeline-card-bottom .deal-age-meta{font-size:11px;font-weight:550;color:#66738a;white-space:nowrap}
.revamped-kanban .card-stage-number{align-self:flex-end;font-size:10px;font-weight:800;letter-spacing:.25px;color:#5267c5;background:#edf1ff;border:1px solid #d9e1ff;border-radius:6px;padding:2px 7px;line-height:1.4}
.revamped-kanban .column-stage-number{display:flex;justify-content:center;align-items:center;min-height:30px;margin-top:9px;padding:6px 8px;border:1px dashed #aab8e0;border-radius:8px;background:#e7ebf8;color:#5368bc;font-size:10px;font-weight:800;letter-spacing:.3px}
.revamped-kanban .pipeline-add{background:#f7f8ff;border-color:#b9c5e8;color:#3659d9}
html[data-theme="dark"] .revamped-kanban .pipeline-column{background:#151c2b!important;border-color:#303b52!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card{background:#1d2638!important;border-color:#3b4967!important;border-top-color:#8198ff!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card:hover{background:#222e45!important;border-color:#8198ff!important}
html[data-theme="dark"] .revamped-kanban .pipeline-value{color:#c6d2ff!important}
html[data-theme="dark"] .revamped-kanban .closed-potential-value{color:#aebbd5!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card-bottom{border-color:#35415a!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card-bottom .owner-name,html[data-theme="dark"] .revamped-kanban .pipeline-card-bottom .created-date,html[data-theme="dark"] .revamped-kanban .pipeline-card-bottom .deal-age-meta{color:#c4cee2!important}
html[data-theme="dark"] .revamped-kanban .card-stage-number{background:#283456;color:#d6dfff;border-color:#465a91}
html[data-theme="dark"] .revamped-kanban .column-stage-number{background:#202b43;color:#c9d5ff;border-color:#465a91}
html[data-theme="dark"] .revamped-kanban .pipeline-add{background:#1c2740;color:#c9d5ff;border-color:#4c5f91}
.team-count-pill{display:inline-grid;place-items:center;flex:0 0 30px;width:30px;height:30px;min-width:30px;padding:0;text-align:center;line-height:1;font-variant-numeric:tabular-nums;border-radius:8px;background:#e4e9ff;color:#304ed0}
html[data-theme="dark"] .team-count-pill{background:#273456;color:#e0e7ff}
.team-actions{display:flex;align-items:center;justify-content:flex-end;gap:5px;flex-wrap:wrap}
.team-actions form{margin:0}
.impersonation-banner{position:sticky;top:68px;z-index:6;display:flex;align-items:center;justify-content:center;gap:10px;flex-wrap:wrap;padding:10px 16px;background:#fff0c2;color:#704b00;border-bottom:1px solid #e7c768;font-size:12px}
.impersonation-banner form{margin:0}
.impersonation-banner button{border:1px solid #a77912;border-radius:7px;padding:5px 9px;background:#fff9e6;color:#704b00;font-size:11px;font-weight:800;cursor:pointer}
html[data-theme="dark"] .impersonation-banner{background:#493923;color:#ffe4a3;border-color:#80632e}
html[data-theme="dark"] .impersonation-banner button{background:#302617;color:#ffe4a3;border-color:#80632e}
@media(max-width:1050px){.reporting-controls{grid-template-columns:1fr}.period-toolbar,.custom-range-toolbar{width:100%}}
@media(max-width:620px){.custom-range-toolbar{align-items:stretch}.custom-range-toolbar .period-label{width:100%}.custom-range-toolbar label{flex:1;min-width:130px;align-items:flex-start;flex-direction:column}.custom-range-toolbar input{width:100%}.revamped-kanban .deal-meta{justify-content:flex-start;text-align:left;gap:5px 10px}.impersonation-banner{top:0}}

/* SalesDesk v6.4: one-line controls and compact, aligned Kanban card metadata. */
.period-toolbar{flex-wrap:nowrap;white-space:nowrap;gap:10px}
.period-toolbar .period-label{flex:0 0 auto;white-space:nowrap}
.period-toolbar .period-select{flex:0 0 150px;min-width:150px}
.period-toolbar .btn{flex:0 0 auto;min-width:82px;white-space:nowrap}
.period-toolbar .btn.primary{background:var(--primary,#4b5fd7);color:#fff;border-color:var(--primary,#4b5fd7)}
html[data-theme="dark"] .period-toolbar .btn.primary{background:#6378f4;color:#fff;border-color:#6378f4}
.user-menu .theme-toggle{order:0}
.user-menu .user-dot{order:1}
.user-menu .user-name{order:2}
.user-menu .link-button,.user-menu form{order:3}
.revamped-kanban .kanban-deal-title{font-size:15px!important;line-height:1.32;font-weight:850;letter-spacing:-.15px;overflow-wrap:anywhere}
.revamped-kanban .kanban-title-row{margin-bottom:3px}
.revamped-kanban .card-stage-number{display:block;align-self:flex-start;width:max-content;max-width:100%;margin:0 0 7px;padding:1px 6px;border:0;border-radius:4px;background:transparent;color:#7784a1;font-size:9px;font-weight:750;letter-spacing:.15px;line-height:1.3;text-align:left}
html[data-theme="dark"] .revamped-kanban .card-stage-number{background:transparent;color:#aab9df;border:0}
.revamped-kanban .pipeline-card-bottom{display:flex;flex-direction:row;align-items:center;justify-content:space-between;flex-wrap:nowrap;gap:6px;margin-top:10px;padding-top:8px;border-top:1px solid #e2e7f2;min-width:0}
.revamped-kanban .owner-meta{display:flex;align-items:center;gap:5px;flex:0 1 auto;min-width:0;white-space:nowrap}
.revamped-kanban .owner-meta .owner-avatar{flex:0 0 18px;width:18px;height:18px}
.revamped-kanban .owner-meta .owner-name{display:block;min-width:0;max-width:86px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:10px;line-height:1.2}
.revamped-kanban .deal-meta{display:flex;flex:0 0 auto;justify-content:flex-end;align-items:center;gap:7px;flex-wrap:nowrap;width:auto;min-width:0;text-align:right;font-size:9px;line-height:1.25;white-space:nowrap}
.revamped-kanban .pipeline-card-bottom .created-date,.revamped-kanban .pipeline-card-bottom .deal-age-meta{font-size:9px;font-weight:550;color:#66738a;white-space:nowrap}
html[data-theme="dark"] .revamped-kanban .pipeline-card-bottom .created-date,html[data-theme="dark"] .revamped-kanban .pipeline-card-bottom .deal-age-meta,html[data-theme="dark"] .revamped-kanban .pipeline-card-bottom .owner-name{color:#c4cee2!important}
@media(max-width:1050px){.period-toolbar{flex-wrap:wrap;white-space:normal}}
@media(max-width:620px){.period-toolbar{align-items:stretch}.period-toolbar .period-label{width:100%}.period-toolbar .period-select{flex:1 1 150px}.revamped-kanban .pipeline-card-bottom{gap:5px}.revamped-kanban .owner-meta .owner-name{max-width:62px}.revamped-kanban .deal-meta{gap:5px}.revamped-kanban .pipeline-card-bottom .created-date,.revamped-kanban .pipeline-card-bottom .deal-age-meta{font-size:8.5px}}


/* SalesDesk v6.5: plain compact stage caption aligned with each column heading. */
.revamped-kanban .column-stage-number{display:block;min-height:0;margin:2px 0 10px;padding:0 2px 0 14px;border:0;border-radius:0;background:transparent;color:#7180a2;font-size:11px;font-weight:600;letter-spacing:0;line-height:1.4;text-align:left;box-shadow:none}
html[data-theme="dark"] .revamped-kanban .column-stage-number{background:transparent;color:#aab9df;border:0}

/* Per-user assignment notifications in the header. */
.notification-wrap{position:relative;display:flex;align-items:center}
.notification-toggle{position:relative;display:grid;place-items:center;width:35px;height:35px;border:1px solid var(--line);border-radius:10px;background:var(--white);color:var(--ink);cursor:pointer;font-size:20px;line-height:1}
.notification-toggle:hover,.notification-toggle[aria-expanded="true"]{border-color:#8196f4;background:#eef2ff}
.bell-icon{display:block;transform:rotate(-8deg);font-size:20px}
.notification-count{position:absolute;top:-6px;right:-6px;min-width:18px;height:18px;padding:0 4px;border:2px solid var(--white);border-radius:999px;background:#e32945;color:#fff;font-size:10px;font-weight:850;line-height:14px;text-align:center;box-shadow:0 1px 4px #0002}
.notification-panel{position:absolute;top:calc(100% + 12px);right:-40px;width:min(370px,calc(100vw - 24px));max-height:min(540px,calc(100vh - 100px));overflow:auto;border:1px solid var(--line);border-radius:14px;background:var(--white);color:var(--ink);box-shadow:0 16px 45px rgba(15,25,45,.2);z-index:20;animation:notification-slide .16s ease-out}
@keyframes notification-slide{from{opacity:0;transform:translateY(-6px)}to{opacity:1;transform:translateY(0)}}
.notification-panel-head{position:sticky;top:0;display:flex;align-items:center;justify-content:space-between;gap:10px;padding:14px 16px;border-bottom:1px solid var(--line);background:var(--white);z-index:1}
.notification-panel-head strong{font-size:13px}.notification-panel-head span{font-size:10px;color:var(--muted)}
.notification-item{display:flex;gap:10px;padding:12px 14px;border-bottom:1px solid var(--line);text-decoration:none;align-items:flex-start}
.notification-item:last-child{border-bottom:0}.notification-item:hover{background:#f4f6ff}.notification-item.unread{background:#f0f3ff}
.notification-item-dot{width:8px;height:8px;flex:0 0 8px;margin-top:5px;border-radius:50%;background:#e32945}.notification-item:not(.unread) .notification-item-dot{background:transparent;border:1px solid var(--line)}
.notification-item-content{display:flex;flex-direction:column;gap:4px;min-width:0}.notification-item-content strong{font-size:11px}.notification-item-content span{font-size:11px;font-weight:700;overflow-wrap:anywhere}.notification-item-content small{font-size:10px;line-height:1.45;color:var(--muted);overflow-wrap:anywhere}.notification-empty{padding:24px 18px;text-align:center;color:var(--muted);font-size:11px;line-height:1.6}
html[data-theme="dark"] .notification-toggle{background:#252d40;color:#eaf0ff;border-color:#3b4760}
html[data-theme="dark"] .notification-toggle:hover,html[data-theme="dark"] .notification-toggle[aria-expanded="true"]{background:#303b58;border-color:#6579bd}
html[data-theme="dark"] .notification-count{border-color:var(--white)}
html[data-theme="dark"] .notification-item:hover{background:#272f42}html[data-theme="dark"] .notification-item.unread{background:#252d43}
@media(max-width:720px){.notification-panel{right:-85px}.notification-toggle{width:32px;height:32px}.user-menu{gap:7px}}

/* v6.6 workflow styling */
.revamped-kanban .pipeline-title strong{font-size:14px;font-weight:850;letter-spacing:-.15px}
.revamped-kanban .pipeline-card.stage-card-1{border-top-color:#778df2!important}
.revamped-kanban .pipeline-card.stage-card-2{border-top-color:#6893c3!important}
.revamped-kanban .pipeline-card.stage-card-3{border-top-color:#c69b47!important}
.revamped-kanban .pipeline-card.stage-card-4{border-top-color:#9a83c5!important}
.revamped-kanban .pipeline-card.stage-card-5{border-top-color:#3c9b69!important}
.revamped-kanban .pipeline-card.stage-card-6{border-top-color:#c7746d!important}
.kanban-updates{margin-top:9px;padding-top:8px;border-top:1px solid #e2e7f2;display:flex;flex-direction:column;gap:6px}
.kanban-updates>strong{font-size:10px;color:#5368bc;font-weight:850}
.kanban-update{display:flex;flex-direction:column;gap:2px;padding:6px 7px;border-radius:7px;background:#f5f7ff;overflow-wrap:anywhere}
.kanban-update span{font-size:10px;line-height:1.35;color:#34415a;white-space:pre-wrap}
.kanban-update small{font-size:9px;color:#7783a0}
html[data-theme="dark"] .kanban-updates{border-color:#35415a}
html[data-theme="dark"] .kanban-updates>strong{color:#b9c8ff}
html[data-theme="dark"] .kanban-update{background:#202b43}
html[data-theme="dark"] .kanban-update span{color:#e0e7ff}
html[data-theme="dark"] .kanban-update small{color:#aab9df}


/* SalesDesk v6.7: avatar-based notifications and a single-row six-stage pipeline. */
.notification-wrap{position:relative;display:flex;align-items:center;flex:0 0 auto}
.team-avatar-toggle{position:relative;display:grid;place-items:center;width:35px;height:35px;padding:0;border:0;border-radius:50%;background:transparent;cursor:pointer;flex:0 0 35px}
.team-avatar-toggle .user-dot{width:32px;height:32px;border:2px solid var(--white);box-shadow:0 0 0 1px var(--line);transition:box-shadow .15s,transform .15s}
.team-avatar-toggle:hover .user-dot,.team-avatar-toggle[aria-expanded="true"] .user-dot{box-shadow:0 0 0 2px #8196f4;transform:scale(1.03)}
.team-avatar-toggle .notification-count{top:-2px;right:-3px;z-index:2;min-width:19px;height:19px;line-height:15px}
.notification-panel{right:0;width:min(520px,calc(100vw - 24px));max-width:calc(100vw - 24px);overflow-x:hidden;overflow-y:auto;overscroll-behavior:contain}
.notification-item{min-width:0}
.notification-item-content{flex:1 1 auto;overflow-wrap:anywhere;word-break:break-word}
.notification-item-content strong,.notification-item-content span,.notification-item-content small{max-width:100%;white-space:normal;overflow-wrap:anywhere;word-break:break-word}
@media(min-width:1301px){.pipeline-grid.revamped-kanban{grid-template-columns:repeat(6,minmax(0,1fr));overflow-x:visible}}
@media(max-width:1300px){.pipeline-grid.revamped-kanban{grid-template-columns:repeat(6,minmax(185px,1fr));overflow-x:auto;overflow-y:hidden}}
@media(max-width:720px){.notification-panel{right:0;width:min(520px,calc(100vw - 24px));max-width:calc(100vw - 24px)}.team-avatar-toggle{width:32px;height:32px;flex-basis:32px}.team-avatar-toggle .user-dot{width:29px;height:29px}}


/* SalesDesk v6.8: scrollable active stages and collapsible completed/lost archives. */
.pipeline-active-scroll{width:100%;max-width:100%;overflow-x:auto;overflow-y:hidden;padding:0 0 12px;overscroll-behavior-x:contain;scrollbar-gutter:stable}
.pipeline-grid.revamped-kanban{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(245px,1fr);grid-template-columns:none;gap:12px;width:max-content;min-width:100%;overflow:visible;padding:0 0 4px;align-items:start}
.pipeline-grid.revamped-kanban .pipeline-column{width:auto;min-width:245px;max-width:330px;min-height:260px}
.pipeline-archive-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin-top:16px;align-items:start}
.pipeline-archive{min-width:0;overflow:hidden;border:1px solid #d7deed;border-radius:13px;background:#edf0f8}
.pipeline-archive-summary{display:flex;align-items:center;gap:9px;min-height:54px;padding:12px 14px;cursor:pointer;list-style:none;color:var(--ink)}
.pipeline-archive-summary::-webkit-details-marker{display:none}
.pipeline-archive-summary::marker{content:""}
.pipeline-archive-summary strong{font-size:13px;font-weight:850;letter-spacing:-.1px}
.pipeline-archive-summary .count-pill{margin-left:auto}
.archive-toggle-label{font-size:11px;color:#5368bc;font-weight:700;white-space:nowrap}
.archive-chevron{font-size:18px;color:#5368bc;transition:transform .15s}
.pipeline-archive[open] .archive-chevron{transform:rotate(180deg)}
.pipeline-archive[open] .archive-toggle-label{font-size:0}
.pipeline-archive[open] .archive-toggle-label::after{content:"Hide records";font-size:11px}
.pipeline-archive-content{border-top:1px solid #d7deed;padding:10px;max-height:65vh;overflow:auto;overscroll-behavior:contain}
.pipeline-archive-content .pipeline-column{min-height:0;padding:0;border:0;background:transparent!important;box-shadow:none}
.pipeline-archive-content .pipeline-title{display:none}
.pipeline-archive-content .column-stage-number{margin:0 0 8px;padding:0}
.pipeline-archive-content .pipeline-cards{max-height:calc(65vh - 40px);overflow-y:auto;padding:1px 4px 4px 1px;overscroll-behavior:contain}
.pipeline-archive-content .pipeline-card{max-width:none}
html[data-theme="dark"] .pipeline-archive{background:#151c2b;border-color:#303b52}
html[data-theme="dark"] .pipeline-archive-summary{color:#eaf0ff}
html[data-theme="dark"] .pipeline-archive-content{border-color:#303b52}
html[data-theme="dark"] .pipeline-archive-content .pipeline-column{background:transparent!important}
@media(max-width:720px){.pipeline-grid.revamped-kanban{grid-auto-columns:minmax(250px,82vw)}.pipeline-grid.revamped-kanban .pipeline-column{min-width:250px;max-width:none}.pipeline-archive-grid{grid-template-columns:minmax(0,1fr)}.pipeline-archive-content{max-height:60vh}.pipeline-archive-content .pipeline-cards{max-height:calc(60vh - 40px)}}

/* SalesDesk v6.9: reporting polish, compact responsive pipeline, previews and notification history. */
.custom-range-toolbar{display:flex;flex-wrap:nowrap;min-width:0;gap:9px}
.custom-range-toolbar .period-label{flex:0 0 auto}
.custom-range-toolbar label{flex:0 1 auto}
.custom-range-toolbar input{background:#f0edff;border-color:#d8d0ff;color:#302b54;color-scheme:light}
.custom-range-toolbar .custom-apply,.period-toolbar .btn{min-width:82px;min-height:38px;height:38px;padding:0 15px}
.custom-range-toolbar .generate-pdf{margin-left:auto;min-height:38px;height:38px;background:#fff;border-color:#d8d0ff;color:#5045a8}
.custom-range-toolbar .generate-pdf:hover{background:#f0edff}
.period-toolbar .period-select{background:#f0edff;border-color:#d8d0ff;color:#302b54;color-scheme:light;min-height:38px;height:38px}
html[data-theme="dark"] .custom-range-toolbar input,html[data-theme="dark"] .period-toolbar .period-select{background:#29253f;border-color:#4a426d;color:#f0edff;color-scheme:dark}
html[data-theme="dark"] .custom-range-toolbar .generate-pdf{background:#28243c;border-color:#4a426d;color:#d9d2ff}
@media(max-width:1050px){.custom-range-toolbar{flex-wrap:wrap}.custom-range-toolbar .generate-pdf{margin-left:auto}}
@media(max-width:620px){.custom-range-toolbar{align-items:stretch}.custom-range-toolbar .period-label{width:100%}.custom-range-toolbar label{min-width:0;flex:1 1 120px}.custom-range-toolbar .custom-apply,.custom-range-toolbar .generate-pdf{flex:1 1 auto;margin-left:0}}
.dashboard-lower-grid{grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}
.dashboard-equal-panel{height:100%;min-height:355px;display:flex;flex-direction:column}
.dashboard-equal-panel .pie-layout,.dashboard-equal-panel .top-closed-list{flex:1}
.top-closed-list{display:flex;flex-direction:column;min-width:0}
.top-closed-row{display:flex;align-items:center;gap:10px;padding:10px 0;border-bottom:1px solid #edf0f8;min-width:0;flex:1}
.top-closed-row:last-child{border-bottom:0}
.top-closed-rank{display:grid;place-items:center;width:27px;height:27px;flex:0 0 27px;border-radius:8px;background:#f0edff;color:#5549ad;font-size:11px;font-weight:850}
.top-closed-main{display:flex;flex-direction:column;gap:2px;min-width:0;flex:1}
.top-closed-main strong,.top-closed-main span{font-size:11px;overflow-wrap:anywhere}
.top-closed-main small{font-size:10px;color:var(--muted);overflow-wrap:anywhere}
.top-closed-value{font-size:11px;white-space:nowrap;color:#4d459a}
.compact-empty{padding:15px}
html[data-theme="dark"] .top-closed-row{border-color:#303b52}
html[data-theme="dark"] .top-closed-rank{background:#292541;color:#d9d2ff}
html[data-theme="dark"] .top-closed-value{color:#d9d2ff}
@media(max-width:760px){.dashboard-lower-grid{grid-template-columns:minmax(0,1fr)}.dashboard-equal-panel{min-height:0}}

/* Four equal active columns; no horizontal scrolling on the desktop pipeline. */
.pipeline-active-scroll{overflow:visible;padding-bottom:4px;scrollbar-gutter:auto}
.pipeline-grid.revamped-kanban{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-auto-flow:initial;grid-auto-columns:initial;width:100%;min-width:0;overflow:visible;gap:12px}
.pipeline-grid.revamped-kanban .pipeline-column{min-width:0;max-width:none;width:100%}
.revamped-kanban .pipeline-column{background:#f0edff;border-color:#ded8ff}
.revamped-kanban .pipeline-card{border-top:3px solid var(--stage-color,#778df2);background:var(--stage-tint,#fff);border-color:color-mix(in srgb,var(--stage-color,#778df2) 24%,#fff);border-top-color:var(--stage-color,#778df2)}
.revamped-kanban .pipeline-card:hover{background:var(--stage-hover,#fbfaff);border-color:var(--stage-color,#778df2)}
.revamped-kanban .pipeline-card.stage-card-1{--stage-color:#778df2;--stage-tint:#f5f6ff;--stage-hover:#ecefff}
.revamped-kanban .pipeline-card.stage-card-2{--stage-color:#6893c3;--stage-tint:#f0f6ff;--stage-hover:#e7f0ff}
.revamped-kanban .pipeline-card.stage-card-3{--stage-color:#c69b47;--stage-tint:#fff9eb;--stage-hover:#fff2d2}
.revamped-kanban .pipeline-card.stage-card-4{--stage-color:#9a83c5;--stage-tint:#f7f1ff;--stage-hover:#efe5ff}
.revamped-kanban .pipeline-card.stage-card-5{--stage-color:#3c9b69;--stage-tint:#eefaf2;--stage-hover:#def4e6}
.revamped-kanban .pipeline-card.stage-card-6{--stage-color:#c7746d;--stage-tint:#fff2f0;--stage-hover:#ffe5e1}
.revamped-kanban .pipeline-card .pipeline-value{color:color-mix(in srgb,var(--stage-color,#778df2) 78%,#18213a)}
.revamped-kanban .pipeline-title{gap:7px;min-width:0;flex-wrap:nowrap}
.revamped-kanban .pipeline-title strong{min-width:0;overflow-wrap:anywhere}
.revamped-kanban .pipeline-title .count-pill{margin-left:auto;flex:0 0 auto}
.stage-collapse-toggle{display:none;place-items:center;width:24px;height:24px;flex:0 0 24px;padding:0;border:1px solid #d9d2ff;border-radius:7px;background:#fff;color:#5549ad;font-size:16px;font-weight:800;line-height:1;cursor:pointer}
.pipeline-archive{background:#f0edff;border-color:#ded8ff}
.pipeline-archive-summary{gap:8px}
.pipeline-archive-summary .count-pill{margin-left:auto}
.pipeline-archive-content .revamped-kanban .pipeline-column{background:transparent!important}
.pipeline-archive-content .pipeline-card{border-top-color:var(--stage-color,#778df2)!important}
html[data-theme="dark"] .revamped-kanban .pipeline-column,html[data-theme="dark"] .pipeline-archive{background:#1d2032!important;border-color:#3b3b59!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card{background:#20283a!important;border-color:color-mix(in srgb,var(--stage-color,#778df2) 55%,#35405b)!important;border-top-color:var(--stage-color,#778df2)!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card:hover{background:#273148!important}
html[data-theme="dark"] .stage-collapse-toggle{background:#292541;border-color:#4a426d;color:#e0d9ff}
@media(min-width:761px){.pipeline-column.mobile-collapsed .pipeline-cards{display:flex!important}}
@media(max-width:1100px) and (min-width:761px){.pipeline-grid.revamped-kanban{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){.pipeline-grid.revamped-kanban{grid-template-columns:minmax(0,1fr);gap:10px}.pipeline-grid.revamped-kanban .pipeline-column{min-width:0;max-width:none;min-height:0}.stage-collapse-toggle{display:grid}.pipeline-column.mobile-collapsed .pipeline-cards{display:none}.pipeline-column.mobile-collapsed .stage-collapse-toggle{transform:none}.pipeline-archive-grid{grid-template-columns:minmax(0,1fr)}.pipeline-archive-content{max-height:60vh}.pipeline-archive-content .pipeline-cards{max-height:calc(60vh - 40px)}.pipeline-archive-summary .archive-toggle-label{margin-left:0}.pipeline-archive-summary .count-pill{margin-left:auto}}

/* Attachment side preview and safe download/delete actions. */
.attachment-workspace{display:grid;grid-template-columns:minmax(0,1fr);gap:14px;align-items:start}
.attachment-list{display:flex;flex-direction:column;gap:7px;min-width:0}
.attachment-row{display:flex;align-items:center;gap:8px;min-width:0;padding:8px;border:1px solid var(--line);border-radius:9px;background:#f8f6ff}
.attachment-row form{margin-left:auto;flex:0 0 auto}
.attachment-open{display:flex;align-items:center;gap:8px;min-width:0;flex:1;border:0;background:transparent;text-align:left;cursor:pointer;color:#51478f;padding:3px}
.attachment-open span{min-width:0;overflow-wrap:anywhere;font-size:12px;font-weight:750}
.attachment-open small{flex:0 0 auto;font-size:10px;color:var(--muted)}
.attachment-delete{border:1px solid #f0c9ce;background:#fff3f4;color:#a33c4c;border-radius:7px;padding:6px 9px;font-size:10px;font-weight:800;cursor:pointer}
.attachment-viewer{border:1px solid #dcd6ff;border-radius:12px;background:#faf9ff;overflow:hidden;min-width:0}
.attachment-viewer-head{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 12px;background:#f0edff;border-bottom:1px solid #dcd6ff}
.attachment-viewer-head>strong{min-width:0;overflow-wrap:anywhere;font-size:12px}
.attachment-viewer-actions{display:flex;align-items:center;gap:7px;flex:0 0 auto}
.attachment-preview{height:min(65vh,650px);min-height:180px;display:grid;place-items:center;padding:10px;overflow:auto}
.attachment-preview img{display:block;max-width:100%;max-height:60vh;object-fit:contain;border-radius:6px}
.attachment-preview iframe{width:100%;height:60vh;min-height:400px;border:0;background:#fff}
html[data-theme="dark"] .attachment-row,html[data-theme="dark"] .attachment-viewer{background:#20283a;border-color:#3b3b59}
html[data-theme="dark"] .attachment-open{color:#d9d2ff}
html[data-theme="dark"] .attachment-viewer-head{background:#292541;border-color:#3b3b59}
@media(min-width:1000px){.attachment-workspace{grid-template-columns:minmax(260px,.8fr) minmax(0,1.2fr)}.attachment-viewer{position:sticky;top:85px}}

/* Notification history and dropdown actions. */
.notification-panel-head{align-items:center}
.notification-panel-actions{display:flex;align-items:center;justify-content:flex-end;gap:7px;flex-wrap:wrap;min-width:0}
.notification-action{display:inline-flex;align-items:center;justify-content:center;border:1px solid #d8d0ff;border-radius:7px;padding:5px 8px;background:#f0edff;color:#51478f;font-size:10px;font-weight:800;cursor:pointer;white-space:nowrap}
.notification-panel-actions>span{white-space:nowrap}
.notification-profile{display:flex;align-items:center;gap:14px}
.notification-profile-avatar{width:54px;height:54px;border-radius:50%;font-size:22px;flex:0 0 54px}
.notification-history-list{display:flex;flex-direction:column}
.notification-history-item{display:flex;align-items:flex-start;gap:12px;padding:15px 4px;border-bottom:1px solid var(--line);min-width:0}
.notification-history-item:last-child{border-bottom:0}
.notification-history-item.unread{background:#f7f5ff}
.notification-history-content{display:flex;flex-direction:column;gap:4px;min-width:0;flex:1}
.notification-history-content strong,.notification-history-content span,.notification-history-content small{overflow-wrap:anywhere;word-break:break-word}
.notification-history-content strong{font-size:12px}.notification-history-content span{font-size:12px;font-weight:750}.notification-history-content small{font-size:11px;color:var(--muted);line-height:1.5}
.notification-history-date{font-size:10px;color:var(--muted);white-space:nowrap}
html[data-theme="dark"] .notification-action{background:#292541;border-color:#4a426d;color:#e0d9ff}
html[data-theme="dark"] .notification-history-item.unread{background:#24263b}
@media(max-width:620px){.notification-panel-head{align-items:flex-start;flex-direction:column}.notification-panel-actions{width:100%;justify-content:flex-start}.notification-history-item{flex-wrap:wrap}.notification-history-date{margin-left:20px}}
.revamped-kanban .pipeline-title .count-pill{display:inline-grid;place-items:center;width:24px;height:24px;min-width:24px;padding:0;border-radius:7px;line-height:1;font-variant-numeric:tabular-nums}
.pipeline-archive-content .pipeline-card{background:#fff;border:1px solid #dce3f1;box-shadow:0 3px 9px rgba(34,49,91,.07)}
.pipeline-archive-content .pipeline-card.stage-card-5{background:#eefaf2;border-color:#cbe9d5}
.pipeline-archive-content .pipeline-card.stage-card-6{background:#fff2f0;border-color:#f0d2cf}
.pipeline-archive-content .pipeline-card.stage-card-1{background:#f5f6ff;border-color:#d9defe}
.pipeline-archive-content .pipeline-card.stage-card-2{background:#f0f6ff;border-color:#d2e2f5}
.pipeline-archive-content .pipeline-card.stage-card-3{background:#fff9eb;border-color:#efdfb9}
.pipeline-archive-content .pipeline-card.stage-card-4{background:#f7f1ff;border-color:#e0d3f3}
html[data-theme="dark"] .pipeline-archive-content .pipeline-card{background:#20283a!important;border-color:#3b4967!important}
html[data-theme="dark"] .pipeline-archive-content .pipeline-card.stage-card-5{background:#1d332b!important}
html[data-theme="dark"] .pipeline-archive-content .pipeline-card.stage-card-6{background:#382727!important}
html[data-theme="dark"] .pipeline-archive-content .pipeline-card.stage-card-1{background:#242a43!important}
html[data-theme="dark"] .pipeline-archive-content .pipeline-card.stage-card-2{background:#202f42!important}
html[data-theme="dark"] .pipeline-archive-content .pipeline-card.stage-card-3{background:#383126!important}
html[data-theme="dark"] .pipeline-archive-content .pipeline-card.stage-card-4{background:#30263e!important}
/* Replace selected mint-green editor accents with the lilac reporting palette. */
.current-stage{background:#f0edff!important;border-color:#dcd6ff!important;color:#4f458e!important}
.customer-record-summary{background:#f5f2ff!important;border-color:#e1dcff!important}
.value-difference{background:#f5f2ff!important;border-color:#e1dcff!important}
html[data-theme="dark"] .current-stage,html[data-theme="dark"] .customer-record-summary,html[data-theme="dark"] .value-difference{background:#292541!important;border-color:#4a426d!important;color:#e0d9ff!important}


/* SalesDesk v6.10 refinement: neutral cards with stage-colour top rules, compact archive headers, mobile-safe notifications. */
/* Restore the original neutral Kanban card surface; stage colour is only the thin top highlight. */
.revamped-kanban .pipeline-column{background:#edf0f8!important;border-color:#d7deed!important}
.revamped-kanban .pipeline-card,
.pipeline-archive-content .pipeline-card{background:#fff!important;border:1px solid #dce3f1!important;border-top:3px solid var(--stage-color,#778df2)!important;box-shadow:0 3px 9px rgba(34,49,91,.07)}
.revamped-kanban .pipeline-card:hover,
.pipeline-archive-content .pipeline-card:hover{background:#fbfcff!important;border-color:#cbd5e8!important;border-top-color:var(--stage-color,#778df2)!important}
.revamped-kanban .pipeline-card.stage-card-1,.pipeline-archive-content .pipeline-card.stage-card-1{--stage-color:#778df2}
.revamped-kanban .pipeline-card.stage-card-2,.pipeline-archive-content .pipeline-card.stage-card-2{--stage-color:#6893c3}
.revamped-kanban .pipeline-card.stage-card-3,.pipeline-archive-content .pipeline-card.stage-card-3{--stage-color:#c69b47}
.revamped-kanban .pipeline-card.stage-card-4,.pipeline-archive-content .pipeline-card.stage-card-4{--stage-color:#9a83c5}
.revamped-kanban .pipeline-card.stage-card-5,.pipeline-archive-content .pipeline-card.stage-card-5{--stage-color:#3c9b69}
.revamped-kanban .pipeline-card.stage-card-6,.pipeline-archive-content .pipeline-card.stage-card-6{--stage-color:#c7746d}
.pipeline-archive{background:#edf0f8!important;border-color:#d7deed!important;border-radius:13px}
.pipeline-archive-summary{display:flex;align-items:center;gap:9px;min-height:54px;padding:12px 14px;cursor:pointer;list-style:none;color:var(--ink)}
.pipeline-archive-summary::-webkit-details-marker{display:none}.pipeline-archive-summary::marker{content:""}
.pipeline-archive-summary strong{font-size:14px;font-weight:850;letter-spacing:-.15px;min-width:0;overflow-wrap:anywhere}
.pipeline-archive-summary .stage-dot{flex:0 0 9px}
.pipeline-archive-summary .count-pill{display:inline-grid;place-items:center;flex:0 0 24px;width:24px;height:24px;min-width:24px;margin-left:auto;padding:0;border-radius:7px;line-height:1;font-variant-numeric:tabular-nums;text-align:center}
.archive-toggle-button{display:inline-grid;place-items:center;width:24px;height:24px;flex:0 0 24px;border:1px solid #d9deea;border-radius:7px;background:#fff;color:#52627e;font-size:17px;font-weight:800;line-height:1}
.pipeline-archive[open] .archive-toggle-button{font-size:0}
.pipeline-archive[open] .archive-toggle-button::after{content:"−";font-size:17px}
.pipeline-archive-content{border-top:1px solid #d7deed;padding:10px;max-height:65vh;overflow:auto;overscroll-behavior:contain}
.pipeline-archive-content .pipeline-column{background:transparent!important;border:0!important;box-shadow:none!important;min-height:0;padding:0}
.pipeline-archive-content .pipeline-title{display:none}
.pipeline-archive-content .pipeline-cards{max-height:calc(65vh - 40px);overflow-y:auto;padding:1px 4px 4px 1px;overscroll-behavior:contain}
html[data-theme="dark"] .revamped-kanban .pipeline-column,html[data-theme="dark"] .pipeline-archive{background:#151c2b!important;border-color:#303b52!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card,html[data-theme="dark"] .pipeline-archive-content .pipeline-card{background:#1d2638!important;border-color:#3b4967!important;border-top-color:var(--stage-color,#8198ff)!important}
html[data-theme="dark"] .revamped-kanban .pipeline-card:hover,html[data-theme="dark"] .pipeline-archive-content .pipeline-card:hover{background:#222e45!important;border-color:#465574!important;border-top-color:var(--stage-color,#8198ff)!important}
html[data-theme="dark"] .pipeline-archive-summary{color:#eaf0ff}
html[data-theme="dark"] .pipeline-archive-content{border-color:#303b52}
html[data-theme="dark"] .archive-toggle-button{background:#252d40;border-color:#3b4760;color:#eaf0ff}
/* Clean neutral notification actions instead of lilac buttons. */
.notification-action{background:transparent!important;border:1px solid var(--line)!important;color:var(--ink)!important;border-radius:7px;padding:5px 9px;font-size:10px;font-weight:750;box-shadow:none}
.notification-action:hover{background:var(--soft, #f4f6fa)!important;border-color:#cbd3df!important}
html[data-theme="dark"] .notification-action{background:transparent!important;border-color:#3b4760!important;color:#eaf0ff!important}
html[data-theme="dark"] .notification-action:hover{background:#252d40!important;border-color:#53627e!important}
@media(max-width:620px){
 .notification-panel{position:fixed!important;top:68px!important;right:12px!important;left:12px!important;width:auto!important;max-width:none!important;max-height:calc(100dvh - 84px)!important;box-sizing:border-box;overflow-x:hidden;overflow-y:auto}
 .notification-panel-head{align-items:flex-start;flex-direction:column;gap:9px;padding:12px}
 .notification-panel-actions{width:100%;display:flex;align-items:center;justify-content:flex-start;flex-wrap:wrap;gap:7px}
 .notification-panel-actions>span{margin-left:auto}
 .notification-list{min-width:0;width:100%}
 .notification-item{padding:11px 12px;min-width:0}
 .notification-item-content{min-width:0;max-width:100%}
 .pipeline-archive-summary{min-height:48px;padding:10px 12px}
 .pipeline-archive-summary .count-pill{margin-left:auto}
 .pipeline-archive-content{max-height:60vh}
 .pipeline-archive-content .pipeline-cards{max-height:calc(60vh - 40px)}
}

/* v6.11: uniform stage accordions and right-aligned team status. */
.team-row .team-actions{margin-left:auto;flex:0 0 auto}
.team-row .team-status-pill{margin-left:8px;flex:0 0 auto}
.pipeline-stage-grid{align-items:start}
.pipeline-stage-grid.pipeline-grid{grid-template-columns:repeat(4,minmax(0,1fr));overflow:visible;min-width:0;padding-bottom:0}
.pipeline-stage-summary{width:100%;gap:7px;user-select:none;-webkit-tap-highlight-color:transparent}
.pipeline-stage-summary strong{flex:0 1 auto;min-width:0}
.pipeline-stage-summary .count-pill{display:inline-grid;place-items:center;flex:0 0 28px;width:28px;height:28px;min-width:28px;margin-left:auto;padding:0;text-align:center;line-height:1;border-radius:8px;background:#e4e9ff;color:#304ed0;font-size:12px;font-weight:750;font-variant-numeric:tabular-nums}
.pipeline-stage-summary .archive-toggle-button{display:inline-grid;place-items:center;flex:0 0 28px;width:28px;height:28px;margin-left:0;border:1px solid #dce3f1;border-radius:8px;background:#fff;color:#52627c;font-size:18px;font-weight:600;line-height:1}
.pipeline-stage[open]>.pipeline-stage-summary .archive-toggle-button{font-size:0}
.pipeline-stage[open]>.pipeline-stage-summary .archive-toggle-button::after{content:'−';font-size:18px}
.pipeline-stage>.pipeline-archive-content{max-height:none;overflow:visible;padding:10px}
.pipeline-stage>.pipeline-archive-content .pipeline-column{background:transparent!important;border:0!important;box-shadow:none!important;min-height:0;padding:0}
.pipeline-stage>.pipeline-archive-content .pipeline-title{display:none}
.pipeline-stage>.pipeline-archive-content .column-stage-number{margin:0 0 8px;padding:0}
.pipeline-stage>.pipeline-archive-content .pipeline-cards{max-height:none;overflow:visible;padding:1px 4px 4px 1px}
.pipeline-stage-grid .pipeline-stage-summary .stage-dot{width:8px;height:8px;flex:0 0 8px}
html[data-theme="dark"] .pipeline-stage-summary .count-pill{background:#273456;color:#e0e7ff}
html[data-theme="dark"] .pipeline-stage-summary .archive-toggle-button{background:#1d2638;border-color:#3b4967;color:#e0e7ff}
@media(max-width:1100px) and (min-width:761px){.pipeline-stage-grid.pipeline-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:760px){
 .team-row .team-actions{margin-left:0;order:3;flex-basis:100%;justify-content:flex-start}
 .team-row .team-status-pill{margin-left:auto;order:2}
 .pipeline-stage-grid.pipeline-grid,.pipeline-stage-grid.pipeline-archive-grid{grid-template-columns:minmax(0,1fr);gap:10px}
 .pipeline-stage>.pipeline-archive-content{max-height:60vh;overflow:auto;overscroll-behavior:contain}
 .pipeline-stage>.pipeline-archive-content .pipeline-cards{max-height:calc(60vh - 40px);overflow-y:auto;overscroll-behavior:contain}
 .pipeline-stage-summary{min-height:48px;padding:10px 12px}
}

/* v6.12: mobile pipeline stages expand to full natural height; no nested scrolling. */
.pipeline-stage>.pipeline-archive-content,
.pipeline-stage>.pipeline-archive-content .pipeline-cards{
  max-height:none!important;
  height:auto!important;
  overflow:visible!important;
  overflow-y:visible!important;
  overscroll-behavior:auto!important;
}
.pipeline-stage-summary strong{
  font-size:14px!important;
  line-height:1.25!important;
  font-weight:850!important;
  letter-spacing:-.15px!important;
}
.pipeline-stage-summary .archive-toggle-button{
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  box-sizing:border-box!important;
  padding:0!important;
  text-align:center!important;
  line-height:1!important;
  font-family:inherit!important;
}
.pipeline-stage[open]>.pipeline-stage-summary .archive-toggle-button::after{
  display:block;
  line-height:1!important;
  transform:translateY(-.5px);
}
.pipeline-stage-summary .count-pill{
  background:#e4e9ff!important;
  color:#304ed0!important;
  border:1px solid #d6defa!important;
  font-family:inherit!important;
  font-size:12px!important;
  font-weight:750!important;
}
html[data-theme="dark"] .pipeline-stage-summary .count-pill{
  background:#273456!important;color:#e0e7ff!important;border-color:#3b4967!important;
}
@media(max-width:760px){
  .pipeline-stage>.pipeline-archive-content,
  .pipeline-stage>.pipeline-archive-content .pipeline-cards{
    max-height:none!important;
    height:auto!important;
    overflow:visible!important;
    overflow-y:visible!important;
    -webkit-overflow-scrolling:auto!important;
  }
  .pipeline-stage>.pipeline-archive-content{padding:10px!important}
  .pipeline-stage>.pipeline-archive-content .pipeline-cards{padding:1px 2px 8px!important}
}

/* v6.12: make reporting controls full-width and consistent on mobile. */
@media(max-width:620px){
  .reporting-controls{grid-template-columns:minmax(0,1fr)!important;width:100%;}
  .period-toolbar,.custom-range-toolbar{box-sizing:border-box;width:100%;min-width:0;}
  .period-toolbar{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:9px!important;}
  .period-toolbar .period-label{display:block;width:100%!important;}
  .period-toolbar .period-select{display:block;box-sizing:border-box;width:100%!important;max-width:none!important;min-width:0!important;flex:0 0 38px!important;height:38px!important;}
  .period-toolbar .btn,.period-toolbar .btn.primary{display:block;box-sizing:border-box;width:100%!important;min-width:0!important;max-width:none!important;flex:0 0 38px!important;height:38px!important;min-height:38px!important;padding:0 15px!important;}
  .custom-range-toolbar{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:9px!important;}
  .custom-range-toolbar .period-label{display:block;width:100%!important;}
  .custom-range-toolbar label{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:5px!important;width:100%!important;min-width:0!important;flex:0 0 auto!important;}
  .custom-range-toolbar input{box-sizing:border-box;width:100%!important;min-width:0!important;height:38px!important;min-height:38px!important;}
  .custom-range-toolbar .custom-apply,.custom-range-toolbar .generate-pdf{display:block;box-sizing:border-box;width:100%!important;min-width:0!important;max-width:none!important;flex:0 0 38px!important;height:38px!important;min-height:38px!important;margin:0!important;padding:0 15px!important;}
}


/* v6.13: identical stage heading typography for every Kanban stage, including archived stages 5 and 6. */
.pipeline-stage-summary > strong,
.pipeline-stage-grid .pipeline-stage-summary > strong{
  display:block!important; font-family:inherit!important; font-size:14px!important;
  font-weight:850!important; line-height:1.25!important; letter-spacing:-.15px!important;
  font-style:normal!important; text-transform:none!important; color:inherit!important;
  margin:0!important; padding:0!important; white-space:normal!important;
}

/* v6.13: attachment preview behaves like the Create Customer side pane. */
.attachment-viewer{
  position:fixed!important; z-index:1200!important; top:0!important; right:0!important;
  bottom:0!important; width:min(520px,100vw)!important; height:100dvh!important;
  max-height:100dvh!important; box-sizing:border-box!important; border-radius:16px 0 0 16px!important;
  background:var(--white,#fff)!important; box-shadow:-18px 0 55px rgba(18,27,48,.20)!important;
  display:flex; flex-direction:column; overflow:hidden!important;
}
.attachment-viewer[hidden]{display:none!important}
.attachment-viewer-head{flex:0 0 auto;min-height:58px;box-sizing:border-box}
.attachment-preview{height:auto!important;min-height:0!important;flex:1 1 auto!important;display:flex!important;align-items:stretch!important;justify-content:stretch!important;padding:10px!important;overflow:auto!important}
.attachment-preview iframe{display:block;width:100%;height:100%!important;min-height:0!important;flex:1 1 auto;border:0;background:#fff}
.attachment-preview img{max-height:100%!important;align-self:center;margin:auto}
.mobile-pdf-open{width:100%;align-self:flex-start;display:flex;flex-direction:column;align-items:stretch;gap:12px;padding:12px;box-sizing:border-box;color:var(--ink,#263247)}
.mobile-pdf-open p{margin:0;font-size:13px;line-height:1.5}
.mobile-pdf-open .btn{display:flex;justify-content:center;align-items:center;min-height:42px;text-decoration:none}
@media(max-width:760px){.attachment-viewer{width:100vw!important;border-radius:0!important}.attachment-viewer-head{padding:12px}.attachment-viewer-head>strong{font-size:13px}.attachment-preview{padding:12px!important}}
html[data-theme="dark"] .attachment-viewer{background:#151c2b!important}

/* v6.13: print the real dashboard UI instead of a separate simplified report. */
.overview-print-period{display:none}
@media print{
  @page{size:A4 landscape;margin:9mm}
  html,body{background:#fff!important;color:#1f2937!important;-webkit-print-color-adjust:exact!important;print-color-adjust:exact!important}
  .topbar,.footer,.flash-stack,.reporting-controls,.heading-actions,.text-link{display:none!important}
  .page{width:100%!important;max-width:none!important;margin:0!important;padding:0!important}
  .page-heading{margin:0 0 5mm!important;padding:0!important}
  .page-heading h1{font-size:22px!important}
  .overview-print-period{display:block!important;margin:-2mm 0 5mm;font-size:10px;color:#5b6474}
  .stats-grid,.chart-grid{break-inside:avoid;page-break-inside:avoid}
  .panel,.stat-card{break-inside:avoid;page-break-inside:avoid;box-shadow:none!important;-webkit-print-color-adjust:exact!important;print-color-adjust:exact!important}
  .chart-grid{gap:4mm!important;margin-bottom:4mm!important}
  .panel{padding:4mm!important}
  .line-chart{height:105px!important}
  .line-chart svg{height:90px!important}
  .pie-chart,.pie-chart:before,.legend-dot,.stat-icon,.stage-pill{ -webkit-print-color-adjust:exact!important;print-color-adjust:exact!important}
  .pie-legend{max-height:none!important;overflow:visible!important}
  a{color:inherit!important;text-decoration:none!important}
}

/* v6.14: force one typography contract on every stage heading, including archived stages 5 and 6. */
.pipeline-stage-summary>strong,
.pipeline-grid .pipeline-stage-summary>strong,
.pipeline-archive-grid .pipeline-stage-summary>strong,
.pipeline-stage-grid .pipeline-stage-summary>strong,
.pipeline-stage[data-stage="Deal Closed"]>.pipeline-stage-summary>strong,
.pipeline-stage[data-stage="Deal Lost"]>.pipeline-stage-summary>strong,
.pipeline-column .pipeline-title>strong{
  font-family:inherit!important;font-size:14px!important;font-weight:850!important;
  line-height:1.25!important;letter-spacing:-.15px!important;font-style:normal!important;
  text-transform:none!important;text-decoration:none!important;margin:0!important;padding:0!important;
  white-space:normal!important;word-break:normal!important;overflow-wrap:anywhere!important;
}
/* v6.14: attachment names use the available row width; Download precedes Delete. */
.attachment-row{display:flex!important;align-items:center!important;gap:8px!important;width:100%;box-sizing:border-box}
.attachment-open{display:flex!important;align-items:center!important;gap:8px!important;flex:1 1 auto!important;width:100%;min-width:0!important;padding:5px!important}
.attachment-file-icon{flex:0 0 auto}
.attachment-file-name{display:block!important;flex:1 1 auto!important;min-width:0!important;width:100%;font-size:12px!important;line-height:1.4;overflow-wrap:anywhere!important;word-break:break-word!important;text-align:left}
.attachment-open small{display:none!important}
.attachment-download-row{display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;white-space:nowrap;text-decoration:none!important;border:1px solid var(--line);border-radius:7px;padding:6px 9px;font-size:10px!important;font-weight:800;background:var(--white);color:var(--ink)!important}
.attachment-row form{margin-left:0!important;flex:0 0 auto!important}
.attachment-delete{padding:6px 9px!important;font-size:10px!important}
/* Keep the preview drawer aligned with the site content rather than pinned to the screen edge. */
.attachment-viewer{top:76px!important;right:max(16px,calc((100vw - 1280px)/2))!important;bottom:16px!important;width:min(620px,calc(100vw - 32px))!important;height:auto!important;max-height:none!important;border-radius:14px!important;border:1px solid var(--line)!important;box-shadow:0 18px 60px rgba(18,27,48,.24)!important}
.attachment-preview iframe{height:100%!important;min-height:0!important}
@media(max-width:760px){.attachment-viewer{top:8px!important;right:8px!important;bottom:8px!important;width:calc(100vw - 16px)!important;border-radius:14px!important}.attachment-row{flex-wrap:wrap}.attachment-open{flex-basis:100%!important}.attachment-download-row{margin-left:26px}.attachment-row form{margin-left:0!important}}
/* v6.14: multi-select Attention picker and orange mention pills. */
.attention-picker{display:flex;flex-direction:column;gap:7px;position:relative}
.attention-picker>label{font-size:12px;font-weight:800;color:var(--ink)}
.attention-picker-input{position:relative}
.attention-picker-input input{width:100%;box-sizing:border-box}
.attention-suggestions{position:absolute;top:calc(100% + 4px);left:0;right:0;z-index:40;max-height:220px;overflow:auto;background:var(--white);border:1px solid var(--line);border-radius:9px;box-shadow:0 12px 28px rgba(20,30,50,.14);padding:4px}
.attention-suggestions[hidden]{display:none!important}
.attention-suggestion{display:block;width:100%;border:0;background:transparent;text-align:left;padding:9px 10px;border-radius:6px;color:var(--ink);font:inherit;font-size:12px;cursor:pointer}
.attention-suggestion:hover,.attention-suggestion:focus{background:#fff0df;outline:none}
.attention-chips{display:flex;align-items:center;flex-wrap:wrap;gap:6px}
.attention-chip{display:inline-flex;align-items:center;gap:5px;background:#fff0df;color:#a54d08;border:1px solid #ffd5a6;border-radius:999px;padding:3px 9px;font-size:10px;font-weight:850;line-height:1.4;white-space:normal;overflow-wrap:anywhere}
.attention-chip-selected button{border:0;background:transparent;color:inherit;font-size:15px;line-height:1;padding:0 0 0 2px;cursor:pointer}
.update-attention-line{display:flex;align-items:center;flex-wrap:wrap;gap:5px;margin:5px 0 7px}
.update-attention-line>strong{font-size:10px;color:#a54d08}
html[data-theme="dark"] .attention-chip{background:#482e20;color:#ffd0a0;border-color:#754626}
html[data-theme="dark"] .attention-suggestions{background:var(--white);border-color:var(--line)}
html[data-theme="dark"] .attention-suggestion:hover,html[data-theme="dark"] .attention-suggestion:focus{background:#482e20}
.notification-opening{opacity:.55}

/* SalesDesk v6.15: consistent stage headers, card accents, responsive controls and drawers. */
.theme-toggle{width:40px!important;height:40px!important;min-width:40px!important;min-height:40px!important;padding:0!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;border-radius:10px!important;box-sizing:border-box!important;flex:0 0 40px!important;overflow:hidden}
.theme-toggle #theme-icon{display:block;font-size:17px;line-height:1}
@media(max-width:1000px){.theme-toggle{width:40px!important;height:40px!important;min-width:40px!important;padding:0!important}.theme-toggle #theme-label{display:none!important}}
.pipeline-stage-summary>strong,.pipeline-title>strong,.pipeline-archive-summary>strong,.column-stage-number{font-size:14px!important;font-weight:800!important;line-height:1.3!important;letter-spacing:0!important;color:var(--ink)!important}
.pipeline-stage-summary .stage-dot,.pipeline-title .stage-dot{background:var(--stage-color,#64748b)!important}
.pipeline-card{border-top:3px solid var(--stage-color,#64748b)!important}
.pipeline-card.stage-card-1{--stage-color:#64748b}.pipeline-card.stage-card-2{--stage-color:#147d73}.pipeline-card.stage-card-3{--stage-color:#2864df}.pipeline-card.stage-card-4{--stage-color:#8754ce}.pipeline-card.stage-card-5,.pipeline-card.stage-card-6{--stage-color:#b89a4c}
html[data-theme="dark"] .revamped-kanban .pipeline-card,html[data-theme="dark"] .pipeline-archive-content .pipeline-card{background:var(--white)!important;border-color:var(--line)!important;border-top-color:var(--stage-color,#8198ff)!important}
html[data-theme="dark"] .pipeline-card .deal-value,html[data-theme="dark"] .pipeline-card .value,.pipeline-card .deal-value,.pipeline-card .value{color:#a18442!important}
.mini-status,.attention-chip{padding:3px 8px!important;min-height:0!important;border-radius:999px!important;font-size:10px!important;line-height:1.25!important;font-weight:750!important}
.attention-chip{display:inline-flex;align-items:center;background:#fff0df!important;border:1px solid #f4c28e!important;color:#8a4b0b!important}
html[data-theme="dark"] .attention-chip{background:#422e20!important;border-color:#87582e!important;color:#ffd7a6!important}
.kanban-updates>strong{font-size:12px!important}.pipeline-card .kanban-updates{overflow-wrap:anywhere}
/* Keep an empty card's content compact until expanded on desktop. */
@media(min-width:761px){.pipeline-card:not(:has(.kanban-updates)) .pipeline-card-bottom{display:none}.pipeline-card:not(:has(.kanban-updates)){padding-bottom:10px}}
.attachment-row{display:grid!important;grid-template-columns:minmax(0,1fr) auto auto!important;align-items:center!important;width:100%;box-sizing:border-box;gap:8px!important}
.attachment-open{width:100%!important;max-width:none!important;min-width:0!important;box-sizing:border-box}
.attachment-file-name{display:block!important;width:100%!important;max-width:none!important;white-space:normal!important;overflow-wrap:anywhere!important;word-break:break-word!important}
.attachment-row form{margin-left:0!important}
.attachment-viewer{position:relative!important;top:auto!important;min-width:0!important;width:100%;box-sizing:border-box}
@media(min-width:1000px){.attachment-workspace{grid-template-columns:minmax(0,1fr)!important;gap:18px!important}.attachment-viewer.is-open{margin-top:8px!important;padding:0!important;box-shadow:0 8px 28px rgba(30,40,70,.10)}.attachment-viewer-head{gap:14px}.attachment-viewer-head>strong{flex:1;font-size:14px!important}.attachment-preview{height:min(70vh,760px)!important}}
@media(max-width:760px){.attachment-row{grid-template-columns:minmax(0,1fr) auto auto!important;gap:5px!important;padding:7px!important}.attachment-open{grid-column:1;grid-row:1;min-width:0}.attachment-download-row{grid-column:2;grid-row:1;white-space:nowrap}.attachment-row form{grid-column:3;grid-row:1}.attachment-file-name{font-size:12px!important}.attachment-viewer{margin-top:12px!important}}
.current-stage-deal-context{display:flex;flex-direction:column;gap:3px;margin:6px 0 2px;font-size:12px}.current-stage-deal-context b{font-size:14px}.current-stage-deal-context span{color:var(--muted)}
.back-pipeline-button{align-self:flex-start!important;margin-left:0!important}.page-heading:has(.back-pipeline-button){align-items:flex-start!important}.deal-editor-layout{align-items:start!important}
.table-sort{font:inherit;font-weight:800;color:inherit;background:transparent;border:0;padding:5px 3px;cursor:pointer;text-align:left;white-space:nowrap}.table-sort:hover{color:#6c5ce7;text-decoration:underline}html[data-theme="dark"] .table-sort{color:#edf2ff}html[data-theme="dark"] .person-cell,html[data-theme="dark"] .person-cell strong,html[data-theme="dark"] table td{color:#edf2ff}
.notification-panel-head .notification-action#notification-clear{font-size:10px}
.notification-item{position:relative;touch-action:pan-y}.notification-item-clear{margin-left:auto;flex:0 0 auto;border:1px solid var(--line);background:transparent;color:var(--ink);border-radius:7px;padding:5px 8px;font-size:10px;font-weight:750;cursor:pointer}
@media(max-width:760px){.notification-item-clear{display:none}.notification-item{user-select:none;-webkit-user-select:none}}

/* v6.16 targeted fixes from user screenshot/feedback. */
/* Restore the original, less intrusive desktop theme control; keep the icon square on mobile. */
@media(min-width:1001px){.theme-toggle{width:auto!important;min-width:38px!important;height:38px!important;min-height:38px!important;padding:0 10px!important;flex:0 0 auto!important;border-radius:10px!important}.theme-toggle #theme-label{display:inline!important}}
/* Compact single-line mobile account controls while keeping the brand intact. */
@media(max-width:1000px){.topbar{height:auto!important;min-height:60px!important;padding:7px 12px!important;gap:8px!important;display:flex!important;flex-wrap:wrap!important;align-items:center!important}.topbar>.brand{order:0;flex:1 1 auto;min-width:0;gap:6px;font-size:16px!important}.brand-mark{width:30px!important;height:30px!important;flex:0 0 30px!important}.topbar>.user-menu{order:1;display:flex!important;flex:0 0 auto!important;align-items:center!important;justify-content:flex-end!important;gap:5px!important;white-space:nowrap!important}.user-menu .theme-toggle{width:32px!important;height:32px!important;min-width:32px!important;min-height:32px!important;flex:0 0 32px!important;padding:0!important;border-radius:8px!important}.user-menu .theme-toggle #theme-label{display:none!important}.user-menu .notification-wrap,.user-menu .team-avatar-toggle{width:32px!important;height:32px!important;min-width:32px!important;flex:0 0 32px!important}.user-menu .user-name{display:none!important}.user-menu>.link-button,.user-menu>form>.link-button{font-size:11px!important;padding:4px 5px!important}.user-menu>form{margin:0!important}.topbar>.main-nav{order:2;flex:1 0 100%!important;height:34px!important;gap:17px!important;overflow-x:auto!important;white-space:nowrap!important}.main-nav a{height:34px!important;font-size:12px!important}}
/* Customer table headings: larger, high contrast in both themes. */
table th,.table-sort{font-size:12px!important;letter-spacing:.25px!important;font-weight:850!important;color:#36483f!important}
html[data-theme="dark"] table th,html[data-theme="dark"] .table-sort{color:#f4f7ff!important;background:#202a3d!important}
/* Deal editor context: stage first, then all deal identity fields uniformly small. */
.current-stage-deal-context{display:flex!important;flex-direction:row!important;flex-wrap:wrap!important;align-items:baseline!important;gap:4px!important;margin:5px 0 2px!important;font-size:12px!important;line-height:1.4!important}
.current-stage-deal-context b,.current-stage-deal-context span{font-size:12px!important;font-weight:500!important;color:inherit!important}
.current-stage-deal-context span+span:before{content:'· ';color:var(--muted)}
/* Attachment list and preview: side-by-side on desktop, neatly stacked on narrow screens. */
@media(min-width:1000px){.attachment-workspace{grid-template-columns:minmax(260px,.95fr) minmax(0,1.05fr)!important;gap:18px!important;align-items:start!important}.attachment-viewer{position:relative!important;top:auto!important;right:auto!important;bottom:auto!important;width:100%!important;max-width:100%!important;min-width:0!important;height:min(72vh,780px)!important;max-height:780px!important;margin:0!important;align-self:start!important;overflow:hidden!important}.attachment-viewer[hidden]{display:none!important}.attachment-viewer.is-open{margin:0!important}.attachment-preview{height:calc(min(72vh,780px) - 60px)!important;min-height:0!important;max-height:none!important;overflow:auto!important}.attachment-preview iframe{width:100%!important;height:100%!important;min-height:0!important}}
@media(max-width:999px){.attachment-workspace{grid-template-columns:minmax(0,1fr)!important;gap:12px!important}.attachment-viewer{position:relative!important;top:auto!important;right:auto!important;bottom:auto!important;width:100%!important;max-width:100%!important;min-width:0!important;height:min(68vh,650px)!important;margin:0!important;border-radius:12px!important}.attachment-viewer[hidden]{display:none!important}.attachment-preview{height:calc(min(68vh,650px) - 60px)!important;min-height:0!important}.attachment-preview iframe{height:100%!important;min-height:0!important}}


/* v6.17: notification hierarchy, desktop clear alignment, animated mobile swipe, and attachment preview UX. */
.notification-item{align-items:center!important;transition:transform .2s ease,opacity .2s ease,background-color .15s ease;will-change:transform}
.notification-item-content{flex:1 1 auto;min-width:0;gap:3px!important}
.notification-item-content strong{order:1;font-size:11px!important;line-height:1.3!important;font-weight:850!important}
.notification-item-content span{order:2;font-size:11px!important;line-height:1.35!important;font-weight:750!important}
.notification-item-content small{order:3;font-size:9px!important;line-height:1.35!important}
.notification-item-clear{align-self:center!important;margin:0 0 0 auto!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;height:28px;min-width:48px;box-sizing:border-box;line-height:1!important;position:relative;z-index:2}
.notification-item.swiping{transition:none!important}
.notification-item.notification-swiping-away{overflow:hidden;transition:transform .18s ease,opacity .18s ease!important;pointer-events:none}
@media(max-width:760px){
 .notification-item-clear{display:none!important}
 .notification-item{overflow:hidden;touch-action:pan-y;}
 .notification-item-content{gap:4px!important}
 .attachment-viewer.is-open{position:fixed!important;left:12px!important;right:12px!important;bottom:16px!important;top:auto!important;width:auto!important;max-width:none!important;min-width:0!important;height:min(64dvh,620px)!important;max-height:calc(100dvh - 32px)!important;margin:0!important;z-index:1200!important;box-shadow:0 12px 45px rgba(0,0,0,.35)!important;border:1px solid var(--line)!important;border-radius:14px!important;background:var(--white)!important;}
 .attachment-viewer.is-open .attachment-viewer-head{position:sticky;top:0;z-index:2;background:var(--white)!important;padding:10px!important;}
 .attachment-viewer.is-open .attachment-preview{height:calc(min(64dvh,620px) - 58px)!important;max-height:none!important;min-height:0!important;overflow:auto!important;padding:8px!important;}
 .attachment-viewer.is-open .attachment-preview iframe{height:100%!important;min-height:0!important}
 body.attachment-viewer-open{overflow:hidden}
}
@media(min-width:761px){.notification-item-clear{display:inline-flex!important}}

/* v6.18: exact two-line stage header/context, no leftover helper text */
.current-stage{display:flex!important;flex-direction:column!important;align-items:flex-start!important;gap:4px!important}
.current-stage-heading{display:flex!important;align-items:baseline!important;gap:5px!important;flex-wrap:wrap!important}
.current-stage-heading .small,.current-stage-heading strong{font-size:12px!important;line-height:1.45!important}
.current-stage-deal-context{display:flex!important;flex-wrap:wrap!important;align-items:baseline!important;gap:0!important;margin:0!important;line-height:1.45!important}
.current-stage-deal-context>*{font-size:12px!important;font-weight:500!important;color:inherit!important}
.current-stage-deal-context>*+*::before{content:' · '!important;color:var(--muted)!important;white-space:pre!important}
/* Notification: title, deal, note/attention, stage/date/time; no repeated deal info */
.notification-item-content{display:flex!important;flex-direction:column!important;gap:4px!important}
.notification-item-content>strong{order:0!important}
.notification-item-content>.notification-deal-line{order:1!important;font-size:11px!important;font-weight:750!important}
.notification-item-content>.notification-update-line{order:2!important;font-size:10px!important;font-weight:500!important;line-height:1.45!important}
.notification-item-content>.notification-meta-line{order:3!important;font-size:9px!important;font-weight:450!important;color:var(--muted)!important}
.notification-update-line .attention-chip{display:inline-flex!important;margin:2px 3px 2px 2px!important;padding:2px 7px!important;font-size:9px!important;background:#ffead3!important;color:#9a4909!important;border:1px solid #f6c68e!important;border-radius:99px!important}
.notification-attention-label{font-size:9px!important;margin-left:5px!important}
/* Desktop dual-pane: full-width filename in left pane, viewer immediately beside it. */
@media(min-width:1000px){
 .attachment-workspace{display:grid!important;grid-template-columns:minmax(0,1fr) minmax(0,1fr)!important;gap:12px!important;align-items:start!important}
 .attachment-list{min-width:0!important;width:100%!important}
 .attachment-row{display:grid!important;grid-template-columns:minmax(0,1fr) auto auto!important;width:100%!important;gap:6px!important}
 .attachment-open{min-width:0!important;width:100%!important;max-width:none!important}
 .attachment-file-name{width:100%!important;max-width:none!important;white-space:normal!important;overflow-wrap:anywhere!important}
 .attachment-viewer:not([hidden]){position:relative!important;inset:auto!important;transform:none!important;display:block!important;width:100%!important;max-width:none!important;margin:0!important;height:min(70vh,750px)!important}
}

/* v6.19: desktop attachment filenames occupy the entire list column; preview is adjacent. */
@media(min-width:1000px){
 .attachment-workspace{display:grid!important;grid-template-columns:minmax(0,1.1fr) minmax(0,1fr)!important;gap:16px!important;align-items:start!important;width:100%!important}
 .attachment-list{width:100%!important;min-width:0!important}
 .attachment-row{display:grid!important;grid-template-columns:minmax(0,1fr) auto auto!important;grid-template-rows:auto auto!important;gap:5px 8px!important;width:100%!important;min-width:0!important}
 .attachment-row .attachment-open{grid-column:1/-1!important;grid-row:1!important;display:flex!important;width:100%!important;max-width:none!important;min-width:0!important;box-sizing:border-box!important}
 .attachment-row .attachment-file-name{flex:1 1 auto!important;width:auto!important;max-width:none!important;min-width:0!important;white-space:normal!important;overflow-wrap:anywhere!important}
 .attachment-row .attachment-download-row{grid-column:2!important;grid-row:2!important;justify-self:end!important}
 .attachment-row form{grid-column:3!important;grid-row:2!important;justify-self:end!important}
 .attachment-viewer:not([hidden]){grid-column:2!important;position:relative!important;top:auto!important;right:auto!important;bottom:auto!important;left:auto!important;width:100%!important;max-width:none!important;min-width:0!important;margin:0!important;transform:none!important}
}
.notification-update-line .attention-chip{display:inline-flex!important;vertical-align:middle!important;border-radius:999px!important;background:#ffead3!important;color:#9a4909!important;border:1px solid #f6c68e!important;font-weight:750!important}
html[data-theme="dark"] .notification-update-line .attention-chip{background:#422e20!important;color:#ffd7a6!important;border-color:#87582e!important}

/* v6.20: preview is a true sibling of the entire editor, like Create Customer. */
@media(min-width:1000px){
 .deal-editor-layout:has(> #attachment-viewer:not([hidden])){grid-template-columns:minmax(0,1fr) minmax(310px, .45fr)!important;align-items:start!important}
 .deal-editor-layout > #attachment-viewer:not([hidden]){grid-column:2!important;grid-row:1!important;position:sticky!important;top:86px!important;width:100%!important;height:min(80vh,850px)!important;max-width:none!important;margin:0!important;box-sizing:border-box!important;z-index:2!important}
 .deal-editor-layout > #attachment-viewer:not([hidden]) .attachment-preview{height:calc(min(80vh,850px) - 64px)!important}
 #attachments .attachment-workspace{display:block!important;width:100%!important;max-width:none!important}
 #attachments .attachment-list{width:100%!important;max-width:none!important}
 #attachments .attachment-row{display:grid!important;grid-template-columns:minmax(0,1fr) auto auto!important;grid-template-rows:auto!important;gap:10px!important;align-items:center!important}
 #attachments .attachment-open{grid-column:1!important;grid-row:1!important;width:100%!important;min-width:0!important}
 #attachments .attachment-download-row{grid-column:2!important;grid-row:1!important;white-space:nowrap!important}
 #attachments .attachment-row form{grid-column:3!important;grid-row:1!important}
}
@media(max-width:999px){
 .deal-editor-layout > #attachment-viewer:not([hidden]){z-index:1001!important}
}
.notification-update-line{color:#3269c9!important}
html[data-theme="dark"] .notification-update-line{color:#9bc0ff!important}
.notification-update-line .attention-chip{color:#9a4909!important}
html[data-theme="dark"] .notification-update-line .attention-chip{color:#ffd7a6!important}

/* v6.21: preserve an actual adjacent preview pane, never a floating overlay on desktop. */
@media(min-width:1000px){
 .deal-editor-layout:has(> #attachment-viewer.is-open){display:grid!important;grid-template-columns:minmax(0,1fr) minmax(320px,0.55fr)!important;gap:16px!important}
 .deal-editor-layout > #attachment-viewer.is-open{display:flex!important;flex-direction:column!important;visibility:visible!important;opacity:1!important;position:sticky!important;grid-column:2!important;grid-row:1!important;top:86px!important;left:auto!important;right:auto!important;bottom:auto!important;inset-block-end:auto!important;transform:none!important;max-height:calc(100vh - 110px)!important;height: min(78vh,800px)!important;z-index:3!important}
 .deal-editor-layout > #attachment-viewer.is-open .attachment-preview{flex:1!important;min-height:0!important;height:auto!important;overflow:auto!important}
 .deal-editor-layout > .deal-editor-main{grid-column:1!important;min-width:0!important}
 .deal-page-heading{max-width:100%!important;justify-content:flex-start!important;align-items:flex-start!important}
 .deal-page-heading .back-pipeline-button{margin-left:auto!important;margin-right:0!important;flex-shrink:0!important}
}
@media(min-width:1000px) and (max-width:1250px){.deal-editor-layout:has(> #attachment-viewer.is-open){grid-template-columns:minmax(0,1fr) minmax(290px,.55fr)!important}}

/* v6.22: restore visible attachment preview on both viewports. */
#attachment-viewer[hidden]{display:none!important}
@media(min-width:1000px){
 .deal-editor-layout:has(> #attachment-viewer.is-open){display:grid!important;grid-template-columns:minmax(0,1fr) minmax(320px,.55fr)!important;gap:16px!important;align-items:start!important}
 .deal-editor-layout>.deal-editor-main{min-width:0!important;grid-column:1!important}
 .deal-editor-layout>#attachment-viewer.is-open{display:flex!important;visibility:visible!important;opacity:1!important;position:sticky!important;top:86px!important;right:auto!important;left:auto!important;bottom:auto!important;grid-column:2!important;grid-row:1!important;width:100%!important;height:min(78vh,800px)!important;max-height:none!important;min-width:0!important;z-index:10!important;transform:none!important;flex-direction:column!important}
 .deal-editor-layout>#attachment-viewer.is-open .attachment-preview{flex:1!important;height:auto!important;min-height:0!important;overflow:auto!important}
}
@media(max-width:999px){
 #attachment-viewer.is-open{display:flex!important;visibility:visible!important;opacity:1!important;position:fixed!important;top:auto!important;bottom:12px!important;left:12px!important;right:12px!important;width:auto!important;height:min(75dvh,720px)!important;max-height:calc(100dvh - 24px)!important;z-index:3000!important;transform:none!important;flex-direction:column!important;background:var(--white)!important;box-shadow:0 12px 50px rgba(0,0,0,.4)!important}
 #attachment-viewer.is-open .attachment-preview{flex:1!important;min-height:0!important;height:auto!important;overflow:auto!important}
}
/* v6.22: notes and Attention pills need clear separation, including history. */
.notification-update-line{display:flex!important;align-items:center!important;flex-wrap:wrap!important;column-gap:9px!important;row-gap:6px!important;color:#3269c9!important}
.notification-update-line .notification-note-text{color:#3269c9!important;font-size:inherit!important;font-weight:500!important}
.notification-update-line .attention-chip{margin:0 2px 0 0!important;padding:3px 9px!important;line-height:1.3!important;flex-shrink:0!important}
html[data-theme="dark"] .notification-update-line .notification-note-text{color:#9bc0ff!important}
.notification-history-content{display:flex!important;flex-direction:column!important;gap:5px!important;min-width:0!important}
.notification-history-content .notification-update-line{font-size:10px!important}
.notification-history-content .notification-meta-line{font-size:9px!important;color:var(--muted)!important}

/* v6.23 definitive viewer layout: explicit parent grid and mobile overlay */
#attachment-viewer[hidden] {display:none!important}
@media(min-width:1000px){
 .deal-editor-layout {display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:16px!important;align-items:start!important}
 .deal-editor-layout:has(#attachment-viewer.is-open) {grid-template-columns:minmax(0,1fr) minmax(310px,0.58fr)!important}
 .deal-editor-layout>.deal-editor-main {grid-column:1!important;min-width:0!important;width:100%!important}
 .deal-editor-layout>#attachment-viewer.is-open {display:flex!important;grid-column:2!important;grid-row:1!important;position:sticky!important;top:86px!important;inset:auto!important;width:100%!important;min-width:0!important;height:min(78vh,800px)!important;max-height:none!important;flex-direction:column!important;visibility:visible!important;opacity:1!important;z-index:6!important;margin:0!important}
 .deal-editor-layout>#attachment-viewer.is-open .attachment-preview {flex:1!important;height:auto!important;min-height:0!important;overflow:auto!important}
 .deal-page-heading {width:100%!important;max-width:100%!important;box-sizing:border-box!important;display:flex!important;justify-content:space-between!important;align-items:center!important}
 .deal-page-heading .back-pipeline-button {margin:0!important;align-self:center!important;flex-shrink:0!important}
}
@media(max-width:999px){
 .deal-editor-layout {display:block!important}
 #attachment-viewer.is-open {display:flex!important;position:fixed!important;inset:auto 12px 12px 12px!important;width:auto!important;height:min(76dvh,720px)!important;max-height:calc(100dvh - 24px)!important;flex-direction:column!important;visibility:visible!important;opacity:1!important;z-index:3000!important;margin:0!important;transform:none!important}
 #attachment-viewer.is-open .attachment-preview {flex:1!important;height:auto!important;min-height:0!important;overflow:auto!important}
}
@media(min-width:1000px){
 .deal-page-heading:has(+ .deal-editor-layout #attachment-viewer.is-open){width:calc((100% - 16px) / 1.58)!important;max-width:100%!important}
}

/* v6.25: align desktop preview with the attachment section, not the form header. */
@media(min-width:1000px){
 .deal-editor-layout>#attachment-viewer.is-open{position:relative!important;top:auto!important;align-self:start!important;margin-top:var(--attachment-section-offset,0px)!important;max-height:none!important}
}
.attachment-image-nav:not([hidden]){display:flex;align-items:center;justify-content:space-between;gap:8px;padding:8px 12px;border-bottom:1px solid var(--line);flex:0 0 auto}
.attachment-image-nav[hidden]{display:none!important}
.attachment-image-nav span{font-size:12px;color:var(--muted);white-space:nowrap}
.attachment-image-nav button{min-width:0}
@media(max-width:760px){.attachment-image-nav:not([hidden]){gap:5px;padding:7px}.attachment-image-nav button{font-size:12px;padding:7px 9px}}

/* v6.26: mobile photo-gallery navigation, without modifying working viewer placement */
.gallery-arrow{display:none!important}
@media(max-width:760px){
  .attachment-viewer.gallery-is-image .attachment-preview{position:relative;overflow:hidden;touch-action:pan-y}
  .attachment-viewer.gallery-is-image .attachment-preview img{transition:transform .22s ease,opacity .22s ease;will-change:transform,opacity}
  .attachment-viewer.gallery-is-image .attachment-preview img.gallery-image-enter{transform:translateX(12%);opacity:.35}
  .attachment-viewer.gallery-is-image .gallery-arrow{display:flex!important;position:absolute;top:50%;transform:translateY(-50%);z-index:4;width:32px;height:42px;border:0;border-radius:12px;align-items:center;justify-content:center;background:rgba(18,27,42,.28);color:#fff;font-size:30px;line-height:1;backdrop-filter:blur(3px);cursor:pointer}
  .attachment-viewer.gallery-is-image .gallery-prev{left:8px}
  .attachment-viewer.gallery-is-image .gallery-next{right:8px}
  .attachment-viewer.gallery-is-image .attachment-image-nav{justify-content:center!important;gap:0!important}
  .attachment-viewer.gallery-is-image #attachment-prev,.attachment-viewer.gallery-is-image #attachment-next{display:none!important}
  .attachment-viewer.gallery-is-image #attachment-image-count{display:block!important;text-align:center;font-variant-numeric:tabular-nums}
}
/* v6.26: chart value labels follow the corresponding series colour */
.chart-period-values{display:grid;grid-template-columns:repeat(var(--chart-period-count),minmax(0,1fr));gap:2px;margin-top:6px;font-size:10px;font-weight:700;text-align:center;overflow:hidden}
.chart-period-values span{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.chart-period-values.potential-values{color:#5b8def}
.chart-period-values.closed-values{color:#16a36a}

/* v6.29: same left edge and hierarchy for every notification type */
.notification-history-item{display:grid!important;grid-template-columns:10px minmax(0,1fr)!important;align-items:start!important;column-gap:14px!important;padding:18px 6px!important;flex-wrap:nowrap!important}
.notification-history-item>.notification-item-dot{margin-top:7px!important;grid-column:1!important}
.notification-history-item>.notification-history-content{grid-column:2!important;width:100%!important;min-width:0!important;margin:0!important;padding:0!important}
.notification-history-content .notification-deal-line{font-size:14px!important;line-height:1.4!important}
.notification-history-content .notification-update-line{font-size:12px!important;line-height:1.5!important}
.notification-history-content .notification-meta-line{font-size:10px!important}
.notification-item{align-items:flex-start!important}
.notification-item-content{min-width:0!important;flex:1!important}

/* v6.30 attachment share action, preserving the existing viewer layout. */
.attachment-share{border:1px solid var(--border,#d8deeb);border-radius:9px;background:transparent;color:inherit;font:inherit;font-size:12px;font-weight:700;padding:7px 9px;white-space:nowrap;cursor:pointer;flex:0 0 auto}
.attachment-share:hover{background:rgba(95,105,235,.09)}
.attachment-viewer-actions{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
@media(max-width:760px){.attachment-share{padding:6px 7px;font-size:11px}}

/* v6.31: share action alongside Download and Delete */
.attachment-share-row{display:inline-flex;align-items:center;justify-content:center;cursor:pointer;border:1px solid var(--border,#dce3ee);background:transparent;color:var(--text,#26334c);border-radius:8px;padding:7px 10px;font:inherit;font-size:12px;white-space:nowrap}
.attachment-share-row:hover{background:var(--surface-hover,#eef2ff)}
.attachment-row{gap:8px}
@media(max-width:760px){.attachment-share-row{padding:7px 8px;font-size:11px}}

/* v6.32: compact, uniform attachment actions, including Share. */
#attachments .attachment-row{grid-template-columns:minmax(0,1fr) auto auto auto!important;gap:6px!important}
#attachments .attachment-row .attachment-open{grid-column:1!important;grid-row:1!important;min-width:0!important}
#attachments .attachment-row .attachment-share-row{grid-column:2!important;grid-row:1!important}
#attachments .attachment-row .attachment-download-row{grid-column:3!important;grid-row:1!important}
#attachments .attachment-row form{grid-column:4!important;grid-row:1!important;margin:0!important}
#attachments .attachment-row .attachment-share-row,
#attachments .attachment-row .attachment-download-row,
#attachments .attachment-row .attachment-delete{display:inline-flex!important;align-items:center!important;justify-content:center!important;box-sizing:border-box!important;min-width:0!important;height:29px!important;padding:0 7px!important;margin:0!important;border:1px solid var(--line)!important;border-radius:7px!important;background:var(--white)!important;color:var(--ink)!important;font-family:inherit!important;font-size:10px!important;font-weight:750!important;line-height:1!important;white-space:nowrap!important;text-decoration:none!important;cursor:pointer!important}
#attachments .attachment-row .attachment-delete{color:#c03647!important}
#attachment-share,#attachment-download{box-sizing:border-box!important;min-height:30px!important;height:30px!important;padding:0 9px!important;font-size:11px!important;line-height:1!important}
@media(max-width:760px){#attachments .attachment-row{grid-template-columns:minmax(0,1fr) auto auto auto!important;gap:4px!important}#attachments .attachment-row .attachment-share-row,#attachments .attachment-row .attachment-download-row,#attachments .attachment-row .attachment-delete{padding:0 5px!important;font-size:9px!important;height:28px!important}}

/* v6.33: center mobile gallery arrow glyphs and unify swipe/tap slide animation */
@media(max-width:760px){
 .attachment-viewer.gallery-is-image .gallery-arrow{display:grid!important;place-items:center!important;padding:0!important;box-sizing:border-box!important;text-align:center!important;font-family:Arial,sans-serif!important;font-weight:400!important;font-size:27px!important;line-height:1!important;letter-spacing:0!important;transform:translateY(-50%)!important}
 .attachment-viewer.gallery-is-image .attachment-preview{isolation:isolate}
 .attachment-viewer.gallery-is-image .attachment-preview img.gallery-sliding-in{position:absolute!important;inset:0!important;margin:auto!important;max-width:calc(100% - 20px)!important;max-height:calc(100% - 20px)!important;object-fit:contain!important;opacity:1}
}

/* v6.35: compact push bell aligned with account controls */
.user-menu .push-bell-toggle{order:0;display:inline-flex;align-items:center;justify-content:center;flex:0 0 36px;width:36px;height:36px;min-width:36px;padding:0;border:1px solid var(--line);border-radius:9px;background:var(--white);color:var(--muted);cursor:pointer;box-sizing:border-box;line-height:1}
.user-menu .push-bell-toggle .push-bell-icon{display:block;flex:none}
.user-menu .push-bell-toggle.push-is-enabled{color:var(--primary,#4566df)}
.user-menu .push-bell-toggle.push-is-enabled .push-bell-slash{display:none}
.user-menu .push-bell-toggle:disabled{opacity:.55;cursor:wait}
.user-menu .push-bell-toggle:focus-visible{outline:2px solid var(--primary,#4566df);outline-offset:2px}
@media(max-width:1000px){.topbar>.user-menu .push-bell-toggle{width:32px;height:32px;min-width:32px;flex:0 0 32px;border-radius:8px}.topbar>.user-menu{gap:4px!important}}
@media(max-width:420px){.topbar{padding-left:7px!important;padding-right:7px!important}.topbar>.brand{font-size:14px!important;gap:4px!important}.topbar>.user-menu{gap:3px!important}.topbar>.user-menu>.link-button,.topbar>.user-menu>form>.link-button{font-size:10px!important;padding:3px!important}}

/* v6.37: shared accessible colour and responsive control refinements */
:root{--salesdesk-primary:#4f5fe5;--salesdesk-primary-soft:#e9edff;--salesdesk-ink:#182235;--salesdesk-canvas:#f6f8fc;--salesdesk-success:#19856b;--salesdesk-attention:#facc15;--salesdesk-danger:#c62828}
html:not([data-theme="dark"]) .page{--primary:#4f5fe5;--primary-dark:#354ba2}
.topbar .user-menu{display:flex;align-items:center;gap:8px}
.header-icon-button{position:relative;display:inline-flex;align-items:center;justify-content:center;width:38px;height:38px;padding:0;border:1px solid var(--line);border-radius:11px;background:var(--white);color:var(--primary,#4f5fe5);cursor:pointer}
.header-icon-button svg{display:block}
.account-wrap{position:relative;display:flex;align-items:center}
.account-toggle{display:inline-flex;align-items:center;justify-content:center;cursor:pointer}
.account-panel{position:absolute;right:0;top:calc(100% + 12px);width:min(300px,calc(100vw - 24px));padding:9px;background:var(--white);color:var(--text);border:1px solid var(--line);border-radius:16px;box-shadow:0 16px 45px rgba(18,30,60,.17);z-index:1100}
.account-panel[hidden]{display:none!important}
.account-heading{display:flex;align-items:center;gap:10px;padding:10px 10px 14px;border-bottom:1px solid var(--line);margin-bottom:5px}
.account-heading>span:last-child{display:flex;flex-direction:column;gap:2px;min-width:0}.account-heading small{font-size:11px;color:var(--muted)}
.account-action{display:flex;align-items:center;gap:12px;width:100%;min-height:44px;padding:10px 12px;border:0;border-radius:9px;background:transparent;color:var(--text);font:inherit;font-size:13px;font-weight:650;text-align:left;text-decoration:none;cursor:pointer;box-sizing:border-box}
.account-action:hover,.account-action:focus-visible{background:var(--salesdesk-primary-soft);color:#354ba2}
.account-action svg{flex:none}.account-action-label{flex:1;display:flex;flex-direction:column;gap:3px}.account-action-label small{font-size:10px;font-weight:400;color:var(--muted)}
.account-switch{width:31px;height:18px;border-radius:12px;background:#b7c0d1;position:relative;flex:none;transition:background .18s}
.account-switch:before{content:'';position:absolute;left:3px;top:3px;width:12px;height:12px;border-radius:50%;background:white;transition:transform .18s}
.push-account-action.push-is-enabled .account-switch{background:#4f5fe5}.push-account-action.push-is-enabled .account-switch:before{transform:translateX(13px)}
.push-account-action.push-is-enabled .push-bell-slash{display:none}
.account-signout{color:#c62828}.account-panel form{margin:0}
.notification-item-content>.notification-deal-line{order:0!important;font-size:12px!important;font-weight:800!important}
.notification-item-content>.notification-update-line{order:1!important}.notification-item-content>.notification-meta-line{order:2!important}
.notification-item{padding-top:10px!important;padding-bottom:10px!important}.notification-item-content{gap:3px!important}
.attention-chip.attention-other{background:#fef3c7!important;color:#854d0e!important;border-color:#facc15!important}
.attention-chip.attention-personal{background:#fee2e2!important;color:#991b1b!important;border-color:#ef4444!important}
.stage-index{display:inline-flex;align-items:center;justify-content:center;min-width:27px;height:25px;padding:0 4px;box-sizing:border-box;background:#e9edff;border-radius:7px;color:#354ba2;font-size:11px;font-weight:800;flex:none}
.pipeline-stage-summary .count-pill,.pipeline-title .count-pill{font-size:12px!important;min-width:24px!important;min-height:24px!important;width:auto!important;height:24px!important;padding:0 6px!important;border-radius:14px!important}
.pipeline-column .pipeline-cards>.pipeline-card:nth-of-type(n+4){display:none}
.pipeline-column.stage-all-visible .pipeline-cards>.pipeline-card:nth-of-type(n+4){display:block}
.stage-show-more{display:block;width:100%;min-height:40px;border:1px solid var(--line);border-radius:10px;background:var(--white);color:var(--primary,#4f5fe5);font:inherit;font-size:12px;font-weight:700;cursor:pointer;margin:9px 0}
.pipeline-column.stage-all-visible .stage-show-more{margin-top:12px}
.deal-meta{display:flex!important;flex-direction:column!important;align-items:flex-end!important;text-align:right!important;gap:2px!important;min-width:0}
.pipeline-card-bottom{display:flex!important;align-items:center!important;justify-content:space-between!important;gap:8px!important}
.customer-mobile-list{display:none}
@media(max-width:760px){
 .topbar .user-menu{gap:5px!important}.header-icon-button,.account-toggle{width:35px!important;height:35px!important;min-width:35px!important}
 .account-panel{right:-5px}.customer-mobile-list{display:flex;flex-direction:column;gap:0}.customer-mobile-item{display:flex;align-items:center;gap:12px;padding:13px 3px;border-bottom:1px solid var(--line);color:var(--text);text-decoration:none;min-width:0}
 .customer-mobile-info{display:flex;flex-direction:column;gap:4px;flex:1;min-width:0}.customer-mobile-info strong{font-size:13px;overflow-wrap:anywhere}.customer-mobile-info small{font-size:11px;color:var(--muted)}.customer-mobile-phone{font-size:12px;overflow-wrap:anywhere}.customer-mobile-arrow{font-size:23px;color:var(--muted)}
 .table-wrap{display:none!important}.pipeline-column:has(.pipeline-cards>.pipeline-add:only-child){min-height:0!important;height:auto!important}
 .pipeline-cards{min-height:0!important}.pipeline-column{min-height:0!important}.pipeline-stage-summary{gap:7px!important}
 .page-heading{margin-bottom:20px!important}.page-heading h1{font-size:clamp(29px,8vw,38px)!important}
}
html[data-theme="dark"] .account-action:hover,html[data-theme="dark"] .account-action:focus-visible{background:#283555;color:#e9edff}
html[data-theme="dark"] .stage-index{background:#29365a;color:#c5d1ff}
html[data-theme="dark"] .attention-chip.attention-other{background:#54420c!important;color:#ffe58a!important}
html[data-theme="dark"] .attention-chip.attention-personal{background:#59232a!important;color:#ffb3b3!important}

/* v6.38 unified SalesDesk theme and responsive finishing */
:root{--sales-primary:#4F5FE5;--sales-selected:#E9EDFF;--sales-background:#F6F8FC;--sales-text:#344054;--sales-success:#19856B;--sales-gold:#BD8A20}
html:not([data-theme="dark"]) body{background:var(--sales-background);color:var(--sales-text)}
html:not([data-theme="dark"]) .main-nav a:hover,html:not([data-theme="dark"]) .main-nav a.active,.text-link,.stat-card a{color:var(--sales-primary)}
html:not([data-theme="dark"]) .btn.primary,html:not([data-theme="dark"]) button.btn.primary{background:var(--sales-primary);border-color:var(--sales-primary);color:#fff}
html:not([data-theme="dark"]) .stat-card:nth-child(2){border-top-color:var(--sales-primary)}
html:not([data-theme="dark"]) .stat-card:nth-child(4){border-top-color:var(--sales-success)}
.stat-icon.success{background:#DDF4E8!important;color:var(--sales-success)!important}
html:not([data-theme="dark"]) .stat-icon.blue{background:#E9EDFF;color:var(--sales-primary)}
html:not([data-theme="dark"]) .stage-pill{background:#E9EDFF;color:#3D4FAD}
html:not([data-theme="dark"]) .stage-section,html:not([data-theme="dark"]) .stage-section summary{background:#F6F8FC!important;border-color:#DCE3F2!important}
.stage-section{margin-bottom:8px!important}.stage-section summary{padding:13px 15px!important;display:flex;align-items:center;gap:9px}.stage-summary-number,.current-stage-number{display:inline-flex;align-items:center;justify-content:center;min-width:30px;padding:4px 7px;border-radius:8px;background:#E9EDFF;color:#4356CC;font-size:12px;font-weight:800}
.current-stage{padding:12px 14px!important;margin-bottom:12px!important;background:#F1F3FF!important;border:1px solid #DCE2FB!important;border-radius:13px!important}.current-stage-heading{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.current-stage-deal-context{margin-top:6px!important}
html[data-theme="dark"] .current-stage,html[data-theme="dark"] .stage-summary-number,html[data-theme="dark"] .current-stage-number{background:#283452!important;color:#C7D3FF!important;border-color:#425071!important}
.custom-range-details{min-width:0;border:1px solid var(--line);border-radius:14px;background:var(--white);padding:0}.custom-range-details>summary{list-style:none;display:flex;justify-content:space-between;align-items:center;gap:10px;padding:13px 16px;cursor:pointer;font-weight:750;color:var(--ink)}.custom-range-details>summary::-webkit-details-marker{display:none}.custom-range-details[open] .range-chevron{transform:rotate(180deg)}.custom-range-details .custom-range-toolbar{border:0!important;box-shadow:none!important;margin:0!important;padding:10px 14px 14px!important}.reporting-controls{align-items:start}.period-toolbar{min-width:0}.period-toolbar .period-select{min-width:0}
.single-month-chart{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;min-height:145px;padding:12px}.single-month-value{font-weight:850;font-size:clamp(17px,3vw,23px);color:var(--sales-primary);text-align:center}.single-month-track{width:min(100%,320px);height:67px;border-bottom:2px solid var(--line);display:flex;align-items:end;justify-content:center}.single-month-bar{height:60px;width:min(34%,90px);border-radius:9px 9px 0 0;background:var(--sales-primary)}.single-month-bar.closed-bar{background:var(--sales-success)}.single-month-label{color:var(--muted);font-size:12px}.chart-empty{min-height:120px;display:flex;align-items:center;justify-content:center;flex-direction:column;gap:4px;color:var(--muted);text-align:center}.chart-empty span{font-size:26px;opacity:.55}.chart-empty p{margin:0;font-size:13px}.top-closed-panel:has(.compact-empty){min-height:0!important}.top-closed-panel .compact-empty{min-height:95px!important;padding:18px!important}.top-closed-panel .top-closed-list{flex:0 1 auto!important}.dashboard-equal-panel{min-height:0!important}
.legend-1{background:#2C8B69!important}.legend-2{background:#4B92B7!important}.legend-3{background:#BE9A46!important}.legend-4{background:#8873B4!important}.legend-5{background:#19856B!important}.legend-6{background:#BD6262!important}
.attention-chip.attention-other{background:#FFF4C7!important;border-color:#E3C252!important;color:#785600!important}.attention-chip.attention-personal{background:#FFE0E1!important;border-color:#E38B92!important;color:#AD2632!important}
.deal-row{min-width:0}.deal-main{min-width:0;overflow-wrap:anywhere}.deal-value{min-width:0;overflow-wrap:anywhere}.notification-history-content strong{display:none}.notification-history-item{padding-block:12px!important}
html[data-theme="dark"] .custom-range-details{background:#20283A;border-color:#374158}html[data-theme="dark"] .custom-range-details>summary{color:#E4E9F4}html[data-theme="dark"] .single-month-value{color:#A6B5FF}
@media(max-width:760px){.reporting-controls{gap:10px!important}.period-toolbar{padding:12px!important;display:grid!important;grid-template-columns:minmax(0,1fr) auto!important;gap:8px!important}.period-toolbar .period-label{grid-column:1/-1}.period-toolbar .btn{min-width:88px!important;width:auto!important}.custom-range-details .custom-range-toolbar{display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}.custom-range-toolbar .period-label{grid-column:1/-1}.custom-range-toolbar label{min-width:0!important}.custom-range-toolbar input{width:100%!important;min-width:0!important}.custom-range-toolbar .custom-apply,.custom-range-toolbar .generate-pdf{width:100%!important}.stage-section{margin-bottom:7px!important}.stage-section summary{padding:12px!important}.current-stage{padding:10px 12px!important}.page-heading.deal-page-heading{gap:10px!important}.page-heading.deal-page-heading h1{margin-bottom:3px!important}.dashboard-lower-grid .top-closed-panel{min-height:0!important}.deal-row{gap:9px!important}.deal-value{font-size:12px!important}}
@media print{.custom-range-details{display:none!important}.chart-empty{min-height:85px}}

@media(min-width:761px){.pipeline-column .pipeline-cards>.pipeline-card:nth-of-type(n+4){display:block!important}.pipeline-column .stage-show-more{display:none!important}}
.main-nav a.active{color:#4F5FE5!important;border-bottom:2px solid #4F5FE5!important}
html[data-theme="dark"] .main-nav a.active{color:#B2C0FF!important;border-bottom-color:#B2C0FF!important}
@media(max-width:760px){.pipeline-column .pipeline-cards>.pipeline-card:nth-of-type(n+4){display:none}.pipeline-column.stage-all-visible .pipeline-cards>.pipeline-card:nth-of-type(n+4){display:block}}

/* v6.39 targeted layout corrections */
.custom-range-static{display:block!important;overflow:visible!important}.custom-range-static>summary{display:none!important}.reporting-controls{align-items:start}.custom-range-static .custom-range-toolbar{display:flex!important}.stat-icon svg{width:19px;height:19px;display:block}.stat-icon{display:inline-grid;place-items:center;flex-shrink:0}.stat-card{min-width:0}.stat-label-large{min-width:0}.stage-pill-v639{display:inline-flex!important;flex-direction:column;align-items:flex-end;gap:2px;line-height:1.2}.stage-pill-v639 small{font-size:9px;opacity:.75}.stage-name-block{display:flex;flex-direction:column;min-width:0;gap:3px;flex:1}.stage-name-block strong{font-size:13px!important;line-height:1.2}.stage-name-block small{font-size:10px;color:#68778f;font-weight:600}.pipeline-stage-summary .stage-dot{margin-right:2px}.pipeline-stage-summary .archive-toggle-button{display:grid!important;place-items:center!important;line-height:1!important;vertical-align:middle!important;padding:0!important;position:relative}.pipeline-stage[open]>.pipeline-stage-summary .archive-toggle-button::after{transform:none!important;line-height:1!important}.stage-accordion-title,.current-stage-stage-name{display:inline-flex;flex-direction:column;gap:3px;vertical-align:middle}.stage-accordion-title small,.current-stage-stage-name small{font-size:10px;font-weight:600;color:#66758d}.current-stage-stage-name small{font-size:10px}.deal-editor-layout{grid-template-columns:minmax(0,1fr) minmax(280px,340px)!important;align-items:start!important}.deal-editor-layout>.customer-pane:not([hidden]){grid-column:2;grid-row:1;position:sticky;top:78px}.deal-editor-layout>.deal-editor-main{grid-column:1;grid-row:1}.mobile-collapse-stage{display:none}.account-heading{display:flex;align-items:center;gap:10px}.account-heading>.user-dot{order:0;flex-shrink:0}.account-heading>span:not(.user-dot){order:1}.team-avatar-toggle,.header-icon-button{width:38px!important;height:38px!important;min-width:38px!important;flex-basis:38px!important;border-radius:10px!important;display:grid!important;place-items:center!important}.team-avatar-toggle .user-dot{width:32px!important;height:32px!important;border-radius:8px!important;background:#e9edff!important;color:#4f5fe5!important;border:1px solid #c9d3ff!important;box-shadow:none!important}.user-menu .theme-toggle{min-height:38px}.account-heading .user-dot{border-radius:9px!important;background:#e9edff!important;color:#4f5fe5!important}.stage-show-more{display:none!important}.pipeline-stage>.pipeline-archive-content .pipeline-cards>.pipeline-card:nth-of-type(n+4){display:block!important}
@media(max-width:1050px){.deal-editor-layout{grid-template-columns:minmax(0,1fr)!important}.deal-editor-layout>.customer-pane:not([hidden]){grid-column:1;grid-row:2;position:relative;top:auto}.deal-editor-layout>.deal-editor-main{grid-column:1;grid-row:1}}
@media(max-width:760px){.mobile-collapse-stage{display:flex;width:100%;justify-content:center;align-items:center;gap:6px;margin-top:10px;padding:10px 8px;border:1px solid #d6defa;border-radius:8px;background:#f0f3ff;color:#4057c4;font-size:12px;font-weight:700;cursor:pointer}.user-menu .theme-toggle{width:38px!important;height:38px!important;min-width:38px!important;padding:0!important;display:grid!important;place-items:center!important;border-radius:10px!important}.team-avatar-toggle,.header-icon-button{width:38px!important;height:38px!important;flex-basis:38px!important}.team-avatar-toggle .user-dot{width:32px!important;height:32px!important}.stage-name-block strong{font-size:14px!important}}
html[data-theme="dark"] .stage-name-block small,html[data-theme="dark"] .stage-accordion-title small{color:#aab9d5}html[data-theme="dark"] .mobile-collapse-stage{background:#273456;border-color:#3b4967;color:#dbe5ff}
/* All mobile deals are available when a stage is expanded. */
@media(max-width:760px){.pipeline-stage .pipeline-cards>.pipeline-card:nth-of-type(n+4){display:block!important}.pipeline-stage .pipeline-cards{overflow:visible!important;max-height:none!important}.pipeline-stage .pipeline-archive-content{overflow:visible!important;max-height:none!important}}

/* v6.40 targeted UI refinements */
@media(max-width:760px){
 .pipeline-stage-grid,.pipeline-archive-grid.pipeline-stage-grid{row-gap:12px!important;gap:12px!important}
 .pipeline-stage{margin-top:0!important;margin-bottom:0!important;min-height:0!important}
 .pipeline-stage>.pipeline-stage-summary{min-height:62px!important;margin:0!important;box-sizing:border-box!important;padding:11px 14px!important;align-items:center!important}
 .pipeline-stage:not([open])>.pipeline-archive-content{display:none!important}
 .pipeline-stage .pipeline-title{margin-bottom:0!important}
 .mobile-collapse-stage{background:#E9EDFF!important;color:#4F5FE5!important;border:1px solid #C8D2FF!important;gap:9px!important;font-size:13px!important;font-weight:750!important;min-height:43px!important}
}
.mobile-collapse-stage .collapse-stage-icon{display:block;flex:0 0 18px;stroke-width:2.1}
.kanban-updates>strong,.deal-update-prefix{color:#4F5FE5!important}
.deal-update-prefix{font-weight:750}
.kanban-update{background:#F1F4FF!important;border-color:#E1E8FF!important}
.notification-item-content>.notification-deal-line,.notification-history-content .notification-deal-line{color:#4F5FE5!important}
.notification-update-line .notification-note-text{color:#344F9D!important}
.notification-history-item.unread,.notification-item.unread{background:#F3F5FF!important}
.account-heading{border-bottom:1px solid var(--line)!important;margin-bottom:9px!important;padding:12px 10px 16px!important;gap:11px!important}
.account-panel{padding:10px!important}
.account-panel .account-action{display:grid!important;grid-template-columns:22px minmax(0,1fr) auto!important;column-gap:12px!important;align-items:center!important;min-height:48px!important;padding:10px 11px!important}
.account-panel .account-action>svg{width:20px!important;height:20px!important;grid-column:1!important;justify-self:center!important}
.account-panel .account-action>.account-action-label,.account-panel .account-action>span:not(.account-switch){grid-column:2!important;min-width:0!important}
.account-panel .push-account-action>.account-switch{grid-column:3!important}
.account-panel form{width:100%!important}
html[data-theme="dark"] .kanban-update{background:#26334F!important;border-color:#3C4C70!important}
html[data-theme="dark"] .kanban-updates>strong,html[data-theme="dark"] .deal-update-prefix,html[data-theme="dark"] .notification-deal-line{color:#AAB9FF!important}
html[data-theme="dark"] .notification-item.unread,html[data-theme="dark"] .notification-history-item.unread{background:#25304A!important}
html[data-theme="dark"] .notification-update-line .notification-note-text{color:#C7D2FE!important}

/* v6.41 — targeted accessibility, notification hierarchy and mobile alignment */
:root{--v641-ink:#344054;--v641-message:#4F5FE5;--v641-muted:#667085;--v641-update:#F0F3FF;--v641-update-border:#DCE3FF}
/* Heading is deliberately distinct from message text. */
html:not([data-theme="dark"]) .kanban-updates>strong{color:var(--v641-ink)!important}
html:not([data-theme="dark"]) .kanban-update{background:var(--v641-update)!important;border-color:var(--v641-update-border)!important;color:var(--v641-message)!important}
html:not([data-theme="dark"]) .kanban-update>span{color:var(--v641-message)!important;font-weight:650!important}
html:not([data-theme="dark"]) .kanban-update>small{color:var(--v641-muted)!important}
.kanban-update>span{display:block!important;width:100%!important;margin:0!important;padding:0!important;text-align:left!important;line-height:1.45!important;overflow-wrap:anywhere}
.kanban-update>small{display:block!important;text-align:left!important;margin:0!important;padding:0!important}
.kanban-update .update-attention-line{margin-left:0!important;text-align:left!important}
/* Notification customer/deal names remain neutral; only message is accented. */
html:not([data-theme="dark"]) .notification-item-content>.notification-deal-line,
html:not([data-theme="dark"]) .notification-history-content .notification-deal-line{color:var(--v641-ink)!important}
html:not([data-theme="dark"]) .notification-update-line .notification-note-text{color:var(--v641-message)!important;font-weight:650!important}
.notification-update-line{display:flex!important;align-items:center!important;justify-content:flex-start!important;flex-wrap:wrap!important;gap:6px!important;text-align:left!important}
.notification-note-text{display:inline!important;text-align:left!important}
.notification-item-content>.notification-meta-line,.notification-history-content>.notification-meta-line{text-align:left!important}
/* Dark theme: explicit contrast overrides late v6.40 and legacy selectors. */
html[data-theme="dark"]{--v641-ink:#F3F5FF;--v641-message:#AAB8FF;--v641-muted:#B2BDD3;--v641-update:#252D43;--v641-update-border:#37415C}
html[data-theme="dark"] .kanban-updates,html[data-theme="dark"] .kanban-updates>strong{color:#F3F5FF!important;opacity:1!important;visibility:visible!important}
html[data-theme="dark"] .kanban-update{background:#252D43!important;border-color:#37415C!important;color:#AAB8FF!important;opacity:1!important;visibility:visible!important}
html[data-theme="dark"] .kanban-update>span{color:#AAB8FF!important;font-weight:650!important;opacity:1!important;visibility:visible!important}
html[data-theme="dark"] .kanban-update>small{color:#B2BDD3!important;opacity:1!important;visibility:visible!important}
html[data-theme="dark"] .notification-item-content>.notification-deal-line,
html[data-theme="dark"] .notification-history-content .notification-deal-line{color:#F3F5FF!important}
html[data-theme="dark"] .notification-update-line .notification-note-text{color:#AAB8FF!important;font-weight:650!important}
html[data-theme="dark"] .notification-item-content>.notification-meta-line,
html[data-theme="dark"] .notification-history-content>.notification-meta-line{color:#B2BDD3!important}
html[data-theme="dark"] .attention-chip.attention-other{background:#54420C!important;color:#FFE58A!important;border-color:#D6A72A!important}
html[data-theme="dark"] .attention-chip.attention-personal{background:#59232A!important;color:#FFB3B3!important;border-color:#EF4444!important}
/* Exact equal gaps between the three mobile header controls. */
@media(max-width:1000px){
 .topbar>.user-menu{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:8px!important;column-gap:8px!important}
 .topbar>.user-menu>.theme-toggle,.topbar>.user-menu>.notification-wrap,.topbar>.user-menu>.account-wrap{margin:0!important;flex-shrink:0!important}
 .topbar>.user-menu .theme-toggle,.topbar>.user-menu .header-icon-button,.topbar>.user-menu .account-toggle{width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important;box-sizing:border-box!important}
 .topbar>.user-menu .notification-wrap,.topbar>.user-menu .account-wrap{width:38px!important;height:38px!important;min-width:38px!important;flex:0 0 38px!important}
}
/* Center icon and caption as one inline-flex group, not separate items. */
@media(max-width:760px){
 .mobile-collapse-stage{display:flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;text-align:center!important;line-height:1.25!important}
 .mobile-collapse-stage .collapse-stage-icon{display:block!important;position:static!important;flex:0 0 18px!important;width:18px!important;height:18px!important;margin:0!important;vertical-align:middle!important}
 .mobile-collapse-stage>span{display:block!important;flex:0 0 auto!important;margin:0!important;padding:0!important;line-height:1.25!important}
}


/* v6.42: scoped desktop layout, shared form palette and mobile navigation alignment. */
:root{--v642-primary:#4F5FE5;--v642-panel:#FFFFFF;--v642-field:#FFFFFF;--v642-border:#DCE3EF;--v642-muted:#667085}
/* Align the return action with the relevant editor container rather than viewport. */
@media(min-width:1051px){
 .deal-heading-edit{max-width:900px!important;width:100%!important;margin-left:0!important;margin-right:0!important}
 .deal-heading-new{max-width:100%!important;width:100%!important}
 .deal-heading-edit .back-pipeline-button,.deal-heading-new .back-pipeline-button{margin-left:auto!important;align-self:center!important}
 .deal-layout-edit:not(:has(> #attachment-viewer.is-open)){grid-template-columns:minmax(0,900px)!important;max-width:900px!important}
 .deal-layout-edit:not(:has(> #attachment-viewer.is-open))>.deal-editor-main{width:100%!important}
 .deal-layout-edit .form-panel{max-width:none!important;width:100%!important}
 .deal-layout-new{grid-template-columns:minmax(0,1fr) minmax(280px,340px)!important}
}
/* Stage context: separate stage label, stage number and deal identity. */
.deal-editor-layout .current-stage{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:8px!important;padding:15px 18px!important}
.deal-editor-layout .current-stage-heading{display:flex!important;align-items:center!important;gap:10px!important;flex-wrap:wrap!important}
.deal-editor-layout .current-stage-heading>.small{font-size:11px!important;letter-spacing:.35px!important;color:#667085!important}
.deal-editor-layout .current-stage-stage-name{display:flex!important;flex-direction:row!important;align-items:center!important;gap:9px!important;font-size:14px!important;color:#344054!important}
.deal-editor-layout .current-stage-stage-name small{font-size:11px!important;color:#4F5FE5!important;font-weight:700!important;background:#E9EDFF!important;border-radius:7px!important;padding:3px 7px!important}
.deal-editor-layout .current-stage-deal-context{display:flex!important;flex-wrap:wrap!important;align-items:baseline!important;gap:5px!important;margin:0!important;color:#344054!important}
.deal-editor-layout .current-stage-deal-context b{font-weight:700!important}
/* Quick Create Customer: same blue-indigo language as lead form; preserve side-by-side position. */
.deal-layout-new>.customer-pane:not([hidden]){background:#FFFFFF!important;border:1px solid #DCE3EF!important;box-shadow:0 8px 24px rgba(52,64,84,.06)!important;border-radius:15px!important;color:#344054!important}
.deal-layout-new .customer-pane .eyebrow{color:#4F5FE5!important}
.deal-layout-new .customer-pane h2{color:#344054!important}
.deal-layout-new .customer-pane .muted{color:#667085!important}
.deal-layout-new .customer-pane label{color:#344054!important}
.deal-layout-new .customer-pane input,.deal-layout-new .customer-pane select,.deal-layout-new .customer-pane textarea{background:#FFFFFF!important;border-color:#DCE3EF!important;color:#344054!important}
.deal-layout-new .customer-pane input:focus,.deal-layout-new .customer-pane select:focus,.deal-layout-new .customer-pane textarea:focus{border-color:#4F5FE5!important;outline-color:#4F5FE5!important}
.deal-layout-new .customer-pane .close-pane{background:#E9EDFF!important;color:#4F5FE5!important;border-color:#DCE3FF!important}
.deal-layout-new .customer-pane .btn.primary{background:#4F5FE5!important;color:white!important}
/* Dashboard filters: retain existing layout, replace inconsistent lavender-filled input surfaces. */
html:not([data-theme="dark"]) .reporting-controls .period-select,
html:not([data-theme="dark"]) .reporting-controls input[type="date"]{background:#FFFFFF!important;color:#344054!important;border-color:#DCE3EF!important}
html:not([data-theme="dark"]) .reporting-controls .period-select:focus,
html:not([data-theme="dark"]) .reporting-controls input[type="date"]:focus{border-color:#4F5FE5!important;outline-color:#4F5FE5!important}
html[data-theme="dark"] .deal-layout-new>.customer-pane:not([hidden]){background:#1E2739!important;border-color:#37415C!important;color:#F3F5FF!important}
html[data-theme="dark"] .deal-layout-new .customer-pane h2,html[data-theme="dark"] .deal-layout-new .customer-pane label{color:#F3F5FF!important}
html[data-theme="dark"] .deal-layout-new .customer-pane .muted{color:#B2BDD3!important}
html[data-theme="dark"] .deal-layout-new .customer-pane input,html[data-theme="dark"] .deal-layout-new .customer-pane select,html[data-theme="dark"] .deal-layout-new .customer-pane textarea,
html[data-theme="dark"] .reporting-controls .period-select,html[data-theme="dark"] .reporting-controls input[type="date"]{background:#252D43!important;color:#F3F5FF!important;border-color:#37415C!important}
html[data-theme="dark"] .deal-editor-layout .current-stage-stage-name,html[data-theme="dark"] .deal-editor-layout .current-stage-deal-context{color:#F3F5FF!important}
html[data-theme="dark"] .deal-editor-layout .current-stage-heading>.small{color:#B2BDD3!important}
html[data-theme="dark"] .deal-editor-layout .current-stage-stage-name small{background:#354168!important;color:#C7D3FF!important}
/* Mobile: navigation begins at the same left inset as the logo and page content. */
@media(max-width:1000px){
 .topbar>.main-nav{box-sizing:border-box!important;justify-content:flex-start!important;align-items:stretch!important;gap:18px!important;padding:0!important;margin:0!important;width:100%!important;min-width:0!important;scroll-padding-left:0!important}
 .topbar>.main-nav a{flex:0 0 auto!important;margin:0!important;padding:0!important;justify-content:center!important;white-space:nowrap!important}
}
@media(max-width:760px){
 .topbar{padding-left:12px!important;padding-right:12px!important}
 .topbar>.main-nav{gap:18px!important;overflow-x:auto!important;scrollbar-width:none!important}
 .topbar>.main-nav::-webkit-scrollbar{display:none!important}
 .deal-editor-layout .current-stage{padding:12px!important}
}

/* v6.43 customer phone links and permanent Malaysia country-code field */
.phone-whatsapp-link{color:inherit;text-decoration:underline;text-decoration-color:transparent;text-underline-offset:2px;cursor:pointer}
.phone-whatsapp-link:hover,.phone-whatsapp-link:focus-visible{text-decoration-color:currentColor;color:var(--primary,#4f5fe5)}
.phone-prefix-field{display:flex;align-items:stretch;width:100%;min-width:0}
.phone-prefix{display:flex;align-items:center;justify-content:center;flex:0 0 auto;padding:0 13px;border:1px solid var(--border,#dce3ef);border-right:0;border-radius:9px 0 0 9px;background:var(--surface-2,#f0f3ff);color:inherit;font-weight:700}
.phone-prefix-field input{flex:1;min-width:0;width:100%;border-radius:0 9px 9px 0!important}
.customer-phone-display{min-height:42px;display:flex;align-items:center;padding:10px 12px;border:1px solid var(--border,#dce3ef);border-radius:9px;background:var(--surface,#fff)}
.customer-mobile-item .customer-mobile-info a{color:inherit}

/* v6.44 WhatsApp contact selector */
.contact-method-control{display:flex;flex-direction:column;gap:10px;min-width:0}.contact-radio-row{display:flex;align-items:center;flex-wrap:wrap;gap:14px}.contact-radio-row label{display:inline-flex;align-items:center;gap:6px;font-size:13px;font-weight:600;cursor:pointer}.contact-radio-row input{width:16px;height:16px;accent-color:#5368df}.contact-method-control [hidden]{display:none!important}.contact-method-control small{font-size:12px}.contact-method-control [data-contact-number],.contact-method-control [data-contact-username]{min-width:0}

/* v6.45: independent WhatsApp action, not nested in deal navigation */
.pipeline-card .see-conversation-btn{display:flex;align-items:center;justify-content:center;width:100%;min-height:40px;box-sizing:border-box;margin-top:10px;padding:9px 12px;border:1px solid #c8d2ff;border-radius:8px;background:#e9edff;color:#4f5fe5;font-size:13px;font-weight:750;text-decoration:none;text-align:center;cursor:pointer}
.pipeline-card .see-conversation-btn:hover,.pipeline-card .see-conversation-btn:focus-visible{background:#dce4ff;color:#3447ba}
html[data-theme="dark"] .pipeline-card .see-conversation-btn{background:#273456;color:#dbe5ff;border-color:#3b4967}
@media(max-width:760px){.pipeline-card .see-conversation-btn{min-height:43px;margin-top:10px}.pipeline-card .see-conversation-btn+.mobile-collapse-stage{margin-top:8px}}

/* v6.47 rebuilt from v6.45: stage headings and unified pipeline actions */
.deal-editor-layout .current-stage{display:flex!important;flex-direction:column!important;align-items:stretch!important;gap:13px!important;padding:15px 18px!important;background:#f1f3ff!important;border:1px solid #dce2fb!important;color:#344054!important}
.deal-editor-layout .current-stage-heading{display:flex!important;align-items:center!important;gap:12px!important;flex-wrap:nowrap!important}
.deal-editor-layout .current-stage-number{display:flex!important;align-items:center!important;justify-content:center!important;flex:0 0 48px!important;width:48px!important;height:48px!important;border-radius:11px!important;background:#e1e7ff!important;color:#4f5fe5!important;font-size:18px!important;font-weight:800!important;padding:0!important}
.deal-editor-layout .current-stage-heading-text{display:flex!important;flex-direction:column!important;gap:3px!important;min-width:0!important}
.deal-editor-layout .current-stage-caption{font-size:10px!important;line-height:1.3!important;letter-spacing:.8px!important;font-weight:750!important;color:#64748b!important}
.deal-editor-layout .current-stage-heading .current-stage-stage-name{font-size:17px!important;line-height:1.3!important;color:#344054!important;display:block!important}
.deal-editor-layout .current-stage-deal-context{display:flex!important;flex-wrap:wrap!important;gap:8px 23px!important;align-items:baseline!important;margin:0!important;padding-top:11px!important;border-top:1px solid #dce2fb!important;line-height:1.5!important;color:#344054!important}
.deal-editor-layout .current-stage-deal-context>*{font-size:12px!important;font-weight:500!important;color:inherit!important}
.deal-editor-layout .current-stage-deal-context b{font-weight:750!important}
.deal-editor-layout .current-stage-deal-context>*+*::before{content:none!important;display:none!important}
.stage-section summary .stage-accordion-title{display:flex!important;flex-direction:row!important;align-items:center!important;gap:10px!important;min-width:0!important}
.stage-section summary .stage-accordion-label{display:flex!important;flex-direction:column!important;gap:3px!important;min-width:0!important}
.stage-section summary .stage-completed-icon{color:#169b68!important;flex:0 0 20px!important;width:20px!important;height:20px!important}
.pipeline-card .see-conversation-btn,.pipeline-card .mobile-collapse-stage{width:100%!important;min-height:44px!important;height:auto!important;box-sizing:border-box!important;display:flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;padding:11px 12px!important;margin:10px 0 0!important;border:1px solid #c8d2ff!important;border-radius:9px!important;background:#e9edff!important;color:#4f5fe5!important;font-size:13px!important;font-weight:750!important;line-height:20px!important;text-align:center!important;text-decoration:none!important;cursor:pointer!important;box-shadow:none!important}
.pipeline-card .mobile-collapse-stage{margin-top:8px!important}
.pipeline-card .mobile-collapse-stage .collapse-stage-icon{display:block!important;flex:0 0 18px!important;width:18px!important;height:18px!important;color:inherit!important}
.pipeline-card .mobile-collapse-stage>span{display:inline!important;line-height:20px!important;margin:0!important;padding:0!important}
.pipeline-card .see-conversation-btn:hover,.pipeline-card .mobile-collapse-stage:hover{background:#dce4ff!important}
html[data-theme="dark"] .deal-editor-layout .current-stage{background:#273456!important;border-color:#425071!important;color:#e6edff!important}
html[data-theme="dark"] .deal-editor-layout .current-stage-heading .current-stage-stage-name,html[data-theme="dark"] .deal-editor-layout .current-stage-deal-context{color:#e6edff!important}
html[data-theme="dark"] .deal-editor-layout .current-stage-caption{color:#b2bdd3!important}
html[data-theme="dark"] .deal-editor-layout .current-stage-number{background:#354168!important;color:#c7d3ff!important}
html[data-theme="dark"] .deal-editor-layout .current-stage-deal-context{border-color:#425071!important}
html[data-theme="dark"] .pipeline-card .see-conversation-btn,html[data-theme="dark"] .pipeline-card .mobile-collapse-stage{background:#273456!important;color:#dbe5ff!important;border-color:#3b4967!important}
@media(min-width:761px){.pipeline-card .mobile-collapse-stage{display:none!important}}
@media(max-width:760px){.deal-editor-layout .current-stage{padding:12px!important}.deal-editor-layout .current-stage-number{flex-basis:42px!important;width:42px!important;height:42px!important}.deal-editor-layout .current-stage-deal-context{gap:7px 17px!important}}

/* v6.48: consistent stage controls and full-width actions */
.pipeline-stage-summary .count-pill,.pipeline-stage-summary .archive-toggle-button{width:30px!important;height:30px!important;min-width:30px!important;flex:0 0 30px!important;box-sizing:border-box!important;border:1px solid #d4dcf5!important;border-radius:8px!important;display:grid!important;place-items:center!important;margin:0!important;padding:0!important;background:#e9edff!important;color:#4f5fe5!important;font-size:12px!important;font-weight:750!important;line-height:1!important}
.pipeline-stage-summary .count-pill{margin-left:auto!important}
.pipeline-stage-summary .archive-toggle-button::after{content:none!important;display:none!important}
.pipeline-stage-summary .archive-toggle-button .stage-chevron-icon{display:block!important;width:16px!important;height:16px!important;transition:transform .15s ease;transform:rotate(0deg)}
.pipeline-stage[open]>.pipeline-stage-summary .archive-toggle-button .stage-chevron-icon{transform:rotate(180deg)}
.pipeline-card .see-conversation-btn,.pipeline-card .mobile-collapse-stage{display:flex!important;box-sizing:border-box!important;width:100%!important;min-height:52px!important;height:52px!important;padding:10px 12px!important;align-items:center!important;justify-content:center!important;gap:9px!important;margin:9px 0 0!important;background:#ecefff!important;color:#4f5fe5!important;border:1px solid #c4cfff!important;border-radius:9px!important;font-size:14px!important;font-weight:700!important;line-height:20px!important;text-decoration:none!important;text-align:center!important;box-shadow:none!important;cursor:pointer!important}
.pipeline-card .mobile-collapse-stage{margin-top:8px!important}
.pipeline-card .see-conversation-btn svg,.pipeline-card .mobile-collapse-stage svg{width:17px!important;height:17px!important;flex:0 0 17px!important;display:block!important;vertical-align:middle!important}
.pipeline-card .see-conversation-btn span,.pipeline-card .mobile-collapse-stage span{display:inline-block!important;line-height:20px!important}
.pipeline-card .see-conversation-btn:hover,.pipeline-card .mobile-collapse-stage:hover{background:#dce4ff!important}
html[data-theme="dark"] .pipeline-stage-summary .count-pill,html[data-theme="dark"] .pipeline-stage-summary .archive-toggle-button{background:#273456!important;color:#dbe5ff!important;border-color:#3b4967!important}
html[data-theme="dark"] .pipeline-card .see-conversation-btn,html[data-theme="dark"] .pipeline-card .mobile-collapse-stage{background:#273456!important;color:#dbe5ff!important;border-color:#3b4967!important}

/* v6.49: compact, identical pipeline action buttons */
.pipeline-card .see-conversation-btn,
.pipeline-card .mobile-collapse-stage {
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  box-sizing:border-box!important;
  width:100%!important;
  height:38px!important;
  min-height:38px!important;
  max-height:38px!important;
  padding:0 10px!important;
  margin:8px 0 0!important;
  gap:8px!important;
  border-radius:8px!important;
  font-size:13px!important;
  font-weight:700!important;
  line-height:1!important;
}
.pipeline-card .see-conversation-btn svg,
.pipeline-card .mobile-collapse-stage svg {
  width:16px!important;
  height:16px!important;
  flex:0 0 16px!important;
}
.pipeline-card .see-conversation-btn span,
.pipeline-card .mobile-collapse-stage span {line-height:1!important;}

/* v6.50: improve desktop notification message readability to match pipeline updates */
@media (min-width:761px){
 .notification-panel .notification-update-line,
 .notification-panel .notification-update-line .notification-note-text{font-size:11px!important;font-weight:750!important;line-height:1.45!important;letter-spacing:0!important}
 .notification-panel .notification-update-line .notification-note-text{color:#344F9D!important}
 html[data-theme="dark"] .notification-panel .notification-update-line .notification-note-text{color:#C7D2FE!important}
}

/* v6.52 conversation layout and Gmail-like attention selector */
.deal-conversation{display:flex;flex-direction:column;gap:13px;margin-top:16px;padding:15px;border-radius:12px;background:var(--paper);border:1px solid var(--line)}
.deal-bubble-row{display:flex;width:100%}.deal-bubble-row.mine{justify-content:flex-end}.deal-bubble-row.theirs{justify-content:flex-start}
.deal-bubble{max-width:min(82%,670px);min-width:190px;border-radius:13px;border:1px solid var(--line);padding:12px 14px;background:var(--white);overflow-wrap:anywhere}
.deal-bubble.bubble-own{background:#e9edff;border-color:#cbd5ff}
.deal-bubble-content p{margin:0 0 8px;white-space:pre-wrap;font-size:13px;line-height:1.55;color:var(--ink)}
.deal-bubble-kind{display:flex;align-items:center;gap:6px;color:#4f5fe5;font-size:12px;font-weight:800;margin-bottom:7px}
.deal-bubble-footer{border-top:1px solid var(--line);padding-top:8px;margin-top:9px;display:flex;align-items:center;gap:7px;min-width:0}
.deal-bubble-avatar{display:grid;place-items:center;width:24px;height:24px;flex:0 0 24px;border-radius:50%;background:#dbe3ff;color:#4359c7;font-size:10px;font-weight:800}
.deal-bubble-footer strong{font-size:11px;min-width:0;overflow-wrap:anywhere}.deal-bubble-footer time{font-size:10px;color:var(--muted);margin-left:auto;text-align:right;white-space:nowrap}
.deal-attachment-link,.deal-attachment-missing{display:flex;align-items:center;flex-wrap:wrap;gap:7px;padding:9px 11px;background:var(--white);border:1px solid var(--line);border-radius:8px;color:#4f5fe5;font-size:12px;font-weight:700;overflow-wrap:anywhere}
.deal-attachment-link small,.deal-attachment-missing small{width:100%;padding-left:22px;color:var(--muted);font-size:10px}.deal-attachment-link:hover{text-decoration:underline}
.attachment-row:target{outline:2px solid #5b6ce2;outline-offset:2px;background:#eef0ff;scroll-margin-top:100px}
.deal-update-form{gap:8px!important}.deal-update-form .attention-picker{gap:5px}.deal-update-form .attention-picker-input{display:flex;flex-wrap:wrap;align-items:center;gap:6px;border:1px solid var(--line);border-radius:9px;background:var(--white);padding:5px 8px;min-height:39px}
.deal-update-form .attention-picker-input input{width:auto;flex:1 1 130px;min-width:90px;border:0!important;box-shadow:none!important;padding:6px!important;background:transparent!important}
.deal-update-form .attention-chips{display:contents}.deal-update-form .attention-chips .attention-chip{max-width:100%}
.deal-update-form .attention-suggestions{top:100%;left:0;right:0}
.topbar .user-menu .header-icon-button,.topbar .user-menu .account-toggle{width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important;flex:0 0 38px!important;border-radius:10px!important;box-sizing:border-box!important}
html[data-theme="dark"] .deal-bubble.bubble-own{background:#253257;border-color:#46588b}html[data-theme="dark"] .deal-bubble-avatar{background:#39497b;color:#dce4ff}
@media(max-width:760px){.deal-conversation{padding:9px}.deal-bubble{max-width:90%;padding:10px}.deal-bubble-footer{flex-wrap:wrap}.deal-bubble-footer time{font-size:9px}}


/* v6.53 compact, 90%-width deal conversation bubbles */
.deal-conversation{gap:4px!important;padding:8px!important}
.deal-bubble-row{width:100%;min-width:0}
.deal-bubble{width:90%!important;max-width:90%!important;min-width:0!important;padding:4px 8px!important;border-radius:8px!important;box-sizing:border-box!important}
.deal-bubble-content{display:flex;flex-direction:column;gap:2px;min-width:0}
.deal-bubble-content p{font-size:12px!important;line-height:1.25!important;margin:0!important;overflow-wrap:anywhere}
.deal-bubble-kind{font-size:11px!important;line-height:1.2!important;margin:0!important;gap:4px!important}
.deal-bubble-kind svg{width:12px;height:12px}
.deal-bubble-footer{border-top:0!important;padding:0!important;margin:2px 0 0!important;gap:5px!important;min-height:16px!important;flex-wrap:nowrap!important}
.deal-bubble-avatar{width:16px!important;height:16px!important;flex:0 0 16px!important;font-size:9px!important}
.deal-bubble-footer strong{font-size:10px!important;line-height:1.2!important}
.deal-bubble-footer time{font-size:9px!important;line-height:1.2!important;white-space:nowrap}
.deal-bubble .update-attention-line{margin:0!important;padding:0!important;gap:4px!important}
.deal-bubble .deal-attachment-link,.deal-bubble .deal-attachment-missing{padding:5px 7px!important;gap:4px!important}
.deal-bubble .deal-attachment-link small,.deal-bubble .deal-attachment-missing small{padding-left:0!important}
/* Bell and account avatar: identical outer boxes and visible clickable surfaces. */
.topbar .user-menu .notification-wrap,.topbar .user-menu .account-wrap{display:flex!important;align-items:center!important;justify-content:center!important;flex:0 0 38px!important;width:38px!important;min-width:38px!important;height:38px!important}
.topbar .user-menu #notification-toggle,.topbar .user-menu #account-toggle{display:grid!important;place-items:center!important;flex:0 0 38px!important;width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important;padding:0!important;border-radius:10px!important;box-sizing:border-box!important}
.topbar .user-menu #account-toggle{background:#e9edff!important;border:1px solid #c9d3ff!important}
.topbar .user-menu #account-toggle .user-dot{width:100%!important;height:100%!important;display:grid!important;place-items:center!important;border:0!important;border-radius:9px!important;background:transparent!important;box-shadow:none!important;font-size:15px!important}
html[data-theme="dark"] .topbar .user-menu #account-toggle{background:#273456!important;border-color:#46588b!important}
@media(max-width:1000px){.topbar .user-menu .notification-wrap,.topbar .user-menu .account-wrap,.topbar .user-menu #notification-toggle,.topbar .user-menu #account-toggle{width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important;flex-basis:38px!important}}
@media(max-width:760px){.deal-conversation{padding:6px!important}.deal-bubble{width:90%!important;max-width:90%!important;padding:4px 8px!important}.deal-bubble-footer{flex-wrap:nowrap!important}}

/* v6.54 attachment viewer unified indigo controls and image zoom */
#attachment-viewer .attachment-viewer-head{background:var(--white,#fff)!important;color:var(--ink,#27344c)!important;border-bottom:1px solid var(--line,#dce3f6)!important;}
#attachment-viewer .attachment-viewer-head strong{color:var(--ink,#27344c)!important;}
#attachment-viewer .attachment-viewer-actions .btn,#attachment-viewer #close-attachment-viewer{display:inline-flex!important;align-items:center!important;justify-content:center!important;min-height:34px!important;background:#e9edff!important;color:#4f5fe5!important;border:1px solid #cdd5ff!important;border-radius:8px!important;opacity:1!important;}
#attachment-viewer #close-attachment-viewer{width:34px!important;height:34px!important;padding:0!important;font-size:22px!important;line-height:1!important;}
#attachment-viewer .attachment-viewer-actions .btn:hover,#attachment-viewer #close-attachment-viewer:hover{background:#dbe2ff!important;color:#3547c5!important;}
#attachment-viewer.gallery-is-image .attachment-preview{overflow:hidden!important;touch-action:pan-y;}
#attachment-viewer.gallery-is-image .attachment-preview img:not(.gallery-sliding-in){user-select:none;-webkit-user-drag:none;max-width:100%;max-height:100%;object-fit:contain;will-change:transform;}
html[data-theme=dark] #attachment-viewer .attachment-viewer-head{background:#24253c!important;color:#e9edff!important;border-color:#464968!important;}
html[data-theme=dark] #attachment-viewer .attachment-viewer-head strong{color:#e9edff!important;}
html[data-theme=dark] #attachment-viewer .attachment-viewer-actions .btn,html[data-theme=dark] #attachment-viewer #close-attachment-viewer{background:#353a63!important;color:#cbd4ff!important;border-color:#545b93!important;}
html[data-theme=dark] #attachment-viewer .attachment-viewer-actions .btn:hover,html[data-theme=dark] #attachment-viewer #close-attachment-viewer:hover{background:#424b82!important;}
/* v6.54 drag feedback, no changes to server stage validation */
.pipeline-card{transition:transform 180ms ease,box-shadow 180ms ease,opacity 180ms ease,border-color 180ms ease;}
.pipeline-card.dragging{opacity:.52;transform:scale(.985);box-shadow:0 10px 25px rgba(66,80,160,.16);}
.drop-zone{transition:background-color 180ms ease,box-shadow 180ms ease;}
.drop-zone.drag-over{background:rgba(87,104,226,.07)!important;box-shadow:inset 0 0 0 2px rgba(87,104,226,.4);border-radius:12px;}
.drop-zone.drag-target-ready{padding-bottom:16px;transition:padding-bottom 180ms ease,background-color 180ms ease;}
.pipeline-card.stage-move-success{transform:scale(.975);opacity:.7;}
@media(prefers-reduced-motion:reduce){.pipeline-card,.drop-zone{transition:none!important;}}

/* v6.55: activity jump targets */
.deal-bubble[role="button"]{cursor:pointer;transition:box-shadow .18s ease,transform .18s ease}
.deal-bubble[role="button"]:hover{box-shadow:0 4px 15px rgba(65,76,146,.14)}
.deal-bubble[role="button"]:focus-visible{outline:2px solid #6877e5;outline-offset:3px}
@keyframes update-jump{0%,35%{outline:3px solid #7785ff;outline-offset:3px}100%{outline:3px solid transparent;outline-offset:5px}}
.pipeline-card.kanban-ghost{opacity:.2}
.kanban-floating{position:fixed!important;z-index:9999!important;pointer-events:none!important;transform:rotate(1.5deg) scale(1.025);box-shadow:0 16px 40px rgba(15,25,65,.24)!important;transition:none!important}
.kanban-placeholder{border:2px dashed #7885ee;border-radius:12px;min-height:76px;background:rgba(99,112,235,.08)}
@media(prefers-reduced-motion:reduce){.kanban-floating{transition:none}}

/* v6.56: attachment camera capture and accessible square icon actions */
#attachments .upload-form{display:inline-flex!important;vertical-align:middle;align-items:center;max-width:calc(100% - 55px);margin-right:8px!important;gap:8px!important}
#attachments .camera-upload-form{display:inline-flex!important;vertical-align:middle;align-items:center;margin:0!important}
#attachments .camera-capture-button{width:40px;height:40px;display:inline-flex;align-items:center;justify-content:center;border:1px solid #b8c5f8;border-radius:9px;background:#edf0ff;color:#4559d3;cursor:pointer;padding:0;transition:background .15s,border-color .15s}
#attachments .camera-capture-button:hover{background:#dfe6ff;border-color:#6576dd}
#attachments .attachment-row .attachment-share-row,#attachments .attachment-row .attachment-download-row,#attachments .attachment-row .attachment-delete{width:38px!important;min-width:38px!important;height:38px!important;min-height:38px!important;padding:0!important;border-radius:9px!important;background:#edf0ff!important;border:1px solid #cdd5fa!important;color:#4559d3!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;line-height:0!important}
#attachments .attachment-row .attachment-delete{color:#b63b56!important;background:#fff0f3!important;border-color:#f0c6cf!important}
#attachments .attachment-row .attachment-share-row:hover,#attachments .attachment-row .attachment-download-row:hover{background:#dfe5ff!important}
#attachments .attachment-row .attachment-delete:hover{background:#ffe1e7!important}
#attachments .attachment-row .attachment-open{background:#f0f2ff!important;border:1px solid #d3dbff!important;border-radius:9px!important;color:#4053c8!important;padding:8px!important}
#attachments .attachment-row .attachment-open:hover,#attachments .attachment-row .attachment-open:focus-visible{background:#e2e8ff!important;border-color:#7181e5!important;outline:0}
#attachment-viewer .attachment-viewer-actions #attachment-share,#attachment-viewer .attachment-viewer-actions #attachment-download{width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important;padding:0!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;line-height:0!important}
.deal-update-form .attention-chip-selected button{width:16px!important;height:16px!important;min-width:16px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;padding:0!important;margin:0 0 0 3px!important;font-size:15px!important;line-height:1!important;vertical-align:middle!important;flex-shrink:0!important}
/* Active stage is distinguishable from previous and future stages */
.deal-editor-main .stage-section.stage-active{border:2px solid #5367dc!important;background:#f0f2ff!important;box-shadow:0 0 0 2px rgba(83,103,220,.07)!important}
.deal-editor-main .stage-section.stage-active>summary{background:#e7ebff!important;color:#3449c1!important;border-radius:9px!important}
.deal-editor-main .stage-section.stage-active>summary .stage-accordion-label strong{color:#3449c1!important;font-weight:850!important}
.deal-editor-main .stage-section.stage-active>summary .stage-accordion-label:before{content:'CURRENT STAGE';display:block;color:#5367dc;font-size:9px;letter-spacing:.07em;font-weight:850;line-height:1.1}
html[data-theme="dark"] #attachments .camera-capture-button,html[data-theme="dark"] #attachments .attachment-row .attachment-share-row,html[data-theme="dark"] #attachments .attachment-row .attachment-download-row{background:#343d69!important;color:#d3dbff!important;border-color:#57629a!important}
html[data-theme="dark"] #attachments .attachment-row .attachment-delete{background:#512b3b!important;color:#ffb6c6!important;border-color:#81465d!important}
html[data-theme="dark"] #attachments .attachment-row .attachment-open{background:#30375b!important;color:#d8ddff!important;border-color:#505d91!important}
html[data-theme="dark"] #attachments .attachment-row .attachment-open:hover{background:#3c487b!important}
html[data-theme="dark"] .deal-editor-main .stage-section.stage-active{background:#252d52!important;border-color:#8796ff!important}
html[data-theme="dark"] .deal-editor-main .stage-section.stage-active>summary{background:#303b6a!important;color:#e3e8ff!important}
html[data-theme="dark"] .deal-editor-main .stage-section.stage-active>summary .stage-accordion-label strong{color:#edf0ff!important}
html[data-theme="dark"] .deal-editor-main .stage-section.stage-active>summary .stage-accordion-label:before{color:#b9c5ff!important}
@media(max-width:760px){#attachments .upload-form{max-width:calc(100% - 54px)}#attachments .attachment-row .attachment-share-row,#attachments .attachment-row .attachment-download-row,#attachments .attachment-row .attachment-delete{width:36px!important;min-width:36px!important;height:36px!important;min-height:36px!important}}

/* SalesDesk v6.57 — compact, consistent controls */
.deal-update-form .attention-chip-selected button{appearance:none!important;display:grid!important;place-items:center!important;flex:0 0 16px!important;width:16px!important;height:16px!important;min-height:16px!important;padding:0!important;margin:0 0 0 3px!important;border:0!important;font:400 17px/1 Arial,sans-serif!important;text-align:center!important;transform:none!important}
.v657-actions{display:flex!important;align-items:center!important;gap:8px!important;flex-wrap:nowrap!important;width:100%!important}
.v657-actions>.btn,.v657-actions .v657-move-wrap>.btn{width:clamp(94px,26vw,190px)!important;min-width:0!important;max-width:190px!important;height:42px!important;min-height:42px!important;padding:0 8px!important;display:inline-flex!important;justify-content:center!important;align-items:center!important;font-size:12px!important;line-height:1.1!important;text-align:center!important;white-space:normal!important;box-sizing:border-box!important}
.v657-move-wrap{margin-left:auto!important;position:relative;flex:0 0 auto}.v657-move-menu{position:absolute;right:0;bottom:calc(100% + 6px);min-width:200px;max-width:min(85vw,320px);max-height:260px;overflow:auto;z-index:15;border:1px solid var(--line);border-radius:10px;background:var(--white);box-shadow:0 8px 30px rgba(0,0,0,.14);padding:5px}.v657-move-menu[hidden]{display:none!important}.v657-move-menu button{display:block;width:100%;text-align:left;background:transparent;color:var(--ink);border:0;border-radius:6px;padding:10px;cursor:pointer}.v657-move-menu button:hover{background:var(--paper)}
#attachments .v657-upload-row{display:flex!important;align-items:center!important;gap:8px!important;width:100%;min-width:0;margin-bottom:12px}
#attachments .v657-upload-row .upload-form{display:flex!important;align-items:center!important;flex:1 1 auto!important;max-width:none!important;min-width:0!important;gap:8px!important;margin:0!important;flex-direction:row!important;flex-wrap:nowrap!important}
#attachments .v657-upload-row .upload-form input[type=file]{flex:1 1 auto!important;min-width:0!important;width:0!important;height:40px!important;max-height:40px!important;padding:6px!important;font-size:11px!important;box-sizing:border-box!important}
#attachments .v657-upload-row .upload-form .btn{flex:0 0 auto!important;height:40px!important;min-height:40px!important;padding:0 10px!important;white-space:nowrap!important}
#attachments .v657-upload-row .camera-upload-form{flex:0 0 40px!important;display:flex!important;margin:0!important}
#attachments .v657-upload-row .camera-capture-button{width:40px!important;min-width:40px!important;height:40px!important;min-height:40px!important;padding:0!important;background:var(--white)!important;color:var(--ink)!important;border:1px solid var(--line)!important;box-shadow:none!important}
#attachments .attachment-row{background:transparent!important;padding:5px!important;grid-template-columns:minmax(0,1fr) repeat(3,38px)!important;grid-template-rows:38px!important;gap:5px!important}
#attachments .attachment-row .attachment-open{height:38px!important;min-height:38px!important;padding:0 8px!important;display:flex!important;align-items:center!important;overflow:hidden!important;background:var(--white)!important;color:var(--ink)!important;border:1px solid var(--line)!important}
#attachments .attachment-row .attachment-file-name{white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;min-width:0!important;display:block!important}
#attachments .attachment-row .attachment-share-row,#attachments .attachment-row .attachment-download-row,#attachments .attachment-row .attachment-delete{width:38px!important;min-width:38px!important;height:38px!important;min-height:38px!important;background:var(--white)!important;border:1px solid var(--line)!important;color:var(--ink)!important;border-radius:9px!important;padding:0!important}
#attachments .attachment-row .attachment-delete{color:#b94a56!important}
#attachments .attachment-row .attachment-open:hover,#attachments .attachment-row .attachment-share-row:hover,#attachments .attachment-row .attachment-download-row:hover,#attachments .v657-upload-row .camera-capture-button:hover{background:var(--paper)!important;color:var(--ink)!important;border-color:var(--line)!important}
#attachment-viewer .attachment-viewer-actions .btn,#attachment-viewer #close-attachment-viewer,#attachment-viewer .attachment-image-nav .btn{width:38px!important;min-width:38px!important;height:38px!important;min-height:38px!important;padding:0!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;background:var(--white)!important;color:var(--ink)!important;border:1px solid var(--line)!important;border-radius:9px!important;line-height:1!important;font-size:18px!important}
#attachment-viewer .attachment-image-nav .btn{font-size:0!important}#attachment-viewer #attachment-prev:before{content:'‹';font-size:25px}#attachment-viewer #attachment-next:before{content:'›';font-size:25px}
#attachment-viewer .attachment-viewer-actions .btn:hover,#attachment-viewer #close-attachment-viewer:hover{background:var(--paper)!important;color:var(--ink)!important}
html[data-theme=dark] #attachments .attachment-row .attachment-open,html[data-theme=dark] #attachments .attachment-row .attachment-share-row,html[data-theme=dark] #attachments .attachment-row .attachment-download-row,html[data-theme=dark] #attachments .attachment-row .attachment-delete,html[data-theme=dark] #attachments .v657-upload-row .camera-capture-button,html[data-theme=dark] #attachment-viewer .attachment-viewer-actions .btn,html[data-theme=dark] #attachment-viewer #close-attachment-viewer,html[data-theme=dark] #attachment-viewer .attachment-image-nav .btn{background:var(--white)!important;color:var(--ink)!important;border-color:var(--line)!important}
html[data-theme=dark] #attachments .attachment-row .attachment-delete{color:#f2a0aa!important}
@media(max-width:760px){.v657-actions{gap:5px!important}.v657-actions>.btn,.v657-actions .v657-move-wrap>.btn{width:clamp(90px,28vw,160px)!important;font-size:11px!important;padding:0 4px!important}#attachments .attachment-row{grid-template-columns:minmax(0,1fr) repeat(3,38px)!important;grid-template-rows:38px!important}#attachments .attachment-row .attachment-open{grid-column:1!important;grid-row:1!important}#attachments .attachment-row .attachment-share-row{grid-column:2!important;grid-row:1!important}#attachments .attachment-row .attachment-download-row{grid-column:3!important;grid-row:1!important}#attachments .attachment-row form{grid-column:4!important;grid-row:1!important}#attachments .v657-upload-row{gap:5px!important}#attachments .v657-upload-row .upload-form{gap:5px!important}#attachments .v657-upload-row .upload-form .btn{font-size:11px!important;padding:0 7px!important}}

/* SalesDeskPRO v6.58 */
.brand-word,.brand-pro{color:#171717}.brand-light{color:#5968da;font-weight:inherit}html[data-theme="dark"] .brand-word,html[data-theme="dark"] .brand-pro{color:#f2f5ff}html[data-theme="dark"] .brand-light{color:#9aa9ff}
.deal-list-panel{max-width:none}.deal-list-filters{display:grid;grid-template-columns:minmax(170px,2fr) repeat(4,minmax(120px,1fr));gap:10px;margin:16px 0}.deal-list-filters label{display:flex;flex-direction:column;gap:5px;font-size:12px;font-weight:650;min-width:0}.deal-list-filters input,.deal-list-filters select{width:100%;height:40px}.deal-list-scroll{width:100%;overflow-x:auto}.deal-list-table{width:100%;min-width:1060px;border-collapse:collapse;text-align:left}.deal-list-table th,.deal-list-table td{padding:12px 10px;border-bottom:1px solid var(--line);font-size:12px;vertical-align:middle}.deal-list-table th{white-space:nowrap;font-size:11px}.deal-list-table tr[hidden]{display:none}.deal-list-table td:nth-child(3){min-width:150px}.dl-money{white-space:nowrap;font-weight:700}.dl-closing,.dl-priority{display:inline-flex;align-items:center;justify-content:center;border-radius:7px;padding:5px 9px;color:#fff;font-size:11px;font-weight:750;white-space:nowrap}.dl-closing{background:hsl(calc((var(--pct) - 10)*1.35) 66% 39%)}.dl-low{background:#3179c9}.dl-normal{background:#2d9665}.dl-high{background:#d65353}.dl-urgent{background:#9d2536}.dl-actions{display:flex;gap:7px}.dl-actions a{width:35px;height:35px;display:inline-flex;align-items:center;justify-content:center;border:1px solid var(--line);border-radius:8px;color:var(--ink);font-size:18px}.dl-actions a:hover{border-color:#5968da;color:#5968da}html[data-theme="dark"] .dl-actions a{color:#e4e9f5}html[data-theme="dark"] .dl-actions a:hover{color:#9aa9ff}@media(max-width:850px){.deal-list-filters{grid-template-columns:repeat(2,minmax(0,1fr))}.deal-list-filters label:first-child{grid-column:1/-1}.deal-list-table{min-width:1050px}}

/* v6.59 */
.reporting-controls .custom-range-toolbar input[type="date"]{height:38px!important;min-height:38px!important;box-sizing:border-box}
#attachments .attachment-row .attachment-open,#attachments .attachment-row .attachment-open .attachment-file-name{background:transparent!important;background-color:transparent!important;box-shadow:none!important}
#attachments .attachment-row .attachment-open{border-color:var(--line)!important}
.deal-list-table{min-width:830px;text-align:center}
.deal-list-table th,.deal-list-table td{text-align:center!important;vertical-align:middle}
.deal-list-table th{text-transform:none!important;letter-spacing:normal!important;font-size:12px!important}
.deal-list-table .dl-actions{justify-content:center}
.deal-list-table td:nth-child(3){min-width:unset}
.dl-sort-header{border:0;background:none;color:inherit;font:inherit;font-weight:inherit;padding:0;display:inline-flex;gap:4px;align-items:center;justify-content:center;cursor:pointer;white-space:nowrap}
.dl-sort-icon{opacity:.35;flex:none}.dl-sort-header.active .dl-sort-icon{opacity:1;color:#5968da}.dl-sort-header.desc .dl-sort-icon{transform:rotate(180deg)}
.dl-actions svg{display:block}
.pipeline-closing-pill{font-size:10px!important;padding:3px 7px!important}
.back-pipeline-button{display:inline-flex;align-items:center;gap:5px}
.v657-move-wrap .btn svg{vertical-align:middle;flex:none}

/* v6.60: percentage uses same sizing as other pipeline status pills */
.pipeline-card .card-badges .pipeline-closing-pill{display:inline-flex;align-items:center;justify-content:center;max-width:100%;border-radius:7px;padding:5px 7px;font-size:10px;font-weight:800;line-height:1.25;border:1px solid transparent;white-space:nowrap;background:hsl(calc((var(--pct) - 10)*1.35) 66% 39%);color:#fff}
.deal-list-table tbody tr.dl-clickable-row{cursor:pointer;transition:background-color .15s ease}
.deal-list-table tbody tr.dl-clickable-row:hover{background:var(--surface-hover,rgba(91,104,218,.065))}
.deal-list-table tbody tr.dl-clickable-row:focus-visible{outline:2px solid #5968da;outline-offset:-2px}

/* v6.61 mobile Deal List: no horizontal table scrolling */
.dl-mobile-only{display:none}
@media(max-width:767px){
 .deal-list-panel{padding:14px!important}
 .deal-list-panel>.panel-head{align-items:center!important;margin-bottom:7px!important;gap:8px!important}
 .deal-list-panel>.panel-head h1{font-size:23px!important;margin:0!important}
 .deal-list-panel>.panel-head p{display:none!important}
 .deal-list-panel>.panel-head .btn{padding:9px 11px!important;font-size:11px!important}
 .deal-list-panel #dl-count{margin:0 0 10px!important}
 .deal-list-scroll{display:none!important}
 .dl-mobile-only{display:block}
 .dl-mobile-sort{display:flex;align-items:center;gap:7px;margin-bottom:10px}
 .dl-mobile-sort label{font-size:11px;font-weight:700;white-space:nowrap;color:var(--muted)}
 .dl-mobile-sort select{flex:1;height:36px;padding:5px 9px;background:var(--white);color:var(--ink);border:1px solid var(--line);border-radius:8px}
 .dl-mobile-sort button{height:36px;width:38px;flex:none;display:grid;place-items:center;border:1px solid var(--line);border-radius:8px;background:var(--white);color:var(--ink);cursor:pointer}
 .dl-mobile-sort button.descending svg{transform:rotate(180deg)}
 .dl-mobile-cards{display:grid;gap:9px}
 .dl-mobile-card{background:var(--white);border:1px solid var(--line);border-radius:11px;padding:11px;display:grid;gap:9px;cursor:pointer;min-width:0}
 .dl-mobile-card:focus-visible{outline:2px solid #5968da;outline-offset:2px}
 .dl-card-heading{display:flex;gap:8px;align-items:center;justify-content:space-between;min-width:0}
 .dl-card-heading>svg{color:var(--muted);flex:none}
 .dl-card-names{display:flex;flex-direction:column;gap:2px;min-width:0}
 .dl-card-names strong{font-size:13px;line-height:1.3;overflow-wrap:anywhere}
 .dl-card-names span{font-size:11px;line-height:1.35;color:var(--muted);overflow-wrap:anywhere}
 .dl-card-detail{display:flex;justify-content:space-between;align-items:baseline;gap:9px;font-size:11px;color:var(--muted)}
 .dl-card-detail strong{font-size:12px;color:var(--ink);white-space:nowrap}
 .dl-card-footer{display:flex;gap:6px;align-items:center}
 .dl-card-footer .dl-priority,.dl-card-footer .dl-closing{border-radius:7px;font-size:10px;padding:4px 8px}
 .dl-card-spacer{flex:1}
 .dl-card-whatsapp{display:grid;place-items:center;width:32px;height:32px;border:1px solid var(--line);border-radius:8px;color:#238451}
}

/* v6.61 slim animated Edit Deal context: stays below the actual navigation height */
.deal-page-heading .eyebrow{display:none!important}
.deal-editor-layout .current-stage{gap:7px!important;padding:9px 11px!important}
.deal-editor-layout .current-stage-heading{gap:8px!important}
.deal-editor-layout .current-stage-number{flex:0 0 36px!important;width:36px!important;height:36px!important;font-size:14px!important;border-radius:8px!important}
.deal-editor-layout .current-stage-heading-text{gap:1px!important}
.deal-editor-layout .current-stage-deal-context{padding-top:7px!important;gap:3px 11px!important;line-height:1.3!important}
.deal-sticky-number{display:grid;place-items:center;flex:none;min-width:29px;height:29px;padding:0 5px;border-radius:7px;background:#dce3ff;color:#4f5fe5;font-size:11px;font-weight:800}
.deal-sticky-info{display:flex;flex-direction:column;min-width:0;flex:1;gap:0;line-height:1.3}
.deal-sticky-top{display:flex;align-items:baseline;justify-content:space-between;gap:8px;min-width:0}
.deal-sticky-top strong{font-size:12px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.deal-sticky-top small{font-size:10px;color:#5968da;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex-shrink:1}
.deal-sticky-title{font-size:10px;color:#69748c;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
html[data-theme="dark"] .deal-sticky-number{background:#354168;color:#c7d3ff}
html[data-theme="dark"] .deal-sticky-top small{color:#b7c4ff}
html[data-theme="dark"] .deal-sticky-title{color:#b2bdd5}
@media(max-width:767px){.deal-editor-layout .current-stage-deal-context{flex-direction:column!important;align-items:flex-start!important;gap:2px!important}}
@media(prefers-reduced-motion:reduce){}

/* v6.61 attachments: one themed tint on the OUTER row, not white controls */
#attachments .attachment-row{background:#edf0ff!important;border:1px solid #d8defa!important;border-radius:9px!important;padding:3px 5px!important;gap:4px!important;grid-template-columns:minmax(0,1fr) repeat(3,32px)!important;grid-template-rows:34px!important;min-height:42px!important}
#attachments .attachment-row .attachment-open{height:34px!important;min-height:34px!important;padding:0 5px!important;border:0!important;background:transparent!important;color:#26334b!important}
#attachments .attachment-row .attachment-file-details{display:flex;flex-direction:column;align-items:flex-start;min-width:0;flex:1;gap:0;line-height:1.2}
#attachments .attachment-row .attachment-file-name{font-size:11px!important;font-weight:650!important;line-height:1.2!important;color:inherit!important}
#attachments .attachment-row .attachment-file-meta{font-size:9px!important;font-weight:400!important;line-height:1.2!important;color:#68748b!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}
#attachments .attachment-row .attachment-share-row,#attachments .attachment-row .attachment-download-row,#attachments .attachment-row .attachment-delete{height:32px!important;min-height:32px!important;width:32px!important;min-width:32px!important;background:transparent!important;border:0!important;color:#53627a!important;border-radius:7px!important}
#attachments .attachment-row .attachment-delete{color:#c74b55!important}
#attachments .attachment-row .attachment-open:hover,#attachments .attachment-row .attachment-share-row:hover,#attachments .attachment-row .attachment-download-row:hover{background:rgba(91,108,226,.10)!important}
html[data-theme="dark"] #attachments .attachment-row{background:#252e4a!important;border-color:#3a4774!important}
html[data-theme="dark"] #attachments .attachment-row .attachment-open{background:transparent!important;color:#f1f4ff!important;border:0!important}
html[data-theme="dark"] #attachments .attachment-row .attachment-file-meta{color:#b2bdd5!important}
html[data-theme="dark"] #attachments .attachment-row .attachment-share-row,html[data-theme="dark"] #attachments .attachment-row .attachment-download-row{background:transparent!important;border:0!important;color:#c0cae0!important}
html[data-theme="dark"] #attachments .attachment-row .attachment-delete{background:transparent!important;border:0!important;color:#ff858d!important}
@media(max-width:760px){#attachments .attachment-row{grid-template-columns:minmax(0,1fr) repeat(3,32px)!important;grid-template-rows:34px!important}}

/* v6.62: Quick Create Customer as a true overlay, no scroll to inline sidebar */
.quick-customer-backdrop[hidden],#customer-pane[hidden]{display:none!important}
.quick-customer-backdrop{position:fixed;inset:0;z-index:1090;background:rgba(13,21,42,.55);backdrop-filter:blur(2px)}
body.quick-customer-open{overflow:hidden!important}
#customer-pane:not([hidden]){display:flex!important;flex-direction:column!important;position:fixed!important;inset:50% auto auto 50%!important;transform:translate(-50%,-50%)!important;width:min(520px,calc(100vw - 24px))!important;max-width:none!important;height:auto!important;max-height:min(90dvh,850px)!important;overflow-y:auto!important;overscroll-behavior:contain!important;z-index:1100!important;grid-column:auto!important;grid-row:auto!important;margin:0!important;box-sizing:border-box!important;box-shadow:0 24px 70px rgba(9,18,45,.25)!important;background:var(--white)!important}
#customer-pane .pane-head{position:sticky;top:-18px;z-index:2;background:var(--white);padding:6px 0 10px;border-bottom:1px solid var(--line)}
#customer-pane .quick-customer-actions{position:sticky;bottom:-18px;z-index:2;background:var(--white);padding:12px 0 6px;display:flex;gap:10px;border-top:1px solid var(--line)}
#customer-pane .quick-customer-actions .btn{flex:1;min-width:0}
@media(max-width:767px){#customer-pane:not([hidden]){max-height:90dvh!important;padding:14px!important;border-radius:14px!important}#customer-pane .pane-head{top:-14px}#customer-pane .quick-customer-actions{bottom:-14px}}
@media(max-width:767px){}
@media(prefers-reduced-motion:reduce){}

/* v6.63 alignment patch: centre native file picker and filename vertically. */
#attachments .v657-upload-row .upload-form input[type="file"] {
  display: flex !important;
  align-items: center !important;
  padding: 0 8px !important;
  line-height: 40px !important;
  vertical-align: middle !important;
}
#attachments .v657-upload-row .upload-form input[type="file"]::file-selector-button {
  vertical-align: middle;
  margin-block: 0;
  margin-right: 8px;
}

/* v6.64 administrator audit log */
.logs-scroll{overflow-x:auto}.logs-table{width:100%;border-collapse:collapse;text-align:left}.logs-table th,.logs-table td{padding:12px;border-bottom:1px solid var(--border,#dce1e9);font-size:13px}.logs-pages{display:flex;align-items:center;justify-content:center;gap:18px;margin:24px 0}.skipped-visit-icon{color:#9299a6!important;stroke:#9299a6!important}

.stage-section summary .stage-completed-icon.skipped-visit-icon{color:#9299a6!important;stroke:#9299a6!important}

/* v6.65 activity log mobile cards and notification read status */
.notification-history-item:not(.unread)>.notification-item-dot{background:#9ca3af!important;border:0!important}
.notification-history-item.unread>.notification-item-dot{background:#e32945!important;border:0!important}
.notification-read-all-form{display:flex;justify-content:flex-end;margin:0 0 12px}
.notification-read-all-form button:disabled{opacity:.5;cursor:default}
@media(max-width:767px){.logs-scroll{overflow:visible}.logs-table,.logs-table tbody,.logs-table tr,.logs-table td{display:block;width:100%}.logs-table thead{display:none}.logs-table tr{background:var(--surface,#f6f7fb);border:1px solid var(--line,#dce1e9);border-radius:12px;margin:0 0 12px;padding:10px 12px}.logs-table td{border:0;padding:4px 0!important;overflow-wrap:anywhere;word-break:break-word}.logs-table td:before{content:attr(data-label) ': ';font-size:11px;font-weight:700;color:var(--muted);display:block;margin-bottom:2px}.logs-pages{flex-wrap:wrap}}

/* v6.66: compact, responsive audit history */
.logs-scroll{max-width:100%;overflow-x:auto}.logs-table{table-layout:fixed;width:100%}
.logs-table th,.logs-table td{padding:8px 10px;vertical-align:middle;line-height:1.3;overflow-wrap:anywhere;word-break:normal;white-space:normal}
.logs-table th:nth-child(1){width:16%}.logs-table th:nth-child(2){width:11%}.logs-table th:nth-child(3){width:16%}.logs-table th:nth-child(4){width:27%}.logs-table th:nth-child(5){width:30%}
.logs-deal strong,.logs-deal span{display:block}.logs-deal span{font-size:12px;color:var(--muted)}
.logs-linked{cursor:pointer}.logs-linked:hover{background:var(--surface,#f6f7fb)}.logs-linked:focus-visible{outline:2px solid #6366f1;outline-offset:-2px}
.logs-date-mobile{display:none}
@media(max-width:767px){
.logs-scroll{overflow:visible}.logs-table,.logs-table tbody{display:block;width:100%}.logs-table tr{display:grid;grid-template-columns:minmax(0,1fr) auto;grid-template-areas:'activity time' 'deal deal' 'details details';column-gap:8px;row-gap:2px;margin:0 0 7px;padding:8px 10px;min-width:0;border-radius:10px}
.logs-table td{min-width:0;width:auto!important;max-width:100%;padding:0!important;line-height:1.25;font-size:12px;overflow-wrap:anywhere;word-break:break-word}
.logs-table td:before{display:none!important}.logs-table .logs-activity{grid-area:activity;font-size:12px}.logs-table .logs-time{grid-area:time;text-align:right;color:var(--muted);font-size:10px;white-space:nowrap}
.logs-table .logs-deal{grid-area:deal;font-size:11px}.logs-table .logs-deal strong,.logs-table .logs-deal span{display:inline;font-size:11px}.logs-table .logs-deal span:not(.muted):before{content:' · '}
.logs-table .logs-details{grid-area:details;color:var(--muted);font-size:11px}.logs-table .logs-user{display:none}
.logs-table .logs-details:before{content:attr(data-user) ' · ';display:inline!important;font-size:11px;font-weight:500;color:var(--muted);margin:0}
.logs-date-desktop{display:none}.logs-date-mobile{display:inline}
}

/* v6.67: inline, normal-weight optional guidance beside Attention. */
.deal-update-form .attention-picker>label{display:flex;flex-direction:row;align-items:baseline;flex-wrap:wrap;column-gap:9px;row-gap:2px}
.deal-update-form .attention-picker .attention-optional{font-family:inherit;font-size:12px;font-weight:400;line-height:1.5;color:var(--muted);letter-spacing:normal}

/* v6.68 Remember Me */
.login-card .remember-me{display:flex;align-items:center;gap:9px;font-size:12px;font-weight:400;cursor:pointer;color:inherit}.login-card .remember-me input{width:16px;height:16px;min-width:16px;accent-color:#3458d4;margin:0}.login-card .remember-me span{font:inherit}

/* v6.69: consistent low-contrast pills and highlighted destination fields */
.deal-list-table .dl-priority,.deal-list-table .dl-closing,.dl-mobile-card .dl-priority,.dl-mobile-card .dl-closing{border-radius:999px!important;padding:4px 10px!important;font-weight:650!important;border:1px solid currentColor!important;background:color-mix(in srgb,currentColor 9%,transparent)!important}
@keyframes v669-focus-pulse{0%,100%{box-shadow:0 0 0 0 transparent}20%,65%{box-shadow:0 0 0 5px rgba(86,103,244,.24);outline:2px solid #5965e8} }
@media(prefers-reduced-motion:reduce){}

/* v6.70: align Remember Me checkbox left */
.login-card .form-stack label.remember-me{display:inline-flex!important;flex-direction:row!important;align-items:center!important;justify-content:flex-start!important;gap:9px!important;width:max-content;font-weight:400!important}
.login-card label.remember-me input[type=checkbox]{appearance:auto!important;display:inline-block!important;width:16px!important;height:16px!important;flex:0 0 16px!important;padding:0!important;margin:0!important}
.login-card label.remember-me span{display:inline!important;white-space:nowrap}
/* v6.70: shared colour tiers, preserving pill shape */
.deal-list-table .dl-priority,.deal-list-table .dl-closing,.dl-mobile-card .dl-priority,.dl-mobile-card .dl-closing,.pipeline-card .card-badges .pipeline-closing-pill{border-radius:999px!important;padding:4px 10px!important;font-weight:750!important;border:1px solid var(--pill-border,transparent)!important;background:var(--pill-bg,#eef2ff)!important;color:var(--pill-ink,#3730a3)!important}
.dl-closing[data-pct-tier=zero],.pipeline-closing-pill[data-pct-tier=zero]{--pill-bg:#7f1d1d;--pill-ink:#fff;--pill-border:#7f1d1d}
.dl-closing[data-pct-tier=red],.pipeline-closing-pill[data-pct-tier=red]{--pill-bg:#fee2e2;--pill-ink:#991b1b;--pill-border:#fecaca}
.dl-closing[data-pct-tier=amber],.pipeline-closing-pill[data-pct-tier=amber]{--pill-bg:#fef3c7;--pill-ink:#92400e;--pill-border:#fde68a}
.dl-closing[data-pct-tier=green],.pipeline-closing-pill[data-pct-tier=green]{--pill-bg:#d1fae5;--pill-ink:#065f46;--pill-border:#a7f3d0}
.dl-closing[data-pct-tier=strong],.pipeline-closing-pill[data-pct-tier=strong]{--pill-bg:#bbf7d0;--pill-ink:#14532d;--pill-border:#86efac}
.dl-closing[data-pct-tier=complete],.pipeline-closing-pill[data-pct-tier=complete]{--pill-bg:#047857;--pill-ink:#fff;--pill-border:#047857}
.dl-priority.dl-low{--pill-bg:#dbeafe;--pill-ink:#1d4ed8;--pill-border:#bfdbfe}
.dl-priority.dl-normal{--pill-bg:#d1fae5;--pill-ink:#047857;--pill-border:#a7f3d0}
.dl-priority.dl-high{--pill-bg:#ffedd5;--pill-ink:#c2410c;--pill-border:#fed7aa}
.dl-priority.dl-urgent{--pill-bg:#ffe0e3;--pill-ink:#b4233b;--pill-border:#ffc2cb}
html[data-theme=dark] .dl-closing[data-pct-tier=red],html[data-theme=dark] .pipeline-closing-pill[data-pct-tier=red]{--pill-bg:#532636;--pill-ink:#ffc1ce;--pill-border:#7b354c}
html[data-theme=dark] .dl-closing[data-pct-tier=amber],html[data-theme=dark] .pipeline-closing-pill[data-pct-tier=amber]{--pill-bg:#4b391e;--pill-ink:#ffdf9d;--pill-border:#765625}
html[data-theme=dark] .dl-closing[data-pct-tier=green],html[data-theme=dark] .pipeline-closing-pill[data-pct-tier=green]{--pill-bg:#17483d;--pill-ink:#a8f5d5;--pill-border:#236b59}
html[data-theme=dark] .dl-closing[data-pct-tier=strong],html[data-theme=dark] .pipeline-closing-pill[data-pct-tier=strong]{--pill-bg:#14532d;--pill-ink:#bbf7d0;--pill-border:#166534}
html[data-theme=dark] .dl-priority.dl-low{--pill-bg:#233b63;--pill-ink:#c4dcff;--pill-border:#35558a}
html[data-theme=dark] .dl-priority.dl-normal{--pill-bg:#17483d;--pill-ink:#a8f5d5;--pill-border:#236b59}
html[data-theme=dark] .dl-priority.dl-high{--pill-bg:#55351f;--pill-ink:#ffd2a5;--pill-border:#7b4b2a}
html[data-theme=dark] .dl-priority.dl-urgent{--pill-bg:#532636;--pill-ink:#ffc1ce;--pill-border:#7b354c}

/* v6.71 document completion and multi deal type */
.deal-type-box{border:1px solid var(--border,#cbd5e1);border-radius:10px;padding:8px;min-width:0}.deal-type-chips{display:flex;flex-wrap:wrap;gap:6px;margin-bottom:6px}.deal-type-chip{display:inline-flex;align-items:center;gap:7px;border-radius:999px;padding:4px 9px;background:#e0e7ff;color:#3730a3;font-size:12px}.deal-type-chip button{background:transparent;border:0;color:inherit;cursor:pointer;font-size:16px}.documents-field{min-width:0;grid-column:1/-1;display:grid;gap:9px;padding:12px;border:1px solid var(--border,#d1d5db);border-radius:12px}.documents-field .attachment-list{min-width:0}.finished-check{display:flex;align-items:center;gap:8px;font-weight:500;cursor:pointer}.finished-check.is-finished{color:#16803c}.finished-check input{width:17px;height:17px;accent-color:#16803c}.finish-pill,.finish-symbol{display:inline-flex;align-items:center;gap:4px;border-radius:999px;padding:3px 9px;font-size:12px;font-weight:700}.finished-yes{background:#dcfce7!important;color:#166534!important}.finished-no{background:#fee2e2!important;color:#991b1b!important}.finish-cell{text-align:center}.dl-finish-line{display:flex;gap:8px;flex-wrap:wrap;padding:5px 0}html[data-theme="dark"] .finished-yes{background:#164e36!important;color:#bbf7d0!important}html[data-theme="dark"] .finished-no{background:#552636!important;color:#fecaca!important}html[data-theme="dark"] .deal-type-chip{background:#312e81;color:#e0e7ff}

/* v6.72 two complete document columns, with the original attachments upload row */
.documents-columns{grid-column:1/-1;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:start;min-width:0}
.document-column{min-width:0;display:flex;flex-direction:column;gap:12px}
.document-column>label{min-width:0}
.document-column .documents-field{display:flex;flex-direction:column;gap:9px;min-width:0;grid-column:auto;padding:12px}
.document-column .documents-field>.muted{margin:0}
.document-upload-row{display:flex;align-items:stretch;gap:8px;min-width:0}
.document-upload-row .upload-form{display:flex;flex:1 1 auto;align-items:stretch;gap:8px;min-width:0}
.document-upload-row .upload-form input[type=file]{flex:1 1 auto;min-width:0;width:100%;height:auto}
.document-upload-row .upload-form .btn{flex:0 0 auto;white-space:nowrap}
.document-upload-row .camera-upload-form{display:flex;flex:0 0 auto}
.document-column .attachment-list{min-width:0;width:100%}
.document-column .attachment-row{min-width:0;width:100%;display:flex;align-items:center}
.document-column .attachment-open{flex:1 1 0;min-width:0;overflow:hidden;text-align:left}
.document-column .attachment-file-details,.document-column .attachment-file-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.document-column .attachment-share-row,.document-column .attachment-download-row,.document-column .attachment-delete{flex:0 0 auto}
.document-column .finished-check{display:flex;flex-direction:row;justify-content:flex-start;align-items:center;gap:8px}
@media(max-width:720px){.documents-columns{grid-template-columns:minmax(0,1fr)}.document-upload-row .upload-form{min-width:0}.document-upload-row .upload-form input[type=file]{min-width:0}.document-upload-row .upload-form .btn{padding-inline:9px}}

/* v6.73: preserve original single-line attachment uploader inside half-width document columns */
.documents-field .document-upload-row{display:grid!important;grid-template-columns:minmax(0,1fr) auto 40px!important;align-items:center!important;gap:6px!important;width:100%!important;min-width:0!important;margin:0!important}
.documents-field .document-upload-row .upload-form{display:contents!important}
.documents-field .document-upload-row .upload-form input[type=file]{grid-column:1!important;display:block!important;box-sizing:border-box!important;width:100%!important;min-width:0!important;height:40px!important;max-height:40px!important;padding:6px!important;font-size:11px!important;align-self:center!important}
.documents-field .document-upload-row .upload-form .btn{grid-column:2!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;width:auto!important;min-width:0!important;height:40px!important;min-height:40px!important;padding:0 8px!important;white-space:nowrap!important;font-size:11px!important;align-self:center!important}
.documents-field .document-upload-row .camera-upload-form{grid-column:3!important;display:flex!important;align-items:center!important;justify-content:center!important;align-self:center!important;margin:0!important;min-width:0!important;width:40px!important;height:40px!important}
.documents-field .document-upload-row .camera-capture-button{display:flex!important;align-items:center!important;justify-content:center!important;box-sizing:border-box!important;width:40px!important;height:40px!important;min-width:40px!important;min-height:40px!important;max-height:40px!important;padding:0!important;margin:0!important;flex:none!important;background:var(--white)!important;color:var(--ink)!important;border:1px solid var(--line)!important;border-radius:9px!important}
.documents-field .attachment-list:empty{display:none!important}
.documents-field .finished-check{margin:2px 0 0!important;padding:0!important;min-height:22px!important;line-height:22px!important}
.documents-field .finished-check input{flex:0 0 17px!important;margin:0!important}
@media(max-width:450px){.documents-field .document-upload-row{grid-template-columns:minmax(0,1fr) auto 36px!important;gap:4px!important}.documents-field .document-upload-row .camera-upload-form,.documents-field .document-upload-row .camera-capture-button{width:36px!important;min-width:36px!important;height:40px!important}.documents-field .document-upload-row .upload-form .btn{padding:0 6px!important;font-size:10px!important}}

/* v6.74 - vertically centre native chooser and keep uploader controls in one row */
.documents-field .document-upload-row input[type="file"]{
 display:flex!important;align-items:center!important;line-height:26px!important;
 padding-block:5px!important;vertical-align:middle!important;
}
.documents-field .document-upload-row input[type="file"]::file-selector-button{
 vertical-align:middle!important;margin-block:0!important;
}
#updates:target{outline:2px solid #818cf8;outline-offset:3px}
@keyframes v674BubblePulse{
 0%,100%{box-shadow:0 0 0 0 rgba(99,102,241,.05)}
 50%{box-shadow:0 0 0 8px rgba(99,102,241,.20)}
}
.kanban-updates .kanban-update-link{display:block;color:inherit;text-decoration:none;border-radius:8px}
.kanban-updates .kanban-update-link:hover,.kanban-updates .kanban-update-link:focus-visible{
 background:rgba(99,102,241,.09);outline:2px solid rgba(99,102,241,.35);outline-offset:2px
}

/* v6.76: only visibility of removable Deal Type controls; original v6.74 UI restored */
.deal-type-chip button{display:inline-grid;place-items:center;min-width:20px;width:20px;height:20px;border-radius:50%;opacity:1;font-size:17px;line-height:1;color:inherit}
@keyframes v676-update-focus{0%{box-shadow:0 0 0 7px rgba(99,102,241,.22)}100%{box-shadow:0 0 0 0 rgba(99,102,241,0)}}

/* v6.77: reuse exactly the Attention selector styling, without an extra border */
.deal-type-multi{min-width:0;grid-column:1/-1}.deal-type-picker-input{position:relative;display:flex;flex-wrap:wrap;align-items:center;gap:6px;border:1px solid var(--line);border-radius:9px;background:var(--white);padding:5px 8px;min-height:39px}.deal-type-picker-input input[type=text]{width:auto;flex:1 1 130px;min-width:90px;border:0!important;box-shadow:none!important;padding:6px!important;background:transparent!important}.deal-type-picker-input .attention-suggestions{z-index:50}.customer-record-summary .customer-phone-display{display:inline-flex;min-height:auto;padding:0;border:0;background:transparent}.customer-record-summary .customer-phone-display a{font-size:inherit}.customer-record-summary{gap:6px 17px!important}.deal-type-multi>label{display:block;margin-bottom:5px}

/* v6.78: menu escapes clipped stage accordion without changing original multi-select UI. */
.deal-type-floating-options{box-sizing:border-box!important;display:block;overflow-y:auto;overscroll-behavior:contain;border:1px solid var(--line);border-radius:10px;background:var(--white);box-shadow:0 14px 34px rgba(21,34,73,.17)}
.deal-type-floating-options[hidden]{display:none!important}
/* Single-row attachment actions in drawing, quotation and general sections. */
.document-column .attachment-row,#attachments .attachment-row{display:grid!important;grid-template-columns:minmax(0,1fr) repeat(3,32px)!important;grid-template-rows:34px!important;gap:4px!important;align-items:center!important;width:100%;min-width:0;padding:4px 6px!important}
.document-column .attachment-row .attachment-open,#attachments .attachment-row .attachment-open{grid-column:1!important;grid-row:1!important;min-width:0!important;width:100%!important;overflow:hidden!important;display:flex!important;align-items:center!important;padding:0 4px!important}
.document-column .attachment-row .attachment-file-details,#attachments .attachment-row .attachment-file-details{min-width:0!important;max-width:100%!important;overflow:hidden!important;display:block!important}
.document-column .attachment-row .attachment-file-name,#attachments .attachment-row .attachment-file-name{display:block!important;white-space:nowrap!important;overflow:hidden!important;text-overflow:clip!important;max-width:100%!important;line-height:1.35!important}
.document-column .attachment-row .attachment-file-meta,#attachments .attachment-row .attachment-file-meta{display:none!important}
.document-column .attachment-row .attachment-share-row,#attachments .attachment-row .attachment-share-row{grid-column:2!important;grid-row:1!important;width:32px!important;min-width:32px!important;min-height:32px!important;padding:0!important}
.document-column .attachment-row .attachment-download-row,#attachments .attachment-row .attachment-download-row{grid-column:3!important;grid-row:1!important;width:32px!important;min-width:32px!important;min-height:32px!important;padding:0!important}
.document-column .attachment-row .attachment-delete,#attachments .attachment-row .attachment-delete{grid-column:4!important;grid-row:1!important;width:32px!important;min-width:32px!important;min-height:32px!important;padding:0!important}
/* Same outer dimensions as Pipeline by Stage, with a scrollable document list. */
.dashboard-lower-grid>.dashboard-equal-panel{height:300px!important;min-height:300px!important;max-height:300px!important;overflow:hidden!important}
.dashboard-lower-grid>.dashboard-equal-panel .panel-head{flex:0 0 auto}
.document-pending-panel{display:flex!important;flex-direction:column!important;min-width:0}
.document-pending-scroll{min-height:0;flex:1 1 auto;overflow:auto;overscroll-behavior:contain}
.document-pending-table{width:100%;border-collapse:collapse;font-size:11px}
.document-pending-table th{position:sticky;top:0;z-index:1;background:var(--white);text-align:left;color:var(--muted);font-size:10px;padding:8px 5px;border-bottom:1px solid var(--line)}
.document-pending-table td{padding:8px 5px;border-bottom:1px solid var(--line);vertical-align:middle}
.document-pending-table .center{text-align:center}
.pending-deal-link{display:flex;flex-direction:column;gap:3px;min-width:0;color:inherit;text-decoration:none}
.pending-deal-link strong,.pending-deal-link small{display:block;max-width:200px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.pending-deal-link small{color:var(--muted);font-size:10px}
.pending-deal-link:hover strong{text-decoration:underline;color:#5367dc}
.pending-status{font-weight:850;font-size:15px}.pending-status.finished{color:#16803c}.pending-status.unfinished{color:#c53648}
.pending-priority{font-size:10px;font-weight:750}.pending-priority.priority-urgent{color:#b4233b}.pending-priority.priority-high{color:#c86a17}
.document-pending-count{border-radius:999px;background:#fef3c7;color:#92400e;padding:5px 9px;font-size:11px;font-weight:700;white-space:nowrap}
.pending-empty{text-align:center;color:var(--muted);padding:30px 5px!important}
html[data-theme=dark] .document-pending-count{background:#4b391e;color:#ffdf9d}
@media(max-width:760px){.dashboard-lower-grid>.dashboard-equal-panel{height:auto!important;min-height:230px!important;max-height:330px!important}.document-pending-scroll{max-height:250px}}

/* v6.79: compact and precisely centred Document Pending, matching existing pill format. */
.document-pending-table{table-layout:fixed!important;font-size:11px}
.document-pending-table th:first-child,.document-pending-table td:first-child{width:47%!important}
.document-pending-table th:nth-child(2),.document-pending-table td:nth-child(2){width:15%!important}
.document-pending-table th:nth-child(3),.document-pending-table td:nth-child(3){width:17%!important}
.document-pending-table th:nth-child(4),.document-pending-table td:nth-child(4){width:21%!important}
.document-pending-table th{
 text-transform:none!important;letter-spacing:normal!important;
 font-size:11px!important;font-weight:650!important;
 padding:5px 4px!important;line-height:1.3!important;
}
.document-pending-table td{
 padding:3px 4px!important;height:38px!important;
 line-height:1.2!important;vertical-align:middle!important;
}
.document-pending-table .pending-deal-link{gap:1px!important;line-height:1.2!important}
.document-pending-table .pending-deal-link strong{font-size:11px!important;font-weight:650!important}
.document-pending-table .pending-deal-link small{font-size:10px!important;line-height:1.2!important}
.document-pending-table td.center,.document-pending-table th.center{
 text-align:center!important;vertical-align:middle!important;
}
.document-pending-table .pending-status{
 display:flex!important;align-items:center!important;justify-content:center!important;
 width:22px!important;height:22px!important;margin:auto!important;
 font-size:15px!important;font-weight:800!important;line-height:1!important;
}
.document-pending-table .pending-priority-cell{text-align:center!important}
.document-pending-table .pending-priority{
 display:inline-flex!important;align-items:center!important;justify-content:center!important;
 max-width:100%;margin:auto!important;
 font-size:10px!important;line-height:1.15!important;font-weight:750!important;
 border-radius:999px!important;padding:4px 8px!important;
 border:1px solid transparent!important;white-space:nowrap!important;
}
.document-pending-table .pending-priority.priority-low{background:#dbeafe!important;color:#1d4ed8!important;border-color:#bfdbfe!important}
.document-pending-table .pending-priority.priority-normal{background:#d1fae5!important;color:#047857!important;border-color:#a7f3d0!important}
.document-pending-table .pending-priority.priority-high{background:#ffedd5!important;color:#c2410c!important;border-color:#fed7aa!important}
.document-pending-table .pending-priority.priority-urgent{background:#ffe0e3!important;color:#b4233b!important;border-color:#ffc2cb!important}
html[data-theme=dark] .document-pending-table .pending-priority.priority-low{background:#233b63!important;color:#c4dcff!important;border-color:#35558a!important}
html[data-theme=dark] .document-pending-table .pending-priority.priority-normal{background:#17483d!important;color:#a8f5d5!important;border-color:#236b59!important}
html[data-theme=dark] .document-pending-table .pending-priority.priority-high{background:#55351f!important;color:#ffd2a5!important;border-color:#7b4b2a!important}
html[data-theme=dark] .document-pending-table .pending-priority.priority-urgent{background:#532636!important;color:#ffc1ce!important;border-color:#7b354c!important}

/* v6.80: standalone Deal List chat (does not affect edit-deal history order). */
.dl-chat-lock{overflow:hidden!important}.dl-chat-trigger{display:inline-grid;place-items:center;flex:none;width:36px;height:36px;border:0;border-radius:50%;background:#5361e9;color:#fff;font-weight:750;font-size:24px;line-height:1;cursor:pointer}.dl-chat-trigger:hover{background:#3e4dcc}.dl-actions{display:flex;align-items:center;justify-content:center;gap:8px}.dl-card-footer .dl-chat-trigger{margin-inline:5px}
.dl-chat-modal[hidden]{display:none!important}.dl-chat-modal{position:fixed;inset:0;z-index:12000;display:grid;place-items:center}.dl-chat-scrim{position:absolute;inset:0;background:rgba(9,16,36,.58)}.dl-chat-window{position:relative;display:flex;flex-direction:column;width:min(570px,94vw);height:min(790px,88dvh);min-height:240px;background:var(--white);color:var(--ink);border-radius:15px;overflow:hidden;box-shadow:0 22px 60px #0005}.dl-chat-head{padding:12px 16px;display:flex;align-items:center;justify-content:space-between;border-bottom:1px solid var(--line);flex:none}.dl-chat-head-titles{min-width:0;display:flex;flex-direction:column;gap:2px}.dl-chat-head-titles small{color:var(--muted);text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.dl-chat-close,.dl-chat-viewer-panel header button{border:0;background:transparent;color:var(--ink);font-size:28px;cursor:pointer}.dl-chat-history{flex:1;min-height:0;overflow-y:auto;overscroll-behavior:contain;padding:13px;background:var(--paper);display:flex;flex-direction:column;gap:9px}.dl-chat-bubble-row{display:flex;justify-content:flex-start}.dl-chat-bubble-row.mine{justify-content:flex-end}.dl-chat-bubble{padding:8px 11px;border:1px solid var(--line);border-radius:13px;background:var(--white);max-width:88%;min-width:0;overflow-wrap:anywhere}.dl-chat-bubble-row.mine .dl-chat-bubble{background:rgba(91,108,226,.13);border-color:rgba(91,108,226,.2)}.dl-chat-meta{font-size:10px;color:var(--muted);margin-bottom:4px}.dl-chat-message{font-size:13px;white-space:pre-wrap}.dl-chat-attachment{display:block;max-width:100%;border:1px solid rgba(91,108,226,.25);border-radius:8px;background:rgba(91,108,226,.08);color:var(--ink);padding:9px 12px;cursor:pointer;overflow-wrap:anywhere;text-align:left;font-size:12px}.dl-chat-compose{border-top:1px solid var(--line);background:var(--white);padding:8px 10px}.dl-chat-controls{display:flex;align-items:center;gap:8px}.dl-chat-attach{display:grid;place-items:center;width:36px;height:36px;cursor:pointer;flex:none;color:#5361e9}.dl-chat-controls textarea{flex:1;min-width:0;resize:none;max-height:100px;min-height:37px;padding:9px;border:1px solid var(--line);border-radius:9px;background:var(--white);color:var(--ink);font-size:13px}.dl-chat-send{width:38px;height:38px;flex:none;display:grid;place-items:center;border:0;border-radius:10px;background:#5361e9;color:white;cursor:pointer}.dl-chat-send:disabled{opacity:.6}.dl-chat-files{font-size:11px;color:#5361e9;word-break:break-all;padding:4px 0}.dl-chat-error{font-size:12px;color:#bd3953;padding-top:5px}.dl-chat-viewer{z-index:12010}.dl-chat-viewer-panel{position:relative;width:min(900px,96vw);height:min(900px,94dvh);display:flex;flex-direction:column;gap:10px;padding:12px;background:var(--white);border-radius:12px}.dl-chat-viewer-panel header{display:flex;align-items:center;justify-content:space-between;gap:10px;min-width:0}.dl-chat-viewer-panel header strong{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.dl-chat-viewer-panel #dl-viewer-content{flex:1;min-height:0;display:grid;place-items:center}.dl-chat-viewer-panel img{max-width:100%;max-height:100%;object-fit:contain}.dl-chat-viewer-panel iframe{width:100%;height:100%;border:0}.dl-chat-viewer-panel .btn{align-self:center}
@media(max-width:720px){.dl-chat-window{width:100vw;height:100dvh;border-radius:0}.dl-chat-viewer-panel{width:100vw;height:100dvh;border-radius:0}}
/* v6.80: ensure drawing & quotation file controls are not squeezed or overlaid. */
.document-column .attachment-row{display:grid!important;grid-template-columns:minmax(0,1fr) repeat(3,34px)!important;column-gap:5px!important;padding:5px 6px!important;position:relative!important;overflow:hidden!important}
.document-column .attachment-row>.attachment-open{grid-column:1!important;grid-row:1!important;min-width:0!important;position:static!important;margin:0!important}
.document-column .attachment-row>.attachment-share-row{grid-column:2!important;grid-row:1!important;position:static!important;margin:0!important;transform:none!important;z-index:1!important}
.document-column .attachment-row>.attachment-download-row{grid-column:3!important;grid-row:1!important;position:static!important;margin:0!important;transform:none!important;z-index:1!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;opacity:1!important;visibility:visible!important}
.document-column .attachment-row>.attachment-delete{grid-column:4!important;grid-row:1!important;position:static!important;margin:0!important;transform:none!important;z-index:1!important}
.document-column .attachment-row>:is(.attachment-share-row,.attachment-download-row,.attachment-delete){width:34px!important;min-width:34px!important;height:34px!important;min-height:34px!important;padding:0!important;box-sizing:border-box!important}
.document-column .attachment-row .attachment-file-details{max-width:100%!important}
/* v6.81 — Floating Deal Chat only; Edit Deal attachments intentionally untouched. */
.dl-chat-attach{border:0;background:transparent;padding:0;display:grid;place-items:center;flex:none;width:36px;height:36px;color:#5361e9;cursor:pointer}
.dl-chat-attachment{touch-action:pan-y;user-select:none;-webkit-user-select:none;display:flex;justify-content:space-between;align-items:center;gap:12px}
.dl-chat-attachment>span{min-width:0;overflow-wrap:anywhere}.dl-chat-attachment-type{white-space:nowrap;font-size:10px;color:#5361e9;opacity:.9}
.dl-chat-upload{z-index:12030}.dl-chat-actions{z-index:12040}
.dl-upload-panel,.dl-actions-panel{position:relative;width:min(440px,calc(100vw - 26px));max-height:90dvh;overflow-y:auto;background:var(--white);color:var(--ink);border:1px solid var(--line);border-radius:14px;padding:17px;box-shadow:0 20px 60px #0005}
.dl-upload-panel header{display:flex;align-items:center;justify-content:space-between;gap:8px}.dl-upload-panel header button{border:0;background:transparent;color:var(--ink);font-size:26px;cursor:pointer}
.dl-upload-panel form{display:flex;flex-direction:column;gap:12px}.dl-upload-panel fieldset{border:0;margin:0;padding:0;display:grid;gap:12px}.dl-upload-panel legend{font-weight:600;font-size:13px;margin-bottom:12px}.dl-upload-panel fieldset label{display:flex;align-items:center;gap:9px;font-size:13px}.dl-upload-pick{display:flex;flex-direction:column;gap:7px;font-size:13px;font-weight:600}.dl-upload-pick input{width:100%;min-width:0;font-size:12px;color:var(--ink)}.dl-upload-panel footer{display:flex;justify-content:flex-end;gap:8px}.dl-upload-panel footer .btn{min-width:100px}
.dl-actions-panel{padding:6px;display:grid;gap:0;width:min(315px,calc(100vw - 36px))}.dl-actions-panel>strong{font-size:12px;padding:11px;overflow-wrap:anywhere}.dl-actions-panel>button{padding:12px;text-align:left;border:0;border-top:1px solid var(--line);background:transparent;color:var(--ink);cursor:pointer;font-size:13px}.dl-actions-panel>button:hover{background:var(--paper)}.dl-actions-panel>.dl-action-danger{color:#c84853}

/* v6.82: Chat attachment and upload overlay improvements */
.dl-upload-panel fieldset{display:flex;flex-direction:column;gap:4px}
.dl-upload-panel fieldset label{display:flex!important;flex-direction:row!important;justify-content:flex-start!important;align-items:center!important;gap:12px!important;min-height:39px!important;width:100%;padding:5px 8px;border-radius:8px;cursor:pointer;text-align:left!important}
.dl-upload-panel fieldset label input{flex:none!important;width:18px!important;height:18px!important;margin:0!important}
.dl-upload-panel footer{align-items:center;gap:7px}.dl-upload-panel footer .btn{min-width:0;flex:1;min-height:44px}
.dl-upload-camera{flex:none;width:44px;height:44px;border-radius:10px;background:var(--white);color:var(--ink);border:1px solid var(--line);display:grid;place-items:center;cursor:pointer}
.dl-file-tile{display:grid;grid-template-columns:24px minmax(0,1fr) auto;align-items:center;gap:9px;width:100%;min-width:0}.dl-file-icon{display:grid;place-items:center;color:#5361e9}.dl-file-icon svg{width:21px;height:21px}.dl-file-label{min-width:0;display:flex;flex-direction:column;gap:2px}.dl-file-name{display:block;overflow:hidden;white-space:nowrap;text-overflow:ellipsis;direction:ltr}.dl-file-meta{font-size:10px;color:var(--muted);font-weight:400}.dl-chat-attachment-type{background:rgba(91,108,226,.11);border:1px solid rgba(91,108,226,.18);border-radius:12px;padding:3px 6px;flex:none}.dl-chat-attachment{width:100%;min-width:0;text-align:left}.dl-chat-attachment .dl-file-name{overflow-wrap:normal}
.dl-chat-viewer-panel{height:min(900px,94dvh);gap:8px}.dl-viewer-stage{display:grid;grid-template-columns:36px minmax(0,1fr) 36px;flex:1;min-height:0;align-items:center;gap:3px}.dl-viewer-chevron{background:transparent;border:0;color:var(--ink);padding:7px;cursor:pointer;display:grid;place-items:center}.dl-viewer-chevron:disabled{opacity:.2;cursor:default}.dl-viewer-stage #dl-viewer-content{width:100%;height:100%;min-width:0;min-height:0;overflow:hidden;touch-action:none;display:flex;align-items:center;justify-content:center}.dl-viewer-stage img{max-width:100%;max-height:100%;object-fit:contain;transform-origin:center;will-change:transform;user-select:none;-webkit-user-drag:none}.dl-viewer-stage iframe{width:100%;height:100%;border:0}.dl-viewer-actions{display:flex;gap:8px;justify-content:center;align-items:center}.dl-viewer-actions>*{font-size:12px;min-height:38px;padding:8px 13px;border:1px solid var(--line);border-radius:8px;background:var(--white);color:var(--ink);cursor:pointer;text-decoration:none}.dl-viewer-actions #dl-viewer-delete{color:#be4256}
@media(max-width:600px){.dl-upload-panel{padding:14px}.dl-viewer-stage{grid-template-columns:30px minmax(0,1fr) 30px}.dl-viewer-chevron{padding:3px}.dl-viewer-actions>*{flex:1;text-align:center;padding:8px 5px}}

/* v6.82 deal update and notification attachment summaries */
.v682-file-link{display:flex!important;align-items:center;gap:8px;min-width:0;max-width:100%;text-decoration:none}.v682-file-icon{flex:none;display:grid;place-items:center;color:#5361e9}.v682-file-icon svg{height:20px;width:20px}.v682-file-content{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}.v682-file-content strong,.v682-file-name{font-size:12px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}.v682-file-content small{font-size:10px;color:var(--muted);font-weight:400}.v682-file-tag{font-style:normal;font-size:10px;white-space:nowrap;border-radius:999px;background:rgba(91,108,226,.12);color:#5361e9;padding:3px 6px;flex:none}.v682-notification-file{display:flex!important;align-items:center;gap:7px;min-width:0}.v682-notification-file .v682-file-content{display:flex;min-width:0}.v682-notification-file .v682-file-content strong{font-size:11px;color:var(--ink)}.v682-notification-file .v682-file-tag{font-size:9px}
/* v6.83 — WhatsApp-like tapered bubble tails, chat actions and mentions */
.dl-chat-bubble-row{padding-left:13px;padding-right:13px}
.dl-chat-bubble{position:relative;overflow:visible!important;border-radius:13px 13px 13px 13px!important}
.dl-chat-bubble-row:not(.mine) .dl-chat-bubble{border-top-left-radius:3px!important}
.dl-chat-bubble-row.mine .dl-chat-bubble{border-top-right-radius:3px!important}
.dl-chat-bubble::before{content:"";position:absolute;top:-1px;width:0;height:0;pointer-events:none}
.dl-chat-bubble-row:not(.mine) .dl-chat-bubble::before{left:-15px;border-top:0 solid transparent;border-bottom:18px solid transparent;border-right:16px solid var(--white);filter:drop-shadow(-1px 0 var(--line))}
.dl-chat-bubble-row.mine .dl-chat-bubble::before{right:-15px;border-top:0 solid transparent;border-bottom:18px solid transparent;border-left:16px solid rgba(91,108,226,.13)}
html[data-theme="dark"] .dl-chat-bubble-row.mine .dl-chat-bubble::before{border-left-color:rgba(91,108,226,.13)}
.dl-chat-trigger{font-size:initial!important;background:rgba(91,108,226,.13)!important;color:#5361e9!important;border:1px solid rgba(91,108,226,.2)!important;border-radius:10px!important}
.dl-chat-trigger:hover{background:rgba(91,108,226,.23)!important}
.dl-chat-trigger svg{display:block}
.dl-card-whatsapp,.dl-actions a{color:#238451}
.v683-mention-results[hidden],.v683-mention-chips[hidden]{display:none!important}
.v683-mention-results{display:flex;flex-direction:column;gap:2px;padding:5px;border:1px solid var(--line);border-radius:9px;background:var(--white);box-shadow:0 6px 18px #0002;max-height:180px;overflow:auto;z-index:3}
.v683-mention-results .attention-suggestion{padding:9px 10px;text-align:left;background:transparent;border:0;border-radius:6px;cursor:pointer;color:var(--ink);font-size:13px}
.v683-mention-results .attention-suggestion:hover,.v683-mention-results .attention-suggestion:focus-visible{background:rgba(91,108,226,.12)}
.v683-mention-chips{display:flex;flex-wrap:wrap;gap:5px;margin:5px 0}
.v683-mention-chips .attention-chip{display:inline-flex;align-items:center;gap:4px}
.v683-mention-chips button{border:0;background:none;color:inherit;cursor:pointer;font-size:15px}
.dl-chat-compose{position:relative}
.deal-update-form .v683-mention-results{order:1}.deal-update-form textarea{order:0}.deal-update-form .v683-mention-chips{order:2}
@media(max-width:720px){.dl-chat-bubble-row{padding-left:15px;padding-right:15px}}

/* v6.84: compact cards, consistent bare action icons, rounded chat bubbles. */
.dl-chat-bubble::before,.dl-chat-bubble::after{content:none!important;display:none!important}
.dl-chat-bubble-row{padding-inline:3px!important}
.dl-chat-bubble{border-radius:24px!important;overflow-wrap:anywhere}
.dl-chat-bubble-row.mine .dl-chat-bubble{border-radius:24px 2px 24px 24px!important}
.dl-chat-bubble-row:not(.mine) .dl-chat-bubble{border-radius:2px 24px 24px 24px!important}
.dl-chat-trigger,.dl-chat-trigger:hover{background:transparent!important;border:0!important;border-radius:0!important;color:var(--ink)!important;width:32px!important;height:32px!important;margin:0!important;padding:5px!important}
.dl-chat-trigger svg{width:19px!important;height:19px!important}
.dl-actions{gap:8px!important}.dl-card-footer{gap:5px!important}
@media(max-width:767px){.dl-mobile-card{padding:8px 10px!important;gap:4px!important}.dl-mobile-cards{gap:7px!important}.dl-card-footer .dl-priority,.dl-card-footer .dl-closing{padding:3px 7px!important}.dl-finish-line{padding:1px 0!important;gap:5px!important}.dl-card-footer .dl-chat-trigger{margin:0!important}}
/* Shared mention editor: in-flow orange text; no secondary attention chips. */
.v684-editor{width:100%;min-height:88px;max-height:220px;overflow-y:auto;overflow-wrap:anywhere;white-space:pre-wrap;border:1px solid var(--line);border-radius:9px;background:var(--white);color:var(--ink);padding:10px;font:inherit;font-size:13px;line-height:1.5;outline-offset:2px}
.v684-editor:empty:before{content:attr(data-placeholder);color:var(--muted);pointer-events:none}
.v684-editor .v684-mention,.v684-highlight{color:#d97706!important;font-weight:750!important;background:transparent!important;border:0!important;border-radius:0!important;padding:0!important}
html[data-theme=dark] .v684-editor .v684-mention,html[data-theme=dark] .v684-highlight{color:#ffae48!important}
.dl-chat-controls .v684-editor{flex:1;min-width:0;min-height:38px;max-height:115px;padding:8px 9px}
.v683-mention-chips{display:none!important}.v683-mention-results{position:relative;z-index:20}
/* Chat viewer actions follow Edit Deal viewer buttons and use the same Lucide SVG icon shapes. */
.dl-chat-viewer-panel{gap:0!important;padding:0!important;overflow:hidden;border:1px solid var(--line)}
.dl-chat-viewer-panel header{padding:10px!important;background:var(--white);border-bottom:1px solid var(--line);min-height:58px}
.dl-viewer-actions{order:-1;display:flex!important;gap:8px!important;flex:0 0 auto;margin-left:auto}
.dl-viewer-actions > *,.dl-chat-viewer-panel header [data-viewer-close]{display:inline-flex!important;align-items:center!important;justify-content:center!important;width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important;padding:0!important;line-height:1!important;border:1px solid var(--line)!important;border-radius:9px!important;background:var(--white)!important;color:var(--ink)!important;text-decoration:none!important;cursor:pointer;font-size:18px!important}
.dl-viewer-actions > * svg,.dl-chat-viewer-panel header [data-viewer-close] svg{width:17px;height:17px;display:block;stroke:currentColor!important;opacity:1!important}
.dl-viewer-actions #dl-viewer-delete{color:#b74b57!important}
.dl-viewer-stage{position:relative!important;display:block!important;flex:1;min-height:0;overflow:hidden}
.dl-viewer-stage #dl-viewer-content{height:100%;width:100%;min-width:0;display:flex;align-items:center;justify-content:center;overflow:hidden;touch-action:none}
.dl-viewer-chevron{position:absolute!important;top:50%;transform:translateY(-50%);z-index:3;display:grid!important;place-items:center!important;width:36px;height:42px;padding:0!important;border-radius:12px!important;border:0!important;background:rgba(18,27,42,.34)!important;color:white!important;backdrop-filter:blur(3px);cursor:pointer}
#dl-viewer-prev{left:8px}#dl-viewer-next{right:8px}
.dl-viewer-chevron:disabled{opacity:.2!important}.dl-viewer-stage img{max-width:100%;max-height:100%;object-fit:contain;will-change:transform;user-select:none}
html[data-theme=dark] .dl-viewer-actions > *,html[data-theme=dark] .dl-chat-viewer-panel header [data-viewer-close]{background:var(--white)!important;color:var(--ink)!important;border-color:var(--line)!important}
@media(max-width:600px){.dl-chat-viewer-panel{width:100vw;height:100dvh;border-radius:0}.dl-viewer-actions > *{flex:0 0 38px!important}.dl-chat-viewer-panel header{gap:7px!important}.dl-chat-viewer-panel header strong{flex:1;min-width:0;font-size:12px}}
html[data-theme=dark] #attachment-viewer .attachment-viewer-actions #attachment-share svg{stroke:currentColor!important;opacity:1!important;visibility:visible!important}

/* v6.85 audited overrides */
.dl-chat-trigger{background:transparent!important;border:1px solid #929fca!important;border-radius:8px!important;color:#5262d7!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;padding:0!important;width:38px!important;height:38px!important;box-shadow:none!important}
.dl-chat-trigger svg{color:#5262d7!important;stroke:currentColor!important}
.dl-chat-trigger:hover{background:rgba(82,98,215,.06)!important;border-color:#5262d7!important}
html[data-theme="dark"] .dl-chat-trigger{background:transparent!important;border-color:#7284c9!important;color:#a7b4ff!important}
html[data-theme="dark"] .dl-chat-trigger svg{color:#a7b4ff!important}
html[data-theme="dark"] #attachment-viewer .attachment-viewer-actions .btn, html[data-theme="dark"] #attachment-viewer #attachment-share{background:#303b60!important;color:#f3f5ff!important;border:1px solid #7888ba!important;opacity:1!important}
html[data-theme="dark"] #attachment-viewer .attachment-viewer-actions .btn svg{stroke:#f3f5ff!important;opacity:1!important}
.v684-highlight,.v684-mention{color:#df8123!important;font-weight:750!important;background:none!important;border:0!important;padding:0!important;border-radius:0!important}
html[data-theme="dark"] .v684-highlight,html[data-theme="dark"] .v684-mention{color:#ffb15c!important}
.salesdesk-focus-once{outline:2px solid #6678dd!important;outline-offset:4px!important;animation:none!important;transition:outline-color .3s ease!important}
@media(max-width:760px){}

html[data-theme="dark"] .attachment-share-row,html[data-theme="dark"] #attachment-share{color:#e7edff!important;opacity:1!important}
html[data-theme="dark"] .attachment-share-row svg,html[data-theme="dark"] #attachment-share svg{stroke:#e7edff!important;opacity:1!important}
/* Outlined pair: same footprint for Team Chat and customer conversation. */
.dl-actions .dl-chat-trigger,.dl-actions a,.dl-card-footer .dl-chat-trigger,.dl-card-footer .dl-card-whatsapp{box-sizing:border-box!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;width:38px!important;height:38px!important;min-width:38px!important;min-height:38px!important;border:1px solid var(--line)!important;border-radius:8px!important;background:transparent!important;padding:0!important;margin:0!important}
.dl-actions .dl-chat-trigger,.dl-card-footer .dl-chat-trigger{color:#5262d7!important;border-color:#a6afe1!important}
.dl-actions .dl-chat-trigger svg,.dl-card-footer .dl-chat-trigger svg{stroke:#5262d7!important;width:19px!important;height:19px!important}
.dl-actions a,.dl-card-footer .dl-card-whatsapp{color:#238451!important;border-color:#9bc9b0!important}
.dl-actions a svg,.dl-card-footer .dl-card-whatsapp svg{stroke:#238451!important;width:19px!important;height:19px!important}
html[data-theme="dark"] .dl-actions .dl-chat-trigger,html[data-theme="dark"] .dl-card-footer .dl-chat-trigger{border-color:#7687cf!important;color:#b0bdff!important}
html[data-theme="dark"] .dl-actions .dl-chat-trigger svg,html[data-theme="dark"] .dl-card-footer .dl-chat-trigger svg{stroke:#b0bdff!important}
html[data-theme="dark"] .dl-actions a,html[data-theme="dark"] .dl-card-footer .dl-card-whatsapp{border-color:#5ca482!important;color:#8ce2ab!important}
html[data-theme="dark"] .dl-actions a svg,html[data-theme="dark"] .dl-card-footer .dl-card-whatsapp svg{stroke:#8ce2ab!important}
