/* Autofill-aware Application Tracker source delta. */

body[data-page="applications"] .metric-card__delta strong {
  color: var(--ink, #01382c);
}

.job-row.tracker-entry--locked,
.kanban-card.tracker-entry--locked,
.tracker-table--sheet tr.tracker-entry--locked td {
  background: rgba(15, 23, 42, 0.025);
}

.job-row.tracker-entry--locked {
  border-style: dashed;
}

.tracker-entry--locked .cell-select,
.tracker-entry--locked .cell[contenteditable="true"] {
  cursor: not-allowed;
}

.autofill-lock-pill,
.autofill-chip,
.session-chip,
.error-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 22px;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(1, 56, 44, 0.1);
  font-size: 0.6875rem;
  line-height: 1.1;
  font-weight: 750;
  white-space: nowrap;
}

.autofill-lock-pill {
  color: #475569;
  background: #f8fafc;
}

.autofill-chip {
  color: #0369a1;
  background: #f0f9ff;
  border-color: rgba(3, 105, 161, 0.16);
}

.session-chip {
  color: #047857;
  background: #ecfdf5;
  border-color: rgba(4, 120, 87, 0.18);
}

.session-chip--attention {
  color: #b45309;
  background: #fffbeb;
  border-color: rgba(180, 83, 9, 0.2);
}

.session-chip--error,
.error-chip {
  color: #b91c1c;
  background: #fef2f2;
  border-color: rgba(185, 28, 28, 0.18);
}

.status-pill--autofill-queue {
  color: #0369a1;
  background: #e0f2fe;
}

.status-pill--attention-needed {
  color: #b45309;
  background: #fef3c7;
}

.status-pill--applied-success {
  color: #047857;
  background: #d1fae5;
}

.status-pill--closed {
  color: #b91c1c;
  background: #fee2e2;
}

.status-pill--opened {
  color: #6d28d9;
  background: #ede9fe;
}

/* Build5-parity card actions: hover-revealed Apply/Archive/Delete chips. */
.kanban-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
  padding-top: 8px;
  border-top: 1px dashed rgba(1, 56, 44, 0.1);
  opacity: 0;
  transition: opacity 0.15s ease;
}

.kanban-card:hover .kanban-card__actions,
.kanban-card:focus-within .kanban-card__actions,
.kanban-card--opened .kanban-card__actions {
  opacity: 1;
}

