/* ========================================================================== */
/* GOLDGINI 2026 DESIGN SYSTEM — ALL-LIGHT CLEAN MINIMAL (LINEAR / APPLE STYLE)*/
/* Sidebar: Luminous Pearl White (#FFFFFF) | Border: Ultra-Clean (#E2E8F0)    */
/* Canvas: Soft Slate/Pearl (#F8FAFC) | Cards: Crisp White (#FFFFFF)          */
/* ========================================================================== */

:root {
  --gg-primary: #0F172A;
  --gg-primary-hover: #1E293B;

  --gg-emerald: #10B981;
  --gg-emerald-light: #DEF7EC;
  --gg-emerald-dark: #03543F;

  --gg-amber: #F59E0B;
  --gg-amber-light: #FEF3C7;
  --gg-amber-dark: #92400E;

  --gg-rose: #EF4444;
  --gg-rose-light: #FDE8E8;
  --gg-rose-dark: #9B1C1C;

  --gg-sidebar-bg: #FFFFFF;
  --gg-sidebar-border: #E2E8F0;
  --gg-sidebar-text: #475569;
  --gg-sidebar-text-hover: #0F172A;
  --gg-sidebar-active: #0F172A;

  --gg-canvas: #F8FAFC;
  --gg-card: #FFFFFF;
  --gg-border: #E2E8F0;
  --gg-text-main: #0F172A;
  --gg-text-muted: #64748B;

  --font-space: 'Space Grotesk', system-ui, -apple-system, sans-serif;
  --font-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
}

/* ============================================================ */
/* 1. CLEAN LIGHT CANVAS & CRISP CONTRAST FOR ALL PAGES         */
/* ============================================================ */
html,
body,
.wrapper,
.main-wrapper,
main.main-wrapper,
div.main-wrapper {
  background-color: #F8FAFC !important;
  background-image: none !important;
  background: #F8FAFC !important;
  color: #0F172A !important;
  font-family: var(--font-body) !important;
}

/* Base text contrast & headings for light pages */
h1, h2, h3, h4, h5, h6,
.text-dark,
.fw-bold.text-dark,
.user-name {
  color: #0F172A !important;
}

.text-muted,
.text-secondary {
  color: #64748B !important;
}

/* Clean borders for light pages */
.border,
.border-top,
.border-bottom,
.border-start,
.border-end {
  border-color: #E2E8F0 !important;
}

/* ========================================== */
/* 2. ALL-LIGHT MINIMAL SIDEBAR (LINEAR STYLE)*/
/* ========================================== */
.sidebar-wrapper {
  background: #FFFFFF !important;
  border-right: 1px solid #E2E8F0 !important;
  box-shadow: 2px 0 12px rgba(15, 23, 42, 0.03) !important;
  width: 260px !important;
  transition: all 0.22s ease-out !important;
}

.sidebar-header {
  background: #FFFFFF !important;
  border-bottom: 1px solid #E2E8F0 !important;
  padding: 14px 16px !important;
  height: 64px !important;
}

.sidebar-nav {
  background: transparent !important;
  padding-top: 6px !important;
  padding-bottom: 24px !important;
}

.sidebar-nav ul {
  background: transparent !important;
}

/* CATEGORY SECTION DIVIDERS (HIDDEN FOR MINIMAL CLEAN LOOK) */
.sidebar-wrapper .menu-label,
li.sidebar-section-divider {
  display: none !important;
}

/* REFINED MENU ITEMS (CLEAN LIGHT) */
.sidebar-nav ul.metismenu>li>a {
  color: #475569 !important;
  font-weight: 500 !important;
  font-size: 0.86rem !important;
  border-radius: 8px !important;
  margin: 2px 10px !important;
  padding: 8px 12px !important;
  min-height: 40px !important;
  transition: all 0.15s ease !important;
  border: 1px solid transparent !important;
  display: flex !important;
  align-items: center !important;
  white-space: nowrap !important;
}

.sidebar-nav ul.metismenu>li>a:hover {
  background: #F1F5F9 !important;
  color: #0F172A !important;
  transform: none !important;
  box-shadow: none !important;
}

.sidebar-nav ul.metismenu>li>a:hover .parent-icon i {
  color: #0F172A !important;
  transform: none !important;
}

/* ACTIVE MENU ITEM HIGHLIGHT (LINEAR GRAPHITE PILL) */
.sidebar-nav ul li.mm-active>a,
.sidebar-nav ul li a.active {
  background: #0F172A !important;
  color: #FFFFFF !important;
  font-weight: 600 !important;
  border: 1px solid #1E293B !important;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.12) !important;
  border-radius: 8px !important;
}

.sidebar-nav ul li.mm-active>a i,
.sidebar-nav ul li a.active i,
.sidebar-nav ul li.mm-active>a .sidebar-title-text,
.sidebar-nav ul li a.active .sidebar-title-text {
  color: #FFFFFF !important;
}

/* ======================================================== */
/* ULTRA-CLEAN LIVE BADGE & PULSE DOT                       */
/* ======================================================== */
.sidebar-title-text {
  white-space: nowrap !important;
  font-size: 0.86rem !important;
  font-weight: 500 !important;
  letter-spacing: -0.01em !important;
}

.sidebar-live-badge {
  display: inline-flex !important;
  align-items: center !important;
  gap: 5px !important;
  padding: 2.5px 8px !important;
  border-radius: 9999px !important;
  font-size: 0.62rem !important;
  font-weight: 700 !important;
  line-height: 1 !important;
  letter-spacing: 0.06em !important;
  text-transform: uppercase !important;
  user-select: none !important;
  transition: all 0.2s ease !important;
}

