@import url("https://fonts.googleapis.com/css2?family=Inter:wght@100..900&display=swap");

/* === GLOBAL VARIABLES === */
:root {
  /* Colors */
  --color-primary: #487FFF;
  --color-primary-active: #3b6fd9;
  --color-primary-light: #E4F1FF;
  --color-primary-bg: #EFF6FF;

  --color-purple: #8252E9;
  --color-purple-light: #F0E1FF;
  --color-purple-bg: #F5F3FF;

  --color-orange: #FF9F29;
  --color-orange-active: #ea580c;
  --color-orange-dark: #c2410c;
  --color-orange-light: #FFF0E1;
  --color-orange-bg: #FFF7ED;
  --color-orange-alt: #EF4A00;

  --color-green: #16A34A;
  --color-green-light: #DCFCE7;
  --color-green-bg: #F0FDF4;

  --color-text-dark: #111827;
  --color-text-dark-secondary: #1F2937;
  --color-text-main: #282D44;
  --color-text-gray-dark: #374151;
  --color-text-gray: #4B5563;
  --color-text-light: #6B7280;
  --color-text-muted: #9CA3AF;

  --color-bg-white: #ffffff;
  --color-bg-main: #f0f0f5;
  --color-bg-light: #F5F6FA;
  --color-bg-hover: #f3f4f6;
  --color-bg-hover-dark: #e5e7eb;
  --color-bg-overlay: rgba(17, 24, 39, 0.4);
  --color-bg-overlay-dark: rgba(0, 0, 0, 0.5);

  --color-status-danger: #FF4343;
  --color-status-danger-dark: #dc2626;
  --color-status-danger-light: #fee2e2;

  --color-status-success: #10B981;
  --color-status-success-dark: #155724;
  --color-status-success-light: #d4edda;

  --color-status-pending: #d97706;
  --color-status-pending-light: #fef3c7;

  --color-status-info-light: #e3f2fd;
  --color-status-info-dark: #1976d2;
  --color-status-info-hover: #bbdefb;

  --color-status-purple-light: #f3e5f5;
  --color-status-purple-dark: #7b1fa2;
  --color-status-purple-hover: #e1bee7;

  --color-border-dark: #ddd;
  --color-border-main: #d1d5db;
  --color-border-light: #e5e7eb;
  --color-border-lighter: #f9fafb;
  --color-border-alt: #EBECEF;
  --color-border-transparent: rgba(209, 213, 219, 0.50);

  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(72, 127, 255, 0.2);
  --shadow-card: 0 2px 8px rgba(0, 0, 0, 0.08);
  --shadow-card-hover: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-dropdown: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-modal: 0 10px 25px rgba(0, 0, 0, 0.15);
  --shadow-active: 0 0 0 3px rgba(72, 127, 255, 0.1);

  /* Typography */
  --font-primary: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-secondary: "Times New Roman", Times, serif;

  /* Radius & Spacing */
  --radius-sm: 6px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 16px;
  --radius-full: 50%;

  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 12px;
  --space-lg: 16px;
  --space-xl: 20px;
  --space-2xl: 24px;

  /* Layout */
  --leading-tight: 18px;
  --leading-normal: 24px;
  --sidebar-width: 272px;
  --sidebar-collapsed: 70px;
}

/* === BASE STYLES & RESET === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  font-family: var(--font-primary);
}

a {
  text-decoration: none !important;
}

select {
  color: var(--color-text-gray) !important;
  font-family: var(--font-primary);
  font-size: 13px !important;
  font-style: normal;
  font-weight: 400;
  line-height: 20px;
}

select:focus {
  box-shadow: none;
}

body {
  background-color: var(--color-bg-light);
  color: var(--color-text-light);
  font-size: 14px;
  display: flex;
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
}

/* === LOGIN STYLES === */
.login-wrapper {
  width: 100%;
  max-width: 400px;
  padding: var(--space-xl);
  margin: 0 auto;
}

