/* ===== Reset & Base ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --sidebar-bg: #0f0f14;
  --sidebar-text: #a0a0b0;
  --sidebar-accent: #E8C872;
  --sidebar-width: 260px;
  --bg: #151520;
  --surface: #1c1c2a;
  --surface-hover: #22223a;
  --text: #e8e8f0;
  --text-muted: #7a7a8e;
  --border: #2a2a3e;
  --primary: #E8C872;
  --primary-hover: #d4b45e;
  --primary-text: #0f0f14;
  --radius: 10px;
  --shadow: 0 2px 8px rgba(0,0,0,0.3);
  --glow: 0 0 20px rgba(232,200,114,0.1);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  min-height: 100vh;
}

/* ===== Login Page ===== */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: #0a0a10;
  background-image:
    radial-gradient(ellipse at 20% 50%, rgba(232,200,114,0.06) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 20%, rgba(139,92,246,0.04) 0%, transparent 50%);
}

.login-container { width: 100%; max-width: 420px; padding: 20px; }

.login-card {
  background: var(--surface);
  border-radius: 16px;
  padding: 44px 36px;
  box-shadow: 0 12px 48px rgba(0,0,0,0.4);
  border: 1px solid var(--border);
}

.login-header { text-align: center; margin-bottom: 36px; }
.login-logo { max-width: 220px; margin-bottom: 16px; }
.login-header h1 { font-size: 26px; color: var(--text); font-weight: 700; letter-spacing: 2px; }
.login-header p { color: var(--primary); margin-top: 4px; font-size: 13px; letter-spacing: 3px; text-transform: uppercase; font-weight: 500; }

/* ===== Forms ===== */
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 12px; font-weight: 600; margin-bottom: 6px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.5px; }
.form-group input, .form-group textarea, .form-group select {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  background: var(--bg);
  color: var(--text);
  transition: border-color 0.2s, box-shadow 0.2s;
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(232,200,114,0.15);
}
.form-group input::placeholder { color: var(--text-muted); }
.form-group-full { grid-column: 1 / -1; }

.checkbox-label { display: flex; align-items: center; gap: 8px; cursor: pointer; font-weight: normal !important; }
.checkbox-label input[type="checkbox"] { width: auto; accent-color: var(--primary); }

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 22px;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  text-decoration: none;
}
.btn-primary { background: var(--primary); color: var(--primary-text); }
.btn-primary:hover { background: var(--primary-hover); box-shadow: var(--glow); }
.btn-outline { background: transparent; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover { background: var(--surface-hover); border-color: var(--text-muted); }
.btn-full { width: 100%; }
.btn-sm { padding: 6px 14px; font-size: 12px; }

/* ===== Error/Status Messages ===== */
.error-msg { color: #f87171; font-size: 13px; margin: 8px 0; min-height: 20px; }

/* ===== Dashboard Layout ===== */
.app-layout { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-width);
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  transition: transform 0.3s;
  border-right: 1px solid var(--border);
}

.sidebar-header {
  padding: 24px 20px 16px;
  border-bottom: 1px solid var(--border);
}
.sidebar-logo { max-width: 160px; margin-bottom: 4px; }
.sidebar-header h2 { font-size: 18px; color: var(--text); font-weight: 700; letter-spacing: 2px; }
.sidebar-subtitle { font-size: 11px; color: var(--primary); letter-spacing: 2px; text-transform: uppercase; font-weight: 500; }

.sidebar-nav { flex: 1; padding: 16px 0; }

.nav-item {
  display: flex;
  align-items: center;
  padding: 12px 20px;
  color: var(--sidebar-text);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  border-left: 3px solid transparent;
  margin: 2px 0;
}
.nav-item:hover { background: rgba(232,200,114,0.06); color: var(--text); }
.nav-item.active {
  background: rgba(232,200,114,0.08);
  border-left-color: var(--primary);
  color: var(--primary);
}
.nav-icon { margin-right: 12px; font-size: 16px; }

.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border);
}
.user-name { font-size: 14px; font-weight: 600; color: var(--text); }
.user-role { font-size: 11px; color: var(--text-muted); margin-bottom: 8px; }
.logout-btn { font-size: 12px; color: var(--primary); text-decoration: none; opacity: 0.8; }
.logout-btn:hover { opacity: 1; text-decoration: underline; }

