/**
* Template Name: NiceAdmin - Modernized for Fuzzy DSS Intervensi Stunting
* Updated: 2026
*/

/*--------------------------------------------------------------
# General & CSS Variables
--------------------------------------------------------------*/
:root {
  scroll-behavior: smooth;
  --primary-color: #4154f1;
  --primary-hover: #2a3cd6;
  --primary-gradient: linear-gradient(135deg, #4154f1 0%, #2a3cd6 100%);
  --navy-dark: #012970;
  --text-main: #334155;
  --text-muted: #64748b;
  --bg-page: #f8fafc;
  --card-bg: #ffffff;
  --card-border: #edf2f7;
  --card-radius: 16px;
  --shadow-sm: 0 2px 8px rgba(1, 41, 112, 0.04);
  --shadow-md: 0 5px 20px rgba(1, 41, 112, 0.06);
  --shadow-lg: 0 15px 35px rgba(1, 41, 112, 0.12);
  --font-heading: 'Nunito', sans-serif;
  --font-body: 'Open Sans', 'Poppins', sans-serif;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: all 0.2s ease;
}

a:hover {
  color: var(--primary-hover);
  text-decoration: none;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  color: var(--navy-dark);
  font-weight: 700;
}

/*--------------------------------------------------------------
# Main Layout
--------------------------------------------------------------*/
#main {
  margin-top: 60px;
  padding: 24px 30px;
  transition: all 0.3s;
  min-height: calc(100vh - 120px);
}

@media (max-width: 1199px) {
  #main {
    padding: 20px 15px;
  }
}

/*--------------------------------------------------------------
# Page Title & Breadcrumbs
--------------------------------------------------------------*/
.pagetitle {
  margin-bottom: 20px;
}

.pagetitle h1 {
  font-size: 24px;
  margin-bottom: 4px;
  font-weight: 800;
  color: var(--navy-dark);
  letter-spacing: -0.5px;
}

.breadcrumb {
  font-size: 13px;
  font-family: var(--font-body);
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 0;
}

.breadcrumb a {
  color: var(--text-muted);
  transition: 0.2s;
}

.breadcrumb a:hover {
  color: var(--primary-color);
}

.breadcrumb .breadcrumb-item::before {
  color: #cbd5e1;
}

.breadcrumb .active {
  color: var(--primary-color);
  font-weight: 600;
}

/*--------------------------------------------------------------
# Back to top button
--------------------------------------------------------------*/
.back-to-top {
  position: fixed;
  visibility: hidden;
  opacity: 0;
  right: 20px;
  bottom: 20px;
  z-index: 99999;
  background: var(--primary-gradient);
  width: 42px;
  height: 42px;
  border-radius: 12px;
  transition: all 0.3s ease;
  box-shadow: 0 6px 16px rgba(65, 84, 241, 0.3);
}

.back-to-top i {
  font-size: 24px;
  color: #fff;
  line-height: 0;
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(65, 84, 241, 0.4);
  color: #fff;
}

.back-to-top.active {
  visibility: visible;
  opacity: 1;
}

/*--------------------------------------------------------------
# Header
--------------------------------------------------------------*/
.header {
  transition: all 0.3s;
  z-index: 997;
  height: 65px;
  box-shadow: 0px 2px 15px rgba(1, 41, 112, 0.06);
  background-color: #ffffff;
  padding-left: 20px;
  border-bottom: 1px solid #edf2f7;
}

.logo {
  line-height: 1;
}

@media (min-width: 1200px) {
  .logo {
    width: 280px;
  }
}

.logo img {
  max-height: 28px;
  margin-right: 8px;
}

.logo span {
  font-size: 22px;
  font-weight: 800;
  color: var(--navy-dark);
  font-family: var(--font-heading);
  letter-spacing: -0.5px;
}

.header .toggle-sidebar-btn {
  font-size: 28px;
  padding-left: 10px;
  cursor: pointer;
  color: var(--navy-dark);
  transition: color 0.2s ease;
}

.header .toggle-sidebar-btn:hover {
  color: var(--primary-color);
}

.header .search-bar {
  min-width: 320px;
  padding: 0 20px;
}