.logo-section {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.SuperTrye_Login {
  color: var(--color-text-main);
  font-family: var(--font-secondary);
  font-size: 20px;
  font-style: normal;
  font-weight: 700;
  line-height: var(--leading-normal);
}

.login-card {
  background: var(--color-bg-white);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
}

.login-header {
  padding: var(--space-md) var(--space-xl);
  border-bottom: 1px solid var(--color-border-transparent);
}

.login-title {
  color: var(--color-text-dark);
  font-family: var(--font-primary);
  font-size: 18px;
  font-weight: 600;
  line-height: var(--leading-normal);
}

.login-body {
  padding: var(--space-xl) var(--space-2xl) var(--space-2xl);
}

.form-group {
  margin-bottom: var(--space-lg);
}

.form-label {
  color: var(--color-text-gray);
  font-family: var(--font-primary);
  font-size: 14px;
  font-weight: 600;
  line-height: var(--leading-normal);
  display: block;
  margin-bottom: var(--space-xs);
}

.input-wrapper {
  position: relative;
}

.form-control {
  height: 44px;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  padding: 11px 40px;
  font-size: 14px;
  color: var(--color-text-dark-secondary);
  width: 100%;
  background-color: var(--color-bg-white);
}

.form-control:focus {
  box-shadow: none;
  border-color: var(--color-primary);
  outline: none;
}

.input-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
}

.input-icon:focus {
  outline: none;
}

.input-icon svg {
  width: 20px;
  height: 20px;
}

.input-icon-email {
  cursor: default;
}

.forgot-password {
  display: block;
  text-align: right;
  text-decoration: none;
  margin-top: var(--space-xs);
  margin-bottom: var(--space-lg);
  color: var(--color-status-danger);
  font-family: var(--font-primary);
  font-size: 14px;
  font-weight: 400;
  line-height: var(--leading-tight);
}

.forgot-password:hover {
  text-decoration: underline;
}

.btn-submit {
  display: flex;
  width: 100%;
  padding: 9px var(--space-md);
  justify-content: center;
  align-items: center;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-primary-active);
  background: var(--color-primary-active);
  color: var(--color-bg-white);
  font-family: var(--font-primary);
  font-size: 16px;
  font-weight: 500;
  line-height: var(--leading-normal);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-submit:hover {
  opacity: 0.9;
}

.btn-submit:active {
  transform: translateY(1px);
}

/* === SIDEBAR STYLES === */
.sidebar {
  width: var(--sidebar-width);
  background: var(--color-bg-white);
  height: 100vh;
  position: fixed;
  left: 0;
  top: 0;
  border-right: 1px solid var(--color-border-alt);
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  z-index: 1000;
  transition: transform 0.3s ease, width 0.3s ease;
}

.sidebar-logo {
  border-bottom: 1px solid var(--color-border-alt);
  background: var(--color-bg-white);
  position: sticky;
  top: 0px;
  z-index: 10;
  display: flex;
  height: 73px;
  padding: 16px;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.sidebar-logo img {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
}

.sidebar-logo span {
  font-weight: 700;
  font-size: 18px;
  color: var(--color-text-dark-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-menu {
  padding: 20px 16px;
  list-style: none;
  flex: 1;
}

.menu-label {
  font-size: 9px;
  font-weight: 600;
  color: var(--color-text-muted);
  text-transform: uppercase;
  margin: 16px 0 8px 12px;
  letter-spacing: 0.5px;
}

.sidebar-menu li a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  color: var(--color-text-light);
  font-weight: 500;
  border-radius: var(--radius-md);
  margin-bottom: 4px;
  transition: all 0.2s ease;
  font-size: 14px;
  white-space: nowrap;
}

.sidebar-menu li a i,
.sidebar-menu li a svg {
  font-size: 18px;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--color-text-light);
}

.sidebar-menu li a.active {
  background: var(--color-primary);
  color: var(--color-bg-white);
  padding: 10px 12px;
}

.sidebar-footer {
  padding: 16px;
  border-top: 1px solid var(--color-border-alt);
  flex-shrink: 0;
}

.sidebar-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: var(--radius-md);
  font-weight: 600;
  cursor: pointer;
  color: var(--color-bg-white);
  font-size: 14px;
  justify-content: center;
  margin-bottom: 10px;
  transition: opacity 0.2s ease;
  white-space: nowrap;
}

