/* =====================================================================
   SKNAU — Modern CRM/ERP Theme
   Overrides for the AppUI template (app.css / bootstrap.css) used across
   the authenticated portal (Dashboard, Login, College/Student/Exam
   modules). Pure CSS layer — no markup structure, IDs or JS hooks from
   app.css are changed, so existing data-toggle="layout" sidebar/drawer
   behaviour keeps working.
   ===================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --crm-primary: #4f46e5;
  --crm-primary-dark: #3730a3;
  --crm-primary-light: #eef2ff;
  --crm-accent: #06b6d4;
  --crm-success: #16a34a;
  --crm-success-bg: #ecfdf5;
  --crm-warning: #d97706;
  --crm-warning-bg: #fffbeb;
  --crm-danger: #dc2626;
  --crm-danger-bg: #fef2f2;

  --crm-sidebar-bg: #111827;
  --crm-sidebar-bg-active: #1f2937;
  --crm-sidebar-text: #9ca3af;
  --crm-sidebar-text-active: #ffffff;

  --crm-bg: #f4f5fa;
  --crm-surface: #ffffff;
  --crm-border: #e5e7eb;
  --crm-text: #111827;
  --crm-text-muted: #6b7280;

  --crm-radius: 12px;
  --crm-radius-sm: 8px;
  --crm-shadow: 0 1px 2px rgba(16, 24, 40, 0.06), 0 1px 3px rgba(16, 24, 40, 0.08);
  --crm-shadow-md: 0 4px 10px rgba(16, 24, 40, 0.08);
}

body.app-ui {
  background-color: var(--crm-bg);
  color: var(--crm-text);
  font-family: 'Inter', 'Roboto', -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
}

/* ---------------------------------------------------------------------
   Sidebar / Drawer
   --------------------------------------------------------------------- */
.app-layout-drawer {
  background-color: var(--crm-sidebar-bg) !important;
  border-right: none !important;
  color: var(--crm-sidebar-text);
  box-shadow: 2px 0 12px rgba(0, 0, 0, 0.12);
}

.drawer-header {
  height: 68px;
  line-height: 68px;
  padding: 0 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
}

.drawer-header a img {
  height: 40px;
  filter: brightness(0) invert(1);
  opacity: 0.95;
}

.drawer-main {
  margin-top: 12px;
}

.nav-drawer-header {
  color: #6b7280;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 18px 24px 8px;
  opacity: 0.7;
}

