:root {
  --brand: #0d6efd;
  --brand-dark: #084298;
  --bg-soft: #f4f7fb;
}

body {
  background: var(--bg-soft);
  font-family: -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}

.app-navbar {
  background: linear-gradient(90deg, var(--brand-dark), var(--brand));
  position: sticky;
  top: 0;
  z-index: 1030;
}

.app-wrap {
  display: flex;
  min-height: calc(100vh - 56px);
}

.app-sidebar {
  width: 240px;
  background: #fff;
  border-right: 1px solid #e5e9f0;
  padding: 14px 0;
  flex-shrink: 0;
}

.app-sidebar .nav-link {
  color: #33415c;
  padding: 10px 20px;
  font-size: 0.92rem;
  border-left: 3px solid transparent;
}

.app-sidebar .nav-link i {
  width: 20px;
  display: inline-block;
}

.app-sidebar .nav-link:hover {
  background: #eef3ff;
  color: var(--brand-dark);
}

.app-sidebar .nav-link.active {
  background: #eaf1ff;
  color: var(--brand-dark);
  font-weight: 600;
  border-left-color: var(--brand);
}

.app-content {
  flex: 1;
  padding: 22px;
  max-width: 100%;
  overflow-x: auto;
}

.card {
  border: none;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(20, 30, 60, 0.08);
}

.stat-card {
  border-radius: 14px;
  color: #fff;
  padding: 18px 20px;
}
.stat-card .stat-value { font-size: 1.7rem; font-weight: 700; }
.stat-card .stat-label { font-size: 0.82rem; opacity: 0.9; }
.stat-card i { font-size: 1.8rem; opacity: 0.85; }

.bg-grad-blue   { background: linear-gradient(135deg,#2563eb,#1d4ed8); }
.bg-grad-green  { background: linear-gradient(135deg,#16a34a,#15803d); }
.bg-grad-orange { background: linear-gradient(135deg,#f59e0b,#d97706); }
.bg-grad-red    { background: linear-gradient(135deg,#dc2626,#b91c1c); }
.bg-grad-purple { background: linear-gradient(135deg,#7c3aed,#6d28d9); }

.table thead th {
  background: #f1f5fb;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: #52627a;
  white-space: nowrap;
}
.table td { vertical-align: middle; }
.table-sm td, .table-sm th { padding: 0.45rem 0.6rem; }

.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg,#0b2545,#13315c 60%,#0d6efd);
}
.login-card {
  width: 100%;
  max-width: 400px;
  border-radius: 16px;
}

@media (max-width: 991px) {
  .app-sidebar {
    position: fixed;
    left: -260px;
    top: 56px;
    bottom: 0;
    z-index: 1020;
    transition: left .2s ease;
    box-shadow: 2px 0 10px rgba(0,0,0,.1);
  }
  .app-sidebar.show { left: 0; }
}

.required::after { content: " *"; color: #dc3545; }
.form-label { font-weight: 500; font-size: 0.88rem; }
.section-title {
  font-weight: 700;
  color: var(--brand-dark);
  border-bottom: 2px solid #eaf1ff;
  padding-bottom: 6px;
  margin-bottom: 14px;
}