/* Main content area */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  padding: 32px;
  min-width: 0;
}

/* ===== Hamburger ===== */
.hamburger {
  display: none;
  position: fixed;
  top: 12px; left: 12px;
  z-index: 200;
  background: var(--sidebar-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px;
  cursor: pointer;
  flex-direction: column;
  gap: 4px;
}
.hamburger span { display: block; width: 22px; height: 2px; background: var(--primary); border-radius: 2px; }

/* ===== Page header ===== */
.page-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; flex-wrap: wrap; gap: 12px; }
.page-header h1 { font-size: 24px; font-weight: 700; color: var(--text); }
.lead-count { font-size: 13px; color: var(--text-muted); background: var(--surface); padding: 5px 14px; border-radius: 16px; border: 1px solid var(--border); }

/* ===== Filters ===== */
.filters { display: flex; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; align-items: center; }
.filter-input, .filter-select {
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 13px;
  background: var(--surface);
  color: var(--text);
  min-width: 160px;
}
.filter-input { flex: 1; min-width: 200px; max-width: 320px; }
.filter-input::placeholder { color: var(--text-muted); }

/* ===== Tables ===== */
.table-responsive { overflow-x: auto; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}
.data-table th {
  background: var(--bg);
  padding: 12px 16px;
  text-align: left;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}
