:root {
  --primary: #6366f1;
  --primary-dark: #4f46e5;
  --primary-light: #a5b4fc;
  --sidebar-bg: #1e1b4b;
  --sidebar-hover: #312e81;
  --sidebar-active: #4338ca;
  --sidebar-text: #c7d2fe;
  --sidebar-width: 260px;
  --gradient-1: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  --gradient-2: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);
  --gradient-3: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
  --gradient-4: linear-gradient(135deg, #ffecd2 0%, #fcb69f 100%);
}

* { font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif; }

body { background: #f1f5f9; min-height: 100vh; }

/* ===== LOGIN ===== */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--gradient-1);
  padding: 20px;
}
.login-box { width: 100%; max-width: 400px; }
.login-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 25px 50px rgba(0,0,0,.25);
  padding: 40px 32px;
}
.login-brand {
  text-align: center;
  margin-bottom: 32px;
}
.login-brand h1 {
  font-size: 1.8rem;
  font-weight: 700;
  color: #1e1b4b;
  margin: 0;
}
.login-brand h1 i { color: var(--primary); margin-right: 8px; }
.login-brand p { color: #64748b; font-size: 0.9rem; margin-top: 4px; }

/* ===== LAYOUT ===== */
.app-wrapper {
  display: flex;
  min-height: 100vh;
}

/* ===== SIDEBAR ===== */
.sidebar {
  width: var(--sidebar-width);
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 1040;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease;
  overflow-y: auto;
}
.sidebar-brand {
  padding: 20px 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  text-decoration: none;
  color: #fff;
}
.sidebar-brand:hover { color: #fff; }
.sidebar-brand-icon {
  width: 40px;
  height: 40px;
  background: var(--primary);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.sidebar-brand-text { font-weight: 700; font-size: 1.15rem; }

.sidebar-user {
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,.08);
  display: flex;
  align-items: center;
  gap: 12px;
}
.sidebar-user-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--gradient-1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
}
.sidebar-user-name { font-weight: 600; color: #fff; font-size: 0.9rem; }
.sidebar-user-role { font-size: 0.75rem; color: var(--sidebar-text); }

.sidebar-nav { padding: 16px 12px; flex: 1; }
.sidebar-nav-label {
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255,255,255,.35);
  padding: 16px 12px 8px;
}
.sidebar-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-radius: 10px;
  color: var(--sidebar-text);
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  transition: all 0.15s;
  margin-bottom: 2px;
}
.sidebar-nav a:hover {
  background: var(--sidebar-hover);
  color: #fff;
}
.sidebar-nav a.active {
  background: var(--sidebar-active);
  color: #fff;
  box-shadow: 0 4px 12px rgba(67,56,202,.4);
}
.sidebar-nav a i {
  width: 20px;
  text-align: center;
  font-size: 0.95rem;
}

/* ===== SIDEBAR SUBMENU (collapsible group) ===== */
.nav-group-toggle {
  cursor: pointer;
  justify-content: space-between;
}
.nav-group-toggle.open,
.nav-group-toggle.has-active {
  color: #fff;
}
.nav-group-arrow {
  margin-left: auto;
  font-size: 0.65rem !important;
  width: auto !important;
  transition: transform 0.2s;
}
.nav-group-toggle.open .nav-group-arrow { transform: rotate(180deg); }
.nav-submenu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.25s ease;
}
.nav-submenu.open { max-height: 260px; }
.nav-submenu a {
  font-size: 0.82rem;
  padding: 8px 16px 8px 34px;
  font-weight: 500;
}
.nav-submenu a i {
  font-size: 0.8rem !important;
  width: 20px;
}

