
/* Renderer-owned Jobs side view v2. Existing tabs remain unchanged. */
.jsv-layout{display:block}
.jsv-panel{display:none}
#jobs-section.jsv-active .jsv-layout{
 display:grid;grid-template-columns:minmax(250px,.8fr) minmax(390px,1.2fr);
 gap:18px;align-items:start}
#jobs-section.jsv-active .jsv-layout>*{min-width:0}
#jobs-section.jsv-active .jobs-list.jobs-grid .agency-jobs-date-grid{
 display:flex;flex-direction:column;gap:11px}
#jobs-section.jsv-active .jobs-list.jobs-grid .agency-jobs-date-grid .jsv-unit{
 display:block;width:100%;height:auto;min-width:0;
 margin:0;padding:16px;text-align:left;font:inherit;
 background:var(--bg-card);color:var(--text);
 border:1px solid var(--border);border-radius:11px;box-shadow:none}
#jobs-section.jsv-active .jsv-unit[hidden]{display:none!important}
#jobs-section.jsv-active .jsv-unit[aria-pressed=true]{
 outline:2px solid var(--blue);outline-offset:1px}
#jobs-section.jsv-active .jobs-list.jobs-grid .agency-jobs-date-grid .jsv-unit.jsv-unread{
 border-color:var(--amber);
 box-shadow:inset 3px 0 var(--amber),0 0 0 2px var(--amber-light)}
.jsv-summary-top{display:flex;justify-content:space-between;
 align-items:flex-start;gap:10px;flex-wrap:wrap}
.jsv-summary-heading{display:flex;flex-direction:column;gap:5px;min-width:0}
.jsv-summary-heading small{font-size:10px;color:var(--text-muted)}
.jsv-summary-heading strong{font-size:14px;line-height:1.5;overflow-wrap:anywhere}
#jobs-section .jsv-status{flex:none;margin:0;font-size:10px}
.jsv-summary-roles{display:block;margin-top:10px;font-size:11px;
 line-height:1.65;overflow-wrap:anywhere}
.jsv-summary-meta{display:block;margin-top:8px;font-size:11px;
 line-height:1.65;color:var(--text-muted);overflow-wrap:anywhere}
.jsv-unread-label{display:block;margin-top:10px;font-size:11px;
 line-height:1.6;color:var(--amber-dim);overflow-wrap:anywhere}
.jsv-view{display:block;margin-top:12px;font-size:10px;
 font-weight:700;color:var(--blue)}
#jobs-section.jsv-active .jsv-panel{
 display:block;position:sticky;top:70px;max-height:calc(100dvh - 90px);
 overflow:auto;overscroll-behavior:contain;background:var(--bg-card);
 border:1px solid var(--border);border-radius:12px;box-shadow:var(--shadow-sm)}
#jobs-section .jsv-panel[hidden]{display:none!important}
.jsv-panel-head{position:sticky;top:0;z-index:3;display:flex;
 align-items:center;justify-content:space-between;gap:12px;
 padding:14px 16px;background:var(--bg-card);border-bottom:1px solid var(--border)}
.jsv-panel-title{font-size:12px;line-height:1.6;overflow-wrap:anywhere}
.jsv-close{flex:none;width:38px;height:38px;border:1px solid var(--border);
 border-radius:8px;background:var(--bg-card);color:var(--text-muted);
 font:inherit;font-size:21px}
.jsv-panel-body{padding:14px}
.jsv-empty{margin:22px 8px;font-size:12px;line-height:1.8;
 color:var(--text-muted);text-align:center}
.jsv-roles{display:flex;flex-wrap:wrap;gap:6px;padding:12px 14px 0}
.jsv-roles:empty{display:none}
.jsv-role-help{flex-basis:100%;margin:0 0 5px;font-size:10px;
 line-height:1.6;color:var(--text-muted)}
.jsv-role-button{min-height:36px;padding:7px 9px;font:inherit;font-size:10px;
 border:1px solid var(--border);border-radius:7px;
 background:var(--bg);color:var(--text-muted)}