.nav-drawer > li > a,
.nav-drawer li a {
  color: var(--crm-sidebar-text);
  font-weight: 500;
  font-size: 13.5px;
  margin: 2px 12px;
  border-radius: var(--crm-radius-sm);
  border-left: none !important;
  padding-top: 11px;
  padding-bottom: 11px;
  padding-left: 44px !important;
  width: calc(100% - 24px);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-drawer > li > a > i {
  left: 20px;
  color: #9ca3af;
}

.nav-drawer > li > a:hover,
.nav-drawer > li > a:focus {
  background-color: rgba(255, 255, 255, 0.06);
  color: #ffffff;
}

.nav-drawer > .active > a {
  background-color: var(--crm-primary) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px rgba(79, 70, 229, 0.45);
}

.nav-drawer > .active > a > i {
  color: #ffffff;
}

.nav-subnav > li > a {
  color: #8a93a3;
}

.drawer-footer {
  color: #6b7280;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.drawer-footer a {
  color: #9ca3af;
}

/* ---------------------------------------------------------------------
   Topbar / Header
   --------------------------------------------------------------------- */
.app-layout-header {
  background-color: var(--crm-surface) !important;
  box-shadow: 0 1px 0 var(--crm-border) !important;
}

.app-layout-header .navbar {
  background-color: transparent;
}

.navbar-page-title {
  font-weight: 700;
  font-size: 16px;
  color: var(--crm-text);
}

.navbar-toolbar > li > a i {
  color: var(--crm-text-muted);
}

.navbar-toolbar > li > a i + .badge {
  background-color: var(--crm-danger);
}

.dropdown-profile a span {
  font-weight: 600;
  color: var(--crm-text);
}

/* ---------------------------------------------------------------------
   Content area
   --------------------------------------------------------------------- */
.app-layout-content {
  background-color: var(--crm-bg);
}

.app-layout-content .container-fluid {
  padding-top: 22px;
  padding-bottom: 32px;
}

/* ---------------------------------------------------------------------
   Cards
   --------------------------------------------------------------------- */
.card {
  border: none !important;
  border-radius: var(--crm-radius) !important;
  box-shadow: var(--crm-shadow) !important;
  margin-bottom: 24px;
}

.card-header {
  background-color: transparent !important;
  border-bottom: 1px solid var(--crm-border) !important;
  font-weight: 700;
  font-size: 15px;
  padding: 16px 22px !important;
  border-radius: var(--crm-radius) var(--crm-radius) 0 0 !important;
}

.card-block,
.card-body {
  padding: 22px !important;
}

/* ---------------------------------------------------------------------
   KPI / Stat cards (used on Dashboard-style summary rows)
   --------------------------------------------------------------------- */
.stat-row {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 22px;
}

.stat-card {
  flex: 1 1 220px;
  background: var(--crm-surface);
  border-radius: var(--crm-radius);
  box-shadow: var(--crm-shadow);
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.stat-card .stat-icon {
  width: 46px;
  height: 46px;
  min-width: 46px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  background: var(--crm-primary-light);
  color: var(--crm-primary);
}

.stat-card.stat-success .stat-icon { background: var(--crm-success-bg); color: var(--crm-success); }
.stat-card.stat-warning .stat-icon { background: var(--crm-warning-bg); color: var(--crm-warning); }
.stat-card.stat-danger .stat-icon { background: var(--crm-danger-bg); color: var(--crm-danger); }

.stat-card .stat-label {
  font-size: 12px;
  color: var(--crm-text-muted);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  margin: 0 0 2px;
}

.stat-card .stat-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--crm-text);
  margin: 0;
  line-height: 1.3;
}

/* ---------------------------------------------------------------------
   Buttons
   --------------------------------------------------------------------- */
.btn {
  border-radius: var(--crm-radius-sm);
  font-weight: 600;
  font-size: 13.5px;
  padding: 9px 18px;
  border: none;
  transition: transform 0.05s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}

.btn:active { transform: translateY(1px); }

.btn-primary {
  background-color: var(--crm-primary);
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.35);
}

.btn-primary:hover, .btn-primary:focus {
  background-color: var(--crm-primary-dark);
}

.btn-danger { background-color: var(--crm-danger); }
.btn-warning { background-color: var(--crm-warning); color: #fff; }
.btn-success { background-color: var(--crm-success); }

/* ---------------------------------------------------------------------
   Tables
   --------------------------------------------------------------------- */
.table {
  background-color: var(--crm-surface);
  border-radius: var(--crm-radius-sm);
  overflow: hidden;
}

.table thead th,
.table > thead > tr > th {
  background-color: #f9fafb;
  color: var(--crm-text-muted);
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--crm-border) !important;
  border-top: none !important;
  padding: 12px 16px;
}

.table td,
.table > tbody > tr > td {
  padding: 13px 16px;
  border-top: 1px solid #f1f2f6 !important;
  font-size: 13.5px;
  vertical-align: middle;
}

.table-striped > tbody > tr:nth-of-type(odd) {
  background-color: #fbfbfd;
}

.table-bordered {
  border: 1px solid var(--crm-border) !important;
}

.table-bordered td, .table-bordered th {
  border: 1px solid #eef0f3 !important;
}

.table-hover > tbody > tr:hover {
  background-color: var(--crm-primary-light);
}

/* ---------------------------------------------------------------------
   Forms
   --------------------------------------------------------------------- */