.sidebar-live-dot {
  width: 6px !important;
  height: 6px !important;
  border-radius: 50% !important;
  background-color: #10B981 !important;
  display: inline-block !important;
  position: relative !important;
  box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7) !important;
  animation: sidebar-live-pulse 1.8s infinite cubic-bezier(0.4, 0, 0.6, 1) !important;
  flex-shrink: 0 !important;
}

@keyframes sidebar-live-pulse {
  0% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
  }
  70% {
    transform: scale(1.05);
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0);
  }
  100% {
    transform: scale(0.95);
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
  }
}

/* Default / Inactive State (when viewing other sections) */
.sidebar-nav ul li:not(.mm-active) .sidebar-live-badge {
  background: #ECFDF5 !important;
  border: 1px solid #A7F3D0 !important;
}
.sidebar-nav ul li:not(.mm-active) .sidebar-live-badge,
.sidebar-nav ul li:not(.mm-active) .sidebar-live-badge .sidebar-live-text {
  color: #047857 !important;
}

/* Active State (when on dashboard - overrides any general text color) */
.sidebar-nav ul li.mm-active > a .sidebar-live-badge,
.sidebar-nav ul li a.active .sidebar-live-badge {
  background: rgba(16, 185, 129, 0.18) !important;
  border: 1px solid rgba(52, 211, 153, 0.45) !important;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.25) !important;
}
.sidebar-nav ul li.mm-active > a .sidebar-live-badge,
.sidebar-nav ul li.mm-active > a .sidebar-live-badge .sidebar-live-text,
.sidebar-nav ul li a.active .sidebar-live-badge,
.sidebar-nav ul li a.active .sidebar-live-badge .sidebar-live-text {
  color: #34D399 !important;
  font-weight: 700 !important;
}

/* Parent dropdown with active child page */
.sidebar-nav ul li.sidebar-dropdown-parent.has-active-child > a {
  color: #0F172A !important;
  background: #F8FAFC !important;
  border-left: 3px solid #0F172A !important;
  font-weight: 600 !important;
}

.sidebar-nav ul li.sidebar-dropdown-parent.has-active-child > a .parent-icon i {
  color: #0F172A !important;
}

.sidebar-nav .parent-icon i {
  color: #64748B !important;
  font-size: 1.25rem !important;
  transition: all 0.15s ease !important;
}

/* SUB-MENU TREE & ITEMS */
.sidebar-nav ul.metismenu ul.sub-menu-list {
  padding-left: 10px !important;
  margin-left: 20px !important;
  border-left: 1.5px solid #E2E8F0 !important;
  margin-top: 4px !important;
  margin-bottom: 6px !important;
}

.sidebar-sub-item {
  color: #64748B !important;
  font-weight: 500 !important;
  font-size: 0.84rem !important;
  padding: 7px 10px !important;
  border-radius: 6px !important;
  transition: all 0.15s ease !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  text-decoration: none !important;
  margin: 1px 0 !important;
  border: 1px solid transparent !important;
}

.sidebar-sub-item:hover {
  background-color: #F1F5F9 !important;
  color: #0F172A !important;
  transform: none !important;
  border-color: transparent !important;
}

.sidebar-sub-item:hover i {
  color: #0F172A !important;
}

/* ACTIVE SUB-MENU ITEM (SOFT PILL) */
.sidebar-sub-item.sub-active {
  background: #F1F5F9 !important;
  color: #0F172A !important;
  font-weight: 600 !important;
  box-shadow: none !important;
  border: 1px solid #CBD5E1 !important;
  border-radius: 6px !important;
}

.sidebar-sub-item.sub-active i,
.sidebar-sub-item.sub-active * {
  color: #0F172A !important;
}

/* ========================================== */
/* 3. CLEAN LIGHT TOPBAR (HEADER)             */
/* ========================================== */
.top-header {
  position: fixed !important;
  top: 0 !important;
  left: 256px !important;
  right: 0 !important;
  height: 64px !important;
  z-index: 1040 !important;
  background: #FFFFFF !important;
  border-bottom: 1px solid #E2E8F0 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03) !important;
  transition: left 0.22s ease-out !important;
}

.main-wrapper {
  margin-left: 256px !important;
  margin-top: 64px !important;
}

.top-header .navbar {
  position: relative !important;
  top: 0 !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  height: 100% !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px !important;
  padding: 0 1.25rem !important;
  z-index: 1040 !important;
}

.search-control {
  background-color: #F1F5F9 !important;
  color: #0F172A !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 12px !important;
}

.search-control:focus {
  background-color: #FFFFFF !important;
  border-color: #0F172A !important;
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.08) !important;
  color: #0F172A !important;
}

.btn-toggle a,
.nav-right-links .nav-link {
  color: #0F172A !important;
}

.dropdown-user,
.top-header .dropdown-menu {
  background-color: #FFFFFF !important;
  border: 1px solid #E2E8F0 !important;
  backdrop-filter: blur(20px) !important;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.14) !important;
  color: #0F172A !important;
}

/* ========================================== */
/* 4. CRISP WHITE CARDS ACROSS ALL PAGES      */
/* ========================================== */
.card,
.bg-dark,
.bg-secondary,
.bg-slate-900,
.bg-slate-800,
.bg-zinc-900 {
  background: #FFFFFF !important;
  background-color: #FFFFFF !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 16px !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05), 0 10px 20px -4px rgba(0, 0, 0, 0.04) !important;
  transition: all 0.22s ease !important;
  color: #0F172A !important;
}

