/* assets/css/style.css — DKHCBS SMS Main Styles */

/* ============================================================
   CSS VARIABLES (Design Tokens)
   ============================================================ */
:root {
  --primary:       #1A56DB;
  --primary-light: #EBF5FF;
  --primary-dark:  #1141A8;

  /* Dashboard Card Backgrounds */
  --card-lavender: #F3F0FF;
  --card-mint:     #F0FFF4;
  --card-peach:    #FFF7ED;
  --card-sky:      #EFF6FF;
  --card-purple:   #FAF5FF;

  /* Badges */
  --badge-teal:   #0E9F6E;
  --badge-green:  #057A55;
  --badge-red:    #E02424;
  --badge-blue:   #1C64F2;
  --badge-orange: #FF8A00;

  /* Layout */
  --sidebar-width:        240px;
  --sidebar-collapsed:    64px;
  --navbar-height:        60px;
  --sidebar-bg:           #1E2A3B;
  --sidebar-text:         #CBD5E1;
  --sidebar-active:       #1A56DB;
  --navbar-bg:            #FFFFFF;
  --body-bg:              #F8FAFC;
  --card-bg:              #FFFFFF;
  --text-primary:         #111827;
  --text-secondary:       #6B7280;
  --border:               #E5E7EB;
  --shadow:               0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md:            0 4px 6px rgba(0,0,0,0.07), 0 2px 4px rgba(0,0,0,0.06);
  --shadow-lg:            0 10px 25px rgba(0,0,0,0.1);

  /* Dark mode */
  --dark-body:  #0F172A;
  --dark-card:  #1E293B;
  --dark-text:  #F1F5F9;
  --dark-border:#334155;
}

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

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

body {
  font-family: 'Inter', 'Segoe UI', sans-serif;
  background: var(--body-bg);
  color: var(--text-primary);
  line-height: 1.6;
  transition: background 0.3s, color 0.3s;
  min-height: 100vh;
}


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

img { max-width: 100%; height: auto; }

h1,h2,h3,h4,h5,h6 { font-family: 'Poppins','Segoe UI',sans-serif; font-weight: 600; line-height: 1.3; }
code, .mono { font-family: 'Courier New', monospace; }

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

.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  margin-top: var(--navbar-height);
  padding: 24px;
  padding-bottom: 48px;
  transition: margin-left 0.3s cubic-bezier(0.4,0,0.2,1);
  min-width: 0;
}

.app-wrapper.sidebar-collapsed .main-content {
  margin-left: var(--sidebar-collapsed);
}

/* ============================================================
   NAVBAR
   ============================================================ */
.navbar {
  position: fixed;
  top: 0; left: var(--sidebar-width); right: 0;
  height: var(--navbar-height);
  background: var(--navbar-bg);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 20px;
  gap: 12px;
  z-index: 100;
  box-shadow: var(--shadow);
  transition: left 0.3s cubic-bezier(0.4,0,0.2,1), background 0.3s;
}

.app-wrapper.sidebar-collapsed .navbar {
  left: var(--sidebar-collapsed);
}

