:root {
  --crm-primary: #6366f1;
  --crm-primary-dark: #4f46e5;
  --crm-primary-soft: rgba(99, 102, 241, 0.14);
  --crm-surface: rgba(255, 255, 255, 0.62);
  --crm-bg: #eef2ff;
  --crm-border: rgba(255, 255, 255, 0.45);
  --crm-text: #0f172a;
  --crm-text-muted: #64748b;
  --glass-bg: rgba(255, 255, 255, 0.55);
  --glass-bg-strong: rgba(255, 255, 255, 0.72);
  --glass-bg-soft: rgba(255, 255, 255, 0.38);
  --glass-border: rgba(255, 255, 255, 0.62);
  --glass-border-dark: rgba(99, 102, 241, 0.16);
  --glass-shadow: 0 8px 32px rgba(15, 23, 42, 0.08);
  --glass-shadow-lg: 0 18px 50px -20px rgba(79, 70, 229, 0.28);
  --glass-blur: blur(18px);
  --glass-blur-strong: blur(26px);
}

.glass-surface {
  background: var(--glass-bg-strong);
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
}

html {
  scroll-behavior: smooth;
}

body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  transition: color 0.15s ease, background-color 0.15s ease, border-color 0.15s ease;
}

a.text-primary,
.text-primary,
.text-info {
  color: var(--crm-primary-dark) !important;
}

a.text-primary:hover,
a.text-primary:focus {
  color: var(--crm-primary) !important;
}

.label-primary,
.badge-primary {
  background: var(--crm-primary) !important;
}

.progress-bar-primary,
.progress-bar-info {
  background-color: var(--crm-primary) !important;
}

.dropdown-menu {
  background: var(--glass-bg-strong);
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border: 1px solid var(--glass-border);
  border-radius: 0.875rem;
  box-shadow: var(--glass-shadow-lg);
  padding: 0.35rem;
}

.dropdown-menu > li > a {
  border-radius: 0.5rem;
  padding: 0.55rem 0.85rem;
}

.dropdown-menu > li > a:hover,
.dropdown-menu > li > a:focus {
  background: rgba(99, 102, 241, 0.12);
  color: var(--crm-primary-dark);
}

.modal-content {
  background: var(--glass-bg-strong);
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border: 1px solid var(--glass-border);
  border-radius: 1.125rem;
  box-shadow: var(--glass-shadow-lg);
}

.modal,
.modal-backdrop {
  position: fixed !important;
}

.modal {
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 1050;
  overflow-x: hidden;
  overflow-y: auto;
}

.modal-backdrop {
  z-index: 1040;
}

.modal-dialog {
  margin: 30px auto;
}

.modal.in .modal-dialog {
  transform: none;
}

.modal-header {
  border-bottom-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.35);
  border-top-left-radius: 1.125rem;
  border-top-right-radius: 1.125rem;
}

.modal-footer {
  border-top-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.28);
  border-bottom-left-radius: 1.125rem;
  border-bottom-right-radius: 1.125rem;
}

.alert {
  border-radius: 0.875rem;
  border-width: 1px;
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
}

.table > thead > tr > th {
  color: var(--crm-text-muted);
  font-weight: 600;
  border-bottom-color: var(--crm-border);
}

.table > tbody > tr:hover {
  background-color: rgba(255, 255, 255, 0.35);
}

/* Keep tag pills inside their DataTables column (estimates, invoices, etc.) */
table.dataTable thead th.tags-column,
table.dataTable tbody td:has(.tags-labels) {
  min-width: 11rem;
  max-width: 13rem;
  width: 13rem;
  white-space: normal !important;
  vertical-align: top;
}

table.dataTable tbody td .tags-labels {
  min-width: 0 !important;
  max-width: 100% !important;
  width: 100%;
  overflow: hidden;
}

table.dataTable tbody td .tags-labels .label-tag {
  max-width: 100%;
  white-space: normal;
  word-break: break-word;
  overflow-wrap: anywhere;
  line-height: 1.25;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  background: var(--crm-primary) !important;
  border-color: var(--crm-primary) !important;
  color: #fff !important;
  border-radius: 0.5rem !important;
}

#wrapper {
  background:
    radial-gradient(circle at 15% 20%, rgba(99, 102, 241, 0.22), transparent 34%),
    radial-gradient(circle at 85% 0%, rgba(14, 165, 233, 0.18), transparent 28%),
    radial-gradient(circle at 70% 85%, rgba(168, 85, 247, 0.14), transparent 30%),
    linear-gradient(135deg, #eef2ff 0%, #f8fafc 45%, #e0e7ff 100%);
  background-attachment: fixed;
}

[dir="rtl"] .sidebar.crm-glass-sidebar {
  border-left: 1px solid rgba(255, 255, 255, 0.45) !important;
  border-right: none !important;
}

/* Glass navbar redesign */
#header.crm-glass-navbar {
  background: rgba(255, 255, 255, 0.52) !important;
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.55) !important;
  box-shadow: 0 10px 40px -24px rgba(79, 70, 229, 0.25) !important;
}

#header.crm-glass-navbar nav > .tw-flex {
  align-items: center;
  min-height: 57px;
}

#header .crm-navbar-actions {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  padding-right: 0.75rem;
}

