/* ============================================================
   RecrutaHub — Design System
   Inspirado em Linear, Vercel, Notion
   ============================================================ */

/* ─── Variables (Light Mode) ─────────────────────────────── */
:root {
  --bg: #f9fafb;
  --bg-2: #ffffff;
  --bg-3: #f3f4f6;
  --bg-sidebar: #111827;
  --border: #e5e7eb;
  --border-2: #d1d5db;
  --text: #111827;
  --text-2: #6b7280;
  --text-3: #9ca3af;
  --text-sidebar: #d1d5db;
  --text-sidebar-active: #ffffff;
  --accent: #6366f1;
  --accent-hover: #4f46e5;
  --accent-light: #eef2ff;
  --accent-text: #4f46e5;
  --success: #10b981;
  --success-light: #d1fae5;
  --success-text: #065f46;
  --warning: #f59e0b;
  --warning-light: #fef3c7;
  --warning-text: #92400e;
  --danger: #ef4444;
  --danger-light: #fee2e2;
  --danger-text: #991b1b;
  --info: #3b82f6;
  --info-light: #dbeafe;
  --info-text: #1e40af;
  --purple: #8b5cf6;
  --purple-light: #ede9fe;
  --purple-text: #5b21b6;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04);
  --shadow: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -1px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -2px rgba(0,0,0,0.04);
  --radius: 10px;
  --radius-sm: 6px;
  --radius-lg: 16px;
  --sidebar-w: 240px;
}

/* ─── Dark Mode ──────────────────────────────────────────── */
[data-theme="dark"] {
  --bg: #0f172a;
  --bg-2: #1e293b;
  --bg-3: #0f172a;
  --bg-sidebar: #0d1117;
  --border: #1e293b;
  --border-2: #334155;
  --text: #f1f5f9;
  --text-2: #94a3b8;
  --text-3: #64748b;
  --text-sidebar: #94a3b8;
  --text-sidebar-active: #ffffff;
  --accent: #818cf8;
  --accent-hover: #6366f1;
  --accent-light: #1e1b4b;
  --accent-text: #a5b4fc;
  --success: #34d399;
  --success-light: #064e3b;
  --success-text: #6ee7b7;
  --warning: #fbbf24;
  --warning-light: #451a03;
  --warning-text: #fde68a;
  --danger: #f87171;
  --danger-light: #450a0a;
  --danger-text: #fca5a5;
  --info: #60a5fa;
  --info-light: #1e3a5f;
  --info-text: #93c5fd;
  --purple: #a78bfa;
  --purple-light: #2e1065;
  --purple-text: #c4b5fd;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.3);
  --shadow: 0 4px 6px -1px rgba(0,0,0,0.3);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.4);
}

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

html { font-size: 16px; scroll-behavior: smooth; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

input, select, textarea {
  font-family: inherit;
  font-size: 0.9375rem;
  line-height: 1.5;
}

/* ─── Sidebar ────────────────────────────────────────────── */
.sidebar {
  position: fixed;
  left: 0; top: 0;
  width: var(--sidebar-w);
  height: 100vh;
  background: var(--bg-sidebar);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: transform 0.25s ease;
}

.sidebar-header {
  padding: 20px 16px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
}

.sidebar-close {
  display: none;
  background: none;
  border: none;
  color: var(--text-3);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 4px;
}

.sidebar-nav {
  flex: 1;
  padding: 12px 8px;
  overflow-y: auto;
}

.sidebar-footer {
  padding: 8px;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-sidebar);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
  text-decoration: none;
  transition: all 0.15s;
}

.nav-item:hover {
  background: rgba(255,255,255,0.07);
  color: #fff;
  text-decoration: none;
}

.nav-item.active {
  background: rgba(99,102,241,0.2);
  color: var(--text-sidebar-active);
}

.nav-item i { width: 18px; text-align: center; font-size: 0.875rem; }

.logout-btn { color: #f87171; }
.logout-btn:hover { background: rgba(248,113,113,0.1); color: #fca5a5; }

/* ─── Mobile Header ─────────────────────────────────────── */
.mobile-header {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0;
  height: 56px;
  background: var(--bg-sidebar);
  z-index: 50;
  padding: 0 16px;
  align-items: center;
  justify-content: space-between;
}

.mobile-logo {
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
}

.hamburger {
  background: none;
  border: none;
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 6px;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  z-index: 90;
}

.sidebar-overlay.active { display: block; }

/* ─── Main Content ───────────────────────────────────────── */
.main-content {
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  padding: 32px;
}

/* ─── Page Header ────────────────────────────────────────── */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 28px;
}

.page-header-left {
  display: flex;
  align-items: flex-start;
  gap: 16px;
}

.page-title {
  font-size: 1.625rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.2;
}

.page-subtitle {
  color: var(--text-2);
  font-size: 0.9rem;
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.header-actions { display: flex; gap: 10px; align-items: center; }

.section-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 28px 0 16px;
}

.section-header h3 {
  font-size: 1.125rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ─── Buttons ────────────────────────────────────────────── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  text-decoration: none;
  white-space: nowrap;
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: #fff;
  text-decoration: none;
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}

.btn-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  background: var(--bg-3);
  color: var(--text);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-secondary:hover {
  background: var(--border);
  transform: translateY(-1px);
}

.btn-back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  background: transparent;
  color: var(--text-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  text-decoration: none;
  white-space: nowrap;
  margin-top: 4px;
}

.btn-back:hover { color: var(--text); border-color: var(--border-2); text-decoration: none; }

.btn-danger-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  background: transparent;
  color: var(--danger);
  border: 1px solid var(--danger);
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}

.btn-danger-outline:hover { background: var(--danger-light); }
.btn-danger-outline.sm { padding: 6px 12px; font-size: 0.8rem; }

.full-width { width: 100%; justify-content: center; }
.mt-16 { margin-top: 16px; }

/* ─── Badges ─────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 100px;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.badge-green { background: var(--success-light); color: var(--success-text); }
.badge-blue { background: var(--info-light); color: var(--info-text); }
.badge-yellow { background: var(--warning-light); color: var(--warning-text); }
.badge-red { background: var(--danger-light); color: var(--danger-text); }
.badge-gray { background: var(--bg-3); color: var(--text-2); border: 1px solid var(--border); }
.badge-purple { background: var(--purple-light); color: var(--purple-text); }

.count-badge {
  background: var(--accent-light);
  color: var(--accent-text);
  border-radius: 100px;
  padding: 2px 10px;
  font-size: 0.8rem;
  font-weight: 600;
}

/* ─── Vagas Grid ─────────────────────────────────────────── */
.vagas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
}

