/* =====================================================================
   InventoryERP — Design System
   Dense, utilitarian, Zoho-Inventory-class app shell. Not a marketing
   page: small type, tight 8px grid, one accent color, flat surfaces.
   ===================================================================== */

:root {
  /* ---- Palette: neutral gray/white base, one sparing accent ---- */
  --color-bg:          #f6f7f9;
  --color-surface:     #ffffff;
  --color-border:      #e4e7ec;
  --color-border-dark: #d0d5dd;
  --color-text:        #1d2433;
  --color-text-muted:  #667085;
  --color-text-faint:  #98a2b3;

  --color-accent:       #2563eb;
  --color-accent-hover: #1d4ed8;
  --color-accent-bg:    #eff4ff;

  --color-success: #16a34a;
  --color-success-bg: #eafaf0;
  --color-warning: #d97706;
  --color-warning-bg: #fef6e7;
  --color-danger:  #dc2626;
  --color-danger-bg: #fdecec;
  --color-info:    #0891b2;
  --color-info-bg: #e7f8fb;

  /* ---- 8px spacing grid ---- */
  --sp-1: 4px;
  --sp-2: 8px;
  --sp-3: 16px;
  --sp-4: 24px;
  --sp-5: 32px;
  --sp-6: 48px;

  /* ---- Type scale (utilitarian, not marketing) ---- */
  --fs-cell: 12px;
  --fs-body: 13px;
  --fs-body-lg: 14px;
  --fs-label: 12px;
  --fs-h3: 15px;
  --fs-h2: 18px;
  --fs-h1: 22px;

  --radius: 12px;
  --radius-sm: 8px;
  --shadow-1: 0 1px 2px rgba(16, 24, 40, 0.06);

  --sidebar-w: 200px;
  --topbar-h: 56px;
  --bottomnav-h: 60px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, Helvetica, Arial, sans-serif;
  font-size: var(--fs-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  height: 100%;
}

h1, h2, h3, h4 { margin: 0 0 var(--sp-2) 0; font-weight: 600; }
h1 { font-size: var(--fs-h1); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }
p { margin: 0 0 var(--sp-2) 0; }

a { color: var(--color-accent); text-decoration: none; }
a:hover { color: var(--color-accent-hover); }

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* ---------------------------------------------------------------------
   App shell
   --------------------------------------------------------------------- */

.app-shell {
  display: flex;
  min-height: 100vh;
}

.main-col { 
  margin-left: var(--sidebar-w);
  flex: 1; 
  min-width: 0; 
  display: flex; 
  flex-direction: column;
  overflow-x: hidden;
  max-width: 100%;
  transition: margin-left 0.2s ease;
}

/* When sidebar is collapsed, reduce margin */
.sidebar.collapsed ~ .main-col,
.sidebar.collapsed + .main-col {
  margin-left: 64px;
}

/* ============ SIDEBAR ============ */

.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: var(--color-surface);
  border-right: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  height: 100vh;
  height: 100dvh;
  overflow-y: auto;
  overflow-x: hidden;
  transition: width 0.2s ease;
  z-index: 10;
}
/* ============ COLLAPSED SIDEBAR ============ */

.sidebar.collapsed { 
  width: 64px; 
  overflow-x: hidden;
}

.sidebar.collapsed .nav-label,
.sidebar.collapsed .brand-name,
.sidebar.collapsed .nav-section { 
  display: none; 
}

/* Brand/Logo area */
.sidebar-brand {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  height: var(--topbar-h);
  padding: 0 var(--sp-3);
  border-bottom: 1px solid var(--color-border);
  font-weight: 700;
  font-size: var(--fs-h3);
  flex-shrink: 0;
}

/* Logo mark */
.sidebar-brand .logo-mark {
  width: 26px; 
  height: 26px;
  border-radius: 7px;
  background: var(--color-accent);
  color: #fff;
  display: flex; 
  align-items: center; 
  justify-content: center;
  font-size: 13px; 
  font-weight: 700;
  flex-shrink: 0;
}

/* Collapsed brand - center the logo */
.sidebar.collapsed .sidebar-brand {
  justify-content: center;
  padding: 0;
}

.sidebar.collapsed .sidebar-brand .logo-mark {
  margin: 0 auto;
}

/* Nav section headers */
.nav-section {
  padding: var(--sp-3) var(--sp-3) var(--sp-1);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-faint);
  white-space: nowrap;
  overflow: hidden;
}