.card:hover {
  border-color: #CBD5E1 !important;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 14px 24px -4px rgba(0, 0, 0, 0.06) !important;
}

.card-header {
  background-color: #FFFFFF !important;
  border-bottom: 1px solid #F1F5F9 !important;
  padding: 16px 20px !important;
  color: #0F172A !important;
  font-weight: 700 !important;
}

.card-footer {
  background-color: #FFFFFF !important;
  border-top: 1px solid #F1F5F9 !important;
  padding: 14px 20px !important;
}

/* ========================================== */
/* 5. CRISP CLEAN LIGHT TABLES & LISTS        */
/* ========================================== */
.table,
.table-dark {
  color: #1E293B !important;
  border-color: #E2E8F0 !important;
  background-color: #FFFFFF !important;
}

.table-responsive {
  background: #FFFFFF !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 14px !important;
  overflow: hidden !important;
}

.table thead th,
.table-dark thead th {
  background: #F8FAFC !important;
  color: #475569 !important;
  font-family: var(--font-space) !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  font-size: 0.74rem !important;
  letter-spacing: 0.06em !important;
  border-bottom: 2px solid #E2E8F0 !important;
  padding: 13px 16px !important;
}

.table tbody tr,
.table-dark tbody tr {
  background-color: #FFFFFF !important;
  border-bottom: 1px solid #F1F5F9 !important;
  transition: all 0.15s ease !important;
}

.table tbody tr:hover,
.table-dark tbody tr:hover {
  background-color: #F8FAFC !important;
}

.table tbody td,
.table-dark tbody td {
  padding: 13px 16px !important;
  vertical-align: middle !important;
  border-bottom-color: #F1F5F9 !important;
  color: #1E293B !important;
}

/* ========================================== */
/* 6. FORM INPUTS & SELECTS (LIGHT CLEAN)     */
/* ========================================== */
.form-control,
.form-select,
.dashboard-custom-input,
input,
select,
textarea {
  background-color: #FFFFFF !important;
  color: #0F172A !important;
  border: 1px solid #CBD5E1 !important;
  border-radius: 10px !important;
  padding: 9px 14px !important;
  font-size: 0.92rem !important;
  transition: all 0.2s ease !important;
}

.form-control::placeholder,
.form-select::placeholder {
  color: #94A3B8 !important;
}

.form-control:focus,
.form-select:focus,
.dashboard-custom-input:focus,
input:focus,
select:focus,
textarea:focus {
  background-color: #FFFFFF !important;
  color: #0F172A !important;
  border-color: #0F172A !important;
  box-shadow: 0 0 0 3px rgba(15, 23, 42, 0.08) !important;
}

.form-label {
  color: #334155 !important;
  font-weight: 600 !important;
  font-size: 0.88rem !important;
  margin-bottom: 6px !important;
}

/* ========================================== */
/* 7. CLEAN STRIPE / SHOPIFY BUTTONS          */
/* ========================================== */
.btn {
  border-radius: 8px !important;
  font-family: var(--font-body), system-ui, sans-serif !important;
  font-weight: 600 !important;
  font-size: 0.85rem !important;
  letter-spacing: 0.01em !important;
  padding: 8px 16px !important;
  transition: all 0.15s ease !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
}

.btn:hover {
  transform: none !important;
}

.btn-primary {
  background: #0F172A !important;
  border-color: #0F172A !important;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.1) !important;
  color: #FFFFFF !important;
}

.btn-primary:hover {
  background: #1E293B !important;
  border-color: #1E293B !important;
  color: #FFFFFF !important;
}

.btn-success {
  background: #059669 !important;
  border-color: #047857 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05) !important;
  color: #FFFFFF !important;
}

.btn-success:hover {
  background: #047857 !important;
}

.btn-danger {
  background: #DC2626 !important;
  border-color: #B91C1C !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05) !important;
  color: #FFFFFF !important;
}

.btn-danger:hover {
  background: #B91C1C !important;
}

.btn-warning {
  background: #D97706 !important;
  border-color: #B45309 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05) !important;
  color: #FFFFFF !important;
}

.btn-warning:hover {
  background: #B45309 !important;
}

/* ========================================== */
/* 8. ALERTS, SOFT BADGES & PILLS             */
/* ========================================== */
.alert-secondary,
.alert-dark,
.alert-info {
  background: #EEF2FF !important;
  border: 1px solid #C7D2FE !important;
  color: #3730A3 !important;
  border-radius: 10px !important;
  font-weight: 500 !important;
}

.badge {
  font-family: var(--font-body), system-ui, sans-serif !important;
  font-weight: 600 !important;
  letter-spacing: 0.01em !important;
  border-radius: 6px !important;
  padding: 4px 8px !important;
  font-size: 0.72rem !important;
}

.badge.bg-warning,
.badge-warning {
  background: #FEF3C7 !important;
  color: #92400E !important;
  border: 1px solid #FDE68A !important;
}

.badge.bg-success,
.badge-success {
  background: #DEF7EC !important;
  color: #03543F !important;
  border: 1px solid #BCF0DA !important;
}

.badge.bg-primary {
  background: #EEF2FF !important;
  color: #4338CA !important;
  border: 1px solid #C7D2FE !important;
}