.vaga-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  cursor: pointer;
  transition: all 0.2s;
  box-shadow: var(--shadow-sm);
}

.vaga-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.vaga-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}

.vaga-area-icon {
  width: 38px; height: 38px;
  background: var(--accent-light);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent-text);
  font-size: 1.1rem;
}

.vaga-card-title {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
  line-height: 1.3;
}

.vaga-card-area {
  font-size: 0.8rem;
  color: var(--text-2);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.vaga-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.vaga-candidates {
  font-size: 0.8rem;
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: 5px;
}

.vaga-date { font-size: 0.775rem; color: var(--text-3); }

/* ─── Vaga Descrição Card ────────────────────────────────── */
.vaga-descricao-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}

.vaga-descricao-card h4 {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.vaga-descricao-card p {
  font-size: 0.9375rem;
  color: var(--text);
  line-height: 1.7;
  white-space: pre-line;
  margin-bottom: 16px;
}

.vaga-link-row, .vaga-link-row-standalone {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.vaga-link-row-standalone {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 20px;
  margin-bottom: 16px;
}

.vaga-link-label {
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-2);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* ─── Link Copy Box ──────────────────────────────────────── */
.link-copy-box {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-3);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  padding: 7px 12px;
  cursor: pointer;
  transition: all 0.15s;
  flex: 1;
  min-width: 0;
}

.link-copy-box:hover { border-color: var(--accent); background: var(--accent-light); }
.link-copy-box.copied { border-color: var(--success); background: var(--success-light); }
.link-copy-box.full { width: 100%; }

.link-text {
  font-size: 0.8rem;
  color: var(--text-2);
  font-family: 'Courier New', monospace;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
}

.copy-btn {
  background: none;
  border: none;
  color: var(--text-2);
  cursor: pointer;
  padding: 2px 4px;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.copy-btn:hover { color: var(--accent); }

/* ─── Kanban Board ───────────────────────────────────────── */
.kanban-board {
  display: grid;
  grid-template-columns: repeat(6, minmax(200px, 1fr));
  gap: 12px;
  overflow-x: auto;
  padding-bottom: 16px;
}

.kanban-col {
  background: var(--bg-3);
  border-radius: var(--radius);
  min-height: 200px;
  display: flex;
  flex-direction: column;
}

.kanban-col-header {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 12px 14px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-2);
  border-bottom: 1px solid var(--border);
}

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

.kanban-status-dot.badge-green { background: var(--success); }
.kanban-status-dot.badge-blue { background: var(--info); }
.kanban-status-dot.badge-yellow { background: var(--warning); }
.kanban-status-dot.badge-purple { background: var(--purple); }
.kanban-status-dot.badge-red { background: var(--danger); }
.kanban-status-dot.badge-gray { background: var(--text-3); }

.kanban-count {
  background: var(--border);
  border-radius: 100px;
  padding: 1px 7px;
  font-size: 0.7rem;
  margin-left: auto;
  font-weight: 600;
}

.kanban-cards { padding: 10px; display: flex; flex-direction: column; gap: 8px; flex: 1; }

.kanban-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: var(--shadow-sm);
}

.kanban-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
  border-color: var(--accent);
}

.kanban-card-name { font-size: 0.875rem; font-weight: 600; color: var(--text); margin-bottom: 6px; }

.kanban-card-meta { font-size: 0.77rem; color: var(--text-2); margin-bottom: 8px; }
.kanban-card-meta span { display: flex; align-items: center; gap: 4px; }

.kanban-card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.72rem;
  color: var(--text-3);
}

/* ─── Forms ──────────────────────────────────────────────── */
.field-group { margin-bottom: 16px; }

.field-group label {
  display: block;
  font-size: 0.8375rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
}

.field-group input,
.field-group select,
.field-group textarea {
  width: 100%;
  padding: 10px 13px;
  background: var(--bg);
  border: 1.5px solid var(--border-2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.9375rem;
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
}

.field-group input:focus,
.field-group select:focus,
.field-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(99,102,241,0.12);
}

.field-group textarea { resize: vertical; min-height: 90px; }

.field-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%236b7280'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 18px;
  padding-right: 38px;
  cursor: pointer;
}

.error-msg {
  background: var(--danger-light);
  color: var(--danger-text);
  border: 1px solid var(--danger);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  font-size: 0.85rem;
  margin-bottom: 14px;
}

.obs-hint { color: var(--text-3); font-size: 0.75rem; font-weight: 400; }

/* ─── Modal ──────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.45);
  backdrop-filter: blur(3px);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.modal {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  width: 100%;
  max-width: 580px;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-lg);
  animation: modalIn 0.2s ease;
}

@keyframes modalIn {
  from { opacity: 0; transform: scale(0.95) translateY(10px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
}

.modal-header h3 { font-size: 1rem; font-weight: 700; }

.modal-close {
  background: none;
  border: none;
  color: var(--text-2);
  cursor: pointer;
  font-size: 1.1rem;
  padding: 4px;
  border-radius: 4px;
  transition: all 0.15s;
}

.modal-close:hover { background: var(--bg-3); color: var(--text); }

.modal-body {
  padding: 22px 24px;
  overflow-y: auto;
  flex: 1;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}

/* ─── Candidato Panel ────────────────────────────────────── */
.candidato-panel { display: flex; flex-direction: column; gap: 16px; }

.candidato-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.info-item { display: flex; flex-direction: column; gap: 3px; }
.info-item label { font-size: 0.75rem; font-weight: 600; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.04em; }
.info-item span, .info-item a { font-size: 0.9rem; color: var(--text); }
.info-item a:hover { color: var(--accent); }

.candidato-link-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.candidato-link-row label {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-2);
  display: flex;
  align-items: center;
  gap: 5px;
}

.respostas-section {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.respostas-section h4 {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--accent-text);
}

.resposta-item { margin-bottom: 16px; padding-bottom: 16px; border-bottom: 1px solid var(--border); }
.resposta-item:last-child { margin-bottom: 0; padding-bottom: 0; border-bottom: none; }

.resposta-pergunta {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 5px;
}

.resposta-texto {
  font-size: 0.875rem;
  color: var(--text);
  line-height: 1.6;
  white-space: pre-line;
}

.respostas-pendente {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px;
  background: var(--warning-light);
  border-radius: var(--radius-sm);
  color: var(--warning-text);
  font-size: 0.875rem;
}

