/* ==========================================================================
   Simple Table View + No-Login User Picker
   Everything the multi-view Kanban/timeline UI used to need, replaced with
   one flat table. Reuses tokens from style.css (--bg-*, --text-*, --accent-*).
   ========================================================================== */

/* ---------- Who-are-you overlay ---------- */
.user-picker-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(4, 7, 13, 0.85);
  backdrop-filter: blur(6px);
}
.user-picker-overlay.active { display: flex; }

.user-picker-card {
  width: min(480px, 90vw);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  padding: 2rem;
  text-align: center;
}
.user-picker-card h2 {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}
.user-picker-card > p {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin-bottom: 1.5rem;
}
.user-picker-options {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.user-pick-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  width: 100%;
  padding: 0.85rem 1rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  color: var(--text-main);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition-fast);
}
.user-pick-btn:hover {
  border-color: var(--border-focus);
  background: var(--bg-card-hover);
  transform: translateY(-1px);
}
.user-pick-avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  color: #04070d;
  flex: none;
}

/* ---------- Current-user badge (header) ---------- */
.current-user-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.7rem 0.4rem 0.4rem;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  color: var(--text-main);
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 600;
}
.current-user-badge:hover { border-color: var(--border-focus); }
.current-user-badge .cu-avatar {
  width: 22px;
  height: 22px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  font-weight: 700;
  color: #04070d;
}
.current-user-badge .cu-switch {
  color: var(--text-dim);
  font-weight: 500;
  font-size: 0.72rem;
}

/* ---------- Toolbar summary line ---------- */
.simple-summary {
  font-size: 0.82rem;
  color: var(--text-muted);
  white-space: nowrap;
}
.simple-summary b { color: var(--text-main); font-variant-numeric: tabular-nums; }

/* ---------- The table itself ---------- */
.simple-table-wrap {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.simple-table {
  width: 100%;
  border-collapse: collapse;
}
.simple-table th {
  text-align: left;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-dim);
  font-weight: 600;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface-elevated);
}
.simple-table td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-subtle);
  vertical-align: middle;
}
.simple-table tbody tr:last-child td { border-bottom: none; }
.simple-table tbody tr:hover { background: var(--bg-card); }
.simple-table tbody tr.row-done .st-title-text { color: var(--text-dim); text-decoration: line-through; }

.st-title-text {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
}
.st-desc {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
  max-width: 46ch;
}

.module-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.25rem 0.6rem;
  border-radius: var(--radius-full);
  white-space: nowrap;
}
.module-pill::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}

.status-quick-select {
  font-family: var(--font-sans);
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35rem 0.5rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: var(--bg-card);
  color: var(--text-main);
  cursor: pointer;
}

.assignee-cell { text-align: center; }
.assignee-btn {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-full);
  border: 1px dashed var(--border-subtle);
  background: transparent;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition-fast);
}
.assignee-btn.unassigned:hover {
  border-color: var(--border-focus);
  color: var(--text-main);
}
.assignee-btn.assigned {
  border-style: solid;
  color: #04070d;
}
.assignee-btn.assigned.is-me {
  box-shadow: 0 0 0 2px var(--bg-surface), 0 0 0 3px currentColor;
}

.row-actions-cell {
  display: flex;
  gap: 0.3rem;
  justify-content: flex-end;
}

.simple-empty-state {
  padding: 3rem 1rem;
  text-align: center;
  color: var(--text-muted);
}