.navbar-title {
  flex: 1;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.navbar-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hamburger {
  display: none;
  flex-direction: column;
  gap: 4px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  border-radius: 6px;
}
.hamburger span {
  width: 20px; height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  display: block;
  transition: all 0.3s;
}
.hamburger:hover { background: var(--primary-light); }

.icon-btn {
  background: none;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 6px 10px;
  cursor: pointer;
  font-size: 1rem;
  color: var(--text-primary);
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: background 0.2s, border-color 0.2s;
  text-decoration: none;
}
.icon-btn:hover { background: var(--primary-light); border-color: var(--primary); text-decoration: none; }

.nav-badge {
  position: absolute;
  top: -4px; right: -4px;
  background: #E02424;
  color: #fff;
  font-size: 0.65rem;
  font-weight: 700;
  border-radius: 9999px;
  min-width: 16px; height: 16px;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px;
}

/* Avatar */
.avatar-wrap { position: relative; }
.avatar-btn {
  background: none; border: 1px solid var(--border);
  border-radius: 10px; padding: 4px 10px 4px 6px;
  cursor: pointer; display: flex; align-items: center; gap: 8px;
  transition: background 0.2s;
}
.avatar-btn:hover { background: var(--primary-light); }
.avatar-img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.avatar-info { display: flex; flex-direction: column; text-align: left; }
.avatar-name { font-size: 0.82rem; font-weight: 600; color: var(--text-primary); line-height: 1.2; }
.avatar-role { font-size: 0.7rem; color: var(--text-secondary); }
.avatar-dropdown {
  position: absolute; right: 0; top: calc(100% + 6px);
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: var(--shadow-lg);
  min-width: 180px;
  padding: 6px 0;
  z-index: 200;
  display: none;
  animation: fadeSlideUp 0.15s ease forwards;
}
.avatar-dropdown.open { display: block; }
.dropdown-item {
  display: block; padding: 9px 16px;
  font-size: 0.87rem; color: var(--text-primary);
  transition: background 0.15s;
}
.dropdown-item:hover { background: var(--primary-light); text-decoration: none; }
.dropdown-item.text-danger { color: #E02424; }
.dropdown-divider { border: none; border-top: 1px solid var(--border); margin: 4px 0; }

/* ============================================================
   PAGE CONTENT
   ============================================================ */
.page-content {
  animation: fadeSlideUp 0.4s ease forwards;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

.page-header h1 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
}

/* ============================================================
   CARDS
   ============================================================ */
.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 20px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.card-header {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Stat cards */
.stat-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  cursor: default;
}
.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}
.stat-icon {
  font-size: 1.8rem;
  width: 48px; height: 48px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.stat-body { flex: 1; min-width: 0; }
.stat-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.2;
  font-family: 'Poppins', sans-serif;
}
.stat-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 500;
  margin-top: 2px;
}

/* Colored card backgrounds */
.bg-lavender { background: var(--card-lavender) !important; }
.bg-mint      { background: var(--card-mint)     !important; }
.bg-peach     { background: var(--card-peach)    !important; }
.bg-sky       { background: var(--card-sky)      !important; }
.bg-purple    { background: var(--card-purple)   !important; }

/* Summary card (large) */
.summary-card {
  border-radius: 14px;
  padding: 20px;
  border: 1px solid transparent;
}
.summary-card .summary-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 16px;
}

/* ============================================================
   GRID LAYOUTS
   ============================================================ */
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.grid-auto { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 16px; }

/* Dashboard grid: left big + right big */
.dashboard-top { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.dashboard-mini { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }

/* ============================================================
   TABLES
   ============================================================ */
.table-wrap { overflow-x: auto; border-radius: 12px; border: 1px solid var(--border); }

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card-bg);
  font-size: 0.88rem;
}

thead tr {
  background: var(--primary-light);
}