.candidato-panel-footer {
  padding-top: 8px;
  border-top: 1px solid var(--border);
}

/* ─── Link Result (cadastro candidato) ───────────────────── */
.link-result-box {
  background: var(--success-light);
  border: 1px solid var(--success);
  border-radius: var(--radius);
  padding: 16px;
  margin-bottom: 16px;
}

.link-result-box p { color: var(--success-text); font-size: 0.875rem; margin-bottom: 8px; }
.link-result-box p:first-child { font-weight: 600; display: flex; align-items: center; gap: 6px; }
.link-result-label { font-weight: 600 !important; }
.link-result-hint { font-size: 0.78rem !important; color: var(--text-2) !important; margin-top: 8px !important; }

/* ─── Auth ────────────────────────────────────────────────── */
.auth-body {
  background: var(--bg);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.auth-container { width: 100%; max-width: 400px; }

.auth-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  box-shadow: var(--shadow-lg);
}

.auth-logo {
  text-align: center;
  margin-bottom: 32px;
}

.auth-logo h1 { font-size: 1.625rem; font-weight: 800; color: var(--text); margin: 10px 0 4px; }
.auth-logo p { color: var(--text-2); font-size: 0.875rem; }

/* ─── Logo Icon ──────────────────────────────────────────── */
.logo-icon {
  width: 52px; height: 52px;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: 1.5rem;
  margin: 0 auto;
  box-shadow: 0 4px 12px rgba(99,102,241,0.3);
}

.logo-icon.sm {
  width: 32px; height: 32px;
  border-radius: 8px;
  font-size: 0.9rem;
  margin: 0;
}

/* ─── Toast ──────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  padding: 12px 20px;
  background: var(--text);
  color: var(--bg-2);
  border-radius: var(--radius);
  font-size: 0.875rem;
  font-weight: 500;
  z-index: 300;
  box-shadow: var(--shadow-lg);
  animation: toastIn 0.2s ease;
  max-width: 320px;
}

@keyframes toastIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.toast.error { background: var(--danger); color: #fff; }
.toast.success { background: var(--success); color: #fff; }

/* ─── Empty & Loading ────────────────────────────────────── */
.loading-center {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-2);
  font-size: 1.1rem;
}

.empty-state {
  text-align: center;
  padding: 64px 20px;
  color: var(--text-2);
}

.empty-state.sm { padding: 40px 20px; }

.empty-state i {
  font-size: 2.5rem;
  color: var(--text-3);
  margin-bottom: 16px;
  display: block;
}

.empty-state h3 { font-size: 1.125rem; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.empty-state p { font-size: 0.9rem; max-width: 320px; margin: 0 auto 20px; }

.error-state {
  text-align: center;
  padding: 64px 20px;
  color: var(--text-2);
}

.error-state i { font-size: 2.5rem; color: var(--danger); margin-bottom: 16px; display: block; }
.error-state h3 { font-size: 1.125rem; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.error-state p { font-size: 0.9rem; }

/* ─── Public Pages ───────────────────────────────────────── */
.public-body {
  background: var(--bg);
  min-height: 100vh;
  padding-bottom: 48px;
}

.public-container { max-width: 640px; margin: 0 auto; padding: 0 16px; }

.public-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
  margin-bottom: 28px;
}

.public-brand { font-weight: 700; font-size: 1rem; color: var(--text); }

.public-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow);
}

/* ─── Vaga Pública ───────────────────────────────────────── */
.vaga-public-header { margin-bottom: 20px; }
.vaga-public-header h2 { font-size: 1.5rem; font-weight: 800; margin: 10px 0 6px; }
.vaga-area-pub { font-size: 0.875rem; color: var(--text-2); display: flex; align-items: center; gap: 5px; }

.vaga-descricao-pub {
  background: var(--bg-3);
  border-radius: var(--radius-sm);
  padding: 16px;
  margin-bottom: 24px;
}

.vaga-descricao-pub p {
  font-size: 0.9375rem;
  color: var(--text);
  line-height: 1.7;
  white-space: pre-line;
}

.inscricao-form-header {
  margin-bottom: 20px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.inscricao-form-header h3 { font-size: 1.125rem; font-weight: 700; margin-bottom: 6px; }
.inscricao-form-header p { font-size: 0.875rem; color: var(--text-2); }

/* ─── Success Card ───────────────────────────────────────── */
.success-card { text-align: center; }
.success-icon { font-size: 3rem; color: var(--success); margin-bottom: 16px; }
.success-card h2 { font-size: 1.5rem; font-weight: 800; margin-bottom: 10px; }
.success-card p { color: var(--text-2); font-size: 0.9375rem; margin-bottom: 12px; }
.success-card strong { color: var(--text); }

.candidato-link-section {
  background: var(--bg-3);
  border-radius: var(--radius);
  padding: 16px;
  margin: 20px 0;
  text-align: left;
}

.candidato-link-section p { font-size: 0.875rem; color: var(--text-2); margin-bottom: 10px; }
.candidato-link-section strong { color: var(--text); }
.link-hint { font-size: 0.8rem !important; color: var(--text-2) !important; display: flex; gap: 6px; align-items: flex-start; margin-top: 10px !important; }
.link-hint i { margin-top: 2px; flex-shrink: 0; color: var(--accent); }

/* ─── Candidato Público ──────────────────────────────────── */
.candidato-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.candidato-avatar {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  font-size: 1.5rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

.candidato-header h2 { font-size: 1.25rem; font-weight: 700; margin-bottom: 4px; }
.candidato-vaga { font-size: 0.85rem; color: var(--text-2); display: flex; align-items: center; gap: 5px; }

.status-section { margin-bottom: 28px; }
.status-section h3 { font-size: 0.9rem; font-weight: 600; color: var(--text-2); margin-bottom: 16px; text-transform: uppercase; letter-spacing: 0.04em; }

/* ─── Timeline ───────────────────────────────────────────── */
.timeline {
  display: flex;
  align-items: flex-start;
  gap: 0;
  overflow-x: auto;
  padding-bottom: 8px;
}

.timeline-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  min-width: 80px;
  position: relative;
}

.step-dot {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  z-index: 1;
  position: relative;
  flex-shrink: 0;
  font-size: 0.75rem;
  font-weight: 700;
}

.step-line {
  position: absolute;
  top: 15px;
  left: 50%;
  right: -50%;
  height: 2px;
  z-index: 0;
}

.step-label {
  font-size: 0.7rem;
  text-align: center;
  margin-top: 8px;
  line-height: 1.3;
  padding: 0 4px;
  font-weight: 500;
}

/* Done steps */
.step-done .step-dot {
  background: var(--success);
  color: #fff;
}
.step-done .step-line { background: var(--success); }
.step-done .step-label { color: var(--text-2); }

/* Current step */
.step-current .step-dot {
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-light), 0 0 0 6px rgba(99,102,241,0.15);
}
.step-current .step-line { background: var(--border-2); }
.step-current .step-label { color: var(--accent-text); font-weight: 700; }