.data-table td {
  padding: 12px 16px;
  font-size: 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.data-table tbody tr:hover { background: var(--surface-hover); }
.data-table tbody tr:last-child td { border-bottom: none; }

.member-name { font-weight: 600; color: var(--text); }
.contact-cell { font-size: 13px; }

/* ===== Status Badges ===== */
.status-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.unassigned { color: var(--text-muted); font-style: italic; font-size: 13px; }

/* ===== Role Badges ===== */
.role-badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
}
.role-admin { background: rgba(232,200,114,0.15); color: #E8C872; }
.role-manager { background: rgba(139,92,246,0.15); color: #a78bfa; }
.role-pt { background: rgba(59,130,246,0.15); color: #60a5fa; }

.badge-active { color: #34d399; font-size: 13px; font-weight: 600; }
.badge-inactive { color: #f87171; font-size: 13px; font-weight: 600; }

/* ===== Links ===== */
.phone-link, .email-link { color: var(--primary); text-decoration: none; }
.phone-link:hover, .email-link:hover { text-decoration: underline; color: var(--primary-hover); }

/* ===== Stats Cards ===== */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 16px; margin-bottom: 32px; }

.stat-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow);
  text-align: center;
  border: 1px solid var(--border);
  transition: border-color 0.2s;
}
.stat-card:hover { border-color: rgba(232,200,114,0.3); }
.stat-value { font-size: 36px; font-weight: 800; color: var(--primary); }
.stat-label { font-size: 13px; color: var(--text-muted); margin-top: 4px; font-weight: 500; }

/* ===== Sections ===== */
.section { margin-bottom: 32px; }
.section h2 { font-size: 18px; font-weight: 700; margin-bottom: 16px; color: var(--text); }

/* ===== Status Bars ===== */
.status-bars { background: var(--surface); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); border: 1px solid var(--border); }
.status-bar-row { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.status-bar-row:last-child { margin-bottom: 0; }
.status-bar-label { min-width: 130px; }
.status-bar-track { flex: 1; height: 24px; background: var(--bg); border-radius: 12px; overflow: hidden; }
.status-bar-fill { height: 100%; border-radius: 12px; transition: width 0.3s; min-width: 2px; }
.status-bar-count { min-width: 36px; text-align: right; font-weight: 600; font-size: 14px; }

/* ===== Modal ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}
.modal {
  background: var(--surface);
  border-radius: 14px;
  width: 100%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  border: 1px solid var(--border);
}
.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
}
.modal-header h2 { font-size: 18px; color: var(--text); }
.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--text-muted);
  padding: 0 4px;
}
.modal-close:hover { color: var(--primary); }
.modal-body { padding: 24px; }

/* ===== Detail Grid ===== */
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 24px; }
.detail-item label { display: block; font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.5px; color: var(--text-muted); margin-bottom: 2px; }
.detail-item div { font-size: 14px; color: var(--text); }

/* ===== Update Section ===== */
.update-section { border-top: 1px solid var(--border); padding-top: 20px; margin-bottom: 24px; }
.update-section h3 { font-size: 15px; font-weight: 700; margin-bottom: 12px; color: var(--text); }
.form-inline { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-inline button { grid-column: 1 / -1; justify-self: start; }

/* ===== History ===== */
.history-section { border-top: 1px solid var(--border); padding-top: 20px; }
.history-section h3 { font-size: 15px; font-weight: 700; margin-bottom: 12px; color: var(--text); }
.history-list { display: flex; flex-direction: column; gap: 12px; }
.history-item { padding: 12px; background: var(--bg); border-radius: 8px; border: 1px solid var(--border); }
.history-change { margin-bottom: 4px; }
.history-meta { font-size: 12px; color: var(--text-muted); }
.history-notes { font-size: 13px; margin-top: 4px; color: var(--text); font-style: italic; opacity: 0.8; }

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

/* ===== Change Password ===== */
.change-password-container {
  max-width: 440px;
  margin: 80px auto;
}
.change-password-container h2 { margin-bottom: 8px; color: var(--text); }
.change-password-container p { color: var(--text-muted); margin-bottom: 24px; }
.form-card {
  background: var(--surface);
  padding: 24px;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

/* ===== Loading & Empty ===== */
.loading { text-align: center; padding: 60px 20px; color: var(--text-muted); font-size: 15px; }
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
  font-size: 15px;
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

/* ===== Settings ===== */
.settings-section { max-width: 700px; }
.settings-heading { font-size: 18px; font-weight: 700; color: var(--text); margin-bottom: 16px; }
.settings-status {
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 14px;
  margin-bottom: 20px;
  border: 1px solid var(--border);
}
.settings-status.status-ok { background: rgba(34,197,94,0.1); color: #34d399; border-color: rgba(34,197,94,0.2); }
.settings-status.status-warn { background: rgba(245,158,11,0.1); color: #fbbf24; border-color: rgba(245,158,11,0.2); }
.settings-textarea {
  width: 100%;
  font-family: 'SF Mono', SFMono-Regular, Consolas, monospace;
  font-size: 12px;
  line-height: 1.5;
  resize: vertical;
}

/* Drop zone */
.drop-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 40px 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.2s, background 0.2s;
  background: var(--bg);
}
.drop-zone:hover {
  border-color: var(--text-muted);
}
.drop-zone.drop-zone-active {
  border-color: var(--primary);
  background: rgba(232,200,114,0.05);
}
.drop-zone-icon {
  font-size: 36px;
  margin-bottom: 8px;
  opacity: 0.6;
}
.drop-zone-text {
  font-size: 14px;
  color: var(--text-muted);
}
.drop-zone-text strong {
  color: var(--primary);
}
.drop-zone-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  opacity: 0.7;
}

/* File info after selection */
.file-info {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
}
.file-icon {
  font-size: 24px;
  opacity: 0.7;
}
.file-name {
  flex: 1;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  word-break: break-all;
}
.file-remove {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 18px;
  padding: 0 4px;
  transition: color 0.2s;
}
.file-remove:hover {
  color: #f87171;
}

/* Field hint */
.field-hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 4px;
  opacity: 0.8;
}

/* Verify success banner */
.verify-success {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 14px;
  background: rgba(34,197,94,0.1);
  color: #34d399;
  border: 1px solid rgba(34,197,94,0.2);
  margin-bottom: 16px;
}

/* Step indicator */
.settings-steps {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
}
.settings-step {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: var(--text-muted);
  padding: 6px 12px;
  border-radius: 16px;
  background: var(--bg);
  border: 1px solid var(--border);
}
.settings-step.step-active {
  color: var(--primary);
  border-color: var(--primary);
  background: rgba(232,200,114,0.08);
}
.settings-step.step-done {
  color: #34d399;
  border-color: rgba(34,197,94,0.3);
  background: rgba(34,197,94,0.08);
}
.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  font-size: 11px;
  font-weight: 700;
  background: var(--border);
  color: var(--text);
}
.step-active .step-num {
  background: var(--primary);
  color: var(--primary-text);
}
.step-done .step-num {
  background: #34d399;
  color: #0a0a10;
}

/* ===== View Toggle ===== */
.view-toggle {
  display: inline-flex;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}
.view-toggle-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 34px;
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  font-size: 16px;
}
.view-toggle-btn:hover { color: var(--text); background: var(--surface-hover); }
.view-toggle-btn.active { color: var(--primary); background: rgba(232,200,114,0.12); }
.view-toggle-btn + .view-toggle-btn { border-left: 1px solid var(--border); }