[dir="rtl"] #header .crm-navbar-actions {
  padding-right: 0;
  padding-left: 0.75rem;
}

#header .logo.logo-text {
  font-weight: 700;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, #312e81 0%, #6366f1 55%, #0ea5e9 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.crm-nav-icon-btn,
.crm-nav-quick-create-btn,
#header .crm-navbar-actions > li.icon > a,
#header .crm-navbar-actions > li.header-timers > a,
#header .crm-navbar-actions > li > a.crm-nav-settings,
#header .notifications-icon {
  background: rgba(255, 255, 255, 0.42) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.58) !important;
  box-shadow: 0 4px 16px -10px rgba(79, 70, 229, 0.35);
  transition: all 0.2s ease;
}

.crm-nav-icon-btn,
.crm-nav-quick-create-btn {
  color: #475569 !important;
  border-radius: 0.875rem !important;
}

.crm-nav-icon-btn:hover,
.crm-nav-icon-btn:focus {
  color: #4338ca !important;
  background: rgba(255, 255, 255, 0.72) !important;
  border-color: rgba(99, 102, 241, 0.28) !important;
  transform: translateY(-1px);
}

#header .crm-navbar-actions > li.icon > a,
#header .crm-navbar-actions > li.header-timers > a,
#header .notifications-icon {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  min-width: 2.25rem;
  min-height: 2.25rem;
  margin-top: 0.95rem;
  padding: 0 0.55rem !important;
  border-radius: 0.875rem !important;
  height: auto !important;
}

#header .crm-navbar-actions > li > a.crm-nav-settings {
  display: inline-flex !important;
  align-items: center;
  min-height: 2.25rem;
  margin-top: 0.95rem;
  padding: 0 0.85rem !important;
  border-radius: 999px !important;
  height: auto !important;
  color: #475569 !important;
  font-weight: 600;
}

#header .crm-navbar-actions > li.icon > a:hover,
#header .crm-navbar-actions > li.icon > a:focus,
#header .crm-navbar-actions > li.header-timers > a:hover,
#header .crm-navbar-actions > li.header-timers > a:focus,
#header .notifications-icon:hover,
#header .notifications-icon:focus,
#header .crm-navbar-actions > li > a.crm-nav-settings:hover,
#header .crm-navbar-actions > li > a.crm-nav-settings:focus {
  color: #4338ca !important;
  background: rgba(255, 255, 255, 0.78) !important;
  border-color: rgba(99, 102, 241, 0.28) !important;
  transform: translateY(-1px);
}

#header .crm-navbar-actions > li.icon > a i,
#header .notifications-icon i {
  color: inherit !important;
}

.crm-nav-quick-create-btn {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.92), rgba(79, 70, 229, 0.96)) !important;
  color: #fff !important;
  border-color: rgba(255, 255, 255, 0.35) !important;
  box-shadow: 0 8px 22px -10px rgba(79, 70, 229, 0.65);
}

.crm-nav-quick-create:hover .crm-nav-quick-create-btn,
.crm-nav-quick-create:focus .crm-nav-quick-create-btn {
  transform: translateY(-1px) scale(1.03);
  box-shadow: 0 12px 28px -10px rgba(79, 70, 229, 0.75);
}

#top_search input.crm-nav-search,
#top_search input[type="search"] {
  background: rgba(255, 255, 255, 0.42) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.58) !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35), 0 4px 18px -12px rgba(79, 70, 229, 0.35);
}

#top_search input.crm-nav-search:focus,
#top_search input[type="search"]:focus {
  background: rgba(255, 255, 255, 0.72) !important;
  border-color: rgba(99, 102, 241, 0.35) !important;
  box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.12), 0 8px 24px -12px rgba(79, 70, 229, 0.35) !important;
}

#top_search #search_results,
#top_search .search-results,
#top_search .dropdown-menu.search-results {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.62);
  border-radius: 1rem;
  box-shadow: var(--glass-shadow-lg);
}

.mobile-navbar {
  background: rgba(255, 255, 255, 0.72) !important;
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: var(--glass-shadow-lg);
  border-radius: 0 0 1rem 1rem;
  margin-top: 0.25rem;
}

.mobile-navbar .nav.navbar-nav > li > a {
  border-radius: 0.75rem;
  margin: 0.15rem 0.5rem;
  padding: 0.65rem 0.85rem !important;
  height: auto !important;
  color: #475569 !important;
  font-weight: 500;
  transition: all 0.18s ease;
}

.mobile-navbar .nav.navbar-nav > li > a:hover,
.mobile-navbar .nav.navbar-nav > li > a:focus {
  background: rgba(255, 255, 255, 0.62) !important;
  color: #4338ca !important;
}

.mobile-navbar .navbar-nav > li > a {
  border-bottom: none !important;
}

/* Glass sidebar redesign */
.sidebar.crm-glass-sidebar {
  background: rgba(255, 255, 255, 0.38) !important;
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  border-right: 1px solid rgba(255, 255, 255, 0.45) !important;
  box-shadow: 12px 0 40px -30px rgba(79, 70, 229, 0.25);
}

