/* Insights Users table header styling to match theme sample */
.datatables-users.table thead.table-light th,
.datatables-users.table thead th {
  background-color: var(--bs-light, #f8f9fa);
  color: var(--bs-heading-color, #566a7f);
  border-bottom: 1px solid var(--bs-border-color, #e4e6e8);
  padding-top: 0.75rem;
  padding-bottom: 0.75rem;
  padding-left: 1rem;
  padding-right: 1rem;
  vertical-align: middle;
  font-weight: 600;
}

/* Remove DataTables default sort icons and cursor when ordering off */
.datatables-users thead th.sorting,
.datatables-users thead th.sorting_asc,
.datatables-users thead th.sorting_desc {
  background-image: none !important;
  cursor: default !important;
}

/* Also hide DataTables pseudo-element sort indicators */
.datatables-users thead th.sorting::before,
.datatables-users thead th.sorting::after,
.datatables-users thead th.sorting_asc::before,
.datatables-users thead th.sorting_asc::after,
.datatables-users thead th.sorting_desc::before,
.datatables-users thead th.sorting_desc::after {
  display: none !important;
  content: none !important;
}

/* Compact header spacing similar to theme */
.datatables-users.table thead th:first-child {
  padding-left: 1.25rem;
}
.datatables-users.table thead th:last-child {
  padding-right: 1.25rem;
}

/* Ensure header row spacing matches sample */
.card-datatable .table thead tr {
  height: auto;
}
body {
  font-family: 'Inter', sans-serif;
}

.badge-notifications {
  position: absolute;
  top: 6px;
  right: 6px;
  font-size: 0.65rem;
  padding: 0.15rem 0.35rem;
}

.login .card {
  max-width: 420px;
}

[data-bs-theme="dark"] .login .card {
  background-color: #161a2d;
}

[data-bs-theme="dark"] .login .card .text-muted {
  color: #c3c5d0 !important;
}

/* App brand styling (extracted from demo.css) */
.menu .app-brand {
  height: 110px;
}

.app-brand-logo svg {
  width: 38px;
  height: 20px;
}

.app-brand-text {
    font-size: 1.45rem;
    font-weight: 200 !important;
    letter-spacing: 0.15px;
    position: relative;
    top: 2px;
    opacity: 0.6 !important;
}

/* Authentication page brand styling */
.authentication-wrapper .app-brand-text {
    text-transform: capitalize;
    /* opacity: 1 !important; */
    font-weight: 200 !important;
    font-size: 2.0rem;
    position: relative;
    top: 2px;
    margin-left: 10px;
    opacity: 0.4 !important;
}

/* Layout navbar fixed padding */
.layout-navbar-fixed .layout-wrapper:not(.layout-without-menu) .layout-page {
  padding-top: 64px !important;
}

/* Navbar page z-index issue solution */
.content-wrapper .navbar {
  z-index: auto;
}

/* Sidebar brand logo */
.sidebar-brand {
  padding: 1.5rem 1rem;
  text-align: center;
}

.sidebar-brand img {
  width: 100%;
  max-width: 180px;
  height: auto;
}

/* Performance optimization for sidebar hover - Fix for lag issues */
.layout-menu-collapsed .layout-menu {
  will-change: width;
}

/* Reduce hover selector complexity to prevent style recalculation lag */
.layout-menu-collapsed .layout-menu:not(:hover) * {
  transition: none !important;
}

/* Use simpler hover detection with faster transition */
.layout-menu-collapsed .layout-menu:hover {
  transition: width 0.2s ease-out;
}

/* Optimize hover state changes to prevent DOM thrashing */
.layout-menu-collapsed .layout-menu:hover .menu-inner > .menu-item,
.layout-menu-collapsed .layout-menu:hover .menu-inner > .menu-header {
  transition: opacity 0.15s ease-out;
}

/* Use JavaScript-managed hover class for better performance */
.layout-menu-collapsed .layout-menu.menu-hovering {
  transform: translateZ(0); /* Hardware acceleration */
  will-change: width;
}

/* Prevent excessive repaints during hover transitions */
.layout-menu-collapsed .layout-menu.menu-hovering .menu-inner {
  backface-visibility: hidden;
  transform: translateZ(0);
}

/* Brand Color Theme - Match Landing Page */
:root {
  /* Primary colors based on landing page #005f7b */
  --bs-primary: #005f7b;
  --bs-primary-rgb: 0, 95, 123;
  
  /* Generate subtle variants for light theme */
  --bs-primary-text-emphasis: #003a49;
  --bs-primary-bg-subtle: #e6f2f5;
  --bs-primary-border-subtle: #b3d9e1;
  
  /* Accent color from landing page */
  --zen-accent: #80EEE1;
  --zen-accent-rgb: 128, 238, 225;
  
  /* Hover/active color from landing page */
  --zen-hover: #00A0AA;
  --zen-hover-rgb: 0, 160, 170;
}

/* Dark theme overrides */
[data-bs-theme="dark"] {
  --bs-primary-text-emphasis: #66b8d1;
  --bs-primary-bg-subtle: #0d2932;
  --bs-primary-border-subtle: #1a4a57;
}

/* Apply accent color to specific elements */
.btn-outline-primary:hover,
.btn-primary:hover {
  background-color: var(--zen-hover);
  border-color: var(--zen-hover);
}

/* Links and interactive elements */
a:not(.btn):hover {
  color: var(--zen-hover);
}

/* Active states */
.nav-link.active,
.navbar-nav .nav-link:hover {
  color: var(--zen-hover) !important;
}

/* Sidebar controls - simple approach */
@media (min-width: 1200px) {
  /* Hide all sidebar toggle buttons on wide screens - no collapse/expand functionality */
  #layout-menu .app-brand .layout-menu-toggle {
    display: none !important;
  }
  
  /* Force sidebar to always be expanded on wide screens */
  html.layout-menu-collapsed #layout-menu {
    width: var(--layout-menu-expanded-width) !important;
  }
  
  /* Ensure brand text is always visible on wide screens */
  html.layout-menu-collapsed #layout-menu .app-brand .app-brand-text {
    display: block !important;
  }
}

.dataTables_wrapper .row:last-child {
  padding-left:20px !important;
  padding-right:20px !important;
  padding-top:20px !important;
  padding-bottom:5px !important;
}

/* ZenScore inline SVG wrapper */
.zs-link { display: inline-flex; align-items: center; justify-content: center; line-height: 0; }
.zs-link svg { display: block; height: auto; }