@media (max-width: 1199px) {
  .header .search-bar {
    position: fixed;
    top: 50px;
    left: 0;
    right: 0;
    padding: 15px 20px;
    box-shadow: 0px 10px 20px rgba(1, 41, 112, 0.08);
    background: white;
    z-index: 9999;
    transition: 0.3s;
    visibility: hidden;
    opacity: 0;
  }

  .header .search-bar-show {
    top: 65px;
    visibility: visible;
    opacity: 1;
  }
}

.header .search-form {
  width: 100%;
}

.header .search-form input {
  border: 1.5px solid #e2e8f0;
  font-size: 13.5px;
  color: var(--navy-dark);
  padding: 8px 38px 8px 14px;
  border-radius: 50px;
  transition: 0.25s;
  width: 100%;
  background: #f8fafc;
}

.header .search-form input:focus {
  outline: none;
  box-shadow: 0 0 0 3px rgba(65, 84, 241, 0.12);
  border-color: var(--primary-color);
  background: #fff;
}

.header .search-form button {
  border: 0;
  padding: 0;
  margin-left: -32px;
  background: none;
}

.header .search-form button i {
  color: #94a3b8;
  font-size: 14px;
}

/*--------------------------------------------------------------
# Header Nav & Profile Dropdown
--------------------------------------------------------------*/
.header-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.header-nav .nav-icon {
  font-size: 20px;
  color: var(--navy-dark);
  margin-right: 20px;
  position: relative;
  transition: color 0.2s ease;
}

.header-nav .nav-icon:hover {
  color: var(--primary-color);
}

.header-nav .nav-profile {
  color: var(--navy-dark);
}

.header-nav .nav-profile img {
  max-height: 36px;
  border-radius: 50%;
  border: 2px solid #e2e8f0;
}

.header-nav .nav-profile span {
  font-size: 14px;
  font-weight: 700;
  color: var(--navy-dark);
}

.dropdown-menu {
  border-radius: 16px;
  padding: 12px;
  border: 1px solid #edf2f7;
  box-shadow: 0 10px 30px rgba(1, 41, 112, 0.12);
  animation-name: dropdown-animate;
  animation-duration: 0.2s;
  animation-fill-mode: both;
}

.dropdown-menu .dropdown-header {
  text-align: center;
  font-size: 14px;
  padding: 10px 15px;
}

.dropdown-menu .dropdown-item {
  font-size: 13.5px;
  padding: 9px 14px;
  border-radius: 8px;
  font-weight: 500;
  transition: 0.2s;
  color: var(--text-main);
}

.dropdown-menu .dropdown-item:hover {
  background-color: #f6f9ff;
  color: var(--primary-color);
}

.dropdown-menu .dropdown-item i {
  margin-right: 8px;
  font-size: 16px;
  line-height: 0;
}

@keyframes dropdown-animate {
  0% {
    opacity: 0;
    transform: translateY(6px);
  }

  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

/*--------------------------------------------------------------
# Sidebar
--------------------------------------------------------------*/
.sidebar {
  position: fixed;
  top: 65px;
  left: 0;
  bottom: 0;
  width: 280px;
  z-index: 996;
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  padding: 20px 16px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #cbd5e1 transparent;
  box-shadow: 0px 0px 20px rgba(1, 41, 112, 0.04);
  background-color: #ffffff;
  border-right: 1px solid #edf2f7;
}

@media (max-width: 1199px) {
  .sidebar {
    left: -280px;
  }
}

.sidebar::-webkit-scrollbar {
  width: 5px;
}

.sidebar::-webkit-scrollbar-thumb {
  background-color: #cbd5e1;
  border-radius: 10px;
}

@media (min-width: 1200px) {

  #main,
  #footer {
    margin-left: 280px;
  }
}

@media (max-width: 1199px) {
  .toggle-sidebar .sidebar {
    left: 0;
  }
}

@media (min-width: 1200px) {

  .toggle-sidebar #main,
  .toggle-sidebar #footer {
    margin-left: 0;
  }

  .toggle-sidebar .sidebar {
    left: -280px;
  }
}

.sidebar-nav {
  padding: 0;
  margin: 0;
  list-style: none;
}

.sidebar-nav .nav-item {
  margin-bottom: 4px;
}