.sidebar.crm-glass-sidebar > ul.nav > li:hover a:first-child,
.sidebar.crm-glass-sidebar > ul.nav > li.active a:first-child {
  background: rgba(255, 255, 255, 0.58) !important;
  border: 1px solid rgba(255, 255, 255, 0.75) !important;
  box-shadow: 0 8px 24px -16px rgba(79, 70, 229, 0.35) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.sidebar.crm-glass-sidebar ul.nav li.active > a,
.sidebar.crm-glass-sidebar ul.nav > li > a:hover,
.sidebar.crm-glass-sidebar ul.nav > li > a:focus {
  color: #4338ca !important;
}

.sidebar .crm-sidebar-profile {
  background: rgba(255, 255, 255, 0.42) !important;
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 255, 255, 0.58) !important;
  border-radius: 1rem !important;
  padding: 0.65rem 0.75rem !important;
  box-shadow: 0 8px 24px -16px rgba(79, 70, 229, 0.28);
  color: #334155 !important;
  transition: all 0.2s ease;
}

.sidebar .crm-sidebar-profile:hover,
.sidebar .crm-sidebar-profile:focus {
  background: rgba(255, 255, 255, 0.62) !important;
  border-color: rgba(99, 102, 241, 0.25) !important;
  transform: translateY(-1px);
}

.sidebar .crm-sidebar-profile .tw-text-neutral-500,
.sidebar .crm-sidebar-profile span.tw-text-sm {
  color: #64748b !important;
}

.sidebar ul.nav li a {
  border-radius: 0.875rem;
  margin-left: 0.15rem;
  margin-right: 0.15rem;
  transition: all 0.18s ease;
}

.sidebar ul.nav li a i.menu-icon {
  width: 2rem;
  height: 2rem;
  margin-right: 0.75rem;
  margin-top: -0.1rem;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  float: none !important;
  border-radius: 0.7rem;
  background: rgba(255, 255, 255, 0.35);
  border: 1px solid rgba(255, 255, 255, 0.45);
  color: #64748b !important;
  font-size: 0.95rem !important;
}

.sidebar > ul.nav > li.active > a i.menu-icon,
.sidebar > ul.nav > li:hover > a i.menu-icon,
.sidebar > ul.nav > li > a:focus i.menu-icon {
  background: rgba(99, 102, 241, 0.14);
  border-color: rgba(99, 102, 241, 0.22);
  color: #4338ca !important;
}

.sidebar > ul.nav > li.active {
  border-left-color: #6366f1;
}

.sidebar ul.nav li .nav-second-level li a {
  margin-left: 0.35rem;
  border-radius: 0.75rem;
}

.sidebar ul.nav li .nav-second-level li.active a {
  background: rgba(255, 255, 255, 0.42) !important;
  border: 1px solid rgba(255, 255, 255, 0.55) !important;
  color: #4338ca !important;
}

.sidebar .badge,
.sidebar .menu-badge {
  border-radius: 999px;
  box-shadow: 0 4px 12px -8px rgba(15, 23, 42, 0.35);
}

.sidebar .dropdown-menu {
  margin-top: 0.35rem;
}

.content {
  padding-top: 1rem;
}

.login_admin,
.login_client,
.forgot_password,
.reset_password {
  background:
    radial-gradient(circle at top right, rgb(99 102 241 / 0.28), transparent 35%),
    radial-gradient(circle at bottom left, rgb(14 165 233 / 0.22), transparent 30%),
    radial-gradient(circle at 50% 50%, rgb(168 85 247 / 0.12), transparent 40%),
    linear-gradient(135deg, #eef2ff 0%, #f8fafc 50%, #e0e7ff 100%) !important;
  background-attachment: fixed !important;
}

/* Login video background */
.login-video-bg {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.login-video-bg video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  filter: saturate(1.05) contrast(1.02);
}

.login-video-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.18) 0%, rgba(15, 23, 42, 0.08) 45%, rgba(15, 23, 42, 0.22) 100%);
}

.login_admin.login-video-active {
  background: transparent !important;
}

.login_admin.login-video-active .authentication-form-wrapper > .text-center h1 {
  color: #0f172a !important;
  text-shadow: 0 2px 16px rgba(255, 255, 255, 0.95), 0 0 24px rgba(255, 255, 255, 0.75);
}

.login_admin.login-video-active .authentication-form-wrapper > .text-center p {
  color: #334155 !important;
  text-shadow: 0 1px 12px rgba(255, 255, 255, 0.9);
}

.login_admin.login-video-active .company-logo img {
  filter: drop-shadow(0 2px 16px rgba(255, 255, 255, 0.95));
}

.login_admin.login-video-active .tw-bg-white {
  background: rgba(255, 255, 255, 0.32) !important;
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  border: 1px solid rgba(255, 255, 255, 0.55) !important;
  box-shadow:
    0 24px 60px -20px rgba(15, 23, 42, 0.35),
    inset 0 1px 0 rgba(255, 255, 255, 0.65) !important;
}

.login_admin.login-video-active .form-control {
  background: rgba(255, 255, 255, 0.88) !important;
  border-color: rgba(255, 255, 255, 0.7) !important;
}

.login_admin.login-video-active .form-control:focus {
  background: rgba(255, 255, 255, 0.96) !important;
  border-color: rgba(99, 102, 241, 0.45) !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12) !important;
}