.sidebar-btn:last-child {
  margin-bottom: 0;
}

.btn-blue {
  background: var(--color-primary-active);
}

.btn-orange {
  background: var(--color-orange-alt);
}

/* === MAIN CONTENT BODY === */
.main-content {
  margin-left: var(--sidebar-width);
  flex: 1;
  width: calc(100% - var(--sidebar-width));
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  transition: margin-left 0.3s ease, width 0.3s ease;
}

/* === HEADER STYLES === */
.header {
  height: 72px;
  background: var(--color-bg-white);
  border-bottom: 1px solid var(--color-border-alt);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
  width: 100%;
  padding: 0 24px;
  flex-shrink: 0;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 16px;
  flex: 1;
  min-width: 0;
}

.menu-toggle {
  font-size: 24px;
  color: var(--color-text-light);
  cursor: pointer;
  background: none;
  border: none;
  padding: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  transition: background 0.2s ease;
}

.menu-toggle:hover {
  background: var(--color-bg-hover);
}

.search-bar {
  display: flex;
  align-items: center;
  background: var(--color-border-lighter);
  border: 1px solid var(--color-border-alt);
  border-radius: var(--radius-md);
  padding: 0 16px;
  width: 320px;
  max-width: 100%;
  height: 40px;
  transition: width 0.3s ease;
}

.search-bar i,
.search-bar svg {
  color: var(--color-text-muted);
  font-size: 18px;
  margin-right: 8px;
  flex-shrink: 0;
}

.search-bar input {
  border: none;
  background: none;
  outline: none;
  width: 100%;
  font-size: 14px;
  color: var(--color-text-dark-secondary);
}

.search-bar input::placeholder {
  color: var(--color-text-muted);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.icon-btn {
  display: flex;
  width: 40px;
  height: 40px;
  justify-content: center;
  align-items: center;
  border-radius: 20px;
  background: var(--color-border-alt);
  border: none;
}

.user-avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  object-fit: cover;
  border: 2px solid var(--color-border-alt);
  cursor: pointer;
  transition: border-color 0.2s ease;
  flex-shrink: 0;
}

.user-avatar:hover {
  border-color: var(--color-primary);
}

/* === CONTENT SECTION === */
.content-body {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
  min-height: calc(100vh - 72px);
}

.overview-section {
  background: var(--color-bg-white);
  border-radius: var(--radius-xl);
  padding: 16px 20px !important;
  margin-bottom: 24px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);
  border: 1px solid var(--color-border-alt);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
}

.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

.page-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text-dark-secondary);
}

.breadcrumb {
  font-size: 14px;
  color: var(--color-text-light);
}

.breadcrumb a {
  color: var(--color-text-gray);
  font-weight: 500;
  line-height: var(--leading-normal);
}

/* === STAT CARDS === */
.stat-card {
  border-radius: var(--radius-md);
  padding: 16px 20px;
  width: 100%;
  display: flex;
  height: 100%;
  align-items: start !important;
  justify-content: space-between;
  position: relative;

  transition: transform 0.2s ease;
}


.stat-card::before {
  content: '';
  position: absolute;
  left: 0;
  top: 25%;
  bottom: 25%;
  width: 3px;
  height: 50%;
}

.stat-card.blue::before {
  background: var(--color-primary);
}

.stat-card.purple::before {
  background: var(--color-purple);
}