.jsv-role-button[aria-pressed=true]{background:var(--navy);color:#fff}
#jobs-section .jsv-panel .job-card{height:auto;margin:0 0 12px;box-shadow:none}
#jobs-section .jsv-panel details.booking-group{
 margin:0;border:0;box-shadow:none;overflow:visible}
#jobs-section .jsv-panel .booking-group-summary{display:none}
#jobs-section .jsv-panel .booking-group-body{
 padding:0;border:0;background:transparent}
#jobs-section .jsv-panel .booking-group-role-count{line-height:1.6}
#jobs-section .jsv-panel .jc-meta,
#jobs-section .jsv-panel .jc-meta-finish-pair,
#jobs-section .jsv-panel .jc-meta-rate-pair{grid-template-columns:1fr}
#jobs-section .jsv-panel .jc-actions{flex-wrap:wrap}
#jobs-section .jsv-panel .jsv-role-hidden{display:none!important}
#jobs-section .jsv-unit:focus-visible,.jsv-close:focus-visible,
.jsv-role-button:focus-visible{
 outline:3px solid var(--blue);outline-offset:2px}
@media(max-width:900px){
 #jobs-section.jsv-active .jsv-layout{display:block}
 #jobs-section.jsv-active .jsv-panel{display:none}
 #jobs-section.jsv-active .jsv-panel.jsv-panel-open{
  display:block;position:fixed;inset:70px 12px 82px;z-index:700;
  max-height:none;box-shadow:var(--shadow-lg)}
 .jsv-close,.jsv-role-button{min-height:44px}
}
@media(prefers-reduced-motion:reduce){
 .jsv-panel,.jsv-unit{transition:none!important}
}


/* Unread booking amber pulse v1 */
@keyframes crewfill-jsv-unread-pulse {
  0%, 100% {
    box-shadow:
      inset 3px 0 var(--amber),
      0 0 0 2px var(--amber-light);
  }
  50% {
    box-shadow:
      inset 5px 0 var(--amber),
      0 0 0 4px rgba(245, 166, 35, 0.55),
      0 0 22px 5px rgba(245, 166, 35, 0.45);
  }
}
#jobs-section.jsv-active .jobs-list.jobs-grid .agency-jobs-date-grid .jsv-unit.jsv-unread {
  animation: crewfill-jsv-unread-pulse 2.4s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) {
  #jobs-section.jsv-active .jobs-list.jobs-grid .agency-jobs-date-grid .jsv-unit.jsv-unread {
    animation: none !important;
  }
}