.authentication-form-wrapper .tw-bg-white,
.login_admin .tw-bg-white {
  background: rgba(255, 255, 255, 0.58) !important;
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border-radius: 1.25rem !important;
  border: 1px solid rgba(255, 255, 255, 0.62) !important;
  box-shadow: var(--glass-shadow-lg) !important;
}

#header .navbar-nav > li > a:hover,
#header .navbar-nav > li > a:focus {
  color: var(--crm-primary-dark) !important;
}

.panel_s,
.panel {
  background: var(--glass-bg) !important;
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border: 1px solid var(--glass-border) !important;
  box-shadow: var(--glass-shadow);
  transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.panel-body,
.panel_s .panel-body {
  background: transparent !important;
}

.panel-heading {
  background: rgba(255, 255, 255, 0.28) !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.35) !important;
}

.panel_s:hover,
.panel:hover {
  box-shadow: var(--glass-shadow-lg);
  border-color: rgba(255, 255, 255, 0.78) !important;
}

/* Form fields — visible highlighted borders */
.form-control,
textarea.form-control,
select.form-control,
input.form-control,
input[type="text"],
input[type="password"],
input[type="email"],
input[type="url"],
input[type="number"],
input[type="tel"],
input[type="search"]:not(.crm-nav-search),
input[type="date"],
input[type="datetime"],
input[type="datetime-local"],
input[type="time"],
input[type="month"],
input[type="week"],
input[type="file"],
input[type="color"] {
  background: rgba(255, 255, 255, 0.82) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid #cbd5e1 !important;
  border-radius: 0.5rem !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04), 0 1px 2px rgba(15, 23, 42, 0.03) !important;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.form-control:hover,
textarea.form-control:hover,
select.form-control:hover,
input.form-control:hover,
input[type="text"]:hover,
input[type="password"]:hover,
input[type="email"]:hover,
input[type="url"]:hover,
input[type="number"]:hover,
input[type="tel"]:hover,
input[type="search"]:not(.crm-nav-search):hover,
input[type="date"]:hover,
input[type="datetime"]:hover,
input[type="datetime-local"]:hover,
input[type="time"]:hover,
input[type="month"]:hover,
input[type="week"]:hover,
input[type="file"]:hover {
  border-color: #94a3b8 !important;
}

.form-control:focus,
textarea.form-control:focus,
select.form-control:focus,
input.form-control:focus,
input[type="text"]:focus,
input[type="password"]:focus,
input[type="email"]:focus,
input[type="url"]:focus,
input[type="number"]:focus,
input[type="tel"]:focus,
input[type="search"]:not(.crm-nav-search):focus,
input[type="date"]:focus,
input[type="datetime"]:focus,
input[type="datetime-local"]:focus,
input[type="time"]:focus,
input[type="month"]:focus,
input[type="week"]:focus,
input[type="file"]:focus {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: #6366f1 !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.16), inset 0 1px 2px rgba(15, 23, 42, 0.04) !important;
  outline: none !important;
}

.bootstrap-select > .dropdown-toggle.btn-default,
.bootstrap-select .btn-default {
  background: rgba(255, 255, 255, 0.82) !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 0.5rem !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04), 0 1px 2px rgba(15, 23, 42, 0.03) !important;
  color: #334155 !important;
  transition: border-color 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
}

.bootstrap-select > .dropdown-toggle.btn-default:hover,
.bootstrap-select .btn-default:hover {
  border-color: #94a3b8 !important;
  background: rgba(255, 255, 255, 0.92) !important;
}

.bootstrap-select.open > .dropdown-toggle.btn-default,
.bootstrap-select > .dropdown-toggle.btn-default:focus,
.bootstrap-select > .dropdown-toggle.btn-default:active {
  background: rgba(255, 255, 255, 0.95) !important;
  border-color: #6366f1 !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.16), inset 0 1px 2px rgba(15, 23, 42, 0.04) !important;
  outline: none !important;
}

.input-group-addon {
  background: rgba(255, 255, 255, 0.72) !important;
  border: 1px solid #cbd5e1 !important;
  color: #64748b !important;
}

.input-group .form-control {
  border-color: #cbd5e1 !important;
}

.input-group .form-control:focus {
  z-index: 2;
}

.has-error .form-control,
.has-error .bootstrap-select > .dropdown-toggle.btn-default {
  border-color: #f43f5e !important;
  box-shadow: 0 0 0 3px rgba(244, 63, 94, 0.12) !important;
}

