/* ============================================================================
   HR — Employee intake inbox
   [2026-08-30] Styles for hr_intake_inbox.php.

   The page is a queue: most visits are "has anyone replied, and can I act on it".
   So a submitted row is the only thing that gets colour, and everything else
   stays quiet. Matches the Employee Directory's compact-row treatment rather
   than inventing a second look for the same part of the product.
   ========================================================================== */

.hr-intake-inbox {
  display: grid;
  gap: 16px;
}

.hr-intake-inbox .hii-header,
.hr-intake-inbox .hii-new,
.hr-intake-inbox .hii-flash,
.hr-intake-inbox .hii-row,
.hr-intake-inbox .hii-empty {
  margin-bottom: 0;
}

.hr-intake-inbox .hii-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  border-radius: 18px;
  padding: 22px;
}

.hr-intake-inbox .hii-kicker {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: #1d4ed8;
  margin-bottom: 5px;
}

.hr-intake-inbox .hii-title {
  margin: 0 0 8px;
  font-size: 24px;
  line-height: 1.15;
}

.hr-intake-inbox .hii-header p { margin: 0; max-width: 60ch; }

.hr-intake-inbox .hii-header-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

/* --- flash --------------------------------------------------------------- */

.hr-intake-inbox .hii-flash {
  border-radius: 14px;
  padding: 16px 18px;
  border-left: 4px solid #94a3b8;
}

.hr-intake-inbox .hii-flash p { margin: 0 0 6px; }
.hr-intake-inbox .hii-flash p:last-child { margin-bottom: 0; }
.hr-intake-inbox .hii-flash.is-success { border-left-color: #16a34a; }
.hr-intake-inbox .hii-flash.is-warning { border-left-color: #d97706; }
.hr-intake-inbox .hii-flash.is-danger  { border-left-color: #dc2626; }

/* The link is shown exactly once, so it has to be easy to select accurately. */
.hr-intake-inbox .hii-link {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 13px;
  word-break: break-all;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 10px 12px;
  user-select: all;
}

/* --- new invitation ------------------------------------------------------ */

.hr-intake-inbox .hii-new {
  border-radius: 16px;
  padding: 20px 22px;
}

.hr-intake-inbox .hii-new h2 {
  margin: 0 0 14px;
  font-size: 17px;
}

.hr-intake-inbox .hii-new-grid {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 14px;
  align-items: start;
}

.hr-intake-inbox .hii-new-grid label { display: block; margin-bottom: 5px; }
.hr-intake-inbox .hii-new-grid .input { width: 100%; min-height: 44px; border-radius: 10px; }
.hr-intake-inbox .hii-new-grid p { margin: 5px 0 0; }
.hr-intake-inbox .hii-req { color: #b91c1c; }

.hr-intake-inbox .hii-new-submit {
  align-self: start;
  padding-top: 22px;   /* line the button up with the inputs, not the labels */
}

.hr-intake-inbox .hii-sender { margin: 14px 0 0; }

/* --- list ---------------------------------------------------------------- */

.hr-intake-inbox .hii-section-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 8px 2px -4px;
}

.hr-intake-inbox .hii-section-head h2 {
  margin: 0;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #0f172a;
}

.hr-intake-inbox .hii-count {
  min-width: 22px;
  padding: 1px 8px;
  border-radius: 999px;
  background: #16a34a;
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.hr-intake-inbox .hii-list {
  display: grid;
  gap: 10px;
}

.hr-intake-inbox .hii-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  padding: 14px 18px;
  border-radius: 12px;
  border: 1px solid #e8edf4;
  box-shadow: 0 1px 2px rgba(15, 23, 42, .05);
}

/* Only a reply earns emphasis — it is the one row that needs an action. */
.hr-intake-inbox .hii-row.is-ready {
  border-color: #bbf7d0;
  background: #f6fefa;
}

.hr-intake-inbox .hii-row-main { min-width: 0; }

.hr-intake-inbox .hii-row-name {
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
  overflow-wrap: anywhere;
}

.hr-intake-inbox .hii-row-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.hr-intake-inbox .hii-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
  white-space: nowrap;
  background: #e2e8f0;
  color: #334155;
}

.hr-intake-inbox .hii-pill.is-ready { background: #dcfce7; color: #166534; }
.hr-intake-inbox .hii-pill.is-wait  { background: #dbeafe; color: #1e40af; }
.hr-intake-inbox .hii-pill.is-done  { background: #ede9fe; color: #5b21b6; }
.hr-intake-inbox .hii-pill.is-muted { background: #e2e8f0; color: #64748b; }

.hr-intake-inbox .hii-row-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.hr-intake-inbox .hii-inline { display: inline; margin: 0; }

.hr-intake-inbox .hii-empty {
  padding: 18px;
  border-radius: 12px;
  border: 1px dashed #cbd5e1;
  box-shadow: none;
  color: #64748b;
  font-size: 14px;
}

@media (max-width: 820px) {
  .hr-intake-inbox .hii-new-grid { grid-template-columns: 1fr; }
  .hr-intake-inbox .hii-new-submit { padding-top: 0; }
  .hr-intake-inbox .hii-new-submit .btn { width: 100%; }
  .hr-intake-inbox .hii-row { align-items: flex-start; }
  .hr-intake-inbox .hii-row-actions { width: 100%; }
}

/* [2026-08-30] Delete is destructive and rare. It reads as a quiet text link
   rather than a button, so it never competes with "Open in intake form" — the
   thing HR actually clicks all day — but turns unmistakably red on hover. */
.hr-intake-inbox .hii-delete {
  background: none;
  border: 0;
  padding: 6px 8px;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  color: #94a3b8;
  cursor: pointer;
  border-radius: 8px;
}

.hr-intake-inbox .hii-delete:hover {
  color: #b91c1c;
  background: #fef2f2;
}

.hr-intake-inbox .hii-delete:focus-visible {
  outline: 2px solid #b91c1c;
  outline-offset: 1px;
}

.hr-intake-inbox .hii-bulk { margin-left: auto; }
