/* Original portal page-content / page-heading geometry, shared by Office and shadow roots. */
.office>.stage>.content,.office.is-estimation-dashboard>.stage>.content{width:min(1540px,100%);max-width:1540px;margin:0 auto;padding:34px clamp(20px,3vw,40px) 64px}
:is(.content,:host) :is(.page-heading,.workspace-heading){display:flex;align-items:flex-end;justify-content:space-between;flex-direction:row;flex-wrap:nowrap;gap:22px;min-width:0;margin:0 0 26px;padding:0;font-family:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}
:is(.content,:host) :is(.page-heading,.workspace-heading)>div:first-child{min-width:0;flex:1}
:is(.content,:host) :is(.page-heading,.workspace-heading) h1{margin:0;font-size:clamp(32px,3vw,42px);font-weight:760;letter-spacing:-.045em;line-height:1.05;color:var(--text,var(--ink))}
:is(.content,:host) :is(.page-heading,.workspace-heading) p{max-width:760px;margin:9px 0 0;font-size:14px;line-height:1.55;color:var(--muted)}
:is(.content,:host) :is(.page-heading,.workspace-heading) .heading-actions{display:flex;align-items:center;align-self:flex-end;justify-content:flex-end;flex-wrap:wrap;gap:8px;flex:0 1 auto;margin:0}
:is(.content,:host) :is(.page-heading,.workspace-heading) .crumbs{display:none}
:is(.content,:host) :is(.page-heading,.workspace-heading) :is(.primary,.button,.primary-button,.secondary-button){height:42px;min-height:42px;padding:0 16px;border-radius:11px;display:inline-flex;align-items:center;justify-content:center;gap:8px;font-size:12px;font-weight:700;white-space:nowrap}
/* Migration bookkeeping was not part of the original page header. */
.content :is(.persistent-directory,.persistent-subcontractors,.project-module)>.directory-summary{display:none}
/* Keep the approved viewport-fitted calendar and tasks layout. */
@media(min-width:901px){.office.is-estimation-dashboard>.stage>.content{padding-bottom:14px}.office.is-estimation-dashboard .content>.page-heading{flex:none}}
@media(max-width:1180px){.office>.stage>.content,.office.is-estimation-dashboard>.stage>.content{padding-inline:24px}}
@media(max-width:860px){.office>.stage>.content,.office.is-estimation-dashboard>.stage>.content{padding:28px 20px 52px}:is(.content,:host) :is(.page-heading,.workspace-heading){gap:16px}:is(.content,:host) :is(.page-heading,.workspace-heading) p{font-size:13px}}
@media(max-width:760px){.office>.stage>.content,.office.is-estimation-dashboard>.stage>.content{padding:18px 12px 26px}:is(.content,:host) :is(.page-heading,.workspace-heading){align-items:flex-start;flex-direction:column;gap:16px;margin-bottom:17px}:is(.content,:host) :is(.page-heading,.workspace-heading) h1{font-size:clamp(28px,8vw,36px)}:is(.content,:host) :is(.page-heading,.workspace-heading) .heading-actions{align-self:stretch;justify-content:flex-start;width:100%;margin:0}:is(.content,:host) :is(.page-heading,.workspace-heading)>div:first-child{flex-basis:auto}}