/* ===== MAIN CONTENT ===== */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* ===== TOP NAVBAR ===== */
.top-navbar {
  background: #fff;
  padding: 0 24px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #e2e8f0;
  position: sticky;
  top: 0;
  z-index: 1030;
}
.navbar-left { display: flex; align-items: center; gap: 16px; }
.navbar-right { display: flex; align-items: center; gap: 16px; }
.btn-sidebar-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.2rem;
  color: #475569;
  cursor: pointer;
  padding: 4px;
}
.page-title { font-size: 1.15rem; font-weight: 700; color: #1e293b; }
.navbar-date {
  font-size: 0.82rem;
  color: #64748b;
}
.navbar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 10px;
  transition: background 0.15s;
  position: relative;
}
.navbar-user:hover { background: #f1f5f9; }
.navbar-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--gradient-1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-weight: 700;
  font-size: 0.75rem;
}
.navbar-user-name { font-size: 0.85rem; font-weight: 600; color: #334155; }
.user-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 8px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0,0,0,.12);
  min-width: 200px;
  padding: 8px;
  display: none;
  z-index: 1050;
}
.user-dropdown.show { display: block; }
.user-dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 8px;
  color: #475569;
  font-size: 0.85rem;
  text-decoration: none;
  cursor: pointer;
}
.user-dropdown-item:hover { background: #f1f5f9; color: #1e293b; }
.user-dropdown-divider { height: 1px; background: #e2e8f0; margin: 4px 0; }

/* ===== CONTENT AREA ===== */
.content-area {
  padding: 24px;
  flex: 1;
}

/* ===== HERO BANNER (beranda) ===== */
.hero-banner {
  position: relative;
  background: linear-gradient(120deg, #4338ca 0%, #6366f1 55%, #818cf8 100%);
  border-radius: 20px;
  padding: 28px 30px;
  color: #fff;
  overflow: hidden;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 24px;
  box-shadow: 0 16px 40px -16px rgba(67,56,202,.55);
}
.hero-decor {
  position: absolute;
  right: -18px;
  bottom: -26px;
  font-size: 9rem;
  color: rgba(255,255,255,.1);
  transform: rotate(-12deg);
  pointer-events: none;
}
.hero-banner-main { flex: 1 1 240px; min-width: 0; }
.hero-eyebrow {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255,255,255,.7);
  margin: 0 0 4px;
}
.hero-title { font-size: 1.5rem; font-weight: 700; margin: 0 0 4px; }
.hero-sub { font-size: 0.85rem; color: rgba(255,255,255,.8); margin: 0; }
.hero-banner-progress {
  flex: 1 1 220px;
  max-width: 260px;
  background: rgba(255,255,255,.12);
  border-radius: 14px;
  padding: 14px 16px;
  backdrop-filter: blur(2px);
}
.hero-progress-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.78rem;
  color: rgba(255,255,255,.85);
  margin-bottom: 8px;
}
.hero-progress-label strong { font-size: 0.95rem; color: #fff; }
.hero-progress-track {
  height: 8px;
  border-radius: 99px;
  background: rgba(255,255,255,.2);
  overflow: hidden;
}
.hero-progress-fill {
  height: 100%;
  border-radius: 99px;
  background: #fff;
  width: 0%;
  transition: width 0.6s ease;
}
.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  color: var(--primary-dark);
  font-weight: 700;
  font-size: 0.88rem;
  padding: 12px 22px;
  border-radius: 12px;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}
.hero-cta:hover {
  color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0,0,0,.2);
}

/* ===== STAT CARDS ===== */
.stat-card {
  position: relative;
  border-radius: 16px;
  padding: 20px;
  overflow: hidden;
  box-shadow: 0 10px 24px -12px rgba(15,23,42,.25);
  transition: transform 0.2s, box-shadow 0.2s;
  color: #fff;
  animation: statIn 0.4s ease both;
}
.stat-card:nth-child(1) { animation-delay: .02s; }
.stat-card:nth-child(2) { animation-delay: .08s; }
.stat-card:nth-child(3) { animation-delay: .14s; }
.stat-card:nth-child(4) { animation-delay: .2s; }
@keyframes statIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
.stat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px -12px rgba(15,23,42,.32);
}
.stat-grad-1 { background: var(--gradient-1); }
.stat-grad-2 { background: var(--gradient-2); }
.stat-grad-3 { background: var(--gradient-3); }
.stat-grad-4 { background: var(--gradient-4); color: #92400e; }
.stat-card-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 18px;
}
.stat-card-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  background: rgba(255,255,255,.25);
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}
.stat-grad-4 .stat-card-icon { background: rgba(255,255,255,.5); }
.stat-card-watermark {
  position: absolute;
  right: -6px;
  top: -10px;
  font-size: 4rem;
  opacity: 0.15;
}
.stat-card-value { font-size: 1.7rem; font-weight: 700; line-height: 1; margin-bottom: 6px; position: relative; z-index: 1; }
.stat-card-label { font-size: 0.8rem; font-weight: 500; opacity: 0.9; position: relative; z-index: 1; }

