@import url("https://fonts.googleapis.com/css2?family=Blinker&family=Caladea&family=Poppins:ital@1&family=Tektur&display=swap");

.material-symbols-outlined {
  font-variation-settings: "FILL" 0, "wght" 400, "GRAD" 0, "opsz" 48;
}

:root {
  --font-one: "Blinker", sans-serif;
  --font-two: "Caladea", serif;
  --font-three: "Poppins", sans-serif;
  --font-four: "Tektur", cursive;
}
* {
  font-family: var(--font-one);
  box-sizing: border-box;
}
.font-one {
  font-family: var(--font-one);
}
.font-two {
  font-family: var(--font-two);
}
.font-three {
  font-family: var(--font-three);
}
.font-four {
  font-family: var(--font-four);
}

/* CSS for sidebar - Updated for modern design */
#sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 16rem; /* 256px - matches Tailwind w-64 */
  height: 100vh;
  z-index: 40;
  background-color: #ffffff;
  border-right: 1px solid #e5e7eb;
  box-shadow: 2px 0 4px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease-in-out;
  overflow-y: auto;
}

/* Dark mode support */
.dark #sidebar {
  background-color: #1f2937;
  border-right-color: #374151;
  box-shadow: 2px 0 4px rgba(0, 0, 0, 0.3);
}

/* Mobile: hidden by default */
@media (max-width: 767px) {
  #sidebar {
    left: -100%;
  }
}

/* Desktop: always visible */
@media (min-width: 768px) {
  #sidebar {
    left: 0;
  }
}

/* CSS for sidebar content */
#sidebar-content {
  padding: 5px;
}

/* Sidebar navigation styling */
#sidebar nav {
  display: flex;
  flex-direction: column;
  height: 100%;
  background-color: inherit;
}

/* Logo section */
#sidebar .logo-section {
  padding: 1.5rem 1rem;
  border-bottom: 1px solid #e5e7eb;
  background-color: #f8fafc;
}

.dark #sidebar .logo-section {
  background-color: #111827;
  border-bottom-color: #374151;
}

#sidebar .logo-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

#sidebar .logo-img {
  height: 2rem;
  width: auto;
}

#sidebar .logo-text {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
}

.dark #sidebar .logo-text {
  color: #f3f4f6;
}

/* Close button for mobile */
#sidebar .close-btn {
  display: none;
  padding: 0.5rem;
  border-radius: 0.5rem;
  background: none;
  border: none;
  color: #6b7280;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

#sidebar .close-btn:hover {
  background-color: #f3f4f6;
  color: #374151;
}

.dark #sidebar .close-btn:hover {
  background-color: #374151;
  color: #d1d5db;
}

@media (max-width: 767px) {
  #sidebar .close-btn {
    display: block;
  }
}

/* Navigation menu */
#sidebar .nav-menu {
  flex: 1;
  padding: 1rem 0;
  overflow-y: auto;
}

#sidebar .nav-section {
  padding: 0 0.75rem;
}

#sidebar .nav-section + .nav-section {
  margin-top: 0.5rem;
}

/* Navigation links */
#sidebar .nav-link {
  display: flex;
  align-items: center;
  padding: 0.75rem 1rem;
  margin: 0.125rem 0;
  border-radius: 0.5rem;
  text-decoration: none;
  color: #4b5563;
  font-weight: 500;
  transition: all 0.2s ease-in-out;
  cursor: pointer;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}

#sidebar .nav-link:hover {
  background-color: #f3f4f6;
  color: #111827;
}

#sidebar .nav-link-active {
  background-color: #dbeafe;
  color: #1d4ed8;
}

#sidebar .nav-link-active:hover {
  background-color: #bfdbfe;
}

.dark #sidebar .nav-link {
  color: #9ca3af;
}

.dark #sidebar .nav-link:hover {
  background-color: #374151;
  color: #d1d5db;
}

.dark #sidebar .nav-link-active {
  background-color: #1e3a8a;
  color: #60a5fa;
}

.dark #sidebar .nav-link-active:hover {
  background-color: #1e40af;
}

/* Navigation icons */
#sidebar .nav-icon {
  width: 1.25rem;
  height: 1.25rem;
  margin-right: 0.75rem;
  flex-shrink: 0;
}

#sidebar .nav-text {
  flex: 1;
  font-size: 0.875rem;
}

#sidebar .nav-arrow {
  width: 1rem;
  height: 1rem;
  transition: transform 0.2s ease-in-out;
}

#sidebar .nav-arrow.rotated {
  transform: rotate(180deg);
}

/* Submenu */
#sidebar .submenu {
  margin-left: 1rem;
  margin-top: 0.25rem;
}

#sidebar .submenu .nav-link {
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
}

#sidebar .submenu .nav-icon {
  width: 1rem;
  height: 1rem;
  margin-right: 0.5rem;
}

/* Bottom section */
#sidebar .bottom-section {
  padding: 1rem;
  border-top: 1px solid #e5e7eb;
  background-color: #f8fafc;
}

.dark #sidebar .bottom-section {
  background-color: #111827;
  border-top-color: #374151;
}

/* Theme toggle */
#sidebar .theme-section {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

#sidebar .theme-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.dark #sidebar .theme-label {
  color: #d1d5db;
}

#sidebar .theme-toggle {
  position: relative;
  display: inline-flex;
  height: 1.5rem;
  width: 2.75rem;
  align-items: center;
  border-radius: 9999px;
  background-color: #d1d5db;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

#sidebar .theme-toggle.checked,
#sidebar .theme-toggle-checked {
  background-color: #3b82f6;
}

#sidebar .theme-toggle-thumb {
  display: inline-block;
  height: 1.25rem;
  width: 1.25rem;
  border-radius: 50%;
  background-color: white;
  transition: transform 0.2s ease-in-out;
  transform: translateX(0.125rem);
}

#sidebar .theme-toggle-thumb.checked,
#sidebar .theme-toggle-thumb-checked {
  transform: translateX(1.375rem);
}

/* Sidebar collapse states */
#sidebar.sidebar-collapsed {
  width: 4rem;
}

#sidebar.sidebar-collapsed .nav-text,
#sidebar.sidebar-collapsed .logo-text,
#sidebar.sidebar-collapsed .collapse-text {
  display: none;
}

#sidebar.sidebar-collapsed .nav-link {
  justify-content: center;
  padding: 0.75rem;
}

#sidebar.sidebar-collapsed .nav-icon {
  margin-right: 0;
}

#sidebar.sidebar-expanded {
  width: 16rem;
}

/* Collapse button */
#sidebar .collapse-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.75rem;
  border-radius: 0.5rem;
  background: none;
  border: none;
  color: #6b7280;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

#sidebar .collapse-btn:hover {
  background-color: #f3f4f6;
  color: #374151;
}

.dark #sidebar .collapse-btn:hover {
  background-color: #374151;
  color: #d1d5db;
}

#sidebar .collapse-icon {
  width: 1rem;
  height: 1rem;
  margin-right: 0.5rem;
}

@media (max-width: 767px) {
  #sidebar .collapse-btn {
    display: none;
  }
}

/* CSS for main content - Updated for modern design */
#main-content {
  transition: margin-left 0.3s ease-in-out;
  min-height: 100vh;
  margin-left: 0;
  background-color: #f8fafc;
}

/* Main content margin adjustments for sidebar collapse */
#main-content.md\:ml-16 {
  margin-left: 4rem;
}

#main-content.md\:ml-64 {
  margin-left: 16rem;
}

/* Desktop: add margin for sidebar */
@media (min-width: 768px) {
  #main-content {
    margin-left: 16rem; /* 256px - matches sidebar width */
  }
}

/* Main header styling */
.main-header {
  background-color: white;
  border-bottom: 1px solid #e5e7eb;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 0;
}

.page-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

/* Dark mode support */
.dark #main-content {
  background-color: #111827;
}

.dark .main-header {
  background-color: #1f2937;
  border-bottom-color: #374151;
}

.dark .page-title {
  color: #f3f4f6;
}

/* Dashboard Main Content Styles */
.main-content {
  padding: 1.5rem;
}

.content-container {
  max-width: 1200px;
  margin: 0 auto;
}

/* Quick Actions */
.quick-actions {
  margin-bottom: 2rem;
}

.sale-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  font-weight: 600;
  border-radius: 0.5rem;
  text-decoration: none;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.2s ease-in-out;
}

.sale-button:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
  transform: translateY(-1px);
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.stat-card {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  transition: box-shadow 0.2s ease-in-out;
}

.stat-card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.stat-content {
  padding: 1.5rem;
}

.stat-info {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.stat-details {
  flex: 1;
}

.stat-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #6b7280;
  margin: 0 0 0.25rem 0;
}

.stat-number {
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  margin: 0;
}

.stat-number-warning {
  color: #d97706;
}

.stat-number-error {
  color: #dc2626;
}

.stat-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stat-icon-primary {
  background-color: #dbeafe;
  color: #1d4ed8;
}

.stat-icon-warning {
  background-color: #fef3c7;
  color: #d97706;
}

.stat-icon-error {
  background-color: #fee2e2;
  color: #dc2626;
}

.stat-action {
  margin-top: 1rem;
}

.stat-button {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.5rem 1rem;
  background-color: #3b82f6;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.375rem;
  text-decoration: none;
  transition: background-color 0.2s ease-in-out;
}

.stat-button:hover {
  background-color: #2563eb;
}

/* Content Grid */
.content-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 1.5rem;
}