.btn-primary {
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.92) 0%, rgba(79, 70, 229, 0.96) 100%) !important;
  border-color: rgba(255, 255, 255, 0.25) !important;
  box-shadow: 0 8px 24px -8px rgba(79, 70, 229, 0.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background: linear-gradient(180deg, #4f46e5 0%, #4338ca 100%) !important;
  border-color: #4338ca !important;
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 999px;
  border: 2px solid #f1f5f9;
}

::-webkit-scrollbar-thumb:hover {
  background: #94a3b8;
}

/* Expenses page year/currency toolbar */
.crm-expenses-stats-toolbar {
  padding-top: 0.15rem;
}

.crm-expenses-filter-control {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.35rem;
}

.crm-expenses-filter-label {
  margin: 0;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #64748b;
}

.crm-expenses-filter-control .btn-default,
.crm-expenses-filter-control .dropdown-toggle {
  background: rgba(255, 255, 255, 0.82) !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 0.75rem !important;
  min-height: 2.1rem;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
}

.crm-expenses-filter-control .btn-default:hover,
.crm-expenses-filter-control .btn-default:focus {
  border-color: #6366f1 !important;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.crm-expenses-year-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: rgba(99, 102, 241, 0.1);
  border: 1px solid rgba(99, 102, 241, 0.18);
  color: #4338ca;
  font-size: 0.82rem;
  font-weight: 600;
}

.crm-expenses-year-badge i {
  opacity: 0.85;
}

/* Tags input + autocomplete dropdown */
.tags-input-wrapper,
.form-group:has(ul.tagit) {
  position: relative;
  overflow: visible;
  z-index: 2;
}

.tags-input-shell {
  position: relative;
  width: 100%;
}

.form-group ul.tagit,
.tags-input-wrapper ul.tagit {
  width: 100% !important;
  min-height: 2.5rem;
  margin-top: 0 !important;
  padding: 0.35rem 0.55rem !important;
  background: rgba(255, 255, 255, 0.82) !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 0.5rem !important;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
  box-sizing: border-box;
}

.form-group ul.tagit input[type="text"],
.tags-input-wrapper ul.tagit input[type="text"] {
  min-width: 6rem;
  width: auto !important;
  max-width: 100%;
}

.form-group ul.tagit li.tagit-choice,
.tags-input-wrapper ul.tagit li.tagit-choice {
  max-width: 100%;
  word-break: break-word;
}

.form-group ul.tagit li.tagit-choice .tagit-label:not(a),
.tags-input-wrapper ul.tagit li.tagit-choice .tagit-label:not(a) {
  white-space: normal;
  word-break: break-word;
}

.tags-input-wrapper > ul.tagit-autocomplete.ui-autocomplete,
.tags-input-wrapper ul.tagit-autocomplete {
  position: absolute !important;
  box-sizing: border-box !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  margin-top: 0 !important;
  padding: 0.35rem !important;
  border: 1px solid #cbd5e1 !important;
  border-radius: 0.75rem !important;
  background: rgba(255, 255, 255, 0.98) !important;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 16px 40px -20px rgba(79, 70, 229, 0.35) !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  max-height: 220px !important;
  z-index: 10050 !important;
  list-style: none !important;
}

.tags-input-wrapper ul.tagit-autocomplete .ui-menu-item {
  display: block !important;
  width: 100% !important;
  float: none !important;
  clear: both !important;
  margin: 0 0 0.2rem 0 !important;
  padding: 0 !important;
}

.tags-input-wrapper ul.tagit-autocomplete .ui-menu-item-wrapper,
.tags-input-wrapper ul.tagit-autocomplete .ui-menu-item a {
  display: block !important;
  width: 100% !important;
  white-space: normal !important;
  word-break: break-word !important;
  overflow-wrap: anywhere !important;
  line-height: 1.35 !important;
  border-radius: 0.5rem !important;
  padding: 0.45rem 0.65rem !important;
}

.tags-input-wrapper ul.tagit-autocomplete .ui-menu-item-wrapper.ui-state-active,
.tags-input-wrapper ul.tagit-autocomplete .ui-menu-item-wrapper.ui-state-hover,
.tags-input-wrapper ul.tagit-autocomplete .ui-menu-item a.ui-state-active,
.tags-input-wrapper ul.tagit-autocomplete .ui-menu-item a.ui-state-hover {
  background: rgba(99, 102, 241, 0.12) !important;
  color: #312e81 !important;
  border: 1px solid transparent !important;
  margin: 0 !important;
}

/* Dashboard glass redesign */
body.dashboard #wrapper {
  background:
    radial-gradient(circle at 12% 18%, rgba(99, 102, 241, 0.28), transparent 34%),
    radial-gradient(circle at 88% 8%, rgba(14, 165, 233, 0.22), transparent 28%),
    radial-gradient(circle at 72% 88%, rgba(168, 85, 247, 0.18), transparent 32%),
    linear-gradient(135deg, #eef2ff 0%, #f8fafc 45%, #e0e7ff 100%);
  background-attachment: fixed;
}

body.dashboard .screen-options-btn {
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  color: var(--crm-primary-dark);
  border: 1px solid var(--glass-border);
  border-top: 0;
  border-bottom-left-radius: 0.875rem;
  border-bottom-right-radius: 0.875rem;
  box-shadow: var(--glass-shadow);
  transition: all 0.2s ease;
}

body.dashboard .screen-options-btn:hover {
  background: rgba(255, 255, 255, 0.78);
  color: var(--crm-primary-dark);
}

body.dashboard .screen-options-area {
  background: rgba(255, 255, 255, 0.45);
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border-bottom: 1px solid var(--glass-border);
}

body.dashboard .alert-warning {
  background: rgba(254, 243, 199, 0.55);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid rgba(253, 230, 138, 0.65);
  color: #92400e;
}

body.dashboard .top_stats_wrapper {
  padding: 1.15rem 1.25rem 1.35rem;
  background: rgba(255, 255, 255, 0.52);
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 1.125rem;
  box-shadow: var(--glass-shadow-lg);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  overflow: hidden;
  position: relative;
}

body.dashboard .dashboard-content {
  padding: 1.25rem 1.5rem 2rem;
}

body.dashboard .dashboard-content > .row {
  margin-left: -10px;
  margin-right: -10px;
}

body.dashboard .dashboard-content > .row > [class*="col-"] {
  padding-left: 10px;
  padding-right: 10px;
}

body.dashboard .widget {
  margin-bottom: 1.25rem;
}

body.dashboard .alert {
  border-radius: 0.875rem;
  box-shadow: var(--glass-shadow);
}

body.dashboard .top_stats_wrapper::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--crm-primary);
  border-radius: 1rem 0 0 1rem;
}

