.nav-link.active {
    background-color: #5e72e4;
    border-radius: 0.375rem;
    color: #fff !important;
}

.nav-link.active i {
    color: #fff !important;
}

/* Remove all background colors from parent items */
.nav-item.active {
    background-color: transparent !important;
}

.nav-item.active > .nav-link {
    background-color: transparent !important;
    color: #67748e !important;
}

.nav-item.active > .nav-link i {
    color: #67748e !important;
}

/* Only show blue background on the specific active link */
.nav-item .collapse .nav-link.active,
.nav-item .collapsing .nav-link.active {
    background-color: #5e72e4 !important;
    color: #fff !important;
}

.nav-item .collapse .nav-link.active i,
.nav-item .collapsing .nav-link.active i {
    color: #fff !important;
}

/* Keep parent items expanded but not highlighted */
.nav-item .collapse.show,
.nav-item .collapsing {
    display: block;
}

.nav-item .nav-link.active:hover {
    color: #fff !important;
}

.sidenav .nav-item .collapse .nav .nav-item .nav-link.active,
.sidenav .nav-item .collapsing .nav .nav-item .nav-link.active {
    background-color: #5e72e4;
    color: #fff !important;
}

.sidenav .nav-item .collapse .nav .nav-item .nav-link.active i,
.sidenav .nav-item .collapsing .nav .nav-item .nav-link.active i {
    color: #fff !important;
}

/* Enhanced Sidenav Toggle Functionality */
.g-sidenav-hidden .sidenav {
    transform: translateX(-250px);
}

.g-sidenav-hidden .main-content {
    margin-left: 0 !important;
}

.g-sidenav-show .sidenav {
    transform: translateX(0);
}

.g-sidenav-show .main-content {
    margin-left: 250px;
}

@media (max-width: 1199.98px) {
    .g-sidenav-show .main-content {
        margin-left: 0;
    }
    
    .g-sidenav-hidden .sidenav {
        transform: translateX(-250px);
    }
    
    .g-sidenav-show .sidenav {
        transform: translateX(0);
    }
}

/* Sidenav toggler styling */
.sidenav-toggler {
    cursor: pointer;
    transition: all 0.3s ease;
}

.sidenav-toggler:hover {
    opacity: 0.8;
}

.sidenav-toggler.active {
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

/* Sidenav header toggle button */
.sidenav-toggle-btn {
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    color: #67748e;
    background: transparent;
    border: none;
    padding: 5px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.sidenav-toggle-btn:hover {
    color: #5e72e4;
    background-color: rgba(94, 114, 228, 0.1);
}

.sidenav-toggle-btn:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(94, 114, 228, 0.25);
}

/* Backdrop for mobile */
.backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1040;
    cursor: pointer;
}

/* Modal tab navigation styling */
.modal .nav-tabs {
    border-bottom: 0;
}

.modal .nav-tabs .nav-link {
    color: #67748e;
    padding: 1rem;
    transition: all 0.2s ease;
    border: 0;
    position: relative;
    background-color: transparent;
}

.modal .nav-tabs .nav-link:not(.active):hover {
    color: #5e72e4;
    background-color: transparent !important;
}

.modal .nav-tabs .nav-link:not(.active):hover i {
    color: #5e72e4;
}

.modal .nav-tabs .nav-link.active,
.modal .nav-tabs .nav-link.active:hover,
.modal .nav-tabs .nav-link.active:focus {
    background-color: transparent !important;
    color: #5e72e4 !important;
    font-weight: 600;
    border-bottom: 2px solid #5e72e4;
    border-radius: 0;
}

.modal .nav-tabs .nav-link.active i,
.modal .nav-tabs .nav-link.active:hover i,
.modal .nav-tabs .nav-link.active:focus i {
    color: #5e72e4 !important;
}

.modal .nav-tabs .nav-link.active:hover {
    cursor: default;
} 