.stat-card.orange::before {
  background: var(--color-orange);
}

.stat-card.green::before {
  background: var(--color-green);
}

.stat-card.blue {
  background: var(--color-primary-bg);
}

.stat-card.purple {
  background: var(--color-purple-bg);
}

.stat-card.orange {
  background: var(--color-orange-bg);
}

.stat-card.green {
  background: var(--color-green-bg);
}

.stat-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.stat-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-light);
  margin-bottom: var(--space-sm);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.stat-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text-dark-secondary);
  white-space: nowrap;
  overflow: hidden;
}

.stat-icon {
  padding: 9px;
  height: 48px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
}

.stat-card.blue .stat-icon {
  background: var(--color-primary-light);
  color: var(--color-primary);
}

.stat-card.purple .stat-icon {
  background: var(--color-purple-light);
  color: var(--color-purple);
}

.stat-card.orange .stat-icon {
  background: var(--color-orange-light);
  color: var(--color-orange);
}

.stat-card.green .stat-icon {
  background: var(--color-green-light);
  color: var(--color-green);
}

/* === CHART SECTION === */
.chart-section {
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--color-border-alt);
  margin-bottom: 24px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 12px;
}

.chart-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text-dark-secondary);
}

.chart-actions {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
}

.chart-select {
  padding: 8px 32px 8px 16px;
  border: 1px solid var(--color-border-alt);
  border-radius: var(--radius-sm);
  outline: none;
  font-size: 14px;
  color: var(--color-text-light);
  appearance: none;
  background: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="%236B7280" viewBox="0 0 16 16"><path d="M4 6l4 4 4-4H4z"/></svg>') no-repeat right 12px center;
  cursor: pointer;
  transition: border-color 0.2s ease;
}

.chart-select:hover,
.chart-select:focus {
  border-color: var(--color-primary);
}

.chart-container {
  position: relative;
  height: 300px;
  width: 100%;
}

.chart-legend {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--color-border-alt);
  padding-top: 20px;
  margin-top: 20px;
  flex-wrap: wrap;
  gap: 16px;
}

.legend-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
  flex: 1;
  min-width: 120px;
}

.legend-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--color-text-light);
  font-weight: 500;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  flex-shrink: 0;
}

.dot.blue {
  background: var(--color-primary);
}

.dot.purple {
  background: var(--color-purple);
}

.dot.orange {
  background: var(--color-orange);
}

.dot.green {
  background: var(--color-green);
}

.legend-value {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-top: 4px;
  flex-wrap: wrap;
}

.legend-amount {
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text-dark-secondary);
}

.legend-change {
  font-size: 12px;
  font-weight: 600;
}

.legend-change.up {
  color: var(--color-green);
}

.legend-change.down {
  color: var(--color-status-danger-dark);
}

/* === CUSTOM SELECT === */
.custom-select {
  position: relative;
  width: 140px;
  font-family: var(--font-primary);
}

.select-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: var(--color-bg-white);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-md);
  cursor: pointer;
  font-size: 14px;
  color: var(--color-text-gray-dark);
  transition: all 0.2s ease;
}

.select-header:hover {
  border-color: var(--color-border-main);
}

.select-header.active {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-active);
}

.select-header i {
  font-size: 16px;
  color: var(--color-text-light);
  transition: transform 0.2s ease;
}

.select-header.active i {
  transform: rotate(180deg);
}

.current-selection {
  font-weight: 500;
}

.select-options {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: var(--color-bg-white);
  border: 1px solid var(--color-border-light);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-dropdown);
  display: none;
  overflow: hidden;
  z-index: 100;
}

.select-options.active {
  display: block;
}

.option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  cursor: pointer;
  transition: background 0.15s ease;
  border-bottom: 1px solid var(--color-bg-hover);
}

.option:last-child {
  border-bottom: none;
}

.option:hover {
  background: var(--color-border-lighter);
}