.project-workspace-header{min-width:0;margin-bottom:14px;display:grid;grid-template-columns:minmax(0,1fr) auto;gap:20px;align-items:start}
.project-workspace-header-main{min-width:0}
.project-workspace-back{margin:0 0 8px;padding:0;display:inline-flex;align-items:center;gap:6px;border:0;background:transparent;color:#a52732;font-size:11px;font-weight:800;cursor:pointer}
.project-workspace-back svg{width:15px;height:15px}
.project-workspace-back:focus-visible{outline:2px solid #c62e3b;outline-offset:3px;border-radius:4px}
.project-workspace-header h1{max-width:1000px;margin:0 0 7px;font-size:clamp(30px,3.6vw,48px);font-weight:760;line-height:1.03;letter-spacing:-.05em}
.project-workspace-header p{max-width:1000px;margin:0;color:var(--muted);font-size:13px;line-height:1.5}
.project-workspace-actions{padding-top:48px;display:flex;justify-content:flex-end;align-items:center;flex-wrap:wrap;gap:8px}
.project-workspace-actions>button{white-space:nowrap}


:root{--font-ui:Inter,ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;--sidebar-width:264px}
body{font-family:var(--font-ui)}
@media(min-width:801px){.office>.sidebar{width:264px}.office>.stage{margin-left:264px}}
.office>.stage>.topbar{height:68px;min-height:68px}
.content .project-workspace-header{font-family:var(--font-ui)}
.content .project-workspace-header h1{font-size:clamp(30px,3.6vw,48px);font-weight:760;line-height:1.03;letter-spacing:-.05em;margin:0 0 7px}
.content .project-workspace-actions>.primary{height:42px;min-height:42px;padding:0 16px;font-size:12px;font-weight:700;border-radius:12px}
@media(max-width:800px){.office>.stage>.topbar{height:auto}}
@media(max-width:760px){.project-workspace-header{grid-template-columns:1fr;gap:10px}.project-workspace-actions{padding-top:0;justify-content:flex-start}.project-workspace-actions>button{flex:1;justify-content:center}}

/* Project header and five-section navigation: original portal reference. */
.content .work-detail .project-workspace-header{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:20px;align-items:start;margin:0 0 14px;padding:0}
.content .work-detail .project-workspace-back{display:inline-flex;align-items:center;gap:6px;height:auto;min-height:0;margin:0 0 8px;padding:0;border:0;border-radius:0;background:transparent;box-shadow:none;backdrop-filter:none;color:#a52732;font-size:11px;font-weight:800;line-height:1.5;transform:none}
.content .work-detail .project-workspace-back svg{width:15px;height:15px;stroke-width:2}
.content .work-detail .project-workspace-header h1{max-width:1000px;margin:0 0 7px;font-size:clamp(30px,3.6vw,48px);font-weight:760;line-height:1.03;letter-spacing:-.05em}
.content .work-detail .project-workspace-header p{max-width:1000px;margin:0;font-size:13px;line-height:1.5;color:var(--muted)}
.content .work-detail .project-workspace-actions{display:flex;align-items:center;justify-content:flex-end;gap:8px;padding-top:48px}
.content .work-detail .project-workspace-actions>.primary{height:42px;min-height:42px;padding:0 16px;border:1px solid #d72b3a;border-radius:12px;background:linear-gradient(145deg,#d83848,#d32e40);box-shadow:0 9px 24px #d52c3930,inset 0 1px 0 #ffffff47;color:#fff;font-size:12px;font-weight:700;gap:8px}
.content .work-detail .project-workspace-actions>.primary svg{width:16px;height:16px}
.content .work-detail .work-detail-tabs{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));grid-auto-flow:row;min-height:64px;margin:0 0 14px;padding:6px;gap:5px;overflow-x:auto;border:1px solid var(--line);border-radius:16px;background:rgba(255,255,255,.58);box-shadow:none;backdrop-filter:none}
.content .work-detail .work-detail-tabs>button{min-width:0;min-height:52px;padding:8px 10px;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--muted);display:flex;align-items:center;gap:9px;text-align:left;box-shadow:none;outline:none;transform:none}
.content .work-detail .work-tab-icon{width:30px;height:30px;flex:0 0 30px;padding:7px;border-radius:8px;background:#f1f3f1;color:#69736d;box-shadow:none}
.content .work-detail .work-tab-icon svg{width:16px;height:16px}
.content .work-detail .work-detail-tabs>button>span:last-child{min-width:0;display:flex;flex-direction:column;gap:3px;overflow:hidden}
.content .work-detail .work-detail-tabs strong,.content .work-detail .work-detail-tabs small{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;line-height:1.2;margin:0}
.content .work-detail .work-detail-tabs strong{font-size:10px;font-weight:700}
.content .work-detail .work-detail-tabs small{font-size:9px;font-weight:400}
.content .work-detail .work-detail-tabs>button:hover{border-color:var(--line);background:rgba(255,255,255,.72);color:var(--text)}
.content .work-detail .work-detail-tabs>button[aria-selected=true]{border-color:rgba(198,46,59,.28);background:#faecee;color:#972731;box-shadow:inset 0 0 0 1px rgba(198,46,59,.08)}
.content .work-detail .work-detail-tabs>button[aria-selected=true] .work-tab-icon{background:#fff;color:#a52732}
.content .work-detail :is(.project-workspace-back,.work-detail-tabs>button):focus-visible{outline:2px solid #c62e3b;outline-offset:2px}
html[data-theme=dark] .content .work-detail .project-workspace-back{color:#ef9da4}
html[data-theme=dark] .content .work-detail .work-detail-tabs{background:rgba(255,255,255,.025)}
html[data-theme=dark] .content .work-detail .work-tab-icon{background:rgba(255,255,255,.08);color:#b8c0bb}
html[data-theme=dark] .content .work-detail .work-detail-tabs>button:hover{background:rgba(255,255,255,.06)}
html[data-theme=dark] .content .work-detail .work-detail-tabs>button[aria-selected=true]{background:rgba(198,46,59,.16);color:#ef9da4;box-shadow:inset 0 0 0 1px rgba(198,46,59,.18)}
html[data-theme=dark] .content .work-detail .work-detail-tabs>button[aria-selected=true] .work-tab-icon{background:rgba(198,46,59,.16);color:#ef9da4}
@media(max-width:760px){.content .work-detail .project-workspace-header{grid-template-columns:1fr;gap:10px}.content .work-detail .project-workspace-actions{padding-top:0;justify-content:flex-start}.content .work-detail .work-detail-tabs{grid-template-columns:repeat(5,minmax(138px,1fr));gap:5px;padding:5px}.content .work-detail .work-detail-tabs>button{padding:8px;gap:7px}}

.project-workspace-title-row{display:flex;align-items:center;gap:12px;margin-bottom:7px;min-width:0}
.project-workspace-title-row h1{margin-bottom:0!important;min-width:0;overflow-wrap:anywhere}
.quote-name-edit{display:grid;place-items:center;width:36px;height:36px;flex:0 0 36px;border:1px solid var(--line,#dde1df);border-radius:50%;background:var(--panel,rgba(255,255,255,.72));color:var(--muted,#64706b);transition:color .18s,border-color .18s,background .18s}
.quote-name-edit svg{width:16px;height:16px}
.quote-name-edit:hover:not(:disabled){color:#ca2639;border-color:#ca2639;background:rgba(202,38,57,.06)}
.quote-name-edit:focus-visible{outline:2px solid #ca2639;outline-offset:3px}
.quote-name-edit:disabled{opacity:.4;cursor:not-allowed}
.quote-name-modal{width:min(480px,calc(100vw - 32px))}

.quote-name-modal>label{margin:20px 24px}
.quote-name-modal>.modal-actions{padding:0 24px}
.quote-name-modal>.form-error{margin:0 24px 16px}
.quote-name-modal input{font-size:14px}