/* Nav items */
.nav-item {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 9px var(--sp-3);
  margin: 2px var(--sp-2);
  border-radius: var(--radius-sm);
  color: var(--color-text-muted);
  font-size: var(--fs-body);
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.1s, color 0.1s;
  white-space: nowrap;
  overflow: hidden;
}
/* ============ SIDEBAR LOGO ============ */

/* ============ SIDEBAR LOGO ============ */

/* Full sidebar logo */
.company-logo-full,
.logo-mark-full {
    display: flex;
}

/* Collapsed sidebar logo */
.company-logo-collapsed,
.logo-mark-collapsed {
    display: none;
}

/* Company logo image */
.company-logo {
    object-fit: contain;
    flex-shrink: 0;
}

.company-logo-full {
    max-height: 50px;
    max-width: 120px;
}

.company-logo-collapsed {
    max-height: 28px;
    max-width: 40px;
    margin: 0 auto;
}

/* Logo mark */
.logo-mark {
    width: 26px; 
    height: 26px;
    border-radius: 7px;
    background: var(--color-accent);
    color: #fff;
    align-items: center; 
    justify-content: center;
    font-size: 13px; 
    font-weight: 700;
    flex-shrink: 0;
}

.logo-mark-full {
    display: flex;
}

.logo-mark-collapsed {
    display: none;
}

/* Brand area */
.sidebar-brand {
    display: flex;
    align-items: center;
    gap: var(--sp-2);
    height: var(--topbar-h);
    padding: 0 var(--sp-3);
    border-bottom: 1px solid var(--color-border);
    font-weight: 700;
    font-size: var(--fs-h3);
    flex-shrink: 0;
}

/* When collapsed - show collapsed logo, hide full logo and brand name */
.sidebar.collapsed .company-logo-full,
.sidebar.collapsed .logo-mark-full,
.sidebar.collapsed .brand-name {
    display: none;
}

.sidebar.collapsed .company-logo-collapsed,
.sidebar.collapsed .logo-mark-collapsed {
    display: flex;
}

.sidebar.collapsed .sidebar-brand {
    justify-content: center;
    padding: 0;
}
.nav-item:hover { background: var(--color-bg); color: var(--color-text); }
.nav-item.active { background: var(--color-accent-bg); color: var(--color-accent); }

.nav-item .icon { 
  width: 18px; 
  height: 18px; 
  flex-shrink: 0; 
}

.nav-item .nav-label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Collapsed nav items - center icons */
.sidebar.collapsed .nav-item {
  justify-content: center;
  padding: 10px 8px;
  margin: 2px 8px;
}

.sidebar.collapsed .nav-item .icon {
  width: 20px;
  height: 20px;
}

/* ---------------------------------------------------------------------
   Topbar
   --------------------------------------------------------------------- */

.main-col { 
  flex: 1; 
  min-width: 0; 
  display: flex; 
  flex-direction: column;
  overflow-x: hidden;
  max-width: 100%;
}

.topbar {
  height: var(--topbar-h);
  background: var(--color-surface);
  border-bottom: 1px solid var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--sp-4);
  position: sticky;
  top: 0;
  z-index: 20;
}

.topbar-search {
  flex: 1;
  max-width: 420px;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 6px var(--sp-2);
  color: var(--color-text-faint);
  font-size: var(--fs-body);
}

.topbar-actions { display: flex; align-items: center; gap: var(--sp-3); }

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--color-success-bg);
  color: var(--color-success);
}
.status-pill.offline { background: var(--color-danger-bg); color: var(--color-danger); }
.status-pill .dot { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.avatar {
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--color-accent);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 700;
}

/* ---------------------------------------------------------------------
   Page content
   --------------------------------------------------------------------- */

.page {
  padding: var(--sp-4);
  max-width: 1440px;
  width: 100%;
  margin: 0 auto;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-4);
  flex-wrap: wrap;
  gap: var(--sp-2);
}

.page-header .subtitle { color: var(--color-text-muted); font-size: var(--fs-body); margin-top: 2px; }

/* ---- Cards: one shadow depth, consistent radius, never nested ---- */

.card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-1);
  padding: var(--sp-3);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--sp-3);
}

.card + .card { margin-top: var(--sp-3); }