/* Sidenav collapse/expand button styles */
.sidenav-collapse-btn {
  color: #67748e;
  background: transparent;
  border: none;
  padding: 5px 8px;
  border-radius: 4px;
  transition: all 0.3s ease;
  font-size: 1.2rem;
}
.sidenav-collapse-btn:hover {
  color: #5e72e4;
  background-color: rgba(94, 114, 228, 0.1);
}
.sidenav-collapse-btn:focus {
  outline: none;
  box-shadow: 0 0 0 2px rgba(94, 114, 228, 0.25);
}
.sidenav-expand-btn {
  display: none;
  position: fixed;
  top: 20px;
  left: 10px;
  z-index: 2000;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  padding: 0;
  justify-content: center;
  align-items: center;
  font-size: 1.2rem;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.g-sidenav-hidden .sidenav-expand-btn {
  display: flex !important;
}
.g-sidenav-hidden .sidenav {
  transform: translateX(-250px);
}
.g-sidenav-hidden .main-content {
  margin-left: 0 !important;
} 

/* Dashboard Styles */
.dashboard-container {
  padding: 1.5rem 1rem;
  max-width: 1600px;
  margin: 0 auto;
  background: #f8f9fc;
}
.dashboard-sections {
  background: linear-gradient(120deg, #f8f9fa 70%, #e9ecef 100%);
  border-radius: 24px;
  box-shadow: 0 4px 32px rgba(44, 62, 80, 0.07);
  padding: 2rem 1.5rem 1.5rem 1.5rem;
  margin-bottom: 2rem;
}
.dashboard-header {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 24px;
}
.dashboard-header h2 {
    font-family: 'Inter', 'Segoe UI', 'Roboto', Arial, sans-serif;
    font-size: 2.2rem;
    font-weight: 700;
    color: #222;
    margin-bottom: 4px;
}
.dashboard-header .dashboard-welcome {
    font-size: 1.1rem;
    color: #5e72e4;
    margin-bottom: 0;
    font-weight: 400;
}
.dashboard-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  margin-bottom: 0;
}
@media (min-width: 1200px) {
  .dashboard-cards {
    grid-template-columns: repeat(4, 1fr);
  }
}
.dashboard-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(44, 62, 80, 0.10);
  padding: 20px 24px 18px 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  transition: box-shadow 0.2s, transform 0.2s;
  min-width: 0;
  min-height: 120px;
}
.dashboard-card.dashboard-quick-actions {
  background: linear-gradient(120deg, #e9ecef 60%, #f8f9fa 100%);
  align-items: stretch;
}
.quick-actions-btns {
  display: flex;
  gap: 10px;
  margin-top: 10px;
}
.btn {
  border: none;
  border-radius: 6px;
  padding: 8px 16px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}
.btn-primary {
  background: #5e72e4;
  color: #fff;
}
.btn-primary:hover {
  background: #324cdd;
}
.btn-secondary {
  background: #f4f5f7;
  color: #5e72e4;
}
.btn-secondary:hover {
  background: #e9ecef;
}
.dashboard-card.dashboard-chart {
  background: linear-gradient(120deg, #f8f9fa 60%, #e9ecef 100%);
  align-items: stretch;
  min-height: 180px;
}
.dashboard-card .card-title {
  font-size: 1.05rem;
  font-weight: 600;
  color: #67748e;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.dashboard-card .card-value {
  font-size: 2.1rem;
  font-weight: 700;
  color: #222;
  margin-bottom: 0;
}
.dashboard-card .card-subvalue {
  font-size: 0.875rem;
  font-weight: 500;
  margin-top: 4px;
  opacity: 0.85;
}
.dashboard-card .card-icon {
  font-size: 2.3rem;
  color: #5e72e4;
  margin-bottom: 10px;
}
.dashboard-tables {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    margin-top: 0;
}
.dashboard-table {
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(44, 62, 80, 0.10);
    padding: 18px 18px 10px 18px;
    min-width: 0;
    margin-bottom: 0;
    overflow-x: auto;
}
.dashboard-table .table-title {
    font-size: 1.08rem;
    font-weight: 700;
    color: #5e72e4;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.table-responsive {
    width: 100%;
    overflow-x: auto;
}
.table-responsive table {
    width: 100%;
    border-collapse: collapse;
    min-width: 420px;
}

/* Customer Receivables Table with scrollbar */
.customer-receivables-table {
    max-height: 400px;
    overflow-y: auto;
    overflow-x: auto;
}

/* Style the scrollbar for customer receivables */
.customer-receivables-table::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.customer-receivables-table::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.customer-receivables-table::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.customer-receivables-table::-webkit-scrollbar-thumb:hover {
    background: #555;
}

th, td {
    padding: 10px 8px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 1rem;
}
th {
    background: #f8f9fa;
    color: #5e72e4;
    font-weight: 700;
}
tr:last-child td {
    border-bottom: none;
}
.text-center {
    text-align: center;
}
@media (max-width: 1200px) {
  .dashboard-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 900px) {
  .dashboard-container {
    padding: 1rem 0.5rem;
  }
  .dashboard-sections {
    padding: 1rem 0.5rem 0.5rem 0.5rem;
  }
  .dashboard-cards {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .dashboard-card {
    min-height: 100px;
  }
  .dashboard-header h2 {
        font-size: 1.5rem;
    }
    .dashboard-header .dashboard-welcome {
        font-size: 1rem;
    }
    .dashboard-card .card-value {
        font-size: 1.5rem;
    }
    .dashboard-table .table-title {
        font-size: 1rem;
    }
    .table-responsive table {
        min-width: 340px;
    }
    th.hide-mobile, td.hide-mobile {
        display: none;
    }
}
@media (max-width: 600px) {
    .dashboard-header h2 {
        font-size: 1.1rem;
    }
    .dashboard-header .dashboard-welcome {
        font-size: 0.95rem;
    }
    .dashboard-card .card-value {
        font-size: 1.1rem;
    }
    .dashboard-table .table-title {
        font-size: 0.95rem;
    }
    th, td {
        font-size: 0.95rem;
        padding: 8px 4px;
    }
    .dashboard-cards {
      grid-template-columns: 1fr;
      gap: 10px;
    }
    .dashboard-card {
      min-height: 80px;
      padding: 10px 6px 8px 6px;
    }
    .dashboard-card.dashboard-chart.wide {
      grid-column: span 1;
      min-height: 120px;
      padding: 8px 2px 4px 2px;
    }
    .dashboard-card .card-title {
      font-size: 0.98rem;
    }
    .dashboard-card .card-value {
      font-size: 1.2rem;
    }
    .quick-actions-btns {
      flex-direction: column;
      gap: 6px;
    }
    .btn {
      font-size: 0.98rem;
      padding: 10px 0;
      width: 100%;
      min-height: 44px;
    }
    .dashboard-table {
      padding: 8px 2px 4px 2px;
    }
    .table-responsive table {
      min-width: 320px;
    }
    th, td {
      font-size: 0.95rem;
      padding: 6px 2px;
    }
} 
.dashboard-card.dashboard-chart.wide {
  grid-column: span 2;
  min-height: 320px;
  padding: 32px 32px 24px 32px;
  background: linear-gradient(120deg, #f8f9fa 60%, #e9ecef 100%);
  box-shadow: 0 4px 24px rgba(44, 62, 80, 0.10);
  margin-bottom: 24px;
}
@media (max-width: 1200px) {
  .dashboard-card.dashboard-chart.wide {
    grid-column: span 1;
    min-height: 220px;
    padding: 18px 8px 12px 8px;
  }
} 
.badge-status {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: 0.92em;
  font-weight: 600;
  color: #fff;
  margin: 0 2px;
  vertical-align: middle;
}
.badge-success {
  background: #2ecc71;
}
.badge-pending {
  background: #f39c12;
}
.badge-danger {
  background: #e74c3c;
}
.badge-default {
  background: #b2bec3;
}

/* Dashboard Date Range Filter Styles */
.dashboard-filters {
  margin-top: 15px;
  padding: 15px;
  background: #f8f9fa;
  border-radius: 8px;
  border: 1px solid #dee2e6;
}

.date-range-filter {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.date-range-filter label {
  font-weight: 600;
  margin-bottom: 0;
  color: #495057;
}

.date-range-filter input[type="date"] {
  max-width: 180px;
  border: 1px solid #ced4da;
  background-color: white;
}

.date-separator {
  color: #6c757d;
  font-weight: 500;
}

.date-range-filter .btn {
  padding: 0.25rem 0.75rem;
  font-size: 0.875rem;
}

.date-range-filter .btn-primary {
  background-color: #5e72e4;
  border-color: #5e72e4;
}

.date-range-filter .btn-primary:hover {
  background-color: #4c63d2;
  border-color: #4c63d2;
}

.date-range-filter .btn-secondary {
  background-color: #6c757d;
  border-color: #6c757d;
  color: white;
}

.date-range-filter .btn-secondary:hover {
  background-color: #5a6268;
  border-color: #5a6268;
}

@media (max-width: 768px) {
  .dashboard-filters {
    padding: 10px;
  }
  
  .date-range-filter {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }
  
  .date-range-filter input[type="date"] {
    max-width: 100%;
    width: 100%;
  }
  
  .date-range-filter .btn {
    width: 100%;
  }
  
  .date-separator {
    display: none;
  }
} 