.option-label {
  font-size: 14px;
  color: var(--color-text-gray-dark);
  font-weight: 400;
}

.radio-circle {
  width: 18px;
  height: 18px;
  border: 2px solid var(--color-border-main);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s ease;
  background: var(--color-bg-white);
}

.radio-circle.selected {
  border-color: var(--color-primary);
  background: var(--color-primary);
}

.radio-circle.selected::after {
  content: '';
  width: 6px;
  height: 6px;
  background: var(--color-bg-white);
  border-radius: var(--radius-full);
}

.option.selected .option-label {
  color: var(--color-primary);
  font-weight: 500;
}

.btn-filter {
  width: 40px;
  height: 40px;
  background: var(--color-primary);
  color: var(--color-bg-white);
  border-radius: var(--radius-md);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 18px;
  transition: all 0.2s ease;
}

.btn-filter:hover {
  background: var(--color-primary-active);
}

/* === DATE FILTER MODAL === */
.filter-dropdown-container {
  position: relative;
}

.date-filter-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: var(--color-bg-overlay);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
}

.date-filter-modal.active {
  display: flex;
  animation: fadeInModal 0.2s ease forwards;
}

.date-filter-content {
  width: 360px;
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-modal);
  animation: slideUpModal 0.3s ease forwards;
}

@keyframes fadeInModal {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes slideUpModal {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--color-border-light);
}

.modal-header h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text-dark);
}

.modal-body {
  padding: 20px;
}

.date-inputs {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
}

.input-group {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.input-group label {
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text-gray);
  margin-bottom: var(--space-sm);
}

.date-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--color-border-main);
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--color-text-gray-dark);
  outline: none;
  transition: border-color 0.2s ease;
}

.date-input:focus {
  border-color: var(--color-primary);
  box-shadow: var(--shadow-active);
}

.date-input::placeholder {
  color: var(--color-text-light);
  font-weight: 400;
}

.modal-actions {
  display: flex;
  gap: 12px;
}

.btn-reset-light {
  flex: 1;
  padding: 10px 0;
  background: var(--color-bg-hover);
  color: var(--color-text-gray);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-reset-light:hover {
  background: var(--color-bg-hover-dark);
}

.btn-apply-orange {
  flex: 1;
  padding: 10px 0;
  background: var(--color-orange-active);
  color: var(--color-bg-white);
  border: none;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-apply-orange:hover {
  background: var(--color-orange-dark);
}

/* === TABLES === */
.table-section-dashboard {
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-alt);
  margin-bottom: 24px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
}

.table-header-dashboard {
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--color-border-alt);
  flex-wrap: wrap;
  gap: 12px;
}

.table-title-dashboard {
  font-size: 16px;
  font-weight: 600;
  color: var(--color-text-dark-secondary);
}

.view-all-dashboard {
  color: var(--color-primary);
  font-size: 14px;
  font-weight: 500;
  transition: opacity 0.2s ease;
}

.view-all-dashboard:hover {
  opacity: 0.8;
  text-decoration: underline;
}

