/* ============================================================
   SCHOOL MANAGEMENT SYSTEM — PREMIUM REDESIGN v2
   Clean · Modern · Responsive · Inter Font
   ============================================================ */

/* ── CSS CUSTOM PROPERTIES ───────────────────────────────────── */
:root {
  /* Brand Palette */
  --primary:         #4f46e5;   /* Indigo */
  --primary-hover:   #4338ca;
  --primary-light:   #eef2ff;
  --primary-dark:    #3730a3;
  --accent:          #06b6d4;   /* Cyan */
  --accent-light:    #ecfeff;

  /* Status */
  --success:   #10b981;
  --success-bg:#d1fae5;
  --warning:   #f59e0b;
  --warning-bg:#fef3c7;
  --danger:    #ef4444;
  --danger-bg: #fee2e2;
  --info:      #3b82f6;
  --info-bg:   #dbeafe;

  /* Surfaces */
  --bg:         #f1f5f9;
  --surface:    #ffffff;
  --surface-2:  #f8fafc;
  --surface-3:  #f1f5f9;
  --border:     #e2e8f0;
  --border-2:   #cbd5e1;

  /* Text */
  --text:    #0f172a;
  --text-2:  #475569;
  --text-3:  #94a3b8;
  --text-4:  #cbd5e1;

  /* Sidebar */
  --sb-bg:        #0f172a;
  --sb-surface:   #1e293b;
  --sb-border:    rgba(148,163,184,.1);
  --sb-text:      #94a3b8;
  --sb-text-h:    #e2e8f0;
  --sb-active-bg: rgba(79,70,229,.18);
  --sb-active:    #a5b4fc;
  --sb-width:     256px;
  --topbar-h:     62px;

  /* Shape */
  --r-xs:  4px;
  --r-sm:  8px;
  --r:     12px;
  --r-lg:  16px;
  --r-xl:  20px;
  --r-2xl: 24px;
  --r-full:9999px;

  /* Shadow */
  --sh-xs: 0 1px 2px rgba(0,0,0,.04);
  --sh-sm: 0 1px 3px rgba(0,0,0,.07), 0 1px 2px rgba(0,0,0,.04);
  --sh:    0 4px 6px -1px rgba(0,0,0,.07), 0 2px 4px -1px rgba(0,0,0,.04);
  --sh-md: 0 10px 15px -3px rgba(0,0,0,.08), 0 4px 6px -2px rgba(0,0,0,.04);
  --sh-lg: 0 20px 25px -5px rgba(0,0,0,.10), 0 10px 10px -5px rgba(0,0,0,.04);
  --sh-xl: 0 25px 50px -12px rgba(0,0,0,.20);

  /* Motion */
  --t: .15s cubic-bezier(.4,0,.2,1);
  --ts:.28s cubic-bezier(.4,0,.2,1);
}

/* ── RESET ───────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { height: 100%; scroll-behavior: smooth; }
body {
  height: 100%;
  overflow: hidden;
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  font-size: 14px;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* ═══════════════════════════════════════════════════════════════
   SHELL
═══════════════════════════════════════════════════════════════ */
.app-shell {
  display: flex;
  height: 100vh;
  overflow: hidden;
}

/* ═══════════════════════════════════════════════════════════════
   SIDEBAR
═══════════════════════════════════════════════════════════════ */
.sidebar {
  width: var(--sb-width);
  height: 100vh;
  background: var(--sb-bg);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0;
  z-index: 1050;
  transition: transform var(--ts);
  flex-shrink: 0;
}

/* Brand -------------------------------------------------------- */
.sb-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 18px 16px 16px;
  border-bottom: 1px solid var(--sb-border);
  text-decoration: none;
  flex-shrink: 0;
}

.sb-logo-mark {
  width: 38px; height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary) 0%, #7c3aed 100%);
  display: flex; align-items: center; justify-content: center;
  font-size: 1rem;
  color: #fff;
  flex-shrink: 0;
  box-shadow: 0 4px 14px rgba(79,70,229,.4);
}

.sb-brand-name {
  font-size: .88rem;
  font-weight: 700;
  color: #f1f5f9;
  letter-spacing: -.1px;
  line-height: 1.1;
}
.sb-brand-sub {
  font-size: .63rem;
  color: var(--sb-text);
  text-transform: uppercase;
  letter-spacing: .9px;
  font-weight: 500;
  margin-top: 2px;
  display: block;
}

/* Scrollable nav ----------------------------------------------- */
.sb-nav {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 8px 10px 10px;
}

.sb-nav::-webkit-scrollbar { width: 3px; }
.sb-nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,.08); border-radius: 4px; }

/* Section label */
.sb-section {
  font-size: .61rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #334155;
  padding: 14px 8px 5px;
}

/* Nav link */
.sb-link {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  color: var(--sb-text);
  font-size: .835rem;
  font-weight: 500;
  text-decoration: none;
  border: none;
  background: none;
  width: 100%;
  cursor: pointer;
  border-radius: var(--r-sm);
  transition: background var(--t), color var(--t);
  position: relative;
  white-space: nowrap;
  margin-bottom: 1px;
}

.sb-link i.sb-icon {
  font-size: .95rem;
  width: 20px;
  text-align: center;
  flex-shrink: 0;
  opacity: .6;
  transition: opacity var(--t);
}

.sb-link span { flex: 1; }

.sb-link:hover, .sb-link:focus-visible {
  background: rgba(255,255,255,.06);
  color: var(--sb-text-h);
  text-decoration: none;
  outline: none;
}
.sb-link:hover i.sb-icon, .sb-link:focus-visible i.sb-icon { opacity: 1; }