.form-control {
  border: 1px solid var(--crm-border);
  border-radius: var(--crm-radius-sm);
  padding: 9px 14px;
  font-size: 13.5px;
  box-shadow: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-control:focus {
  border-color: var(--crm-primary);
  box-shadow: 0 0 0 3px var(--crm-primary-light);
}

label {
  font-weight: 600;
  font-size: 13px;
  color: var(--crm-text-muted);
}

/* ---------------------------------------------------------------------
   Badges / pills / alerts
   --------------------------------------------------------------------- */
.badge {
  border-radius: 999px;
  font-weight: 600;
  padding: 4px 10px;
}

.alert {
  border: none;
  border-radius: var(--crm-radius-sm);
}

/* ---------------------------------------------------------------------
   Login screen (DefaultLogin.aspx / SuperLogin.aspx)
   --------------------------------------------------------------------- */
.crm-auth-shell {
  min-height: 100vh;
  display: flex;
  align-items: stretch;
  background: var(--crm-bg);
}

.crm-auth-brand {
  flex: 1 1 45%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 60px 64px;
  color: #fff;
  background: linear-gradient(135deg, var(--crm-primary-dark) 0%, var(--crm-primary) 60%, var(--crm-accent) 130%);
  position: relative;
  overflow: hidden;
}

.crm-auth-brand::after {
  content: "";
  position: absolute;
  width: 480px;
  height: 480px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  right: -160px;
  bottom: -160px;
}

.crm-auth-brand img.crm-auth-logo {
  height: 52px;
  background: #fff;
  padding: 8px 12px;
  border-radius: 10px;
  margin-bottom: 34px;
}

.crm-auth-brand h1 {
  font-size: 28px;
  font-weight: 800;
  margin-bottom: 14px;
  line-height: 1.3;
}

.crm-auth-brand p {
  font-size: 14.5px;
  opacity: 0.9;
  max-width: 380px;
  line-height: 1.6;
}

.crm-auth-form-wrap {
  flex: 1 1 55%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
}

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

.crm-auth-card .card {
  margin-bottom: 0;
}

.crm-auth-card .card-header {
  text-align: center;
  border-bottom: none !important;
  padding-bottom: 4px !important;
  font-size: 22px;
}

.crm-auth-card .card-header small {
  display: block;
  font-weight: 500;
  font-size: 13px;
  color: var(--crm-text-muted);
  margin-top: 4px;
}

.crm-auth-card .btn-primary {
  width: 100%;
  padding: 11px 18px;
  margin-top: 6px;
}

@media (max-width: 900px) {
  .crm-auth-brand { display: none; }
  .crm-auth-form-wrap { flex: 1 1 100%; }
}

/* ---------------------------------------------------------------------
   Legacy top bar (College/University header on pre-login-style pages)
   --------------------------------------------------------------------- */
.crm-topbar {
  background: linear-gradient(90deg, var(--crm-primary-dark), var(--crm-primary));
  padding: 12px 24px;
  display: flex;
  align-items: center;
}

.crm-topbar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  font-weight: 700;
  font-size: 15px;
}

.crm-topbar-brand img {
  height: 34px;
  border-radius: 6px;
  background: #fff;
  padding: 2px;
}

.topnav {
  background-color: var(--crm-surface) !important;
  border-bottom: 1px solid var(--crm-border);
  border-radius: var(--crm-radius) var(--crm-radius) 0 0;
}

.topnav a {
  color: var(--crm-text) !important;
  font-weight: 600 !important;
  font-size: 13px !important;
}

.topnav a:hover {
  background-color: var(--crm-primary-light) !important;
  color: var(--crm-primary) !important;
}

.crm-topbar-user {
  text-align: right;
  padding: 10px 24px !important;
  font-size: 13px;
  color: var(--crm-text-muted);
  border-top: 1px solid var(--crm-border);
}

.crm-topbar-user a {
  color: var(--crm-primary);
  font-weight: 600;
  margin-left: 14px;
  text-decoration: none;
}

.crm-topbar-user a.crm-topbar-logout {
  color: var(--crm-danger);
}

/* ---------------------------------------------------------------------
   Dashboard profile card + detail table + notices
   --------------------------------------------------------------------- */
.crm-profile-card {
  box-shadow: none !important;
  border: 1px solid var(--crm-border) !important;
}

.crm-profile-card .card-header small {
  display: block;
  font-weight: 500;
  color: var(--crm-text-muted);
  font-size: 12.5px;
  margin-top: 2px;
}