th {
  padding: 11px 14px;
  text-align: left;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

td {
  padding: 11px 14px;
  border-top: 1px solid var(--border);
  color: var(--text-primary);
  vertical-align: middle;
}

tbody tr:hover { background: var(--primary-light); }
tbody tr:last-child td { border-bottom: none; }

.mono-id { font-family: 'Courier New', monospace; font-size: 0.82rem; font-weight: 600; }

/* Assessment table badges */
.badge-teal   { background: #00BCD4; color: #fff; padding: 2px 9px; border-radius: 12px; font-size: 0.78rem; font-weight: 600; white-space: nowrap; }
.badge-green  { background: #4CAF50; color: #fff; padding: 2px 9px; border-radius: 12px; font-size: 0.78rem; font-weight: 600; white-space: nowrap; }
.badge-red    { background: #F44336; color: #fff; padding: 2px 9px; border-radius: 12px; font-size: 0.78rem; font-weight: 600; white-space: nowrap; }
.badge-blue   { background: #2196F3; color: #fff; padding: 2px 9px; border-radius: 12px; font-size: 0.78rem; font-weight: 600; white-space: nowrap; }
.badge-gray   { background: #9E9E9E; color: #fff; padding: 2px 9px; border-radius: 12px; font-size: 0.78rem; font-weight: 600; white-space: nowrap; }
.badge-orange { background: #FF9800; color: #fff; padding: 2px 9px; border-radius: 12px; font-size: 0.78rem; font-weight: 600; white-space: nowrap; }

.total-row td { font-weight: 700; background: var(--primary-light); }

/* ============================================================
   FORMS
   ============================================================ */
.form-group { margin-bottom: 16px; }
.form-group label {
  display: block;
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.form-control, .form-select {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.9rem;
  color: var(--text-primary);
  background: var(--card-bg);
  transition: border-color 0.2s, box-shadow 0.2s;
  font-family: inherit;
}
.form-control:focus, .form-select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(26,86,219,0.12);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 18px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
  text-decoration: none;
  white-space: nowrap;
}
.btn:hover { text-decoration: none; }
.btn-primary   { background: var(--primary);  color: #fff; }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-success   { background: #057A55; color: #fff; }
.btn-success:hover { background: #045a3e; }
.btn-danger    { background: #E02424; color: #fff; }
.btn-danger:hover  { background: #b91c1c; }
.btn-warning   { background: #FF8A00; color: #fff; }
.btn-teal      { background: #0E9F6E; color: #fff; }
.btn-teal:hover { background: #0a7d56; }
.btn-outline   { background: transparent; border: 1px solid var(--border); color: var(--text-primary); }
.btn-outline:hover { background: var(--primary-light); border-color: var(--primary); }
.btn-sm { padding: 5px 12px; font-size: 0.8rem; }
.btn-xs { padding: 3px 8px; font-size: 0.75rem; border-radius: 6px; }

.action-btns { display: flex; gap: 6px; flex-wrap: wrap; }

/* ============================================================
   PROFILE PAGE
   ============================================================ */
.profile-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }

.profile-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 24px;
  text-align: center;
}

.profile-avatar {
  width: 120px; height: 120px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  margin: 0 auto 14px;
  border: 4px solid var(--primary);
  display: block;
  box-shadow: 0 4px 16px rgba(26,86,219,0.18);
}
.profile-avatar-placeholder {
  width: 120px; height: 120px;
  border-radius: 50%;
  background: linear-gradient(135deg, #FF8A00, #E02424);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 14px;
  font-size: 2.8rem;
  color: #fff;
  font-weight: 700;
  box-shadow: 0 4px 16px rgba(0,0,0,0.12);
}

.profile-name { font-size: 1.05rem; font-weight: 700; color: var(--text-primary); margin-bottom: 16px; }

.profile-illustration {
  font-size: 3.5rem;
  margin-bottom: 12px;
  display: block;
}

.profile-field {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  text-align: left;
  margin-bottom: 8px;
  font-size: 0.87rem;
}
.profile-field-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--primary);
  flex-shrink: 0;
  margin-top: 5px;
}
.profile-field-label { color: var(--text-secondary); font-weight: 500; min-width: 110px; flex-shrink: 0; }
.profile-field-value { color: var(--text-primary); font-weight: 600; }

/* ============================================================
   COURSE DETAIL
   ============================================================ */
.course-header-card {
  background: var(--primary-light);
  border-radius: 12px;
  padding: 16px 20px;
  margin-bottom: 20px;
  border-left: 4px solid var(--primary);
}
.course-header-card p { margin-bottom: 4px; font-size: 0.9rem; }
.course-header-card strong { color: var(--primary); }

/* ============================================================
   MATERIAL CARD
   ============================================================ */
.material-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  transition: box-shadow 0.2s;
}
.material-card:hover { box-shadow: var(--shadow-md); }
.material-icon { font-size: 2rem; }
.material-info { flex: 1; }
.material-title { font-weight: 600; font-size: 0.9rem; }
.material-date  { font-size: 0.78rem; color: var(--text-secondary); }

/* ============================================================
   FEE CARDS
   ============================================================ */
.fee-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.fee-row {
  display: flex; justify-content: space-between; align-items: center;
  padding: 8px 0; border-bottom: 1px dashed var(--border);
  font-size: 0.88rem;
}
.fee-row:last-child { border-bottom: none; }
.fee-label { color: var(--text-secondary); font-weight: 500; }
.fee-value { font-weight: 700; font-family: 'Poppins', sans-serif; }
.fee-value.green  { color: #057A55; }
.fee-value.red    { color: #E02424; }
.fee-value.blue   { color: var(--primary); }
.fee-value.orange { color: #FF8A00; }

/* ============================================================
   ALERTS
   ============================================================ */
.alert {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 16px;
  font-size: 0.88rem;
  display: flex; align-items: center; gap: 8px;
}
.alert-success { background: #F0FFF4; border: 1px solid #057A55; color: #057A55; }
.alert-error   { background: #FFF5F5; border: 1px solid #E02424; color: #E02424; }
.alert-warning { background: #FFFBEB; border: 1px solid #FF8A00; color: #FF8A00; }
.alert-info    { background: var(--primary-light); border: 1px solid var(--primary); color: var(--primary); }

/* ============================================================
   SEARCH BAR
   ============================================================ */
.search-wrap {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
  margin-bottom: 20px;
}
.search-input-wrap {
  position: relative;
  flex: 1;
  min-width: 200px;
  max-width: 360px;
}
.search-input-wrap input {
  padding-left: 36px;
}
.search-icon {
  position: absolute;
  left: 10px; top: 50%;
  transform: translateY(-50%);
  color: var(--text-secondary);
  font-size: 1rem;
  pointer-events: none;
}

/* ============================================================
   PAGINATION
   ============================================================ */
.pagination-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  flex-wrap: wrap;
}
.pagination { display: flex; gap: 4px; list-style: none; }
.page-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.85rem;
  color: var(--text-primary);
  text-decoration: none;
  transition: all 0.15s;
}
.page-btn:hover, .page-btn.active {
  background: var(--primary); color: #fff;
  border-color: var(--primary);
  text-decoration: none;
}
.page-info { font-size: 0.82rem; color: var(--text-secondary); }

/* ============================================================
   TOAST NOTIFICATIONS
   ============================================================ */
.toast-container {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 9999;
  display: flex; flex-direction: column; gap: 10px;
  pointer-events: none;
}
.toast {
  min-width: 280px; max-width: 360px;
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.18);
  padding: 13px 18px 13px 14px;
  display: flex; align-items: center; gap: 10px;
  animation: toastIn 0.35s cubic-bezier(0.4,0,0.2,1) forwards;
  pointer-events: auto;
  border-left: 4px solid var(--primary);
}
.toast.toast-success { border-left-color: #057A55; }
.toast.toast-error   { border-left-color: #E02424; }
.toast.toast-warning { border-left-color: #FF8A00; }
.toast.toast-info    { border-left-color: var(--primary); }
.toast-icon { font-size: 1.2rem; flex-shrink: 0; }
.toast-message { flex: 1; font-size: 0.87rem; font-weight: 500; color: var(--text-primary); }
.toast-close {
  background: none; border: none; cursor: pointer;
  color: var(--text-secondary); font-size: 1rem; padding: 0 2px;
  flex-shrink: 0;
}
.toast-exit { animation: toastOut 0.3s ease forwards; }

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}

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

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

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Staggered card animation */
.stagger > * {
  animation: fadeSlideUp 0.4s ease both;
}
.stagger > *:nth-child(1) { animation-delay: 0.05s; }
.stagger > *:nth-child(2) { animation-delay: 0.10s; }
.stagger > *:nth-child(3) { animation-delay: 0.15s; }
.stagger > *:nth-child(4) { animation-delay: 0.20s; }
.stagger > *:nth-child(5) { animation-delay: 0.25s; }
.stagger > *:nth-child(6) { animation-delay: 0.30s; }

/* ============================================================
   LOGIN PAGE
   ============================================================ */
.login-body {
  min-height: 100vh;
  background: linear-gradient(135deg, #0F172A 0%, #1E2A3B 60%, #1141A8 100%);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.login-card {
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 20px;
  padding: 40px;
  width: 100%; max-width: 420px;
  animation: fadeSlideUp 0.5s ease forwards;
}
.login-logo {
  text-align: center;
  margin-bottom: 28px;
}
.login-logo img { width: 70px; height: 70px; border-radius: 16px; }
.login-logo h1 { color: #fff; font-size: 1.3rem; margin-top: 10px; }
.login-logo p  { color: rgba(255,255,255,0.6); font-size: 0.83rem; margin-top: 4px; }
.login-card .form-group label { color: rgba(255,255,255,0.8); }
.login-card .form-control {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.15);
  color: #fff;
}
.login-card .form-control:focus {
  border-color: var(--primary);
  background: rgba(255,255,255,0.12);
}
.login-card .form-control::placeholder { color: rgba(255,255,255,0.35); }
.btn-login {
  width: 100%;
  background: var(--primary);
  color: #fff;
  padding: 12px;
  font-size: 1rem;
  font-weight: 700;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  margin-top: 8px;
  transition: all 0.2s;
}
.btn-login:hover { background: var(--primary-dark); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(26,86,219,0.4); }
.login-footer { text-align: center; margin-top: 20px; color: rgba(255,255,255,0.5); font-size: 0.78rem; }
.login-error {
  background: rgba(224,36,36,0.15);
  border: 1px solid rgba(224,36,36,0.4);
  color: #fca5a5;
  padding: 10px 14px;
  border-radius: 8px;
  margin-bottom: 16px;
  font-size: 0.85rem;
}

/* ============================================================
   EMPTY STATES
   ============================================================ */
.empty-state {
  text-align: center;
  padding: 48px 20px;
  color: var(--text-secondary);
}
.empty-state-icon { font-size: 3rem; margin-bottom: 12px; opacity: 0.5; }
.empty-state p { font-size: 0.9rem; }

/* ============================================================
   UTILITY
   ============================================================ */
.text-center { text-align: center; }
.text-right  { text-align: right; }
.text-muted  { color: var(--text-secondary) !important; }
.text-primary-c { color: var(--primary) !important; }
.text-success { color: #057A55 !important; }
.text-danger  { color: #E02424 !important; }
.fw-600 { font-weight: 600; }
.fw-700 { font-weight: 700; }
.fs-sm  { font-size: 0.82rem; }
.mb-0   { margin-bottom: 0; }
.mb-1   { margin-bottom: 8px; }
.mb-2   { margin-bottom: 16px; }
.mb-3   { margin-bottom: 24px; }
.mt-2   { margin-top: 16px; }
.mt-3   { margin-top: 24px; }
.gap-2  { gap: 16px; }
.d-flex { display: flex; }
.align-center { align-items: center; }
.flex-1 { flex: 1; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1024px) {
  .sidebar { width: var(--sidebar-collapsed); }
  .sidebar .sidebar-label { display: none; }
  .sidebar .sidebar-title { display: none; }
  .sidebar .sidebar-collapse-btn { display: none; }
  .main-content { margin-left: var(--sidebar-collapsed); }
  .navbar { left: var(--sidebar-collapsed); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .dashboard-mini { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .sidebar { 
    transform: translateX(-100%);
    width: var(--sidebar-width) !important;
    z-index: 300;
    transition: transform 0.3s cubic-bezier(0.4,0,0.2,1);
  }
  .sidebar .sidebar-label { display: inline !important; }
  .sidebar .sidebar-title { display: flex !important; }
  .sidebar.mobile-open { transform: translateX(0); }
  .sidebar-overlay {
    display: block;
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 299;
    opacity: 0; pointer-events: none;
    transition: opacity 0.3s;
  }
  .sidebar-overlay.active { opacity: 1; pointer-events: auto; }
  .main-content { margin-left: 0 !important; }
  .navbar { left: 0 !important; }
  .hamburger { display: flex; }
  .profile-grid { grid-template-columns: 1fr; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .dashboard-top { grid-template-columns: 1fr; }
  .dashboard-mini { grid-template-columns: 1fr 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .form-row-3 { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .main-content { padding: 14px; }
  .dashboard-mini { grid-template-columns: 1fr; }
  .avatar-info { display: none; }
}