/* ===== Kanban Board ===== */
.kanban-board {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 16px;
  min-height: 400px;
}

.kanban-column {
  flex: 0 0 280px;
  min-width: 280px;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  max-height: calc(100vh - 240px);
  transition: flex 0.3s, min-width 0.3s;
}

.kanban-column-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  border-top: 3px solid var(--border);
  border-radius: var(--radius) var(--radius) 0 0;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text);
  flex-shrink: 0;
}

.kanban-column-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.kanban-column-count {
  margin-left: auto;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  background: var(--surface);
  padding: 2px 8px;
  border-radius: 10px;
  border: 1px solid var(--border);
}

.kanban-column-body {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: background 0.2s, border-color 0.2s;
}

/* Drop target highlight */
.kanban-column-body.kanban-drop-target {
  background: rgba(232,200,114,0.04);
  border: 2px dashed rgba(232,200,114,0.4);
  border-radius: 0 0 calc(var(--radius) - 1px) calc(var(--radius) - 1px);
  margin: 0 1px 1px;
  padding: 7px;
}

/* Collapsed lost column */
.kanban-column.collapsed {
  flex: 0 0 52px;
  min-width: 52px;
  cursor: pointer;
  align-items: center;
  overflow: hidden;
}
.kanban-column.collapsed .kanban-column-header {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  padding: 14px 0;
  justify-content: center;
  width: 100%;
  border-top: 3px solid #ef4444;
}
.kanban-column.collapsed .kanban-column-body { display: none; }
.kanban-column.collapsed .kanban-column-count { display: none; }
.kanban-column.collapsed .kanban-collapse-btn { display: none; }

.kanban-collapse-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 14px;
  padding: 0 2px;
  line-height: 1;
  transition: color 0.2s;
}
.kanban-collapse-btn:hover { color: var(--text); }

/* ===== Kanban Cards ===== */
.kanban-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  cursor: grab;
  transition: box-shadow 0.2s, border-color 0.2s, opacity 0.2s;
  user-select: none;
}
.kanban-card:hover {
  border-color: rgba(232,200,114,0.3);
  box-shadow: 0 2px 12px rgba(0,0,0,0.3);
}
.kanban-card:active { cursor: grabbing; }

.kanban-card-ghost {
  opacity: 0.3 !important;
}

.kanban-card-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}

.kanban-card-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.kanban-card-age {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 8px;
  background: var(--bg);
  color: var(--text-muted);
  border: 1px solid var(--border);
  white-space: nowrap;
}

