/* The private CRM extends the existing Werkauftrag.ch workspace. */
.crm{--crm-text:#34435a;max-width:1400px;margin:0 auto;color:var(--ink)}
.crm h1{font-size:clamp(29px,3vw,38px)}.crm h2{font-size:21px;letter-spacing:-.55px}.crm h3{font-size:15px;letter-spacing:-.2px}
.crm-head{align-items:flex-start;margin-bottom:26px}.crm-head p{max-width:660px;font-size:14px}.crm-head>.actions{padding-top:10px;flex-shrink:0}.crm .btn{white-space:normal;text-align:center}.crm-back{display:inline-block;font-size:13px;color:var(--muted);margin:0 0 20px;text-decoration:none}.crm-back:hover{text-decoration:underline;color:var(--green)}
.crm-scope-note{border-top:1px solid var(--line);margin:32px 0 0;padding:20px 0 0;font-size:12px;color:var(--muted);max-width:100%}.crm-muted{color:var(--muted);font-size:12px}.crm-sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.crm-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:15px;margin-bottom:34px}.crm-metric{text-align:left;background:white;border:1px solid var(--line);border-radius:12px;padding:19px 21px;display:grid;gap:8px;color:var(--ink)}.crm-metric:hover{border-color:#9aace0;background:#fcfdff}.crm-metric>span{font-size:12px;font-weight:600;color:var(--crm-text)}.crm-metric>strong{font-size:35px;line-height:1.1;font-weight:650;letter-spacing:-1.3px;font-variant-numeric:tabular-nums}.crm-metric>small{color:var(--muted);font-size:11px}.crm-metric-alert>strong{color:#ac4233}
.crm-section-title{display:flex;align-items:center;justify-content:space-between;gap:16px;margin:0 0 17px}.crm-section-title p{font-size:12px;color:var(--muted);margin-top:5px}.crm-section-title .eyebrow{margin-bottom:9px}.crm-export{color:var(--green);font-size:12px;font-weight:600;text-decoration:none;padding:12px 0;flex-shrink:0}.crm-export:hover{text-decoration:underline}
.crm-branches{display:flex;gap:8px;flex-wrap:wrap;padding-bottom:20px;border-bottom:1px solid var(--line)}.crm-branches button{display:inline-flex;gap:8px;align-items:center;border:1px solid #dce1ea;border-radius:7px;background:#fff;color:#536077;font-size:12px;padding:10px 12px;min-height:40px;font-weight:600}.crm-branches button>span{color:#7c879b;font-size:10px;font-weight:500}.crm-branches button.active{color:#1640c4;border-color:#aabbea;background:#edf2ff}.crm-branches button.active>span{color:#345eae}.crm-branches button:hover{border-color:#aabbea}
.crm-filters{display:grid;grid-template-columns:minmax(175px,1.55fr) repeat(4,minmax(115px,1fr));gap:12px;margin:21px 0 13px}.crm-filters label{font-size:11px;color:#58647a}.crm-filters input,.crm-filters select{font-size:12px;min-height:43px;padding:10px;border-radius:7px;background:white}.crm-result-caption{display:flex;justify-content:space-between;align-items:center;gap:12px;min-height:38px;margin-bottom:14px;font-size:12px;color:var(--muted)}
.crm-tasks{margin:11px 0 27px;padding-top:5px}.crm-tasks h2{font-size:17px}.crm-task-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:11px}.crm-task{display:grid;gap:8px;border:1px solid #dbe2f1;border-radius:9px;background:#f0f4fd;padding:15px 17px;text-decoration:none;min-width:0}.crm-task:hover{border-color:#9bb0e5;background:#ebf1ff}.crm-task>div{display:flex;align-items:start;justify-content:space-between;gap:9px;flex-wrap:wrap}.crm-task>strong{font-size:13px;font-weight:600;line-height:1.5;overflow-wrap:anywhere}.crm-task>span{font-size:11px;color:var(--muted);overflow-wrap:anywhere}.crm-owner{font-size:10px;color:#5f6e89}.crm-due{font-size:11px;color:#5b667a;line-height:1.5;white-space:nowrap}.crm-due.is-overdue{color:#aa3e30;font-weight:650}.crm-due.is-today{color:#2555c7;font-weight:650}
.crm-table-wrap{background:white;border:1px solid var(--line);border-radius:10px;overflow-x:auto}.crm-table{width:100%;border-collapse:collapse;text-align:left;font-size:12px;line-height:1.55}.crm-table th{background:#f2f4f8;color:#667187;font-size:10px;letter-spacing:.02em;font-weight:600;padding:13px 16px;white-space:nowrap;border-bottom:1px solid var(--line)}.crm-table td{padding:17px 16px;vertical-align:top;border-bottom:1px solid #ebedf2;max-width:300px;overflow-wrap:anywhere}.crm-table tbody tr:last-child td{border-bottom:0}.crm-table tbody tr:hover{background:#fafbfe}.crm-table td>span:not(.crm-status):not(.crm-due){display:block;font-size:11px;color:#717a8c;margin-top:4px}.crm-table .crm-contact-link{font-size:13px;font-weight:650;color:#283953;text-decoration:none;display:block;min-width:130px;line-height:1.5}.crm-table .crm-contact-link:hover{color:var(--green);text-decoration:underline}.crm-status{display:inline-flex;align-items:center;border-radius:5px;font-size:10px;line-height:1.45;font-weight:600;background:#edf1f7;color:#536178;padding:5px 7px;max-width:100%;white-space:normal}.crm-status-new{background:#eef1f5;color:#57657a}.crm-status-interested,.crm-status-meeting{background:#eaf0ff;color:#2450a6}.crm-status-active{background:#e8f4ea;color:#356341}.crm-status-lost,.crm-status-do_not_contact{background:#f8eae7;color:#9d3f32}.crm-status-not_now,.crm-status-awaiting_reply{background:#fbf1db;color:#856629}.crm-priority{color:#a9582f!important;font-weight:500}.crm-pagination{display:flex;justify-content:space-between;align-items:center;gap:15px;margin-top:17px;font-size:12px;color:var(--muted)}
.crm-empty{text-align:center;padding:52px 25px;border:1px dashed #ccd5e6;border-radius:11px;background:#fff}.crm-empty-mark{display:grid;place-items:center;font-size:24px;width:48px;height:48px;background:#edf2ff;color:#2453ec;border-radius:12px;margin:0 auto 17px}.crm-empty p{font-size:13px;color:var(--muted);max-width:500px;margin:12px auto 22px}.crm-empty .actions{justify-content:center}
.crm-contact-meta{display:flex;gap:20px;align-items:center;flex-wrap:wrap;font-size:12px;color:#5e6c80;padding:0 0 26px}.crm-contact-meta .crm-status{font-size:12px;padding:6px 10px}.crm-suppressed{padding:17px 20px;border:1px solid #e2beb7;border-radius:9px;color:#9d4136;background:#fff3ee;margin-bottom:22px;font-size:13px}.crm-suppressed p{font-size:12px;line-height:1.6;margin-top:5px}.crm-detail-grid{display:grid;grid-template-columns:minmax(0,1fr) 280px;gap:28px;align-items:start}.crm-detail-main{min-width:0}.crm-next{padding:22px 24px;background:#edf2fc;border:1px solid #dce4f7;border-radius:10px;margin-bottom:27px}.crm-next h2{font-size:20px;overflow-wrap:anywhere}.crm-next .crm-section-title{align-items:start;margin-bottom:10px}.crm-next p{font-size:12px;color:#61718d}.crm-log-section{padding:0 0 29px;border-bottom:1px solid var(--line);margin-bottom:26px}.crm-quick-actions{display:flex;gap:8px;flex-wrap:wrap}.crm-quick-actions .btn{font-size:12px;padding:10px 15px;min-height:40px}.crm-activity-form{padding:24px 22px;background:white;border:1px solid var(--line);border-radius:10px;margin-top:17px;gap:17px}.crm-activity-form textarea{min-height:95px}
.crm-contact-sidebar{padding:22px;background:#fff;border:1px solid var(--line);border-radius:10px;min-width:0}.crm-contact-sidebar>h2{font-size:17px}.crm-facts{margin:20px 0 0;display:grid;gap:15px}.crm-facts dt{font-size:10px;color:#788297;margin-bottom:4px}.crm-facts dd{font-size:12px;color:#35445d;margin:0;line-height:1.65;overflow-wrap:anywhere}.crm-contact-sidebar section{border-top:1px solid var(--line);padding-top:17px;margin-top:19px}.crm-contact-sidebar section h3{font-size:11px;color:#657188;font-weight:500;margin-bottom:6px}.crm-contact-sidebar section p{font-size:12px;overflow-wrap:anywhere;color:#35445d}.crm-contact-sidebar>.hint{font-size:10px;border-top:1px solid var(--line);padding-top:18px;margin-top:22px}
.crm-timeline{list-style:none;margin:24px 0 0;padding:0}.crm-timeline>li{position:relative;display:grid;grid-template-columns:30px minmax(0,1fr);gap:15px;padding:0 0 28px}.crm-timeline>li:before{content:'';position:absolute;left:14px;top:31px;bottom:0;width:1px;background:#dae2ef}.crm-timeline>li:last-child:before{display:none}.crm-timeline-dot{width:30px;height:30px;border:1px solid #d5dff3;border-radius:50%;background:#edf2fe;display:grid;place-items:center;color:#5477bd;font-size:15px;position:relative}.crm-system .crm-timeline-dot{color:#8e98ab;background:#f1f3f7;border-color:#e1e5ed}.crm-timeline-top{display:flex;justify-content:space-between;gap:16px;align-items:baseline}.crm-timeline-top>strong{font-size:13px;font-weight:600;overflow-wrap:anywhere}.crm-timeline-top time{font-size:10px;color:#7e889a;white-space:nowrap;flex-shrink:0}.crm-timeline article>p:not(.crm-timeline-label){font-size:12px;color:#4d5c73;margin-top:9px;overflow-wrap:anywhere}.crm-timeline-label{font-size:10px;color:#7a859a;margin-top:5px}.crm-timeline small{display:block;font-size:9px;margin-top:10px}.crm-timeline-empty{color:var(--muted);font-size:13px;padding:20px 0}
.crm-contact-form{background:white;border:1px solid var(--line);border-radius:11px;padding:0 27px;gap:0;max-width:1100px}.crm-form-section{padding:27px 0;border-bottom:1px solid var(--line)}.crm-form-section header{display:flex;gap:14px;align-items:baseline;margin-bottom:23px}.crm-form-section header>span{color:#8b98b2;font-size:12px;flex-shrink:0}.crm-form-section header h2{font-size:18px}.crm-form-section header p{font-size:12px;color:var(--muted);margin-top:6px}.crm-form-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px 22px}.crm-form-grid>label{min-width:0;font-size:12px;color:#4b5870}.crm-form-grid input,.crm-form-grid select,.crm-contact-form textarea,.crm-activity-form textarea{font-size:13px;border-radius:7px}.crm-span{grid-column:1/-1}.crm-form-section fieldset{margin:0 0 23px}.crm-category-checks{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}.crm-category-checks .check-label{font-size:12px}.crm-more summary{font-size:13px;font-weight:600;cursor:pointer;line-height:1.5;color:#455978}.crm-more[open] summary{margin-bottom:22px}.crm-long-fields{margin-top:22px}.crm-long-fields textarea{min-height:112px}.crm-form-footer{padding:22px 0;display:flex;align-items:center;justify-content:space-between;gap:20px}.crm-form-footer>.hint{margin:0;max-width:380px}.crm-reopen{margin-top:20px;align-items:start!important;font-size:12px;line-height:1.6;color:#925344}.crm-reopen input{margin-top:2px!important}.crm-edit{margin-bottom:30px;scroll-margin-top:24px}.crm-edit>h2{margin:0 0 16px}.crm [hidden]{display:none!important}.crm-error:empty{display:none}.crm-error{margin:17px 0 0;font-size:13px}.crm form[aria-busy=true]{opacity:.8}
.crm-import{border:1px solid var(--line);border-radius:11px;background:white;padding:27px}.crm-import-intro p{font-size:13px;color:var(--muted);max-width:750px;margin:12px 0 15px}.crm-step-label{display:block;font-size:12px;font-weight:650;color:#355181;letter-spacing:.01em}.crm-file-form{display:grid;grid-template-columns:minmax(190px,1.5fr) minmax(160px,1fr) auto;gap:17px;align-items:end;margin:23px 0 0}.crm-file-form label{font-size:12px;color:#506078}.crm-file-form input,.crm-file-form select{font-size:13px}.crm-file-form input[type=file]{padding:13px;background:#f7f9fd;border-color:#c2cce1}.crm-file-form>.error{grid-column:1/-1;margin:0}.crm-import-file{margin:27px 0;padding:16px 19px;border:1px solid #dde5f5;background:#f2f6ff;border-radius:8px;display:flex;gap:14px;justify-content:space-between;flex-wrap:wrap;font-size:12px}.crm-import-file span{color:#61718d}.crm-mapping-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:17px;margin:23px 0}.crm-mapping-grid label{font-size:11px;color:#5a6983}.crm-mapping-grid select{font-size:12px;min-height:42px;padding:10px}.crm-mapping-form>.btn{margin-top:23px}.crm-import-preview{border-top:1px solid var(--line);padding-top:27px;margin-top:28px}.crm-import-preview h2{margin:14px 0 7px}.crm-import-preview>p{font-size:12px;color:var(--muted)}.crm-preview-table{min-width:600px}.crm-import-preview .crm-table-wrap{max-height:450px;margin:22px 0;overflow:auto}.crm-preview-table th{position:sticky;top:0;z-index:1}.crm-preview-table td{font-size:12px;padding:13px 15px}.crm-preview-table .crm-invalid{color:#a63c30!important}.crm-preview-table .crm-valid{color:#347342!important}.crm-import-preview form>.btn{margin-top:20px}.crm-import-preview .check-label{font-size:12px}.crm-import-success{padding:27px 22px;background:#eef7ed;border:1px solid #d9e9d5;border-radius:8px;margin-top:28px}.crm-import-success h2{color:#315b36}.crm-import-success p{font-size:13px;color:#537456;margin:12px 0 22px}
.crm-draft-note{font-size:12px;padding:16px 0 0;color:#7a633b}.crm-error>.actions{margin-top:15px}.crm-error .crm-table-wrap{max-height:300px;overflow:auto;margin-top:14px}.crm-error p{font-size:12px;margin:8px 0}.crm-error .btn{margin-top:8px}
@media(max-width:700px){.sidebar nav:has(a[href="#crm"]) a{flex:1;min-width:0;padding:8px 4px;font-size:9px;text-align:center;line-height:1.35}}
@media(max-width:1200px){.crm-filters{grid-template-columns:repeat(4,minmax(0,1fr))}.crm-search{grid-column:1/-1}.crm-detail-grid{grid-template-columns:minmax(0,1fr) 245px;gap:20px}.crm-head{flex-wrap:wrap;gap:12px}.crm-head>.actions{padding-top:0}.crm-metrics{gap:10px}.crm-metric{padding:17px}.crm-table td,.crm-table th{padding-left:12px;padding-right:12px}.crm-task-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-timeline-top{flex-wrap:wrap;gap:7px}}
@media(max-width:850px){.crm-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-detail-grid{grid-template-columns:minmax(0,1fr)}.crm-contact-sidebar{display:block}.crm-facts{grid-template-columns:repeat(2,minmax(0,1fr));gap:17px 25px}.crm-mapping-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.crm-file-form{grid-template-columns:1fr 1fr}.crm-file-form>label:first-child{grid-column:1/-1}.crm-form-footer{flex-wrap:wrap}.crm-form-footer>.actions{margin-left:auto}.crm-category-checks{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:650px){.crm-head{margin-bottom:21px}.crm-head h1{font-size:29px}.crm-head p{font-size:12px}.crm-head>.actions{width:100%}.crm-head>.actions .btn{flex:1;font-size:11px;padding:10px}.crm-metrics{margin-bottom:27px;gap:9px}.crm-metric{padding:15px}.crm-metric>strong{font-size:29px}.crm-metric>span{font-size:11px}.crm-metric>small{font-size:9px;line-height:1.5}.crm-section-title{align-items:start;gap:10px}.crm-section-title h2{font-size:18px}.crm-export{font-size:10px;padding:5px 0}.crm-branches{gap:6px;padding-bottom:16px}.crm-branches button{font-size:11px;padding:8px 9px;min-height:39px}.crm-filters{grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}.crm-filters label{font-size:10px}.crm-search{grid-column:1/-1}.crm-result-caption{font-size:11px}.crm-task-grid{grid-template-columns:minmax(0,1fr)}.crm-tasks .crm-section-title .btn{font-size:10px;max-width:130px}.crm-tasks h2{font-size:17px}.crm-tasks .crm-section-title p{font-size:10px;max-width:190px}.crm-table-wrap{border:0;background:transparent;border-radius:0}.crm-table:not(.crm-preview-table),.crm-table:not(.crm-preview-table) tbody{display:block}.crm-table:not(.crm-preview-table) thead{display:none}.crm-table:not(.crm-preview-table) tr{display:grid;grid-template-columns:1fr 1fr;background:#fff;border:1px solid var(--line);border-radius:9px;margin-bottom:12px;padding:15px;gap:13px 17px}.crm-table:not(.crm-preview-table) td{display:block;border:0;padding:0;max-width:none;font-size:11px}.crm-table:not(.crm-preview-table) td:first-child{grid-column:1/-1;padding-bottom:12px;border-bottom:1px solid var(--line)}.crm-table:not(.crm-preview-table) td:not(:first-child):before{content:attr(data-label);display:block;color:#8a93a4;font-size:9px;margin-bottom:5px}.crm-table .crm-contact-link{font-size:15px}.crm-table td>span:not(.crm-status):not(.crm-due){font-size:10px}.crm-status{font-size:10px}.crm-due{font-size:10px;white-space:normal}.crm-empty{padding:34px 20px}.crm-empty h2{font-size:21px}.crm-empty p{font-size:12px}.crm-contact-meta{gap:12px;font-size:11px;padding-bottom:20px}.crm-next{padding:19px}.crm-next .crm-section-title{flex-wrap:wrap}.crm-next h2{font-size:20px}.crm-detail-grid{gap:22px}.crm-quick-actions{gap:7px}.crm-quick-actions .btn{font-size:11px;padding:9px 11px;min-height:40px}.crm-activity-form{padding:19px 16px}.crm-timeline-section>.crm-section-title p{font-size:10px}.crm-timeline-section>.crm-section-title>span{font-size:10px}.crm-timeline>li{gap:11px;grid-template-columns:28px minmax(0,1fr)}.crm-timeline-top strong{font-size:12px}.crm-timeline-top time{font-size:9px}.crm-timeline article>p:not(.crm-timeline-label){font-size:11px}.crm-contact-form{padding:0 18px}.crm-form-section{padding:23px 0}.crm-form-section header{gap:10px}.crm-form-section header h2{font-size:17px}.crm-form-section header p{font-size:11px}.crm-form-grid{grid-template-columns:minmax(0,1fr);gap:16px}.crm-span{grid-column:auto}.crm-form-grid>label{font-size:11px}.crm-category-checks{gap:12px 8px}.crm-category-checks .check-label{font-size:11px}.crm-form-footer .actions{width:100%;display:grid;grid-template-columns:1fr 1fr}.crm-form-footer .btn{padding:11px 10px;font-size:11px}.crm-more summary{font-size:12px}.crm-facts{gap:16px}.crm-contact-sidebar{padding:20px}.crm-import{padding:20px 16px}.crm-import-intro p{font-size:12px}.crm-file-form{grid-template-columns:minmax(0,1fr)}.crm-file-form>label:first-child{grid-column:auto}.crm-mapping-grid{grid-template-columns:minmax(0,1fr);gap:15px}.crm-import-file{padding:13px;font-size:11px;gap:7px;overflow-wrap:anywhere}.crm-import-preview h2{font-size:22px}.crm-import-preview>p{font-size:11px}.crm-preview-table th{font-size:10px}.crm-preview-table td{font-size:11px}.crm-import-preview .check-label{align-items:start;font-size:11px}.crm-import-preview .check-label input{margin-top:0}.crm-scope-note{font-size:10px;margin-top:25px;padding-top:17px}.crm-pagination{font-size:10px;gap:7px}.crm-pagination .btn{font-size:10px;padding:9px}}