.sidebar-nav .nav-heading {
  font-size: 11px;
  text-transform: uppercase;
  color: #94a3b8;
  font-weight: 700;
  letter-spacing: 0.8px;
  margin: 16px 0 8px 12px;
}

.sidebar-nav .nav-link {
  display: flex;
  align-items: center;
  font-size: 14.5px;
  font-weight: 600;
  color: var(--primary-color);
  background: #eef2ff;
  padding: 10px 14px;
  border-radius: 10px;
  transition: all 0.2s ease;
}

.sidebar-nav .nav-link i {
  font-size: 17px;
  margin-right: 10px;
  color: var(--primary-color);
  transition: all 0.2s ease;
}

.sidebar-nav .nav-link.collapsed {
  color: #475569;
  background: transparent;
  font-weight: 500;
}

.sidebar-nav .nav-link.collapsed i {
  color: #94a3b8;
}

.sidebar-nav .nav-link.collapsed:hover {
  color: var(--primary-color);
  background: #f8faff;
}

.sidebar-nav .nav-link.collapsed:hover i {
  color: var(--primary-color);
}

.sidebar-nav .nav-content {
  padding: 4px 0 4px 0;
  margin: 0;
  list-style: none;
}

.sidebar-nav .nav-content a {
  display: flex;
  align-items: center;
  font-size: 13.5px;
  font-weight: 500;
  color: #475569;
  padding: 8px 0 8px 38px;
  transition: 0.2s;
  border-radius: 8px;
}

.sidebar-nav .nav-content a:hover,
.sidebar-nav .nav-content a.active {
  color: var(--primary-color);
  font-weight: 600;
}

/*--------------------------------------------------------------
# Cards
--------------------------------------------------------------*/
.card {
  margin-bottom: 24px;
  border: 1px solid var(--card-border);
  border-radius: var(--card-radius);
  box-shadow: var(--shadow-sm);
  background-color: var(--card-bg);
  transition: all 0.25s ease;
}

.card-header {
  border-bottom: 1px solid #f1f5f9;
  background-color: transparent;
  color: var(--navy-dark);
  font-weight: 700;
  padding: 16px 20px;
}

.card-footer {
  border-top: 1px solid #f1f5f9;
  background-color: transparent;
  padding: 14px 20px;
}

.card-title {
  padding: 16px 0 12px 0;
  font-size: 18px;
  font-weight: 700;
  color: var(--navy-dark);
  font-family: var(--font-heading);
  letter-spacing: -0.3px;
}

.card-title span {
  color: #94a3b8;
  font-size: 13px;
  font-weight: 400;
}

.card-body {
  padding: 0 20px 20px 20px;
}

/*--------------------------------------------------------------
# Buttons
--------------------------------------------------------------*/
.btn {
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  padding: 8px 18px;
  transition: all 0.25s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--primary-gradient);
  border: none;
  color: #fff;
  box-shadow: 0 4px 14px rgba(65, 84, 241, 0.28);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #3244db 0%, #1e2eb8 100%);
  color: #fff;
  box-shadow: 0 6px 20px rgba(65, 84, 241, 0.38);
}

.btn-outline-primary {
  border: 1.5px solid var(--primary-color);
  color: var(--primary-color);
  background: transparent;
}

.btn-outline-primary:hover {
  background: var(--primary-color);
  color: #fff;
  box-shadow: 0 4px 12px rgba(65, 84, 241, 0.25);
}

