.project-archive-overlay{position:fixed;inset:0;background:#0006;z-index:1200;display:flex;align-items:center;justify-content:center;padding:12px;box-sizing:border-box}
.project-archive-panel{width:min(760px,100%);max-height:92vh;max-height:92dvh;background:#fff;border-radius:12px;display:flex;flex-direction:column;box-shadow:0 12px 40px #0003;overflow:hidden}
.project-archive-header{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:16px 20px;border-bottom:1px solid #eee}
.project-archive-header h3{margin:0;font-size:18px}.project-archive-header button,.project-archive-panel button{padding:8px 12px;border:1px solid #b9d8ff;border-radius:7px;background:#fff;color:#1989fa;cursor:pointer}
.project-archive-panel button:disabled{opacity:.55;cursor:default}.project-archive-panel button.primary{background:#1989fa;color:#fff;border-color:#1989fa}
.project-archive-body{padding:16px 20px;overflow:auto;min-height:0;overscroll-behavior:contain}.project-archive-title{font-size:14px;font-weight:700;overflow-wrap:anywhere;flex:1;min-width:0}
.project-archive-summary{display:flex;align-items:flex-end;gap:16px;margin-bottom:16px}.project-archive-price{flex:0 0 240px;max-width:100%}
.project-archive-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px}.project-archive-field{display:flex;flex-direction:column;gap:6px;font-size:13px;color:#666;min-width:0}.project-archive-field.wide{grid-column:1/-1}
.project-archive-grid.project-archive-notes{grid-template-columns:minmax(0,1fr)}.project-archive-grid.project-archive-notes textarea{flex:0 0 auto;height:50px;min-height:50px}
.project-archive-panel input,.project-archive-panel textarea,.project-archive-panel select{box-sizing:border-box;width:100%;min-width:0;padding:10px;border:1px solid #ddd;border-radius:7px;font-size:14px;background:#fff;color:#333;font-family:inherit}.project-archive-panel textarea{resize:vertical;min-height:88px}
.project-archive-panel select:disabled{opacity:1;background:#f6f7f8;color:#666}
.project-archive-panel input:read-only,.project-archive-panel textarea:read-only{background:#f6f7f8}.project-archive-actions{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end;margin-top:12px}
.project-archive-help{font-size:12px;color:#888;line-height:1.6;margin:10px 0}.project-archive-status{font-size:13px;line-height:1.6;color:#666;white-space:pre-wrap;overflow-wrap:anywhere;margin:0 0 12px}.project-archive-status.error{color:#cf1322}
.project-followup-heading{display:flex;justify-content:space-between;align-items:center;gap:12px;margin-top:22px;border-top:1px solid #eee;padding-top:16px}.project-followup-heading h4{margin:0}.project-followup-editor{margin-top:12px;padding:12px;background:#f6faff;border-radius:8px}
.project-followup-row{padding:12px 0;border-bottom:1px solid #eee;font-size:14px;line-height:1.7;white-space:pre-wrap;overflow-wrap:anywhere}.project-followup-row b{color:#1989fa}.project-followup-empty{padding:16px 0;color:#999;font-size:13px}
.project-followup-controls{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin:12px 0;font-size:12px;color:#888}.project-followup-controls label{display:flex;gap:6px;align-items:center}.project-followup-controls input[type=checkbox]{width:auto}
.project-followup-actions{display:flex;gap:8px;justify-content:flex-end;padding:6px 0}.project-followup-badge{color:#999;font-size:12px;margin-left:6px}.project-followup-editor .project-archive-field{margin-top:8px}
@media(max-width:480px){.project-archive-overlay{padding:8px}.project-archive-header{padding:12px}.project-archive-body{padding:12px}.project-archive-grid{grid-template-columns:1fr}.project-archive-field.wide{grid-column:auto}.project-archive-summary{flex-direction:column;align-items:stretch;gap:12px}.project-archive-price{flex:0 0 auto}}

/* Compact dossier header and integrated notes controls; retain the 480px breakpoint. */
.project-archive-header{align-items:flex-start;gap:12px}.project-archive-header>button{flex-shrink:0}
.project-archive-header .project-archive-heading{min-width:0;line-height:1.5;overflow-wrap:anywhere}
.project-archive-heading .project-archive-title{display:inline;font-size:14px;font-weight:600}
.project-archive-status:empty{display:none}
.project-archive-grid.project-archive-notes{display:block;border:1px solid #ddd;border-radius:8px;overflow:visible}
.project-archive-notes-toolbar{display:flex;align-items:center;gap:8px;min-width:0;padding:7px 10px;border-bottom:1px solid #eee;background:#fafcff;border-radius:8px 8px 0 0}
.project-archive-notes-caption{font-size:13px;color:#666;white-space:nowrap}
.project-archive-panel .project-archive-price-select{width:156px;max-width:44vw;height:28px;padding:3px 6px;font-size:13px;border-radius:5px}
.project-archive-panel .project-archive-save{margin-left:auto;padding:3px 9px;height:28px;font-size:12px;white-space:nowrap;border-radius:5px}
.project-archive-panel .project-archive-notes textarea{border:0;border-radius:0 0 8px 8px;margin:0;padding:8px 10px}
.project-archive-help-anchor{position:relative;display:inline-flex;flex-shrink:0}
.project-archive-panel .project-archive-help-button{display:inline-flex;align-items:center;justify-content:center;width:18px;height:18px;box-sizing:border-box;text-align:center;flex:0 0 18px;padding:0;border:1px solid #9eaebf;border-radius:50%;font-size:13px;line-height:1;background:#fff;color:#748599}
.project-archive-help-tooltip{position:absolute;left:-70px;top:25px;z-index:2;width:280px;max-width:70vw;padding:8px 10px;border-radius:6px;background:#263445;color:white;box-shadow:0 3px 12px #0002;font-size:12px;line-height:1.6;visibility:hidden;opacity:0;pointer-events:none}
.project-archive-help-anchor:hover .project-archive-help-tooltip,.project-archive-help-anchor:focus-within .project-archive-help-tooltip{visibility:visible;opacity:1}
.project-archive-help-button:focus-visible{outline:2px solid #1989fa;outline-offset:2px}
@media(max-width:480px){.project-archive-notes-toolbar{gap:6px;padding:6px 8px}.project-archive-panel .project-archive-price-select{width:132px;min-width:0}.project-archive-header .project-archive-heading{font-size:16px}.project-archive-heading .project-archive-title{font-size:13px}}

/* Follow-up controls share their title row; narrow screens retain a readable second row. */
.project-followup-heading-inline{justify-content:flex-start;gap:8px}
.project-followup-heading-inline h4{line-height:26px;white-space:nowrap}
.project-followup-heading-inline .project-followup-controls{margin:0;gap:8px}
.project-followup-heading-inline .project-followup-controls label{white-space:nowrap}
.project-archive-panel .project-followup-heading-inline button{height:26px;box-sizing:border-box;padding:2px 8px;font-size:13px;line-height:20px;white-space:nowrap}
.project-followup-heading-inline .project-followup-add{margin-left:auto}
@media(max-width:480px){.project-followup-heading-inline{display:grid;grid-template-columns:auto minmax(0,1fr);gap:8px}.project-followup-heading-inline h4{grid-row:1;grid-column:1}.project-followup-heading-inline .project-followup-add{grid-row:1;grid-column:2;justify-self:end;margin-left:0}.project-followup-heading-inline .project-followup-controls{grid-row:2;grid-column:1/-1}}

.project-history-list{margin-top:10px}.project-history-list .project-followup-entry{margin:6px 0}.project-history-list>.task-card{margin:6px 0}
@media(max-width:600px){.project-followup-heading-unified{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:8px}.project-followup-heading-unified h4{grid-row:1;grid-column:1}.project-followup-heading-unified .project-followup-add{grid-row:1;grid-column:2;justify-self:end;margin-left:0}.project-followup-heading-unified .project-followup-task-add{grid-row:1;grid-column:3;justify-self:end}.project-followup-heading-unified .project-followup-controls{grid-row:2;grid-column:1/-1}}

/* Timeline markers are presentation only; full statuses remain in accessible labels/details. */
.project-history-list .project-followup-entry{display:flex;align-items:center;gap:8px;box-sizing:border-box;min-height:39px;padding:6px 8px;border:1px solid #dce8f5;border-left:3px solid #389e0d;border-radius:8px}
.project-history-list .project-followup-entry .project-followup-row{flex:1;min-width:0;padding:0;border:0;font-size:12px;line-height:1.5}
.project-history-list .project-followup-entry .project-followup-actions{flex-shrink:0;padding:0;gap:6px}
.project-history-list .project-followup-entry button{padding:3px 7px;font-size:12px;white-space:nowrap}
.project-history-list .project-followup-deleted{border-left-color:#999}
.project-archive-panel .project-followup-heading-inline .project-archive-help-button{width:18px;height:18px;padding:0;font-size:13px;line-height:1}
.project-history-legend-row{display:flex;align-items:center;gap:7px;margin:3px 0}.project-history-legend-dot{display:inline-block;width:8px;height:8px;border-radius:50%;flex-shrink:0}.history-green{background:#389e0d}.history-red{background:#ee0a24}.history-gray{background:#999}
@media(max-width:600px){.project-followup-heading-unified{grid-template-columns:auto auto minmax(0,1fr) auto}.project-followup-heading-unified .project-history-help{grid-row:1;grid-column:2}.project-followup-heading-unified .project-followup-add{grid-column:3}.project-followup-heading-unified .project-followup-task-add{grid-column:4}}

/* Shared timeline columns keep recorders aligned with assignment executors, including read-only rows. */
.project-history-list{--history-date-width:38px;--history-people-width:260px;--history-actions-width:86px}
.project-history-list .project-followup-entry,.project-history-list .task-card.task-timed{display:grid;grid-template-columns:var(--history-date-width) minmax(40px,1fr) minmax(0,var(--history-people-width)) var(--history-actions-width);align-items:center;gap:8px;font-size:12px;line-height:1.5}
.project-history-list .task-line-meta{min-width:0;max-width:100%}.project-history-list .project-followup-meta{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:#777}
.project-history-list .project-followup-entry>.project-followup-actions{grid-column:4;justify-content:flex-end;min-width:0}.project-history-list .task-timed>button{justify-self:end}
@media(max-width:600px){.project-history-list .project-followup-entry,.project-history-list .task-card.task-timed{grid-template-columns:var(--history-date-width) minmax(40px,1fr) var(--history-actions-width);gap:3px 6px}.project-history-list .project-followup-meta{grid-row:2;grid-column:1/3;font-size:11px}.project-history-list .project-followup-entry>.project-followup-actions{grid-column:3;grid-row:1/3}}