.sb-link.active {
  background: var(--sb-active-bg);
  color: var(--sb-active);
  font-weight: 600;
}
.sb-link.active i.sb-icon { opacity: 1; color: var(--sb-active); }

/* Sub-menu */
.sb-group-toggle { gap: 9px; }
.sb-chevron {
  margin-left: auto;
  font-size: .6rem !important;
  opacity: .4 !important;
  width: auto !important;
  transition: transform var(--t), opacity var(--t) !important;
}
.sb-link.active .sb-chevron { opacity: .7 !important; }

.sb-submenu {
  margin: 1px 0 3px 10px;
  border-left: 1px solid rgba(148,163,184,.12);
  padding-left: 4px;
}

.sb-sub-link {
  padding: 6px 10px 6px 14px;
  font-size: .8rem;
  color: #64748b;
  border-radius: var(--r-sm);
}
.sb-sub-link i.sb-icon { font-size: .8rem; opacity: .5; }
.sb-sub-link:hover { color: var(--sb-text-h); }
.sb-sub-link.active {
  background: rgba(79,70,229,.12);
  color: #a5b4fc;
  font-weight: 600;
}
.sb-sub-link.active i.sb-icon { color: #a5b4fc; opacity: 1; }

/* Bottom user card --------------------------------------------- */
.sb-footer {
  flex-shrink: 0;
  padding: 10px;
  border-top: 1px solid var(--sb-border);
}

.sb-user {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 10px;
  border-radius: var(--r-sm);
  background: rgba(255,255,255,.04);
  border: 1px solid var(--sb-border);
}

.sb-avatar {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: .78rem;
  font-weight: 700;
  flex-shrink: 0;
}

.sb-user-name {
  font-size: .8rem;
  font-weight: 600;
  color: #e2e8f0;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
}
.sb-user-role {
  font-size: .67rem;
  color: var(--sb-text);
  display: block;
  margin-top: 1px;
}

.sb-logout {
  margin-left: auto;
  background: none;
  border: none;
  color: var(--sb-text);
  font-size: .9rem;
  padding: 4px;
  border-radius: 6px;
  cursor: pointer;
  transition: color var(--t), background var(--t);
  flex-shrink: 0;
}
.sb-logout:hover { color: var(--danger); background: rgba(239,68,68,.1); }

/* ═══════════════════════════════════════════════════════════════
   MAIN WRAPPER
═══════════════════════════════════════════════════════════════ */
.main-wrap {
  flex: 1;
  margin-left: var(--sb-width);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background: var(--bg);
  overflow-y: auto;
  overflow-x: hidden;
}

/* ═══════════════════════════════════════════════════════════════
   TOPBAR
═══════════════════════════════════════════════════════════════ */
.topbar {
  height: var(--topbar-h);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  padding: 0 24px;
  gap: 12px;
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: var(--sh-xs);
}

.tb-toggle {
  display: none;
  width: 36px; height: 36px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  background: none;
  color: var(--text-2);
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--t);
  flex-shrink: 0;
}
.tb-toggle:hover { background: var(--surface-2); color: var(--text); }

.tb-search {
  flex: 1;
  max-width: 400px;
  margin: 0 auto;
}

.tb-search .input-group {
  background: var(--surface-2);
  border-radius: var(--r-full);
  border: 1.5px solid var(--border);
  overflow: hidden;
  transition: border-color var(--t), box-shadow var(--t);
}

.tb-search .input-group:focus-within {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79,70,229,.12);
  background: var(--surface);
}

.tb-search .input-group-text {
  background: transparent;
  border: none;
  color: var(--text-3);
  padding: 0 10px 0 14px;
  font-size: .82rem;
}

.tb-search input {
  background: transparent;
  border: none;
  font-size: .835rem;
  color: var(--text);
  padding: 8px 14px 8px 2px;
  font-family: inherit;
}
.tb-search input::placeholder { color: var(--text-3); }
.tb-search input:focus { box-shadow: none; outline: none; }

.tb-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  margin-left: auto;
}

.tb-btn {
  position: relative;
  width: 36px; height: 36px;
  border-radius: var(--r-sm);
  border: 1.5px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: all var(--t);
  font-size: .9rem;
  text-decoration: none;
}
.tb-btn:hover { background: var(--surface-2); color: var(--text); border-color: var(--border-2); text-decoration: none; }

.tb-badge {
  position: absolute;
  top: 5px; right: 5px;
  width: 7px; height: 7px;
  background: var(--danger);
  border-radius: 50%;
  border: 2px solid var(--surface);
}

.tb-user {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 4px 10px 4px 4px;
  border-radius: var(--r-full);
  border: 1.5px solid var(--border);
  background: var(--surface);
  cursor: pointer;
  transition: all var(--t);
  text-decoration: none;
  color: var(--text);
}
.tb-user:hover { background: var(--surface-2); color: var(--text); border-color: var(--border-2); text-decoration: none; }

.tb-avatar {
  width: 28px; height: 28px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: .72rem;
  font-weight: 700;
}

.tb-user-name {
  font-size: .82rem;
  font-weight: 600;
  max-width: 110px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ═══════════════════════════════════════════════════════════════
   PAGE CONTENT
═══════════════════════════════════════════════════════════════ */
.page-body {
  padding: 24px 28px;
  flex: 1;
}

/* Page header */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 22px;
}

.page-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--text);
  margin: 0;
  letter-spacing: -.3px;
  display: flex;
  align-items: center;
  gap: 9px;
}