.btn-success {
  background: linear-gradient(135deg, #10b981 0%, #059669 100%);
  border: none;
  color: #fff;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.25);
}

.btn-success:hover {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  color: #fff;
}

.btn-warning {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  border: none;
  color: #fff;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.25);
}

.btn-danger {
  background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
  border: none;
  color: #fff;
  box-shadow: 0 4px 14px rgba(239, 68, 68, 0.25);
}

.btn-rounded-pill,
.rounded-pill {
  border-radius: 50px !important;
}

/*--------------------------------------------------------------
# Forms & Inputs
--------------------------------------------------------------*/
.form-label {
  font-size: 13.5px;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
}

.form-control,
.form-select {
  border-radius: 10px;
  border: 1.5px solid #e2e8f0;
  padding: 9px 14px;
  font-size: 14px;
  color: #1e293b;
  transition: all 0.2s ease;
  background-color: #fff;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3.5px rgba(65, 84, 241, 0.12);
  outline: none;
}

.input-group-text {
  border-radius: 10px;
  border: 1.5px solid #e2e8f0;
  background-color: #f8fafc;
  color: #64748b;
}

/*--------------------------------------------------------------
# Tables & DataTables
--------------------------------------------------------------*/
.table {
  vertical-align: middle;
}

.table thead th,
.datatable thead th {
  background-color: #f8faff !important;
  color: #475569 !important;
  font-weight: 700 !important;
  font-size: 12.5px !important;
  text-transform: uppercase !important;
  letter-spacing: 0.5px !important;
  border-bottom: 1.5px solid #e2e8f0 !important;
  padding: 12px 16px !important;
}

.table tbody td {
  padding: 12px 16px;
  border-bottom: 1px solid #f1f5f9;
  font-size: 14px;
}

.table-hover tbody tr:hover {
  background-color: #f8faff !important;
}

/* DataTables Controls */
.dataTable-input,
.dataTable-selector {
  border-radius: 8px !important;
  border: 1.5px solid #e2e8f0 !important;
  padding: 6px 12px !important;
  font-size: 13.5px !important;
}

.dataTable-input:focus,
.dataTable-selector:focus {
  border-color: var(--primary-color) !important;
  box-shadow: 0 0 0 3px rgba(65, 84, 241, 0.12) !important;
}

.dataTable-pagination li a {
  border-radius: 8px !important;
  margin: 0 2px !important;
  border: 1px solid #e2e8f0 !important;
  font-size: 13px !important;
  color: #475569 !important;
}

.dataTable-pagination li.active a {
  background: var(--primary-gradient) !important;
  border-color: transparent !important;
  color: #fff !important;
  box-shadow: 0 2px 8px rgba(65, 84, 241, 0.3) !important;
}

/*--------------------------------------------------------------
# Badges & Alerts
--------------------------------------------------------------*/
.badge {
  padding: 6px 12px;
  font-weight: 600;
  font-size: 12px;
  border-radius: 50px;
  letter-spacing: 0.2px;
}

.bg-primary-subtle {
  background-color: #eef2ff !important;
  color: #4154f1 !important;
}

.bg-success-subtle {
  background-color: #ecfdf5 !important;
  color: #059669 !important;
}

.bg-warning-subtle {
  background-color: #fffbeb !important;
  color: #d97706 !important;
}

.bg-danger-subtle {
  background-color: #fef2f2 !important;
  color: #dc2626 !important;
}

.bg-info-subtle {
  background-color: #f0f9ff !important;
  color: #0284c7 !important;
}

.alert {
  border-radius: 12px;
  border: 1px solid transparent;
  padding: 14px 18px;
  font-size: 14px;
}

/*--------------------------------------------------------------
# Dashboard Components & Helper Classes
--------------------------------------------------------------*/
/* Hero Banner */
.dashboard-hero-banner {
  background: linear-gradient(135deg, #012970 0%, #1a365d 40%, #1e40af 100%);
  border-radius: 20px;
  padding: 2rem 2.25rem;
  color: #ffffff;
  position: relative;
  overflow: hidden;
  box-shadow: 0 15px 35px -5px rgba(1, 41, 112, 0.22);
}

.dashboard-hero-banner::after {
  content: '';
  position: absolute;
  width: 320px;
  height: 320px;
  background: radial-gradient(circle, rgba(65, 84, 241, 0.35) 0%, rgba(255, 255, 255, 0) 70%);
  top: -60px;
  right: -40px;
  border-radius: 50%;
  pointer-events: none;
}

.hero-pill-badge {
  background: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #ffffff;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 14px;
  border-radius: 50px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  display: inline-flex;
  align-items: center;
}

.hero-welcome-title {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.75rem;
  color: #ffffff;
  margin-bottom: 0.5rem;
  letter-spacing: -0.5px;
}

.hero-welcome-sub {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
  max-width: 650px;
  margin-bottom: 0;
  line-height: 1.6;
}

.btn-hero-action {
  background: #ffffff;
  color: var(--navy-dark);
  font-weight: 700;
  font-size: 0.9rem;
  padding: 10px 22px;
  border-radius: 50px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  border: none;
}

.btn-hero-action:hover {
  background: #eef2ff;
  color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.2);
}

/* Stat Cards */
.stat-card {
  background: #ffffff;
  border-radius: 18px;
  border: 1px solid #edf2f7;
  box-shadow: 0 4px 16px rgba(1, 41, 112, 0.04);
  transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
  height: 100%;
  position: relative;
  overflow: hidden;
}

.stat-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(1, 41, 112, 0.09);
  border-color: #dbeafe;
}

