/* Customer assistant visual system. Scoped: main chat and production UI are untouched. */
#viewCustomers{--cw-accent:#bf3025;--cw-ink:#222631;--cw-muted:#68707d;background:#faf9f7;color:var(--cw-ink);font-family:"Segoe UI","PingFang SC","Microsoft YaHei",sans-serif}
#viewCustomers *{box-sizing:border-box}
body:has(#viewCustomers.on) .trial-mode{display:none}
.ca-make-box .ca-card-head{position:relative;padding-right:38px}
.ca-make-box .ca-card-head .ccs-close{position:absolute;right:0;top:0}
.ca-make-box .ca-make-input{font-family:"Segoe UI","Microsoft YaHei",sans-serif;font-size:16px;line-height:1.6}
#viewCustomers .ca-head{position:relative;padding:16px 28px;background:transparent;border:0;gap:16px;backdrop-filter:none}
#viewCustomers .ca-head h2{font-size:20px;letter-spacing:0}
#viewCustomers .ca-head .sub{font-size:12px;color:var(--cw-muted);line-height:1.6}
#viewCustomers:has(#caHomePane.on) .ca-head>div:first-child{display:none}
#viewCustomers:has(#caHomePane.on) .ca-head{justify-content:flex-end;padding-bottom:0}
#viewCustomers .ca-tabs{background:#f0eeeb;border-radius:12px;padding:4px}
#viewCustomers .ca-tab{min-height:38px;padding:8px 14px;font-size:13px;white-space:nowrap}
#viewCustomers .ca-tab.on{color:var(--cw-accent);background:#fff;box-shadow:0 2px 5px #32251c08}
.cw-home{max-width:1320px;margin:auto;padding:8px 28px 28px!important}
.cw-hero{display:grid;grid-template-columns:minmax(250px,1.08fr) minmax(230px,1fr) minmax(250px,.85fr);align-items:center;gap:8px;min-height:246px}
.cw-intro{position:relative;z-index:1;padding:12px 0 24px}
.cw-greeting{color:#737885;font-size:13px;margin:0 0 12px}
.cw-intro h1{font-size:clamp(28px,2.65vw,40px);line-height:1.35;letter-spacing:-1px;margin:0;font-weight:750}
.cw-intro h1 em{font-style:normal;color:var(--cw-accent)}
.cw-intro>p:last-child{font-size:13px;color:var(--cw-muted);line-height:1.8;margin:12px 0 0;max-width:320px}
.cw-coach-art{width:116%;max-width:none;height:270px;object-fit:contain;object-position:center bottom;margin-left:-8%;mix-blend-mode:multiply;align-self:end;pointer-events:none}
.cw-entry{position:relative;border:1px solid #e9e6e2;background:#fff;border-radius:16px;padding:4px 18px;box-shadow:0 4px 18px #33221903}
.cw-entry button{display:flex;align-items:center;gap:12px;text-align:left;background:none;border:0;width:100%;padding:22px 0;color:inherit;font:inherit;cursor:pointer}
.cw-entry button+button{border-top:1px solid #f0eeeb}
.cw-entry button>div{flex:1;min-width:0}
.cw-entry strong{display:block;font-size:16px;line-height:1.5;margin-bottom:4px}
.cw-entry span{font-size:12px;color:var(--cw-muted);line-height:1.6}
.cw-entry svg:first-child{width:38px;height:38px;padding:8px;border-radius:11px;background:#fff1ee;color:var(--cw-accent);flex-shrink:0}
.cw-entry svg:last-child{width:17px;height:17px;color:#8b8f98;flex-shrink:0}
.cw-entry button:hover strong{color:var(--cw-accent)}
.cw-plan{position:relative;padding:22px 28px;background:#fff2ef;border:1px solid #f3ded8;border-radius:16px;margin:0 0 18px}
.cw-plan-meta{font-size:12px;color:#97534c;margin:0 0 10px}
.cw-plan-text{font-size:18px;line-height:1.75;font-weight:600;margin:0 0 18px;max-width:920px}
.cw-plan-actions{display:flex;gap:10px;flex-wrap:wrap}
.cw-plan-actions .cj-button{font-size:15px!important;min-height:46px!important;padding:11px 20px!important}
.cw-columns{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(0,1fr);gap:18px}
.cw-panel{border:1px solid #e8e5e1;background:#fff;border-radius:16px;padding:20px;min-width:0}
.cw-panel-header{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;border-bottom:1px solid #f0eeeb;padding-bottom:14px}
.cw-panel h2{display:flex;align-items:center;gap:10px;font-size:20px;margin:0;font-weight:650}
.cw-panel h2 svg{width:21px;height:21px;color:var(--cw-accent)}
.cw-panel-header>span{font-size:12px;color:var(--cw-muted)}
.cw-customer-row{display:flex;align-items:center;gap:12px;padding:16px 0;border-bottom:1px solid #f0eeeb;min-width:0}
.cw-customer-row:last-child{border-bottom:0}
.cw-row-copy{flex:1;min-width:0}
.cw-row-copy strong{font-size:15px;overflow-wrap:anywhere}
.cw-row-copy p{font-size:14px;color:var(--cw-muted);line-height:1.7;margin:5px 0 0;overflow-wrap:anywhere}
.cw-badge{font-size:11px;display:inline-block;padding:3px 8px;border-radius:20px;background:#fff0ed;color:#a7382d;margin-left:8px}
.cw-customer-row .cj-button{flex-shrink:0;font-size:13px;padding:8px 12px;min-height:40px}
.cw-time{color:var(--cw-accent);font-weight:650;font-size:22px;min-width:66px}
.cw-time small{display:block;font-size:11px;font-weight:400;margin-top:5px}
.cw-empty{color:var(--cw-muted);font-size:13px;line-height:1.8;padding:16px 0 2px;margin:0}
.cw-clients{margin-top:18px}
.cw-search{border:1px solid #e1deda;border-radius:9px;padding:10px 12px;min-width:180px;max-width:100%;font:inherit;font-size:13px;background:#fff}
.cw-tools{display:flex;gap:8px;flex-wrap:wrap}
.cw-status{font-size:12px;color:var(--cw-muted);margin:12px 0 0;min-height:18px}
.cw-reason{display:block;color:#786a66;font-size:12px;line-height:1.7;margin-top:5px}
.cw-picker{display:grid;gap:8px;margin-top:15px;max-height:50vh;overflow:auto}
.cw-home [aria-pressed=true]{color:var(--cw-accent);background:#fff1ef}
.cw-suggestions:empty{display:none}
.cw-suggestions{margin-top:12px}
.cw-suggestions .cw-customer-row{border-color:#eed7d2}
/* One set of controls across upload, archive, follow-up and private-coach dialogs. */
#viewCustomers .cj-button,.ca-side .cj-button,.cj-modal .cj-button{border-color:#e3ded8;color:#343843;background:#fff;border-radius:10px;min-height:42px;font:500 13px/1.5 "Segoe UI","Microsoft YaHei",sans-serif;padding:10px 15px}
#viewCustomers .cj-button:hover,.ca-side .cj-button:hover,.cj-modal .cj-button:hover{background:#fff5f1;border-color:#d9b7ad}
#viewCustomers .cj-button.primary,.ca-side .cj-button.primary,.cj-modal .cj-button.primary{background:#bf3025;border-color:#bf3025;color:#fff}
#viewCustomers button:focus-visible,.ca-side button:focus-visible,.cj-modal button:focus-visible{outline:3px solid #d67562;outline-offset:3px}
#viewCustomers button:disabled{opacity:.55;cursor:wait}
#viewCustomers .ca-pane:not(.cw-home){max-width:1320px;margin:auto;padding:20px 28px 40px}
#viewCustomers .ca-workflow{max-width:850px;gap:20px}
#viewCustomers .ca-card{border-color:#e8e3de;border-radius:18px;padding:26px;box-shadow:0 5px 20px #37272003}
#viewCustomers .ca-step{margin-bottom:22px;gap:13px}
#viewCustomers .ca-step>b{width:36px;height:36px;background:#fff0ec;color:#b53328;border-radius:11px}
#viewCustomers .ca-step strong{font-size:18px;font-weight:650}
#viewCustomers .ca-step small{font-size:13px;color:#68707d;margin-top:5px}
#viewCustomers .ca-drop{min-height:230px;background:#fdfaf7;border-color:#d9c5bb;gap:12px}
#viewCustomers .ca-drop small{font-size:12px;color:#68707d}
#viewCustomers .ca-form-grid,#viewCustomers .ca-detail-form{gap:18px}
#viewCustomers label{font-size:13px;line-height:1.7}
#viewCustomers input,#viewCustomers select,#viewCustomers textarea{font-family:inherit;color:#303640}
#viewCustomers .ca-form-grid input,#viewCustomers .ca-form-grid select,#viewCustomers .ca-form-grid textarea{padding:12px;border-radius:10px;font-size:14px}
#viewCustomers .ca-guide{gap:18px;padding:22px 0}
#viewCustomers .ca-guide p{font-size:17px;line-height:1.8}
#viewCustomers .ca-reason{background:#f8f6f2;padding:18px;line-height:1.8}
#viewCustomers .ca-archive-layout{grid-template-columns:250px minmax(0,1fr);gap:22px;min-height:0}
#viewCustomers .ca-archive-tools{margin-bottom:22px}
#viewCustomers .ca-customer{margin:0;padding:14px;border-color:#e8e3df;box-shadow:none}
#viewCustomers .ca-customer.on{background:#fff1eb;border-color:#d89f90}
#viewCustomers .ca-avatar{background:#f7e8e2;color:#a63226}
#viewCustomers .ca-detail-head{padding:0 0 8px}
#viewCustomers .ca-detail{padding:0;background:transparent;box-shadow:none;border:0}
#viewCustomers .ca-detail-head h3{font-size:24px}
#viewCustomers .cj-workspace{max-width:none}
#viewCustomers .cj-coach-entry{background:#fff0ea;border-color:#f0d9cf;color:#632c23;padding:22px;border-radius:16px}
#viewCustomers .cj-coach-entry h2{font-size:22px;margin:7px 0}
#viewCustomers .cj-coach-entry p{color:#79605a}
#viewCustomers .cj-info-tabs .on{background:#fff0ea;border-color:#d6ac9e}
#viewCustomers .cj-info-pane,#viewCustomers .cj-progress{border-color:#e8e3de;border-radius:16px}
#viewCustomers .cj-step.current{color:#a12d24}
#viewCustomers .cj-step.current .cj-step-dot{background:#bf3025;box-shadow:0 0 0 3px #f6e1db}
#viewCustomers .cj-empty{border-color:#ddc6bb;background:#fffdfa;padding:32px 24px}
#viewCustomers .cj-empty h2{color:#44332f;font-size:22px}
#viewCustomers .cj-empty p{color:#746c67}
.ca-side{width:min(560px,100vw);box-shadow:-12px 0 48px #31221c14;font-family:"Segoe UI","Microsoft YaHei",sans-serif}
.ca-side-head{padding:22px 52px 20px 24px;background:#fffaf6}
.ca-side-head strong{font-size:19px}
.ca-side-head small{line-height:1.7;color:#68707d}
.ca-side-list{padding:22px 24px;background:#faf9f7}
.ca-turn{margin-bottom:22px}
.ca-turn .ca-turn-body{padding:16px 18px;line-height:1.85;border-radius:16px;border-color:#ece5df;font-size:14px}
.ca-turn.me .ca-turn-body{background:#fff0e9;border-color:#f0d9ce}
.ca-side-foot{padding:14px 20px max(18px,env(safe-area-inset-bottom));background:#fff;border-top:1px solid #ece5df}
.ca-side-input{font-family:inherit;font-size:15px;line-height:1.7;padding:12px;min-height:50px}
.cj-modal{font-family:"Segoe UI","Microsoft YaHei",sans-serif}
@media(max-width:1180px){
.cw-hero{grid-template-columns:minmax(220px,1.1fr) minmax(180px,.9fr)}.cw-coach-art{height:240px}
.cw-entry{grid-column:1/-1;display:flex;margin-bottom:18px;padding:0 18px}.cw-entry button{flex:1;padding:16px 0}.cw-entry button+button{border-top:0;border-left:1px solid #eee9e4;margin-left:18px;padding-left:18px}
#viewCustomers .ca-head{flex-direction:row;align-items:center}
}
@media(max-width:900px){
.cw-columns{grid-template-columns:1fr 1fr}
#viewCustomers .ca-archive-layout{grid-template-columns:1fr}
#viewCustomers .ca-list{position:static;max-height:220px;grid-template-columns:repeat(2,minmax(0,1fr));overflow:auto}
.cw-customer-row{flex-wrap:wrap}.cw-row-copy{flex-basis:55%}
#viewCustomers .ca-head .sub{display:none}
}
@media(max-width:600px){
#viewCustomers .ca-head{padding:12px 14px;display:block}
#viewCustomers:has(#caHomePane.on) .ca-head{padding:10px 14px 0}
#viewCustomers .ca-head h2{font-size:18px;margin-bottom:10px}
#viewCustomers .ca-tabs{width:100%;overflow-x:auto}
#viewCustomers .ca-tab{font-size:12px;padding:10px;min-height:42px;flex:1}
.cw-home{padding:8px 14px 22px!important}.cw-hero{grid-template-columns:minmax(0,1.15fr) minmax(0,.85fr);gap:0;min-height:0}
.cw-intro{padding:20px 0}.cw-greeting{font-size:11px;margin-bottom:8px}
.cw-intro h1{font-size:clamp(22px,5.8vw,29px);letter-spacing:-.5px}
.cw-intro>p:last-child{font-size:12px;line-height:1.6;max-width:190px}
.cw-coach-art{height:185px;width:122%;margin-left:-15%}
.cw-entry{padding:0 12px;margin-bottom:14px;border-radius:13px}.cw-entry button{gap:8px;padding:14px 0}.cw-entry button+button{margin-left:10px;padding-left:10px}
.cw-entry strong{font-size:13px}.cw-entry span{font-size:11px}.cw-entry svg:first-child{width:28px;height:28px;padding:5px}.cw-entry svg:last-child{display:none}
.cw-plan{padding:18px;margin-bottom:14px;border-radius:14px}.cw-plan-text{font-size:16px;margin-bottom:14px}.cw-plan-actions .cj-button{flex:1;padding:10px 8px!important}
.cw-columns{grid-template-columns:1fr;gap:14px}.cw-panel{padding:17px;border-radius:14px}.cw-panel h2{font-size:17px}.cw-panel-header{gap:8px;padding-bottom:12px}
.cw-customer-row{gap:8px;padding:14px 0}.cw-time{font-size:20px;min-width:56px}.cw-time+.cw-row-copy{flex-basis:calc(100% - 68px)}
.cw-customer-row .cj-button{min-height:44px!important}.cw-clients{margin-top:14px}.cw-tools{width:100%}.cw-tools .cj-button{flex:1}
.cw-search{width:100%;min-width:0;font-size:16px}.cw-empty{padding-top:12px}
#viewCustomers .ca-pane:not(.cw-home){padding:14px}
#viewCustomers .ca-card{padding:18px;border-radius:14px}
#viewCustomers .ca-form-grid,#viewCustomers .ca-detail-form{grid-template-columns:1fr;gap:14px}
#viewCustomers input,#viewCustomers select,#viewCustomers textarea{font-size:16px}
#viewCustomers .ca-drop{min-height:205px}
#viewCustomers .ca-list{grid-template-columns:1fr;max-height:210px}
#viewCustomers .ca-detail-head{padding-top:8px;flex-wrap:wrap}
#viewCustomers .ca-customer{padding:12px}
#viewCustomers .cj-coach-entry{padding:18px}
#viewCustomers .cj-coach-entry>.cj-button{width:100%;margin-top:12px}
.ca-side{width:100vw}.ca-side-list{padding:16px}.ca-side-head{padding:18px 48px 16px 18px}.ca-side-input{font-size:16px}
.ca-side-tools{gap:7px}.ca-side-foot{padding-left:14px;padding-right:14px}
}
@media(prefers-reduced-motion:reduce){.ca-side{transition:none}}

/* 行内「隐藏 / 删除」（2026-09-18 用户要求：可主动隐藏和删除，都不真删库）。 */
.cw-row-actions{display:flex;gap:6px;flex-wrap:wrap;align-items:center;justify-content:flex-end}
.ca-owner-row{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:8px 0;border-bottom:1px solid var(--line,#e9ebee)}
.ca-owner-row:last-child{border-bottom:0}
/* Explicit results stay separate from AI suggestions and customer-stage changes. */
.cw-result-modal .cw-result-field{display:flex;flex-direction:column;gap:8px;margin:18px 0;font-size:16px;line-height:1.6;color:#303640}
.cw-result-modal .cw-result-field[hidden]{display:none}
.cw-result-modal .cj-input{width:100%;min-height:48px;font-size:16px;line-height:1.6;padding:12px}
.cw-result-modal textarea.cj-input{resize:vertical;min-height:140px}
.cw-result-hint{font-size:14px;line-height:1.7;color:#596273;margin:12px 0}
.cw-result-error{font-size:15px;line-height:1.6;color:#a1231d;margin:12px 0}
.cw-result-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:20px}
.cw-result-modal .cw-result-actions .cj-button{width:100%;min-height:48px;font-size:16px}
.cw-result-modal [disabled]{opacity:.65;cursor:wait}
#viewCustomers .cw-agenda-result-row{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;padding:10px 0;border-bottom:1px solid #eee5df}
#viewCustomers .cw-agenda-result-row:last-child{border-bottom:0}
#viewCustomers .cw-agenda-result-row .schedule-link{flex:1 1 150px;min-height:48px;font-size:16px;line-height:1.5;overflow-wrap:anywhere}
#viewCustomers .cw-agenda-result-row .cj-button{flex:0 0 auto;min-height:48px;font-size:16px;padding:10px 14px}
.cw-result-quote{white-space:pre-wrap;overflow-wrap:anywhere;font-size:15px;line-height:1.7;max-height:170px;overflow:auto;margin:10px 0}
.cw-saved-result summary,.ca-review-result summary{cursor:pointer;font-size:15px;line-height:1.6;padding:8px 0}
.ca-review-result{margin:0;padding:14px 20px;background:#fff3ed;border-bottom:1px solid #ecd5c8;flex:0 0 auto;max-height:35dvh;overflow:auto}
.ca-review-result[hidden]{display:none}
.ca-review-head{display:flex;align-items:center;justify-content:space-between;gap:8px}.ca-review-head strong{font-size:16px;line-height:1.6}
#viewCustomers .ca-review-hide,.ca-review-hide{flex-shrink:0;min-height:44px;padding:8px;background:transparent;border:0;color:#855345;cursor:pointer;font-size:14px}
.ca-review-status{font-size:14px;line-height:1.65;margin:8px 0;color:#665247}
#viewCustomers .ca-review-result .cj-button,.ca-review-result .cj-button{width:100%;min-height:48px;font-size:16px}
@media(max-width:600px){.ca-review-result{padding:12px 14px}.ca-review-result .cw-result-quote{max-height:120px}}