.page-title i { color: var(--primary); font-size: 1.15rem; }

.page-subtitle {
  font-size: .82rem;
  color: var(--text-2);
  margin: 4px 0 0;
  font-weight: 400;
}

/* Breadcrumb */
.breadcrumb {
  background: none;
  padding: 0;
  margin: 5px 0 0;
  font-size: .76rem;
}
.breadcrumb-item + .breadcrumb-item::before { color: var(--text-4); }
.breadcrumb-item a { color: var(--primary); text-decoration: none; font-weight: 500; }
.breadcrumb-item a:hover { text-decoration: underline; }
.breadcrumb-item.active { color: var(--text-3); }

/* ═══════════════════════════════════════════════════════════════
   WELCOME BANNER
═══════════════════════════════════════════════════════════════ */
.welcome-banner {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 55%, #2563eb 100%);
  border-radius: var(--r-xl);
  padding: 26px 30px;
  color: #fff;
  position: relative;
  overflow: hidden;
  margin-bottom: 22px;
}

.welcome-banner::before {
  content: '';
  position: absolute;
  top: -30px; right: -20px;
  width: 180px; height: 180px;
  background: rgba(255,255,255,.07);
  border-radius: 50%;
  pointer-events: none;
}
.welcome-banner::after {
  content: '';
  position: absolute;
  bottom: -50px; right: 120px;
  width: 140px; height: 140px;
  background: rgba(6,182,212,.12);
  border-radius: 50%;
  pointer-events: none;
}

.welcome-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: rgba(255,255,255,.14);
  border: 1px solid rgba(255,255,255,.2);
  border-radius: var(--r-full);
  padding: 3px 10px;
  font-size: .72rem;
  font-weight: 600;
  margin-bottom: 9px;
  position: relative;
  z-index: 1;
}

.welcome-banner h4 { font-size: 1.15rem; font-weight: 700; margin: 0 0 4px; position: relative; z-index: 1; }
.welcome-banner p  { font-size: .82rem; opacity: .8; margin: 0; position: relative; z-index: 1; }

/* ═══════════════════════════════════════════════════════════════
   STAT CARDS
═══════════════════════════════════════════════════════════════ */
.stat-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--sh-sm);
  transition: transform var(--t), box-shadow var(--t);
  cursor: default;
  position: relative;
  overflow: hidden;
}

.stat-card:hover { transform: translateY(-2px); box-shadow: var(--sh-md); }
.stat-card::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  border-radius: var(--r-lg) var(--r-lg) 0 0;
}

