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

:root {
  /* ── Paleta Valore ─────────────────────────────── */
  --primary: #0a1628;        /* azul escuro Valore */
  --primary-light: #dde8f7;  /* azul claro para backgrounds */
  --accent: #7c3aed;         /* roxo Valore */
  --accent-hover: #6d28d9;
  --accent-light: #ede9fe;
  --success: #22c55e;
  --success-light: #dcfce7;
  --warning: #f59e0b;
  --warning-light: #fef3c7;
  --danger: #ef4444;
  --danger-light: #fee2e2;
  --info: #1d4ed8;
  --info-light: #dbeafe;
  --bg: #f4f6fb;
  --surface: #ffffff;
  --surface2: #f8f9fd;
  --border: #e4e8f2;
  --border-strong: #cdd3e8;
  --text: #0a1628;
  --text-2: #4a5568;
  --text-3: #8896b0;
  --sidebar-w: 240px;
  --sidebar-w-collapsed: 64px;
  --header-h: 64px;
  --radius: 10px;
  --radius-lg: 14px;
  --shadow-sm: 0 1px 3px rgba(26,31,54,.06), 0 1px 2px rgba(26,31,54,.04);
  --shadow: 0 4px 16px rgba(26,31,54,.08), 0 1px 4px rgba(26,31,54,.04);
  --shadow-lg: 0 8px 32px rgba(26,31,54,.12), 0 2px 8px rgba(26,31,54,.06);
  --font: 'Plus Jakarta Sans', sans-serif;
  --font-serif: 'Fraunces', serif;
  --transition: 0.18s ease;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ─── LOGIN ───────────────────────────────────────────────────────────────── */
.login-page {
  display: flex;
  min-height: 100vh;
}

.login-left {
  flex: 1;
  background: var(--primary);
  background-image: radial-gradient(ellipse at 80% 20%, #112240 0%, transparent 60%),
                    radial-gradient(ellipse at 10% 80%, #1d4ed8 0%, transparent 50%);
  padding: 48px 56px;
  display: flex;
  flex-direction: column;
  gap: 40px;
  position: relative;
  overflow: hidden;
}

.login-left::before {
  content: '';
  position: absolute;
  right: -60px; bottom: -80px;
  width: 320px; height: 320px;
  border-radius: 50%;
  border: 1.5px solid rgba(29,78,216,.25);
}

.login-left::after {
  content: '';
  position: absolute;
  right: 20px; bottom: -20px;
  width: 200px; height: 200px;
  border-radius: 50%;
  border: 1px solid rgba(29,78,216,.15);
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-mark {
  width: 44px; height: 44px;
  background: var(--accent);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; font-weight: 700;
  color: white;
  font-family: var(--font-serif);
}

.brand-name { font-size: 18px; font-weight: 600; color: white; }
.brand-tagline { font-size: 12px; color: rgba(255,255,255,.5); }

.login-headline {
  font-size: 40px;
  line-height: 1.2;
  color: white;
  font-weight: 300;
  letter-spacing: -0.5px;
  margin-top: auto;
}

.headline-serif {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  color: #93c5fd;
}

.login-features {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.feature-pill {
  background: rgba(255,255,255,.08);
  border: 1px solid rgba(255,255,255,.12);
  color: rgba(255,255,255,.8);
  padding: 8px 14px;
  border-radius: 100px;
  font-size: 12px;
  display: flex; align-items: center; gap: 8px;
}

.feature-pill i { color: #a5b4fc; font-size: 12px; }

.login-right {
  width: 480px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px;
  background: var(--surface);
}

.login-card {
  width: 100%;
  max-width: 380px;
}

.login-card h2 {
  font-size: 26px; font-weight: 600;
  color: var(--primary);
  margin-bottom: 8px;
}

.login-subtitle {
  color: var(--text-2);
  margin-bottom: 36px;
  font-size: 14px;
}

.form-group { margin-bottom: 20px; }
.form-group label {
  display: block;
  font-size: 13px; font-weight: 500;
  color: var(--text-2);
  margin-bottom: 6px;
}

.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 14px;
  color: var(--text);
  background: var(--surface);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}

.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(88,101,242,.1);
}

.form-group textarea { resize: vertical; min-height: 100px; }

.input-with-icon { position: relative; }
.input-with-icon input { padding-right: 44px; }
.eye-btn {
  position: absolute; right: 12px; top: 50%;
  transform: translateY(-50%);
  background: none; border: none;
  color: var(--text-3); cursor: pointer; padding: 4px;
}

.error-msg {
  color: var(--danger);
  background: var(--danger-light);
  border: 1px solid #fca5a5;
  padding: 10px 14px;
  border-radius: var(--radius);
  font-size: 13px;
  margin-bottom: 16px;
}

/* ─── BUTTONS ─────────────────────────────────────────────────────────────── */
.btn-primary {
  background: var(--accent);
  color: white;
  border: none;
  padding: 12px 20px;
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 14px; font-weight: 500;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: background var(--transition), transform 0.1s;
  text-decoration: none;
}
.btn-primary:hover { background: var(--accent-hover); }
.btn-primary:active { transform: scale(0.98); }
.btn-full { width: 100%; justify-content: center; }

/* Botão azul exclusivo da tela de login */
.btn-login {
  background: #1d4ed8;
  color: white;
  border: none;
  padding: 12px 20px;
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 14px; font-weight: 500;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: background var(--transition), transform 0.1s;
}
.btn-login:hover { background: #1e40af; }
.btn-login:active { transform: scale(0.98); }

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1.5px solid var(--border);
  padding: 10px 18px;
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 13px; font-weight: 500;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: all var(--transition);
}

.btn-secondary:hover { background: var(--bg); border-color: var(--border-strong); }

.btn-danger {
  background: var(--danger);
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 13px; font-weight: 500;
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 8px;
  transition: all var(--transition);
}

.btn-danger:hover { background: #dc2626; }

.btn-icon {
  background: none;
  border: 1.5px solid var(--border);
  color: var(--text-2);
  width: 36px; height: 36px;
  border-radius: var(--radius);
  cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: all var(--transition); font-size: 14px;
}

.btn-icon:hover { background: var(--bg); color: var(--text); border-color: var(--border-strong); }

/* ─── APP LAYOUT ──────────────────────────────────────────────────────────── */
#app { display: flex; min-height: 100vh; }

/* ─── SIDEBAR ─────────────────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--primary);
  background-image: linear-gradient(180deg, #112240 0%, #0a1628 100%);
  display: flex; flex-direction: column;
  position: fixed; left: 0; top: 0; bottom: 0;
  z-index: 100;
  transition: width var(--transition);
  overflow: hidden;
}

.sidebar.collapsed { width: var(--sidebar-w-collapsed); }
.sidebar.collapsed .brand-text,
.sidebar.collapsed .nav-item span,
.sidebar.collapsed .nav-arrow,
.sidebar.collapsed .nav-submenu,
.sidebar.collapsed .nav-section-label,
.sidebar.collapsed .user-info-sm { display: none; }
.sidebar.collapsed .brand-mark-sm { margin: 0 auto; }
.sidebar.collapsed .sidebar-header { justify-content: center; padding: 18px 8px; }
.sidebar.collapsed .sidebar-toggle { margin-left: 0; }
.sidebar.collapsed .nav-item,
.sidebar.collapsed .nav-sub-item { justify-content: center; padding: 10px; }
.sidebar.collapsed .nav-item i,
.sidebar.collapsed .nav-sub-item i { margin: 0; }

.sidebar-header {
  display: flex; align-items: center; gap: 12px;
  padding: 18px 16px;
  border-bottom: 1px solid rgba(255,255,255,.06);
  min-height: 64px;
}

.brand-mark-sm {
  width: 32px; height: 32px; flex-shrink: 0;
  background: var(--accent);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px; font-weight: 700; color: white;
  font-family: var(--font-serif);
}

.brand-name-sm { font-size: 15px; font-weight: 600; color: white; }

.sidebar-toggle {
  margin-left: auto;
  background: none; border: none;
  color: rgba(255,255,255,.4); cursor: pointer;
  font-size: 16px; padding: 4px;
  transition: color var(--transition);
}
.sidebar-toggle:hover { color: white; }

.sidebar-nav {
  flex: 1; overflow-y: auto; overflow-x: hidden;
  padding: 12px 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.1) transparent;
}

.nav-section-label {
  font-size: 10px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 1px;
  color: rgba(255,255,255,.3);
  padding: 14px 16px 4px;
}

.nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 16px;
  color: rgba(255,255,255,.65);
  cursor: pointer;
  transition: all var(--transition);
  border-radius: 0;
  font-size: 13.5px; font-weight: 500;
  position: relative;
  white-space: nowrap;
}

.nav-item:hover { color: white; background: rgba(255,255,255,.06); }
.nav-item.active { color: white; background: rgba(88,101,242,.25); }
.nav-item.active::before {
  content: '';
  position: absolute; left: 0; top: 4px; bottom: 4px;
  width: 3px; background: var(--accent);
  border-radius: 0 3px 3px 0;
}

.nav-item i:first-child { width: 18px; text-align: center; font-size: 14px; flex-shrink: 0; }
.nav-arrow { margin-left: auto; font-size: 10px; transition: transform var(--transition); }
.nav-arrow.open { transform: rotate(180deg); }

.nav-submenu {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.3s ease;
}
.nav-submenu.open { max-height: 400px; }

.nav-sub-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 16px 8px 36px;
  color: rgba(255,255,255,.5);
  cursor: pointer;
  transition: all var(--transition);
  font-size: 13px; white-space: nowrap;
}

.nav-sub-item:hover { color: rgba(255,255,255,.9); background: rgba(255,255,255,.04); }
.nav-sub-item.active { color: #c4b5fd; }
.nav-sub-item i { font-size: 12px; width: 14px; text-align: center; }

.sidebar-footer {
  display: flex; align-items: center;
  padding: 14px 16px;
  border-top: 1px solid rgba(255,255,255,.06);
  gap: 8px;
}

.user-avatar-sm {
  width: 32px; height: 32px; flex-shrink: 0;
  background: var(--accent);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600; color: white;
}

.user-info-sm { flex: 1; min-width: 0; cursor: pointer; }
.user-info-sm div:first-child {
  font-size: 13px; font-weight: 500; color: white;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.user-info-sm div:last-child { font-size: 11px; color: rgba(255,255,255,.4); }

.btn-logout {
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 8px;
  color: rgba(255,255,255,.6);
  cursor: pointer;
  font-size: 14px;
  padding: 7px 9px;
  flex-shrink: 0;
  transition: all var(--transition);
}
.btn-logout:hover {
  background: rgba(239,68,68,.15);
  border-color: rgba(239,68,68,.3);
  color: #ef4444;
}

/* ─── MAIN CONTENT ────────────────────────────────────────────────────────── */
.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  transition: margin-left var(--transition);
  min-width: 0;
}

.sidebar.collapsed ~ .main-content { margin-left: var(--sidebar-w-collapsed); }

/* ─── PAGE WRAPPER ────────────────────────────────────────────────────────── */
.page-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 20px 32px;
  display: flex; align-items: center;
  gap: 16px;
  position: sticky; top: 0; z-index: 50;
}

.page-title {
  font-size: 18px; font-weight: 600;
  color: var(--primary);
  display: flex; align-items: center; gap: 10px;
}

.page-title i {
  width: 36px; height: 36px;
  background: var(--accent-light);
  color: var(--accent);
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
}

.page-actions { margin-left: auto; display: flex; gap: 8px; }

.page-body { padding: 28px 32px; }

/* ─── CARDS ───────────────────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.card-header {
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center;
  gap: 10px;
  font-size: 14px; font-weight: 600;
  color: var(--primary);
}

.card-body { padding: 22px; }

/* ─── STAT CARDS ──────────────────────────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
  box-shadow: var(--shadow-sm);
  display: flex; align-items: center;
  gap: 16px;
  transition: box-shadow var(--transition), border-color var(--transition);
}

.stat-card:hover { box-shadow: var(--shadow); border-color: var(--accent); }

.stat-icon {
  width: 48px; height: 48px; flex-shrink: 0;
  border-radius: var(--radius);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}

.stat-icon.blue { background: #dbeafe; color: #1d4ed8; border: 1.5px solid #93c5fd; }
.stat-icon.green { background: #dbeafe; color: #1d4ed8; border: 1.5px solid #93c5fd; }
.stat-icon.amber { background: #dbeafe; color: #1d4ed8; border: 1.5px solid #93c5fd; }
.stat-icon.purple { background: #dbeafe; color: #1d4ed8; border: 1.5px solid #93c5fd; }
.stat-icon.pink { background: #dbeafe; color: #1d4ed8; border: 1.5px solid #93c5fd; }
.stat-icon.teal { background: #dbeafe; color: #1d4ed8; border: 1.5px solid #93c5fd; }

.stat-value { font-size: 30px; font-weight: 800; line-height: 1; color: var(--text); }
.stat-label { font-size: 12.5px; color: var(--text-2); margin-top: 5px; font-weight: 500; }
.stat-trend { font-size: 11px; margin-top: 6px; }
.stat-trend.up { color: var(--success); }
.stat-trend.down { color: var(--danger); }

/* ─── TABLES ──────────────────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; }
thead th {
  text-align: left;
  font-size: 11px; font-weight: 600;
  text-transform: uppercase; letter-spacing: .6px;
  color: var(--text-3);
  padding: 10px 16px;
  background: var(--surface2);
  border-bottom: 1px solid var(--border);
}
tbody td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--border);
  font-size: 13.5px;
  color: var(--text);
}
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover td { background: var(--bg); }

/* ─── BADGES ──────────────────────────────────────────────────────────────── */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 10px; border-radius: 100px;
  font-size: 11px; font-weight: 600;
  white-space: nowrap;
}
.badge-success { background: var(--success-light); color: #15803d; }
.badge-warning { background: var(--warning-light); color: #b45309; }
.badge-danger  { background: var(--danger-light);  color: #b91c1c; }
.badge-info    { background: var(--info-light);    color: #1d4ed8; }
.badge-neutral { background: var(--bg); color: var(--text-2); border: 1px solid var(--border); }
.badge-purple  { background: #ede9fe; color: #6d28d9; }

/* ─── SEARCH BAR ──────────────────────────────────────────────────────────── */
.search-bar {
  display: flex; align-items: center;
  gap: 10px;
  margin-bottom: 18px;
}

.search-input {
  flex: 1; max-width: 320px;
  position: relative;
}

.search-input i {
  position: absolute; left: 12px; top: 50%;
  transform: translateY(-50%);
  color: var(--text-3); font-size: 14px;
}

.search-input input {
  width: 100%;
  padding: 9px 14px 9px 36px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  font-family: var(--font);
  font-size: 13.5px; color: var(--text);
  background: var(--surface);
  outline: none; transition: border-color var(--transition);
}

.search-input input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(88,101,242,.08); }

/* ─── EMPLOYEE CARD ───────────────────────────────────────────────────────── */
.employee-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.employee-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: var(--shadow-sm);
}

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

.emp-avatar {
  width: 52px; height: 52px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 600; color: white;
  margin-bottom: 14px;
}

.emp-name { font-size: 15px; font-weight: 600; color: var(--primary); margin-bottom: 3px; }
.emp-position { font-size: 12.5px; color: var(--text-2); margin-bottom: 8px; }
.emp-dept { font-size: 11.5px; color: var(--accent); font-weight: 500; }

/* ─── AVATAR COLORS ───────────────────────────────────────────────────────── */
.av-0 { background: #6366f1; }
.av-1 { background: #ec4899; }
.av-2 { background: #0ea5e9; }
.av-3 { background: #10b981; }
.av-4 { background: #f59e0b; }
.av-5 { background: #8b5cf6; }
.av-6 { background: #14b8a6; }
.av-7 { background: #f97316; }

/* ─── KNOWLEDGE / NEWS CARDS ──────────────────────────────────────────────── */
.content-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}

.content-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  cursor: pointer;
  transition: all var(--transition);
  box-shadow: var(--shadow-sm);
}

.content-card:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.content-card-cat { font-size: 11px; font-weight: 600; color: var(--accent); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 8px; }
.content-card-title { font-size: 15px; font-weight: 600; color: var(--primary); margin-bottom: 8px; line-height: 1.4; }
.content-card-preview { font-size: 13px; color: var(--text-2); line-height: 1.6; margin-bottom: 12px;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.content-card-meta { display: flex; align-items: center; gap: 12px; font-size: 11.5px; color: var(--text-3); }

/* ─── MODAL ───────────────────────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(26,31,54,.5);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: none; align-items: center; justify-content: center;
  padding: 24px;
}
.modal-overlay.open { display: flex; }

.modal-box {
  background: var(--surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%; max-width: 560px;
  max-height: 90vh; display: flex; flex-direction: column;
}

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center;
}

.modal-header h3 { font-size: 16px; font-weight: 600; color: var(--primary); flex: 1; }
.modal-close { background: none; border: none; color: var(--text-3); cursor: pointer; font-size: 18px; padding: 4px; border-radius: 6px; transition: all var(--transition); }
.modal-close:hover { background: var(--bg); color: var(--text); }

.modal-body { padding: 24px; overflow-y: auto; flex: 1; }
.modal-footer { padding: 16px 24px; border-top: 1px solid var(--border); display: flex; gap: 10px; justify-content: flex-end; }

/* ─── TOAST ───────────────────────────────────────────────────────────────── */
#toast-container {
  position: fixed; bottom: 24px; right: 24px;
  z-index: 2000;
  display: flex; flex-direction: column; gap: 10px;
}

.toast {
  background: var(--primary);
  color: white;
  padding: 13px 18px;
  border-radius: var(--radius);
  display: flex; align-items: center; gap: 12px;
  font-size: 13.5px; font-weight: 500;
  box-shadow: var(--shadow-lg);
  animation: slideIn .25s ease;
  min-width: 240px; max-width: 360px;
}

.toast.success { background: #166534; }
.toast.error   { background: #991b1b; }
.toast.info    { background: #1e40af; }
.toast.warning { background: #92400e; }

@keyframes slideIn {
  from { transform: translateX(120%); opacity: 0; }
  to   { transform: translateX(0);   opacity: 1; }
}

/* ─── TABS ────────────────────────────────────────────────────────────────── */
.tabs {
  display: flex; gap: 0;
  border-bottom: 2px solid var(--border);
  margin-bottom: 24px;
}

.tab {
  padding: 10px 20px;
  font-size: 13.5px; font-weight: 500;
  color: var(--text-2);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all var(--transition);
  white-space: nowrap;
  display: flex; align-items: center; gap: 7px;
}

.tab:hover { color: var(--accent); }
.tab.active { color: var(--accent); border-bottom-color: var(--accent); }

/* ─── MISC ────────────────────────────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 60px 32px;
}

.empty-state i {
  font-size: 48px; color: var(--border-strong);
  display: block; margin-bottom: 16px;
}

.empty-state h3 { font-size: 16px; font-weight: 600; color: var(--text-2); margin-bottom: 8px; }
.empty-state p  { font-size: 13.5px; color: var(--text-3); max-width: 340px; margin: 0 auto 20px; }

.divider { border: none; border-top: 1px solid var(--border); margin: 20px 0; }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-full { grid-column: 1 / -1; }

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px 24px;
}

.detail-item label { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .5px; color: var(--text-3); display: block; margin-bottom: 3px; }
.detail-item span { font-size: 13.5px; color: var(--text); font-weight: 500; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--bg); border: 1px solid var(--border);
  padding: 4px 10px; border-radius: 6px;
  font-size: 12px; color: var(--text-2);
  font-weight: 500;
}

/* Priority colors */
.priority-high   { color: var(--danger);  }
.priority-medium { color: var(--warning); }
.priority-low    { color: var(--success); }

.timeline {
  position: relative;
  padding-left: 24px;
}

.timeline::before {
  content: '';
  position: absolute; left: 8px; top: 0; bottom: 0;
  width: 1.5px; background: var(--border);
}

.timeline-item {
  position: relative;
  margin-bottom: 20px;
  padding-bottom: 4px;
}

.timeline-item::before {
  content: '';
  position: absolute; left: -20px; top: 4px;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--accent);
  border: 2px solid var(--surface);
}

.timeline-date { font-size: 11px; color: var(--text-3); margin-bottom: 3px; }
.timeline-text { font-size: 13.5px; color: var(--text); }

/* ─── ORGANOGRAMA ─────────────────────────────────────────────────────────── */
.org-tree {
  overflow-x: auto;
  padding: 24px;
}

.org-node {
  display: inline-flex; flex-direction: column;
  align-items: center; gap: 0;
}

.org-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 18px;
  text-align: center;
  min-width: 150px;
  transition: all var(--transition);
  cursor: default;
}

.org-card:hover { border-color: var(--accent); box-shadow: var(--shadow); }
.org-card .emp-avatar { margin: 0 auto 10px; }

.org-children {
  display: flex; gap: 16px;
  align-items: flex-start;
  position: relative;
  padding-top: 24px;
}

.org-children::before {
  content: '';
  position: absolute; top: 0; left: 50%;
  width: 1.5px; height: 24px;
  background: var(--border);
}

/* ─── RECOGNITION WALL ────────────────────────────────────────────────────── */
.recognition-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.recognition-type {
  font-size: 28px; margin-bottom: 8px;
}

/* ─── PROGRESS ────────────────────────────────────────────────────────────── */
.progress-bar {
  height: 8px;
  background: var(--bg);
  border-radius: 100px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: 100px;
  transition: width .6s ease;
}

/* ─── SELECT ──────────────────────────────────────────────────────────────── */
select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%235a607f' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px !important;
}

/* ─── SCROLLBAR ───────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-3); }

/* ─── RESPONSIVE ──────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
  .login-left { display: none; }
  .login-right { width: 100%; }
  .form-row { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .page-body { padding: 20px 16px; }
  .page-header { padding: 16px; }
}


/* ─── VALORE BRAND STYLES ──────────────────────────────────────────────────── */

/* Logo na sidebar */
.sidebar-logo-img {
  width: 28px;
  height: 28px;
  object-fit: contain;
  flex-shrink: 0;
  cursor: pointer;
  transition: opacity var(--transition);
}
.sidebar-logo-img:hover { opacity: 0.8; }

/* Quando sidebar recolhida, centraliza a logo */
.sidebar.collapsed .sidebar-logo-img {
  margin: 0 auto;
  display: block;
}

/* Logo na tela de login */
.login-logo {
  width: 200px;
  height: auto;
  max-height: 60px;
  object-fit: contain;
  display: block;
}

/* ─── RESPONSIVO ────────────────────────────────────────────────────────────── */
@media (max-width: 1280px) {
  :root { --sidebar-w: 200px; }
}
@media (max-width: 1024px) {
  :root { --sidebar-w: 180px; }
  .page-body { padding: 16px 18px; }
  .stats-grid { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
}
