/* Resource Assignment workflow */
.resource-assignment-modal { max-width: 980px; width: min(980px, calc(100vw - 28px)); }
.resource-assignment-modal .modal-body { padding: 0; }
.resource-stepper {
  display:grid; grid-template-columns:repeat(4,1fr); gap:8px; padding:14px 22px;
  border-bottom:1px solid var(--line); background:var(--surface-muted,#f8fafc);
}
.resource-step {
  display:flex; align-items:center; gap:9px; min-width:0; border:0; background:transparent;
  color:var(--muted); padding:8px 6px; text-align:left; cursor:pointer;
}
.resource-step span {
  width:28px; height:28px; display:grid; place-items:center; border-radius:50%;
  border:1px solid var(--line-strong,var(--line)); font-size:.75rem; font-weight:800; flex:0 0 28px;
}
.resource-step strong { font-size:.78rem; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.resource-step.is-active { color:var(--text); }
.resource-step.is-active span,
.resource-step.is-complete span { background:var(--tenant-secondary,#3b82f6); color:#fff; border-color:var(--tenant-secondary,#3b82f6); }
.resource-step.is-complete span::after { content:"✓"; }
.resource-step.is-complete span { font-size:0; }

.resource-panel { padding:24px 24px 22px; }
.resource-panel-heading { display:flex; align-items:flex-start; justify-content:space-between; gap:20px; margin-bottom:18px; }
.resource-panel-heading h3 { margin:3px 0 5px; font-size:1.35rem; }
.resource-count { font-size:.8rem; color:var(--muted); white-space:nowrap; padding-top:7px; }
.resource-field-label { display:block; font-size:.78rem; font-weight:800; margin-bottom:7px; }
.resource-field-label > span { color:#c026d3; }
.resource-search-box { display:flex; align-items:center; gap:8px; min-height:44px; border:1px solid var(--line); border-radius:12px; padding:0 12px; background:var(--surface,#fff); }
.resource-search-box:focus-within { border-color:var(--tenant-secondary,#3b82f6); box-shadow:0 0 0 3px color-mix(in srgb,var(--tenant-secondary,#3b82f6) 12%,transparent); }
.resource-search-box > span { color:var(--muted); }
.resource-search-box input { border:0 !important; outline:0 !important; box-shadow:none !important; background:transparent !important; min-height:40px; padding:0 !important; width:100%; }
.resource-selection-list { display:grid; gap:8px; max-height:350px; overflow:auto; margin-top:10px; }
.resource-person-option {
  width:100%; display:flex; align-items:center; gap:12px; padding:12px; border:1px solid var(--line); border-radius:12px;
  background:var(--surface,#fff); color:var(--text); text-align:left; cursor:pointer;
}
.resource-person-option:hover,.resource-person-option.is-selected { border-color:var(--tenant-secondary,#3b82f6); background:color-mix(in srgb,var(--tenant-secondary,#3b82f6) 5%,var(--surface,#fff)); }
.resource-avatar,.resource-selected-icon { width:38px; height:38px; display:grid; place-items:center; border-radius:11px; background:var(--surface-muted,#f1f5f9); color:var(--tenant-secondary,#3b82f6); font-weight:900; flex:0 0 38px; }
.resource-person-copy { display:flex; flex-direction:column; gap:3px; min-width:0; flex:1; }
.resource-person-copy strong { font-size:.86rem; }
.resource-person-copy small { color:var(--muted); font-size:.75rem; }
.resource-radio { width:17px; height:17px; border:1.5px solid var(--line-strong,var(--line)); border-radius:50%; flex:0 0 17px; }
.resource-person-option.is-selected .resource-radio { border:5px solid var(--tenant-secondary,#3b82f6); }
.resource-selected-card {
  margin-top:12px; display:flex; align-items:center; gap:12px; padding:14px; border:1px solid var(--tenant-secondary,#3b82f6);
  border-radius:14px; background:color-mix(in srgb,var(--tenant-secondary,#3b82f6) 5%,var(--surface,#fff));
}
.resource-selected-card > div:nth-child(2) { flex:1; min-width:0; display:flex; flex-direction:column; gap:3px; }
.resource-selected-card strong { font-size:.9rem; }
.resource-selected-card span,.resource-selected-card small { color:var(--muted); font-size:.75rem; }

.resource-check-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; max-height:390px; overflow:auto; padding:2px; }
.resource-check-card { position:relative; display:flex; gap:10px; align-items:flex-start; padding:13px; border:1px solid var(--line); border-radius:13px; background:var(--surface,#fff); cursor:pointer; }
.resource-check-card:hover { border-color:var(--tenant-secondary,#3b82f6); }
.resource-check-card > input { position:absolute; opacity:0; pointer-events:none; }
.resource-check-card:has(input:checked) { border-color:var(--tenant-secondary,#3b82f6); background:color-mix(in srgb,var(--tenant-secondary,#3b82f6) 5%,var(--surface,#fff)); box-shadow:0 0 0 2px color-mix(in srgb,var(--tenant-secondary,#3b82f6) 12%,transparent); }
.resource-check-mark { width:20px; height:20px; border:1.5px solid var(--line-strong,var(--line)); border-radius:6px; flex:0 0 20px; position:relative; }
.resource-check-card:has(input:checked) .resource-check-mark { background:var(--tenant-secondary,#3b82f6); border-color:var(--tenant-secondary,#3b82f6); }
.resource-check-card:has(input:checked) .resource-check-mark::after { content:""; position:absolute; left:5px; top:2px; width:6px; height:10px; border:solid #fff; border-width:0 2px 2px 0; transform:rotate(45deg); }
.resource-check-copy { display:flex; flex-direction:column; gap:4px; min-width:0; flex:1; }
.resource-check-copy strong { font-size:.86rem; }
.resource-check-copy small { color:var(--muted); font-size:.73rem; line-height:1.35; }
.resource-role-wrap { margin-top:5px; }
.resource-inline-select { width:100%; min-height:34px; font-size:.76rem; }
.resource-inline-note { color:var(--muted); font-size:.72rem; }

.resource-form-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:14px; margin-top:18px; }
.resource-form-grid label { display:flex; flex-direction:column; gap:7px; font-size:.78rem; font-weight:800; }
.resource-form-grid .optional { font-weight:500; color:var(--muted); }
.resource-form-grid input,.resource-form-grid select,.resource-form-grid textarea { font:inherit; font-weight:500; }
.resource-filter-row { display:grid; grid-template-columns:1fr 220px; gap:10px; margin-bottom:10px; }
.resource-actions { display:flex; justify-content:flex-end; gap:10px; margin-top:22px; padding-top:16px; border-top:1px solid var(--line); }
.resource-actions .primary,.resource-actions .secondary { min-width:120px; }

.resource-review { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:12px; }
.resource-review-card { border:1px solid var(--line); border-radius:14px; padding:15px; background:var(--surface,#fff); }
.resource-review-person { grid-column:1/-1; display:flex; flex-direction:column; gap:4px; }
.resource-review-person strong { font-size:1rem; }
.resource-review-person > span:not(.eyebrow) { color:var(--muted); font-size:.78rem; }
.resource-review-title { display:flex; justify-content:space-between; gap:10px; margin-bottom:8px; font-size:.82rem; font-weight:800; }
.resource-review-title strong { color:var(--tenant-secondary,#3b82f6); }
.resource-review-row { display:flex; gap:9px; padding:9px 0; border-top:1px solid var(--line); }
.resource-review-row > span { color:#16a34a; font-weight:900; }
.resource-review-row div { display:flex; flex-direction:column; gap:2px; min-width:0; }
.resource-review-row small { color:var(--muted); font-size:.72rem; }
.resource-review-meta { display:flex; justify-content:space-between; gap:12px; padding:8px 0; border-top:1px solid var(--line); font-size:.75rem; }
.resource-review-meta span { color:var(--muted); }

@media (max-width:760px) {
  .resource-stepper { padding:10px 12px; }
  .resource-step { justify-content:center; }
  .resource-step strong { display:none; }
  .resource-panel { padding:18px 15px; }
  .resource-check-grid,.resource-review,.resource-form-grid { grid-template-columns:1fr; }
  .resource-review-person { grid-column:auto; }
  .resource-filter-row { grid-template-columns:1fr; }
  .resource-selected-card { align-items:flex-start; flex-wrap:wrap; }
  .resource-selected-card .small-btn { margin-left:50px; }
  .resource-actions { position:sticky; bottom:0; background:var(--surface,#fff); z-index:2; }
}

/* Asset catalog */
.catalog-tabs { display:flex; gap:7px; overflow:auto; margin:0 0 14px; padding-bottom:2px; }
.catalog-tab { border:1px solid var(--line); background:var(--surface,#fff); color:var(--muted); border-radius:10px; padding:10px 14px; font-weight:800; cursor:pointer; white-space:nowrap; }
.catalog-tab:hover,.catalog-tab.is-active { color:var(--text); border-color:var(--tenant-secondary,#3b82f6); background:color-mix(in srgb,var(--tenant-secondary,#3b82f6) 7%,var(--surface,#fff)); }
.asset-catalog-page { margin-bottom:12px; }

/* UI-13 employee resource workflow */
.resource-selected-copy { flex:1; min-width:0; display:flex; flex-direction:column; gap:4px; }
.resource-existing-summary { display:flex; flex-wrap:wrap; gap:7px; margin-top:5px; }
.resource-existing-summary span { display:inline-flex; align-items:center; min-height:24px; padding:3px 8px; border-radius:999px; background:var(--surface-muted,#f1f5f9); color:var(--muted); font-size:.7rem; font-weight:750; }
.resource-existing-names { margin-top:2px; color:var(--muted); }
.resource-check-card:has(input:disabled) { opacity:.62; cursor:not-allowed; background:var(--surface-muted,#f8fafc); }
.resource-check-card:has(input:disabled):hover { border-color:var(--line); }
.resource-check-card input:disabled + .resource-check-mark { background:var(--surface-muted,#e2e8f0); border-color:var(--line); }
.resource-inline-note.resource-already { display:inline-flex; width:max-content; max-width:100%; margin-top:5px; padding:3px 7px; border-radius:7px; background:var(--surface-muted,#f1f5f9); color:var(--muted); font-size:.68rem; font-weight:700; }
.resource-selected-card { align-items:flex-start; }
@media (max-width:760px) {
  .resource-check-grid { grid-template-columns:1fr; }
  .resource-step strong { display:none; }
  .resource-stepper { gap:4px; }
}

/* UI-20: wizard validation feedback must appear on the step being edited. */
.resource-step-message {
  margin: -2px 0 14px;
  min-height: 0;
}
.resource-step-message:empty { display: none; }
.resource-step-message.error {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
}