body.dashboard .top_stats_wrapper:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 34px -20px rgb(79 70 229 / 0.35);
  border-color: rgb(99 102 241 / 0.22);
}

body.dashboard .quick-stats-invoices .top_stats_wrapper::before {
  background: #6366f1;
}

body.dashboard .quick-stats-leads .top_stats_wrapper::before {
  background: #10b981;
}

body.dashboard .quick-stats-projects .top_stats_wrapper::before {
  background: #f59e0b;
}

body.dashboard .quick-stats-tasks .top_stats_wrapper::before {
  background: #0ea5e9;
}

body.dashboard .top_stats_wrapper svg {
  width: 2.35rem !important;
  height: 2.35rem !important;
  padding: 0.55rem;
  border-radius: 0.85rem;
  background: rgba(255, 255, 255, 0.45);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: var(--crm-primary-dark) !important;
  flex-shrink: 0;
}

body.dashboard .quick-stats-leads .top_stats_wrapper svg {
  color: #059669 !important;
}

body.dashboard .quick-stats-projects .top_stats_wrapper svg {
  color: #d97706 !important;
}

body.dashboard .quick-stats-tasks .top_stats_wrapper svg {
  color: #0284c7 !important;
}

body.dashboard .top_stats_wrapper .tw-font-semibold {
  color: var(--crm-text) !important;
  font-size: 0.95rem;
}

body.dashboard .top_stats_wrapper .progress,
body.dashboard .home-summary .progress,
body.dashboard .progress-finance-status .progress {
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.35);
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.35);
}

body.dashboard .top_stats_wrapper .progress-bar,
body.dashboard .home-summary .progress-bar,
body.dashboard .progress-finance-status .progress-bar {
  border-radius: 999px;
}

body.dashboard .widget .panel_s,
body.dashboard .finance-summary .panel_s {
  background: rgba(255, 255, 255, 0.48) !important;
  backdrop-filter: var(--glass-blur-strong);
  -webkit-backdrop-filter: var(--glass-blur-strong);
  border: 1px solid rgba(255, 255, 255, 0.62) !important;
  border-radius: 1.125rem;
  box-shadow: var(--glass-shadow-lg);
  overflow: hidden;
}

body.dashboard .widget .panel-body,
body.dashboard .finance-summary .panel-body {
  padding: 1.15rem 1.25rem !important;
}

body.dashboard .widget .panel-body hr,
body.dashboard .finance-summary hr {
  border-color: var(--crm-border);
  opacity: 0.85;
}

body.dashboard .widget .panel-body > p svg,
body.dashboard .widget .tw-flex svg.tw-w-6,
body.dashboard .home-summary p svg {
  padding: 0.5rem;
  border-radius: 0.75rem;
  background: rgba(255, 255, 255, 0.42);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.55);
  color: var(--crm-primary-dark) !important;
}

body.dashboard .home-summary a ._total,
body.dashboard .home-summary a .bold {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--crm-text);
}

body.dashboard .home-summary a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  transition: color 0.15s ease, opacity 0.15s ease;
}

body.dashboard .home-summary a:hover {
  opacity: 1;
  color: var(--crm-primary-dark) !important;
}

body.dashboard .home-summary-separator,
body.dashboard .finance-summary .col-md-12 + .col-md-12 {
  position: relative;
}

body.dashboard .progress-finance-status {
  margin-top: -1.25rem;
  margin-bottom: 1rem;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--crm-text-muted) !important;
}

body.dashboard .text-stats-wrapper {
  margin-bottom: 0.15rem;
}

body.dashboard .nav-tabs-horizontal,
body.dashboard .panel-full-width-tabs .nav {
  background: rgba(255, 255, 255, 0.35) !important;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 0.875rem 0.875rem 0 0;
}

body.dashboard .nav-tabs-horizontal > li > a,
body.dashboard .panel-full-width-tabs .nav li a {
  border-radius: 0.65rem 0.65rem 0 0;
  color: var(--crm-text-muted);
  font-weight: 600;
}

body.dashboard .nav-tabs-horizontal > li.active > a,
body.dashboard .nav-tabs-horizontal > li.active > a:hover,
body.dashboard .nav-tabs-horizontal > li.active > a:focus,
body.dashboard .panel-full-width-tabs .nav li.active a {
  color: var(--crm-primary-dark) !important;
  background: rgba(255, 255, 255, 0.62) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 2px solid var(--crm-primary) !important;
}

body.dashboard .table-responsive .table,
body.dashboard .dataTables_wrapper .table {
  border-radius: 0.75rem;
}