.badge.bg-danger,
.badge-danger {
  background: #FDE8E8 !important;
  color: #9B1C1C !important;
  border: 1px solid #FBD5D5 !important;
}

.badge.bg-secondary {
  background: #F1F5F9 !important;
  color: #475569 !important;
  border: 1px solid #E2E8F0 !important;
}
  color: #FCA5A5 !important;
  border: 1px solid rgba(239, 68, 68, 0.4) !important;
}

.badge-notify {
  background-color: #10B981 !important;
  color: #FFFFFF !important;
  font-weight: 900 !important;
  border: 1px solid rgba(255, 255, 255, 0.4) !important;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.6) !important;
}

.modal-content {
  background-color: #FFFFFF !important;
  border: 1px solid #E2E8F0 !important;
  border-radius: 20px !important;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.15) !important;
  color: #0F172A !important;
}

.modal-dark .modal-content {
  background-color: rgba(15, 23, 42, 0.95) !important;
  border: 1px solid rgba(255, 255, 255, 0.12) !important;
  color: #E2E8F0 !important;
}

/* ========================================================================== */
/* 10. CATEGORY VARIANTS MATRIX (DARK NEON CYBER CONTAINER PRESERVED)        */
/* ========================================================================== */
.goldgini-variants-matrix,
.goldgini-variants-matrix.card {
  background: #090D22 !important;
  background-color: #090D22 !important;
  border: 1px solid rgba(212, 255, 0, 0.35) !important;
  border-radius: 16px !important;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6) !important;
  color: #FFFFFF !important;
}