/* ---- KPI grid ---- */

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--sp-3);
  margin-bottom: var(--sp-4);
}

.kpi-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--sp-3);
}

.kpi-label {
  font-size: var(--fs-label);
  color: var(--color-text-muted);
  font-weight: 500;
  margin-bottom: var(--sp-1);
}

.kpi-value { font-size: 22px; font-weight: 700; letter-spacing: -0.01em; }
.kpi-delta { font-size: 11px; margin-top: 4px; color: var(--color-text-faint); }
.kpi-delta.up { color: var(--color-success); }
.kpi-delta.down { color: var(--color-danger); }

/* ---- Buttons ---- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: var(--fs-body);
  font-weight: 600;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  background: var(--color-bg);
  color: var(--color-text);
  border-color: var(--color-border);
}

.btn:hover { background: #eef0f3 !important;color:blue !important; }
.btn-primary { background: var(--color-accent); color: #fff; border-color: var(--color-accent); }
.btn-primary:hover { background: var(--color-accent-hover); }
.btn-danger { background: var(--color-danger-bg); color: var(--color-danger); border-color: transparent; }
.btn-sm { padding: 5px 10px; font-size: 12px; }

/* ---- Forms ---- */

.form-group { margin-bottom: var(--sp-3); }
.form-label { display: block; font-size: var(--fs-label); font-weight: 600; margin-bottom: 6px; color: var(--color-text); }
.form-hint { font-size: 11px; color: var(--color-text-faint); margin-top: 4px; }

.form-control {
  width: 100%;
  font-size: var(--fs-body-lg);
  padding: 9px 12px;
  border: 1px solid var(--color-border-dark);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  color: var(--color-text);
}
.form-control:focus { outline: none; border-color: var(--color-accent); box-shadow: 0 0 0 3px var(--color-accent-bg); }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-3); }

/* ---- Tables: sticky header, borders not stripes ---- */

.table-wrap { overflow-x: auto; }

table.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--fs-cell);
}

.data-table thead th {
  position: sticky;
  top: 0;
  background: var(--color-surface);
  text-align: left;
  font-weight: 600;
  color: var(--color-text-muted);
  padding: 10px 12px;
  border-bottom: 1px solid var(--color-border);
  white-space: nowrap;
}

.data-table tbody td {
  padding: 10px 12px;
  border-bottom: 1px solid var(--color-border);
  vertical-align: middle;
}

.data-table tbody tr { position: relative; }
.data-table tbody tr:hover { background: var(--color-bg); }

.row-actions { opacity: 0; display: inline-flex; gap: var(--sp-1); transition: opacity 0.1s; }
.data-table tbody tr:hover .row-actions { opacity: 1; }

/* ---- Badges ---- */

.badge {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
}
.badge-success { background: var(--color-success-bg); color: var(--color-success); }
.badge-warning { background: var(--color-warning-bg); color: var(--color-warning); }
.badge-danger  { background: var(--color-danger-bg); color: var(--color-danger); }
.badge-info    { background: var(--color-info-bg); color: var(--color-info); }
.badge-neutral { background: var(--color-bg); color: var(--color-text-muted); border: 1px solid var(--color-border); }

/* ---- Empty state ---- */

.empty-state {
  text-align: center;
  padding: var(--sp-6) var(--sp-3);
  color: var(--color-text-muted);
}
.empty-state .icon { font-size: 32px; margin-bottom: var(--sp-2); }

/* ---- Toasts ---- */

.toast-stack {
  position: fixed;
  bottom: var(--sp-4);
  right: var(--sp-4);
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  z-index: 100;
}
.toast {
  background: var(--color-text);
  color: #fff;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: var(--fs-body);
  box-shadow: var(--shadow-1);
  min-width: 220px;
}
.toast.success { background: var(--color-success); }
.toast.error { background: var(--color-danger); }

/* ---- Skeleton loaders ---- */