body.dashboard .table > thead > tr > th {
  background: rgba(255, 255, 255, 0.35);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

body.dashboard .table > tbody > tr > td {
  border-top-color: #f1f5f9;
  vertical-align: middle;
}

body.dashboard .todo-panel .todo-title {
  font-size: 0.95rem !important;
  font-weight: 700;
  letter-spacing: 0.01em;
}

body.dashboard .todo-panel .media {
  padding: 0.65rem 0.75rem;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 0.875rem;
  background: rgba(255, 255, 255, 0.22);
  transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

body.dashboard .todo-panel .media:hover {
  background: rgba(255, 255, 255, 0.48);
  border-color: rgba(255, 255, 255, 0.62);
  box-shadow: var(--glass-shadow);
}

body.dashboard #calendar,
body.dashboard .fc-theme-standard .fc-scrollgrid,
body.dashboard .fc-theme-standard td,
body.dashboard .fc-theme-standard th {
  border-color: var(--crm-border) !important;
}

body.dashboard .fc .fc-toolbar.fc-header-toolbar {
  margin-bottom: 1rem;
  gap: 0.75rem;
}

body.dashboard .fc .fc-button {
  border-radius: 0.65rem !important;
  font-weight: 600;
  box-shadow: none !important;
}

body.dashboard .fc .fc-button-primary {
  background: var(--crm-primary) !important;
  border-color: var(--crm-primary) !important;
}

body.dashboard .fc .fc-button-primary:not(:disabled).fc-button-active,
body.dashboard .fc .fc-button-primary:not(:disabled):active {
  background: var(--crm-primary-dark) !important;
  border-color: var(--crm-primary-dark) !important;
}

body.dashboard .fc .fc-daygrid-day-number,
body.dashboard .fc .fc-col-header-cell-cushion {
  color: var(--crm-text-muted);
  font-weight: 600;
}

body.dashboard .fc .fc-daygrid-day.fc-day-today {
  background: rgba(99, 102, 241, 0.12) !important;
}

body.dashboard .fc .fc-scrollgrid,
body.dashboard .fc-theme-standard td,
body.dashboard .fc-theme-standard th {
  background: rgba(255, 255, 255, 0.18);
}

body.dashboard .placeholder-dashboard-widgets {
  border: 2px dashed rgba(99, 102, 241, 0.28);
  background: rgba(255, 255, 255, 0.22);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 1.125rem;
}

body.dashboard .widget-dragger {
  color: rgba(148, 163, 184, 0.85);
  opacity: 0.75;
}

body.dashboard .widget-dragger:hover {
  color: var(--crm-primary);
  opacity: 1;
}

@media (max-width: 767px) {
  body.dashboard .dashboard-content {
    padding: 0.85rem 0.75rem 1.25rem;
  }

  body.dashboard .top_stats_wrapper {
    margin-bottom: 0.65rem;
  }
}

/* Estimate items grouped by category */
.estimate-items-panel {
  padding-top: 0.5rem;
}

.estimate-items-toolbar {
  margin-bottom: 1rem;
}

.estimate-items-toolbar .items-wrapper {
  margin-top: 0.35rem;
}

.estimate-category-sections {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  clear: both;
  width: 100%;
}

.estimate-items-totals {
  clear: both;
  margin-top: 1.25rem;
  float: none !important;
}

.estimate-category-block {
  background: var(--glass-bg-strong);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border-dark);
  border-radius: 1rem;
  box-shadow: var(--glass-shadow);
  overflow: hidden;
}

.estimate-items-entry-table {
  margin-bottom: 1rem;
}

.estimate-items-entry-table .table-responsive {
  background: var(--glass-bg-strong);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border-dark);
  border-radius: 1rem;
  box-shadow: var(--glass-shadow);
  padding: 0.75rem 0.75rem 0.25rem;
}

.estimate-category-block {
  margin-top: 0.75rem;
}

.estimate-category-block .estimate-category-items-table {
  margin-bottom: 0;
}

.estimate-category-block .estimate-category-items-table tbody tr.item td:first-child {
  width: 30px;
}

.estimate-category-block .estimate-category-items-table tbody tr.item td {
  border-top: 1px solid rgba(148, 163, 184, 0.14);
  vertical-align: top;
}

.estimate-items-entry-table textarea.form-control,
.estimate-category-block .estimate-category-items-table textarea.form-control {
  min-height: 2.35rem;
  padding: 0.4rem 0.65rem;
  line-height: 1.35;
  resize: vertical;
}

.estimate-category-block .estimate-category-items-table td.custom_field .form-group {
  margin-bottom: 0;
}

.estimate-category-block .estimate-category-items-table td.custom_field textarea.form-control {
  min-height: 2.35rem;
}

.estimate-category-block.is-active {
  border-color: rgba(99, 102, 241, 0.35);
  box-shadow: var(--glass-shadow-lg);
}

.estimate-category-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: rgba(148, 163, 184, 0.16);
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #475569;
  cursor: pointer;
}

table.items.items-preview.estimate-items-preview .estimate-items-category-heading,
table.items.items-preview[data-type="estimate"] .estimate-items-category-heading {
  padding: 0.65rem 0.85rem;
  background: rgba(148, 163, 184, 0.16);
  border-top: 1px solid rgba(148, 163, 184, 0.18);
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #475569;
}

