/* Job theme contract. Override these tokens in a later theme stylesheet or on
   an ancestor; layout and controller code contain no palette values. */
:root {
  --job-overview:#285ac2; --job-overview-wash:#eef3ff;
  --job-preparation:#7044aa; --job-preparation-wash:#f5effb;
  --job-files:#096d83; --job-files-wash:#eaf6f8;
  --job-delivery:#237449; --job-delivery-wash:#edf7f0;
  --job-radius:14px; --job-gap:16px;
  --job-surface:var(--pf-card,#fff); --job-ink:var(--pf-ink,#203b35);
  --job-muted:var(--pf-muted,#60736b); --job-line:var(--pf-line,#d6e1db);
}
.job-workspace,.job-composer,.job-share-dialog {
  --job-accent:var(--job-overview); --job-wash:var(--job-overview-wash);
  color:var(--job-ink);
}
.job-workspace{--job-viewport-fallback:100vh}
@supports (height:100dvh){.job-workspace{--job-viewport-fallback:100dvh}}
[data-job-stage=overview],.job-workspace[data-current-job-stage=overview]{--job-accent:var(--job-overview);--job-wash:var(--job-overview-wash)}
[data-job-stage=preparation],.job-workspace[data-current-job-stage=preparation]{--job-accent:var(--job-preparation);--job-wash:var(--job-preparation-wash)}
[data-job-stage=files],.job-workspace[data-current-job-stage=files]{--job-accent:var(--job-files);--job-wash:var(--job-files-wash)}
[data-job-stage=delivery],.job-workspace[data-current-job-stage=delivery],.job-share-dialog{--job-accent:var(--job-delivery);--job-wash:var(--job-delivery-wash)}
/* Four stable destinations, with secondary tools belonging to their stage. */
#portfolioProjectTabs.job-stage-navigation{display:flex;flex:1 1 auto;flex-direction:column;min-height:0;padding:10px var(--ops-page-inset,16px);border-bottom:1px solid var(--job-line);background:var(--job-surface)}
.job-stage-navigation>.job-stage-bar{flex:none}
.job-work-scroll{display:flex;flex-direction:column;align-self:stretch;width:100%;min-width:0;overflow-x:hidden;touch-action:pan-y;scroll-padding-block:8px}
.job-work-scroll>*{flex:none;min-width:0}
.job-workspace .job-work-scroll:focus-visible{outline-offset:-2px}
.job-stage-bar{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
#portfolioProjectTabs .job-stage-bar>button{display:flex;align-items:center;justify-content:center;gap:8px;min-width:0;min-height:52px;padding:8px;border:1px solid var(--job-line);border-radius:var(--job-radius);background:var(--job-surface);color:var(--job-accent);font:inherit;font-size:13px;line-height:1.2;font-weight:650;cursor:pointer}
/* Overlay the description so a reveal never moves the number or nearby tools. */
.job-stage-labels{position:relative;display:grid;align-items:center;flex:1;min-width:0;min-height:2.4em}
.job-stage-title,.job-stage-hint{transition:opacity 140ms ease,transform 140ms ease}
.job-stage-hint{position:absolute;inset:0;display:grid;place-content:center;opacity:0;transform:translateY(3px);pointer-events:none}
@media(min-width:601px){
  .job-stage-bar>button:focus-visible .job-stage-title{opacity:0;transform:translateY(-3px)}
  .job-stage-bar>button:focus-visible .job-stage-hint{opacity:1;transform:none}
}
@media(hover:hover) and (min-width:601px){
  .job-stage-bar>button:not(:disabled):hover .job-stage-title{opacity:0;transform:translateY(-3px)}
  .job-stage-bar>button:not(:disabled):hover .job-stage-hint{opacity:1;transform:none}
}
@media(prefers-reduced-motion:reduce){.job-stage-title,.job-stage-hint{transition:none;transform:none!important}}
#portfolioProjectTabs .job-stage-bar>button.is-active{border-color:var(--job-accent);background:var(--job-wash);box-shadow:inset 0 -2px var(--job-accent)}
.job-stage-number{display:grid;place-items:center;flex:none;width:23px;height:23px;border-radius:50%;background:var(--job-wash);border:1px solid currentColor;font-size:12px}
#portfolioProjectTabs .job-stage-bar>button.is-active .job-stage-number{background:var(--job-accent);color:var(--job-surface);border-color:var(--job-accent)}
.job-section-tools{display:flex;flex-wrap:wrap;gap:4px;margin-top:8px}
#portfolioProjectTabs .job-section-tools button{padding:6px 10px;min-height:44px;border:0;border-radius:8px;background:transparent;color:var(--job-muted);font:inherit;font-size:12px;cursor:pointer}
#portfolioProjectTabs .job-section-tools button.is-active{background:var(--job-wash);color:var(--job-accent)}
#portfolioProjectTabs .job-section-status{display:none}
.job-workspace .portfolio-btn--primary,.job-share-dialog .work-review-primary{background:var(--job-accent);border-color:var(--job-accent);color:var(--job-surface)}
.job-workspace :focus-visible,.job-composer :focus-visible,.job-share-dialog :focus-visible{outline:2px solid var(--job-accent);outline-offset:3px}
/* New job: the draft stays mounted while choosing or creating a site. */
.job-composer .ops-layout{max-width:760px;gap:var(--job-gap)}
.job-composer .ops-card{padding:18px;border-radius:var(--job-radius);background:var(--job-surface)}
.job-composer .ops-card h2{font-size:14px;margin:0 0 10px}
.job-composer .ops-job-fields{display:flex;flex-direction:column;gap:var(--job-gap);margin:0;padding:0;border:0;min-width:0}
.job-composer .ops-title-field{margin:0}
.job-composer .ops-title-field input{font-size:24px!important}
.job-composer .job-flow-presets{margin-bottom:8px}
.job-composer .job-flow-presets button{flex:1;justify-content:center;min-height:48px;background:var(--job-surface);color:var(--job-ink)}
.job-composer .job-flow-presets button[aria-pressed=true]{background:var(--job-wash);border-color:var(--job-accent);color:var(--job-accent)}
.job-composer .job-flow-presets button[data-job-preset=custom]{flex:0 0 auto}
.job-preparation-note{display:flex;align-items:center;gap:8px;color:var(--job-preparation);font-size:12px}
.job-create-modes{display:flex;gap:6px;margin-bottom:16px}
.job-create-modes button{min-height:44px;padding:8px 16px;border:1px solid var(--job-line);border-radius:9px;background:var(--job-surface);color:var(--job-muted);font:inherit;cursor:pointer}
.job-create-modes button[aria-pressed=true]{background:var(--job-wash);border-color:var(--job-accent);color:var(--job-accent)}
.job-composer .job-flow-tile small{display:none}
.job-composer .job-flow-tile{min-height:84px;background:var(--job-surface)}
.job-composer .job-flow-tile.is-selected{background:var(--job-wash);border-color:var(--job-accent);color:var(--job-accent)}
.job-composer .job-flow-check{color:var(--job-accent)}
.job-composer [data-job-selected-summary]{display:none}
.job-composer [data-job-property-preview]>details{margin:0}
.job-delivery-share{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:18px;margin-bottom:16px;border:1px solid var(--job-delivery);border-radius:var(--job-radius);background:var(--job-delivery-wash)}
.job-delivery-share>div{display:grid;gap:5px;min-width:0}
.job-delivery-share strong{font-size:16px}
.job-delivery-share small{color:var(--job-muted)}
.job-delivery-share button{flex:none;min-height:44px}
.job-share-kind{display:flex;flex-wrap:wrap;gap:8px;margin-bottom:12px}
.job-share-kind button[aria-pressed=true]{background:var(--job-wash);border-color:var(--job-accent);color:var(--job-accent)}
.job-share-consequence{font-size:12px;color:var(--job-muted);margin:8px 0}
.job-share-dialog [data-preview-host]{border:1px solid var(--job-line);border-radius:var(--job-radius)}
.job-share-dialog [data-preview-host]::before{content:'Customer preview';display:block;padding:12px;font-weight:650;color:var(--job-accent)}
.job-workspace [hidden],.job-composer [hidden],.job-share-dialog [hidden]{display:none!important}
@media(max-width:600px){
  #portfolioProjectTabs.job-stage-navigation{padding-block:8px}
  .job-stage-bar{gap:4px}
  #portfolioProjectTabs .job-stage-bar>button{flex-direction:column;gap:2px;padding:4px 2px;font-size:11px;border-radius:10px;min-height:62px}
  .job-stage-labels{width:100%}
  .job-stage-hint{display:none}
  .job-section-tools{gap:0;margin-top:4px}
  #portfolioProjectTabs .job-section-tools button{padding:5px 8px}
  .job-composer .ops-card{padding:14px}
  .job-composer .job-flow-presets button{font-size:12px;padding:8px}
  .job-delivery-share{padding:14px;gap:8px;flex-wrap:wrap}
}
/* Keep Cancel above the result popover, even while a search is pending. */
.job-composer [data-existing-job-site]>label{display:flex;align-items:center;min-height:36px;padding-right:70px}
.job-composer [data-job-cancel-site]{position:absolute;right:0;top:-4px;min-height:44px}
.job-composer .portfolio-search-results{top:100%}
.job-share-dialog .agv3-detail-dialog__footer .job-share-consequence{flex:1 1 100%}
.job-share-dialog .agv3-detail-dialog__footer [data-status]:empty{display:none}

.job-share-dialog .agv3-detail-dialog__footer{flex-wrap:wrap}
.work-share-dialog.job-share-dialog .agv3-detail-dialog__footer .work-review-primary{background:var(--job-accent);border-color:var(--job-accent)}
#portfolioProjectTabs .job-stage-bar>button:disabled{opacity:.55;cursor:default}
@media(max-width:600px){.job-composer .ag-field-help>summary{width:44px;min-height:44px}}