table.crm-detail-table {
  border-collapse: collapse;
}

table.crm-detail-table td {
  padding: 10px 14px !important;
  border-top: 1px solid #f1f2f6 !important;
  font-size: 13.5px;
}

table.crm-detail-table td:nth-child(odd) {
  width: 22%;
  color: var(--crm-text-muted);
  font-weight: 600;
  background: #fafafd;
}

table.crm-detail-table td:nth-child(even) {
  color: var(--crm-text);
}

.crm-notice {
  border-left: 4px solid var(--crm-warning);
  font-size: 13.5px;
  line-height: 1.6;
}

/* =====================================================================
   Theme switcher (light / dark / system), top search, fullscreen toggle
   Shared markup/JS with the Admin module (assets/js/crm-toolbar.js) so
   the same behaviour works across the whole authenticated portal.
   ===================================================================== */
html[data-theme="dark"] body {
  background: #0b1115;
  color: #dfe3e8;
}
html[data-theme="dark"] .card,
html[data-theme="dark"] .crm-auth-card,
html[data-theme="dark"] .crm-profile-card {
  background: #151b23;
  border-color: #262f3a;
  color: #dfe3e8;
}
html[data-theme="dark"] .card-header {
  background: #151b23;
  border-color: #262f3a;
}
html[data-theme="dark"] .table {
  color: #c7cfd8;
}
html[data-theme="dark"] .form-control {
  background-color: #151b23;
  border-color: #2c3644;
  color: #dfe3e8;
}
html[data-theme="dark"] .crm-topbar {
  background: #0b1115;
  border-bottom-color: #262f3a;
}

.crm-toolbar { display: flex; align-items: center; gap: 6px; margin-left: auto; margin-right: 10px; }
.crm-toolbar-btn { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; border-radius: 9px; background: rgba(255,255,255,0.12); color: #fff; border: 0; cursor: pointer; font-size: 14px; transition: background .15s ease; }
.crm-toolbar-btn:hover { background: rgba(255,255,255,0.22); }
.crm-theme-menu { position: relative; }
.crm-theme-options { display: none; position: absolute; right: 0; top: 44px; background: #fff; border: 1px solid var(--crm-border); border-radius: 10px; box-shadow: var(--crm-shadow-md); min-width: 150px; padding: 6px; z-index: 500; }
.crm-theme-options.open { display: block; }
.crm-theme-options button { display: flex; align-items: center; gap: 8px; width: 100%; text-align: left; background: transparent; border: 0; padding: 8px 10px; border-radius: 7px; font-size: 13px; color: var(--crm-text); cursor: pointer; }
.crm-theme-options button:hover { background: var(--crm-primary-light); }
.crm-theme-options button.active { color: var(--crm-primary); font-weight: 600; }
html[data-theme="dark"] .crm-theme-options { background: #151b23; border-color: #262f3a; }
html[data-theme="dark"] .crm-theme-options button { color: #dfe3e8; }
html[data-theme="dark"] .crm-theme-options button:hover { background: #1c2531; }

.crm-top-search { display: flex; align-items: center; gap: 8px; background: rgba(255,255,255,0.12); border-radius: 9px; padding: 0 12px; height: 36px; width: 220px; margin-left: 16px; }
.crm-top-search i { color: rgba(255,255,255,0.7); font-size: 12px; }
.crm-top-search input { border: 0; background: transparent; outline: none; font-size: 13px; color: #fff; width: 100%; }
.crm-top-search input::placeholder { color: rgba(255,255,255,0.65); }
@media (max-width: 767.98px) {
  .crm-top-search { display: none; }
}

/* Utility classes (security-hardening pass: replacing inline style="" attributes
   so pages can run under a strict Content-Security-Policy with no 'unsafe-inline'). */
.u-text-indianred { color: indianred; }
.u-text-red { color: red; }
.u-fs-14 { font-size: 14px; }
.u-hidden { display: none; }
.u-td-pad { padding: 5px; }
.u-full-width { width: 100%; }
.u-mt-20 { margin-top: 20px; }

/*# sourceMappingURL=maps/app-custom.css.map */