.estimate-category-block .table-responsive {
  padding: 0.75rem 0.75rem 0.25rem;
}

.estimate-category-block .estimate-items-table {
  margin-bottom: 0;
}

.estimate-category-block .estimate-items-table thead th {
  border-bottom: 1px solid rgba(148, 163, 184, 0.18);
  color: #64748b;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
}

.estimate-category-block .estimate-items-table textarea.form-control,
.estimate-category-block .estimate-items-table input.form-control,
.estimate-category-block .estimate-items-table .bootstrap-select .dropdown-toggle {
  border-radius: 0.75rem;
}

.estimate-category-empty {
  border: 1px dashed rgba(99, 102, 241, 0.22);
  border-radius: 1rem;
  background: rgba(255, 255, 255, 0.35);
}

.items-category-wrapper .bootstrap-select .dropdown-toggle {
  border-radius: 0.75rem;
}

.items-wrapper .bootstrap-select .dropdown-menu .dropdown-header,
.items-wrapper .bootstrap-select .dropdown-menu li.dropdown-header,
.items-wrapper .bootstrap-select .dropdown-menu .divider + .dropdown-header {
  background: rgba(148, 163, 184, 0.22);
  color: #334155;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0.55rem 0.85rem;
  margin: 0.15rem 0;
}

.items-wrapper .bootstrap-select .dropdown-menu li:not(.dropdown-header) a {
  padding-left: 1.15rem;
}

.items-wrapper .bootstrap-select .dropdown-menu li.active:not(.dropdown-header) a,
.items-wrapper .bootstrap-select .dropdown-menu li:not(.dropdown-header) a:hover {
  background: rgba(99, 102, 241, 0.12);
  color: var(--crm-primary-dark);
}

.estimate-category-block .estimate-add-item-btn {
  border-radius: 0.75rem;
  min-width: 42px;
}

/* ---------------------------------------------------------------- */
/* PREMIUM SUBMENU REDESIGN & WRAPPING PREVENTER */
/* ---------------------------------------------------------------- */

/* Submenu container as a unified glassmorphic panel */
.sidebar ul.nav li .nav-second-level {
  background: rgba(255, 255, 255, 0.15) !important;
  margin: 0.25rem 0.5rem 0.5rem 0.5rem !important;
  border-radius: 0.875rem !important;
  padding: 0.35rem !important;
  border: 1px solid rgba(255, 255, 255, 0.25) !important;
  box-shadow: inset 0 2px 8px rgba(79, 70, 229, 0.04) !important;
}

/* Individual submenu link styles — reset default card appearances */
.sidebar ul.nav li .nav-second-level li a {
  background: transparent !important;
  border: 1px solid transparent !important;
  box-shadow: none !important;
  margin: 0.15rem 0 !important;
  padding: 0.55rem 0.75rem !important;
  display: flex !important;
  align-items: center !important;
  gap: 0.75rem !important;
  color: #475569 !important;
  font-size: 0.82rem !important;
  font-weight: 500 !important;
  transition: all 0.18s ease !important;
  width: auto !important;
}

/* Submenu hover state */
.sidebar ul.nav li .nav-second-level li a:hover,
.sidebar ul.nav li .nav-second-level li a:focus {
  background: rgba(255, 255, 255, 0.55) !important;
  border-color: rgba(255, 255, 255, 0.75) !important;
  color: #4338ca !important;
  box-shadow: 0 4px 12px -8px rgba(79, 70, 229, 0.2) !important;
}

/* Submenu active/selected state */
.sidebar ul.nav li .nav-second-level li.active a {
  background: rgba(99, 102, 241, 0.12) !important;
  border: 1px solid rgba(99, 102, 241, 0.22) !important;
  color: #4338ca !important;
  font-weight: 600 !important;
  box-shadow: none !important;
}

/* Remove default heavy background/border boxes from sub-menu icons */
.sidebar ul.nav li .nav-second-level li a i.menu-icon {
  background: transparent !important;
  border: none !important;
  width: auto !important;
  height: auto !important;
  margin-right: 0 !important;
  margin-top: 0 !important;
  font-size: 0.875rem !important;
  color: #64748b !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* Submenu icon active state */
.sidebar ul.nav li .nav-second-level li a:hover i.menu-icon,
.sidebar ul.nav li .nav-second-level li.active a i.menu-icon {
  color: #4338ca !important;
}

/* Delicate dot-bullet styling for items without custom icons */
.sidebar ul.nav li .nav-second-level li a i.sub-menu-bullet {
  font-size: 0.45rem !important;
  opacity: 0.45;
  margin-left: 0.2rem !important;
  margin-right: 0.2rem !important;
  transition: all 0.18s ease !important;
}

/* Bullet hover state */
.sidebar ul.nav li .nav-second-level li a:hover i.sub-menu-bullet,
.sidebar ul.nav li .nav-second-level li.active a i.sub-menu-bullet {
  opacity: 0.95;
  transform: scale(1.2);
  color: #4338ca !important;
}

/* Submenu text wrapping preventer and ellipsis */
.sidebar ul.nav li .nav-second-level li a .sub-menu-text {
  white-space: nowrap !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  flex: 1 !important;
  text-align: left !important;
  display: inline-block !important;
  vertical-align: middle !important;
}