/* Pending steps */
.step-pending .step-dot {
  background: var(--bg-3);
  border: 2px solid var(--border-2);
}
.step-pending .step-line { background: var(--border); }
.step-pending .step-label { color: var(--text-3); }

/* Pulse animation for current */
.step-pulse {
  width: 10px; height: 10px;
  background: #fff;
  border-radius: 50%;
  animation: pulse 1.5s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.7; transform: scale(0.8); }
}

/* Reprovado */
.timeline-reprovado {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--danger-light);
  border: 1px solid var(--danger);
  border-radius: var(--radius);
  padding: 14px 18px;
  width: 100%;
}

.timeline-reprovado-icon { font-size: 1.5rem; color: var(--danger); flex-shrink: 0; }
.timeline-reprovado-text strong { display: block; color: var(--danger-text); font-size: 0.9rem; margin-bottom: 3px; }
.timeline-reprovado-text p { color: var(--danger-text); font-size: 0.8rem; opacity: 0.8; }

/* ─── Comportamental Form (público) ─────────────────────── */
.comportamental-section {
  border-top: 1px solid var(--border);
  padding-top: 24px;
}

.comportamental-header {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  margin-bottom: 20px;
}

.comportamental-header i { font-size: 1.5rem; color: var(--accent); margin-top: 3px; flex-shrink: 0; }
.comportamental-header h3 { font-size: 1rem; font-weight: 700; margin-bottom: 4px; }
.comportamental-header p { font-size: 0.85rem; color: var(--text-2); line-height: 1.5; }

.respostas-ok {
  text-align: center;
  padding: 24px;
  background: var(--success-light);
  border-radius: var(--radius);
  border: 1px solid var(--success);
}

.respostas-ok i { font-size: 2.5rem; color: var(--success); margin-bottom: 12px; display: block; }
.respostas-ok h3 { font-size: 1.1rem; font-weight: 700; color: var(--success-text); margin-bottom: 8px; }
.respostas-ok p { font-size: 0.875rem; color: var(--success-text); }

/* ─── Responsive ─────────────────────────────────────────── */
@media (max-width: 768px) {
  .mobile-header { display: flex; }
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-close { display: block; }
  .main-content { margin-left: 0; padding: 72px 16px 24px; }
  .page-header { flex-direction: column; align-items: flex-start; }
  .page-header-left { flex-direction: column; gap: 10px; }
  .vagas-grid { grid-template-columns: 1fr; }
  .kanban-board { grid-template-columns: repeat(2, 280px); }
  .modal { max-width: 100%; border-radius: var(--radius) var(--radius) 0 0; align-self: flex-end; }
  .modal-overlay { align-items: flex-end; }
  .candidato-info-grid { grid-template-columns: 1fr; }
  .header-actions { flex-wrap: wrap; }
  .toast { bottom: 16px; right: 16px; left: 16px; }
}

@media (max-width: 480px) {
  .timeline { gap: 0; }
  .step-label { font-size: 0.65rem; }
  .step-dot { width: 26px; height: 26px; }
  .auth-card { padding: 28px 20px; }
  .public-card { padding: 20px; }
}

/* ═══════════════════════════════════════════════════════════════
   V2 — NOVOS COMPONENTES
   ═══════════════════════════════════════════════════════════════ */

/* ─── Tabs (abas da vaga) ────────────────────────────────── */
.tabs {
  display: flex;
  gap: 4px;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--border);
  padding-bottom: 0;
}

.tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 18px;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  color: var(--text-2);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  border-radius: var(--radius-sm) var(--radius-sm) 0 0;
}

.tab-btn:hover { color: var(--text); background: var(--bg-3); }
.tab-btn.active { color: var(--accent-text); border-bottom-color: var(--accent); font-weight: 600; }

.tab-badge {
  background: var(--accent-light);
  color: var(--accent-text);
  border-radius: 100px;
  padding: 1px 7px;
  font-size: 0.72rem;
  font-weight: 700;
}

.hidden { display: none !important; }

/* ─── Info Card da Vaga ──────────────────────────────────── */
.info-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.info-card-row {
  display: flex;
  gap: 24px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.info-card-field { display: flex; flex-direction: column; gap: 4px; }
.info-card-field label { font-size: 0.72rem; font-weight: 700; color: var(--text-3); text-transform: uppercase; letter-spacing: 0.05em; }
.info-card-field span { font-size: 0.9rem; color: var(--text); }

.info-card-body { margin-bottom: 20px; }
.info-card-body label { font-size: 0.78rem; font-weight: 600; color: var(--text-2); display: block; margin-bottom: 8px; }

.descricao-text {
  font-size: 0.9375rem;
  line-height: 1.75;
  color: var(--text);
  white-space: pre-line;
  background: var(--bg-3);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}

.info-empty { font-size: 0.875rem; color: var(--text-3); padding: 12px 0; }

.info-card-links {
  border-top: 1px solid var(--border);
  padding-top: 16px;
}

.link-row-label { font-size: 0.8rem; font-weight: 500; color: var(--text-2); margin-bottom: 8px; display: flex; align-items: center; gap: 5px; }

.info-card-actions { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }

.link-btn { background: none; border: none; color: var(--accent); cursor: pointer; font-size: inherit; text-decoration: underline; padding: 0; }
.link-btn:hover { color: var(--accent-hover); }

/* ─── Botões extras ──────────────────────────────────────── */
.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--bg-3);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-sm);
  color: var(--text-2);
  cursor: pointer;
  font-size: 0.9rem;
  transition: all 0.15s;
  flex-shrink: 0;
}
.btn-icon:hover { color: var(--text); background: var(--border); }

.btn-primary.sm, .btn-secondary.sm { padding: 6px 12px; font-size: 0.8rem; }
.ml-auto { margin-left: auto; }
.mt-24 { margin-top: 24px; }