.table-responsive-dashboard {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.table-dashboard {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  text-align: left;
}

.table-title {
  color: var(--color-text-dark);
  font-size: 18px;
  font-weight: 700;
  line-height: var(--leading-normal);
}

.table-dashboard th {
  padding: var(--space-lg);
  font-size: 12px;
  font-weight: 600;
  color: var(--color-text-main);
  border-bottom: 1px solid var(--color-border-alt);
  background: #F5F6FA;
  text-transform: capitalize;
  white-space: nowrap;
}

.table-dashboard td {
  padding: var(--space-lg);
  font-size: 14px;
  color: var(--color-text-light);
  border-bottom: 1px solid var(--color-bg-hover);
  white-space: nowrap;
}

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

.table-dashboard .td-dark {
  color: var(--color-text-dark-secondary);
  font-weight: 500;
}

.table-dashboard .td-blue {
  color: var(--color-primary);
  font-weight: 500;
}

.table-dashboard tbody tr:nth-child(even) {
  background-color: var(--color-border-lighter);
}

.table-dashboard tbody tr {
  transition: background-color 0.2s ease;
}

.btn-print2 {
  display: flex;
  width: 32px;
  padding: 8px 0;
  justify-content: center;
  align-items: center;
  border-radius: 16px;
  background: rgba(239, 71, 112, 0.15);
}

.btn-success1 {
  display: flex;
  padding: 6px 12px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  border-radius: 4px;
  background: #45B369;
  color: var(--color-bg-white);
}

.btn-success1:hover {
  color: var(--color-bg-white);
  background: #45B369;

}

.table-pagination {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 16px 24px;
  gap: 8px;
  border-top: 1px solid var(--color-border-alt);
  background: var(--color-bg-white);
}

.page-btn,
.page-num {
  padding: 6px 12px;
  border: 1px solid var(--color-border-alt);
  background: var(--color-bg-white);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--color-text-gray);
  transition: all 0.2s ease;
}

.page-btn:hover:not(:disabled),
.page-num:hover {
  background: var(--color-bg-hover);
  color: var(--color-text-dark-secondary);
}

.page-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.page-numbers {
  display: flex;
  gap: 4px;
}

.page-num.active {
  background: var(--color-primary);
  color: var(--color-bg-white);
  border-color: var(--color-primary);
}

/* Status badges */
.status-badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  text-transform: capitalize;
}

.status-badge.active {
  background: var(--color-green-light);
  color: var(--color-green);
}

.status-badge.pending {
  background: var(--color-status-pending-light);
  color: var(--color-status-pending);
}

.status-badge.inactive {
  background: var(--color-status-danger-light);
  color: var(--color-status-danger-dark);
}

/* === VENDOR STYLES === */
.form-section {
  background: var(--color-bg-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--color-border-alt);
  margin-bottom: 24px;

  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.02);
  gap: 20px;

}

.section-title {
  color: var(--color-text-dark) !important;
  font-size: 18px;
  font-weight: 600;
  line-height: var(--leading-normal);
}

.btn-secondary-vendor {
  color: var(--color-text-gray);
  font-size: 14px;
  font-weight: 500;
  display: flex;
  width: 160px;
  padding: 10px 12px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  border: none;
  border-radius: var(--radius-md);
  background: rgba(75, 85, 99, 0.12);
}

.btn-secondary-vendor:hover {
  background: rgba(75, 85, 99, 0.2) !important;
  color: var(--color-text-gray) !important;

}

.btn-primary-vendor {
  color: var(--color-bg-white);
  font-size: 14px;
  font-weight: 500;
  display: flex;
  padding: 10px 12px;
  justify-content: center;
  align-items: center;
  gap: 8px;

  width: 160px;
  border: none;
  border-radius: var(--radius-md);
  background: var(--color-primary-active);
}

.btn-filter-view {
  background-color: var(--color-primary) !important;
}

.form-select {
  display: flex;
  padding: 10px 16px 10px 12px;
  flex-direction: column;
  align-items: flex-start;
  border-radius: var(--radius-md);
  border: 1px solid var(--color-border-main);
  color: var(--color-text-gray);
  font-size: 16px;
  font-weight: 400;

}

.form-select:focus {
  box-shadow: none;
}

.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--radius-lg);
  font-size: 11px;
  font-weight: 500;
  text-transform: capitalize;
}

.badge-purchase {
  background: var(--color-status-success-light);
  color: var(--color-status-success-dark);
}

.actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.btn-icon {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  padding: 0;
}

.btn-view {
  background: var(--color-status-info-light);
  color: var(--color-status-info-dark);
}

.btn-view:hover {
  background: var(--color-status-info-hover);
}