.data-card {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.card-header {
  padding: 1.5rem 1.5rem 0 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.card-header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 1rem;
}

.card-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.card-action {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.5rem 1rem;
  border: 1px solid #d1d5db;
  color: #374151;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.375rem;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
}

.card-action:hover {
  background-color: #f9fafb;
  border-color: #9ca3af;
}

.card-body {
  display: flex !important;
  flex-direction: column;
  gap: 1rem;
  padding: 1.5rem;
}

/* Table Styles */
.table-container {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table th {
  padding: 0.75rem 1rem;
  text-align: left;
  font-size: 0.75rem;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid #e5e7eb;
  background-color: #f9fafb;
}

.data-table td {
  padding: 0.75rem 1rem;
  font-size: 0.875rem;
  color: #111827;
  border-bottom: 1px solid #f3f4f6;
}

.data-table tr:hover {
  background-color: #f9fafb;
}

.data-table .font-medium {
  font-weight: 500;
}

.table-button {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  background-color: #3b82f6;
  color: white;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 0.25rem;
  text-decoration: none;
  transition: background-color 0.2s ease-in-out;
}

.table-button:hover {
  background-color: #2563eb;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: #6b7280;
}

.empty-state svg {
  margin: 0 auto 1rem auto;
  color: #9ca3af;
}

.empty-title {
  font-size: 0.875rem;
  font-weight: 500;
  color: #111827;
  margin: 0 0 0.25rem 0;
}

.empty-description {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0;
}

/* Hidden Mobile */
.hidden-mobile {
  display: table-cell;
}

@media (max-width: 768px) {
  .hidden-mobile {
    display: none;
  }
  
  .content-grid {
    grid-template-columns: 1fr;
  }
  
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

/* Dark Mode Support */
.dark .stat-card,
.dark .data-card {
  background-color: #1f2937;
  border-color: #374151;
}

.dark .stat-label {
  color: #9ca3af;
}

.dark .stat-number {
  color: #f3f4f6;
}

.dark .card-title {
  color: #f3f4f6;
}

.dark .card-header {
  border-bottom-color: #374151;
}

.dark .card-action {
  border-color: #4b5563;
  color: #d1d5db;
}

.dark .card-action:hover {
  background-color: #374151;
  border-color: #6b7280;
}

.dark .data-table th {
  background-color: #374151;
  color: #d1d5db;
  border-bottom-color: #4b5563;
}

.dark .data-table td {
  color: #f3f4f6;
  border-bottom-color: #374151;
}

.dark .data-table tr:hover {
  background-color: #374151;
}

.dark .empty-title {
  color: #f3f4f6;
}

.dark .empty-description {
  color: #9ca3af;
}

/* Sales Page Specific Styles */
.sales-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 2rem;
  align-items: start;
}

.controls-panel {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Filter Cards */
.filter-card {
  background: white;
  border-radius: 0.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.filter-options {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
}

.filter-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  background: white;
  color: #374151;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.filter-option:hover {
  background-color: #f9fafb;
  border-color: #d1d5db;
}

.filter-option.filter-custom {
  border-color: #3b82f6;
  color: #3b82f6;
}

.filter-option.filter-custom:hover {
  background-color: #eff6ff;
}

.filter-option.active {
  background-color: #3b82f6;
  border-color: #3b82f6;
  color: white;
}

.filter-indicator {
  display: flex;
  align-items: center;
  color: #3b82f6;
}

.filter-option.active .filter-indicator {
  color: white;
}

/* Custom Date Range */
.custom-date-range {
  padding: 1rem;
  border-top: 1px solid #e5e7eb;
  background-color: #f9fafb;
}

.date-inputs {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 1rem;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.input-group label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.date-input {
  padding: 0.5rem 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  transition: border-color 0.2s ease-in-out;
}

.date-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.date-actions {
  display: flex;
  gap: 0.75rem;
}

.btn-secondary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: #6b7280;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.375rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

.btn-secondary:hover {
  background-color: #4b5563;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: #3b82f6;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.375rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

.btn-primary:hover {
  background-color: #2563eb;
}

/* Year Options */
.year-options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 1rem;
}

.year-option {
  padding: 0.5rem 1rem;
  border: 1px solid #e5e7eb;
  border-radius: 0.375rem;
  background: white;
  color: #374151;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.year-option:hover {
  background-color: #f9fafb;
  border-color: #d1d5db;
}

.year-option.active {
  background-color: #3b82f6;
  border-color: #3b82f6;
  color: white;
}

/* Compare Section */
.compare-section {
  margin-top: 1rem;
}

.compare-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.75rem 1rem;
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  font-weight: 600;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.compare-button:hover {
  background: linear-gradient(135deg, #059669, #047857);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

/* Stats Dashboard */
.stats-dashboard {
  margin-bottom: 2rem;
}

/* Bottom Section */
.bottom-section {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 2rem;
  margin-top: 2rem;
}

/* Profit Card */
.profit-card {
  background: linear-gradient(135deg, #10b981, #059669);
  border-radius: 1rem;
  box-shadow: 0 8px 25px rgba(16, 185, 129, 0.3);
  transition: all 0.3s ease-in-out;
  overflow: hidden;
  position: relative;
}

.profit-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 35px rgba(16, 185, 129, 0.4);
}

.profit-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.05));
  pointer-events: none;
}

.profit-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 1.5rem 0 1.5rem;
  position: relative;
  z-index: 1;
}

.profit-title {
  color: white;
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0;
}

.profit-icon {
  width: 3rem;
  height: 3rem;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
}

.profit-content {
  padding: 1rem 1.5rem 1.5rem 1.5rem;
  position: relative;
  z-index: 1;
}

.profit-amount {
  font-size: 2.5rem;
  font-weight: 700;
  color: white;
  margin: 0.5rem 0;
  line-height: 1;
}

.profit-description {
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.875rem;
  margin-bottom: 1rem;
}

.profit-trend {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: rgba(255, 255, 255, 0.9);
  font-size: 0.875rem;
  font-weight: 500;
}

/* Summary Card */
.summary-card {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: all 0.3s ease-in-out;
}

.summary-card:hover {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.summary-header {
  padding: 1.5rem 1.5rem 1rem 1.5rem;
  border-bottom: 1px solid #f3f4f6;
}

.summary-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 0.25rem 0;
}

.summary-subtitle {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0;
}

.summary-content {
  padding: 1.5rem;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.5rem;
}

.summary-metric {
  background: #f8fafc;
  border-radius: 0.75rem;
  padding: 1.25rem;
  position: relative;
  transition: all 0.2s ease-in-out;
  border: 1px solid #e2e8f0;
}

.summary-metric:hover {
  background: #f1f5f9;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.summary-metric.highlight-metric {
  background: linear-gradient(135deg, #eff6ff, #dbeafe);
  border-color: #3b82f6;
}

.summary-metric.highlight-metric:hover {
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
}

.metric-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

.metric-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 0.75rem;
  line-height: 1.2;
}

.profit-value {
  color: #059669;
}

.cash-value {
  color: #1d4ed8;
}

.metric-icon {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sales-icon {
  background-color: #dbeafe;
  color: #1d4ed8;
}

.cogs-icon {
  background-color: #fef3c7;
  color: #d97706;
}

.expenses-icon {
  background-color: #fee2e2;
  color: #dc2626;
}

.profit-icon {
  background-color: #d1fae5;
  color: #059669;
}

.outstanding-icon {
  background-color: #f3e8ff;
  color: #7c3aed;
}

.cash-icon {
  background-color: #dbeafe;
  color: #1d4ed8;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .sales-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .controls-panel {
    order: 2;
  }
  
  .stats-dashboard {
    order: 1;
  }
  
  .bottom-section {
    order: 3;
  }
}

@media (max-width: 768px) {
  .bottom-section {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .summary-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .year-options {
    justify-content: center;
  }
  
  .date-actions {
    flex-direction: column;
  }
  
  .profit-amount {
    font-size: 2rem;
  }
  
  .metric-value {
    font-size: 1.125rem;
  }
}

/* Dark Mode Support */
.dark .filter-card,
.dark .profit-card,
.dark .summary-card {
  background-color: #1f2937;
  border-color: #374151;
}

.dark .filter-option {
  background-color: #1f2937;
  border-color: #374151;
  color: #d1d5db;
}

.dark .filter-option:hover {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .filter-option.filter-custom {
  border-color: #3b82f6;
  color: #60a5fa;
}

.dark .filter-option.filter-custom:hover {
  background-color: #1e3a8a;
}

.dark .custom-date-range {
  background-color: #111827;
  border-top-color: #374151;
}

.dark .input-group label {
  color: #d1d5db;
}

.dark .date-input {
  background-color: #1f2937;
  border-color: #374151;
  color: #f3f4f6;
}

.dark .date-input:focus {
  border-color: #3b82f6;
}

.dark .year-option {
  background-color: #1f2937;
  border-color: #374151;
  color: #d1d5db;
}

.dark .year-option:hover {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .summary-item {
  border-bottom-color: #374151;
}

.dark .summary-item.summary-divider {
  border-bottom-color: #4b5563;
}

.dark .summary-item.summary-highlight {
  background-color: #1e3a8a;
}

.dark .summary-label {
  color: #9ca3af;
}

.dark .summary-value {
  color: #f3f4f6;
}

.dark .summary-item.summary-highlight .summary-label,
.dark .summary-item.summary-highlight .summary-value {
  color: #60a5fa;
}

/* Dark Mode for New Bottom Section */
.dark .summary-card {
  background-color: #1f2937;
  border-color: #374151;
}

.dark .summary-title {
  color: #f3f4f6;
}

.dark .summary-subtitle {
  color: #9ca3af;
}

.dark .summary-metric {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .summary-metric:hover {
  background-color: #4b5563;
}

.dark .summary-metric.highlight-metric {
  background: linear-gradient(135deg, #1e3a8a, #1e40af);
  border-color: #3b82f6;
}

.dark .summary-metric.highlight-metric:hover {
  background: linear-gradient(135deg, #1e40af, #2563eb);
}

.dark .metric-label {
  color: #9ca3af;
}

.dark .metric-value {
  color: #f3f4f6;
}

.dark .profit-value {
  color: #34d399;
}

.dark .cash-value {
  color: #60a5fa;
}

/* Charts Section Styles */
/* .charts-section {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
} */

.chart-card {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: all 0.3s ease-in-out;
}

.chart-card:hover {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
  transform: translateY(-2px);
}

.chart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.5rem 1.5rem 1rem 1.5rem;
  border-bottom: 1px solid #f3f4f6;
}

.chart-title-section {
  flex: 1;
}

.chart-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 0.25rem 0;
}

.chart-subtitle {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0;
}

.chart-action {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: #3b82f6;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
}

.chart-action:hover {
  background-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.chart-stats {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.stat-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background-color: #d1fae5;
  color: #059669;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 0.375rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.chart-content {
  padding: 1.5rem;
}

.chart-container {
  position: relative;
  height: 300px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.chart-container canvas {
  max-width: 100%;
  max-height: 100%;
}

/* Responsive Design for Charts */
@media (max-width: 1024px) {
  .charts-section {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .chart-container {
    height: 250px;
  }
}

@media (max-width: 768px) {
  .chart-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .chart-stats {
    align-self: stretch;
    justify-content: flex-start;
  }
  
  .chart-container {
    height: 200px;
  }
  
  .chart-title {
    font-size: 1.125rem;
  }
}

/* Dark Mode Support for Charts */
.dark .chart-card {
  background-color: #1f2937;
  border-color: #374151;
}

.dark .chart-header {
  border-bottom-color: #374151;
}

.dark .chart-title {
  color: #f3f4f6;
}

.dark .chart-subtitle {
  color: #9ca3af;
}

.dark .stat-badge {
  background-color: #064e3b;
  color: #34d399;
}

/* Invoices, Expenses, and Outstanding Pages Styles */
.invoices-layout,
.expenses-layout,
.outstanding-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
}

.invoices-panel,
.expenses-panel,
.outstanding-panel {
  grid-column: 1;
}

.details-panel {
  grid-column: 2;
}

/* Expenses Summary */
.expenses-summary {
  margin-bottom: 2rem;
}

.summary-card {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease-in-out;
}

.summary-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.summary-content {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.summary-icon {
  width: 4rem;
  height: 4rem;
  background: rgba(217, 119, 6, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #d97706;
}

.summary-details {
  flex: 1;
}

.summary-title {
  font-size: 1rem;
  font-weight: 600;
  color: #92400e;
  margin: 0 0 0.25rem 0;
}

.summary-amount {
  font-size: 1.5rem;
  font-weight: 700;
  color: #92400e;
  margin: 0;
}

/* Card Headers */
.card-header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.filter-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filter-select {
  padding: 0.5rem 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  background: white;
  font-size: 0.875rem;
  color: #374151;
  transition: all 0.2s ease-in-out;
}

.filter-select:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Action Buttons */
.add-expense-btn,
.add-payment-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: #10b981;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.add-expense-btn:hover,
.add-payment-btn:hover {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.send-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: #3b82f6;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.send-btn:hover {
  background-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* Action Buttons in Tables */
.action-buttons {
  display: flex;
  gap: 0.5rem;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.5rem;
  font-size: 0.75rem;
  font-weight: 500;
  border-radius: 0.375rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.info-btn {
  background-color: #dbeafe;
  color: #1d4ed8;
}

.info-btn:hover {
  background-color: #bfdbfe;
  transform: translateY(-1px);
}

.edit-btn {
  background-color: #fef3c7;
  color: #d97706;
}

.edit-btn:hover {
  background-color: #fde68a;
  transform: translateY(-1px);
}

.delete-btn {
  background-color: #fee2e2;
  color: #dc2626;
}

.delete-btn:hover {
  background-color: #fecaca;
  transform: translateY(-1px);
}

/* Outstanding Badge */
.outstanding-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background-color: #fef3c7;
  color: #d97706;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 0.375rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* Customer Info */
.customer-info {
  margin-left: 1rem;
}

.customer-name {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 0.25rem 0;
}

.customer-phone {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0;
}

/* Back Button */
.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: #f3f4f6;
  color: #374151;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.back-btn:hover {
  background-color: #e5e7eb;
  transform: translateY(-1px);
}

/* Print Button */
.print-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background-color: #6b7280;
  color: white;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.print-btn:hover {
  background-color: #4b5563;
  transform: translateY(-1px);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .invoices-layout,
  .expenses-layout,
  .outstanding-layout {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .details-panel {
    grid-column: 1;
  }
  
  .expenses-summary {
    margin-bottom: 1.5rem;
  }
}

@media (max-width: 768px) {
  .card-header-content {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .header-actions {
    align-self: stretch;
    justify-content: space-between;
  }
  
  .action-buttons {
    flex-direction: column;
    gap: 0.25rem;
  }
  
  .action-btn {
    justify-content: center;
  }
  
  .summary-content {
    flex-direction: column;
    text-align: center;
  }
  
  .summary-icon {
    width: 3rem;
    height: 3rem;
  }
}

/* Dark Mode Support */
.dark .summary-card {
  background: linear-gradient(135deg, #451a03, #78350f);
}

.dark .summary-title,
.dark .summary-amount {
  color: #fbbf24;
}

.dark .summary-icon {
  background: rgba(251, 191, 36, 0.1);
  color: #fbbf24;
}

.dark .filter-select {
  background-color: #374151;
  border-color: #4b5563;
  color: #f3f4f6;
}

.dark .filter-select:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

.dark .outstanding-badge {
  background-color: #451a03;
  color: #fbbf24;
}

.dark .customer-name {
  color: #f3f4f6;
}

.dark .customer-phone {
  color: #9ca3af;
}

.dark .back-btn {
  background-color: #374151;
  color: #f3f4f6;
}

.dark .back-btn:hover {
  background-color: #4b5563;
}

.dark .print-btn {
  background-color: #4b5563;
}

.dark .print-btn:hover {
  background-color: #6b7280;
}

/* Sale Page Layout */
.sale-layout {
  margin-top: 2rem;
  min-height: calc(100vh - 200px);
}

/* Sale Page Specific Styles */
.sale-container {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transition: all 0.3s ease-in-out;
}

.sale-container:hover {
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.sale-header {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  padding: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.sale-title {
  font-size: 1.5rem;
  font-weight: 600;
  margin: 0 0 0.5rem 0;
}

.sale-subtitle {
  font-size: 0.875rem;
  opacity: 0.9;
  margin: 0;
}

.sale-content {
  padding: 2rem;
}

/* Sale Form Styles */
.sale-form {
  display: grid;
  gap: 1.5rem;
}

.form-section {
  background: #f8fafc;
  border-radius: 0.75rem;
  padding: 1.5rem;
  border: 1px solid #e2e8f0;
}

.section-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 1rem 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-title svg {
  width: 20px;
  height: 20px;
  color: #3b82f6;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.form-input,
.form-select {
  padding: 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  color: #111827;
  background: white;
  transition: all 0.2s ease-in-out;
}

.form-input:focus,
.form-select:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-input:disabled {
  background-color: #f9fafb;
  color: #6b7280;
  cursor: not-allowed;
}

/* Sale Actions */
.sale-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
}

.sale-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.sale-btn-primary {
  background-color: #10b981;
  color: white;
}

.sale-btn-primary:hover {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.sale-btn-secondary {
  background-color: #6b7280;
  color: white;
}

.sale-btn-secondary:hover {
  background-color: #4b5563;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(107, 114, 128, 0.3);
}

.sale-btn-outline {
  background-color: transparent;
  color: #374151;
  border: 1px solid #d1d5db;
}

.sale-btn-outline:hover {
  background-color: #f9fafb;
  border-color: #9ca3af;
}

/* Sale Summary */
.sale-summary {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border-radius: 0.75rem;
  padding: 1.5rem;
  border: 1px solid #bae6fd;
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.summary-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.summary-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #0369a1;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.summary-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0c4a6e;
}

.summary-value.large {
  font-size: 1.5rem;
}

/* Responsive Design for Sale Page */
@media (max-width: 1024px) {
  .sale-content {
    padding: 1.5rem;
  }
  
  .form-grid {
    grid-template-columns: 1fr;
  }
  
  .sale-actions {
    flex-direction: column;
  }
  
  .sale-btn {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .sale-header {
    padding: 1rem;
  }
  
  .sale-title {
    font-size: 1.25rem;
  }
  
  .sale-content {
    padding: 1rem;
  }
  
  .form-section {
    padding: 1rem;
  }
  
  .summary-grid {
    grid-template-columns: 1fr;
  }
}

/* Dark Mode Support for Sale Page */
.dark .sale-container {
  background-color: #1f2937;
  border-color: #374151;
}

.dark .sale-header {
  background: linear-gradient(135deg, #1e40af, #1e3a8a);
}

.dark .form-section {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .section-title {
  color: #f3f4f6;
}

.dark .form-label {
  color: #d1d5db;
}

.dark .form-input,
.dark .form-select {
  background-color: #374151;
  border-color: #4b5563;
  color: #f3f4f6;
}

.dark .form-input:focus,
.dark .form-select:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

.dark .form-input:disabled {
  background-color: #4b5563;
  color: #9ca3af;
}

.dark .sale-actions {
  border-top-color: #4b5563;
}

.dark .sale-btn-outline {
  color: #d1d5db;
  border-color: #4b5563;
}

.dark .sale-btn-outline:hover {
  background-color: #4b5563;
  border-color: #6b7280;
}

.dark .sale-summary {
  background: linear-gradient(135deg, #0c4a6e, #075985);
  border-color: #0369a1;
}

.dark .summary-label {
  color: #7dd3fc;
}

.dark .summary-value {
  color: #e0f2fe;
}

/* SelectItem Model Specific Styles */
.sale-layout-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-top: 2rem;
}

.product-selection-panel,
.invoice-panel {
  display: flex;
  flex-direction: column;
}

/* Filter Controls */
.filter-controls {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.price-filter {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.filter-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
  white-space: nowrap;
}

.filter-input {
  padding: 0.5rem 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  color: #111827;
  background: white;
  width: 120px;
  transition: all 0.2s ease-in-out;
}

.filter-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.search-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  background-color: #3b82f6;
  color: white;
  border: none;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.search-btn:hover {
  background-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* Product Table Styling */
.data-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  border: 1px solid #e5e7eb;
}

.data-table thead {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 2px solid #e2e8f0;
}

.data-table th {
  padding: 1rem 0.75rem;
  text-align: left;
  font-weight: 600;
  font-size: 0.875rem;
  color: #374151;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-bottom: 1px solid #e5e7eb;
}

.data-table td {
  padding: 1rem 0.75rem;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: middle;
}

.data-table tbody tr {
  transition: all 0.2s ease-in-out;
}

.data-table tbody tr:hover {
  background-color: #f8fafc;
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

/* Product Table Specific Styles */
.price-cell {
  font-weight: 700;
  color: #059669;
  font-size: 1rem;
}

.font-medium {
  font-weight: 600;
  color: #111827;
}

/* Action Buttons in Table */
.action-buttons {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 0.375rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
  white-space: nowrap;
}

.select-btn {
  background-color: #10b981;
  color: white;
  box-shadow: 0 1px 2px rgba(16, 185, 129, 0.2);
}

.select-btn:hover {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.info-btn {
  background-color: #dbeafe;
  color: #1d4ed8;
  box-shadow: 0 1px 2px rgba(59, 130, 246, 0.2);
}

.info-btn:hover {
  background-color: #bfdbfe;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* Invoice Panel */
.invoice-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  border-radius: 0.375rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.status-badge:not(.success) {
  background-color: #fef3c7;
  color: #d97706;
}

.status-badge.success {
  background-color: #d1fae5;
  color: #059669;
}

/* Selected Items Container */
.selected-items-container {
  min-height: 200px;
  max-height: 400px;
  overflow-y: auto;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 1rem;
  background-color: #f9fafb;
}

/* Invoice Summary */
.invoice-summary {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
}

.summary-section {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border-radius: 0.75rem;
  padding: 1.5rem;
  border: 1px solid #bae6fd;
  margin-bottom: 1.5rem;
}

.summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.summary-row:last-child {
  margin-bottom: 0;
}

.summary-row.total-row {
  padding-top: 1rem;
  border-top: 1px solid #bae6fd;
  margin-top: 1rem;
  margin-bottom: 0;
}

.summary-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #0369a1;
}

.summary-value {
  font-size: 1.125rem;
  font-weight: 700;
  color: #0c4a6e;
}

.summary-value.total-amount {
  font-size: 1.5rem;
  color: #059669;
}

.discount-input {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.discount-input .form-input {
  width: 120px;
  text-align: right;
}

/* Invoice Actions */
.invoice-actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
}

/* Payment Form */
.payment-form {
  margin-top: 2rem;
}

.payment-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.payment-status .status-badge.success {
  background-color: #d1fae5;
  color: #059669;
}

/* Responsive Design for SelectItem Model */
@media (max-width: 1024px) {
  .sale-layout-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .payment-form-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .filter-controls {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .price-filter {
    align-self: stretch;
  }
  
  .filter-input {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .invoice-actions {
    flex-direction: column;
  }
  
  .sale-actions {
    flex-direction: column;
  }
  
  .summary-row {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .discount-input {
    align-self: stretch;
  }
  
  .discount-input .form-input {
    width: 100%;
  }
}

/* Dark Mode Support for SelectItem Model */
.dark .filter-label {
  color: #d1d5db;
}

.dark .filter-input {
  background-color: #374151;
  border-color: #4b5563;
  color: #f3f4f6;
}

.dark .filter-input:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

.dark .selected-items-container {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .invoice-summary {
  border-top-color: #4b5563;
}

.dark .summary-section {
  background: linear-gradient(135deg, #0c4a6e, #075985);
  border-color: #0369a1;
}

.dark .summary-label {
  color: #7dd3fc;
}

.dark .summary-value {
  color: #e0f2fe;
}

.dark .summary-value.total-amount {
  color: #34d399;
}

.dark .summary-row.total-row {
  border-top-color: #0369a1;
}

/* Dark Mode Support for Data Tables */
.dark .data-table {
  background-color: #1f2937;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
  border-color: #374151;
}

.dark .data-table thead {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-bottom-color: #4b5563;
}

.dark .data-table th {
  color: #f3f4f6;
  border-bottom-color: #4b5563;
}

.dark .data-table td {
  border-bottom-color: #374151;
  color: #f3f4f6;
}

.dark .data-table tbody tr:hover {
  background-color: #374151;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.dark .font-medium {
  color: #f3f4f6;
}

.dark .price-cell {
  color: #34d399;
}

.dark .select-btn {
  background-color: #10b981;
  color: white;
  box-shadow: 0 1px 2px rgba(16, 185, 129, 0.3);
}

.dark .select-btn:hover {
  background-color: #059669;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.dark .info-btn {
  background-color: #1e3a8a;
  color: #93c5fd;
  box-shadow: 0 1px 2px rgba(30, 58, 138, 0.3);
}

.dark .info-btn:hover {
  background-color: #1e40af;
  box-shadow: 0 4px 12px rgba(30, 64, 175, 0.4);
}

/* DataTables Library Override Styles */
/* Override DataTables default styling to work with our dark mode */
.dataTables_wrapper {
  color: inherit;
}

.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_processing,
.dataTables_wrapper .dataTables_paginate {
  color: inherit;
}

.dataTables_wrapper .dataTables_length select,
.dataTables_wrapper .dataTables_filter input {
  background-color: inherit;
  color: inherit;
  border: 1px solid #d1d5db;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
  background-color: inherit;
  color: inherit;
  border: 1px solid #d1d5db;
}

.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
  background-color: #f3f4f6;
  color: #111827;
  border-color: #9ca3af;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current {
  background-color: #3b82f6;
  color: white;
  border-color: #3b82f6;
}

/* Dark Mode Overrides for DataTables */
.dark .dataTables_wrapper .dataTables_length select,
.dark .dataTables_wrapper .dataTables_filter input {
  background-color: #374151;
  color: #f3f4f6;
  border-color: #4b5563;
}

.dark .dataTables_wrapper .dataTables_length select:focus,
.dark .dataTables_wrapper .dataTables_filter input:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

.dark .dataTables_wrapper .dataTables_paginate .paginate_button {
  background-color: #374151;
  color: #f3f4f6;
  border-color: #4b5563;
}

.dark .dataTables_wrapper .dataTables_paginate .paginate_button:hover {
  background-color: #4b5563;
  color: #f3f4f6;
  border-color: #6b7280;
}

.dark .dataTables_wrapper .dataTables_paginate .paginate_button.current {
  background-color: #3b82f6;
  color: white;
  border-color: #3b82f6;
}

.dark .dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  background-color: #2563eb;
  border-color: #2563eb;
}

/* Force DataTables table to use our dark mode styles */
.dark .dataTables_wrapper table.dataTable {
  background-color: #1f2937 !important;
  color: #f3f4f6 !important;
}

.dark .dataTables_wrapper table.dataTable thead th {
  background-color: #374151 !important;
  color: #f3f4f6 !important;
  border-color: #4b5563 !important;
}

.dark .dataTables_wrapper table.dataTable tbody td {
  background-color: #1f2937 !important;
  color: #f3f4f6 !important;
  border-color: #374151 !important;
}

.dark .dataTables_wrapper table.dataTable tbody tr:hover td {
  background-color: #374151 !important;
  color: #f3f4f6 !important;
}

.dark .dataTables_wrapper table.dataTable tbody tr.odd td {
  background-color: #1f2937 !important;
  color: #f3f4f6 !important;
}

.dark .dataTables_wrapper table.dataTable tbody tr.even td {
  background-color: #1f2937 !important;
  color: #f3f4f6 !important;
}

.dark .dataTables_wrapper table.dataTable tbody tr.odd:hover td,
.dark .dataTables_wrapper table.dataTable tbody tr.even:hover td {
  background-color: #374151 !important;
  color: #f3f4f6 !important;
}

/* Override DataTables processing overlay */
.dark .dataTables_processing {
  background-color: #1f2937 !important;
  color: #f3f4f6 !important;
  border: 1px solid #374151 !important;
}

/* Override DataTables info text */
.dark .dataTables_info {
  color: #9ca3af !important;
}

/* Complete Sale Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  backdrop-filter: blur(4px);
}

.modal-container {
  background: white;
  border-radius: 1rem;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  max-width: 500px;
  width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
  from {
    opacity: 0;
    transform: translateY(-20px) scale(0.95);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-header {
  padding: 2rem 2rem 1rem 2rem;
  text-align: center;
  border-bottom: 1px solid #e5e7eb;
}

.modal-icon {
  width: 4rem;
  height: 4rem;
  background: linear-gradient(135deg, #10b981, #059669);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem auto;
  color: white;
}

.modal-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 0.5rem 0;
}

.modal-subtitle {
  font-size: 1rem;
  color: #6b7280;
  margin: 0;
}

.modal-body {
  padding: 1.5rem 2rem;
}

.confirmation-details {
  background: #f8fafc;
  border-radius: 0.75rem;
  padding: 1.5rem;
  border: 1px solid #e2e8f0;
}

.detail-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.detail-item:last-child {
  margin-bottom: 0;
}

.detail-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.detail-value {
  font-size: 0.875rem;
  font-weight: 600;
  color: #111827;
}

.status-ready {
  color: #059669;
  background-color: #d1fae5;
  padding: 0.25rem 0.75rem;
  border-radius: 0.375rem;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.modal-actions {
  padding: 1rem 2rem 2rem 2rem;
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
}

.modal-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: 0.5rem;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
  min-width: 120px;
  justify-content: center;
}

/* Removed duplicate modal-btn-secondary definition */

.modal-btn-primary {
  background-color: #3b82f6;
  color: white;
}

.modal-btn-primary:hover {
  background-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.modal-btn-success {
  background-color: #10b981;
  color: white;
}

.modal-btn-success:hover {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

/* Loader Styles for Modal Buttons */
.modal-btn .loader-container {
  display: none;
  align-items: center;
  justify-content: center;
}

.modal-btn.loading .loader-container {
  display: flex;
}

.modal-btn.loading .loader {
  width: 16px;
  height: 16px;
  border: 2px solid transparent;
  border-top: 2px solid currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Responsive Design for Modal */
@media (max-width: 640px) {
  .modal-container {
    width: 95%;
    margin: 1rem;
  }
  
  .modal-header {
    padding: 1.5rem 1.5rem 1rem 1.5rem;
  }
  
  .modal-body {
    padding: 1rem 1.5rem;
  }
  
  .modal-actions {
    padding: 1rem 1.5rem 1.5rem 1.5rem;
    flex-direction: column;
  }
  
  .modal-btn {
    width: 100%;
  }
}

/* Dark Mode Support for Modal */
.dark .modal-container {
  background-color: #1f2937;
  border-color: #374151;
}

.dark .modal-header {
  border-bottom-color: #374151;
}

.dark .modal-title {
  color: #f3f4f6;
}

.dark .modal-subtitle {
  color: #9ca3af;
}

.dark .confirmation-details {
  background-color: #374151;
  border-color: #4b5563;
}


.dark .detail-value {
  color: #f3f4f6;
}

.dark .status-ready {
  background-color: #064e3b;
  color: #34d399;
}

/* Removed duplicate dark mode modal-btn-secondary definition */

/* Categories Page Styles */
.categories-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.categories-panel {
  flex: 1;
}

.add-category-btn {
  background-color: #10b981;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.add-category-btn:hover {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.add-item-btn {
  background-color: #3b82f6;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.add-item-btn:hover {
  background-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.category-name {
  font-weight: 600;
  color: #111827;
}

.category-description {
  color: #6b7280;
  font-size: 0.875rem;
}

.item-count {
  font-weight: 600;
  color: #3b82f6;
  background-color: #eff6ff;
  padding: 0.25rem 0.75rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
}

/* Products Page Styles */
.products-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.products-stats {
  margin-bottom: 1rem;
}

.products-panel {
  flex: 1;
}

.stat-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  margin-bottom: 1rem;
}

.stat-icon.warning {
  background: linear-gradient(135deg, #f59e0b, #d97706);
}

.stat-icon.danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
}

.stat-icon.success {
  background: linear-gradient(135deg, #10b981, #059669);
}

.stat-content {
  flex: 1;
}

.stat-title {
  font-size: 0.875rem;
  font-weight: 500;
  color: #6b7280;
  margin: 0 0 0.5rem 0;
}

.stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: #111827;
  margin: 0 0 0.5rem 0;
}

.stat-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #3b82f6;
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: color 0.2s ease-in-out;
}

.stat-link:hover {
  color: #1d4ed8;
}

.stock-password-section {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.view-stock-btn {
  background-color: #3b82f6;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.view-stock-btn:hover {
  background-color: #2563eb;
}

.cost-cell {
  color: #dc2626;
  font-weight: 600;
}

.price-cell {
  color: #059669;
  font-weight: 600;
}

.quantity-cell {
  color: #3b82f6;
  font-weight: 600;
}

.add-btn {
  background-color: #10b981;
  color: white;
}

.add-btn:hover {
  background-color: #059669;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.reorder-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}

.reorder-section {
  flex: 1;
}

.reorder-point {
  color: #6b7280;
  font-weight: 500;
}

.items-left {
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
}

.items-left.warning {
  background-color: #fef3c7;
  color: #d97706;
}

.items-left.danger {
  background-color: #fee2e2;
  color: #dc2626;
}

/* Store Page Styles */
.store-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.store-summary {
  margin-bottom: 1rem;
}

.store-panel {
  flex: 1;
}

.summary-card {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  padding: 2rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
  box-shadow: 0 10px 25px -5px rgba(59, 130, 246, 0.3);
}

.summary-icon {
  width: 4rem;
  height: 4rem;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
}

.summary-content {
  flex: 1;
}

.summary-title {
  font-size: 1rem;
  font-weight: 500;
  margin: 0 0 0.5rem 0;
  opacity: 0.9;
}

.summary-value {
  font-size: 2.5rem;
  font-weight: 700;
  margin: 0 0 0.5rem 0;
}

.summary-subtitle {
  font-size: 0.875rem;
  margin: 0;
  opacity: 0.8;
}

.item-name {
  font-weight: 600;
  color: #111827;
}

.amount-cell {
  color: #059669;
  font-weight: 600;
}

.date-cell {
  color: #6b7280;
  font-size: 0.875rem;
}

/* Modal Form Styles */
.modal-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.form-input {
  padding: 0.75rem 1rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  transition: all 0.2s ease-in-out;
  background-color: white;
}

.form-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-textarea {
  padding: 0.75rem 1rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  transition: all 0.2s ease-in-out;
  background-color: white;
  resize: vertical;
  min-height: 100px;
}

.form-textarea:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.modal-large {
  max-width: 600px;
}

.warning-message {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  background-color: #fef3c7;
  border: 1px solid #f59e0b;
  border-radius: 0.5rem;
  color: #92400e;
  font-size: 0.875rem;
}

.modal-btn-danger {
  background-color: #ef4444;
  color: white;
}

.modal-btn-danger:hover {
  background-color: #dc2626;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .reorder-layout {
    grid-template-columns: 1fr;
  }
  
  .form-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
  
  .summary-card {
    flex-direction: column;
    text-align: center;
  }
  
  .stock-password-section {
    flex-direction: column;
    align-items: stretch;
  }
  
  .modal-actions {
    flex-direction: column;
  }
  
  .modal-btn {
    width: 100%;
  }
}

/* Dark Mode Support */
.dark .category-name {
  color: #f3f4f6;
}

.dark .category-description {
  color: #9ca3af;
}

.dark .item-count {
  background-color: #1e3a8a;
  color: #93c5fd;
}

.dark .stat-title {
  color: #9ca3af;
}

.dark .stat-value {
  color: #f3f4f6;
}

.dark .stat-link {
  color: #60a5fa;
}

.dark .stat-link:hover {
  color: #93c5fd;
}

.dark .cost-cell {
  color: #fca5a5;
}

.dark .price-cell {
  color: #6ee7b7;
}

.dark .quantity-cell {
  color: #93c5fd;
}

.dark .reorder-point {
  color: #9ca3af;
}

.dark .items-left.warning {
  background-color: #451a03;
  color: #fbbf24;
}

.dark .items-left.danger {
  background-color: #450a0a;
  color: #fca5a5;
}

.dark .item-name {
  color: #f3f4f6;
}

.dark .amount-cell {
  color: #6ee7b7;
}

.dark .date-cell {
  color: #9ca3af;
}

.dark .form-label {
  color: #d1d5db;
}

.dark .form-input {
  background-color: #374151;
  border-color: #4b5563;
  color: #f3f4f6;
}

.dark .form-input:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

.dark .form-textarea {
  background-color: #374151;
  border-color: #4b5563;
  color: #f3f4f6;
}

.dark .form-textarea:focus {
  border-color: #60a5fa;
  box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

.dark .warning-message {
  background-color: #451a03;
  border-color: #d97706;
  color: #fbbf24;
}

.dark .add-item-btn {
  background-color: #3b82f6;
  color: white;
}

.dark .add-item-btn:hover {
  background-color: #2563eb;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

/* Ordered Page Styles */
.ordered-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.ordered-summary {
  margin-bottom: 1rem;
}

.ordered-panel {
  flex: 1;
}

/* Summation Page Styles */
.summation-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.summation-panel {
  flex: 1;
}

.category-cell {
  padding: 1rem;
}

.category-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.category-icon {
  width: 2.5rem;
  height: 2.5rem;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.category-details {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.category-name {
  font-weight: 600;
  color: #111827;
  font-size: 1rem;
}

.category-description {
  color: #6b7280;
  font-size: 0.875rem;
}

.value-cell {
  font-weight: 600;
  color: #059669;
  font-size: 1.125rem;
  text-align: right;
  padding: 1rem;
}

.total-row {
  background: linear-gradient(135deg, #f8fafc, #e2e8f0);
  border-top: 2px solid #3b82f6;
}

.total-cell {
  padding: 1.5rem 1rem;
}

.total-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.total-icon {
  width: 3rem;
  height: 3rem;
  background: linear-gradient(135deg, #10b981, #059669);
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.total-details {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.total-label {
  font-weight: 700;
  color: #111827;
  font-size: 1.125rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.total-description {
  color: #6b7280;
  font-size: 0.875rem;
}

.total-value {
  font-weight: 700;
  color: #059669;
  font-size: 1.5rem;
  text-align: right;
  padding: 1.5rem 1rem;
}

/* Responsive Design for Ordered and Summation */
@media (max-width: 768px) {
  .category-info {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .category-icon {
    width: 2rem;
    height: 2rem;
  }
  
  .total-info {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .total-icon {
    width: 2.5rem;
    height: 2.5rem;
  }
  
  .value-cell,
  .total-value {
    text-align: left;
    font-size: 1rem;
  }
}

/* Dark Mode Support for Ordered and Summation */
.dark .category-name {
  color: #f3f4f6;
}

.dark .category-description {
  color: #9ca3af;
}

.dark .value-cell {
  color: #6ee7b7;
}

.dark .total-row {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-top-color: #60a5fa;
}

.dark .total-label {
  color: #f3f4f6;
}

.dark .total-description {
  color: #9ca3af;
}

.dark .total-value {
  color: #6ee7b7;
}

/* Customer Pages Styles */
.customers-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.customers-panel {
  flex: 1;
}

.sms-all-btn {
  background-color: #10b981;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.sms-all-btn:hover {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.sms-btn {
  background-color: #10b981;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.sms-btn:hover {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.customer-name {
  font-weight: 600;
  color: #111827;
}

.phone-number {
  color: #6b7280;
  font-family: monospace;
}

.purchase-count {
  font-weight: 600;
  color: #3b82f6;
}

.last-purchase {
  color: #6b7280;
  font-size: 0.875rem;
}

/* Outstanding Customers Layout */
.outstanding-customers-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
  height: calc(100vh - 200px);
}

.outstanding-list-panel {
  overflow: hidden;
}

.details-panel {
  overflow: hidden;
}

.individual-details {
  height: 100%;
}

.general-summary {
  height: 100%;
}

.outstanding-details {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  height: 100%;
}

.invoice-details,
.balance-section {
  overflow-y: auto;
}

.balance-info {
  padding: 1rem;
}

/* Settings Page Styles */
.settings-layout {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.settings-panel,
.users-panel {
  flex: 1;
}

.profile-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.password-section {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.form-help {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #6b7280;
  font-size: 0.875rem;
  margin-bottom: 1rem;
}

.form-error {
  color: #ef4444;
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

.form-actions {
  margin-top: 1rem;
}

.save-btn {
  background-color: #3b82f6;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.save-btn:hover {
  background-color: #2563eb;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.add-user-btn {
  background-color: #8b5cf6;
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.add-user-btn:hover {
  background-color: #7c3aed;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.3);
}

.users-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.user-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem;
  background-color: #f9fafb;
  border-radius: 0.5rem;
  border: 1px solid #e5e7eb;
  transition: all 0.2s ease-in-out;
}

.user-item:hover {
  background-color: #f3f4f6;
  border-color: #d1d5db;
}

.user-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.user-avatar {
  width: 2.5rem;
  height: 2.5rem;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.user-details {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.user-name {
  font-weight: 600;
  color: #111827;
  font-size: 1rem;
  margin: 0;
}

.user-phone {
  color: #6b7280;
  font-size: 0.875rem;
  margin: 0;
}

.user-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.user-role {
  display: flex;
  align-items: center;
}

.role-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.role-badge.admin {
  background-color: #fef3c7;
  color: #92400e;
}

.role-badge.user {
  background-color: #dbeafe;
  color: #1e40af;
}

.cancel-btn {
  background-color: #6b7280;
  color: white;
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  text-decoration: none;
}

.cancel-btn:hover {
  background-color: #4b5563;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(107, 114, 128, 0.3);
}

/* Responsive Design for Customer and Settings Pages */
@media (max-width: 1024px) {
  .outstanding-customers-layout {
    grid-template-columns: 1fr;
    height: auto;
  }
  
  .outstanding-details {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .user-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .user-actions {
    width: 100%;
    justify-content: space-between;
  }
  
  .form-grid {
    grid-template-columns: 1fr;
  }
}

/* Dark Mode Support for Customer and Settings Pages */
.dark .customer-name {
  color: #f3f4f6;
}

.dark .phone-number {
  color: #9ca3af;
}

.dark .purchase-count {
  color: #60a5fa;
}

.dark .last-purchase {
  color: #9ca3af;
}

.dark .sms-all-btn {
  background-color: #10b981;
  color: white;
}

.dark .sms-all-btn:hover {
  background-color: #059669;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.dark .sms-btn {
  background-color: #10b981;
  color: white;
}

.dark .sms-btn:hover {
  background-color: #059669;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.dark .form-help {
  color: #9ca3af;
}

.dark .form-error {
  color: #f87171;
}

.dark .save-btn {
  background-color: #3b82f6;
  color: white;
}

.dark .save-btn:hover {
  background-color: #2563eb;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.dark .add-user-btn {
  background-color: #8b5cf6;
  color: white;
}

.dark .add-user-btn:hover {
  background-color: #7c3aed;
  box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.dark .user-item {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .user-item:hover {
  background-color: #4b5563;
  border-color: #6b7280;
}

.dark .user-name {
  color: #f3f4f6;
}

.dark .user-phone {
  color: #9ca3af;
}

.dark .role-badge.admin {
  background-color: #451a03;
  color: #fbbf24;
}

.dark .role-badge.user {
  background-color: #1e3a8a;
  color: #93c5fd;
}

.dark .cancel-btn {
  background-color: #6b7280;
  color: white;
}

.dark .cancel-btn:hover {
  background-color: #4b5563;
  box-shadow: 0 4px 12px rgba(107, 114, 128, 0.4);
}

/* Enhanced Financial Overview Styles */
.summary-title-section {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.summary-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.refresh-btn {
  background-color: #f3f4f6;
  color: #6b7280;
  border: none;
  padding: 0.5rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
}

.refresh-btn:hover {
  background-color: #e5e7eb;
  color: #374151;
  transform: rotate(180deg);
}

.key-metrics-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.key-metric {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease-in-out;
}

.key-metric:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.key-metric::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #3b82f6, #1d4ed8);
}

.profit-metric::before {
  background: linear-gradient(90deg, #10b981, #059669);
}

.cash-metric::before {
  background: linear-gradient(90deg, #8b5cf6, #7c3aed);
}

.metric-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.metric-icon-wrapper {
  width: 3rem;
  height: 3rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.metric-icon-wrapper.sales {
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
  color: #1d4ed8;
}

.metric-icon-wrapper.profit {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #059669;
}

.metric-icon-wrapper.cash {
  background: linear-gradient(135deg, #e9d5ff, #ddd6fe);
  color: #7c3aed;
}

.metric-icon-wrapper.cogs {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  color: #d97706;
}

.metric-icon-wrapper.expenses {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  color: #dc2626;
}

.metric-icon-wrapper.outstanding {
  background: linear-gradient(135deg, #f3e8ff, #e9d5ff);
  color: #9333ea;
}

.metric-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.metric-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.metric-value {
  font-size: 1.5rem;
  font-weight: 700;
  color: #111827;
  line-height: 1.2;
}

.metric-change {
  display: flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  font-weight: 500;
}

.metric-change.positive {
  color: #059669;
}

.metric-change.negative {
  color: #dc2626;
}

.secondary-metrics-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

.metric-card {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1.25rem;
  transition: all 0.2s ease-in-out;
}

.metric-card:hover {
  border-color: #d1d5db;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.metric-card-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.metric-card .metric-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #374151;
  margin: 0;
}

.metric-card .metric-value {
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
  margin-bottom: 0.5rem;
}

.metric-description {
  font-size: 0.75rem;
  color: #6b7280;
  line-height: 1.4;
}

.financial-health {
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border: 1px solid #bbf7d0;
  border-radius: 1rem;
  padding: 1.5rem;
}

.health-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.health-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #166534;
  margin: 0;
}

.health-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
}

.health-status.positive {
  background-color: #dcfce7;
  color: #166534;
}

.health-status.negative {
  background-color: #fee2e2;
  color: #dc2626;
}

.health-metrics {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.health-metric {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.health-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
  min-width: 100px;
}

.health-bar {
  flex: 1;
  height: 8px;
  background-color: #e5e7eb;
  border-radius: 4px;
  overflow: hidden;
}

.health-fill {
  height: 100%;
  background: linear-gradient(90deg, #10b981, #059669);
  border-radius: 4px;
  transition: width 0.3s ease-in-out;
}

.health-value {
  font-size: 0.875rem;
  font-weight: 600;
  color: #059669;
  min-width: 40px;
  text-align: right;
}

/* Responsive Design for Enhanced Financial Overview */
@media (max-width: 1024px) {
  .key-metrics-row {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .secondary-metrics-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .metric-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .metric-icon-wrapper {
    width: 2.5rem;
    height: 2.5rem;
  }
  
  .metric-value {
    font-size: 1.25rem;
  }
  
  .health-metric {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .health-label {
    min-width: auto;
  }
  
  .health-bar {
    width: 100%;
  }
}

/* Dark Mode Support for Enhanced Financial Overview */
.dark .refresh-btn {
  background-color: #374151;
  color: #9ca3af;
}

.dark .refresh-btn:hover {
  background-color: #4b5563;
  color: #d1d5db;
}

.dark .key-metric {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .metric-label {
  color: #9ca3af;
}

.dark .metric-value {
  color: #f3f4f6;
}

.dark .metric-card {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .metric-card:hover {
  border-color: #6b7280;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.dark .metric-card .metric-label {
  color: #d1d5db;
}

.dark .metric-card .metric-value {
  color: #f3f4f6;
}

.dark .metric-description {
  color: #9ca3af;
}

.dark .financial-health {
  background: linear-gradient(135deg, #064e3b, #065f46);
  border-color: #059669;
}

.dark .health-title {
  color: #6ee7b7;
}

.dark .health-status.positive {
  background-color: #064e3b;
  color: #6ee7b7;
}

.dark .health-label {
  color: #d1d5db;
}

.dark .health-bar {
  background-color: #374151;
}

.dark .health-value {
  color: #6ee7b7;
}

/* Cat-Info Page Styles */
.modern-header {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.sidebar-toggle-btn {
  background-color: #f3f4f6;
  color: #6b7280;
  border: none;
  padding: 0.75rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sidebar-toggle-btn:hover {
  background-color: #e5e7eb;
  color: #374151;
}

.page-title-section {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.page-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #111827;
  margin: 0;
}

.page-subtitle {
  font-size: 0.875rem;
  color: #6b7280;
}

.main-content {
  padding: 1.5rem;
}

.content-grid {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 1.5rem;
}

/* Card Styles */
.brands-card,
.items-card {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.card-header {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 1px solid #e5e7eb;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.card-title-section {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.card-icon {
  width: 3rem;
  height: 3rem;
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
  color: #1d4ed8;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.card-title-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.card-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.card-subtitle {
  font-size: 0.875rem;
  color: #6b7280;
}

.card-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.action-btn {
  background-color: #f3f4f6;
  color: #6b7280;
  border: none;
  padding: 0.5rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
}

.action-btn:hover {
  background-color: #e5e7eb;
  color: #374151;
  transform: translateY(-1px);
}

.action-btn.add-btn {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #059669;
}

.action-btn.add-btn:hover {
  background: linear-gradient(135deg, #a7f3d0, #6ee7b7);
  color: #047857;
}

.action-btn.edit-btn {
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
  color: #1d4ed8;
}

.action-btn.edit-btn:hover {
  background: linear-gradient(135deg, #bfdbfe, #93c5fd);
  color: #1e40af;
}

.action-btn.delete-btn {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  color: #dc2626;
}

.action-btn.delete-btn:hover {
  background: linear-gradient(135deg, #fecaca, #fca5a5);
  color: #b91c1c;
}

.action-btn.cancel-btn {
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #6b7280;
}

.action-btn.cancel-btn:hover {
  background: linear-gradient(135deg, #e5e7eb, #d1d5db);
  color: #374151;
}

/* Form Styles */
.add-form,
.edit-form {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border: 1px solid #bae6fd;
  border-radius: 0.75rem;
  padding: 1.5rem;
  margin: 1rem;
}

.form-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.form-input {
  background-color: #ffffff;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  padding: 0.75rem;
  font-size: 0.875rem;
  transition: all 0.2s ease-in-out;
}

.form-input:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.radio-group {
  display: flex;
  gap: 1rem;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.875rem;
  color: #374151;
}

.radio-label input[type="radio"] {
  display: none;
}

.radio-custom {
  width: 1rem;
  height: 1rem;
  border: 2px solid #d1d5db;
  border-radius: 50%;
  position: relative;
  transition: all 0.2s ease-in-out;
}

.radio-label input[type="radio"]:checked + .radio-custom {
  border-color: #3b82f6;
  background-color: #3b82f6;
}

.radio-label input[type="radio"]:checked + .radio-custom::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0.25rem;
  height: 0.25rem;
  background-color: white;
  border-radius: 50%;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 1rem;
}

.btn-primary {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-primary:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

/* Brands List Styles */
.brands-list {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.brand-item {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: all 0.2s ease-in-out;
}

.brand-item:hover {
  border-color: #d1d5db;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}

.brand-item.all-brands {
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border-color: #bae6fd;
}

.brand-item.sub-category {
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border-color: #bbf7d0;
}

.brand-info {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex: 1;
}

.brand-icon {
  width: 2.5rem;
  height: 2.5rem;
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #6b7280;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.brand-details {
  flex: 1;
}

.brand-link {
  text-decoration: none;
  color: inherit;
}

.brand-name {
  font-size: 1rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 0.25rem 0;
}

.brand-description {
  font-size: 0.875rem;
  color: #6b7280;
}

.brand-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.reorder-info {
  font-size: 0.75rem;
  color: #6b7280;
  background-color: #f3f4f6;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
}

.brand-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.view-btn {
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
  color: #1d4ed8;
  text-decoration: none;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s ease-in-out;
}

.view-btn:hover {
  background: linear-gradient(135deg, #bfdbfe, #93c5fd);
  color: #1e40af;
  transform: translateY(-1px);
}

/* Table Styles */
.table-container {
  padding: 1rem;
  overflow-x: auto;
}

.modern-table {
  width: 100%;
  border-collapse: collapse;
  background-color: #ffffff;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.table-header {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 1px solid #e5e7eb;
  padding: 1rem;
  text-align: left;
  font-weight: 600;
  color: #374151;
}

.header-content {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.table-row {
  border-bottom: 1px solid #f3f4f6;
  transition: all 0.2s ease-in-out;
}

.table-row:hover {
  background-color: #f9fafb;
}

.table-cell {
  padding: 1rem;
  vertical-align: top;
}

.item-name-cell {
  min-width: 200px;
}

.item-info {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.item-icon {
  width: 2rem;
  height: 2rem;
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #6b7280;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.item-details {
  flex: 1;
}

.item-name {
  font-weight: 600;
  color: #111827;
  margin-bottom: 0.25rem;
}

.item-description {
  font-size: 0.875rem;
  color: #6b7280;
  line-height: 1.4;
}

.quantity-info,
.price-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.quantity-value,
.price-value {
  font-weight: 600;
  color: #111827;
}

.quantity-unit,
.price-currency {
  font-size: 0.75rem;
  color: #6b7280;
}

.actions-cell {
  width: 120px;
}

.action-buttons {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Summary Stats */
.items-summary {
  margin-top: 0.5rem;
}

.summary-stats {
  display: flex;
  gap: 1rem;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.stat-label {
  font-size: 0.875rem;
  color: #6b7280;
}

.stat-value {
  font-weight: 600;
  color: #111827;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .content-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .main-content {
    padding: 1rem;
  }
  
  .header-content {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .header-left {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  
  .card-title-section {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .brand-item {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .brand-info {
    width: 100%;
  }
  
  .brand-actions {
    width: 100%;
    justify-content: flex-end;
  }
  
  .table-container {
    padding: 0.5rem;
  }
  
  .modern-table {
    font-size: 0.875rem;
  }
  
  .table-cell {
    padding: 0.75rem 0.5rem;
  }
  
  .action-buttons {
    flex-direction: column;
    gap: 0.25rem;
  }
  
  .summary-stats {
    flex-direction: column;
    gap: 0.5rem;
  }
}

/* Dark Mode Support */
.dark .modern-header {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .sidebar-toggle-btn {
  background-color: #4b5563;
  color: #9ca3af;
}

.dark .sidebar-toggle-btn:hover {
  background-color: #6b7280;
  color: #d1d5db;
}

.dark .page-title {
  color: #f3f4f6;
}

.dark .page-subtitle {
  color: #9ca3af;
}

.dark .brands-card,
.dark .items-card {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .card-header {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  border-color: #6b7280;
}

.dark .card-title {
  color: #f3f4f6;
}

.dark .card-subtitle {
  color: #9ca3af;
}

.dark .brand-item {
  background-color: #374151;
  border-color: #4b5563;
}

.dark .brand-item:hover {
  border-color: #6b7280;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.dark .brand-item.all-brands {
  background: linear-gradient(135deg, #1e3a8a, #1e40af);
  border-color: #3b82f6;
}

.dark .brand-item.sub-category {
  background: linear-gradient(135deg, #064e3b, #065f46);
  border-color: #059669;
}

.dark .brand-name {
  color: #f3f4f6;
}

.dark .brand-description {
  color: #9ca3af;
}

.dark .reorder-info {
  background-color: #4b5563;
  color: #d1d5db;
}

.dark .form-input {
  background-color: #374151;
  border-color: #4b5563;
  color: #f3f4f6;
}

.dark .form-input:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.dark .form-label {
  color: #d1d5db;
}

.dark .radio-label {
  color: #d1d5db;
}

.dark .modern-table {
  background-color: #374151;
}

.dark .table-header {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  border-color: #6b7280;
  color: #d1d5db;
}

.dark .table-row:hover {
  background-color: #4b5563;
}

.dark .item-name {
  color: #f3f4f6;
}

.dark .item-description {
  color: #9ca3af;
}

.dark .quantity-value,
.dark .price-value {
  color: #f3f4f6;
}

.dark .quantity-unit,
.dark .price-currency {
  color: #9ca3af;
}

.dark .stat-label {
  color: #9ca3af;
}

.dark .stat-value {
  color: #f3f4f6;
}

/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.modal-container {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal-header {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 1px solid #e5e7eb;
  padding: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.modal-title-section {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.modal-icon {
  width: 3rem;
  height: 3rem;
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #059669;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.modal-title-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.modal-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.modal-subtitle {
  font-size: 0.875rem;
  color: #6b7280;
}

.modal-close-btn {
  background-color: #f3f4f6;
  color: #6b7280;
  border: none;
  padding: 0.5rem;
  border-radius: 0.5rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close-btn:hover {
  background-color: #e5e7eb;
  color: #374151;
}

.modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-section {
  background: linear-gradient(135deg, #f9fafb, #f3f4f6);
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  padding: 1.5rem;
}

.section-title {
  font-size: 1rem;
  font-weight: 600;
  color: #374151;
  margin: 0 0 1rem 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.section-title::before {
  content: '';
  width: 4px;
  height: 1rem;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border-radius: 2px;
}

.form-input.readonly {
  background-color: #f9fafb;
  color: #6b7280;
  cursor: not-allowed;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  padding-top: 1rem;
  border-top: 1px solid #e5e7eb;
}

.btn-secondary {
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #374151;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-secondary:hover {
  background: linear-gradient(135deg, #e5e7eb, #d1d5db);
  color: #111827;
  transform: translateY(-1px);
}

.loader-container {
  display: flex;
  align-items: center;
  justify-content: center;
}

.loader {
  width: 16px;
  height: 16px;
  border: 2px solid transparent;
  border-top: 2px solid currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Responsive Modal */
@media (max-width: 768px) {
  .modal-overlay {
    padding: 0.5rem;
  }
  
  .modal-container {
    max-height: 95vh;
  }
  
  .modal-header {
    padding: 1rem;
  }
  
  .modal-body {
    padding: 1rem;
  }
  
  .form-grid {
    grid-template-columns: 1fr;
  }
  
  .modal-actions {
    flex-direction: column;
  }
  
  .btn-primary,
  .btn-secondary {
    width: 100%;
    justify-content: center;
  }
}

/* Dark Mode Modal Support */
.dark .modal-container {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .modal-header {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  border-color: #6b7280;
}

.dark .modal-title {
  color: #f3f4f6;
}

.dark .modal-subtitle {
  color: #9ca3af;
}

.dark .modal-close-btn {
  background-color: #4b5563;
  color: #9ca3af;
}

.dark .modal-close-btn:hover {
  background-color: #6b7280;
  color: #d1d5db;
}

.dark .form-section {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  border-color: #6b7280;
}

.dark .section-title {
  color: #d1d5db;
}

.dark .section-title::before {
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
}

.dark .form-input.readonly {
  background-color: #4b5563;
  color: #9ca3af;
}

.dark .modal-actions {
  border-color: #6b7280;
}

.dark .btn-secondary {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  color: #d1d5db;
}

.dark .btn-secondary:hover {
  background: linear-gradient(135deg, #6b7280, #9ca3af);
  color: #f3f4f6;
}

/* Container class for consistent layout */
.container {
  max-width:  100%;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Cat-Info Layout Styles - Following Categories Pattern */
.cat-info-layout {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 1.5rem;
  min-height: 400px; /* Ensure minimum height */
}

.brands-panel,
.items-panel {
  display: flex;
  flex-direction: column;
}

.data-card {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-header {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 1px solid #e5e7eb;
  padding: 1.5rem;
}

.card-header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.card-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #111827;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.add-category-btn {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  border: none;
  padding: 0.75rem 1rem;
  border-radius: 0.5rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
}

.add-category-btn:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.card-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  background-color: #ffffff;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.data-table th {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 1px solid #e5e7eb;
  padding: 1rem;
  text-align: left;
  font-weight: 600;
  color: #374151;
  font-size: 0.875rem;
}

.data-table td {
  padding: 1rem;
  border-bottom: 1px solid #f3f4f6;
  vertical-align: top;
}

.data-table tr:hover {
  background-color: #f9fafb;
}

.brand-name {
  min-width: 200px;
}

.brand-link {
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.brand-link strong {
  font-weight: 600;
  color: #111827;
}

.brand-description {
  font-size: 0.875rem;
  color: #6b7280;
}

.reorder-point {
  font-weight: 500;
  color: #374151;
}

.item-name {
  min-width: 200px;
}

.item-name strong {
  font-weight: 600;
  color: #111827;
  display: block;
  margin-bottom: 0.25rem;
}

.item-description {
  font-size: 0.875rem;
  color: #6b7280;
}

.item-quantity,
.item-cost,
.item-price {
  font-weight: 500;
  color: #374151;
}

.action-buttons {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.action-btn {
  background-color: #f3f4f6;
  color: #6b7280;
  border: none;
  padding: 0.5rem 0.75rem;
  border-radius: 0.375rem;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
}

.action-btn:hover {
  background-color: #e5e7eb;
  color: #374151;
  transform: translateY(-1px);
}

.action-btn.edit-btn {
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
  color: #1d4ed8;
}

.action-btn.edit-btn:hover {
  background: linear-gradient(135deg, #bfdbfe, #93c5fd);
  color: #1e40af;
}

.action-btn.delete-btn {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  color: #dc2626;
}

.action-btn.delete-btn:hover {
  background: linear-gradient(135deg, #fecaca, #fca5a5);
  color: #b91c1c;
}

.action-btn.info-btn {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #059669;
}

.action-btn.info-btn:hover {
  background: linear-gradient(135deg, #a7f3d0, #6ee7b7);
  color: #047857;
}

.items-summary {
  margin-bottom: 1rem;
}

.summary-stats {
  display: flex;
  gap: 1rem;
  padding: 1rem;
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border: 1px solid #bae6fd;
  border-radius: 0.75rem;
}

.stat-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.stat-label {
  font-size: 0.875rem;
  color: #6b7280;
  font-weight: 500;
}

.stat-value {
  font-weight: 600;
  color: #111827;
}

/* Modal Styles - Following Categories Pattern */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 1rem;
}

.modal-container {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.modal-container.modal-large {
  max-width: 600px;
}

.modal-header {
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-bottom: 1px solid #e5e7eb;
  padding: 1.5rem;
  text-align: center;
}

.modal-icon {
  width: 4rem;
  height: 4rem;
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #059669;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
}

.modal-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #111827;
  margin: 0 0 0.5rem 0;
}

.modal-subtitle {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0;
}

.modal-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex: 1;
}

.modal-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.form-group.full-width {
  grid-column: 1 / -1;
}

.form-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.form-input,
.form-textarea {
  background-color: #ffffff;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  padding: 0.75rem;
  font-size: 0.875rem;
  transition: all 0.2s ease-in-out;
}

.form-input:focus,
.form-textarea:focus {
  outline: none;
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-textarea {
  resize: vertical;
  min-height: 100px;
}

.radio-group {
  display: flex;
  gap: 1rem;
}

.radio-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.875rem;
  color: #374151;
}

.radio-label input[type="radio"] {
  display: none;
}

.radio-custom {
  width: 1rem;
  height: 1rem;
  border: 2px solid #d1d5db;
  border-radius: 50%;
  position: relative;
  transition: all 0.2s ease-in-out;
}

.radio-label input[type="radio"]:checked + .radio-custom {
  border-color: #3b82f6;
  background-color: #3b82f6;
}

.radio-label input[type="radio"]:checked + .radio-custom::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 0.25rem;
  height: 0.25rem;
  background-color: white;
  border-radius: 50%;
}

.modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 1rem;
  padding: 1.5rem;
  border-top: 1px solid #e5e7eb;
}

.modal-btn {
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
}

.modal-btn-secondary {
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #374151;
}

.modal-btn-secondary:hover {
  background: linear-gradient(135deg, #e5e7eb, #d1d5db);
  color: #111827;
  transform: translateY(-1px);
}

.modal-btn-primary {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
}

.modal-btn-primary:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.modal-btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
}

.modal-btn-danger:hover {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

/* Confirmation Details Styles */
.confirmation-details {
  padding: 1rem 0;
}

.detail-item {
  margin-bottom: 1rem;
}

.warning-message {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  border: 1px solid #f59e0b;
  border-radius: 0.75rem;
  color: #92400e;
  font-size: 0.875rem;
  font-weight: 500;
}

.warning-message svg {
  color: #d97706;
  flex-shrink: 0;
}

.warning-message span {
  line-height: 1.4;
}

.loader-container {
  display: flex;
  align-items: center;
  justify-content: center;
}

.loader {
  width: 16px;
  height: 16px;
  border: 2px solid transparent;
  border-top: 2px solid currentColor;
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Responsive Design */
@media (max-width: 1024px) {
  .cat-info-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .form-grid {
    grid-template-columns: 1fr;
  }
  
  .modal-actions {
    flex-direction: column;
  }
  
  .modal-btn {
    width: 100%;
    justify-content: center;
  }
  
  .action-buttons {
    flex-direction: column;
    gap: 0.25rem;
  }
  
  .action-btn {
    width: 100%;
    justify-content: center;
  }
  
  .summary-stats {
    flex-direction: column;
    gap: 0.5rem;
  }
}

/* Dark Mode Support */
.dark .data-card {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .card-header {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  border-color: #6b7280;
}

.dark .card-title {
  color: #f3f4f6;
}

.dark .data-table {
  background-color: #374151;
}

.dark .data-table th {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  border-color: #6b7280;
  color: #d1d5db;
}

.dark .data-table tr:hover {
  background-color: #4b5563;
}

.dark .brand-link strong {
  color: #f3f4f6;
}

.dark .brand-description {
  color: #9ca3af;
}

.dark .reorder-point {
  color: #d1d5db;
}

.dark .item-name strong {
  color: #f3f4f6;
}

.dark .item-description {
  color: #9ca3af;
}

.dark .item-quantity,
.dark .item-cost,
.dark .item-price {
  color: #d1d5db;
}

.dark .modal-container {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .modal-header {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  border-color: #6b7280;
}

.dark .modal-title {
  color: #f3f4f6;
}

.dark .modal-subtitle {
  color: #9ca3af;
}

.dark .form-input,
.dark .form-textarea {
  background-color: #374151;
  border-color: #4b5563;
  color: #f3f4f6;
}

.dark .form-input:focus,
.dark .form-textarea:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.dark .form-label {
  color: #d1d5db;
}

.dark .radio-label {
  color: #d1d5db;
}

.dark .modal-actions {
  border-color: #6b7280;
}

.dark .modal-btn-secondary {
  background: linear-gradient(135deg, #374151, #4b5563);
  color: #d1d5db;
}

.dark .modal-btn-secondary:hover {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  color: #f3f4f6;
  transform: translateY(-1px);
}

.dark .modal-btn-primary {
  background: linear-gradient(135deg, #1e40af, #1e3a8a);
  color: #f3f4f6;
}

.dark .modal-btn-primary:hover {
  background: linear-gradient(135deg, #1e3a8a, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(30, 64, 175, 0.4);
}

.dark .modal-btn-danger {
  background: linear-gradient(135deg, #b91c1c, #991b1b);
  color: #f3f4f6;
}

.dark .modal-btn-danger:hover {
  background: linear-gradient(135deg, #991b1b, #7f1d1d);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(185, 28, 28, 0.4);
}

.dark .summary-stats {
  background: linear-gradient(135deg, #1e3a8a, #1e40af);
  border-color: #3b82f6;
}

.dark .stat-label {
  color: #9ca3af;
}

.dark .stat-value {
  color: #f3f4f6;
}

.dark .warning-message {
  background: linear-gradient(135deg, #451a03, #78350f);
  border-color: #d97706;
  color: #fbbf24;
}

.dark .warning-message svg {
  color: #f59e0b;
}

/* Outstanding Invoices Summary Cards Styles */
.summary-cards-section {
  margin-bottom: 2rem;
}

.summary-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.summary-card {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease-in-out;
  position: relative;
  overflow: hidden;
}

.summary-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.summary-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #3b82f6, #1d4ed8);
}

.summary-card.revenue-card::before {
  background: linear-gradient(90deg, #10b981, #059669);
}

.summary-card.total-card::before {
  background: linear-gradient(90deg, #8b5cf6, #7c3aed);
}

.summary-card-header {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.summary-icon {
  width: 3rem;
  height: 3rem;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.summary-icon.outstanding {
  background: linear-gradient(135deg, #dbeafe, #bfdbfe);
  color: #1d4ed8;
}

.summary-icon.revenue {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #059669;
}

.summary-icon.total {
  background: linear-gradient(135deg, #e9d5ff, #ddd6fe);
  color: #7c3aed;
}

.summary-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.summary-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 0;
}

.summary-value {
  font-size: 1.75rem;
  font-weight: 700;
  color: #111827;
  line-height: 1.2;
}

.summary-description {
  font-size: 0.875rem;
  color: #6b7280;
  line-height: 1.4;
}

.summary-action {
  margin-top: 1rem;
}

.action-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #3b82f6;
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.2s ease-in-out;
}

.action-link:hover {
  color: #1d4ed8;
  transform: translateX(2px);
}

/* SMS Cards Styles */
.sms-cards-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.sms-card {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 1rem;
  padding: 1.5rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease-in-out;
}

.sms-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.sms-card-header {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.sms-icon {
  width: 2.5rem;
  height: 2.5rem;
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #6b7280;
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.sms-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.sms-title {
  font-size: 1rem;
  font-weight: 600;
  color: #111827;
  margin: 0;
}

.sms-description {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0;
}

.sms-count {
  font-size: 0.875rem;
  color: #6b7280;
  font-weight: 500;
}

.sms-action,
.sms-actions {
  display: flex;
  gap: 0.5rem;
}

.sms-btn {
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.sms-btn.primary {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
}

.sms-btn.primary:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.sms-btn.secondary {
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #374151;
}

.sms-btn.secondary:hover {
  background: linear-gradient(135deg, #e5e7eb, #d1d5db);
  color: #111827;
  transform: translateY(-1px);
}

/* Responsive Design */
@media (max-width: 1024px) {
  .summary-cards-grid,
  .sms-cards-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .summary-card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .summary-icon {
    width: 2.5rem;
    height: 2.5rem;
  }
  
  .summary-value {
    font-size: 1.5rem;
  }
  
  .sms-card-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.75rem;
  }
  
  .sms-actions {
    width: 100%;
    justify-content: stretch;
  }
  
  .sms-btn {
    flex: 1;
    justify-content: center;
  }
}

/* Dark Mode Support */
.dark .summary-card {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .summary-card:hover {
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.dark .summary-title {
  color: #9ca3af;
}

.dark .summary-value {
  color: #f3f4f6;
}

.dark .summary-description {
  color: #9ca3af;
}

.dark .action-link {
  color: #60a5fa;
}

.dark .action-link:hover {
  color: #93c5fd;
}

.dark .sms-card {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .sms-card:hover {
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.dark .sms-icon {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  color: #9ca3af;
}

.dark .sms-title {
  color: #f3f4f6;
}

.dark .sms-description,
.dark .sms-count {
  color: #9ca3af;
}

.dark .sms-btn.secondary {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  color: #d1d5db;
}

.dark .sms-btn.secondary:hover {
  background: linear-gradient(135deg, #6b7280, #9ca3af);
  color: #f3f4f6;
}

/* SMS Modal Styles */
.modal-container.large {
  max-width: 800px;
  width: 90%;
}

/* Shortcuts Section */
.shortcuts-section {
 
  margin-top: 1.5rem;
  padding: 1rem;
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-radius: 0.75rem;
  border: 1px solid #e2e8f0;
}

.shortcuts-title {
  font-size: 0.875rem;
  font-weight: 600;
  color: #475569;
  margin: 0 0 1rem 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.shortcuts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 0.75rem;
}

.shortcut-item {
  display: flex !important;
  flex-direction: column !important;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  background: white;
  border-radius: 0.5rem;
  border: 1px solid #e2e8f0;
  transition: all 0.2s ease-in-out;
}

.shortcut-item:hover {
  border-color: #3b82f6;
  box-shadow: 0 2px 4px rgba(59, 130, 246, 0.1);
}

.shortcut-code {
  font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
  font-size: 0.875rem;
  font-weight: 600;
  color: #3b82f6;
  background: #dbeafe;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  min-width: 80px;
  text-align: center;
}

.shortcut-description {
  font-size: 0.875rem;
  color: #64748b;
  flex: 1;
}

/* Templates List */
.templates-list {
  max-height: 400px;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.template-item {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem;
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  margin-bottom: 0.75rem;
  transition: all 0.2s ease-in-out;
}

.template-item:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1);
  transform: translateY(-1px);
}

.template-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.template-message {
  font-size: 0.875rem;
  color: #374151;
  line-height: 1.5;
  background: #f9fafb;
  padding: 0.75rem;
  border-radius: 0.5rem;
  border-left: 3px solid #3b82f6;
}

.template-meta {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.template-target {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  color: #6b7280;
  background: #f3f4f6;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
}

.template-actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}

.template-btn {
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.template-btn.send-btn {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
}

.template-btn.send-btn:hover {
  background: linear-gradient(135deg, #059669, #047857);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

.template-btn.edit-btn {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
}

.template-btn.edit-btn:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.template-btn.delete-btn {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
}

.template-btn.delete-btn:hover {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: #6b7280;
}

.empty-icon {
  margin: 0 auto 1rem;
  width: 4rem;
  height: 4rem;
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #9ca3af;
}

.empty-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #374151;
  margin: 0 0 0.5rem 0;
}

.empty-description {
  font-size: 0.875rem;
  color: #6b7280;
  margin: 0;
}

/* Scheduled SMS Styles */
.add-schedule-form {
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-radius: 0.75rem;
  border: 1px solid #e2e8f0;
}

.form-section {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.form-section-title {
  font-size: 1rem;
  font-weight: 600;
  color: #374151;
  margin: 0;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #e5e7eb;
}

.form-actions {
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
  margin-top: 1rem;
}

.scheduled-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid #e5e7eb;
}

.list-title {
  font-size: 1rem;
  font-weight: 600;
  color: #374151;
  margin: 0;
}

.add-schedule-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  color: white;
  border: none;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
}

.add-schedule-btn:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.4);
}

.scheduled-items {
  max-height: 300px;
  overflow-y: auto;
  padding-right: 0.5rem;
}

.empty-schedule {
  text-align: center;
  padding: 2rem 1rem;
  color: #6b7280;
}

/* Dark Mode Support for SMS Modals */
.dark .shortcuts-section {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .shortcuts-title {
  color: #d1d5db;
}

.dark .shortcut-item {
  background: #4b5563;
  border-color: #6b7280;
}

.dark .shortcut-item:hover {
  border-color: #60a5fa;
  box-shadow: 0 2px 4px rgba(96, 165, 250, 0.2);
}

.dark .shortcut-code {
  color: #60a5fa;
  background: #1e3a8a;
}

.dark .shortcut-description {
  color: #9ca3af;
}

.dark .template-item {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .template-item:hover {
  border-color: #60a5fa;
  box-shadow: 0 4px 12px rgba(96, 165, 250, 0.2);
}

.dark .template-message {
  color: #d1d5db;
  background: #4b5563;
  border-left-color: #60a5fa;
}

.dark .template-target {
  color: #9ca3af;
  background: #4b5563;
}

.dark .empty-icon {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  color: #9ca3af;
}

.dark .empty-title {
  color: #d1d5db;
}

.dark .empty-description {
  color: #9ca3af;
}

.dark .add-schedule-form {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .form-section-title {
  color: #d1d5db;
  border-bottom-color: #6b7280;
}

.dark .list-title {
  color: #d1d5db;
}

.dark .list-header {
  border-bottom-color: #6b7280;
}

/* Responsive Design for SMS Modals */
@media (max-width: 768px) {
  .modal-container.large {
    width: 95%;
    max-width: none;
  }
  
  .shortcuts-grid {
    grid-template-columns: 1fr;
  }
  
  .template-item {
    flex-direction: column;
    align-items: stretch;
  }
  
  .template-actions {
    justify-content: center;
    margin-top: 0.75rem;
  }
  
  .form-actions {
    flex-direction: column;
  }
  
  .list-header {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }
}

/* Add Item Modal Styles */
.product-name-highlight {
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  font-weight: 600;
}

.input-with-icon {
  position: relative;
  display: flex;
  align-items: center;
}

.input-icon {
  position: absolute;
  left: 0.75rem;
  color: #6b7280;
  pointer-events: none;
  z-index: 1;
}

.input-with-icon .form-input {
  padding-left: 2.5rem;
}

.form-help {
  font-size: 0.75rem;
  color: #6b7280;
  margin-top: 0.25rem;
  font-style: italic;
}

.confirmation-details {
  margin-top: 1.5rem;
  padding: 1rem;
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-radius: 0.75rem;
  border: 1px solid #e2e8f0;
}

.detail-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid #e5e7eb;
}

.detail-item:last-child {
  border-bottom: none;
  font-weight: 600;
  color: #059669;
}

.detail-label {
  font-size: 0.875rem;
  color: #6b7280;
  font-weight: 500;
}

.detail-value {
  font-size: 0.875rem;
  color: #374151;
  font-weight: 600;
}

/* Dark Mode Support for Add Item Modal */
.dark .product-name-highlight {
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.dark .input-icon {
  color: #9ca3af;
}

.dark .form-help {
  color: #9ca3af;
}

.dark .confirmation-details {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .detail-item {
  border-bottom-color: #4b5563;
}

.dark .detail-item:last-child {
  color: #10b981;
}

.dark .detail-label {
  color: #9ca3af;
}


/* Dynamic stock calculation styling */
#newStockDisplay {
  font-weight: 700;
  transition: color 0.3s ease;
}

#newStockDisplay.negative-stock {
  color: #ef4444 !important;
  animation: pulse-red 1s infinite;
}

#newStockDisplay.positive-stock {
  color: #059669 !important;
}

@keyframes pulse-red {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

/* Enhanced confirmation details */
.confirmation-details {
  position: relative;
  overflow: hidden;
}

.confirmation-details::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #3b82f6, #10b981, #f59e0b);
  border-radius: 1px;
}

.detail-item:last-child {
  background: linear-gradient(135deg, #f0fdf4, #dcfce7);
  border-radius: 0.5rem;
  padding: 0.75rem;
  margin-top: 0.5rem;
  border: 1px solid #bbf7d0;
}

.dark .detail-item:last-child {
  background: linear-gradient(135deg, #064e3b, #065f46);
  border-color: #10b981;
}

/* Stock level indicators */
.stock-indicator {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.25rem 0.5rem;
  border-radius: 0.25rem;
  margin-left: 0.5rem;
}

.stock-indicator.low {
  background: #fef3c7;
  color: #92400e;
  border: 1px solid #fbbf24;
}

.stock-indicator.critical {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #f87171;
}

.stock-indicator.good {
  background: #d1fae5;
  color: #065f46;
  border: 1px solid #34d399;
}

.dark .stock-indicator.low {
  background: #451a03;
  color: #fbbf24;
  border-color: #f59e0b;
}

.dark .stock-indicator.critical {
  background: #7f1d1d;
  color: #fca5a5;
  border-color: #ef4444;
}

.dark .stock-indicator.good {
  background: #064e3b;
  color: #6ee7b7;
  border-color: #10b981;
}

/* Product Information Modal Styles */
.product-info-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Product Header */
.product-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, #f8fafc, #f1f5f9);
  border-radius: 0.75rem;
  border: 1px solid #e2e8f0;
}

.product-icon {
  width: 4rem;
  height: 4rem;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border-radius: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  flex-shrink: 0;
}

.product-title-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.product-name {
  font-size: 1.5rem;
  font-weight: 700;
  color: #1f2937;
  margin: 0;
  line-height: 1.2;
}

.product-status {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.status-badge {
  padding: 0.25rem 0.75rem;
  border-radius: 1rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.status-badge.in-stock {
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  color: #065f46;
  border: 1px solid #10b981;
}

.status-badge.out-of-stock {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  color: #991b1b;
  border: 1px solid #ef4444;
}

.status-badge.low-stock {
  background: linear-gradient(135deg, #fef3c7, #fde68a);
  color: #92400e;
  border: 1px solid #f59e0b;
}

/* Product Description */
.product-description {
  padding: 1rem;
  background: #f9fafb;
  border-radius: 0.5rem;
  border-left: 4px solid #3b82f6;
}

.section-title {
  font-size: 1rem;
  font-weight: 600;
  color: #374151;
  margin: 0 0 0.75rem 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.product-desc {
  font-size: 0.875rem;
  color: #6b7280;
  line-height: 1.6;
  margin: 0;
  white-space: pre-line;
}

/* Product Details Grid */
.product-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.detail-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border: 1px solid #e5e7eb;
  border-radius: 0.75rem;
  transition: all 0.2s ease-in-out;
}

.detail-card:hover {
  border-color: #3b82f6;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1);
  transform: translateY(-1px);
}

.detail-icon {
  width: 2.5rem;
  height: 2.5rem;
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  border-radius: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6b7280;
  flex-shrink: 0;
}

.detail-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex: 1;
}

.detail-label {
  font-size: 0.75rem;
  color: #6b7280;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.detail-value {
  font-size: 1.125rem;
  font-weight: 700;
  color: #1f2937;
}

/* Stock Status Section */
.stock-status-section {
  padding: 1rem;
  background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
  border-radius: 0.75rem;
  border: 1px solid #bae6fd;
}

.stock-indicator-container {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.stock-bar {
  width: 100%;
  height: 0.75rem;
  background: #e5e7eb;
  border-radius: 0.375rem;
  overflow: hidden;
  position: relative;
}

.stock-fill {
  height: 100%;
  background: linear-gradient(90deg, #10b981, #34d399);
  border-radius: 0.375rem;
  transition: width 0.3s ease-in-out;
  position: relative;
}

.stock-fill::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% { transform: translateX(-100%); }
  100% { transform: translateX(100%); }
}

.stock-text {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.875rem;
  color: #374151;
  font-weight: 500;
}

.current-stock {
  font-weight: 700;
  color: #059669;
}

/* Dark Mode Support for Product Info Modal */
.dark .product-header {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .product-icon {
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
}

.dark .product-name {
  color: #f9fafb;
}

.dark .status-badge.in-stock {
  background: linear-gradient(135deg, #064e3b, #065f46);
  color: #6ee7b7;
  border-color: #10b981;
}

.dark .status-badge.out-of-stock {
  background: linear-gradient(135deg, #7f1d1d, #991b1b);
  color: #fca5a5;
  border-color: #ef4444;
}

.dark .status-badge.low-stock {
  background: linear-gradient(135deg, #451a03, #92400e);
  color: #fbbf24;
  border-color: #f59e0b;
}

.dark .product-description {
  background: #4b5563;
  border-left-color: #60a5fa;
}

.dark .section-title {
  color: #d1d5db;
}

.dark .product-desc {
  color: #9ca3af;
}

.dark .detail-card {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .detail-card:hover {
  border-color: #60a5fa;
  box-shadow: 0 4px 12px rgba(96, 165, 250, 0.2);
}

.dark .detail-icon {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  color: #9ca3af;
}

.dark .detail-label {
  color: #9ca3af;
}

.dark .detail-value {
  color: #f9fafb;
}

.dark .stock-status-section {
  background: linear-gradient(135deg, #1e3a8a, #1e40af);
  border-color: #3b82f6;
}

.dark .stock-bar {
  background: #4b5563;
}

.dark .stock-fill {
  background: linear-gradient(90deg, #10b981, #34d399);
}

.dark .stock-text {
  color: #d1d5db;
}

.dark .current-stock {
  color: #34d399;
}

/* Responsive Design for Product Info Modal */
@media (max-width: 768px) {
  .product-header {
    flex-direction: column;
    text-align: center;
  }
  
  .product-details-grid {
    grid-template-columns: 1fr;
  }
  
  .detail-card {
    flex-direction: column;
    text-align: center;
  }
  
  .detail-icon {
    width: 3rem;
    height: 3rem;
  }
}

/* Delete Item Modal Styles */
.modal-header.danger {
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border-bottom: 1px solid #fecaca;
}

.modal-header.danger .modal-icon {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
}

.modal-header.danger .modal-title {
  color: #991b1b;
}

.modal-header.danger .modal-subtitle {
  color: #b91c1c;
}

/* Delete Warning Container */
.delete-warning-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 1.5rem;
  padding: 1rem;
}

/* Warning Icon */
.warning-icon {
  width: 5rem;
  height: 5rem;
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ef4444;
  border: 3px solid #fecaca;
  animation: pulse-warning 2s infinite;
}

@keyframes pulse-warning {
  0%, 100% { 
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
  }
  50% { 
    transform: scale(1.05);
    box-shadow: 0 0 0 10px rgba(239, 68, 68, 0);
  }
}

/* Warning Message */
.warning-message {
  max-width: 500px;
}

.warning-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #991b1b;
  margin: 0 0 0.75rem 0;
  line-height: 1.3;
}

.warning-description {
  font-size: 0.875rem;
  color: #7f1d1d;
  line-height: 1.6;
  margin: 0;
}

/* Product Details Card */
.product-details-card {
  width: 100%;
  max-width: 400px;
  padding: 1rem;
  background: linear-gradient(135deg, #f9fafb, #f3f4f6);
  border-radius: 0.75rem;
  border: 1px solid #e5e7eb;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

/* Confirmation Checkbox */
.confirmation-checkbox {
  display: flex;
  justify-content: center;
  margin-top: 0.5rem;
}

.checkbox-container {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
  user-select: none;
  padding: 0.75rem 1rem;
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  border-radius: 0.5rem;
  border: 1px solid #fecaca;
  transition: all 0.2s ease-in-out;
}

.checkbox-container:hover {
  background: linear-gradient(135deg, #fee2e2, #fecaca);
  border-color: #f87171;
}

.checkbox-container input[type="checkbox"] {
  display: none;
}

.checkmark {
  width: 1.25rem;
  height: 1.25rem;
  background: #f3f4f6;
  border: 2px solid #d1d5db;
  border-radius: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease-in-out;
  position: relative;
}

.checkbox-container input[type="checkbox"]:checked + .checkmark {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  border-color: #dc2626;
}

.checkbox-container input[type="checkbox"]:checked + .checkmark::after {
  content: '';
  width: 0.375rem;
  height: 0.75rem;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-label {
  font-size: 0.875rem;
  font-weight: 600;
  color: #991b1b;
}

/* Danger Button */
.modal-btn-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
  border: 1px solid #dc2626;
}

.modal-btn-danger:hover:not(:disabled) {
  background: linear-gradient(135deg, #dc2626, #b91c1c);
  border-color: #b91c1c;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.4);
}

.modal-btn-danger:disabled {
  background: linear-gradient(135deg, #fca5a5, #f87171);
  border-color: #f87171;
  cursor: not-allowed;
  opacity: 0.6;
  transform: none;
  box-shadow: none;
}

/* Dark Mode Support for Delete Modal */
.dark .modal-header.danger {
  background: linear-gradient(135deg, #7f1d1d, #991b1b);
  border-bottom-color: #991b1b;
}

.dark .modal-header.danger .modal-icon {
  background: linear-gradient(135deg, #fca5a5, #f87171);
  color: #7f1d1d;
}

.dark .modal-header.danger .modal-title {
  color: #fca5a5;
}

.dark .modal-header.danger .modal-subtitle {
  color: #f87171;
}

.dark .warning-icon {
  background: linear-gradient(135deg, #7f1d1d, #991b1b);
  color: #fca5a5;
  border-color: #991b1b;
}

.dark .warning-title {
  color: #fca5a5;
}

.dark .warning-description {
  color: #f87171;
}

.dark .product-details-card {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #4b5563;
}

.dark .checkbox-container {
  background: linear-gradient(135deg, #7f1d1d, #991b1b);
  border-color: #991b1b;
}

.dark .checkbox-container:hover {
  background: linear-gradient(135deg, #991b1b, #b91c1c);
  border-color: #b91c1c;
}

.dark .checkmark {
  background: #4b5563;
  border-color: #6b7280;
}

.dark .checkbox-container input[type="checkbox"]:checked + .checkmark {
  background: linear-gradient(135deg, #fca5a5, #f87171);
  border-color: #f87171;
}

.dark .checkbox-label {
  color: #fca5a5;
}

/* Responsive Design for Delete Modal */
@media (max-width: 768px) {
  .delete-warning-container {
    padding: 0.5rem;
  }
  
  .warning-icon {
    width: 4rem;
    height: 4rem;
  }
  
  .warning-title {
    font-size: 1.125rem;
  }
  
  .product-details-card {
    max-width: 100%;
  }
  
  .checkbox-container {
    padding: 0.5rem 0.75rem;
  }
}

/* CSS for button to open/close the sidebar */
#sidebar-toggle {
  cursor: pointer;
  display: block;
  padding: 0.5rem;
  border-radius: 0.5rem;
  background: none;
  border: none;
  color: #6b7280;
  transition: all 0.2s ease-in-out;
  margin-right: 1rem;
  min-width: 2.5rem;
  min-height: 2.5rem;
  flex-shrink: 0;
}

#sidebar-toggle:hover {
  background-color: #f3f4f6;
  color: #374151;
}

#sidebar-toggle svg {
  display: block;
  width: 24px;
  height: 24px;
}

/* Dark mode support for toggle button */
.dark #sidebar-toggle {
  color: #9ca3af;
}

.dark #sidebar-toggle:hover {
  background-color: #374151;
  color: #d1d5db;
}

/* Hide toggle button on desktop */
@media (min-width: 768px) {
  #sidebar-toggle {
    display: none;
  }
}

/* CSS for open and shift classes - Updated for modern design */
#sidebar.open {
  left: 0; /* Show the sidebar on mobile */
}

#main-content.shift {
  margin-left: 0; /* Reset margin on mobile when sidebar is open */
}

/* Mobile overlay */
#mobile-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  z-index: 30;
  display: none;
}

#mobile-overlay.show {
  display: block;
}
#sidebar-content a {
  text-align: left;
  text-decoration: none;
  /* font-size: 19px; */
  /* color: var(--pri-text); */
}
#sidebar-content ul {
  align-items: start;
  justify-content: start;
  list-style: none;
}
#sidebar-togglex {
  display: none;
}
.odd {
  background: white !important;
}
.add_cat_model {
  position: fixed;
  top: 0;
  background: #00000064;
  height: 100vh;
  display: flex;
  align-items: center;
}
.inner_add_cat_model {
  position: relative;
  top: 50px;
  /* left: 15%; */
  background: var(--white);
  box-shadow: 0px 4px 5px #000000a1;
  animation: modelIn 600ms;
}
.edit_cat_model {
  position: fixed;
  top: 0;
  background: #00000064;
  height: 100vh;
  display: flex;
  align-items: center;
}
.inner_edit_cat_model {
  position: relative;
  top: 50px;
  /* left: 15%; */
  background: var(--white);
  box-shadow: 0px 4px 5px #000000a1;
  animation: modelIn 600ms;
}
.delete_cat_model {
  position: fixed;
  top: 0;
  background: #00000064;
  height: 100vh;
  display: flex;
  align-items: center;
}
.inner_delete_cat_model {
  position: relative;
  top: 50px;
  /* left: 15%; */
  background: var(--white);
  box-shadow: 0px 4px 5px #000000a1;
  animation: modelIn 600ms;
}
.add_item_model {
  position: fixed;
  top: 0;
  background: #00000064;
  height: 100vh;
  display: flex;
  align-items: center;
}
.inner_add_item_model {
  position: relative;
  top: 20px;
  /* left: 15%; */
  background: var(--white);
  box-shadow: 0px 4px 5px #000000a1;
  animation: modelIn 600ms;
}
.add_to_item_model {
  position: fixed;
  top: 0;
  background: #00000064;
  height: 100vh;
  display: flex;
  align-items: center;
}
.inner_add_to_item_model {
  position: relative;
  top: 50px;
  /* left: 15%; */
  background: var(--white);
  box-shadow: 0px 4px 5px #000000a1;
  animation: modelIn 600ms;
}
.selectItem_model {
  position: fixed;
  top: 0;
  background: #6e928b64;
  height: 100vh;
  display: flex;
  width: 100%;
  align-items: center;
}
.inner_selectItem_model {
  position: relative;
  top: 50px;
  /* left: -7%; */

  background: var(--white);
  box-shadow: 0px 2px 5px #00347897;
  animation: modelIn 600ms;
}
.completeSaleModel {
  position: fixed;
  top: 0;
  background: #6e928b64;
  height: 100vh;
  display: flex;
  width: 100%;
  align-items: center;
}
.innerCompleteSaleModel {
  position: relative;
  top: 50px;
  /* left: -7%; */

  background: var(--white);
  box-shadow: 0px 2px 5px #00347897;
  animation: modelIn 600ms;
}

@keyframes modelIn {
  0% {
    top: 0;
  }
}

/* CSS for drop-down menu */

/* Media query for mobile devices */
@media screen and (max-width: 768px) {
  #sidebar-togglex {
    display: block;
    cursor: pointer;
  }
  #sidebar {
    width: 100%; /* Occupy full width */
    left: -100%; /* Hide the sidebar initially */
    transition: left 0.3s ease-in-out; /* Smooth transition animation */
  }

  #main-content.shift {
    margin-left: 0; /* Remove margin for main content */
  }

  #sidebar.open {
    left: 0; /* Show the sidebar */
  }
}

.finalizingSale {
  animation: fromDown 600ms;
}

@keyframes fromDown {
  0% {
    margin-top: 20px;
  }
}
.sales_dashboard_wraper {
  display: grid;
  grid-template-columns: 15% 64% 19%;
  grid-gap: 10px;
}
.sales_dashboard_wraperx {
  display: grid;
  grid-template-columns: 15% 85%;
  grid-gap: 10px !important;
}

#makeSale {
  padding: 13px;
  font-size: 1.4rem;
  align-items: center;
  text-align: center;
  font-weight: 600;
  cursor: pointer;
  border-radius: 5px;
  font-family: var(--font-four);
  background-image: linear-gradient(to top, var(--pri-color), var(--sec-color));
}
.saleBtn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: white;
  background: linear-gradient(135deg, #3b82f6, #1d4ed8);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
  position: relative;
  overflow: hidden;
  font-family: var(--font-one);
  min-width: 120px;
}
#makeSale:hover {
  background-image: linear-gradient(to top, var(--sec-color), var(--sec-color));
}
.saleBtn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s;
}

.saleBtn:hover {
  background: linear-gradient(135deg, #2563eb, #1e40af);
  transform: translateY(-2px);
  box-shadow: 0 8px 15px -3px rgba(59, 130, 246, 0.4);
  color: white;
  text-decoration: none;
}

.saleBtn:hover::before {
  left: 100%;
}

.saleBtn:active {
  transform: translateY(0);
  box-shadow: 0 4px 6px -1px rgba(59, 130, 246, 0.3);
}

.saleBtn::after {
  content: '🛒';
  font-size: 1rem;
  margin-left: 0.25rem;
}

/* Dark mode support for sale button */
.dark .saleBtn {
  background: linear-gradient(135deg, #1e40af, #1e3a8a);
  box-shadow: 0 4px 6px -1px rgba(30, 64, 175, 0.3);
}

.dark .saleBtn:hover {
  background: linear-gradient(135deg, #1d4ed8, #1e40af);
  box-shadow: 0 8px 15px -3px rgba(30, 64, 175, 0.4);
}

/* Responsive design for sale button */
@media (max-width: 768px) {
  .saleBtn {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
    min-width: 100px;
  }
  
  .saleBtn::after {
    font-size: 0.875rem;
  }
}

@media (max-width: 480px) {
  .saleBtn {
    padding: 0.5rem 0.75rem;
    font-size: 0.7rem;
    min-width: 80px;
  }
  
  .saleBtn::after {
    font-size: 0.75rem;
  }
}
.linearBg:hover {
  background-image: linear-gradient(to top, var(--sec-color), var(--sec-color));
}
.linearBg{
  padding: 0;
  font-size: 1rem;
  align-items: center;
  text-align: center;
  /* font-weight: 600; */
  cursor: pointer;
  border-radius: 5px;
  font-family: var(--font-four);
  background-image: linear-gradient(to top, var(--pri-color), var(--sec-color));
}
#notfyBtn {
  font-size: 1.4rem;
  margin-right: 20px;
}

#notifyContainer {
  display: none;
  position: absolute;
  background-color: #f9f9f9;
  box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
  padding: 12px;
  /* margin-top: 20px; */
}

#notifyContainer a {
  display: block;
  text-decoration: none;
  /* color: #333; */
  padding: 8px;
}

#notifyContainer a:hover {
  background-color: #ddd;
}

/* styles.css */
/* Profile Button Styling */
#profileBtn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: linear-gradient(135deg, #f8fafc, #e2e8f0);
  border: 1px solid #d1d5db;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  font-weight: 500;
  color: #374151;
  text-decoration: none;
  min-width: 120px;
  justify-content: center;
}

#profileBtn:hover {
  background: linear-gradient(135deg, #e2e8f0, #d1d5db);
  transform: translateY(-1px);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  color: #1f2937;
  text-decoration: none;
}

#profileBtn .fa-user {
  font-size: 1.1rem;
  color: #6b7280;
  transition: color 0.3s ease;
}

#profileBtn:hover .fa-user {
  color: #374151;
}

/* Profile Dropdown Styling */
#profileDropDown {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background: white;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  padding: 0.5rem;
  min-width: 200px;
  z-index: 50;
  margin-top: 0.5rem;
  animation: dropdownSlideIn 0.2s ease-out;
}

@keyframes dropdownSlideIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#profileDropDown a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  text-decoration: none;
  color: #374151;
  border-radius: 8px;
  transition: all 0.2s ease;
  font-weight: 500;
  font-size: 0.875rem;
}

#profileDropDown a:hover {
  background: linear-gradient(135deg, #f3f4f6, #e5e7eb);
  color: #1f2937;
  transform: translateX(4px);
}

#profileDropDown a i {
  width: 16px;
  text-align: center;
  color: #6b7280;
  transition: color 0.2s ease;
}

#profileDropDown a:hover i {
  color: #374151;
}

/* Dark mode support for profile section */
.dark #profileBtn {
  background: linear-gradient(135deg, #374151, #4b5563);
  border-color: #6b7280;
  color: #f9fafb;
}

.dark #profileBtn:hover {
  background: linear-gradient(135deg, #4b5563, #6b7280);
  color: #ffffff;
}

.dark #profileBtn .fa-user {
  color: #9ca3af;
}

.dark #profileBtn:hover .fa-user {
  color: #d1d5db;
}

.dark #profileDropDown {
  background: #1f2937;
  border-color: #374151;
}

.dark #profileDropDown a {
  color: #d1d5db;
}

.dark #profileDropDown a:hover {
  background: linear-gradient(135deg, #374151, #4b5563);
  color: #f9fafb;
}

.dark #profileDropDown a i {
  color: #9ca3af;
}

.dark #profileDropDown a:hover i {
  color: #d1d5db;
}

/* Additional utility classes for profile section */
.theme-text {
  color: #374151;
  transition: color 0.3s ease;
}

.pointer {
  cursor: pointer;
}

.theme-text-c {
  color: #374151;
  transition: color 0.3s ease;
}

.w-500 {
  font-weight: 500;
}

/* Responsive design for profile section */
@media (max-width: 768px) {
  #profileBtn {
    padding: 0.5rem 0.75rem;
    min-width: 100px;
    font-size: 0.875rem;
  }
  
  #profileDropDown {
    min-width: 180px;
    right: -0.5rem;
  }
  
  #profileDropDown a {
    padding: 0.625rem 0.75rem;
    font-size: 0.8rem;
  }
}
.alert-circle{
  color: red;
  font-size: 12px;
  position: relative !important;
  margin-top: -25px !important;

}
.siteHL{
  font-size: 18px;
}
.siteHL img{
  width: 100px;
  
}
.enlarge{
  font-size: 1.5rem;
}
#subLinks a{
  padding-left: 20px;
}
#newSchedules{
  overflow-y: scroll;
  height: fit-content;
  max-height: 60vh;
  scroll-behavior: smooth;
}
.balFigure{
  font-size: 1.4rem;
}

/* Invoice Details Modal Styles */
.large-modal {
    max-width: 900px;
    width: 95%;
}

.invoice-details-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.invoice-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    border-radius: 12px;
    color: white;
}

.invoice-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.invoice-number {
    font-size: 2rem;
    font-weight: 700;
    margin: 0;
}

.invoice-date {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.25rem;
}

.date-label {
    font-size: 0.875rem;
    opacity: 0.8;
}

.date-value {
    font-size: 1.125rem;
    font-weight: 600;
}

.customer-section,
.financial-section,
.items-section,
.payments-section {
    background: #f8fafc;
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
}

.dark .customer-section,
.dark .financial-section,
.dark .items-section,
.dark .payments-section {
    background: #1f2937;
    border-color: #374151;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 600;
    margin: 0 0 1.5rem 0;
    color: #1f2937;
}

.dark .section-title {
    color: #f9fafb;
}

.customer-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.financial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.financial-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    transition: all 0.2s ease;
}

.financial-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.dark .financial-card {
    background: #374151;
    border-color: #4b5563;
}

.financial-card.outstanding {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-color: #f59e0b;
}

.dark .financial-card.outstanding {
    background: linear-gradient(135deg, #451a03, #78350f);
    border-color: #d97706;
}

.card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    background: #f1f5f9;
    border-radius: 8px;
    color: #64748b;
}

.dark .card-icon {
    background: #4b5563;
    color: #9ca3af;
}

.financial-card.outstanding .card-icon {
    background: #fbbf24;
    color: #92400e;
}

.dark .financial-card.outstanding .card-icon {
    background: #d97706;
    color: #451a03;
}

.card-content {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.card-label {
    font-size: 0.875rem;
    color: #64748b;
    font-weight: 500;
}

.dark .card-label {
    color: #9ca3af;
}

.card-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1f2937;
}

.dark .card-value {
    color: #f9fafb;
}

.financial-card.outstanding .card-value {
    color: #92400e;
}

.dark .financial-card.outstanding .card-value {
    color: #fbbf24;
}

.items-table-container {
    overflow-x: auto;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.dark .items-table-container {
    border-color: #4b5563;
}

.items-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.dark .items-table {
    background: #374151;
}

.items-table th {
    background: #f8fafc;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: #374151;
    border-bottom: 1px solid #e2e8f0;
}

.dark .items-table th {
    background: #4b5563;
    color: #f9fafb;
    border-color: #6b7280;
}

.items-table td {
    padding: 1rem;
    border-bottom: 1px solid #e2e8f0;
    color: #64748b;
}

.dark .items-table td {
    border-color: #4b5563;
    color: #d1d5db;
}

.items-table tr:last-child td {
    border-bottom: none;
}

.payments-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.payment-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: white;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.dark .payment-item {
    background: #374151;
    border-color: #4b5563;
}

.payment-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.payment-method {
    font-weight: 600;
    color: #1f2937;
}

.dark .payment-method {
    color: #f9fafb;
}

.payment-date {
    font-size: 0.875rem;
    color: #64748b;
}

.dark .payment-date {
    color: #9ca3af;
}

.payment-amount {
    font-size: 1.125rem;
    font-weight: 700;
    color: #059669;
}

.dark .payment-amount {
    color: #10b981;
}

.status-badge.outstanding {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #f59e0b;
}

.dark .status-badge.outstanding {
    background: #451a03;
    color: #fbbf24;
    border-color: #d97706;
}

/* Add Payment Modal Styles */
.payment-summary {
    background: #f8fafc;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    border: 1px solid #e2e8f0;
}

.dark .payment-summary {
    background: #1f2937;
    border-color: #374151;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.summary-row:last-child {
    margin-bottom: 0;
}

.summary-label {
    font-weight: 500;
    color: #64748b;
}

.dark .summary-label {
    color: #9ca3af;
}

.summary-value {
    font-weight: 600;
    color: #1f2937;
}

.dark .summary-value {
    color: #f9fafb;
}

.outstanding-amount {
    color: #dc2626;
    font-weight: 700;
}

.dark .outstanding-amount {
    color: #f87171;
}

.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 12px;
    color: #64748b;
    pointer-events: none;
}

.dark .input-icon {
    color: #9ca3af;
}

.input-with-icon .form-input {
    padding-left: 40px;
}

.payment-preview {
    background: #f0f9ff;
    border: 1px solid #0ea5e9;
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
}

.dark .payment-preview {
    background: #0c4a6e;
    border-color: #0284c7;
}

.preview-title {
    font-size: 1rem;
    font-weight: 600;
    margin: 0 0 0.75rem 0;
    color: #0c4a6e;
}

.dark .preview-title {
    color: #7dd3fc;
}

.preview-details {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.preview-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.preview-label {
    font-weight: 500;
    color: #0369a1;
}

.dark .preview-label {
    color: #bae6fd;
}

.preview-value {
    font-weight: 600;
    color: #0c4a6e;
}

.dark .preview-value {
    color: #7dd3fc;
}

.modal-btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: 1px solid #059669;
}

.modal-btn-success:hover {
    background: linear-gradient(135deg, #059669, #047857);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.dark .modal-btn-success {
    background: linear-gradient(135deg, #059669, #047857);
    border-color: #047857;
}

.dark .modal-btn-success:hover {
    background: linear-gradient(135deg, #047857, #065f46);
}

/* Form Section Styles */
.form-section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
}

.dark .form-section {
    background: #1f2937;
    border-color: #374151;
}

.form-section:last-child {
    margin-bottom: 0;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.125rem;
    font-weight: 600;
    margin: 0 0 1.5rem 0;
    color: #1f2937;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid #e2e8f0;
}

.dark .section-title {
    color: #f9fafb;
    border-color: #374151;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-grid:last-child {
    margin-bottom: 0;
}

/* Radio Group Styles */
.radio-group {
    margin-bottom: 1rem;
}

.radio-label {
    display: block;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.75rem;
}

.dark .radio-label {
    color: #d1d5db;
}

.radio-options {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    margin-top: 0.5rem;
}

.radio-custom {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    cursor: pointer;
    padding: 0.75rem 1rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    min-width: 120px;
    justify-content: center;
}

.dark .radio-custom {
    background: #1f2937;
    border-color: #374151;
}

.radio-custom:hover {
    background: #f1f5f9;
    border-color: #3b82f6;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    color: #3b82f6;
}

.dark .radio-custom:hover {
    background: #374151;
    border-color: #60a5fa;
    color: #60a5fa;
}

.radio-custom input[type="radio"]:checked + .radio-checkmark {
    border-color: #3b82f6;
    background: #3b82f6;
}

.dark .radio-custom input[type="radio"]:checked + .radio-checkmark {
    border-color: #60a5fa;
    background: #60a5fa;
}

.radio-custom input[type="radio"]:checked ~ .radio-text {
    color: #3b82f6;
    font-weight: 600;
}

.dark .radio-custom input[type="radio"]:checked ~ .radio-text {
    color: #60a5fa;
}

/* Selected radio button styling */
.radio-custom:has(input[type="radio"]:checked) {
    background: #eff6ff;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.dark .radio-custom:has(input[type="radio"]:checked) {
    background: #1e3a8a;
    border-color: #60a5fa;
    box-shadow: 0 0 0 3px rgba(96, 165, 250, 0.1);
}

.radio-custom input[type="radio"] {
    display: none;
}

.radio-checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid #d1d5db;
    border-radius: 50%;
    position: relative;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.dark .radio-checkmark {
    border-color: #6b7280;
}

.radio-custom input[type="radio"]:checked + .radio-checkmark {
    border-color: #3b82f6;
    background: #3b82f6;
}

.dark .radio-custom input[type="radio"]:checked + .radio-checkmark {
    border-color: #60a5fa;
    background: #60a5fa;
}

.radio-custom input[type="radio"]:checked + .radio-checkmark::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    transform: translate(-50%, -50%);
}

.radio-text {
    font-weight: 500;
    color: #374151;
    transition: color 0.2s ease;
}

.dark .radio-text {
    color: #d1d5db;
}

.radio-custom input[type="radio"]:checked ~ .radio-text {
    color: #3b82f6;
    font-weight: 600;
}

.dark .radio-custom input[type="radio"]:checked ~ .radio-text {
    color: #60a5fa;
}

/* Readonly Input Styles */
.form-input.readonly {
    background: #f3f4f6;
    color: #6b7280;
    cursor: not-allowed;
    border-color: #d1d5db;
}

.dark .form-input.readonly {
    background: #374151;
    color: #9ca3af;
    border-color: #4b5563;
}

/* Form Help Text */
.form-help {
    font-size: 0.875rem;
    color: #6b7280;
    margin-top: 0.5rem;
    font-style: italic;
}

.dark .form-help {
    color: #9ca3af;
}

/* Large Modal */
.large-modal {
    max-width: 800px;
    width: 95%;
}

/* Summary Cards Section */
.summary-cards-section {
    margin-bottom: 2rem;
}

.summary-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.summary-card {
    background: white;
    border-radius: 16px;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.dark .summary-card {
    background: #1f2937;
    border-color: #374151;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.summary-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.dark .summary-card:hover {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.summary-card .card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.summary-card .card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: #f1f5f9;
    color: #64748b;
    flex-shrink: 0;
}

.dark .summary-card .card-icon {
    background: #374151;
    color: #9ca3af;
}

.summary-card .card-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1f2937;
    margin: 0;
}

.dark .summary-card .card-title {
    color: #f9fafb;
}

.summary-card .card-subtitle {
    font-size: 0.875rem;
    color: #64748b;
    margin: 0;
}

.dark .summary-card .card-subtitle {
    color: #9ca3af;
}

.summary-card .card-body {
    margin-bottom: 1rem;
}

.summary-card .card-value {
    font-size: 2rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 0.5rem;
    line-height: 1;
}

.dark .summary-card .card-value {
    color: #f9fafb;
}

.summary-card .card-trend {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #64748b;
}

.dark .summary-card .card-trend {
    color: #9ca3af;
}

.summary-card .card-action {
    margin-top: auto;
}

/* Card Variants */
.summary-card.outstanding {
    border-left: 4px solid #f59e0b;
}

.summary-card.outstanding .card-icon {
    background: #fef3c7;
    color: #92400e;
}

.dark .summary-card.outstanding .card-icon {
    background: #451a03;
    color: #fbbf24;
}

.summary-card.outstanding .card-value {
    color: #f59e0b;
}

.dark .summary-card.outstanding .card-value {
    color: #fbbf24;
}

.summary-card.success {
    border-left: 4px solid #10b981;
}

.summary-card.success .card-icon {
    background: #d1fae5;
    color: #059669;
}

.dark .summary-card.success .card-icon {
    background: #064e3b;
    color: #10b981;
}

.summary-card.success .card-value {
    color: #10b981;
}

.dark .summary-card.success .card-value {
    color: #10b981;
}

.summary-card.revenue {
    border-left: 4px solid #3b82f6;
}

.summary-card.revenue .card-icon {
    background: #dbeafe;
    color: #2563eb;
}

.dark .summary-card.revenue .card-icon {
    background: #1e3a8a;
    color: #60a5fa;
}

.summary-card.revenue .card-value {
    color: #3b82f6;
}

.dark .summary-card.revenue .card-value {
    color: #60a5fa;
}

/* Action Button */
.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.action-btn-primary {
    background: #3b82f6;
    color: white;
    border-color: #3b82f6;
}

.action-btn-primary:hover {
    background: #2563eb;
    border-color: #2563eb;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.dark .action-btn-primary {
    background: #1d4ed8;
    border-color: #1d4ed8;
}

.dark .action-btn-primary:hover {
    background: #1e40af;
    border-color: #1e40af;
}

/* Responsive Design */
@media (max-width: 768px) {
    .summary-cards-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .summary-card {
        padding: 1rem;
    }
    
    .summary-card .card-value {
        font-size: 1.5rem;
    }
}

/* Expense Modal Styles */
.expense-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: #374151;
    font-size: 0.875rem;
}

.input-label svg {
    width: 16px;
    height: 16px;
    color: #6b7280;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    transition: all 0.2s ease;
    background: #ffffff;
}

.form-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.form-input::placeholder {
    color: #9ca3af;
}

/* Dark mode for expense modals */
[data-theme="dark"] .input-label {
    color: #f1f5f9;
}

[data-theme="dark"] .input-label svg {
    color: #94a3b8;
}

[data-theme="dark"] .form-input {
    background: #1e293b;
    border-color: #334155;
    color: #f1f5f9;
}

[data-theme="dark"] .form-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

[data-theme="dark"] .form-input::placeholder {
    color: #64748b;
}

/* Financial Dashboard Styles */
.financial-dashboard {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    margin-bottom: 2rem;
}

.primary-metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.financial-card {
    background: #ffffff;
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.financial-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

.financial-card .card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.financial-card .card-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    flex-shrink: 0;
}

.financial-card .card-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.financial-card .card-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

.financial-card .card-body {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.financial-card .card-value {
    font-size: 2rem;
    font-weight: 700;
    color: #111827;
    line-height: 1;
}

.financial-card .card-trend {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.financial-card .card-trend.positive {
    color: #059669;
}

.financial-card .card-trend.warning {
    color: #d97706;
}

.financial-card .card-trend svg {
    width: 1rem;
    height: 1rem;
}

/* Financial Card Variants */
.revenue-card .card-icon {
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
}

.profit-card .card-icon {
    background: linear-gradient(135deg, #10b981, #059669);
}

.items-card .card-icon {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
}

.outstanding-card .card-icon {
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

/* Secondary Metrics Grid */
.secondary-metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.metric-card {
    background: #ffffff;
    border-radius: 0.75rem;
    padding: 1.25rem;
    box-shadow: 0 2px 4px -1px rgba(0, 0, 0, 0.06), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    transition: all 0.2s ease;
}

.metric-card:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.metric-card .metric-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.metric-card .metric-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    flex-shrink: 0;
}

.metric-card .metric-info {
    flex: 1;
}

.metric-card .metric-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #6b7280;
    margin: 0;
}

.metric-card .metric-value {
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.metric-card .metric-description {
    font-size: 0.75rem;
    color: #9ca3af;
    margin: 0;
}

/* Financial Health Section */
.financial-health-section {
    background: #ffffff;
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border: 1px solid #e5e7eb;
}

.health-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.health-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.health-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border-radius: 2rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.health-status.positive {
    background: #d1fae5;
    color: #065f46;
}

.health-metrics {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.health-metric {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.health-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    min-width: 120px;
}

.health-bar {
    flex: 1;
    height: 0.5rem;
    background: #e5e7eb;
    border-radius: 0.25rem;
    overflow: hidden;
}

.health-fill {
    height: 100%;
    background: linear-gradient(90deg, #10b981, #059669);
    border-radius: 0.25rem;
    transition: width 0.3s ease;
}

.health-value {
    font-size: 0.875rem;
    font-weight: 600;
    color: #111827;
    min-width: 3rem;
    text-align: right;
}

/* Dark mode support for financial dashboard */
[data-theme="dark"] .financial-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .financial-card .card-title {
    color: #f1f5f9;
}

[data-theme="dark"] .financial-card .card-subtitle {
    color: #94a3b8;
}

[data-theme="dark"] .financial-card .card-value {
    color: #f1f5f9;
}

[data-theme="dark"] .metric-card {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .metric-card .metric-label {
    color: #94a3b8;
}

[data-theme="dark"] .metric-card .metric-value {
    color: #f1f5f9;
}

[data-theme="dark"] .metric-card .metric-description {
    color: #64748b;
}

[data-theme="dark"] .financial-health-section {
    background: #1e293b;
    border-color: #334155;
}

[data-theme="dark"] .health-title {
    color: #f1f5f9;
}

[data-theme="dark"] .health-label {
    color: #cbd5e1;
}

[data-theme="dark"] .health-value {
    color: #f1f5f9;
}

[data-theme="dark"] .health-bar {
    background: #334155;
}

/* Responsive design */
@media (max-width: 768px) {
    .primary-metrics-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .secondary-metrics-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .financial-card {
        padding: 1rem;
    }
    
    .financial-card .card-value {
        font-size: 1.5rem;
    }
    
    .health-metric {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .health-label {
        min-width: auto;
    }
    
    .health-value {
        min-width: auto;
        text-align: left;
    }
}

/* Statistics Page Styles */
.filter-section {
    margin-bottom: 2rem;
}

.filter-card {
    background: #ffffff;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    overflow: hidden;
}

.dark .filter-card {
    background: #1f2937;
    border-color: #374151;
}

.filter-header {
    padding: 1.5rem 1.5rem 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.dark .filter-header {
    border-bottom-color: #374151;
}

.filter-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.dark .filter-title {
    color: #f9fafb;
}

.filter-body {
    padding: 1.5rem;
}

.filter-form {
    width: 100%;
}

.filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    align-items: end;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
}

.dark .filter-group label {
    color: #d1d5db;
}

.filter-select,
.filter-input {
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    background: #ffffff;
    color: #111827;
    transition: all 0.2s;
}

.dark .filter-select,
.dark .filter-input {
    background: #374151;
    border-color: #4b5563;
    color: #f9fafb;
}

.filter-select:focus,
.filter-input:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.filter-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: #3b82f6;
    color: #ffffff;
    border: none;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    height: fit-content;
}

.filter-btn:hover {
    background: #2563eb;
}

/* Stats Overview */
.stats-overview {
    margin-bottom: 2rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.stat-card {
    background: #ffffff;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    overflow: hidden;
    transition: all 0.2s;
}

.dark .stat-card {
    background: #1f2937;
    border-color: #374151;
}

.stat-card:hover {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.stat-card .card-header {
    padding: 1.5rem 1.5rem 1rem;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.stat-card .card-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-card.revenue .card-icon {
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
}

.stat-card.profit .card-icon {
    background: rgba(16, 185, 129, 0.1);
    color: #10b981;
}

.stat-card.outstanding .card-icon {
    background: rgba(245, 158, 11, 0.1);
    color: #f59e0b;
}

.stat-card.customers .card-icon {
    background: rgba(139, 92, 246, 0.1);
    color: #8b5cf6;
}

.stat-card .card-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0 0 0.25rem 0;
}

.dark .stat-card .card-title {
    color: #f9fafb;
}

.stat-card .card-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

.dark .stat-card .card-subtitle {
    color: #9ca3af;
}

.stat-card .card-body {
    padding: 0 1.5rem 1.5rem;
}

.stat-card .card-value {
    font-size: 2rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 0.5rem;
}

.dark .stat-card .card-value {
    color: #f9fafb;
}

.stat-card .card-trend {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    color: #6b7280;
}

.dark .stat-card .card-trend {
    color: #9ca3af;
}

/* Charts Section */
.charts-section {
    margin-bottom: 2rem;
}

.charts-grid {
  width: 100% !important;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.chart-card {
  width: 100% !important;
    background: #ffffff;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    overflow: hidden;
}

.dark .chart-card {
    background: #1f2937;
    border-color: #374151;
}

.chart-header {
    padding: 1.5rem 1.5rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e5e7eb;
}

.dark .chart-header {
    border-bottom-color: #374151;
}

.chart-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.dark .chart-title {
    color: #f9fafb;
}

.chart-controls {
    display: flex;
    gap: 0.5rem;
}

.chart-select {
    padding: 0.5rem 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    font-size: 0.875rem;
    background: #ffffff;
    color: #111827;
}

.dark .chart-select {
    background: #374151;
    border-color: #4b5563;
    color: #f9fafb;
}

.chart-body {
    padding: 1.5rem;
    height: 300px;
    position: relative;
}

/* Tables Section */
.tables-section {
    margin-bottom: 2rem;
}

.tables-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(500px, 1fr));
    gap: 1.5rem;
}

.table-card {
    background: #ffffff;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    overflow: hidden;
}

.dark .table-card {
    background: #1f2937;
    border-color: #374151;
}

.table-header {
    padding: 1.5rem 1.5rem 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.dark .table-header {
    border-bottom-color: #374151;
}

.table-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0 0 0.25rem 0;
}

.dark .table-title {
    color: #f9fafb;
}

.table-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

.dark .table-subtitle {
    color: #9ca3af;
}

.table-body {
    padding: 0;
}

.table-container {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    background: #f9fafb;
    padding: 0.75rem 1rem;
    text-align: left;
    font-size: 0.875rem;
    font-weight: 600;
    color: #374151;
    border-bottom: 1px solid #e5e7eb;
}

.dark .data-table th {
    background: #374151;
    color: #d1d5db;
    border-bottom-color: #4b5563;
}

.data-table td {
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    color: #111827;
    border-bottom: 1px solid #e5e7eb;
}

.dark .data-table td {
    color: #f9fafb;
    border-bottom-color: #374151;
}

.data-table tr:hover {
    background: #f9fafb;
}

.dark .data-table tr:hover {
    background: #374151;
}

.profit-cell {
    color: #10b981;
    font-weight: 600;
}

.text-center {
    text-align: center;
}

.font-medium {
    font-weight: 500;
}

/* Inventory Section */
.inventory-section {
    margin-bottom: 2rem;
}

.inventory-card {
    background: #ffffff;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e5e7eb;
    overflow: hidden;
}

.dark .inventory-card {
    background: #1f2937;
    border-color: #374151;
}

.inventory-header {
    padding: 1.5rem 1.5rem 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.dark .inventory-header {
    border-bottom-color: #374151;
}

.inventory-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0 0 0.25rem 0;
}

.dark .inventory-title {
    color: #f9fafb;
}

.inventory-subtitle {
    font-size: 0.875rem;
    color: #6b7280;
    margin: 0;
}

.dark .inventory-subtitle {
    color: #9ca3af;
}

.inventory-body {
    padding: 1.5rem;
}

.inventory-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.inventory-stat {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: #f9fafb;
    border-radius: 0.5rem;
    border: 1px solid #e5e7eb;
}

.dark .inventory-stat {
    background: #374151;
    border-color: #4b5563;
}

.inventory-stat.warning {
    background: rgba(245, 158, 11, 0.1);
    border-color: #f59e0b;
}

.dark .inventory-stat.warning {
    background: rgba(245, 158, 11, 0.2);
}

.stat-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(59, 130, 246, 0.1);
    color: #3b82f6;
    flex-shrink: 0;
}

.inventory-stat.warning .stat-icon {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

.stat-content {
    flex: 1;
}

.stat-label {
    font-size: 0.875rem;
    color: #6b7280;
    margin-bottom: 0.25rem;
}

.dark .stat-label {
    color: #9ca3af;
}

.stat-value {
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
}

.dark .stat-value {
    color: #f9fafb;
}

/* Statistics Responsive Design */
@media (max-width: 768px) {
    .filter-row {
        grid-template-columns: 1fr;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .charts-grid {
        grid-template-columns: 1fr !important;
    }
    
    .tables-grid {
        grid-template-columns: 1fr;
    }
    
    .inventory-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .chart-body {
        height: 250px;
    }
}

@media (max-width: 640px) {
    .filter-card,
    .stat-card,
    .chart-card,
    .table-card,
    .inventory-card {      
        margin: 0 -1rem;   
        border-radius: 0;  
        border-left: none; 
        border-right: none;
    }
    
    .inventory-grid {      
        grid-template-columns: 1fr;
    }
}

/* Customer Details Modal Styles */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal-content {
    background: white;
    border-radius: 12px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.5rem;
    border-bottom: 1px solid #e5e7eb;
    background: #f9fafb;
}

.modal-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.25rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
}

.modal-close {
    background: none;
    border: none;
    padding: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
    color: #6b7280;
    transition: all 0.2s;
}

.modal-close:hover {
    background: #f3f4f6;
    color: #374151;
}

.modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
}

.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1.5rem;
    border-top: 1px solid #e5e7eb;
    background: #f9fafb;
}

/* Customer Info Sections */
.customer-info-section,
.invoices-section,
.sales-history-section {
    margin-bottom: 2rem;
}

.section-header {
    margin-bottom: 1rem;
}

.section-header h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #111827;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-header h4::before {
    content: '';
    width: 4px;
    height: 20px;
    background: #3b82f6;
    border-radius: 2px;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.info-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.info-item label {
    font-size: 0.875rem;
    font-weight: 500;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.info-item span {
    font-size: 1rem;
    font-weight: 600;
    color: #111827;
}

/* Modal Tables */
.modal-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.875rem;
}

.modal-table th {
    background: #f8fafc;
    padding: 0.75rem;
    text-align: left;
    font-weight: 600;
    color: #374151;
    border-bottom: 1px solid #e5e7eb;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.modal-table td {
    padding: 0.75rem;
    border-bottom: 1px solid #f3f4f6;
    color: #4b5563;
}

.modal-table tr:hover {
    background: #f9fafb;
}

/* Status Badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-paid {
    background: #dcfce7;
    color: #166534;
}

.status-outstanding {
    background: #fef3c7;
    color: #92400e;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    font-weight: 500;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.875rem;
}

.btn-secondary {
    background: #f3f4f6;
    color: #374151;
    border: 1px solid #d1d5db;
}

.btn-secondary:hover {
    background: #e5e7eb;
    border-color: #9ca3af;
}

.btn-primary {
    background: #3b82f6;
    color: white;
}

.btn-primary:hover {
    background: #2563eb;
}

/* Dark mode support for modal */
.dark .modal-content {
    background: #1f2937;
    border-color: #374151;
}

.dark .modal-header,
.dark .modal-footer {
    background: #111827;
    border-color: #374151;
}

.dark .modal-title {
    color: #f9fafb;
}

.dark .modal-close {
    color: #9ca3af;
}

.dark .modal-close:hover {
    background: #374151;
    color: #d1d5db;
}

.dark .info-grid {
    background: #111827;
    border-color: #374151;
}

.dark .info-item label {
    color: #9ca3af;
}

.dark .info-item span {
    color: #f9fafb;
}

.dark .modal-table th {
    background: #111827;
    color: #d1d5db;
    border-color: #374151;
}

.dark .modal-table td {
    color: #d1d5db;
    border-color: #374151;
}

.dark .modal-table tr:hover {
    background: #1f2937;
}

.dark .section-header h4 {
    color: #f9fafb;
}

/* Responsive modal */
@media (max-width: 768px) {
    .modal {
        padding: 0.5rem;
    }
    
    .modal-content {
        max-height: 95vh;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding: 1rem;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
        padding: 1rem;
    }
    
    .modal-table {
        font-size: 0.75rem;
    }
    
    .modal-table th,
    .modal-table td {
        padding: 0.5rem;
    }
}