.stat-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
}

.stat-card-primary::before {
  background: linear-gradient(90deg, #4154f1, #60a5fa);
}

.stat-card-info::before {
  background: linear-gradient(90deg, #0ea5e9, #38bdf8);
}

.stat-card-warning::before {
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
}

.stat-card-success::before {
  background: linear-gradient(90deg, #10b981, #34d399);
}

.stat-card-body {
  padding: 1.4rem;
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.stat-icon-wrapper {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
  transition: transform 0.3s ease;
}

.stat-card:hover .stat-icon-wrapper {
  transform: scale(1.08);
}

.stat-label {
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #64748b;
  display: block;
  margin-bottom: 2px;
}

.stat-value {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.85rem;
  color: var(--navy-dark);
  margin: 0;
  line-height: 1.2;
}

.stat-desc {
  font-size: 0.78rem;
  color: #94a3b8;
  margin-top: 4px;
  display: flex;
  align-items: center;
}

/* Shortcut Cards */
.shortcut-card {
  background: #ffffff;
  border-radius: 16px;
  border: 1px solid #edf2f7;
  padding: 1.15rem 1.25rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: inherit;
  transition: all 0.25s ease;
  height: 100%;
  box-shadow: 0 3px 10px rgba(1, 41, 112, 0.03);
}

.shortcut-card:hover {
  border-color: var(--primary-color);
  background: #f8faff;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(65, 84, 241, 0.1);
}

.shortcut-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: #eef2ff;
  color: var(--primary-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
  transition: all 0.25s ease;
}

.shortcut-card:hover .shortcut-icon {
  background: var(--primary-color);
  color: #ffffff;
}

.shortcut-title {
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--navy-dark);
  margin-bottom: 2px;
}

.shortcut-subtitle {
  font-size: 0.76rem;
  color: #64748b;
  margin: 0;
}

/* Custom Table Card */
.custom-card {
  background: #ffffff;
  border-radius: 18px;
  border: 1px solid #edf2f7;
  box-shadow: 0 4px 20px rgba(1, 41, 112, 0.05);
  overflow: hidden;
}

.custom-card-header {
  padding: 1.25rem 1.5rem;
  background: #ffffff;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.custom-card-title {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.15rem;
  color: var(--navy-dark);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.custom-table thead th {
  background: #f8faff;
  color: #475569;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 14px 16px;
  border-bottom: 1px solid #e2e8f0;
}

.custom-table tbody td {
  padding: 14px 16px;
  vertical-align: middle;
  font-size: 0.88rem;
  color: #334155;
  border-bottom: 1px solid #f1f5f9;
}

.custom-table tbody tr:hover {
  background-color: #f8faff;
}

/*--------------------------------------------------------------
# Modals
--------------------------------------------------------------*/
.modal-content {
  border-radius: 20px;
  border: none;
  box-shadow: 0 20px 50px rgba(1, 41, 112, 0.18);
  overflow: hidden;
}

.modal-header {
  border-bottom: 1px solid #f1f5f9;
  padding: 18px 24px;
}

.modal-title {
  font-family: var(--font-heading);
  font-weight: 800;
  color: var(--navy-dark);
}

.modal-body {
  padding: 24px;
}

.modal-footer {
  border-top: 1px solid #f1f5f9;
  padding: 16px 24px;
}

/*--------------------------------------------------------------
# Footer
--------------------------------------------------------------*/
.footer {
  padding: 20px 0;
  font-size: 13.5px;
  transition: all 0.3s;
  border-top: 1px solid #edf2f7;
  background-color: #ffffff;
  color: var(--text-muted);
}

.footer .copyright {
  text-align: center;
  color: var(--navy-dark);
  font-weight: 600;
}