/* ==========================================================================
   Payroll Center — Sprint 1
   Timeclock Monitor (default) + Payroll Audit Session wizard
   ========================================================================== */

.payroll-center-page {
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
}

.pc-shell {
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px 24px 64px;
}

.pc-hidden { display: none !important; }

.pc-muted { color: var(--text-muted); }
.pc-error { color: var(--accent-red); }

/* ---------- Generic buttons ---------- */
.pc-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 600;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text-primary);
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, transform 0.05s ease;
  line-height: 1.2;
  white-space: nowrap;
}
.pc-btn:hover:not(:disabled) { background: var(--bg-card-alt); }
.pc-btn:active:not(:disabled) { transform: translateY(1px); }
.pc-btn:disabled { opacity: 0.55; cursor: not-allowed; }

.pc-btn--primary {
  background: var(--accent-green);
  color: #fff;
  border-color: var(--accent-green);
}
.pc-btn--primary:hover:not(:disabled) { background: var(--accent-green-dark, #15803d); }

.pc-btn--ghost {
  background: transparent;
  border-color: var(--border-default);
  color: var(--text-primary);
}

.pc-btn--sm { padding: 4px 10px; font-size: 12px; }

.pc-link-btn {
  background: none;
  border: none;
  color: var(--accent-blue);
  cursor: pointer;
  padding: 4px 6px;
  font-size: 14px;
  font-weight: 500;
}
.pc-link-btn:hover { text-decoration: underline; }

.pc-select,
.pc-input {
  padding: 7px 10px;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  background: var(--bg-card);
  color: var(--text-primary);
  font-size: 14px;
  font-family: inherit;
}
.pc-select:focus,
.pc-input:focus {
  outline: 2px solid var(--accent-blue-light);
  border-color: var(--accent-blue);
}

/* ==========================================================================
   MONITOR VIEW
   ========================================================================== */

.pc-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-default);
  flex-wrap: wrap;
}

.pc-header-left {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pc-back-link {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  margin-bottom: 4px;
}
.pc-back-link:hover { color: var(--accent-blue); }

.pc-title {
  font-size: 28px;
  font-weight: 700;
  margin: 0;
  color: var(--text-primary);
}

.pc-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  margin: 0;
}

.pc-header-right {
  display: flex;
  gap: 12px;
  align-items: flex-end;
  flex-wrap: wrap;
}

.pc-control {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pc-control-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  font-weight: 600;
}

/* --------- Summary pills row --------- */
.pc-summary-row {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 20px 0;
}

.pc-pill {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 20px;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
}

.pc-pill-value {
  font-size: 26px;
  font-weight: 700;
  line-height: 1;
}