/* Color accents */
.stat-card.blue::after   { background: linear-gradient(90deg, #3b82f6, #60a5fa); }
.stat-card.green::after  { background: linear-gradient(90deg, #10b981, #34d399); }
.stat-card.orange::after { background: linear-gradient(90deg, #f59e0b, #fbbf24); }
.stat-card.teal::after   { background: linear-gradient(90deg, #06b6d4, #22d3ee); }
.stat-card.red::after    { background: linear-gradient(90deg, #ef4444, #f87171); }
.stat-card.purple::after { background: linear-gradient(90deg, #8b5cf6, #a78bfa); }
.stat-card.navy::after   { background: linear-gradient(90deg, #4f46e5, #818cf8); }
.stat-card.pink::after   { background: linear-gradient(90deg, #ec4899, #f472b6); }

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

/* Icon bg colors */
.stat-icon.blue   { background: #eff6ff; color: #2563eb; }
.stat-icon.green  { background: var(--success-bg); color: var(--success); }
.stat-icon.orange { background: var(--warning-bg); color: #d97706; }
.stat-icon.teal   { background: var(--accent-light); color: #0891b2; }
.stat-icon.red    { background: var(--danger-bg); color: var(--danger); }
.stat-icon.purple { background: #f5f3ff; color: #7c3aed; }
.stat-icon.navy   { background: var(--primary-light); color: var(--primary); }
.stat-icon.pink   { background: #fdf2f8; color: #be185d; }

.stat-info { flex: 1; min-width: 0; }

.stat-value {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--text);
  line-height: 1;
  letter-spacing: -.4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stat-label {
  font-size: .76rem;
  color: var(--text-2);
  margin-top: 4px;
  font-weight: 500;
}

.stat-trend {
  font-size: .71rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-top: 6px;
  padding: 2px 6px;
  border-radius: var(--r-full);
}
.stat-trend.up   { background: var(--success-bg); color: #065f46; }
.stat-trend.down { background: var(--danger-bg);  color: #991b1b; }
.stat-trend.flat { background: var(--surface-3);  color: var(--text-2); }

/* ═══════════════════════════════════════════════════════════════
   MODULE / OVERVIEW LINK CARDS
═══════════════════════════════════════════════════════════════ */
.module-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--surface);
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  padding: 18px;
  text-decoration: none;
  color: var(--text);
  transition: all var(--t);
  box-shadow: var(--sh-xs);
}
.module-card:hover {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79,70,229,.08), var(--sh);
  transform: translateY(-2px);
  color: var(--text);
  text-decoration: none;
}

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

.module-info { flex: 1; min-width: 0; }
.module-info h6 { font-size: .88rem; font-weight: 600; margin: 0 0 2px; }
.module-info p  { font-size: .77rem; color: var(--text-2); margin: 0; line-height: 1.45; }

.module-arrow { color: var(--text-4); font-size: .75rem; flex-shrink: 0; transition: transform var(--t), color var(--t); }
.module-card:hover .module-arrow { color: var(--primary); transform: translateX(3px); }

/* ═══════════════════════════════════════════════════════════════
   CARDS
═══════════════════════════════════════════════════════════════ */
.card, .school-card {
  background: var(--surface);
  border: 1px solid var(--border) !important;
  border-radius: var(--r-lg) !important;
  box-shadow: var(--sh-sm);
  overflow: hidden;
}

.card-header {
  background: var(--surface) !important;
  border-bottom: 1px solid var(--border) !important;
  padding: 14px 18px !important;
  font-weight: 600;
  font-size: .875rem;
  color: var(--text);
  border-radius: var(--r-lg) var(--r-lg) 0 0 !important;
}

.card-header h6 {
  margin: 0;
  font-size: .875rem;
  font-weight: 600;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.card-header h6 i { color: var(--primary); }

.card-body { padding: 18px !important; }

.card-footer {
  background: var(--surface-2) !important;
  border-top: 1px solid var(--border) !important;
  padding: 11px 18px !important;
  font-size: .8rem;
  color: var(--text-2);
  border-radius: 0 0 var(--r-lg) var(--r-lg) !important;
}

/* ═══════════════════════════════════════════════════════════════
   TABLES
═══════════════════════════════════════════════════════════════ */
.table {
  font-size: .84rem;
  color: var(--text);
  margin: 0;
  --bs-table-bg: transparent;
}

.table thead th {
  background: var(--surface-2) !important;
  color: var(--text-2);
  font-size: .7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .7px;
  border-bottom: 2px solid var(--border) !important;
  padding: 10px 14px;
  white-space: nowrap;
}

.table tbody td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--surface-3) !important;
  vertical-align: middle;
  color: var(--text);
  background: transparent;
}

.table tbody tr:last-child td { border-bottom: none !important; }
.table tbody tr { transition: background var(--t); }
.table tbody tr:hover td { background: #f8f7ff !important; }
.table-hover > tbody > tr:hover > * { background: #f8f7ff; }

/* ═══════════════════════════════════════════════════════════════
   FORMS
═══════════════════════════════════════════════════════════════ */
.form-control, .form-select {
  border: 1.5px solid var(--border);
  border-radius: var(--r-sm);
  font-size: .84rem;
  padding: 8px 12px;
  color: var(--text);
  background: var(--surface);
  transition: border-color var(--t), box-shadow var(--t);
  font-family: inherit;
}

.form-control:focus, .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79,70,229,.12);
  outline: none;
  background: var(--surface);
  color: var(--text);
}

.form-control::placeholder { color: var(--text-3); }

.form-label {
  font-size: .74rem;
  font-weight: 700;
  color: var(--text-2);
  margin-bottom: 5px;
  text-transform: uppercase;
  letter-spacing: .3px;
  display: block;
}

.form-text { font-size: .75rem; color: var(--text-3); margin-top: 4px; }

.input-group-text {
  background: var(--surface-2);
  border: 1.5px solid var(--border);
  color: var(--text-2);
  font-size: .84rem;
  padding: 8px 12px;
  font-family: inherit;
}

/* Field group heading */
.field-group-title {
  font-size: .7rem;
  font-weight: 800;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: .6px;
  padding-bottom: 7px;
  border-bottom: 2px solid var(--primary-light);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ═══════════════════════════════════════════════════════════════
   BUTTONS
═══════════════════════════════════════════════════════════════ */
.btn {
  font-family: 'Inter', inherit;
  font-size: .84rem;
  font-weight: 600;
  border-radius: var(--r-sm);
  padding: 8px 18px;
  transition: all var(--t);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  letter-spacing: -.1px;
}
.btn:active { transform: scale(.97) !important; }

.btn-primary {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
  box-shadow: 0 2px 8px rgba(79,70,229,.3);
}
.btn-primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  box-shadow: 0 4px 16px rgba(79,70,229,.4);
  transform: translateY(-1px);
  color: #fff;
}

.btn-success { background: var(--success); border-color: var(--success); color: #fff; }
.btn-success:hover { background: #059669; border-color: #059669; transform: translateY(-1px); color: #fff; }

.btn-danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn-danger:hover { background: #dc2626; border-color: #dc2626; transform: translateY(-1px); color: #fff; }

.btn-warning { background: var(--warning); border-color: var(--warning); color: #fff; }
.btn-warning:hover { background: #d97706; border-color: #d97706; transform: translateY(-1px); color: #fff; }

.btn-info { background: var(--info); border-color: var(--info); color: #fff; }
.btn-info:hover { background: #2563eb; border-color: #2563eb; transform: translateY(-1px); color: #fff; }

.btn-outline-primary { color: var(--primary); border-color: var(--primary); background: transparent; }
.btn-outline-primary:hover { background: var(--primary); color: #fff; transform: translateY(-1px); border-color: var(--primary); }

.btn-outline-secondary {
  color: var(--text-2);
  border: 1.5px solid var(--border);
  background: var(--surface);
}
.btn-outline-secondary:hover { background: var(--surface-2); color: var(--text); border-color: var(--border-2); }

.btn-sm  { font-size: .78rem; padding: 5px 12px; border-radius: var(--r-xs); }
.btn-lg  { font-size: .95rem; padding: 11px 26px; border-radius: var(--r); }
.btn-icon {
  width: 34px; height: 34px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  font-size: .88rem;
}

/* ═══════════════════════════════════════════════════════════════
   BADGES
═══════════════════════════════════════════════════════════════ */
.badge {
  font-family: inherit;
  font-size: .7rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: var(--r-full);
  letter-spacing: .05px;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

/* Soft variants */
.badge-soft-success  { background: var(--success-bg); color: #065f46; }
.badge-soft-danger   { background: var(--danger-bg);  color: #991b1b; }
.badge-soft-warning  { background: var(--warning-bg); color: #92400e; }
.badge-soft-info     { background: var(--info-bg);    color: #1e40af; }
.badge-soft-primary  { background: var(--primary-light); color: var(--primary-dark); }
.badge-soft-secondary{ background: var(--surface-3);  color: var(--text-2); }
.badge-soft-purple   { background: #ede9fe; color: #5b21b6; }

/* Status */
.badge-active    { background: var(--success-bg); color: #065f46; }
.badge-inactive  { background: var(--surface-3);  color: var(--text-2); }
.badge-paid      { background: var(--success-bg); color: #065f46; }
.badge-partial   { background: var(--info-bg);    color: #1e40af; }
.badge-pending   { background: var(--warning-bg); color: #92400e; }
.badge-overdue   { background: var(--danger-bg);  color: #991b1b; }
.badge-present   { background: var(--success-bg); color: #065f46; }
.badge-absent    { background: var(--danger-bg);  color: #991b1b; }
.badge-late      { background: var(--warning-bg); color: #92400e; }
.badge-leave     { background: #ede9fe; color: #5b21b6; }

/* ═══════════════════════════════════════════════════════════════
   MODAL
═══════════════════════════════════════════════════════════════ */
.modal-content {
  border: none;
  border-radius: var(--r-xl) !important;
  box-shadow: var(--sh-xl);
  overflow: hidden;
}
.modal-header {
  background: var(--surface-2) !important;
  border-bottom: 1px solid var(--border) !important;
  padding: 18px 22px !important;
}
.modal-title { font-size: .93rem; font-weight: 700; }
.modal-body  { padding: 22px !important; }
.modal-footer {
  background: var(--surface-2) !important;
  border-top: 1px solid var(--border) !important;
  padding: 14px 22px !important;
}
.modal-backdrop { backdrop-filter: blur(3px); background: rgba(15,23,42,.55) !important; }

/* ═══════════════════════════════════════════════════════════════
   ALERTS
═══════════════════════════════════════════════════════════════ */
.alert {
  border-radius: var(--r) !important;
  font-size: .84rem;
  padding: 11px 14px;
  display: flex;
  align-items: flex-start;
  gap: 9px;
  border: 1px solid transparent;
}
.alert-success { background: var(--success-bg); border-color: #a7f3d0; color: #064e3b; }
.alert-danger  { background: var(--danger-bg);  border-color: #fecaca; color: #7f1d1d; }
.alert-warning { background: var(--warning-bg); border-color: #fde68a; color: #78350f; }
.alert-info    { background: var(--info-bg);    border-color: #bfdbfe; color: #1e3a8a; }

/* ═══════════════════════════════════════════════════════════════
   NAV TABS
═══════════════════════════════════════════════════════════════ */
.nav-tabs { border-bottom: 2px solid var(--border) !important; }
.nav-tabs .nav-link {
  border: none !important;
  border-bottom: 2px solid transparent !important;
  border-radius: 0 !important;
  margin-bottom: -2px;
  color: var(--text-2);
  font-size: .84rem;
  font-weight: 500;
  padding: 9px 16px;
  background: none !important;
  cursor: pointer;
  transition: color var(--t), border-color var(--t);
}
.nav-tabs .nav-link:hover { color: var(--text); border-bottom-color: var(--border) !important; }
.nav-tabs .nav-link.active { color: var(--primary) !important; border-bottom-color: var(--primary) !important; font-weight: 700; }

/* ═══════════════════════════════════════════════════════════════
   PAGINATION
═══════════════════════════════════════════════════════════════ */
.page-link {
  border: 1px solid var(--border);
  color: var(--text-2);
  font-size: .82rem;
  padding: 6px 12px;
  transition: all var(--t);
  font-weight: 500;
  font-family: inherit;
}
.page-link:hover { background: var(--surface-2); color: var(--text); border-color: var(--border-2); }
.page-item.active .page-link { background: var(--primary); border-color: var(--primary); color: #fff; }
.page-item.disabled .page-link { color: var(--text-4); }

/* ═══════════════════════════════════════════════════════════════
   QUICK ACTIONS
═══════════════════════════════════════════════════════════════ */
.quick-action-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  padding: 16px 10px;
  border-radius: var(--r);
  background: var(--surface);
  border: 1.5px solid var(--border);
  color: var(--text-2);
  font-size: .74rem;
  font-weight: 600;
  text-decoration: none;
  transition: all var(--t);
  text-align: center;
  cursor: pointer;
  width: 100%;
}
.quick-action-btn i { font-size: 1.35rem; margin-bottom: 1px; }
.quick-action-btn:hover {
  background: var(--primary-light);
  border-color: #c7d2fe;
  color: var(--primary);
  text-decoration: none;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(79,70,229,.12);
}

/* ═══════════════════════════════════════════════════════════════
   ACTIVITY LIST
═══════════════════════════════════════════════════════════════ */
.activity-item {
  display: flex;
  gap: 11px;
  padding: 9px 0;
  border-bottom: 1px solid var(--surface-3);
  align-items: flex-start;
}
.activity-item:last-child { border-bottom: none; }
.activity-icon {
  width: 30px; height: 30px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: .77rem;
  flex-shrink: 0;
  margin-top: 1px;
}
.activity-content { flex: 1; font-size: .81rem; line-height: 1.45; color: var(--text); }
.activity-time    { font-size: .71rem; color: var(--text-3); margin-top: 1px; display: block; }

/* ═══════════════════════════════════════════════════════════════
   CHART
═══════════════════════════════════════════════════════════════ */
.chart-container { position: relative; height: 240px; }
.chart-placeholder {
  height: 200px;
  border: 2px dashed var(--border);
  border-radius: var(--r);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--text-3);
  gap: 9px;
  font-size: .8rem;
  background: var(--surface-2);
}
.chart-placeholder i { font-size: 2rem; opacity: .3; }

/* ═══════════════════════════════════════════════════════════════
   PROFILE / DETAIL VIEW
═══════════════════════════════════════════════════════════════ */
.profile-cover {
  height: 90px;
  background: linear-gradient(135deg, var(--primary) 0%, #7c3aed 100%);
  border-radius: var(--r-lg) var(--r-lg) 0 0;
  position: relative;
}
.profile-avatar-wrap {
  position: absolute;
  bottom: -26px;
  left: 22px;
}
.profile-avatar-lg {
  width: 68px; height: 68px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #7c3aed);
  display: flex; align-items: center; justify-content: center;
  color: #fff;
  font-size: 1.7rem;
  font-weight: 700;
  border: 4px solid var(--surface);
  box-shadow: var(--sh);
}

/* ═══════════════════════════════════════════════════════════════
   TIMETABLE
═══════════════════════════════════════════════════════════════ */
.timetable-grid th {
  background: var(--primary);
  color: #fff;
  text-align: center;
  padding: 10px 8px;
  font-size: .75rem;
  font-weight: 600;
  letter-spacing: .1px;
}
.timetable-cell {
  min-height: 62px;
  padding: 6px;
  font-size: .77rem;
  text-align: center;
  border: 1px solid var(--border);
  background: var(--surface);
  transition: background var(--t);
}
.timetable-cell:hover { background: var(--primary-light); }
.timetable-subject { font-weight: 600; color: var(--primary); font-size: .8rem; }
.timetable-teacher { color: var(--text-2); font-size: .7rem; margin-top: 2px; }
.timetable-break   { background: var(--surface-2); color: var(--text-3); font-style: italic; }

/* ═══════════════════════════════════════════════════════════════
   SKELETON
═══════════════════════════════════════════════════════════════ */
.skeleton {
  background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 50%, #f1f5f9 75%);
  background-size: 200% 100%;
  animation: shimmer 1.6s infinite;
  border-radius: var(--r-sm);
}
@keyframes shimmer {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}
.skeleton-text   { height: 13px; border-radius: 4px; }
.skeleton-circle { border-radius: 50%; }

/* ═══════════════════════════════════════════════════════════════
   EMPTY STATE
═══════════════════════════════════════════════════════════════ */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 52px 24px;
  text-align: center;
}
.empty-state i   { font-size: 3.2rem; color: var(--border-2); margin-bottom: 14px; }
.empty-state h6  { font-size: .93rem; font-weight: 600; color: var(--text); margin-bottom: 5px; }
.empty-state p   { font-size: .81rem; color: var(--text-2); margin: 0; }

/* ═══════════════════════════════════════════════════════════════
   PHOTO / AVATAR
═══════════════════════════════════════════════════════════════ */
.avatar-sm { width: 30px; height: 30px; border-radius: 50%; font-size: .76rem; }
.avatar-md { width: 40px; height: 40px; border-radius: 50%; font-size: .95rem; }
.avatar-lg { width: 54px; height: 54px; border-radius: 50%; font-size: 1.2rem; }
.avatar-xl { width: 76px; height: 76px; border-radius: 50%; font-size: 1.8rem; }
.photo-placeholder {
  background: var(--surface-2);
  display: flex; align-items: center; justify-content: center;
  color: var(--border-2);
  font-size: 2.2rem;
  border: 2px dashed var(--border);
}
.photo-preview { border-radius: 50%; object-fit: cover; border: 3px solid var(--border); }

/* ═══════════════════════════════════════════════════════════════
   CUSTOM SCROLLBAR (main)
═══════════════════════════════════════════════════════════════ */
.main-wrap::-webkit-scrollbar        { width: 5px; }
.main-wrap::-webkit-scrollbar-track  { background: var(--bg); }
.main-wrap::-webkit-scrollbar-thumb  { background: var(--border-2); border-radius: 4px; }
.main-wrap::-webkit-scrollbar-thumb:hover { background: #94a3b8; }

/* ═══════════════════════════════════════════════════════════════
   MOBILE OVERLAY
═══════════════════════════════════════════════════════════════ */
.sb-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15,23,42,.6);
  z-index: 1040;
  backdrop-filter: blur(2px);
  cursor: pointer;
}
.sb-overlay.show { display: block; }

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════════ */
@media (max-width: 991.98px) {
  .sidebar { transform: translateX(calc(-1 * var(--sb-width))); box-shadow: none; }
  .sidebar.open { transform: translateX(0); box-shadow: var(--sh-xl); }
  .main-wrap { margin-left: 0; }
  .page-body { padding: 18px 16px; }
  .topbar { padding: 0 14px; }
  .tb-toggle { display: flex; }
  .tb-search { max-width: 280px; }
}

@media (max-width: 767.98px) {
  .tb-search { display: none; }
  .welcome-banner { padding: 18px 20px; }
  .page-title { font-size: 1.1rem; }
  .stat-value { font-size: 1.35rem; }
  .stat-card { padding: 14px; }
}

@media (max-width: 575.98px) {
  .page-body { padding: 12px; }
  .btn { min-height: 42px; }
  .card-body { padding: 14px !important; }
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE LAYOUT — shell, headers, tables (all screen sizes)
═══════════════════════════════════════════════════════════════ */
img, svg, video { max-width: 100%; }
.main-wrap { min-width: 0; }

/* Desktop: fixed sidebar, content sits to its right exactly once */
@media (min-width: 992px) {
  .sidebar { position: fixed; top: 0; left: 0; }
  .main-wrap { margin-left: var(--sb-width); }
}

/* Headers and toolbars wrap onto new lines instead of overflowing */
.page-body .d-flex.justify-content-between,
.page-body .d-flex.align-items-center { flex-wrap: wrap; gap: 10px; }
.page-header { gap: 12px; }
.page-header > div:first-child { min-width: 0; flex: 1 1 240px; }
.page-header > .d-flex { flex-wrap: wrap; }
.card-header.d-flex { flex-wrap: wrap; gap: 8px; }

/* Wide tables scroll inside their card instead of pushing the page sideways */
.card > .table-responsive,
.table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.card > .table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }

@media (max-width: 991.98px) {
  .topbar { gap: 8px; }
  .page-title { font-size: 1.15rem; }
}

@media (max-width: 575.98px) {
  .page-header { flex-direction: column; align-items: stretch; }
  .page-header .btn { width: 100%; }
  .page-header > .d-flex { width: 100%; }
  .page-header > .d-flex .btn { flex: 1 1 auto; }
  .card-footer.d-flex { flex-direction: column; align-items: stretch; gap: 8px; }
  .modal-dialog { margin: .5rem; }
  .stat-value { font-size: 1.2rem; }
  /* Filter bars: two fields per row on phones instead of a long stack */
  .card-body > .row > [class*="col-md-"] { flex: 0 0 50%; max-width: 50%; }
  .card-body > .row > [class*="col-md-"] .btn { width: 100%; }
}

/* ═══════════════════════════════════════════════════════════════
   PRINT
═══════════════════════════════════════════════════════════════ */
@media print {
  .no-print, .sidebar, .topbar { display: none !important; }
  .main-wrap { margin-left: 0 !important; }
  body { overflow: auto !important; background: #fff !important; }
  .card, .school-card { box-shadow: none !important; border: 1px solid #ddd !important; }
}

/* ═══════════════════════════════════════════════════════════════
   BOOTSTRAP OVERRIDES
═══════════════════════════════════════════════════════════════ */
.text-primary { color: var(--primary) !important; }
.text-muted   { color: var(--text-2) !important; }
.bg-primary   { background-color: var(--primary) !important; }
.border-primary { border-color: var(--primary) !important; }
.fw-semibold { font-weight: 600 !important; }
.fw-medium   { font-weight: 500 !important; }

/* Spinner */
.spinner-border { border-color: var(--primary); border-right-color: transparent; }
.spinner-border.text-primary { border-color: var(--primary); border-right-color: transparent; }

/* Dropdown */
.dropdown-menu {
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-lg);
  font-size: .84rem;
  padding: 6px;
}
.dropdown-item {
  border-radius: var(--r-sm);
  padding: 7px 12px;
  font-family: inherit;
  font-size: .84rem;
  color: var(--text);
  transition: background var(--t);
}
.dropdown-item:hover { background: var(--primary-light); color: var(--primary); }

/* Tooltip */
.tooltip .tooltip-inner {
  font-size: .76rem;
  border-radius: var(--r-sm);
  padding: 4px 10px;
  font-family: inherit;
  background: var(--text);
}

/* ═══════════════════════════════════════════════════════════════
   MOTION — entrance reveals, progress ring, status pulse
   (all disabled for users who prefer reduced motion)
═══════════════════════════════════════════════════════════════ */
@keyframes sms-fade-up {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}
@keyframes sms-fade-in  { from { opacity: 0; } to { opacity: 1; } }
@keyframes sms-scale-in { from { opacity: 0; transform: scale(.96); } to { opacity: 1; transform: none; } }
@keyframes sms-pop {
  0%   { transform: scale(.4); opacity: 0; }
  60%  { transform: scale(1.12); opacity: 1; }
  100% { transform: scale(1); }
}
@keyframes sms-ring-fill { from { stroke-dashoffset: 314.16; } }
@keyframes sms-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-6px); } }
@keyframes sms-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(239, 68, 68, .45); }
  70%  { box-shadow: 0 0 0 7px rgba(239, 68, 68, 0); }
  100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

/* `backwards` (not `both`) so hover transforms on cards still work after the reveal ends */
.reveal {
  animation: sms-fade-up .55s cubic-bezier(.2, .7, .2, 1) backwards;
  animation-delay: calc(var(--i, 0) * 70ms);
}
.modal-anim          { animation: sms-scale-in .25s ease-out backwards; }
.modal-backdrop-anim { animation: sms-fade-in .2s ease-out backwards; }
.status-pulse        { animation: sms-pulse 1.8s ease-out infinite; }

/* Collection-rate ring */
.collect-ring { transform: rotate(-90deg); flex-shrink: 0; }
.collect-ring .ring-track { fill: none; stroke: var(--surface-3); stroke-width: 10; }
.collect-ring .ring-value {
  fill: none;
  stroke: var(--success);
  stroke-width: 10;
  stroke-linecap: round;
  stroke-dasharray: 314.16;
  stroke-dashoffset: calc(314.16 * (1 - var(--pct, 0)));
  animation: sms-ring-fill 1.2s cubic-bezier(.2, .7, .2, 1) backwards;
}

/* Receipts and student highlights */
.receipt-banner {
  display: flex; align-items: center; gap: 14px;
  padding: 14px 16px;
  background: var(--success-bg);
  border: 1px solid #a7f3d0;
  border-radius: var(--r-lg);
}
.rb-check {
  width: 38px; height: 38px; border-radius: 50%;
  background: var(--success); color: #fff;
  display: grid; place-items: center; font-size: 1.1rem;
  animation: sms-pop .5s cubic-bezier(.3, 1.4, .6, 1) backwards;
}
.student-avatar {
  width: 44px; height: 44px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff; font-weight: 700; font-size: 1.05rem;
  display: grid; place-items: center;
  box-shadow: var(--sh-md);
}
/* Currency stat values shrink with the card instead of truncating to "Rs..." */
.stat-value.money {
  font-size: clamp(1.1rem, 1.4vw, 1.5rem);
  white-space: normal;   /* wrap at the space in "Rs. 5,100" instead of truncating */
  overflow: visible;
  line-height: 1.1;
}

.empty-state { text-align: center; padding: 56px 20px; color: var(--text-3); }
.empty-orb {
  width: 84px; height: 84px; margin: 0 auto; border-radius: 50%;
  display: grid; place-items: center; font-size: 2rem; color: var(--primary);
  background: radial-gradient(circle at 30% 30%, #fff, var(--primary-light));
  animation: sms-float 3s ease-in-out infinite;
}
.pay-summary {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 14px;
  background: var(--surface-2);
  border: 1px dashed var(--border-2);
  border-radius: var(--r-sm);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ═══════════════════════════════════════════════════════════════
   PRINTABLE DOCUMENTS — fee challan and payment receipt (A4)
═══════════════════════════════════════════════════════════════ */
.print-page { max-width: 820px; margin: 0 auto; padding: 16px 0 40px; }
.print-toolbar { display: flex; justify-content: flex-end; gap: 8px; margin-bottom: 14px; }

.challan-copy, .receipt-sheet {
  background: #fff; color: #111;
  border: 1.5px solid #1f2937; border-radius: 6px;
  padding: 18px 22px; position: relative;
  font-size: 12.5px;
}
.challan-head, .receipt-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  border-bottom: 2px solid #1f2937; padding-bottom: 8px; margin-bottom: 10px;
}
.challan-school { font-size: 17px; font-weight: 800; }
.challan-sub { color: #4b5563; font-size: 11.5px; }
.challan-title { font-size: 15px; font-weight: 800; color: #3730a3; letter-spacing: 1px; }
.challan-meta, .challan-student {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 6px 14px; margin-bottom: 10px;
}
.challan-meta > div, .challan-student > div {
  display: flex; flex-direction: column;
  border-bottom: 1px dotted #9ca3af; padding-bottom: 3px;
}
.challan-meta span, .challan-student span {
  font-size: 10.5px; color: #6b7280; text-transform: uppercase; letter-spacing: .4px;
}
.challan-table { width: 100%; border-collapse: collapse; margin: 6px 0 10px; }
.challan-table th, .challan-table td { border: 1px solid #d1d5db; padding: 5px 8px; }
.challan-table th { background: #f3f4f6; text-align: left; font-size: 11px; }
.challan-table tr.subtotal td { font-weight: 700; background: #f9fafb; }
.challan-payable { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.challan-pay-box {
  border: 1.5px solid #111; border-radius: 6px; padding: 8px 10px;
  display: flex; flex-direction: column; gap: 2px;
}
.challan-pay-box span { font-size: 10.5px; color: #374151; }
.challan-pay-box strong { font-size: 15px; }
.challan-pay-box.late { border-style: dashed; border-color: #b91c1c; color: #7f1d1d; }
.challan-words { font-style: italic; margin-top: 6px; font-size: 11.5px; }
.challan-paid-stamp {
  position: absolute; right: 26px; top: 110px;
  border: 3px solid #15803d; color: #15803d; font-weight: 900; font-size: 26px;
  padding: 2px 14px; transform: rotate(-12deg); letter-spacing: 3px; opacity: .85;
}
.challan-foot, .receipt-foot {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-top: 12px; font-size: 10.5px; color: #374151; gap: 16px;
}
.challan-sign { border-top: 1px solid #111; padding-top: 3px; min-width: 150px; text-align: center; }
.challan-cut { text-align: center; color: #9ca3af; font-size: 11px; margin: 10px 0; }

.receipt-sheet { max-width: 620px; margin: 0 auto; }
.receipt-amount {
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  background: #f8fafc; border: 1.5px solid #111; border-radius: 6px;
  padding: 10px 14px; margin: 10px 0;
}
.receipt-amount span { font-size: 10.5px; color: #6b7280; text-transform: uppercase; letter-spacing: .4px; }
.receipt-amount-value { font-size: 22px; font-weight: 800; }
.receipt-words { font-style: italic; font-size: 11.5px; max-width: 280px; text-align: right; }

@media print {
  @page { size: A4; margin: 10mm; }
  body { background: #fff !important; }
  .print-page { max-width: none; padding: 0; }
  .print-toolbar, .no-print { display: none !important; }
  .challan-copy, .receipt-sheet { box-shadow: none !important; border-color: #000; }
  .challan-copy { page-break-inside: avoid; }
  .challan-cut { page-break-after: avoid; }
}