.skeleton {
  background: linear-gradient(90deg, var(--color-border) 25%, #eef0f3 37%, var(--color-border) 63%);
  background-size: 400% 100%;
  animation: skeleton-loading 1.4s ease infinite;
  border-radius: var(--radius-sm);
}
@keyframes skeleton-loading {
  0% { background-position: 100% 50%; }
  100% { background-position: 0 50%; }
}

/* ---- Bottom nav + FAB (mobile) ---- */

.bottom-nav {
  display: none;
  position: fixed;
  border-radius:15px;
      width: 90%;
 bottom: 15px;
    left: 15px;
    right: 0;
  height: var(--bottomnav-h);
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  z-index: 30;
  align-items: center;
  justify-content: space-around;
}
.bottom-nav-item {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-size: 10px; color: var(--color-text-faint); font-weight: 600;
}
.bottom-nav-item.active { color: var(--color-accent); }

.fab {
  position: fixed;
  bottom: calc(var(--bottomnav-h) + var(--sp-3));
  right: var(--sp-3);
  width: 52px; height: 52px;
  border-radius: 50%;
  background: var(--color-accent);
  color: #fff;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
  border: none;
  z-index: 31;
}

/* ---------------------------------------------------------------------
   Responsive
   --------------------------------------------------------------------- */

/* ---------------------------------------------------------------------
   Responsive
   --------------------------------------------------------------------- */

/* Tablet - Sidebar becomes off-canvas */
@media (max-width: 768px) {
  .sidebar { 
    position: fixed; 
    left: 0; 
    top: 0;
    z-index: 40; 
    transform: translateX(-100%); 
    transition: transform 0.25s ease; 
    box-shadow: 4px 0 20px rgba(0,0,0,0.15);
    height: 100vh;
    height: 100dvh;
  }
  .sidebar.open { 
    transform: translateX(0); 
    display: flex !important;
  }
  .form-row { grid-template-columns: 1fr; }
  
  /* Show sidebar toggle button on tablet */
  .sidebar-toggle { 
    display: flex !important; 
  }
}
/* ============================================================
   MOBILE DATA-TABLE FIX — compact app-style rows
   Appended after the original mobile block in style.css so these
   rules win the cascade without needing !important. Applies to
   every page using .data-table (products, invoices, categories,
   brands, warehouses, transfers, adjustments, users, etc.)
   ============================================================ */
@media (max-width: 768px) {
  .data-table tbody tr {
    padding: 10px !important;
    margin-bottom: 8px !important;
  }

  /* Reset the old fixed-width label block approach */
  .data-table tbody td {
    padding: 0 !important;
  }
  .data-table tbody td::before {
    width: auto !important;
    display: inline !important;
  }

  /* First column = card title (name/number). No label needed —
     it's always the primary identifier on every list page. */
  .data-table tbody td:first-child {
    font-size: 14px;
    font-weight: 600;
    padding-bottom: 6px !important;
    border-bottom: 1px solid var(--color-border);
    margin-bottom: 4px;
  }
  .data-table tbody td:first-child::before { content: none !important; }

  /* Middle columns = compact "label ․․․․ value" rows */
  .data-table tbody td:not(:first-child):not(:last-child) {
    display: flex !important;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 3px 0 !important;
    font-size: 12.5px;
  }
  .data-table tbody td:not(:first-child):not(:last-child)::before {
    content: attr(data-label);
    font-weight: 600;
    font-size: 10.5px;
    text-transform: uppercase;
    letter-spacing: .03em;
    color: var(--color-text-faint);
    flex-shrink: 0;
  }
  /* Cells with no data-label (or an empty one) shouldn't reserve
     a label at all — collapse to a plain value row */
  .data-table tbody td:not(:first-child):not(:last-child):not([data-label]),
  .data-table tbody td:not(:first-child):not(:last-child)[data-label=""] {
    justify-content: flex-start;
  }
  .data-table tbody td:not(:first-child):not(:last-child):not([data-label])::before,
  .data-table tbody td:not(:first-child):not(:last-child)[data-label=""]::before {
    content: none !important;
  }

  /* Last column = action buttons, laid out as a compact row */
  .data-table tbody td:last-child {
    display: flex !important;
    gap: 6px;
    flex-wrap: wrap;
    margin-top: 8px;
    padding-top: 8px !important;
    border-top: 1px solid var(--color-border);
  }
  .data-table tbody td:last-child::before { content: none !important; }
  .data-table tbody td:last-child form { display: inline-flex; }

  /* Badges/pills inside value cells shouldn't stretch full width */
  .data-table tbody td .badge { flex-shrink: 0; }
}
/* Mobile */
@media (max-width: 768px) {
    .main-col {
    margin-left: 0 !important;
  }
  
  .sidebar.open + .main-col {
    margin-left: 0 !important;
  }
  /* DON'T use display:none - sidebar needs to be toggleable */
  .sidebar { 
    position: fixed;
    left: 0;
    top: 0;
    z-index: 50;
    transform: translateX(-100%);
    transition: transform 0.25s ease;
    width: 200px;
    max-width: 85vw;
    height: 100vh;
    height: 100dvh;
    box-shadow: 4px 0 20px rgba(0,0,0,0.2);
  }
  .sidebar.open { 
    transform: translateX(0);
    display: flex !important;
  }
  
  /* Bottom navigation */
  .bottom-nav { display: flex; }
  .fab { display: flex; }
  
  /* Page spacing for bottom nav */
  .page { 
    padding: var(--sp-3) !important; 
    padding-bottom: calc(var(--bottomnav-h) + var(--sp-4) + env(safe-area-inset-bottom, 0px)) !important; 
  }
  
  /* Topbar adjustments */
  .topbar { padding: 0 var(--sp-3); }
  .topbar-search { display: none; }
  
  /* Show sidebar toggle */
  .sidebar-toggle { 
    display: flex !important; 
  }
  
  /* KPI grid - 2 columns */
  .kpi-grid { grid-template-columns: repeat(2, 1fr); gap: var(--sp-2); }
  
  /* Mobile table - card view */
  .data-table thead { display: none; }
  .data-table, .data-table tbody, .data-table tr, .data-table td { 
    display: block; 
    width: 100%; 
  }
  .data-table tbody tr { 
    border: 1px solid var(--color-border); 
    border-radius: var(--radius-sm); 
    margin-bottom: var(--sp-2); 
    padding: var(--sp-2); 
  }
  .data-table tbody td { 
    border: none; 
    padding: 4px 0 !important; 
  }
  .data-table tbody td::before { 
    content: attr(data-label); 
    font-weight: 600; 
    color: var(--color-text-muted); 
    display: inline-block; 
    width: 110px; 
  }
  
  /* Row actions always visible on mobile */
  .row-actions { opacity: 1; }
}

/* Sidebar overlay for mobile */
.sidebar-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 39;
}