/* Clear sections role-card presentation v1 */
#jobs-section.jsv-active #jsv-panel .jsv-tidied {
  padding:18px;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidied .jc-top {
  flex-wrap:wrap;
  gap:12px;
  margin-bottom:0;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidied .jc-role {
  font-size:18px;
  font-weight:800;
  line-height:1.35;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-quantity {
  margin-top:5px;
  font-size:12px;
  color:var(--text-muted);
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-section {
  padding:18px 0;
  border-bottom:1px solid var(--border);
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-label {
  margin:0 0 10px;
  color:var(--text-muted);
  font-size:11px;
  font-weight:700;
  letter-spacing:0.06em;
  text-transform:uppercase;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-context {
  margin:0 0 8px;
  color:var(--text-muted);
  font-size:12px;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-date {
  display:flex;
  justify-content:space-between;
  flex-wrap:wrap;
  gap:6px 14px;
  padding:10px 0;
  font-size:12px;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-time {
  font-weight:800;
  font-variant-numeric:tabular-nums;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-rates {
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:16px;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-rates .jc-meta-item {
  display:block;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-rate-label {
  display:block;
  margin-bottom:5px;
  color:var(--text-muted);
  font-size:12px;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-rate-value {
  display:block;
  color:var(--text);
  font-size:18px;
  font-weight:800;
  overflow-wrap:anywhere;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-disclosure {
  border-bottom:1px solid var(--border);
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-disclosure > summary {
  padding:14px 0;
  color:var(--text);
  font-size:12px;
  font-weight:700;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-disclosure-body {
  padding:0 0 14px;
  color:var(--text-muted);
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-disclosure-body .jc-meta {
  display:block;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-disclosure-body .jc-meta > * {
  margin-top:7px;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidied .jc-actions {
  flex-wrap:wrap;
}
@media (max-width:480px) {
  #jobs-section.jsv-active #jsv-panel .jsv-tidy-rates {
    grid-template-columns:1fr;
    gap:14px;
  }
  #jobs-section.jsv-active #jsv-panel .jsv-tidy-disclosure > summary {
    min-height:44px;
  }
}


/* Right-panel spacing, rate margin and scroll handoff v1 */
#jobs-section.jsv-active #jsv-panel .jsv-tidy-date {
  display:grid;
  grid-template-columns:minmax(0,max-content) minmax(0,1fr);
  justify-content:start;
  align-items:baseline;
  column-gap:16px;
  row-gap:3px;
}
#jobs-section.jsv-active #jsv-panel .jsv-tidy-time {
  text-align:left;
  overflow-wrap:anywhere;
}
#jobs-section.jsv-active #jsv-panel .jsv-rate-margin {
  margin-top:14px;
  padding-top:12px;
  border-top:1px solid var(--border);
}
#jobs-section.jsv-active #jsv-panel .jsv-rate-margin-value {
  display:block;
  margin:4px 0;
  color:var(--text);
  font-size:14px;
  font-weight:800;
}
#jobs-section.jsv-active #jsv-panel .jsv-rate-margin small {
  display:block;
  color:var(--text-muted);
  font-size:11px;
}
#jobs-section.jsv-active #jsv-panel .jsv-rate-margin-negative .jsv-rate-margin-value {
  color:var(--red);
}
@media (min-width:901px) {
  #jobs-section.jsv-active #jsv-panel {
    overscroll-behavior-y:auto;
  }
}
@media (max-width:480px) {
  #jobs-section.jsv-active #jsv-panel .jsv-tidy-date {
    grid-template-columns:minmax(0,1fr);
  }
}


/* Pinned Jobs heading, tabs and filters v1 */
@media (min-width:901px) and (min-height:700px) {
  #jobs-section .jsv-pinned-toolbar {
    display:flow-root;
    position:sticky;
    top:var(--jsv-toolbar-top,56px);
    z-index:35;
    background:var(--bg);
    padding-top:8px;
    padding-bottom:1px;
    border-bottom:1px solid var(--border);
    margin-bottom:14px;
  }
  #jobs-section.jsv-active #jsv-panel {
    top:calc(
      var(--jsv-toolbar-top,56px) +
      var(--jsv-toolbar-height,280px) + 10px
    );
    max-height:calc(
      100dvh -
      var(--jsv-toolbar-top,56px) -
      var(--jsv-toolbar-height,280px) - 24px
    );
  }
  #jobs-section .jsv-unit {
    scroll-margin-top:calc(
      var(--jsv-toolbar-top,56px) +
      var(--jsv-toolbar-height,280px) + 12px
    );
  }
}


/* Slim Jobs controls and booking pills v1 */
#jobs-section .jsv-unit .jsv-pills {
  display:flex;
  flex-wrap:wrap;
  gap:5px;
  margin:10px 0 4px;
}
#jobs-section .jsv-unit .jsv-pill {
  display:inline-block;
  padding:3px 7px;
  border-radius:999px;
  font-size:10px;
  font-weight:700;
  line-height:1.4;
  background:var(--bg);
  color:var(--text-muted);
}
#jobs-section .jsv-unit .jsv-pill-role {
  background:var(--purple-light);
  color:var(--purple);
}
#jobs-section .jsv-unit .jsv-pill-day {
  background:var(--blue-light);
  color:var(--blue);
}
#jobs-section .jsv-unit .jsv-pill-direct {
  background:var(--green-light);
  color:var(--green);
}
@media (min-width:901px) and (min-height:700px) {
  #jobs-section .jsv-pinned-toolbar {
    display:grid;
    grid-template-columns:minmax(0,1fr);
    gap:8px;
    padding:10px 0;
  }
  #jobs-section .jsv-pinned-toolbar .agency-jobs-scope-tabs {
    margin:0;
    gap:6px;
  }
  #jobs-section .jsv-pinned-toolbar .agency-jobs-scope-tab {
    min-height:38px;
    padding:7px 9px;
    gap:6px;
    border-radius:7px;
    box-shadow:none;
    font-size:11px;
  }
  #jobs-section .jsv-pinned-toolbar .agency-jobs-scope-tab strong {
    min-width:22px;
    height:20px;
    padding:0 5px;
    font-size:10px;
  }
  #jobs-section .jsv-pinned-toolbar .agency-jobs-toolbar {
    grid-template-columns:minmax(0,1fr) 148px auto;
    align-items:center;
    gap:8px;
    margin:0;
    padding:0;
    border:0;
    border-radius:0;
    box-shadow:none;
    background:transparent;
  }
  #jobs-section .jsv-pinned-toolbar .agency-jobs-toolbar label {
    position:relative;
    min-width:0;
  }
  #jobs-section .jsv-pinned-toolbar .agency-jobs-toolbar label > span {
    position:absolute;
    width:1px;
    height:1px;
    padding:0;
    margin:-1px;
    overflow:hidden;
    clip:rect(0,0,0,0);
    white-space:nowrap;
    border:0;
  }
  #jobs-section .jsv-pinned-toolbar .agency-jobs-search .search-bar,
  #jobs-section .jsv-pinned-toolbar .agency-jobs-status-filter select {
    height:36px;
  }
  #jobs-section .jsv-pinned-toolbar .job-view-btn {
    min-height:36px;
  }
}
@media (min-width:1600px) and (min-height:700px) {
  #jobs-section .jsv-pinned-toolbar {
    grid-template-columns:minmax(0,1.1fr) minmax(480px,1fr);
    align-items:center;
    gap:12px;
  }
}