.kanban-card-details {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-bottom: 8px;
  font-size: 12px;
}
.kanban-card-details a {
  color: var(--text-muted);
  text-decoration: none;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.kanban-card-details a:hover { color: var(--primary); }

.kanban-card-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 8px;
  overflow: hidden;
}
.kanban-card-meta span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.kanban-card-meta-sep { flex-shrink: 0; opacity: 0.4; }

.kanban-card-footer {
  display: flex;
  align-items: center;
  gap: 6px;
}

.kanban-view-btn {
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--bg);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
}
.kanban-view-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* Mobile card nav (arrows + status picker) — hidden on desktop */
.kanban-card-nav { display: none; }

/* ===== Status Picker Modal (Mobile Bottom Sheet) ===== */
.status-picker-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 2000;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.status-picker-sheet {
  background: var(--surface);
  border-radius: 16px 16px 0 0;
  width: 100%;
  max-width: 500px;
  padding: 8px 0 env(safe-area-inset-bottom, 16px);
  animation: slideUp 0.3s ease;
}

.status-picker-handle {
  width: 36px;
  height: 4px;
  background: var(--border);
  border-radius: 2px;
  margin: 8px auto 12px;
}

.status-picker-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  padding: 0 20px 12px;
  border-bottom: 1px solid var(--border);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-picker-options {
  padding: 8px 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.status-picker-option {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 12px;
  border: none;
  border-radius: 10px;
  background: none;
  color: var(--text);
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  width: 100%;
  text-align: left;
  transition: background 0.15s;
}
.status-picker-option:hover { background: var(--surface-hover); }

.status-picker-option .kanban-column-dot {
  width: 10px;
  height: 10px;
}

.status-picker-option-current {
  opacity: 0.4;
  cursor: default;
  pointer-events: none;
}

.status-picker-current-label {
  margin-left: auto;
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

@keyframes slideUp {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ===== Kanban Empty Column ===== */
.kanban-empty {
  text-align: center;
  padding: 24px 8px;
  color: var(--text-muted);
  font-size: 12px;
  opacity: 0.5;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ===== Responsive ===== */
@media (min-width: 1400px) {
  .kanban-column {
    flex: 1 1 280px;
    max-width: 320px;
  }
}

@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .hamburger { display: flex; }
  .main-content { margin-left: 0; padding: 60px 16px 16px; }
  .filters {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }
  .filter-input {
    grid-column: 1 / -1;
    max-width: 100%;
    min-width: 0;
  }
  .filter-select { min-width: 0; }
  .filters .btn { grid-column: 1 / -1; }
  .detail-grid { grid-template-columns: 1fr; }
  .form-inline { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .page-header h1 { font-size: 20px; }

  /* Kanban mobile */
  .kanban-board {
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    gap: 12px;
    padding: 0 4px 16px;
  }
  .kanban-column {
    flex: 0 0 85vw;
    min-width: 85vw;
    scroll-snap-align: start;
    max-height: calc(100vh - 280px);
  }
  .kanban-column.collapsed {
    flex: 0 0 52px;
    min-width: 52px;
    scroll-snap-align: start;
  }
  .kanban-card { cursor: default; }
  .kanban-card-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
  }
  .kanban-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 28px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--bg);
    color: var(--text-muted);
    cursor: pointer;
    font-size: 14px;
    transition: all 0.15s;
  }
  .kanban-nav-btn:hover { border-color: var(--primary); color: var(--primary); }
  .kanban-nav-btn:disabled { opacity: 0.25; pointer-events: none; }
  .kanban-more-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 28px;
    border: 1px solid var(--border);
    border-radius: 6px;
    background: var(--bg);
    color: var(--text-muted);
    cursor: pointer;
    font-size: 16px;
    letter-spacing: 1px;
    transition: all 0.15s;
  }
  .kanban-more-btn:hover { border-color: var(--primary); color: var(--primary); }
}

@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .login-card { padding: 28px 20px; }
}