.goldgini-variants-matrix .card-header {
  background: linear-gradient(135deg, #0C102A 0%, #070A1A 100%) !important;
  border-bottom: 1px solid rgba(212, 255, 0, 0.25) !important;
  color: #FFFFFF !important;
}

.goldgini-variants-matrix h1,
.goldgini-variants-matrix h2,
.goldgini-variants-matrix h3,
.goldgini-variants-matrix h4,
.goldgini-variants-matrix h5,
.goldgini-variants-matrix h6,
.goldgini-variants-matrix .fw-bold {
  color: #FFFFFF !important;
}

.goldgini-variants-matrix p,
.goldgini-variants-matrix span,
.goldgini-variants-matrix label,
.goldgini-variants-matrix small,
.goldgini-variants-matrix div {
  color: #E2E8F0;
}

.goldgini-variants-matrix .text-white {
  color: #FFFFFF !important;
}

.goldgini-variants-matrix .text-warning {
  color: #ffee00e5 !important;
}

.goldgini-variants-matrix .text-secondary {
  color: #94A3B8 !important;
}

.goldgini-variants-matrix .bg-secondary,
.goldgini-variants-matrix .bg-dark,
.goldgini-variants-matrix .bg-slate-900,
.goldgini-variants-matrix .bg-slate-800 {
  background-color: rgba(20, 26, 60, 0.75) !important;
  border: 1px solid rgba(167, 139, 250, 0.25) !important;
  color: #FFFFFF !important;
}

.goldgini-variants-matrix .table,
.goldgini-variants-matrix .table-dark {
  background: transparent !important;
  background-color: transparent !important;
  color: #FFFFFF !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

.goldgini-variants-matrix .table thead th,
.goldgini-variants-matrix .table-dark thead th {
  background: linear-gradient(90deg, #1A234E 0%, #121838 100%) !important;
  color: #D4FF00 !important;
  font-family: var(--font-space) !important;
  font-weight: 800 !important;
  text-transform: uppercase !important;
  font-size: 0.8rem !important;
  letter-spacing: 0.06em !important;
  border-bottom: 2px solid #D4FF00 !important;
  padding: 14px 16px !important;
}

.goldgini-variants-matrix .table tbody tr,
.goldgini-variants-matrix .table-dark tbody tr {
  background-color: transparent !important;
  transition: background-color 0.15s ease !important;
}

.goldgini-variants-matrix .table tbody tr:hover,
.goldgini-variants-matrix .table-dark tbody tr:hover {
  background-color: rgba(107, 38, 255, 0.25) !important;
}

.goldgini-variants-matrix .table tbody td,
.goldgini-variants-matrix .table-dark tbody td {
  padding: 12px 14px !important;
  vertical-align: middle !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
  color: #FFFFFF !important;
}

.goldgini-variants-matrix input,
.goldgini-variants-matrix select,
.goldgini-variants-matrix textarea,
.goldgini-variants-matrix .form-control,
.goldgini-variants-matrix .form-select {
  background-color: #FFFFFF !important;
  color: #0F172A !important;
  border: 1px solid #CBD5E1 !important;
  border-radius: 8px !important;
}

.goldgini-variants-matrix input:focus,
.goldgini-variants-matrix select:focus {
  background-color: #FFFFFF !important;
  color: #0F172A !important;
  border-color: #6320EE !important;
  box-shadow: 0 0 0 3px rgba(99, 32, 238, 0.15) !important;
}

.goldgini-variants-matrix .badge.bg-warning,
.goldgini-variants-matrix .badge-warning {
  background: #D4FF00 !important;
  color: #060816 !important;
  font-weight: 800 !important;
  border: 1px solid #B8E400 !important;
}

.goldgini-variants-matrix .badge.bg-primary {
  background: #6320EE !important;
  color: #FFFFFF !important;
}

/* ========================================== */
/* GLOBAL WHITE THEME OVERRIDES FOR TABLES & CARDS */
/* ========================================== */
.table-bg-dark,
.card.table-bg-dark {
  background-color: #FFFFFF !important;
  color: var(--gg-slate-900) !important;
  border: 1px solid var(--gg-border) !important;
  box-shadow: 0 4px 20px -2px rgba(15, 23, 42, 0.05) !important;
}

.thead-bg,
tr.thead-bg,
th.thead-bg {
  background-color: #F8FAFC !important;
  color: var(--gg-slate-700) !important;
}

.custom-admin-table {
  border-collapse: collapse !important;
  border: 1px solid #E2E8F0 !important;
  background-color: #FFFFFF !important;
  color: #0F172A !important;
}

.custom-admin-table th {
  background-color: #F8FAFC !important;
  color: #475569 !important;
  border: 1px solid #E2E8F0 !important;
  font-weight: 700 !important;
}

.custom-admin-table td {
  border: 1px solid #F1F5F9 !important;
  color: #0F172A !important;
  background-color: #FFFFFF !important;
}

.custom-admin-table tr {
  background-color: #FFFFFF !important;
  color: #0F172A !important;
}

.dashboard-custom-input {
  background-color: #FFFFFF !important;
  border: 1px solid #CBD5E1 !important;
  color: #0F172A !important;
}

.main-wrapper {
  background-color: #F8FAFC !important;
}

/* GLOBAL SELECT & OPTION DROPDOWN WHITE STYLING */
select option,
.form-select option,
option {
  background-color: #FFFFFF !important;
  color: #0F172A !important;
}

select option:hover,
.form-select option:hover,
option:hover,
select option:focus,
.form-select option:focus,
option:focus,
select option:checked,
.form-select option:checked,
option:checked {
  background-color: #F3F0FF !important;
  color: #6320EE !important;
}

/* HIGH CONTRAST ORDER STATUS BADGES */
.status-badge-delivered,
.status-badge-confirmed,
.status-badge-completed {
  background-color: #ECFDF5 !important;
  color: #047857 !important;
  border: 1px solid #A7F3D0 !important;
  font-weight: 700 !important;
  font-size: 0.78rem !important;
  padding: 5px 12px !important;
  border-radius: 20px !important;
  text-transform: capitalize !important;
  display: inline-block !important;
}

.status-badge-cancelled,
.status-badge-canceled {
  background-color: #FEF2F2 !important;
  color: #DC2626 !important;
  border: 1px solid #FECACA !important;
  font-weight: 700 !important;
  font-size: 0.78rem !important;
  padding: 5px 12px !important;
  border-radius: 20px !important;
  text-transform: capitalize !important;
  display: inline-block !important;
}

.status-badge-pending,
.status-badge-processing {
  background-color: #FFFBEB !important;
  color: #B45309 !important;
  border: 1px solid #FDE68A !important;
  font-weight: 700 !important;
  font-size: 0.78rem !important;
  padding: 5px 12px !important;
  border-radius: 20px !important;
  text-transform: capitalize !important;
  display: inline-block !important;
}

.status-badge-shipped {
  background-color: #EFF6FF !important;
  color: #1D4ED8 !important;
  border: 1px solid #BFDBFE !important;
  font-weight: 700 !important;
  font-size: 0.78rem !important;
  padding: 5px 12px !important;
  border-radius: 20px !important;
  text-transform: capitalize !important;
  display: inline-block !important;
}







/* INPUT SELECT TEXT COLOR FIX */
html body select.text-white,
html body .form-select.text-white,
html body select,
html body .form-select,
html body select option,
html body .form-select option,
html body .dataTables_length select,
html body .dataTables_filter input,
html body .dashboard-custom-input.text-white,
html body input.text-white {
  color: #000000 !important;
}

/* ========================================================================== */
/* MASTER LAPTOP & GLOBAL RESPONSIVE ENGINE (ALL LAPTOPS: 1024px - 1440px+)    */
/* ========================================================================== */

/* 1. Toggled Mini-Sidebar (Allows 1-Click Collapsing on All Laptops) */
body.toggled:not(.sidebar-hovered) .sidebar-wrapper {
  width: 70px !important;
  overflow: visible !important;
}

body.toggled:not(.sidebar-hovered) .sidebar-wrapper .sidebar-header {
  width: 70px !important;
  padding: 16px 8px !important;
  justify-content: center !important;
}

body.toggled:not(.sidebar-hovered) .sidebar-wrapper .sidebar-header .badge,
body.toggled:not(.sidebar-hovered) .sidebar-wrapper .sidebar-header .sidebar-close,
body.toggled:not(.sidebar-hovered) .sidebar-wrapper .menu-title,
body.toggled:not(.sidebar-hovered) .sidebar-wrapper .has-arrow:after {
  display: none !important;
}

body.toggled:not(.sidebar-hovered) .sidebar-wrapper .sidebar-nav ul.metismenu>li>a {
  justify-content: center !important;
  padding: 11px 0 !important;
  margin: 4px 6px !important;
  text-align: center !important;
}

body.toggled .sidebar-wrapper:hover {
  width: 250px !important;
  box-shadow: 8px 0 32px rgba(15, 23, 42, 0.15) !important;
}

body.toggled .sidebar-wrapper:hover .sidebar-header .badge,
body.toggled .sidebar-wrapper:hover .menu-title {
  display: inline-block !important;
}

/* 2. All Laptops Media Query (992px to 1440px): 13", 14", 15.6", MacBook, 1366x768, 1080p scaled */
@media screen and (min-width: 992px) and (max-width: 1440px) {

  /* Optimized sidebar width so main dashboard gets 30px more space */
  .sidebar-wrapper {
    width: 235px !important;
  }

  .top-header .navbar {
    left: 235px !important;
  }

  .main-wrapper {
    margin-left: 235px !important;
  }

  /* When collapsed to mini-sidebar on laptops */
  body.toggled .main-wrapper {
    margin-left: 70px !important;
  }

  body.toggled .top-header .navbar {
    left: 70px !important;
  }

  /* Compact content paddings to prevent horizontal scrolling */
  .main-wrapper .main-content {
    padding: 1rem 1.15rem !important;
  }

  .container-fluid {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }

  /* Scaled laptop typography & cards */
  .card {
    margin-bottom: 1rem !important;
  }

  .card-body {
    padding: 0.9rem !important;
  }

  h3,
  .h3 {
    font-size: 1.4rem !important;
  }

  h4,
  .h4 {
    font-size: 1.22rem !important;
  }

  h5,
  .h5 {
    font-size: 1.08rem !important;
  }

  h6,
  .h6 {
    font-size: 0.92rem !important;
  }

  /* Table responsive styling for laptops */
  .table {
    font-size: 12.5px !important;
  }

  .table> :not(caption)>*>* {
    padding: 0.6rem 0.65rem !important;
  }
}

/* 3. Small Laptop / High Scaling Screens (1024px to 1200px) */
@media screen and (min-width: 992px) and (max-width: 1200px) {
  .sidebar-wrapper {
    width: 220px !important;
  }

  .top-header .navbar {
    left: 220px !important;
  }

  .main-wrapper {
    margin-left: 220px !important;
  }

  .main-wrapper .main-content {
    padding: 0.85rem !important;
  }
}

/* 4. Global Smooth Scrollbars for all Tables Across Entire Dashboard */
.table-responsive {
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch !important;
}

.table-responsive::-webkit-scrollbar {
  height: 6px !important;
  width: 6px !important;
}

.table-responsive::-webkit-scrollbar-track {
  background: #F1F5F9 !important;
  border-radius: 4px !important;
}

.table-responsive::-webkit-scrollbar-thumb {
  background: #CBD5E1 !important;
  border-radius: 4px !important;
}

.table-responsive::-webkit-scrollbar-thumb:hover {
  background: #94A3B8 !important;
}

/* 5. Mobile & Tablet Screens (< 992px) */
@media screen and (max-width: 991px) {
  .sidebar-wrapper {
    left: -260px !important;
    width: 260px !important;
    z-index: 1060 !important;
    transition: left 0.3s ease-out !important;
  }

  body.toggled .sidebar-wrapper {
    left: 0px !important;
    width: 260px !important;
  }

  .top-header .navbar {
    left: 0 !important;
  }

  .main-wrapper {
    margin-left: 0 !important;
  }

  body.toggled .main-wrapper {
    margin-left: 0 !important;
  }

  body.toggled .overlay {
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    background: rgba(0, 0, 0, 0.5) !important;
    z-index: 1055 !important;
    display: block !important;
  }

  /* ── HEADER: Compact mobile layout ── */
  .top-header {
    left: 0 !important;
    height: 60px !important;
  }

  .top-header .navbar {
    padding: 0 0.75rem !important;
    gap: 8px !important;
  }

  .main-wrapper {
    margin-top: 60px !important;
  }

  /* ── MAIN CONTENT: Tighter padding on tablets ── */
  .main-wrapper .main-content {
    padding: 1rem !important;
  }

  .px-4 {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }

  .py-4 {
    padding-top: 0.75rem !important;
    padding-bottom: 0.75rem !important;
  }

  /* ── CARDS & PANELS: Full width stacking ── */
  .card {
    margin-bottom: 0.75rem !important;
    border-radius: 12px !important;
  }

  .card-body {
    padding: 0.85rem !important;
  }

  .row.g-3>[class*="col-lg"],
  .row.g-3>[class*="col-xl"] {
    flex: 0 0 50% !important;
    max-width: 50% !important;
  }

  /* ── FILTER TABS: Horizontal scroll ── */
  .nav-pills,
  .nav-tabs,
  .d-flex.flex-wrap.gap-2,
  .d-flex.gap-2.flex-wrap {
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    padding-bottom: 4px !important;
  }

  .nav-pills::-webkit-scrollbar,
  .nav-tabs::-webkit-scrollbar {
    display: none !important;
  }

  .nav-pills .nav-item,
  .nav-tabs .nav-item {
    flex-shrink: 0 !important;
  }

  /* ── BUTTONS: Scale down on tablets ── */
  .btn {
    padding: 7px 14px !important;
    font-size: 0.85rem !important;
    border-radius: 10px !important;
  }

  .btn-sm {
    padding: 5px 10px !important;
    font-size: 0.78rem !important;
  }

  /* ── TABLES: Better scroll experience ── */
  .table-responsive {
    border-radius: 10px !important;
    border: 1px solid var(--gg-border) !important;
    margin: 0 -2px !important;
  }

  .table {
    font-size: 0.82rem !important;
    min-width: 700px !important;
  }

  .table> :not(caption)>*>* {
    padding: 0.55rem 0.6rem !important;
  }

  /* ── PAGE TITLES: Smaller text ── */
  h3,
  .h3 {
    font-size: 1.3rem !important;
  }

  h4,
  .h4 {
    font-size: 1.15rem !important;
  }

  h5,
  .h5 {
    font-size: 1rem !important;
  }

  /* ── FORM CONTROLS ── */
  .form-control,
  .form-select {
    font-size: 0.88rem !important;
    padding: 8px 12px !important;
  }
}

/* ========================================================================== */
/* 6. MOBILE PHONE SCREENS (< 768px) — FULL RESPONSIVE OVERHAUL              */
/* ========================================================================== */
@media screen and (max-width: 767px) {

  /* ── HEADER: Compact mobile ── */
  .top-header {
    height: 56px !important;
  }

  .top-header .navbar {
    padding: 0 0.5rem !important;
    gap: 6px !important;
  }

  .main-wrapper {
    margin-top: 56px !important;
  }

  /* ── SEARCH BAR: Shorter placeholder, compact input ── */
  .top-header .navbar .search-bar {
    min-width: 0 !important;
  }

  .top-header .navbar .search-bar .search-control {
    height: 36px !important;
    font-size: 0.82rem !important;
    padding-left: 44px !important;
    padding-right: 12px !important;
  }

  .top-header .navbar .search-bar .search-control::placeholder {
    font-size: 0.78rem !important;
  }

  /* Hide Ctrl+K badge on mobile */
  .top-header .navbar .search-bar .badge {
    display: none !important;
  }

  .top-header .navbar .search-bar .position-absolute.ms-3 {
    font-size: 1rem !important;
  }

  /* ── PROFILE AVATAR smaller ── */
  .top-header .navbar .rounded-circle {
    width: 34px !important;
    height: 34px !important;
  }

  /* ── MAIN CONTENT: Mobile padding ── */
  .main-wrapper .main-content {
    padding: 0.75rem !important;
  }

  .px-4 {
    padding-left: 0.5rem !important;
    padding-right: 0.5rem !important;
  }

  /* ── PAGE HEADER: Stack title & actions vertically ── */
  .d-flex.align-items-center.justify-content-between {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 10px !important;
  }

  /* Don't apply column direction to internal flex items like badges, icons, etc. */
  .d-flex.align-items-center.justify-content-between .d-flex.align-items-center,
  .badge,
  .btn,
  .nav-item,
  td .d-flex,
  th .d-flex {
    flex-direction: row !important;
  }

  /* ── KPI STAT CARDS: 2 columns on mobile ── */
  .row.g-3>.col-lg-2,
  .row.g-3>.col-lg-3,
  .row.g-3>.col-xl-2,
  .row.g-3>.col-xl-3 {
    flex: 0 0 50% !important;
    max-width: 50% !important;
  }

  .row.g-3>.col-lg-4,
  .row.g-3>.col-xl-4,
  .row.g-3>.col-lg-6,
  .row.g-3>.col-xl-6,
  .row.g-3>.col-lg-8,
  .row.g-3>.col-xl-8,
  .row.g-3>.col-lg-12 {
    flex: 0 0 100% !important;
    max-width: 100% !important;
  }

  .row.g-3>.col-md-4 {
    flex: 0 0 50% !important;
    max-width: 50% !important;
  }

  .row.g-3>.col-md-6,
  .row.g-3>.col-md-8,
  .row.g-3>.col-md-12 {
    flex: 0 0 100% !important;
    max-width: 100% !important;
  }

  /* ── KPI CARDS: Compact styling ── */
  .card {
    border-radius: 10px !important;
    margin-bottom: 0.5rem !important;
  }

  .card-body {
    padding: 0.75rem !important;
  }

  .card .p-3 {
    padding: 0.65rem !important;
  }

  .card h3 {
    font-size: 1.2rem !important;
  }

  .card .small,
  .card .text-secondary.small {
    font-size: 0.72rem !important;
  }

  /* ── FILTER TABS & PILLS: Horizontally scrollable ── */
  .nav-pills,
  .nav-tabs {
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    gap: 4px !important;
  }

  .nav-pills::-webkit-scrollbar,
  .nav-tabs::-webkit-scrollbar {
    display: none !important;
  }

  .nav-pills .nav-link,
  .nav-tabs .nav-link {
    white-space: nowrap !important;
    font-size: 0.78rem !important;
    padding: 6px 12px !important;
    flex-shrink: 0 !important;
  }

  /* ── PILL FILTER BUTTONS (Order Status, Fulfillment Switcher) ── */
  .btn-group,
  .d-flex.border.rounded-pill,
  .d-flex.rounded-pill {
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
  }

  .btn-group::-webkit-scrollbar,
  .d-flex.border.rounded-pill::-webkit-scrollbar,
  .d-flex.rounded-pill::-webkit-scrollbar {
    display: none !important;
  }

  .btn-group .btn {
    flex-shrink: 0 !important;
    white-space: nowrap !important;
    font-size: 0.76rem !important;
    padding: 5px 10px !important;
  }

  /* ── QUICK FILTER BADGES (Vendor Orders) ── */
  .d-flex.flex-wrap.gap-1,
  .d-flex.flex-wrap.gap-2 {
    overflow-x: auto !important;
    flex-wrap: nowrap !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important;
    padding-bottom: 4px !important;
  }

  .d-flex.flex-wrap.gap-1::-webkit-scrollbar,
  .d-flex.flex-wrap.gap-2::-webkit-scrollbar {
    display: none !important;
  }

  .d-flex.flex-wrap.gap-1>.badge,
  .d-flex.flex-wrap.gap-1>.btn,
  .d-flex.flex-wrap.gap-1>button,
  .d-flex.flex-wrap.gap-2>.badge,
  .d-flex.flex-wrap.gap-2>.btn,
  .d-flex.flex-wrap.gap-2>button {
    flex-shrink: 0 !important;
    white-space: nowrap !important;
  }

  /* ── TABLES: Proper responsive scroll ── */
  .table-responsive {
    border: 1px solid var(--gg-border) !important;
    border-radius: 8px !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    position: relative !important;
  }

  /* Fade hint on right edge to indicate scrollable */
  .table-responsive::after {
    content: '' !important;
    position: absolute !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 24px !important;
    background: linear-gradient(to right, transparent, rgba(255, 255, 255, 0.85)) !important;
    pointer-events: none !important;
    z-index: 2 !important;
    border-radius: 0 8px 8px 0 !important;
  }

  .table {
    font-size: 0.78rem !important;
    min-width: 650px !important;
  }

  .table> :not(caption)>*>* {
    padding: 0.45rem 0.5rem !important;
  }

  .table thead th {
    font-size: 0.7rem !important;
    padding: 10px 8px !important;
    letter-spacing: 0.04em !important;
  }

  /* ── DATATABLES CONTROLS ── */
  .dataTables_wrapper .dataTables_length,
  .dataTables_wrapper .dataTables_filter {
    display: block !important;
    text-align: left !important;
    margin-bottom: 8px !important;
    width: 100% !important;
  }

  .dataTables_wrapper .dataTables_filter input {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
  }

  .dataTables_wrapper .dataTables_length select {
    min-width: 60px !important;
  }

  .dataTables_wrapper .dataTables_info,
  .dataTables_wrapper .dataTables_paginate {
    text-align: center !important;
    margin-top: 8px !important;
    font-size: 0.78rem !important;
  }

  /* ── MODALS: Full-width on mobile ── */
  .modal-dialog {
    margin: 0.5rem !important;
    max-width: calc(100% - 1rem) !important;
  }

  .modal-content {
    border-radius: 12px !important;
  }

  .modal-body {
    padding: 1rem !important;
  }

  .modal-header {
    padding: 0.75rem 1rem !important;
  }

  /* ── BADGES: Compact ── */
  .badge {
    font-size: 0.68rem !important;
    padding: 3px 8px !important;
  }

  /* ── TYPOGRAPHY: Mobile scale ── */
  h1,
  .h1 {
    font-size: 1.5rem !important;
  }

  h2,
  .h2 {
    font-size: 1.3rem !important;
  }

  h3,
  .h3 {
    font-size: 1.15rem !important;
  }

  h4,
  .h4 {
    font-size: 1.05rem !important;
  }

  h5,
  .h5 {
    font-size: 0.95rem !important;
  }

  h6,
  .h6 {
    font-size: 0.85rem !important;
  }

  .small,
  small {
    font-size: 0.75rem !important;
  }

  /* ── FORM CONTROLS ── */
  .form-control,
  .form-select,
  input,
  select,
  textarea {
    font-size: 0.85rem !important;
    padding: 7px 10px !important;
    border-radius: 8px !important;
  }

  .form-label {
    font-size: 0.8rem !important;
    margin-bottom: 4px !important;
  }

  /* ── INLINE FLEX ROWS: Stack on mobile ── */
  .d-flex.gap-3:not(.align-items-center):not(td .d-flex):not(th .d-flex):not(.nav-pills):not(.nav-tabs) {
    flex-wrap: wrap !important;
  }

  /* ── SVG CHARTS: Constrain ── */
  svg {
    max-width: 100% !important;
    height: auto !important;
  }
}

/* ========================================================================== */
/* 7. VERY SMALL PHONES (< 576px) — EXTRA COMPACT                            */
/* ========================================================================== */
@media screen and (max-width: 575px) {
  .top-header .navbar {
    padding: 0 0.35rem !important;
  }

  /* ── SEARCH: Even more compact ── */
  .top-header .navbar .search-bar .search-control {
    height: 34px !important;
    font-size: 0.78rem !important;
    padding-left: 38px !important;
  }

  /* ── KPI CARDS: Still 2 columns but tighter ── */
  .row.g-3>.col-6,
  .row.g-3>.col-md-4 {
    flex: 0 0 50% !important;
    max-width: 50% !important;
  }

  /* ── CONTENT: Tightest padding ── */
  .main-wrapper .main-content {
    padding: 0.5rem !important;
  }

  /* ── BUTTONS: Compact on small phones ── */
  .btn {
    padding: 5px 10px !important;
    font-size: 0.78rem !important;
    border-radius: 8px !important;
    gap: 4px !important;
  }

  /* ── TABLE: Allow scroll from edge to edge ── */
  .table {
    font-size: 0.74rem !important;
    min-width: 580px !important;
  }

  .table> :not(caption)>*>* {
    padding: 0.4rem 0.45rem !important;
  }

  .table thead th {
    font-size: 0.66rem !important;
    padding: 8px 6px !important;
  }

  /* ── CARD: Tighter on small phones ── */
  .card {
    border-radius: 8px !important;
  }

  .card-body {
    padding: 0.6rem !important;
  }

  /* ── MODAL: Edge-to-edge ── */
  .modal-dialog {
    margin: 0.25rem !important;
    max-width: calc(100% - 0.5rem) !important;
  }

  /* ── FORM CONTROLS ── */
  .form-control,
  .form-select {
    font-size: 0.82rem !important;
    padding: 6px 8px !important;
  }
}