/* Keep booking details visible during refresh v1 */
#jobs-section.jsv-active #jsv-panel .jsv-panel-head {
  flex-wrap:wrap;
}
#jobs-section.jsv-active #jsv-panel .jsv-refresh-status {
  flex-basis:100%;
  color:var(--text-muted);
  font-size:11px;
  font-weight:600;
  line-height:1.5;
}
#jobs-section.jsv-active #jsv-panel .jsv-refresh-elapsed {
  font-variant-numeric:tabular-nums;
}
#jobs-section.jsv-active #jsv-panel .jsv-refresh-error {
  color:var(--red);
}
#jobs-section.jsv-active #jsv-panel [inert] {
  cursor:progress;
}


/* Clean rows inside existing information disclosures v1 */
#jobs-section.jsv-active #jsv-panel .jsv-clean-rows,
#jobs-section.jsv-active #jsv-panel .jsv-clean-total {
  margin:0;
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-row {
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(0,1fr);
  align-items:baseline;
  gap:12px 20px;
  padding:11px 0;
  border-bottom:1px solid var(--border);
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-row:last-child {
  border-bottom:0;
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-row dt {
  color:var(--text-muted);
  font-size:12px;
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-row dd {
  margin:0;
  color:var(--text);
  font-size:12px;
  font-weight:700;
  text-align:right;
  overflow-wrap:anywhere;
  font-variant-numeric:tabular-nums;
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-total {
  margin-top:10px;
  padding:0 12px;
  border-radius:8px;
  background:var(--bg);
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-total dd {
  font-size:14px;
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-note {
  margin:10px 0 0;
  color:var(--text-muted);
  font-size:11px;
  line-height:1.6;
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-confirmed dd {
  color:var(--green);
}
#jobs-section.jsv-active #jsv-panel .jsv-clean-information .jc-meta:empty {
  display:none;
}
@media(max-width:420px) {
  #jobs-section.jsv-active #jsv-panel .jsv-clean-row {
    grid-template-columns:minmax(0,1fr);
    gap:4px;
  }
  #jobs-section.jsv-active #jsv-panel .jsv-clean-row dd {
    text-align:left;
  }
}
