/* V0.1.18 bugfix2. Scoped layout and Chinese date/time dialog. */
.project-progress-card,.staff-progress{margin-top:18px}
.project-detail-head p,.project-progress-card .card-head p,.stage-step strong,.next-action-card>p,.client-project-detail-grid .muted,.client-project-detail-grid small{font-size:12px}
.stage-step strong{line-height:1.5}
.stage-step{min-width:102px}.client-stage-flow{grid-template-columns:repeat(7,minmax(102px,1fr))}
.supp-date-field18{margin-top:16px}
.supp-builder-head{display:flex;justify-content:space-between;align-items:center;gap:12px;margin:18px 0}
.supp-builder-list{display:flex;flex-direction:column;gap:12px;margin:18px 0}
.supp-builder-row{display:grid;grid-template-columns:minmax(150px,168px) minmax(0,1fr) 76px 36px;gap:10px;align-items:center}
.supp-builder-row .staff-supp-type{min-width:150px;min-height:44px;padding-right:38px}
.supp-builder-row .input{min-width:0}.supp-builder-row .mini-check{font-size:12px;white-space:nowrap}
.expert-pool-list .mini-avatar.expert-surname18{display:grid;place-items:center;flex:0 0 44px;width:44px;height:44px;margin:0;font-size:24px;font-weight:800;line-height:1;border-radius:12px;color:#2e69c6}
.expert-pool-list .mini-avatar.compound18{font-size:19px}
.expert-surname18.avatar,.expert-surname18.profile-avatar{display:grid;place-items:center;font-size:22px;line-height:1}
.expert-surname18.compound18.avatar{font-size:17px}
.expert-pool-list>div>div{min-width:0}.expert-pool-list strong,.expert-pool-list span:not(.mini-avatar),.expert-pool-list small{font-size:12px;overflow-wrap:anywhere}
.date-entry18{position:relative;display:flex;align-items:center;min-width:0}
.date-entry18 .input{padding-right:46px;font-variant-numeric:tabular-nums;font-size:14px;width:100%}
.date-entry18 .input[readonly]{background:#fff;cursor:pointer}
.calendar-button18{position:absolute;right:8px;top:50%;transform:translateY(-50%);background:transparent;border:0;border-radius:6px;display:grid;place-items:center;width:32px;height:32px;color:#526a85}
.calendar-button18:hover{background:#edf4ff}.calendar-button18:focus-visible{outline:2px solid #3b82f6}
.calendar-backdrop18{position:fixed;inset:0;z-index:10050;background:rgba(20,34,54,.46);display:flex;align-items:center;justify-content:center;padding:16px}
.calendar-dialog18{width:380px;max-width:100%;max-height:calc(100dvh - 32px);overflow:auto;background:#fff;border:1px solid var(--line);border-radius:18px;padding:22px;box-shadow:0 24px 70px rgba(0,0,0,.25)}
.calendar-dialog18 h2{font-size:20px;line-height:1.4;margin:0 0 4px}.calendar-dialog18>p{margin:4px 0 14px}
.calendar-heading18{display:grid;grid-template-columns:32px minmax(94px,1fr) minmax(88px,1fr) 32px;gap:6px;align-items:center;margin:16px 0}
.calendar-heading18 .btn{padding:0;width:32px;height:34px}.calendar-heading18 label{display:flex;gap:3px;align-items:center;min-width:0;font-size:12px}
.calendar-heading18 .input{min-height:36px;padding:6px;font-size:14px;min-width:0}.calendar-heading18 select.input{padding-right:26px}
.calendar-week18,.calendar-days18{display:grid;grid-template-columns:repeat(7,minmax(0,1fr));gap:4px;text-align:center}
.calendar-week18{margin-bottom:7px;color:var(--muted);font-size:12px}
.calendar-day18{height:36px;border:1px solid transparent;border-radius:8px;background:#fff;font-size:14px;color:var(--ink)}
.calendar-day18:not(:disabled):hover{background:#edf4ff}.calendar-day18.today{border-color:#8bb4f3}.calendar-day18.selected{background:var(--blue-600);color:#fff}
.calendar-day18:disabled{background:#f7f8fa;color:#b8c1ce;opacity:1;cursor:not-allowed}
.calendar-time18{display:grid;grid-template-columns:1.2fr 1fr 1fr;gap:10px;margin-top:18px;border-top:1px solid var(--line);padding-top:16px}
.calendar-time18 label{display:flex;flex-direction:column;gap:5px;font-size:12px;font-weight:700}.calendar-time18 .input{font-size:14px;padding-left:10px;min-width:0}
.calendar-dialog18 .calendar-preview18{font-size:12px;min-height:36px;margin:14px 0;color:var(--muted)}
.calendar-dialog18 .modal-actions{margin-top:12px;display:flex;justify-content:flex-end;gap:10px}
#toastHost.result-host16{z-index:11000}
.supp-items18{display:flex;flex-direction:column;gap:10px;margin-top:14px}
.supp-item18{display:flex;align-items:center;justify-content:space-between;gap:16px;border:1px solid #eee3c9;background:#fff;border-radius:10px;padding:14px}
.supp-item-body18{min-width:0;flex:1}.supp-item-body18 strong{font-size:13px;overflow-wrap:anywhere}.supp-preview18{font-size:12px;margin:6px 0;color:var(--muted);white-space:pre-wrap;overflow-wrap:anywhere;max-height:66px;overflow:hidden}
.supp-item-actions18{display:flex;gap:8px;flex-shrink:0}.supp-finish18{display:flex;justify-content:space-between;align-items:center;gap:14px;margin-top:14px}
.supp-response18{border:1px solid var(--line);background:#f8fafd;border-radius:12px;padding:18px;font-size:14px;line-height:1.75;white-space:pre-wrap;overflow-wrap:anywhere;max-height:55vh;overflow:auto}
.supp-file-list18{display:grid;gap:12px}.supp-file18{display:flex;justify-content:space-between;align-items:center;gap:12px;border:1px solid var(--line);border-radius:10px;padding:14px}.supp-file18>div{min-width:0}.supp-file18 strong{display:block;overflow-wrap:anywhere}.supp-file18 small{display:block;font-size:12px}
.internal-note18{margin-top:16px}.note-actions18{display:flex;gap:8px;flex-wrap:wrap}.note-actions18>.btn{flex:1}.internal-history18{margin-top:20px}.internal-history18 h4{font-size:14px;margin:0 0 12px}.internal-history18 .pill{margin-left:5px}
.internal-note-entry18{padding:14px;border:1px solid var(--line);background:#f8fafd;border-radius:11px;margin:10px 0}.internal-note-meta18{display:flex;justify-content:space-between;gap:10px;align-items:center}.internal-note-meta18 strong{font-size:13px}.internal-note-entry18 small{display:block;font-size:12px;margin-top:6px}.internal-note-entry18 p{font-size:14px;line-height:1.65;margin:10px 0 0;white-space:pre-wrap;overflow-wrap:anywhere}
@media(max-width:700px){.supp-item18{align-items:flex-start;flex-direction:column}.supp-item-actions18{align-self:flex-end}.supp-finish18{align-items:flex-start;flex-direction:column}.supp-finish18 .btn{align-self:flex-end}}
@media(max-width:560px){.supp-builder-row{grid-template-columns:minmax(150px,1fr) 76px 36px}.supp-builder-row .staff-supp-name{grid-column:1/-1;grid-row:2}.supp-builder-row .mini-check{grid-column:2;grid-row:1}.supp-builder-row .icon-btn{grid-column:3;grid-row:1}.calendar-dialog18{padding:16px}.calendar-time18{gap:6px}.date-entry18 .input{font-size:14px}}
/* Let table containers scroll internally instead of stretching narrow pages. */
.staff-detail-grid>section,.staff-detail-grid>aside,.staff-expert-grid>section,.staff-expert-grid>aside,.client-project-detail-grid>section,.client-project-detail-grid>aside{min-width:0}
.staff-detail-grid .table-wrap,.staff-expert-grid .table-wrap{width:100%;max-width:100%}
@media(max-width:760px){.workspace-entry14{align-items:stretch;flex-direction:column}.workspace-entry14 .row-actions{flex-wrap:wrap}.staff-detail-grid,.staff-expert-grid{grid-template-columns:minmax(0,1fr)}}