/* ─── Kanban card v2 (estrelas + tags) ──────────────────── */
.kanban-card-top { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 6px; }
.kanban-card-name { font-size: 0.875rem; font-weight: 600; color: var(--text); }
.kanban-stars { display: flex; gap: 2px; flex-shrink: 0; }
.kanban-stars .fas.fa-star { color: #f59e0b; font-size: 0.72rem; }
.kanban-stars .far.fa-star { color: var(--border-2); font-size: 0.72rem; }

.kanban-tags { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0; }
.tag {
  background: var(--accent-light);
  color: var(--accent-text);
  border-radius: 100px;
  padding: 2px 8px;
  font-size: 0.68rem;
  font-weight: 500;
}

.talent-badge {
  background: var(--warning-light);
  color: var(--warning-text);
  border-radius: 100px;
  padding: 2px 7px;
  font-size: 0.7rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.talent-full-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: var(--warning-light);
  color: var(--warning-text);
  border-radius: 100px;
  padding: 3px 10px;
  font-size: 0.75rem;
  font-weight: 600;
}

/* ─── Estrelas editáveis ─────────────────────────────────── */
.star-icon {
  cursor: pointer;
  font-size: 1.25rem;
  color: var(--border-2);
  transition: color 0.1s, transform 0.1s;
  padding: 2px;
}
.star-icon.active { color: #f59e0b; }
.star-icon:hover { transform: scale(1.2); color: #fbbf24; }

/* ─── Candidato Panel v2 ─────────────────────────────────── */
.candidato-panel { display: flex; flex-direction: column; gap: 18px; }

.cp-header {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border);
}

.cp-header-info { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cp-stars { display: flex; gap: 3px; margin-right: 4px; }

.cp-link-row {
  background: var(--bg-3);
  border-radius: var(--radius-sm);
  padding: 2px;
}

.cp-controls { display: flex; flex-direction: column; gap: 0; }

.cp-footer {
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

/* Checkbox label */
.checkbox-label {
  display: flex !important;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-weight: 500 !important;
}
.checkbox-label input[type=checkbox] { width: 16px; height: 16px; cursor: pointer; accent-color: var(--accent); }
.checkbox-label span { display: flex; align-items: center; gap: 6px; }

/* ─── Notas Feed ─────────────────────────────────────────── */
.notas-section {
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}

.notas-section h4 {
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.nota-form {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
  align-items: flex-end;
}
.nota-form textarea {
  flex: 1;
  padding: 8px 12px;
  background: var(--bg-2);
  border: 1.5px solid var(--border-2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.875rem;
  resize: none;
  outline: none;
  font-family: inherit;
  min-height: 60px;
}
.nota-form textarea:focus { border-color: var(--accent); }

.notas-feed { display: flex; flex-direction: column; gap: 8px; }
.notas-empty { font-size: 0.8rem; color: var(--text-3); text-align: center; padding: 8px; }

.nota-item {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
}

.nota-body { font-size: 0.875rem; color: var(--text); line-height: 1.5; white-space: pre-line; margin-bottom: 6px; }

.nota-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.72rem;
  color: var(--text-3);
}

.nota-del {
  margin-left: auto;
  background: none;
  border: none;
  color: var(--text-3);
  cursor: pointer;
  font-size: 0.7rem;
  padding: 2px 4px;
  border-radius: 3px;
  transition: all 0.1s;
}
.nota-del:hover { color: var(--danger); background: var(--danger-light); }

/* ─── Banco de Talentos ──────────────────────────────────── */
.filter-bar {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}
.filter-bar input, .filter-bar select {
  padding: 9px 13px;
  background: var(--bg-2);
  border: 1.5px solid var(--border-2);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 0.875rem;
  outline: none;
  font-family: inherit;
  transition: border-color 0.15s;
}
.filter-bar input { flex: 1; min-width: 200px; }
.filter-bar input:focus, .filter-bar select:focus { border-color: var(--accent); }
.filter-bar select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20' fill='%236b7280'%3E%3Cpath fill-rule='evenodd' d='M5.293 7.293a1 1 0 011.414 0L10 10.586l3.293-3.293a1 1 0 111.414 1.414l-4 4a1 1 0 01-1.414 0l-4-4a1 1 0 010-1.414z' clip-rule='evenodd'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 16px;
  padding-right: 32px;
  cursor: pointer;
}

.talentos-grid { display: flex; flex-direction: column; gap: 10px; }

.talento-card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  transition: all 0.15s;
  box-shadow: var(--shadow-sm);
}
.talento-card:hover { border-color: var(--accent); transform: translateX(3px); box-shadow: var(--shadow); }

.talento-avatar {
  width: 44px; height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent), var(--purple));
  color: #fff;
  font-size: 1.1rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

.talento-info { flex: 1; min-width: 0; }
.talento-nome { font-size: 0.9375rem; font-weight: 600; color: var(--text); margin-bottom: 3px; }
.talento-meta { font-size: 0.78rem; color: var(--text-2); display: flex; align-items: center; gap: 5px; margin-bottom: 2px; }

.talento-stars { display: flex; gap: 2px; flex-shrink: 0; }
.talento-stars .fas.fa-star { color: #f59e0b; font-size: 0.8rem; }
.talento-stars .far.fa-star { color: var(--border-2); font-size: 0.8rem; }

.talento-action { flex-shrink: 0; }

/* ─── Vagas arquivadas ───────────────────────────────────── */
.vaga-card.archived { opacity: 0.75; }
.vaga-card.archived:hover { opacity: 1; }

/* ─── Configurações ──────────────────────────────────────── */
.config-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

.config-section {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.config-section h3 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.config-info {
  background: var(--bg-3);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  margin-bottom: 16px;
}
.config-info p { font-size: 0.85rem; color: var(--text-2); margin-bottom: 6px; line-height: 1.5; }
.config-info p:last-child { margin-bottom: 0; }
.config-info a { color: var(--accent); }
.config-info code { background: var(--border); padding: 1px 5px; border-radius: 3px; font-size: 0.8rem; }

.color-picker-row { display: flex; gap: 8px; align-items: center; }
.color-picker-row input[type=color] {
  width: 44px;
  height: 40px;
  padding: 2px;
  border: 1.5px solid var(--border-2);
  border-radius: var(--radius-sm);
  cursor: pointer;
  flex-shrink: 0;
}
.color-picker-row input[type=text] { flex: 1; }

/* ─── Auth extras ────────────────────────────────────────── */
.auth-footer {
  text-align: center;
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
}
.auth-footer a { color: var(--text-2); display: flex; align-items: center; justify-content: center; gap: 6px; text-decoration: none; }
.auth-footer a:hover { color: var(--accent); }

.auth-info {
  font-size: 0.875rem;
  color: var(--text-2);
  margin-bottom: 20px;
  line-height: 1.5;
  background: var(--bg-3);
  padding: 12px 14px;
  border-radius: var(--radius-sm);
}

.candidato-found-card {
  background: var(--success-light);
  border: 1px solid var(--success);
  border-radius: var(--radius);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.candidato-found-card i { font-size: 1.5rem; color: var(--success); flex-shrink: 0; }
.candidato-found-card p { font-size: 0.9rem; color: var(--success-text); font-weight: 500; }

/* ─── Atualizar contato (público) ────────────────────────── */
.update-contato-section {
  border-top: 1px solid var(--border);
  padding-top: 16px;
  margin-top: 8px;
}
.update-contato-section summary {
  font-size: 0.85rem;
  color: var(--text-2);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 0;
  list-style: none;
  user-select: none;
}
.update-contato-section summary::-webkit-details-marker { display: none; }
.update-contato-section summary:hover { color: var(--accent); }
.update-contato-form {
  padding: 16px 0 0;
}
.update-contato-form p { font-size: 0.82rem; color: var(--text-2); margin-bottom: 14px; }

.success-inline {
  font-size: 0.85rem;
  color: var(--success-text);
  background: var(--success-light);
  border: 1px solid var(--success);
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  margin-bottom: 10px;
  display: block;
}

/* ─── Modal Wide ─────────────────────────────────────────── */
.modal-wide { max-width: 720px; }

/* ─── Public page extras ─────────────────────────────────── */
.ml-auto { margin-left: auto; }

/* ─── Responsive v2 ──────────────────────────────────────── */
@media (max-width: 900px) {
  .config-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .tabs { overflow-x: auto; white-space: nowrap; }
  .tab-btn { flex-shrink: 0; }
  .talento-card { flex-wrap: wrap; }
  .talento-action { width: 100%; }
  .info-card-actions { flex-direction: column; }
}


/* ═══════════════════════════════════════════════════════════════
   ABA PERFIL — Editor de Perguntas da Vaga
   ═══════════════════════════════════════════════════════════════ */

/* Cores por categoria */
.cat-comportamental { background: #ede9fe; color: #7c3aed; border-color: #c4b5fd; }
.cat-skills         { background: #dbeafe; color: #1d4ed8; border-color: #93c5fd; }
.cat-motivacional   { background: #fef9c3; color: #a16207; border-color: #fde047; }
.cat-fit            { background: #dcfce7; color: #166534; border-color: #86efac; }
.cat-tecnica        { background: #fee2e2; color: #b91c1c; border-color: #fca5a5; }
.cat-outro          { background: var(--bg-2); color: var(--text-2); border-color: var(--border); }

[data-theme="dark"] .cat-comportamental { background: #3b1d8a22; color: #c4b5fd; border-color: #7c3aed44; }
[data-theme="dark"] .cat-skills         { background: #1e3a5f22; color: #93c5fd; border-color: #1d4ed844; }
[data-theme="dark"] .cat-motivacional   { background: #713f1222; color: #fde047; border-color: #a1620744; }
[data-theme="dark"] .cat-fit            { background: #14532d22; color: #86efac; border-color: #16653444; }
[data-theme="dark"] .cat-tecnica        { background: #7f1d1d22; color: #fca5a5; border-color: #b91c1c44; }

/* Tab badge accent */
.tab-badge-accent { background: var(--accent) !important; color: #fff !important; }

/* ── Editor principal ── */
.perfil-editor { display: flex; flex-direction: column; gap: 20px; padding-bottom: 40px; }

.perfil-header {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 16px;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px;
  padding: 20px 24px;
}
.perfil-header-info h3 { font-size: 1rem; font-weight: 700; color: var(--text-1); margin: 0 0 4px; }
.perfil-header-info h3 i { color: var(--accent); margin-right: 8px; }
.perfil-header-info p { font-size: 0.85rem; color: var(--text-2); margin: 0 0 12px; max-width: 560px; }

.perfil-cats-resumo { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.perfil-cat-pill {
  display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px;
  border-radius: 999px; font-size: 0.75rem; font-weight: 600; border: 1px solid transparent;
}
.perfil-cat-pill i { font-size: 0.55rem; }
.perfil-cat-pill strong { font-weight: 700; }

.perfil-preview-bar {
  display: flex; justify-content: space-between; align-items: center;
  background: var(--bg-2); border: 1px solid var(--border); border-radius: 8px;
  padding: 10px 16px; font-size: 0.85rem; color: var(--text-2);
}

.perfil-empty-state {
  text-align: center; padding: 60px 24px;
  background: var(--bg-card); border: 2px dashed var(--border); border-radius: 12px;
  color: var(--text-3);
}
.perfil-empty-state i { font-size: 2.5rem; margin-bottom: 16px; display: block; opacity: 0.4; }
.perfil-empty-state h3 { font-size: 1.1rem; color: var(--text-1); margin-bottom: 8px; }
.perfil-empty-state p { font-size: 0.875rem; line-height: 1.6; max-width: 400px; margin: 0 auto; }

.perguntas-lista { display: flex; flex-direction: column; gap: 10px; }

.perfil-add-bottom { display: flex; justify-content: center; }

/* ── Cards de pergunta ── */
.pergunta-card {
  display: flex; align-items: stretch; gap: 0;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 12px;
  overflow: hidden; transition: box-shadow 0.15s, border-color 0.15s;
}
.pergunta-card:hover { border-color: var(--accent); box-shadow: 0 4px 16px rgba(99,102,241,0.1); }

.pq-drag-handle {
  display: flex; align-items: center; justify-content: center;
  width: 36px; flex-shrink: 0; cursor: grab;
  background: var(--bg-2); color: var(--text-3);
  border-right: 1px solid var(--border); font-size: 0.85rem;
  transition: background 0.15s;
}
.pq-drag-handle:hover { background: var(--bg-3); color: var(--text-2); }

.pq-body { flex: 1; padding: 16px 18px; min-width: 0; }

.pq-meta {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 10px;
}
.pq-num {
  width: 24px; height: 24px; border-radius: 50%;
  background: var(--accent); color: #fff;
  font-size: 0.72rem; font-weight: 700;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.pq-cat {
  display: inline-flex; align-items: center; padding: 2px 9px;
  border-radius: 999px; font-size: 0.72rem; font-weight: 600; border: 1px solid transparent;
}
.pq-tipo { font-size: 0.75rem; color: var(--text-3); display: flex; align-items: center; gap: 4px; }
.pq-tipo i { font-size: 0.7rem; }
.pq-obrig { font-size: 0.72rem; color: #e11d48; display: flex; align-items: center; gap: 3px; }
.pq-obrig i { font-size: 0.55rem; }
.pq-opcional { font-size: 0.72rem; color: var(--text-3); }

.pq-texto {
  font-size: 0.9rem; color: var(--text-1); line-height: 1.5;
  margin: 0 0 12px; font-weight: 500;
}

.pq-preview-input {
  font-size: 0.78rem; color: var(--text-3); padding: 8px 12px;
  border: 1px dashed var(--border); border-radius: 6px;
  background: var(--bg-2); display: flex; align-items: center; gap: 6px;
}
.pq-preview-warn { color: #f59e0b; border-color: #f59e0b44; }
.pq-preview-options { display: flex; flex-wrap: wrap; gap: 6px; }
.pq-opt {
  font-size: 0.78rem; padding: 4px 12px; border-radius: 6px;
  background: var(--bg-2); border: 1px solid var(--border); color: var(--text-2);
}
.pq-opt-sim { background: #dcfce7; color: #166534; border-color: #86efac; }
.pq-opt-nao { background: #fee2e2; color: #b91c1c; border-color: #fca5a5; }
[data-theme="dark"] .pq-opt-sim { background: #14532d22; color: #86efac; }
[data-theme="dark"] .pq-opt-nao { background: #7f1d1d22; color: #fca5a5; }

.pq-preview-escala { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.pq-escala-dot {
  width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.75rem; font-weight: 600; color: var(--text-2); background: var(--bg-2);
}
.pq-escala-label { font-size: 0.72rem; color: var(--text-3); margin-left: 4px; }

.pq-actions {
  display: flex; flex-direction: column; justify-content: center; gap: 4px;
  padding: 12px 12px; flex-shrink: 0;
}
.pq-btn-edit, .pq-btn-del {
  width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; font-size: 0.78rem; transition: all 0.15s;
  background: var(--bg-2); color: var(--text-2);
}
.pq-btn-edit:hover { background: var(--accent); color: #fff; border-color: var(--accent); }
.pq-btn-del:hover { background: #fee2e2; color: #b91c1c; border-color: #fca5a5; }
[data-theme="dark"] .pq-btn-del:hover { background: #7f1d1d22; color: #fca5a5; border-color: #b91c1c44; }

/* ── Modal formulário nova pergunta ── */
.pq-modal-form { display: flex; flex-direction: column; gap: 18px; }

.pq-cat-grid { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.pq-cat-radio input[type="radio"] { display: none; }
.pq-cat-label {
  display: inline-flex; align-items: center; padding: 5px 12px;
  border-radius: 999px; font-size: 0.78rem; font-weight: 600;
  cursor: pointer; border: 2px solid transparent; transition: all 0.15s;
  opacity: 0.6;
}
.pq-cat-radio input:checked + .pq-cat-label { opacity: 1; box-shadow: 0 0 0 2px var(--accent); }

.pq-tipo-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 8px; margin-top: 6px; }
@media (max-width: 520px) { .pq-tipo-grid { grid-template-columns: repeat(2,1fr); } }
.pq-tipo-radio input[type="radio"] { display: none; }
.pq-tipo-radio span {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 10px 8px; border-radius: 10px; border: 2px solid var(--border);
  font-size: 0.75rem; font-weight: 600; color: var(--text-2);
  cursor: pointer; text-align: center; transition: all 0.15s; background: var(--bg-2);
}
.pq-tipo-radio span i { font-size: 1.1rem; }
.pq-tipo-radio input:checked + span { border-color: var(--accent); color: var(--accent); background: var(--bg-card); box-shadow: 0 0 0 2px var(--accent)22; }
.pq-tipo-radio:hover span { border-color: var(--accent); }

/* ── Modal preview ── */
.pq-preview-modal { display: flex; flex-direction: column; gap: 16px; }
.pq-preview-subtitle { font-size: 0.83rem; color: var(--text-2); padding: 10px 14px; background: var(--bg-2); border-radius: 8px; margin: 0; }
.pq-preview-form { display: flex; flex-direction: column; gap: 16px; max-height: 60vh; overflow-y: auto; padding-right: 4px; }

.pq-preview-item {
  background: var(--bg-2); border: 1px solid var(--border); border-radius: 10px;
  padding: 14px 16px;
}
.pq-preview-header { display: flex; align-items: center; gap: 6px; margin-bottom: 8px; }
.pq-preview-question { font-size: 0.88rem; font-weight: 600; color: var(--text-1); margin: 0 0 10px; line-height: 1.5; }

.pq-radio-label { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; color: var(--text-2); padding: 4px 0; cursor: pointer; }
.pq-escala-row { display: flex; gap: 8px; }
.pq-escala-label-full { display: flex; flex-direction: column; align-items: center; gap: 4px; cursor: pointer; }
.pq-escala-num {
  width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.85rem; font-weight: 700; color: var(--text-2); background: var(--bg-card);
  transition: all 0.15s;
}
input[type="radio"]:checked + .pq-escala-num { background: var(--accent); color: #fff; border-color: var(--accent); }
.pq-escala-hint { display: flex; justify-content: space-between; font-size: 0.72rem; color: var(--text-3); margin-top: 4px; }

/* Respostas por categoria no painel admin */
.respostas-perfil-section { margin-top: 8px; }
.respostas-cat-group { margin-bottom: 8px; }
.respostas-cat-header { margin-bottom: 6px; }

/* ═══════════════════════════════════════════════════════════════
   PÁGINA PÚBLICA — Formulário de Perfil (candidato)
   ═══════════════════════════════════════════════════════════════ */
.pq-pub-item {
  background: var(--bg-2); border: 1px solid var(--border); border-radius: 10px;
  padding: 16px 18px; margin-bottom: 12px;
}
.pq-pub-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 10px; }
.pq-pub-question { font-size: 0.9rem; font-weight: 600; color: var(--text-1); margin: 0 0 12px; line-height: 1.5; }
.pq-obrig-pub { font-size: 0.72rem; color: #e11d48; display: flex; align-items: center; gap: 3px; }
.pq-obrig-pub i { font-size: 0.55rem; }

/* Radio groups públicos */
.pq-radio-group { display: flex; flex-direction: column; gap: 6px; }
.pq-radio-group .pq-radio-label {
  display: flex; align-items: center; gap: 8px; padding: 8px 12px;
  border: 1px solid var(--border); border-radius: 8px; cursor: pointer;
  font-size: 0.875rem; color: var(--text-2); transition: all 0.15s;
  background: var(--bg-card);
}
.pq-radio-group .pq-radio-label:hover { border-color: var(--accent); color: var(--text-1); }
.pq-radio-group .pq-radio-label input { accent-color: var(--accent); flex-shrink: 0; }
.pq-radio-group .pq-radio-label input:checked { }
.pq-radio-group .pq-radio-label:has(input:checked) { border-color: var(--accent); background: var(--accent)11; color: var(--text-1); font-weight: 500; }

/* Escala pública */
.pq-escala-pub { display: flex; gap: 8px; flex-wrap: wrap; }
.pq-escala-pub-label { display: flex; flex-direction: column; align-items: center; gap: 4px; cursor: pointer; }
.pq-escala-pub-label input[type="radio"] { display: none; }
.pq-escala-pub-num {
  width: 40px; height: 40px; border-radius: 50%;
  border: 2px solid var(--border); background: var(--bg-card);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.9rem; font-weight: 700; color: var(--text-2);
  transition: all 0.15s; cursor: pointer;
}
.pq-escala-pub-label:hover .pq-escala-pub-num { border-color: var(--accent); color: var(--accent); }
.pq-escala-pub-label input:checked + .pq-escala-pub-num { background: var(--accent); color: #fff; border-color: var(--accent); transform: scale(1.1); }

/* ═══════════════════════════════════════════════════════════════
   CAMPOS DE LINK — Currículo e Portfólio (formulário público)
   ═══════════════════════════════════════════════════════════════ */
.field-hint {
  display: block; font-size: 0.75rem; color: var(--text-3);
  margin-top: 4px; line-height: 1.4;
}
.field-optional {
  font-size: 0.72rem; font-weight: 400; color: var(--text-3);
  background: var(--bg-2); border-radius: 4px; padding: 1px 5px;
  margin-left: 4px;
}

/* ═══════════════════════════════════════════════════════════════
   DOCUMENTOS ENVIADOS — Área do candidato
   ═══════════════════════════════════════════════════════════════ */
.docs-section {
  background: var(--bg-2); border: 1px solid var(--border);
  border-radius: 12px; padding: 16px 20px; margin-bottom: 16px;
}
.docs-section h3 {
  font-size: 0.875rem; font-weight: 600; color: var(--text-2);
  margin: 0 0 12px; display: flex; align-items: center; gap: 6px;
}
.docs-list { display: flex; flex-wrap: wrap; gap: 10px; }
.doc-link {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 8px 16px; border-radius: 8px; font-size: 0.85rem; font-weight: 600;
  text-decoration: none; transition: all 0.15s;
  background: var(--accent); color: #fff;
  border: 1.5px solid var(--accent);
}
.doc-link:hover { opacity: 0.88; transform: translateY(-1px); }
.doc-link.portfolio {
  background: transparent; color: var(--accent);
  border-color: var(--accent);
}
.doc-link.portfolio:hover { background: var(--accent); color: #fff; }

/* ═══════════════════════════════════════════════════════════════
   DOCUMENTOS — Painel Admin (detalhe do candidato)
   ═══════════════════════════════════════════════════════════════ */
.admin-docs-section {
  background: var(--bg-2); border: 1px solid var(--border);
  border-radius: 10px; padding: 14px 18px; margin-bottom: 16px;
}
.admin-docs-section h4 {
  font-size: 0.8rem; font-weight: 700; color: var(--text-2);
  text-transform: uppercase; letter-spacing: 0.05em;
  margin: 0 0 10px; display: flex; align-items: center; gap: 5px;
}
.admin-docs-list { display: flex; flex-wrap: wrap; gap: 8px; }
.admin-doc-link {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 14px; border-radius: 7px; font-size: 0.8rem; font-weight: 600;
  text-decoration: none; transition: all 0.15s;
  border: 1.5px solid var(--accent); color: var(--accent);
  background: transparent;
}
.admin-doc-link:hover { background: var(--accent); color: #fff; }

/* ═══════════════════════════════════════════════════════════════
   UPLOAD DE PDF — Área de drag & drop
   ═══════════════════════════════════════════════════════════════ */
.upload-section { display: flex; flex-direction: column; gap: 16px; margin: 16px 0; }

.upload-field {}
.upload-label {
  display: flex; align-items: center; gap: 6px;
  font-size: 0.875rem; font-weight: 600; color: var(--text-1);
  margin-bottom: 8px;
}
.upload-label i { color: #e11d48; }

.upload-drop-area {
  border: 2px dashed var(--border); border-radius: 12px;
  padding: 28px 20px; text-align: center; cursor: pointer;
  transition: all 0.2s; background: var(--bg-2);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.upload-drop-area:hover, .upload-drop-area.drag-over {
  border-color: var(--accent); background: var(--accent)0d;
}
.upload-drop-area.drag-over { transform: scale(1.01); }
.upload-icon { font-size: 2rem; color: var(--text-3); }
.upload-drop-area:hover .upload-icon, .upload-drop-area.drag-over .upload-icon { color: var(--accent); }
.upload-text { font-size: 0.875rem; color: var(--text-2); }
.upload-text strong { color: var(--accent); }
.upload-hint { font-size: 0.75rem; color: var(--text-3); }

/* Preview do arquivo selecionado */
.upload-preview {
  display: flex; align-items: center; gap: 10px;
  background: var(--bg-2); border: 1.5px solid var(--accent);
  border-radius: 10px; padding: 10px 14px;
}
.pdf-icon { font-size: 1.4rem; color: #e11d48; flex-shrink: 0; }
.preview-name { font-size: 0.82rem; color: var(--text-1); flex: 1; word-break: break-all; }
.remove-file-btn {
  background: none; border: none; cursor: pointer;
  color: var(--text-3); padding: 4px; border-radius: 4px;
  transition: color 0.15s;
}
.remove-file-btn:hover { color: #e11d48; }

/* Badge de documento enviado (área do candidato) */
.doc-badge {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 14px; border-radius: 8px; font-size: 0.82rem; font-weight: 600;
  background: var(--bg-card); border: 1.5px solid var(--border); color: var(--text-2);
}
.doc-badge i { color: #e11d48; }
.doc-badge.portfolio i { color: var(--accent); }
.docs-note {
  font-size: 0.75rem; color: var(--text-3); margin-top: 10px;
  display: flex; align-items: center; gap: 5px;
}
.docs-note i { color: var(--success); }