/* ===== CARDS ===== */
.card-custom {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 1px 3px rgba(0,0,0,.06);
  overflow: hidden;
}
.card-custom-header {
  padding: 16px 20px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card-custom-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-custom-title i { color: var(--primary); }
.card-custom-body { padding: 20px; }
.card-custom-body.p-0 { padding: 0; }

/* ===== TABLES ===== */
.table-custom {
  margin: 0;
  font-size: 0.85rem;
}
.table-custom thead th {
  background: #f8fafc;
  font-weight: 600;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #64748b;
  padding: 12px 16px;
  border-bottom: 1px solid #e2e8f0;
}
.table-custom tbody td {
  padding: 12px 16px;
  vertical-align: middle;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
}
.table-custom tbody tr:last-child td { border-bottom: none; }
.table-custom tbody tr:hover { background: #f8fafc; }

/* ===== BADGES ===== */
.badge-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 0.72rem;
  font-weight: 600;
}
.badge-success-soft { background: #dcfce7; color: #166534; }
.badge-warning-soft { background: #fef3c7; color: #92400e; }
.badge-info-soft { background: #dbeafe; color: #1e40af; }
.badge-primary-soft { background: #e0e7ff; color: #3730a3; }
.badge-secondary-soft { background: #f1f5f9; color: #475569; }
.badge-danger-soft { background: #fee2e2; color: #991b1b; }

/* ===== BUTTONS ===== */
.btn-primary-custom {
  background: var(--primary);
  border: none;
  color: #fff;
  padding: 10px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.88rem;
  transition: all 0.15s;
  cursor: pointer;
}
.btn-primary-custom:hover {
  background: var(--primary-dark);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(99,102,241,.4);
}
.btn-outline-custom {
  border: 1.5px solid #e2e8f0;
  background: #fff;
  color: #475569;
  padding: 10px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.88rem;
  transition: all 0.15s;
  cursor: pointer;
}
.btn-outline-custom:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: #f5f3ff;
}
.btn-danger-custom {
  background: #dc2626;
  border: none;
  color: #fff;
  padding: 10px 20px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 0.88rem;
  transition: all 0.15s;
  cursor: pointer;
}
.btn-danger-custom:hover {
  background: #b91c1c;
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(220,38,38,.35);
}
.btn-icon {
  width: 34px;
  height: 34px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  border: 1.5px solid #e2e8f0;
  background: #fff;
  color: #64748b;
  font-size: 0.8rem;
  transition: all 0.15s;
  cursor: pointer;
}
.btn-icon:hover { border-color: var(--primary); color: var(--primary); }
.btn-icon-danger:hover { border-color: #ef4444; color: #ef4444; }

/* ===== FORMS ===== */
.form-control-custom {
  border: 1.5px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 0.88rem;
  transition: border-color 0.15s;
  width: 100%;
}
.form-control-custom:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99,102,241,.15);
  outline: none;
}
.form-label-custom {
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
  display: block;
}

/* ===== EMPTY STATE ===== */
.empty-state {
  padding: 48px 24px;
  text-align: center;
  color: #94a3b8;
}
.empty-state i {
  font-size: 2.5rem;
  margin-bottom: 12px;
  opacity: 0.5;
}
.empty-state h6 {
  font-weight: 600;
  color: #64748b;
  margin-bottom: 4px;
}
.empty-state p { font-size: 0.85rem; }

/* ===== JENIS TABS (Penilaian) ===== */
.jenis-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: 10px;
  background: #f8fafc;
  color: #64748b;
  font-weight: 600;
  font-size: 0.82rem;
  text-decoration: none;
  border: 1.5px solid transparent;
  transition: all 0.15s;
}
.jenis-tab:hover { background: #f1f5f9; color: #475569; }
.jenis-tab.active {
  background: #eef2ff;
  color: var(--primary);
  border-color: #c7d2fe;
}

/* ===== PROGRESS BAR (Penilaian) ===== */
.progress-track {
  width: 100%;
  min-width: 90px;
  height: 6px;
  border-radius: 4px;
  background: #f1f5f9;
  overflow: hidden;
  margin-bottom: 4px;
}
.progress-fill {
  height: 100%;
  border-radius: 4px;
  background: var(--gradient-1, var(--primary));
}

/* ===== STUDENT AVATAR ===== */
.student-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: #e0e7ff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  color: var(--primary);
  font-size: 0.78rem;
  flex-shrink: 0;
}

/* ===== WA TAG ===== */
.wa-tag {
  font-size: 0.72rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}
.wa-tag.ok { color: #16a34a; }
.wa-tag.warn { color: #d97706; }
.wa-tag.bad { color: #dc2626; }

/* ===== TOAST ===== */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.toast-custom {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0,0,0,.15);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 300px;
  animation: slideIn 0.3s ease;
}
.toast-custom.success { border-left: 4px solid #22c55e; }
.toast-custom.error { border-left: 4px solid #ef4444; }
.toast-custom.warning { border-left: 4px solid #f59e0b; }
.toast-custom.info { border-left: 4px solid #3b82f6; }
.toast-custom i { font-size: 1.1rem; }
.toast-custom.success i { color: #22c55e; }
.toast-custom.error i { color: #ef4444; }
.toast-custom.warning i { color: #f59e0b; }
.toast-custom.info i { color: #3b82f6; }
.toast-custom span { font-size: 0.85rem; color: #334155; font-weight: 500; }
@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ===== MODAL ===== */
.modal-content {
  border: none;
  border-radius: 16px;
  box-shadow: 0 25px 50px rgba(0,0,0,.25);
}
.modal-header {
  border-bottom: 1px solid #f1f5f9;
  padding: 20px 24px;
}
.modal-header .modal-title { font-weight: 700; font-size: 1.05rem; }
.modal-body { padding: 24px; }
.modal-footer {
  border-top: 1px solid #f1f5f9;
  padding: 16px 24px;
}

/* ===== DATATABLES ===== */
.dataTables_wrapper .dataTables_length {
  font-size: 0.8rem;
  color: #64748b;
}
.dataTables_wrapper .dataTables_length label {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 0;
  font-weight: 400;
}
.dataTables_wrapper .dataTables_length select {
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  padding: 4px 32px 4px 10px;
  min-width: 68px;
  font-size: 0.82rem;
  background-color: #fff;
}
.dataTables_wrapper .dataTables_length select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
  outline: none;
}
.dataTables_wrapper .dataTables_info {
  font-size: 0.8rem;
  color: #64748b;
  padding-top: 0 !important;
  white-space: normal;
}
.dataTables_wrapper .dataTables_paginate .pagination {
  margin: 0;
  gap: 4px;
  flex-wrap: wrap;
}
.dataTables_wrapper .dataTables_paginate .page-link {
  border: 1.5px solid #e2e8f0;
  border-radius: 8px !important;
  margin: 0 !important;
  padding: 5px 11px;
  font-size: 0.82rem;
  color: #475569;
  background: #fff;
}
.dataTables_wrapper .dataTables_paginate .page-item.active .page-link {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: none;
}
.dataTables_wrapper .dataTables_paginate .page-link:hover {
  background: #f5f3ff;
  border-color: var(--primary);
  color: var(--primary);
}
.dataTables_wrapper .dataTables_paginate .page-item.disabled .page-link {
  color: #cbd5e1;
  background: #fff;
  border-color: #e2e8f0;
}
table.dataTable thead th {
  position: relative;
}

/* ===== SCANNER ===== */
.scan-container { max-width: 400px; margin: 0 auto; }
#qr-reader { border-radius: 14px; overflow: hidden; }

.scan-frame-wrap {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  background: #0f172a;
}
.scan-frame-wrap #qr-reader { min-height: 300px; }
.scan-corners {
  position: absolute;
  inset: 0;
  pointer-events: none;
}
.scan-corners span {
  position: absolute;
  width: 30px;
  height: 30px;
  border: 3px solid var(--primary-light);
  opacity: 0;
  transition: opacity 0.2s;
}
.scan-frame-wrap.active .scan-corners span { opacity: 1; }
.scan-corners span:nth-child(1) { top: 10px; left: 10px; border-right: none; border-bottom: none; border-top-left-radius: 8px; }
.scan-corners span:nth-child(2) { top: 10px; right: 10px; border-left: none; border-bottom: none; border-top-right-radius: 8px; }
.scan-corners span:nth-child(3) { bottom: 10px; left: 10px; border-right: none; border-top: none; border-bottom-left-radius: 8px; }
.scan-corners span:nth-child(4) { bottom: 10px; right: 10px; border-left: none; border-top: none; border-bottom-right-radius: 8px; }

.scan-live-dot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  font-weight: 700;
  color: #ef4444;
}
.scan-live-dot .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
  animation: livePulse 1.2s infinite;
}
@keyframes livePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.session-scan-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  border-bottom: 1px solid #f1f5f9;
  animation: statIn 0.3s ease both;
}
.session-scan-item:last-child { border-bottom: none; }

/* ===== QUICK ACTION CARD ===== */
.quick-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1.5px solid #e2e8f0;
  background: #fff;
  color: #334155;
  font-weight: 600;
  font-size: 0.88rem;
  width: 100%;
  transition: all 0.15s;
  cursor: pointer;
  margin-bottom: 10px;
}
.quick-btn:hover {
  border-color: var(--primary);
  background: #f5f3ff;
  color: var(--primary);
}
.quick-btn i { font-size: 1rem; width: 20px; text-align: center; }
.quick-btn-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1rem;
}

/* ===== CARD LINK ===== */
.card-link {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
  white-space: nowrap;
}
.card-link:hover { color: var(--primary-dark); text-decoration: underline; }

/* ===== FOOTER ===== */
.main-footer {
  padding: 16px 24px;
  text-align: center;
  font-size: 0.8rem;
  color: #94a3b8;
  border-top: 1px solid #e2e8f0;
  background: #fff;
}

/* ===== MOBILE ===== */
@media (max-width: 991.98px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
    box-shadow: 0 0 60px rgba(0,0,0,.3);
  }
  .sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.4);
    z-index: 1035;
  }
  .sidebar-overlay.show { display: block; }
  .main-content { margin-left: 0; }
  .btn-sidebar-toggle { display: block; }
}

/* ===== SCROLLBAR ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #cbd5e1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ===== PRINT ===== */
@media print {
  .sidebar, .top-navbar, .main-footer { display: none !important; }
  .main-content { margin-left: 0 !important; }
}