.btn-edit {
  background: var(--color-status-purple-light);
  color: var(--color-status-purple-dark);
}

.btn-edit:hover {
  background: var(--color-status-purple-hover);
}

.btn-icon svg {
  width: 14px;
  height: 14px;
}

.btn-primary-product {
  display: flex;
  width: 160px;
  padding: 10px 12px;
  justify-content: center;
  align-items: center;
  gap: 8px;
  border-radius: 8px;
  background: var(--color-primary);
  color: var(--color-bg-white);
}

.btn-primary-product:hover {
  background: var(--color-primary);
  color: var(--color-bg-white);
}

/* === COLLAPSED SIDEBAR (DESKTOP) === */
body.sidebar-folded .sidebar {
  width: var(--sidebar-collapsed);
}

body.sidebar-folded .main-content {
  margin-left: var(--sidebar-collapsed);
  width: calc(100% - var(--sidebar-collapsed));
}

body.sidebar-folded .sidebar-logo {
  justify-content: center;
  padding: 16px 0;
}

body.sidebar-folded .sidebar-logo span,
body.sidebar-folded .menu-label {
  display: none;
}

body.sidebar-folded .sidebar-menu li a {
  justify-content: center;
  padding: 12px 0;
  font-size: 0;
}

body.sidebar-folded .sidebar-menu li a i,
body.sidebar-folded .sidebar-menu li a svg {
  margin-right: 0;
}

body.sidebar-folded .sidebar-btn {
  font-size: 0;
  padding: 12px 0;
}

body.sidebar-folded .sidebar-btn i {
  font-size: 18px;
}

/* === UTILITY CLASSES === */
.text-truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}

.gap-2 {
  gap: 8px;
}

.gap-3 {
  gap: 12px;
}

.gap-4 {
  gap: 16px;
}

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

::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb {
  background: #c1c1c1;
  border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
  background: #a8a8a8;
}

/* Custom Multi-Select Dropdown Styles */
.custom-multiselect {
  position: relative;
  display: inline-block;
  width: 100%;

}

.multiselect-input {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  background: #fff;
  cursor: pointer;

  flex-wrap: wrap;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;

  white-space: nowrap;

}

.multiselect-input:hover {
  border-color: #adb5bd;
}

.multiselect-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
  max-width: calc(100% - 50px);
  overflow-x: auto;
  overflow-y: hidden;
}

.multiselect-tags::-webkit-scrollbar {
  height: 4px;
}

.multiselect-tags::-webkit-scrollbar-thumb {
  background: rgba(0, 0, 0, 0.2);
  border-radius: 2px;
}

.multiselect-input.active {
  border-color: #0d6efd;
  box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.multiselect-search {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 14px;
  min-width: 100px;
}

.multiselect-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}

.multiselect-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-bg-white);
  background-color: var(--color-text-gray);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 500;
}

.multiselect-tag .remove-tag {
  cursor: pointer;
  font-weight: bold;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.multiselect-tag .remove-tag:hover {
  opacity: 1;
}

.multiselect-arrow {
  color: #6c757d;
  font-size: 18px;
  transition: transform 0.2s;
  pointer-events: none;
}

.multiselect-input.active .multiselect-arrow {
  transform: rotate(180deg);
}

.multiselect-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  background: white;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  max-height: 300px;
  overflow-y: auto;
  z-index: 1000;
  display: none;
}

.multiselect-dropdown.show {
  display: block;
}

.multiselect-option {
  padding: 10px 12px;
  border-bottom: 1px solid #f1f3f5;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: background-color 0.15s;
}

.multiselect-option:last-child {
  border-bottom: none;
}

.multiselect-option:hover {
  background-color: #f8f9fa;
}

.multiselect-option input[type="checkbox"] {
  cursor: pointer;
  width: 18px;
  height: 18px;
  accent-color: #0d6efd;
}