@media (max-width: 1024px) {
  .sidebar-overlay.active {
    display: block;
  }
}

/* Dark theme (first-class, toggled via [data-theme="dark"] on <html>) */
[data-theme="dark"] {
  --color-bg: #0f1319;
  --color-surface: #161b22;
  --color-border: #262d38;
  --color-border-dark: #333c4a;
  --color-text: #e6e9ef;
  --color-text-muted: #9aa4b2;
  --color-text-faint: #6b7484;
  --color-accent-bg: #16233f;
}

/* Density: compact */
[data-density="compact"] .data-table tbody td,
[data-density="compact"] .data-table thead th { padding: 6px 10px; }
[data-density="compact"] .page { padding: var(--sp-3); }

/* ============ SCROLLBAR STYLING ============ */

/* Custom scrollbar - Webkit browsers (Chrome, Edge, Safari) */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a1a1a1;
}

/* Sidebar scrollbar - thinner */
.sidebar::-webkit-scrollbar {
    width: 4px;
}

.sidebar::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.12);
    border-radius: 2px;
}

/* Table horizontal scrollbar */
.table-wrap::-webkit-scrollbar {
    height: 5px;
}

.table-wrap::-webkit-scrollbar-thumb {
    background: #d0d5dd;
    border-radius: 3px;
}

/* Dark theme scrollbar */
[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: #3a3f4a;
}

[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: #4a4f5a;
}

[data-theme="dark"] .sidebar::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.08);
}

/* Firefox scrollbar */
* {
    scrollbar-width: thin;
    scrollbar-color: #c1c1c1 transparent;
}

[data-theme="dark"] * {
    scrollbar-color: #3a3f4a transparent;
}

/* ============ PREVENT UNWANTED SCROLL ============ */

html, body {
    overflow-x: hidden;
    height: 100%;
}

.app-shell {
    overflow-x: hidden;
}

.main-col {
    overflow-x: hidden;
    max-width: 100%;
}

.page {
    overflow-x: auto;
}

.card {
    overflow: hidden;
}

.table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
}

/* Mobile scrollbar - even thinner */
@media (max-width: 768px) {
    ::-webkit-scrollbar {
        width: 2px;
        height: 2px;
    }
    
    html, body {
        overflow-x: hidden;
    }
    
    .page {
        overflow-x: hidden;
    }
}