.pc-pill-label {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

.pc-pill--clean { border-left: 4px solid #10B981; }
.pc-pill--clean .pc-pill-value { color: #10B981; }
.pc-pill--warn { border-left: 4px solid #F59E0B; }
.pc-pill--warn .pc-pill-value { color: #F59E0B; }
.pc-pill--blocker { border-left: 4px solid #EF4444; }
.pc-pill--blocker .pc-pill-value { color: #EF4444; }
.pc-pill--locked { border-left: 4px solid #3B82F6; }
.pc-pill--locked .pc-pill-value { color: #3B82F6; }

/* --------- Grid card --------- */
.pc-grid-card {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  overflow: hidden;
}

.pc-grid-card-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-default);
}

.pc-grid-title {
  font-size: 16px;
  font-weight: 600;
  margin: 0;
}

.pc-grid-meta {
  font-size: 13px;
  color: var(--text-muted);
}

.pc-grid-scroll { overflow: auto; max-height: 75vh; }

.pc-grid {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.pc-grid-th {
  position: sticky;
  top: 0;
  padding: 10px 12px;
  text-align: left;
  background: var(--bg-card-alt);
  color: var(--text-secondary);
  font-weight: 600;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid var(--border-default);
  white-space: nowrap;
}

.pc-grid-th-date {
  display: inline-block;
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 2px;
}

.pc-grid-th--emp { min-width: 180px; }
.pc-grid-th--dept { min-width: 120px; }
.pc-grid-th--status { min-width: 130px; }

.pc-grid-row { border-bottom: 1px solid var(--border-light); }
.pc-grid-row:hover { background: var(--bg-card-alt); }

.pc-grid-td {
  padding: 10px 12px;
  vertical-align: middle;
}

.pc-grid-td--emp { font-weight: 600; color: var(--text-primary); }
.pc-grid-td--dept { color: var(--text-muted); font-size: 12px; }
.pc-grid-td--status { text-align: right; }

.pc-grid-day {
  padding: 8px 10px;
  vertical-align: middle;
  min-width: 110px;
  border-left: 1px solid var(--border-light);
}

.pc-grid-day-times {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
}

.pc-grid-day-mins {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

.pc-grid-day--clean { background: rgba(16, 185, 129, 0.07); }
.pc-grid-day--needs_review { background: rgba(245, 158, 11, 0.10); }
.pc-grid-day--blocker { background: rgba(239, 68, 68, 0.12); }
.pc-grid-day--locked { background: rgba(59, 130, 246, 0.08); }
.pc-grid-day--empty { color: var(--text-muted); text-align: center; }
.pc-grid-day--no_data { color: var(--text-muted); }

.pc-grid-empty td {
  padding: 28px;
  text-align: center;
  color: var(--text-muted);
  font-style: italic;
}

.pc-grid-empty--error td { color: var(--accent-red); }

/* --------- Status badges (shared) --------- */
.pc-badge {
  display: inline-block;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 600;
  text-transform: none;
  white-space: nowrap;
}
.pc-badge--clean { background: rgba(16, 185, 129, 0.15); color: #059669; }
.pc-badge--warn { background: rgba(245, 158, 11, 0.18); color: #d97706; }
.pc-badge--blocker { background: rgba(239, 68, 68, 0.18); color: #dc2626; }
.pc-badge--locked { background: rgba(59, 130, 246, 0.15); color: #2563eb; }

/* ==========================================================================
   WIZARD
   ========================================================================== */

.pc-wizard-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  margin-bottom: 16px;
}

.pc-wizard-header-left {
  display: flex;
  align-items: center;
  gap: 16px;
}

.pc-wizard-title-group {
  border-left: 2px solid var(--border-default);
  padding-left: 16px;
}

.pc-wizard-title {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}

.pc-wizard-subtitle {
  font-size: 12px;
  color: var(--text-muted);
  margin: 2px 0 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}

/* --------- Phase stepper --------- */
.pc-phase-stepper {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
  justify-content: center;
}

.pc-phase-step {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 500;
}

.pc-phase-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-card-alt);
  color: var(--text-muted);
  font-weight: 700;
  font-size: 13px;
  border: 2px solid var(--border-default);
}

.pc-phase-name { color: var(--text-muted); }

.pc-phase-step.is-current .pc-phase-num {
  background: var(--accent-green);
  color: #fff;
  border-color: var(--accent-green);
}
.pc-phase-step.is-current .pc-phase-name {
  color: var(--text-primary);
  font-weight: 600;
}

.pc-phase-step.is-complete .pc-phase-num {
  background: #10B981;
  color: #fff;
  border-color: #10B981;
}
.pc-phase-step.is-complete .pc-phase-num::before {
  content: "✓";
  font-size: 14px;
}
.pc-phase-step.is-complete .pc-phase-num > * { display: none; }

.pc-phase-step.is-future .pc-phase-num { opacity: 0.6; }

.pc-phase-sep {
  flex: 0 0 40px;
  height: 2px;
  background: var(--border-default);
  border-radius: 1px;
}

.pc-phase {
  margin-bottom: 24px;
}

.pc-phase-slot { display: block; }

.pc-phase-footer {
  margin-top: 16px;
  padding: 16px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.pc-phase-footer-actions { display: flex; gap: 8px; }

/* --------- Card primitives --------- */
.pc-card {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  padding: 24px;
  max-width: 680px;
  margin: 24px auto;
}

.pc-card-title { font-size: 20px; font-weight: 700; margin: 0 0 4px; }
.pc-card-subtitle { color: var(--text-muted); margin: 0 0 16px; font-size: 14px; }

.pc-form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  margin: 20px 0;
}

.pc-form-label {
  display: flex;
  flex-direction: column;
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
  gap: 4px;
}
.pc-form-label .pc-input,
.pc-form-label .pc-select {
  margin-top: 2px;
  font-weight: 400;
  color: var(--text-primary);
}

.pc-card-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
  flex-wrap: wrap;
}

/* --------- Health card --------- */
.pc-health-slot { margin-top: 20px; }

.pc-health-card {
  background: var(--bg-card-alt);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 20px;
}
.pc-health-title { font-size: 16px; margin: 0 0 12px; }
.pc-health-list {
  list-style: none;
  padding: 0;
  margin: 0 0 12px;
  display: grid;
  gap: 8px;
}
.pc-health-meta { color: var(--text-muted); font-size: 13px; margin: 8px 0 16px; }

.pc-resume-phase {
  display: inline-block;
  padding: 4px 10px;
  background: var(--accent-blue-light);
  color: var(--accent-blue);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  margin: 8px 0 16px;
}

/* ==========================================================================
   PHASE 2 — Triage
   ========================================================================== */

.pc-triage-layout {
  display: grid;
  grid-template-columns: 35% 65%;
  gap: 16px;
  min-height: 520px;
  height: calc(100vh - 320px);
}

.pc-triage-queue {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.pc-triage-queue-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-default);
  background: var(--bg-card-alt);
}

.pc-triage-queue-title {
  font-size: 14px;
  font-weight: 600;
  margin: 0;
}

.pc-triage-queue-count {
  font-size: 12px;
  color: var(--text-muted);
}

.pc-triage-queue-list {
  flex: 1;
  overflow-y: auto;
}

.pc-triage-queue-empty {
  padding: 32px 16px;
  text-align: center;
  color: var(--text-muted);
  font-style: italic;
  font-size: 13px;
}

.pc-triage-item {
  display: block;
  width: 100%;
  text-align: left;
  padding: 12px 16px;
  border: none;
  border-bottom: 1px solid var(--border-light);
  border-left: 3px solid transparent;
  background: var(--bg-card);
  cursor: pointer;
  font-family: inherit;
  transition: background 0.1s ease;
}
.pc-triage-item:hover { background: var(--bg-card-alt); }
.pc-triage-item.is-active {
  background: var(--accent-blue-light);
  border-left-color: var(--accent-blue);
}

.pc-triage-item--critical { border-left-color: #EF4444; }
.pc-triage-item--warn { border-left-color: #F59E0B; }

.pc-triage-item-head {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 13px;
  font-weight: 600;
}

.pc-triage-item-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
}

/* --------- Right panel detail --------- */
.pc-triage-detail {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 20px;
  min-height: 520px;
}

.pc-triage-empty-state {
  padding: 64px 20px;
  text-align: center;
  color: var(--text-muted);
  font-style: italic;
}

.pc-triage-detail-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  gap: 12px;
}

.pc-triage-detail-title {
  font-size: 18px;
  margin: 0;
}

.pc-triage-detail-sub {
  font-size: 13px;
  color: var(--text-muted);
  margin: 4px 0 0;
}

.pc-triage-detail-nav { display: flex; gap: 8px; }

.pc-evidence {
  background: var(--bg-card-alt);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin: 16px 0;
}

.pc-evidence-row {
  display: flex;
  justify-content: space-between;
  padding: 6px 0;
  border-bottom: 1px dashed var(--border-light);
  font-size: 13px;
}
.pc-evidence-row:last-child { border-bottom: none; }
.pc-evidence-row span { color: var(--text-muted); }
.pc-evidence-row strong { font-weight: 600; }
.pc-evidence-row--inferred { background: rgba(245, 158, 11, 0.10); border-radius: var(--radius-sm); padding: 6px 8px; margin: 4px -8px; }

.pc-resolution { margin-top: 20px; }
.pc-resolution-title { font-size: 14px; font-weight: 600; margin: 0 0 10px; color: var(--text-secondary); text-transform: uppercase; letter-spacing: 0.04em; }

.pc-resolution-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pc-radio {
  display: flex;
  flex-direction: column;
  padding: 10px 12px;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: 13px;
  gap: 6px;
}
.pc-radio:has(input:checked) {
  border-color: var(--accent-blue);
  background: var(--accent-blue-light);
}
.pc-radio > span { font-weight: 500; }

.pc-manual-fields {
  display: none;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.pc-manual-fields label {
  display: flex;
  flex-direction: column;
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 600;
  gap: 3px;
}
.pc-radio:has(input[value="manual"]:checked) .pc-manual-fields { display: grid; }

.pc-triage-detail-actions {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.pc-gate-banner {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #92400e;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 500;
  flex: 1;
}

/* ==========================================================================
   PHASE 3 — Lock (all-employees summary table)
   ========================================================================== */

.pc-lock-global-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  margin-bottom: 16px;
  border-radius: var(--radius-lg);
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.08), rgba(59, 130, 246, 0.06));
  border: 1px solid rgba(16, 185, 129, 0.3);
  font-size: 14px;
}

.pc-lock-global-bar--done {
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.14), rgba(16, 185, 129, 0.06));
  border-color: rgba(16, 185, 129, 0.5);
  color: #059669;
  font-weight: 600;
}

.pc-lock-emp-row { cursor: pointer; }
.pc-lock-emp-row:hover { background: var(--bg-card-alt); }
.pc-lock-emp-row.is-expanded { background: rgba(59, 130, 246, 0.06); }
.pc-lock-emp-row--done { opacity: 0.7; }
.pc-lock-emp-row--done:hover { opacity: 1; }

.pc-lock-td-hours {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.pc-lock-td-num {
  font-variant-numeric: tabular-nums;
  color: var(--text-muted);
}
.pc-lock-td-num--alert { color: #dc2626 !important; font-weight: 600; }

.pc-lock-flag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: var(--radius-sm);
  margin-left: 4px;
  vertical-align: middle;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}
.pc-lock-flag--ot { background: rgba(245, 158, 11, 0.18); color: #d97706; }
.pc-lock-flag--xco { background: rgba(99, 102, 241, 0.14); color: #6366f1; }
.pc-lock-flag--high { background: rgba(239, 68, 68, 0.14); color: #dc2626; }

.pc-lock-chevron {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 10px;
  transition: transform 0.15s ease, background 0.1s ease;
  vertical-align: middle;
  margin-left: 6px;
}
.pc-lock-chevron:hover { background: var(--bg-card-alt); color: var(--text-primary); }
.pc-lock-chevron.is-open { background: var(--accent-blue-light); color: var(--accent-blue); }

.pc-lock-detail-row td { background: var(--bg-card-alt); }

.pc-lock-detail-inner { padding: 8px 0; }

.pc-lock-detail-days {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 4px 12px 12px;
}

.pc-lock-day {
  display: grid;
  grid-template-columns: 110px 1fr auto 140px;
  gap: 12px;
  align-items: center;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  font-size: 13px;
  border: 1px solid var(--border-light);
  background: var(--bg-card);
}

.pc-lock-day--locked { border-left: 3px solid #3B82F6; background: rgba(59, 130, 246, 0.05); }
.pc-lock-day--reviewed { border-left: 3px solid #10B981; background: rgba(16, 185, 129, 0.05); }
.pc-lock-day--open { border-left: 3px solid #F59E0B; background: rgba(245, 158, 11, 0.05); }

.pc-lock-day-date { font-weight: 600; }
.pc-lock-day-info { color: var(--text-secondary); display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.pc-lock-day-times { font-size: 12px; color: var(--text-muted); }
.pc-lock-day-badge { font-size: 11px; color: var(--text-muted); }
.pc-lock-day-status { font-size: 12px; color: var(--text-muted); text-align: right; }
.pc-lock-day-action { text-align: right; }

/* --------- Progress bar --------- */
.pc-progress-block {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 240px;
}

.pc-progress-bar {
  width: 100%;
  height: 8px;
  background: var(--bg-card-alt);
  border-radius: 4px;
  overflow: hidden;
}

.pc-progress-fill {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #10B981, #3B82F6);
  transition: width 0.3s ease;
}

.pc-progress-label {
  font-size: 12px;
  color: var(--text-muted);
  margin: 0;
}

/* ==========================================================================
   DONE card
   ========================================================================== */

.pc-done-card {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 48px 32px;
  max-width: 560px;
  margin: 32px auto;
  text-align: center;
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}

.pc-done-emoji { font-size: 48px; margin-bottom: 8px; }
.pc-done-title { font-size: 22px; margin: 0 0 8px; }
.pc-done-subtitle { color: var(--text-muted); margin: 0 0 20px; }
.pc-done-summary { margin: 16px 0 24px; }
.pc-done-list { list-style: none; padding: 0; margin: 0; display: inline-flex; flex-direction: column; gap: 6px; text-align: left; }

/* ==========================================================================
   Toast
   ========================================================================== */

.pc-toast-root {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.pc-toast {
  background: var(--bg-card);
  color: var(--text-primary);
  padding: 10px 16px;
  border-radius: var(--radius-md);
  border-left: 4px solid var(--accent-blue);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  font-size: 13px;
  max-width: 360px;
  pointer-events: auto;
  animation: pcToastIn 0.2s ease;
}
.pc-toast--success { border-left-color: #10B981; }
.pc-toast--error { border-left-color: #EF4444; }
.pc-toast--info { border-left-color: #3B82F6; }

.pc-toast.is-leaving {
  opacity: 0;
  transform: translateX(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

@keyframes pcToastIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 900px) {
  .pc-triage-layout {
    grid-template-columns: 1fr;
  }
  .pc-summary-row {
    grid-template-columns: repeat(2, 1fr);
  }
  .pc-lock-day {
    grid-template-columns: 80px 1fr;
    grid-template-areas:
      "date info"
      "status action";
  }
  .pc-lock-day-date { grid-area: date; }
  .pc-lock-day-info { grid-area: info; }
  .pc-lock-day-status { grid-area: status; text-align: left; }
  .pc-lock-day-action { grid-area: action; }
  .pc-lock-global-bar { flex-direction: column; text-align: center; }
  .pc-header { flex-direction: column; align-items: flex-start; }
}

/* ==========================================================================
   Dark mode tweaks (piggybacks on portal.css theme)
   ========================================================================== */

[data-theme="dark"] .pc-grid-day--clean { background: rgba(16, 185, 129, 0.15); }
[data-theme="dark"] .pc-grid-day--needs_review { background: rgba(245, 158, 11, 0.18); }
[data-theme="dark"] .pc-grid-day--blocker { background: rgba(239, 68, 68, 0.22); }
[data-theme="dark"] .pc-grid-day--locked { background: rgba(59, 130, 246, 0.18); }
[data-theme="dark"] .pc-gate-banner {
  background: rgba(245, 158, 11, 0.2);
  border-color: rgba(245, 158, 11, 0.5);
  color: #fbbf24;
}

/* ==========================================================================
   Sprint 2 — UX polish + Phase 4 Commission Module
   ========================================================================== */

.pc-monitor-meta {
  font-size: 12px;
  color: var(--text-muted);
  margin: 4px 0 0;
}

.pc-card-note {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 12px;
  background: var(--bg-card-alt);
  padding: 10px 12px;
  border-radius: var(--radius-md);
}

/* --------- Completed runs list --------- */
.pc-completed-runs-slot { margin-top: 16px; }

.pc-completed-runs {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 16px 20px;
  max-width: 760px;
  margin: 0 auto;
}

.pc-completed-runs-title {
  font-size: 14px;
  margin: 0 0 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.pc-completed-runs-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.pc-completed-run {
  display: grid;
  grid-template-columns: 50px 1fr auto auto;
  gap: 12px;
  align-items: center;
  padding: 8px 4px;
  font-size: 13px;
  border-bottom: 1px dashed var(--border-light);
}
.pc-completed-run:last-child { border-bottom: none; }

.pc-completed-run-co { text-align: center; }
.pc-completed-run-period { font-weight: 600; }
.pc-completed-run-meta { color: var(--text-muted); font-size: 12px; }
.pc-completed-run-hours { font-weight: 700; color: var(--text-primary); }

.pc-completed-runs-loading {
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  padding: 12px;
}

/* --------- Phase 2 — batch banner + skip badges + sanity --------- */
.pc-batch-banner-slot { margin-bottom: 12px; }

.pc-batch-banner {
  background: linear-gradient(90deg, rgba(99, 102, 241, 0.12), rgba(59, 130, 246, 0.10));
  border: 1px solid rgba(99, 102, 241, 0.35);
  color: var(--text-primary);
  padding: 12px 16px;
  border-radius: var(--radius-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.pc-batch-banner-text { flex: 1; font-weight: 500; }

.pc-triage-item-skip-badge {
  margin-left: auto;
  font-size: 12px;
  opacity: 0.7;
}

.pc-evidence--office,
.pc-evidence--note {
  background: rgba(59, 130, 246, 0.10);
  border-left: 3px solid var(--accent-blue);
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 13px;
  color: var(--text-primary);
}

.pc-evidence--note {
  background: rgba(245, 158, 11, 0.12);
  border-left-color: #F59E0B;
}

/* --------- Phase 3 — bulk-lock banner + sanity --------- */
.pc-lock-bulk-slot { margin-bottom: 12px; }

.pc-lock-bulk-banner {
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.10), rgba(59, 130, 246, 0.08));
  border: 1px solid rgba(16, 185, 129, 0.35);
  padding: 12px 16px;
  border-radius: var(--radius-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  font-size: 13px;
}

.pc-lock-sanity-slot { margin: 8px 0; }

.pc-sanity-banner {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 500;
}
.pc-sanity-banner--high {
  background: rgba(245, 158, 11, 0.15);
  border: 1px solid rgba(245, 158, 11, 0.45);
  color: #92400e;
}
.pc-sanity-banner--low {
  background: rgba(245, 158, 11, 0.10);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #92400e;
}
[data-theme="dark"] .pc-sanity-banner--high,
[data-theme="dark"] .pc-sanity-banner--low { color: #fbbf24; }

/* --------- Phase 4 — substep nav --------- */
.pc-comm-substep-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 12px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  margin-bottom: 16px;
  flex-wrap: wrap;
}

.pc-comm-substep {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  background: transparent;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  font-family: inherit;
}
.pc-comm-substep:hover { background: var(--bg-card-alt); }
.pc-comm-substep.is-active {
  background: var(--accent-green);
  color: #fff;
  border-color: var(--accent-green);
}

.pc-comm-substep-letter {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--bg-card-alt);
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 12px;
}
.pc-comm-substep.is-active .pc-comm-substep-letter {
  background: rgba(255, 255, 255, 0.2);
  color: #fff;
}

.pc-comm-step { margin-bottom: 24px; }

.pc-comm-upload {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 16px 0 0;
  flex-wrap: wrap;
}
.pc-comm-upload-status {
  font-size: 13px;
  color: var(--text-muted);
}

.pc-comm-banner {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-left: 4px solid var(--accent-blue);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-bottom: 12px;
  font-size: 13px;
}
.pc-comm-banner--info { border-left-color: var(--accent-blue); }
.pc-comm-banner p { margin: 4px 0 0; color: var(--text-muted); }

/* --------- Phase 4 — Tech table --------- */
.pc-comm-table-card {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  overflow: auto;
  max-height: 75vh;
}
.pc-comm-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}
.pc-comm-table th,
.pc-comm-table td {
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid var(--border-light);
}
.pc-comm-table th {
  background: var(--bg-card-alt);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  position: sticky;
  top: 0;
  z-index: 1;
}
.pc-comm-table .pc-num { text-align: right; font-variant-numeric: tabular-nums; }
.pc-comm-empty td {
  text-align: center;
  color: var(--text-muted);
  font-style: italic;
  padding: 24px;
}

/* --------- Phase 4 — Office 3-col layout --------- */
.pc-comm-three-col {
  display: grid;
  grid-template-columns: 320px 1fr 280px;
  gap: 12px;
  min-height: 540px;
}

.pc-comm-list,
.pc-comm-tally {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.pc-comm-detail {
  background: var(--bg-card);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 18px;
  min-height: 540px;
}

.pc-comm-list-header {
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-default);
  background: var(--bg-card-alt);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.pc-comm-list-header h3 {
  font-size: 14px;
  margin: 0;
  font-weight: 600;
}
.pc-comm-list-meta {
  font-size: 11px;
  color: var(--text-muted);
}

.pc-comm-list-body,
.pc-comm-tally-body {
  flex: 1;
  overflow-y: auto;
  max-height: 540px;
  padding: 4px 0;
}

.pc-comm-section { border-bottom: 1px solid var(--border-light); }
.pc-comm-section:last-child { border-bottom: none; }

.pc-comm-section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 8px 16px;
  background: var(--bg-card-alt);
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.pc-comm-section-head:hover { background: var(--border-light); }

.pc-comm-line {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 16px;
  border: none;
  border-bottom: 1px solid var(--border-light);
  background: transparent;
  cursor: pointer;
  font-family: inherit;
}
.pc-comm-line:hover { background: var(--bg-card-alt); }
.pc-comm-line.is-active {
  background: var(--accent-blue-light);
  border-left: 3px solid var(--accent-blue);
}

.pc-comm-line-name {
  font-weight: 600;
  font-size: 13px;
}
.pc-comm-line-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin-top: 2px;
}

/* --------- Tally cards --------- */
.pc-comm-tally-card {
  margin: 8px;
  padding: 10px 12px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  background: var(--bg-card-alt);
}
.pc-comm-tally-card--tech { border-left: 3px solid var(--accent-green); }
.pc-comm-tally-card--office { border-left: 3px solid var(--accent-blue); }

.pc-comm-tally-name {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 4px;
}

.pc-comm-tally-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 12px;
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  gap: 2px;
}

/* --------- Phase 4 completion card --------- */
.pc-comm-completion-card { max-width: 820px; }
.pc-comm-detail-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-top: 12px;
}
.pc-comm-summary-card {
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 12px;
  background: var(--bg-card-alt);
}
.pc-comm-summary-card h3 {
  margin: 0 0 8px;
  font-size: 13px;
}
.pc-comm-summary-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 12px;
  color: var(--text-secondary);
  display: grid;
  gap: 4px;
}
.pc-comm-suggestion {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 10px 12px;
  background: var(--bg-card-alt);
  margin-bottom: 10px;
}
.pc-comm-suggestion:last-child { margin-bottom: 0; }
.pc-comm-confidence {
  display: inline-block;
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-left: 6px;
}
.pc-comm-detail-form {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}
.pc-comm-detail-form select,
.pc-comm-detail-form textarea {
  width: 100%;
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  font: inherit;
  background: var(--bg-card);
}
.pc-comm-detail-form textarea { min-height: 84px; resize: vertical; }
.pc-comm-detail-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.pc-comm-inline-note {
  font-size: 12px;
  color: var(--text-muted);
}
.pc-done-total {
  margin-top: 8px;
  padding-top: 8px;
  border-top: 1px solid var(--border-default);
  font-size: 16px;
}

.pc-done-handoff-slot { margin-top: 16px; }

.pc-handoff-card {
  background: var(--bg-card-alt);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 16px;
  margin: 12px 0 16px;
}
.pc-handoff-card p { margin: 0 0 4px; font-size: 14px; }

/* --------- Toast action button --------- */
.pc-toast {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: space-between;
}
.pc-toast-text { flex: 1; }
.pc-toast-action {
  background: transparent;
  border: 1px solid var(--border-default);
  color: var(--accent-blue);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  cursor: pointer;
  font-weight: 600;
  font-family: inherit;
}
.pc-toast-action:hover { background: var(--bg-card-alt); }

/* --------- Sprint 2 responsive --------- */
@media (max-width: 1100px) {
  .pc-comm-three-col {
    grid-template-columns: 1fr;
  }
  .pc-comm-list-body,
  .pc-comm-tally-body { max-height: 360px; }
  .pc-comm-detail { min-height: 320px; }
}
@media (max-width: 700px) {
  .pc-completed-run {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .pc-completed-run-co { text-align: left; width: max-content; }
  .pc-comm-substep-nav { flex-direction: column; }
  .pc-adp-overview-grid { grid-template-columns: 1fr; }
}

.pc-adp-overview-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.pc-adp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .92rem;
}

.pc-adp-table th,
.pc-adp-table td {
  border-bottom: 1px solid #e5e7eb;
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.pc-adp-table th {
  background: #f8fafc;
  color: #334155;
  font-size: .8rem;
  letter-spacing: .02em;
  text-transform: uppercase;
}

.pc-finalize-grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.pc-finalize-history-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.pc-finalize-history-item {
  padding: 12px 14px;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  background: var(--bg-card-alt);
}

.pc-finalize-history-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  font-size: 13px;
}

.pc-finalize-history-meta,
.pc-finalize-audit-subcopy {
  color: var(--text-muted);
  font-size: 12px;
}

.pc-finalize-audit-table td {
  font-size: 13px;
}

.pc-finalize-audit-table strong {
  color: var(--text-primary);
}


/* ==========================================================================
   Sprint 5 — immersive shell redesign
   ========================================================================== */

.pc-view {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.pc-shell {
  max-width: 1480px;
  padding-top: 28px;
}

.pc-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(320px, 420px);
  gap: 20px;
  align-items: stretch;
}

.pc-hero-main,
.pc-action-card,
.pc-truth-card,
.pc-worksurface-card,
.pc-rail-card,
.pc-phase-hero,
.pc-command-card,
.pc-wizard-rail {
  border: 1px solid rgba(148, 163, 184, 0.22);
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.06);
}

.pc-hero-main {
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.98), rgba(30, 41, 59, 0.94) 45%, rgba(30, 64, 175, 0.88));
  color: #fff;
  border-radius: 28px;
  padding: 28px;
  position: relative;
  overflow: hidden;
}

.pc-hero-main::after {
  content: "";
  position: absolute;
  inset: auto -80px -120px auto;
  width: 240px;
  height: 240px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(191, 219, 254, 0.45), rgba(191, 219, 254, 0));
  pointer-events: none;
}

.pc-hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.9);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 12px;
}

.pc-hero-main .pc-back-link,
.pc-hero-main .pc-title,
.pc-hero-main .pc-subtitle,
.pc-hero-main .pc-monitor-meta {
  color: #fff;
}

.pc-title {
  font-size: 40px;
  line-height: 1.05;
}

.pc-subtitle {
  max-width: 720px;
  font-size: 16px;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
}

.pc-monitor-meta {
  color: rgba(255, 255, 255, 0.72);
}

.pc-hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.pc-hero-tag,
.pc-context-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.pc-hero-tag {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.pc-monitor-brief-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, 0.9fr);
  gap: 14px;
  margin-top: 22px;
}

.pc-monitor-brief-card {
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  padding: 18px 18px 16px;
  backdrop-filter: blur(8px);
}

.pc-monitor-brief-card h2 {
  margin: 0 0 8px;
  font-size: 18px;
}

.pc-monitor-brief-card p,
.pc-monitor-brief-list {
  margin: 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: 13px;
  line-height: 1.6;
}

.pc-monitor-brief-list {
  padding-left: 18px;
}

.pc-monitor-brief-kicker,
.pc-action-card-topline,
.pc-truth-card-kicker,
.pc-section-kicker,
.pc-rail-card-kicker,
.pc-wizard-kicker,
.pc-phase-hero-kicker,
.pc-command-card-kicker {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 11px;
  font-weight: 800;
}

.pc-monitor-brief-kicker,
.pc-truth-card-kicker {
  color: rgba(255, 255, 255, 0.72);
  margin-bottom: 8px;
}

.pc-hero-actions {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.pc-action-card,
.pc-truth-card,
.pc-worksurface-card,
.pc-rail-card,
.pc-phase-hero,
.pc-command-card,
.pc-wizard-rail {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(248, 250, 252, 0.96));
  border-radius: 24px;
}

.pc-action-card,
.pc-truth-card,
.pc-rail-card,
.pc-command-card {
  padding: 20px;
}

.pc-action-card-topline,
.pc-section-kicker,
.pc-rail-card-kicker,
.pc-wizard-kicker,
.pc-phase-hero-kicker,
.pc-command-card-kicker {
  color: #64748b;
  margin-bottom: 6px;
}

.pc-action-card-headline,
.pc-truth-card-title,
.pc-worksurface-title,
.pc-rail-card-title,
.pc-phase-hero-title,
.pc-command-card h3 {
  margin: 0;
  color: #0f172a;
}

.pc-action-card-headline,
.pc-truth-card-title,
.pc-command-card h3 {
  font-size: 20px;
}

.pc-action-card-copy,
.pc-truth-card-copy,
.pc-worksurface-copy,
.pc-phase-hero-copy,
.pc-command-card p {
  margin: 8px 0 0;
  color: #475569;
  line-height: 1.6;
  font-size: 14px;
}

.pc-action-card-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.pc-action-card-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.pc-action-card-note {
  margin: 14px 0 0;
  color: #64748b;
  font-size: 12px;
}

.pc-truth-card {
  background: linear-gradient(160deg, rgba(37, 99, 235, 0.1), rgba(255, 255, 255, 0.98) 55%);
}

.pc-monitor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(310px, 0.8fr);
  gap: 20px;
  align-items: start;
}

.pc-monitor-main,
.pc-monitor-rail {
  min-width: 0;
}

.pc-monitor-main {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.pc-monitor-rail {
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: sticky;
  top: 20px;
}

.pc-workflow-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.pc-workflow-step {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.96);
  border: 1px solid rgba(226, 232, 240, 0.96);
}

.pc-workflow-step.is-active {
  border-color: rgba(37, 99, 235, 0.28);
  box-shadow: 0 12px 26px rgba(37, 99, 235, 0.08);
}

.pc-workflow-step strong {
  display: block;
  color: #0f172a;
}

.pc-workflow-step p {
  margin: 4px 0 0;
  color: #64748b;
  font-size: 12px;
}

.pc-workflow-step-num {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #e2e8f0;
  color: #0f172a;
  font-weight: 800;
  flex: 0 0 auto;
}

.pc-worksurface-card {
  padding: 20px;
}

.pc-worksurface-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
}

.pc-worksurface-notes {
  display: grid;
  grid-template-columns: repeat(3, minmax(140px, 1fr));
  gap: 10px;
  min-width: min(100%, 560px);
}

.pc-worksurface-note {
  border-radius: 16px;
  border: 1px solid rgba(191, 219, 254, 0.8);
  background: linear-gradient(180deg, rgba(239, 246, 255, 0.92), rgba(255, 255, 255, 0.98));
  padding: 12px 14px;
}

.pc-worksurface-note span,
.pc-rail-list span {
  display: block;
  color: #64748b;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  font-weight: 700;
}

.pc-worksurface-note strong,
.pc-rail-list strong {
  display: block;
  margin-top: 6px;
  color: #0f172a;
  line-height: 1.5;
}

.pc-grid-card--immersive {
  border-radius: 22px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.pc-rail-card-title {
  font-size: 18px;
}

.pc-rail-list,
.pc-rail-bullets {
  display: grid;
  gap: 12px;
  margin: 14px 0 0;
  padding: 0;
}

.pc-rail-list {
  list-style: none;
}

.pc-rail-bullets {
  padding-left: 18px;
  color: #475569;
  line-height: 1.55;
  font-size: 14px;
}

.pc-rail-card--truth {
  background: linear-gradient(165deg, rgba(254, 249, 195, 0.66), rgba(255, 255, 255, 0.98) 55%);
}

.pc-rail-card--workflow {
  background: linear-gradient(165deg, rgba(237, 233, 254, 0.72), rgba(255, 255, 255, 0.98) 55%);
}

.pc-monitor-history-slot .pc-completed-runs {
  margin: 0;
  max-width: none;
  padding: 0;
  background: transparent;
  border: none;
  box-shadow: none;
}

.pc-monitor-history-slot .pc-completed-runs-title {
  display: none;
}

.pc-wizard-header {
  padding: 16px 20px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
}

.pc-wizard-kicker {
  color: #64748b;
  margin-bottom: 2px;
}

.pc-wizard-title {
  font-size: 24px;
}

.pc-wizard-context-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.pc-context-pill {
  background: #eef2ff;
  color: #3730a3;
}

.pc-context-pill--highlight {
  background: #dcfce7;
  color: #166534;
}

.pc-wizard-rail {
  padding: 18px;
}

.pc-phase-stepper {
  margin-bottom: 16px;
  background: transparent;
  border: none;
  padding: 0;
}

.pc-phase-label-group {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pc-phase-detail {
  font-size: 11px;
  color: #64748b;
}

.pc-phase-hero {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 22px;
  margin-bottom: 14px;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.96), rgba(29, 78, 216, 0.9));
}

.pc-phase-hero-kicker,
.pc-phase-hero-title,
.pc-phase-hero-copy {
  color: #fff;
}

.pc-phase-hero-title {
  font-size: 26px;
}

.pc-phase-hero-copy {
  max-width: 720px;
  color: rgba(255, 255, 255, 0.82);
}

.pc-phase-hero-context {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-content: flex-start;
  justify-content: flex-end;
}

.pc-phase-hero .pc-context-pill {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.pc-phase-command-deck {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.pc-command-card--accent {
  background: linear-gradient(165deg, rgba(220, 252, 231, 0.95), rgba(255, 255, 255, 0.98));
}

.pc-card {
  max-width: none;
  margin: 0;
}

.pc-phase-1,
.pc-phase-2,
.pc-phase-3,
.pc-phase-4,
.pc-phase-5 {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.pc-completed-runs-slot {
  margin-top: 0;
}

.pc-completed-runs {
  max-width: none;
  margin: 0;
}

.pc-gate-banner--info {
  background: rgba(59, 130, 246, 0.12);
  border-color: rgba(59, 130, 246, 0.35);
  color: #1d4ed8;
}

.pc-gate-banner--warning {
  background: rgba(245, 158, 11, 0.14);
  border-color: rgba(245, 158, 11, 0.35);
  color: #92400e;
}

.pc-gate-banner--danger {
  background: rgba(239, 68, 68, 0.12);
  border-color: rgba(239, 68, 68, 0.35);
  color: #b91c1c;
}

@media (max-width: 1200px) {
  .pc-hero,
  .pc-monitor-layout,
  .pc-phase-command-deck {
    grid-template-columns: 1fr;
  }

  .pc-monitor-rail {
    position: static;
  }

  .pc-workflow-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .pc-worksurface-head,
  .pc-phase-hero {
    flex-direction: column;
  }

  .pc-worksurface-notes,
  .pc-monitor-brief-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .pc-shell {
    padding-left: 16px;
    padding-right: 16px;
  }

  .pc-title {
    font-size: 32px;
  }

  .pc-action-card-grid,
  .pc-summary-row,
  .pc-workflow-strip {
    grid-template-columns: 1fr;
  }

  .pc-worksurface-notes {
    grid-template-columns: 1fr;
  }

  .pc-wizard-header {
    position: static;
    flex-direction: column;
    align-items: flex-start;
  }

  .pc-wizard-header-right {
    width: 100%;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
  }

  .pc-wizard-context-pills {
    justify-content: flex-start;
  }
}

[data-theme="dark"] .pc-action-card,
[data-theme="dark"] .pc-truth-card,
[data-theme="dark"] .pc-worksurface-card,
[data-theme="dark"] .pc-rail-card,
[data-theme="dark"] .pc-phase-hero,
[data-theme="dark"] .pc-command-card,
[data-theme="dark"] .pc-wizard-rail {
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.98), rgba(15, 23, 42, 0.92));
  border-color: rgba(71, 85, 105, 0.6);
}

[data-theme="dark"] .pc-action-card-headline,
[data-theme="dark"] .pc-truth-card-title,
[data-theme="dark"] .pc-worksurface-title,
[data-theme="dark"] .pc-rail-card-title,
[data-theme="dark"] .pc-command-card h3,
[data-theme="dark"] .pc-worksurface-note strong,
[data-theme="dark"] .pc-rail-list strong,
[data-theme="dark"] .pc-workflow-step strong {
  color: #f8fafc;
}

[data-theme="dark"] .pc-action-card-copy,
[data-theme="dark"] .pc-truth-card-copy,
[data-theme="dark"] .pc-worksurface-copy,
[data-theme="dark"] .pc-command-card p,
[data-theme="dark"] .pc-rail-bullets,
[data-theme="dark"] .pc-workflow-step p {
  color: #cbd5e1;
}

[data-theme="dark"] .pc-workflow-step,
[data-theme="dark"] .pc-worksurface-note,
[data-theme="dark"] .pc-context-pill {
  background: rgba(15, 23, 42, 0.72);
  border-color: rgba(71, 85, 105, 0.7);
  color: #e2e8f0;
}