.multiselect-option label {
  flex: 1;
  cursor: pointer;
  margin-bottom: 0;
  font-size: 14px;
}

.trend-sales {
  display: flex;
  padding: 0 4px;
  align-items: center;
  border-radius: 6px;
  background: rgba(69, 179, 105, 0.15);
  color: #45B369;
  font-family: Inter;
  font-size: 14px;
  font-style: normal;
  font-weight: 500;
  line-height: 24px;
  /* 171.429% */
}

.trend-expense {
  color: #4B5563;
  font-family: Inter;
  font-size: 10px;
  font-style: normal;
  font-weight: 400;
  line-height: 24px;
  /* 171.429% */
}

.redbutton {

  background: #EF4A00 !important;
}

.badge-account {
  padding: 9px 12px;
  border-radius: 4px;
  background: rgba(75, 85, 99, 0.16);
}
.btn-primary {
 display: flex;
width: 160px;
padding: 10px 12px;
justify-content: center;
align-items: center;
gap: 8px;
border-radius: 8px;
background: var(--color-primary-active);
}
.btn-primary:hover{
  background-color: var(--color-primary-active) !important;

}
.expens-area{
  display: flex;
padding: 11px 20px 69px 20px;
align-items: flex-start;
gap: 8px;
align-self: stretch;
}

/* === RESPONSIVE BREAKPOINTS === */
@media (max-width: 1199px) {
  .stat-card {
    width: 100%;
  }

  .search-bar {
    width: 280px;
  }
}

@media (max-width: 991px) {
  :root {
    --sidebar-width: 240px;
  }

  .search-bar {
    width: 200px;
  }

  .content-body {
    padding: 20px;
  }

  .chart-legend {
    flex-direction: row;
  }

  .legend-item {
    min-width: calc(50% - 8px);
  }
}

@media (max-width: 767px) {
  :root {
    --sidebar-width: 260px;
  }

  .sidebar {
    transform: translateX(-100%);
    box-shadow: 2px 0 8px rgba(0, 0, 0, 0.1);
  }

  .sidebar.active {
    transform: translateX(0);
  }

  .main-content {
    margin-left: 0;
    width: 100%;
  }

  .menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .stat-card {
    padding: 16px;
    width: 100%;
  }

  .stat-value {
    font-size: 20px;
  }

  .stat-icon {
    width: 40px;
    height: 40px;
    font-size: 20px;
  }

  .search-bar {
    width: 100%;
    max-width: 200px;
  }

  .header {
    padding: 0 16px;
  }

  .content-body {
    padding: 16px;
  }

  .chart-section,
  .table-section {
    padding: 16px;
  }

  .chart-legend {
    flex-direction: column;
    gap: 12px;
  }

  .legend-item {
    width: 100%;
    min-width: auto;
  }

  th,
  td {
    padding: 12px 16px;
  }
}

@media (max-width: 575px) {
  .stat-card {
    flex-direction: row;
    align-items: center;
    width: 100%;
  }

  .header-left {
    gap: 12px;
  }

  .search-bar {
    display: none;
  }

  .header-right {
    gap: 8px;
  }

  .icon-btn {
    width: 36px;
    height: 36px;
  }

  .user-avatar {
    width: 36px;
    height: 36px;
  }

  .page-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .chart-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .chart-actions {
    width: 100%;
  }

  .chart-select {
    flex: 1;
  }

  .table-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
  }

  .sidebar-overlay.active {
    display: block;
  }
}

@media (max-width: 375px) {
  .content-body {
    padding: 12px;
  }

  .stat-value {
    font-size: 18px;
  }

  .page-title {
    font-size: 18px;
  }

  .chart-container {
    height: 200px;
  }
}

@media print {

  .sidebar,
  .header,
  .menu-toggle {
    display: none !important;
  }

  .main-content {
    margin-left: 0 !important;
    width: 100% !important;
  }

  .content-body {
    padding: 0;
  }
}