/* Shift workspace: date selection and readable, source-job based crew cards. */
.shift-workspace { --shift-border: #e5e4ef; --shift-muted: #68677c; }
.shift-workspace .panel { padding: 24px; border: 1px solid var(--shift-border); border-radius: 18px; box-shadow: 0 3px 14px #241d5805; }
.shift-workspace .panel-title { margin: 0; font-size: 19px; line-height: 1.5; }
.shift-workspace .panel-subtitle { margin: 5px 0 0; font-size: 14px; line-height: 1.6; }
.shift-workspace .btn { min-height: 40px; white-space: normal; box-shadow: none; }
.shift-workspace .btn:hover { transform: none; }
.shift-workspace .btn:focus-visible,
.shift-workspace button:focus-visible,
.shift-workspace summary:focus-visible { outline: 3px solid #7567df; outline-offset: 3px; }
.shift-workspace .shift-sync { padding: 16px 24px; }
.shift-sync-bar { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 20px; }
.shift-sync .panel-title { display: flex; align-items: center; gap: 8px; font-size: 15px; }
.shift-sync .panel-title svg { width: 18px; height: 18px; color: #13877e; }
.shift-sync-status { margin: 4px 0 0; color: var(--shift-muted); font-size: 12px; }
.shift-sync-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.shift-sync-actions .btn { font-size: 13px; padding: 8px 12px; border-radius: 9px; background: #fff; }
.shift-sync-help { margin-top: 10px; color: var(--shift-muted); font-size: 12px; }
.shift-sync-help summary { width: fit-content; cursor: pointer; padding: 4px 0; }
.shift-sync-help p { max-width: 80ch; line-height: 1.7; }
.shift-schedule-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.shift-view-switch { display: inline-flex; flex: 0 0 auto; gap: 3px; padding: 4px; border: 1px solid var(--shift-border); border-radius: 11px; background: #f5f5fa; }
.shift-view-switch button { min-width: 64px; min-height: 36px; padding: 6px 12px; border: 0; border-radius: 7px; color: #68677c; background: transparent; font-size: 14px; font-weight: 700; cursor: pointer; }
.shift-view-switch button[aria-pressed="true"] { color: #4d40c4; background: #fff; box-shadow: 0 1px 4px #33278015; }
.shift-schedule-filters { display: grid; grid-template-columns: repeat(2, minmax(0, 240px)); gap: 12px; margin: 20px 0 16px; }
.shift-schedule-filters .field { min-width: 0; }
.shift-schedule-filters .field label { font-size: 12px; color: var(--shift-muted); }
.shift-schedule-filters input,
.shift-schedule-filters select { width: 100%; min-width: 0; min-height: 44px; padding: 9px 12px; border: 1px solid #dcdbe8; border-radius: 9px; background: #fff; font-size: 15px; }
.shift-date-picker { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; padding-bottom: 20px; }
.shift-date-button { display: grid; justify-items: center; gap: 3px; min-width: 0; padding: 9px 3px; border: 1px solid var(--shift-border); border-radius: 10px; background: #fff; color: #292644; line-height: 1.3; cursor: pointer; }
.shift-date-button:hover { border-color: #aaa0e9; background: #f8f7ff; }
.shift-date-weekday { color: var(--shift-muted); font-size: 12px; }
.shift-date-button strong { font-size: 17px; font-weight: 750; font-variant-numeric: tabular-nums; }
.shift-date-count { color: var(--shift-muted); font-size: 11px; }
.shift-date-button.is-today { border-color: #159487; }
.shift-date-button.is-today .shift-date-weekday { color: #08786d; font-weight: 700; }
.shift-date-button[aria-pressed="true"] { border-color: #5d4bdd; background: #5d4bdd; color: #fff; box-shadow: 0 3px 9px #5d4bdd20; }
.shift-date-button[aria-pressed="true"] .shift-date-weekday,
.shift-date-button[aria-pressed="true"] .shift-date-count { color: #fff; }
.shift-schedule-results { min-width: 0; }
.shift-day { min-width: 0; padding-top: 20px; border-top: 1px solid var(--shift-border); }
.shift-day + .shift-day { margin-top: 28px; }
.shift-day-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.shift-day-heading h3 { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0; font-size: 20px; line-height: 1.4; }
.shift-day-heading > span { color: var(--shift-muted); font-size: 13px; }
.shift-today-label { padding: 3px 8px; border-radius: 5px; background: #e4f6f1; color: #097768; font-size: 12px; font-weight: 600; }
.shift-day.is-empty .shift-day-heading { margin-bottom: 0; }
.shift-day-empty { margin: 16px 0 0; padding: 24px 16px; border-radius: 12px; background: #f7f7fb; color: var(--shift-muted); text-align: center; font-size: 14px; line-height: 1.7; }
.shift-job-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 14px; align-items: start; }
.shift-job { min-width: 0; padding: 18px; border: 1px solid var(--shift-border); border-top: 3px solid #168e84; border-radius: 12px; background: #fff; overflow-wrap: anywhere; }
.shift-job.is-night { border-top-color: #7360cc; }
.shift-job-topline { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-bottom: 9px; }
.shift-job-source { color: var(--shift-muted); font-size: 11px; }
.shift-job-tags { display: flex; flex-wrap: wrap; gap: 5px; }
.shift-job-tag { display: inline-block; max-width: 100%; padding: 3px 8px; border-radius: 5px; font-size: 11px; font-weight: 700; line-height: 1.5; }
.shift-job-tag.is-confirmed { color: #087367; background: #e6f6f0; }
.shift-job-tag.is-pending { color: #835809; background: #fff3d5; }
.shift-job-tag.is-night { color: #594495; background: #f0ebff; }
.shift-job-title { margin: 0 0 12px; color: #282342; font-size: 18px; font-weight: 750; line-height: 1.55; }
.shift-job-time,
.shift-job-meeting { display: flex; align-items: flex-start; gap: 8px; margin: 7px 0; font-size: 14px; line-height: 1.6; }
.shift-job-time svg,
.shift-job-meeting svg { flex: 0 0 17px; width: 17px; height: 17px; margin-top: 3px; color: #7c7792; }
.shift-job-time strong { font-weight: 650; font-variant-numeric: tabular-nums; }
.shift-job-meeting { color: #4f4c62; }
.shift-job-address { margin: 6px 0 0 25px; color: var(--shift-muted); font-size: 12px; line-height: 1.6; }
.shift-job-crew { margin-top: 15px; padding-top: 12px; border-top: 1px solid #eeedf4; }
.shift-crew-label { margin: 0 0 8px; color: var(--shift-muted); font-size: 11px; }
.shift-job-crew ul { display: flex; flex-wrap: wrap; gap: 7px; margin: 0; padding: 0; list-style: none; }
.shift-job-crew li { min-width: 0; max-width: 100%; }
.shift-crew-person { display: inline-flex; flex-wrap: wrap; align-items: baseline; gap: 6px; max-width: 100%; padding: 6px 9px; border-radius: 6px; background: #f5f5fa; line-height: 1.5; }
.shift-crew-person strong { font-size: 13px; font-weight: 650; }
.shift-crew-person > span { color: var(--shift-muted); font-size: 11px; }
.shift-crew-note { display: block; max-width: 32ch; margin-top: 4px; color: #85560a; font-size: 12px; }
.shift-job-note,
.shift-job-warning { margin: 12px 0 0; padding: 9px 11px; border-radius: 7px; font-size: 12px; line-height: 1.65; background: #fff8e8; color: #79530c; white-space: pre-line; }
.shift-job > .btn { margin-top: 12px; }
@media (min-width: 821px) {
  .shift-shell > .main > .topbar { padding-block: 12px; }
  .shift-shell .topbar-context,
  .shift-shell .topbar-sub { display: none; }
}
@media (max-width: 820px) {
  .shift-workspace .panel { padding: 16px; border-radius: 14px; }
  .shift-workspace .shift-sync { padding: 14px 16px; }
  .shift-sync-bar { align-items: flex-start; gap: 10px; }
  .shift-sync-actions { width: 100%; }
  .shift-sync-actions .btn { flex: 1 1 auto; }
  .shift-schedule-heading { align-items: flex-start; }
  .shift-schedule-heading > div:first-child { flex: 1 1 160px; }
  .shift-schedule-filters { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .shift-schedule-filters input,
  .shift-schedule-filters select { padding-inline: 8px; font-size: 16px; }
  .shift-date-picker { gap: 4px; padding-bottom: 16px; }
  .shift-date-button { padding: 8px 1px; border-radius: 7px; }
  .shift-date-button strong { font-size: 14px; }
  .shift-date-weekday { font-size: 11px; }
  .shift-date-count { font-size: 10px; }
  .shift-day-heading h3 { font-size: 18px; }
  .shift-job { padding: 15px; }
  .shift-job-grid { grid-template-columns: minmax(0, 1fr); }
  .shift-job-title { font-size: 17px; }
}
@media print {
  .shift-date-picker,
  .shift-view-switch,
  .shift-sync-actions,
  .shift-sync-help { display: none; }
  .shift-job { break-inside: avoid; }
}