.kanban-card__action {
  appearance: none;
  border: 1px solid rgba(1, 56, 44, 0.12);
  background: #fff;
  color: var(--ink, #01382c);
  font: inherit;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.12s ease, border-color 0.12s ease;
}

.kanban-card__action:hover {
  background: rgba(1, 56, 44, 0.04);
}

.kanban-card__action--applied {
  border-color: rgba(34, 197, 94, 0.4);
  color: #16803c;
}

.kanban-card__action--applied:hover {
  background: rgba(34, 197, 94, 0.08);
  border-color: rgba(34, 197, 94, 0.6);
}

.kanban-card__action--delete {
  color: #b91c1c;
  border-color: rgba(185, 28, 28, 0.3);
}

.kanban-card__action--delete:hover {
  background: rgba(185, 28, 28, 0.06);
  border-color: rgba(185, 28, 28, 0.5);
}

/* Build5-parity tracker results-header right-side controls. */
.results-show-drafts {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.8125rem;
  color: rgba(1, 56, 44, 0.55);
  cursor: pointer;
  user-select: none;
}

.results-show-drafts input {
  margin: 0;
}

.results-refresh {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ink, #01382c);
  background: #fff;
  border: 1px solid rgba(1, 56, 44, 0.12);
  border-radius: 999px;
  cursor: pointer;
}

.results-refresh:hover {
  background: rgba(1, 56, 44, 0.04);
}

/* Hide cards-only / board-only controls based on the active view mode.
   Sort dropdown is cards-only; Show-drafts checkbox is board-only.
   Refresh stays visible across all views. */
.app-tab-panel[data-app-panel="tracker"]:has([data-tracker-view-target="board"].is-active) .results-sort,
.app-tab-panel[data-app-panel="tracker"]:has([data-tracker-view-target="table"].is-active) .results-sort {
  display: none;
}

.app-tab-panel[data-app-panel="tracker"]:has([data-tracker-view-target="cards"].is-active) .results-show-drafts,
.app-tab-panel[data-app-panel="tracker"]:has([data-tracker-view-target="table"].is-active) .results-show-drafts {
  display: none;
}

.tracker-card-actions .autofill-chip,
.tracker-card-actions .session-chip,
.tracker-card-actions .error-chip,
.tracker-card-actions .autofill-lock-pill {
  font-size: 0.625rem;
}

.page-grid--tracker,
.page-grid--tracker .section-stack,
.tracker-view[data-tracker-view="board"] {
  min-width: 0;
  max-width: 100%;
}

.kanban-board[data-autofill-taxonomy="true"] {
  --autofill-kanban-gap: 18px;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  grid-template-columns: repeat(var(--autofill-kanban-cols, 9), minmax(260px, 280px));
  gap: var(--autofill-kanban-gap);
  column-gap: var(--autofill-kanban-gap);
  align-items: start;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-inline: contain;
  padding-bottom: 12px;
  -webkit-overflow-scrolling: touch;
}

.kanban-board[data-autofill-taxonomy="true"] .kanban-column {
  box-sizing: border-box;
  width: 100%;
  min-width: 0;
  border-radius: 14px;
  padding: 12px;
}

.kanban-card__company {
  margin-bottom: 8px;
}

.kanban-card__autofill {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 10px;
}

.tracker-table--sheet[data-autofill-taxonomy="true"] {
  min-width: 1440px;
}

.tracker-table--sheet col.col-primary {
  width: 150px;
}

.tracker-table--sheet col.col-session {
  width: 170px;
}

.tracker-table--sheet col.col-error {
  width: 170px;
}

.tracker-table--sheet col.col-owner {
  width: 120px;
}

.tracker-table--sheet col.col-last-run {
  width: 118px;
}

.tracker-table--sheet td .cell.cell--status-label {
  font-size: 0.75rem;
  color: #334155;
}

.autofill-cell-stack {
  display: grid;
  gap: 4px;
  padding: 8px 10px;
}

.autofill-cell-stack strong {
  font-size: 0.8125rem;
  color: var(--ink, #01382c);
}

.autofill-cell-stack span {
  font-size: 0.75rem;
  color: var(--ink-faint, #6b7280);
}

.autofill-detail-list {
  display: grid;
  gap: 8px;
  margin: 12px 0 0;
}

.autofill-detail-list div {
  display: grid;
  grid-template-columns: 170px minmax(0, 1fr);
  gap: 12px;
  font-size: 0.8125rem;
}

.autofill-detail-list dt {
  margin: 0;
  color: var(--ink-faint, #6b7280);
  font-weight: 700;
}

.autofill-detail-list dd {
  margin: 0;
  color: #334155;
}

@media (max-width: 900px) {
  .autofill-detail-list div {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 680px) {
  .kanban-board[data-autofill-taxonomy="true"] {
    grid-template-columns: repeat(9, minmax(236px, 252px));
    overflow-x: auto;
  }
}

/* ── Auto-Fill: Download Extension hero ─────────────────────────
   Mirrors /jobseeker-dashboard/feed/ zero-state__welcome card.
   Scoped to .surface-card--feed-hero so other settings-sections stay neutral. */
.surface-card--feed-hero {
  background: linear-gradient(135deg, rgba(5, 150, 105, 0.08) 0%, rgba(5, 150, 105, 0.02) 100%) !important;
  border: 1px solid rgba(5, 150, 105, 0.18) !important;
  border-radius: 16px !important;
  box-shadow: none !important;
}

.surface-card--feed-hero > .surface-card__body {
  padding: 28px 28px 24px;
}

.surface-card--feed-hero .surface-card-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  background: rgba(5, 150, 105, 0.1);
  color: #047857;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 10px;
}

.surface-card--feed-hero .settings-section__title {
  font-size: 26px;
  line-height: 1.25;
  font-weight: 700;
  color: #064e3b;
  max-width: 32ch;
  margin: 0 0 8px;
}

.surface-card--feed-hero .settings-section__title strong {
  color: #047857;
  font-weight: 700;
}

.surface-card--feed-hero .settings-section__desc {
  font-size: 14px;
  line-height: 1.55;
  color: rgba(6, 78, 59, 0.78);
  max-width: 64ch;
  margin: 0;
}

.surface-card--feed-hero .settings-section__head {
  align-items: flex-start;
  gap: 16px;
}

.surface-card--feed-hero .settings-rows {
  margin-top: 20px;
  border-top: 1px solid rgba(5, 150, 105, 0.14);
  padding-top: 16px;
}
