/* Shared workspace UI foundation. Component-specific charts and document exports keep their contracts. */
body:has(#pms-design2-shell) {--pms-control-height:38px;--pms-content-gap:20px;color-scheme:light}
body:has(#pms-design2-shell) :where(main,header,aside,nav,section,article,div:not(.evidence),form,fieldset,details,ul,ol,li,span) {font-family:inherit}
body:has(#pms-design2-shell) :is(#pms-design2-shell,#project-checklist,.pms-build-badge) {font-family:inherit}
body:has(#pms-design2-shell) #pms-design2-shell .pms-account-menu {border:0;padding:0;margin:0;background:transparent;box-shadow:none}
body:has(#pms-design2-shell) :is(h1,h2,h3,h4,p,a,label,button,input,select,textarea,table,summary,legend,dt,dd,small) {font-family:inherit}
body:has(#pms-design2-shell) :is(button,input,select,textarea) {font-size:12px;line-height:1.5}
body:has(#pms-design2-shell) textarea {border:1px solid #CAD5E2;border-radius:7px;padding:10px 12px;background:white;color:var(--pms-navy);max-width:100%}
body:has(#pms-design2-shell) input:is([type=radio],[type=checkbox]) {display:inline-block;width:16px;height:16px;min-height:0;padding:0;margin:0 6px 0 0;vertical-align:middle;accent-color:var(--pms-action,var(--pms-blue));flex-shrink:0}
body:has(#pms-design2-shell) main :is(button,.button,.button-link,.nav-tab) {font-size:12px;line-height:1.4;font-weight:600;border-radius:7px;min-height:var(--pms-control-height)}
body:has(#pms-design2-shell) main :is(.button,.button-link) {display:inline-flex;align-items:center;justify-content:center;gap:7px;padding:8px 13px;border:1px solid #CAD5E2;background:white;color:var(--pms-navy);text-decoration:none;cursor:pointer}
body:has(#pms-design2-shell) main :is(button,.button,.button-link,.nav-tab):hover:not(:disabled):not([aria-disabled=true]) {border-color:#9EB2C9}
body:has(#pms-design2-shell) main :is(button.primary,.button.primary,.nav-tab.primary,button[type=submit],.button-primary):not(.recycle-danger):not(.danger):not(.destructive) {background:var(--pms-action,var(--pms-blue));border-color:var(--pms-action,var(--pms-blue));color:white}
body:has(#pms-design2-shell) main :is(.recycle-danger,.danger,.destructive) {background:var(--pms-danger);border-color:var(--pms-danger);color:white}
body:has(#pms-design2-shell) main :is(button,.button,.nav-tab):is(:disabled,[aria-disabled=true]) {opacity:.6;cursor:not-allowed;box-shadow:none}
body:has(#pms-design2-shell) :is(button,[role=button])[aria-busy=true] {cursor:progress}
body:has(#pms-design2-shell) :is(button,input,select,textarea,a,summary,[tabindex]):focus-visible {outline:3px solid var(--pms-action,var(--pms-blue));outline-offset:3px}
body:has(#pms-design2-shell) >main {max-width:1600px;min-width:0;margin:0 auto;padding:26px 28px 90px}
body:has(#pms-design2-shell) >main>h1 {font-size:28px;line-height:1.25;letter-spacing:-.7px;font-weight:650;color:var(--pms-navy);margin:0 0 12px}
body:has(#pms-design2-shell) >main>h2 {font-size:26px;line-height:1.3;letter-spacing:-.6px;font-weight:650;color:var(--pms-navy);margin:0 0 12px}
body:has(#pms-design2-shell) main :is(h2,h3,h4) {line-height:1.4;color:var(--pms-navy)}
body:has(#pms-design2-shell) main :is(.muted,.hint,.bi-muted,.description) {color:var(--pms-muted);line-height:1.6}
body:has(#pms-design2-shell) main :is(.card,.access-card,.bi-card,.panel,.action-card,.import-state) {border:1px solid var(--pms-border);border-radius:12px;background:white;box-shadow:var(--pms-shadow)}
body:has(#pms-design2-shell) main :where(.pa-section-card,#imports,#reports) {border:1px solid var(--pms-border);border-radius:12px;background:white;box-shadow:var(--pms-shadow);padding:24px}
body:has(#pms-design2-shell) main :is(.card,.access-card,.bi-card) {padding:24px;margin:0 0 20px}
body:has(#pms-design2-shell) main :is(.controls,.filters,.filter-row,.button-row,.wizard-actions) {gap:12px;flex-wrap:wrap;align-items:center}
body:has(#pms-design2-shell) main :is(.controls,.filters,.filter-row) label {font-size:11px;font-weight:500;color:var(--pms-muted)}
body:has(#pms-design2-shell) main :is(.table-wrap,.table-wrapper,.access-table,.table-scroll) {overflow:auto;max-width:100%;border:1px solid var(--pms-border);border-radius:9px;scrollbar-width:thin}
body:has(#pms-design2-shell) main table {font-size:12px;font-variant-numeric:tabular-nums}
body:has(#pms-design2-shell) main :is(.matrix,.compare-table,.access-table>table) {width:100%}
body:has(#pms-design2-shell) main :is(.matrix,.compare-table,.access-table>table) :is(th,td) {padding:10px 12px;font-size:12px}
body:has(#pms-design2-shell) main :is(th,td) {line-height:1.5}
body:has(#pms-design2-shell) main table:not(.evolution-matrix):not(.c3-period-table):not(.c3-data-table) th {background:#F3F6FA;color:#52657A;font-size:11px;font-weight:600;border-color:var(--pms-border)}
body:has(#pms-design2-shell) main table:not(.evolution-matrix):not(.c3-period-table):not(.c3-data-table) td {border-color:var(--pms-border)}
body:has(#pms-design2-shell) main :is(.empty-state,.empty,.bi-empty) {padding:28px 22px;border:1px dashed #CCD7E5;border-radius:9px;background:#FAFBFD;color:var(--pms-muted);line-height:1.6}
body:has(#pms-design2-shell) main :is(.notice,.info,.error-box,.error,.warning-box) {border-radius:8px;font-size:12px;line-height:1.6;padding:14px 16px}
body:has(#pms-design2-shell) main .error-box {border-color:#E5BBBB;background:#FFF7F7;color:#913E3E}
body:has(#pms-design2-shell) main .info {border-color:#CBDCED;background:#F0F5FB;color:#314F70}
body:has(#pms-design2-shell) dialog {border:1px solid var(--pms-border);border-radius:12px;color:var(--pms-text);font:inherit;box-shadow:0 16px 48px #162B4526;max-width:calc(100vw - 32px)}
body:has(#pms-design2-shell) dialog::backdrop {background:#162B4566}
body:has(#pms-design2-shell) main details>summary {font-size:12px;font-weight:600;cursor:pointer;border-radius:7px}
body:has(#pms-design2-shell) main [hidden] {display:none!important}
/* Legacy workspace layouts adopt the same page/card rhythm as Dashboard and Controls. */
body:has(#pms-design2-shell) >main:not(:has(:is(#overview-page,#curves-workspace,#activity-progress,#progress))):not(#forensics-design2):not(.projects-design2) >section {margin-top:20px;margin-bottom:20px}
body:has(#pms-design2-shell) #persistent-header {border:1px solid var(--pms-border);border-left:4px solid var(--pms-action,var(--pms-blue));background:white;padding:18px 20px;border-radius:12px;box-shadow:var(--pms-shadow);margin:0 0 22px}
body:has(#pms-design2-shell) #persistent-header .controls {display:flex;gap:18px;align-items:center;flex-wrap:wrap}
body:has(#pms-design2-shell) #persistent-header .controls>div {min-width:0;flex:1 1 280px;font-size:13px;overflow-wrap:anywhere}
body:has(#pms-design2-shell) #persistent-header label {display:grid;gap:5px;font-size:11px;color:var(--pms-muted);max-width:440px;margin:0}
body:has(#pms-design2-shell) #persistent-header .controls label {min-width:0;flex:1 1 220px}
body:has(#pms-design2-shell) #persistent-header select {margin:0;font-size:12px;max-width:100%;min-width:0;width:100%}
body:has(#pms-design2-shell) #persistent-header .muted {display:block;font-size:10px;margin-bottom:4px}
body:has(#pms-design2-shell) :is(.bi-card,#phase72-import,.analysis-view,.schedule-view) {padding:24px;border:1px solid var(--pms-border);border-radius:12px;box-shadow:var(--pms-shadow);background:white}
body:has(#pms-design2-shell) #phase72-import>h3 {font-size:17px;margin-top:0}
body:has(#pms-design2-shell) .bi-card>h3 {font-size:16px;margin:0 0 14px}
body:has(#pms-design2-shell) #p6-update-assistant .p6ua-header,body:has(#pms-design2-shell) #p6-update-verification .p6ua-header {background:white;border:1px solid var(--pms-border);border-radius:12px;padding:22px}
body:has(#pms-design2-shell) .builder-header {position:static;max-width:1544px;margin:24px auto 0;background:white;color:var(--pms-navy);border:1px solid var(--pms-border);border-radius:12px;padding:22px 24px;box-shadow:var(--pms-shadow)}
body:has(#pms-design2-shell) .builder-header h1 {font-size:22px;letter-spacing:-.4px;font-weight:650}
body:has(#pms-design2-shell):has(.builder-header)>main {width:calc(100% - 56px);max-width:1544px;margin:22px auto 90px;padding:24px;background:white;border:1px solid var(--pms-border);border-radius:12px;box-shadow:var(--pms-shadow)}
body:has(#pms-design2-shell) .builder-header .context {font-size:11px;color:var(--pms-muted);gap:12px 20px}
body:has(#pms-design2-shell) .builder-header :is(button,.exit) {font-size:12px;background:white;color:var(--pms-navy);border:1px solid #CAD5E2;padding:8px 13px;min-height:38px;border-radius:7px}
body:has(#pms-design2-shell) .modal-backdrop {z-index:100}
body:has(#pms-design2-shell) .modal {border-radius:12px;border:1px solid var(--pms-border)}
body:has(#pms-design2-shell) .steps {gap:8px;margin-bottom:24px;overflow:auto}
body:has(#pms-design2-shell) .steps button {flex:1;min-width:125px;background:#F3F6FA;border:1px solid var(--pms-border);color:var(--pms-muted)}
body:has(#pms-design2-shell) .steps button.active {background:var(--pms-action,var(--pms-blue));border-color:var(--pms-action,var(--pms-blue));color:white}
body:has(#pms-design2-shell) main .curve {padding:14px 16px;border-radius:8px;border-color:var(--pms-border);margin:10px 0}
body:has(#pms-design2-shell) main .access-module-form {background:#F8FAFD;border-color:var(--pms-border);border-radius:9px;padding:18px}
body:has(#pms-design2-shell) main .access-grid {gap:20px}
body:has(#pms-design2-shell) main .access-narrow {max-width:480px;margin:20px auto}
body:has(#pms-design2-shell) .pms-ai-panel {font-family:inherit;border-color:var(--pms-border);border-radius:12px;color:var(--pms-text)}
body:has(#pms-design2-shell) .pms-ai-panel :is(button,textarea,select) {font-family:inherit;border-radius:7px;font-size:12px}
body:has(#pms-design2-shell) .pms-ai-panel textarea {background:white;color:var(--pms-navy);line-height:1.6}
body:has(#pms-design2-shell) .pms-ai-panel [data-ai-submit],body:has(#pms-design2-shell) main .bi-button {background:var(--pms-action,var(--pms-blue));border:1px solid var(--pms-action,var(--pms-blue));color:white;font-size:12px;min-height:38px;border-radius:7px;padding:8px 13px}
body:has(#pms-design2-shell) .js-plotly-plot text {font-family:"Segoe UI Variable Text","Segoe UI",system-ui,sans-serif!important}
body:has(#pms-design2-shell) :is(.pms-ai-answer,.pms-ai-message) {border-color:var(--pms-border);border-radius:9px}
body:has(#pms-design2-shell) :is(.pa-accordion,.access-user) {border-radius:9px;border-color:var(--pms-border)}
body:has(#pms-design2-shell) main .top {gap:20px;flex-wrap:wrap}
body:has(#pms-design2-shell) .access-account {font-family:inherit}
body:has(#pms-design2-shell) #project-portfolio .portfolio-header {position:static;background:white;color:var(--pms-navy);padding:22px 24px;border:1px solid var(--pms-border);border-radius:12px;box-shadow:var(--pms-shadow);gap:20px}
body:has(#pms-design2-shell) #project-portfolio .portfolio-header h1 {font-size:28px;letter-spacing:-.7px;margin:0}
body:has(#pms-design2-shell) .p6ua-header h1 {display:none}
@media(min-width:1400px) {body.project-checklist-open:has(#pms-design2-shell)>main {max-width:calc(100% - 340px);margin-left:0;margin-right:340px}}
@media(min-width:1400px) {body.project-checklist-open:has(#pms-design2-shell) .builder-header {width:calc(100% - 396px);max-width:none;margin-left:28px;margin-right:368px}}
@media(min-width:1400px) {body.project-checklist-open:has(#pms-design2-shell):has(.builder-header)>main {width:calc(100% - 396px);max-width:none;margin-left:28px;margin-right:368px}}
@media(max-width:900px) {body:has(#pms-design2-shell)>main {padding:24px 24px 90px}body:has(#pms-design2-shell) .builder-header {margin:20px 24px 0}body:has(#pms-design2-shell) main .row {grid-template-columns:minmax(0,1fr)}body:has(#pms-design2-shell) #persistent-header label {max-width:100%;flex:1}}
@media(max-width:600px) {body:has(#pms-design2-shell)>main {padding:22px 16px 90px}body:has(#pms-design2-shell)>main>h1 {font-size:25px}body:has(#pms-design2-shell)>main>h2 {font-size:24px}body:has(#pms-design2-shell) main :is(.access-card,.bi-card,#phase72-import) {padding:18px}body:has(#pms-design2-shell) main .access-grid {grid-template-columns:minmax(0,1fr)}body:has(#pms-design2-shell) .builder-header {margin:18px 16px 0;padding:18px}body:has(#pms-design2-shell) .builder-header .context {display:grid;gap:8px}}
@media(max-width:600px) {body:has(#pms-design2-shell):has(.builder-header)>main {width:calc(100% - 32px);padding:18px;margin-top:18px}}
@media print {body:has(#pms-design2-shell)>main {max-width:none;margin:0;padding:0}body:has(#pms-design2-shell) .builder-header,body:has(#pms-design2-shell) #pms-design2-shell {display:none!important}body:has(#pms-design2-shell) main :is(.card,.access-card,.bi-card,.panel) {box-shadow:none}}
