:root {
  --font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Cairo", Tahoma, Arial, sans-serif;
  --sidebar-bg: #0f172a;
  --sidebar-bg-dark: #020617;
  --sidebar-hover: rgba(255, 255, 255, 0.08);
  --sidebar-active: #2563eb;
  --sidebar-text: #ffffff;
  --sidebar-muted: #94a3b8;
  --bg-main: #f8fafc;
  --card-bg: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  --border: #e2e8f0;
  --radius: 12px;
  --shadow: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.07), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] {
  --bg-main: #0b0f19;
  --card-bg: #111827;
  --text-main: #f9fafb;
  --text-muted: #9ca3af;
  --border: #1f2937;
  --primary-light: #1e3a8a;
  --success-light: #064e3b;
  --warning-light: #78350f;
  --danger-light: #7f1d1d;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: var(--font-family);
  direction: rtl;
  color: var(--text-main);
  background: var(--bg-main);
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }

/* Layout */
.layout { display: flex; min-height: 100vh; }

/* MODERN LUXURY EXECUTIVE SLATE/NAVY SIDEBAR */
.sidebar {
  width: 242px;
  background: linear-gradient(180deg, #0e1526 0%, #0a0f1d 100%);
  color: var(--sidebar-text);
  padding: 16px 10px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  box-shadow: -2px 0 16px rgba(0, 0, 0, 0.25);
  user-select: none;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  height: 100vh;
  position: sticky;
  top: 0;
  z-index: 100;
  transition: width 0.22s cubic-bezier(0.4, 0, 0.2, 1), padding 0.22s ease;
}

/* Brand Header */
.sidebar .brand {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 0 4px 14px 4px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 8px;
  min-height: 46px;
}
.sidebar .brand-content {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.sidebar .brand-icon {
  width: 36px;
  height: 36px;
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
  background: rgba(255, 255, 255, 0.04);
}
.sidebar .brand-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
  display: block;
}
.sidebar .brand-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.sidebar .brand-title {
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.5px;
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}
.sidebar .brand-badge {
  font-size: 9.5px;
  font-weight: 700;
  color: #60a5fa;
  background: rgba(37, 99, 235, 0.2);
  padding: 1px 6px;
  border-radius: 4px;
  display: inline-block;
  width: fit-content;
  letter-spacing: 0.4px;
}

/* Sidebar Collapse Toggle Button */
.sidebar-toggle-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 7px;
  color: #94a3b8;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.18s ease;
  flex-shrink: 0;
  padding: 0;
}
.sidebar-toggle-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.2);
}
.sidebar-toggle-btn .toggle-arrow-path {
  transition: transform 0.22s ease;
}

/* Sidebar Navigation Items */
.sidebar nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding-left: 2px;
}

/* Scrollbar for sidebar */
.sidebar nav::-webkit-scrollbar { width: 4px; }
.sidebar nav::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.12); border-radius: 4px; }
.sidebar nav:hover::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.22); }

/* Section Categories */
.nav-section-label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.6px;
  color: #64748b;
  padding: 10px 8px 3px 8px;
  margin-top: 6px;
  text-transform: uppercase;
  user-select: none;
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-group {
  display: flex;
  flex-direction: column;
}

.nav-item {
  width: 100%;
  border: none;
  background: transparent;
  font-family: inherit;
  text-align: right;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #94a3b8;
  padding: 8px 10px;
  border-radius: 8px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.16s ease;
  border: 1px solid transparent;
  text-decoration: none !important;
  position: relative;
  user-select: none;
}

.nav-item:hover {
  background: rgba(255, 255, 255, 0.06);
  color: #f8fafc;
}

.nav-item.active {
  background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 3px 10px rgba(37, 99, 235, 0.35);
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.nav-left .icon {
  width: 19px;
  height: 19px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: currentColor;
}

.nav-left .icon svg {
  width: 19px;
  height: 19px;
}

.nav-label {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-arrow {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: #64748b;
  transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1), color 0.18s;
}

.nav-item:hover .nav-arrow {
  color: #cbd5e1;
}

.nav-item.active .nav-arrow {
  color: #ffffff;
}

.nav-group.open > .nav-item .nav-arrow {
  transform: rotate(-90deg);
  color: #ffffff;
}

/* Submenu dropdowns */
.submenu {
  display: none;
  flex-direction: column;
  margin-right: 18px;
  padding-right: 10px;
  border-right: 1.5px solid rgba(255, 255, 255, 0.12);
  padding-top: 3px;
  padding-bottom: 5px;
  gap: 2px;
}

.nav-group.open .submenu {
  display: flex;
}

.submenu a {
  color: #94a3b8;
  padding: 6.5px 10px;
  font-size: 12.5px;
  font-weight: 500;
  border-radius: 6px;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}

.submenu a:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  transform: translateX(-2px);
}

.submenu a.sub-active {
  color: #60a5fa;
  font-weight: 700;
  background: rgba(37, 99, 235, 0.2);
}

/* Support Button Directly Below Settings */
.support-nav-item {
  margin-top: 6px;
  background: rgba(37, 99, 235, 0.08);
  border: 1px dashed rgba(59, 130, 246, 0.35);
  color: #93c5fd;
  border-radius: 8px;
}

.support-nav-item:hover {
  background: rgba(37, 99, 235, 0.2);
  border-color: rgba(59, 130, 246, 0.6);
  color: #ffffff;
}

.support-icon-wrapper {
  color: #60a5fa;
}

.support-badge-tag {
  background: rgba(37, 99, 235, 0.3);
  color: #93c5fd;
  font-size: 10px;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  letter-spacing: 0.4px;
}

/* ==================== COLLAPSIBLE SIDEBAR RULES ==================== */
.sidebar-collapsed .sidebar,
html.sidebar-collapsed .sidebar,
body.sidebar-collapsed .sidebar {
  width: 66px !important;
  padding: 14px 6px !important;
}

.sidebar-collapsed .sidebar .brand,
html.sidebar-collapsed .sidebar .brand,
body.sidebar-collapsed .sidebar .brand {
  justify-content: center !important;
  flex-direction: column !important;
  padding-bottom: 10px !important;
  gap: 8px !important;
  margin-bottom: 6px !important;
}

.sidebar-collapsed .brand-info,
html.sidebar-collapsed .brand-info,
body.sidebar-collapsed .brand-info {
  display: none !important;
}

.sidebar-collapsed .brand-content,
html.sidebar-collapsed .brand-content,
body.sidebar-collapsed .brand-content {
  justify-content: center !important;
  width: 100% !important;
}

.sidebar-collapsed .brand-icon,
html.sidebar-collapsed .brand-icon,
body.sidebar-collapsed .brand-icon {
  margin: 0 auto !important;
}

.sidebar-collapsed .sidebar-toggle-btn,
html.sidebar-collapsed .sidebar-toggle-btn,
body.sidebar-collapsed .sidebar-toggle-btn {
  margin: 0 auto !important;
}

.sidebar-collapsed .sidebar-toggle-btn .toggle-arrow-path,
html.sidebar-collapsed .sidebar-toggle-btn .toggle-arrow-path,
body.sidebar-collapsed .sidebar-toggle-btn .toggle-arrow-path {
  transform: rotate(180deg) !important;
  transform-origin: center !important;
}

.sidebar-collapsed .sidebar nav,
html.sidebar-collapsed .sidebar nav,
body.sidebar-collapsed .sidebar nav {
  overflow: visible !important;
  padding-left: 0 !important;
}

/* In collapsed mode, center all nav items */
.sidebar-collapsed .nav-item,
html.sidebar-collapsed .nav-item,
body.sidebar-collapsed .nav-item {
  justify-content: center !important;
  padding: 8px 0 !important;
  border-radius: 8px !important;
  width: 100% !important;
  margin-bottom: 2px !important;
}

.sidebar-collapsed .nav-left,
html.sidebar-collapsed .nav-left,
body.sidebar-collapsed .nav-left {
  justify-content: center !important;
  width: 100% !important;
  gap: 0 !important;
  margin: 0 !important;
}

.sidebar-collapsed .nav-left .icon,
html.sidebar-collapsed .nav-left .icon,
body.sidebar-collapsed .nav-left .icon {
  margin: 0 auto !important;
  width: 20px !important;
  height: 20px !important;
}

/* In collapsed mode, hide all text labels, badges, and ARROWS completely */
.sidebar-collapsed .nav-label,
html.sidebar-collapsed .nav-label,
body.sidebar-collapsed .nav-label,
.sidebar-collapsed .nav-arrow,
html.sidebar-collapsed .nav-arrow,
body.sidebar-collapsed .nav-arrow,
.sidebar-collapsed .support-badge-tag,
html.sidebar-collapsed .support-badge-tag,
body.sidebar-collapsed .support-badge-tag {
  display: none !important;
  width: 0 !important;
  height: 0 !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
}

/* In collapsed mode, turn section headers into subtle divider lines */
.sidebar-collapsed .nav-section-label,
html.sidebar-collapsed .nav-section-label,
body.sidebar-collapsed .nav-section-label {
  height: 1px !important;
  margin: 8px 4px !important;
  padding: 0 !important;
  background: rgba(255, 255, 255, 0.08) !important;
  font-size: 0 !important;
  color: transparent !important;
  overflow: hidden !important;
}

/* CRITICAL: In collapsed mode, ALL in-flow submenus MUST be hidden completely (even if .nav-group.open) */
.sidebar-collapsed .submenu,
html.sidebar-collapsed .submenu,
body.sidebar-collapsed .submenu,
.sidebar-collapsed .nav-group.open > .submenu,
html.sidebar-collapsed .nav-group.open > .submenu,
body.sidebar-collapsed .nav-group.open > .submenu {
  display: none !important;
}

/* Position relative for hover popups */
.sidebar-collapsed .nav-group,
html.sidebar-collapsed .nav-group,
body.sidebar-collapsed .nav-group {
  position: relative !important;
}

/* Collapsed Hover Flyout for Groups with Submenus */
.sidebar-collapsed .nav-group:hover > .submenu,
html.sidebar-collapsed .nav-group:hover > .submenu,
body.sidebar-collapsed .nav-group:hover > .submenu {
  display: flex !important;
  position: absolute !important;
  right: calc(100% + 8px) !important;
  top: 0 !important;
  background: #0f172a !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  border-radius: 10px !important;
  padding: 8px !important;
  min-width: 195px !important;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.75), 0 0 1px 1px rgba(255, 255, 255, 0.12) !important;
  z-index: 999999 !important;
  margin-right: 0 !important;
  border-right: none !important;
  gap: 3px !important;
}

.sidebar-collapsed .nav-group:hover > .submenu a,
html.sidebar-collapsed .nav-group:hover > .submenu a,
body.sidebar-collapsed .nav-group:hover > .submenu a {
  padding: 7px 12px !important;
  font-size: 13px !important;
  color: #cbd5e1 !important;
  border-radius: 6px !important;
  white-space: nowrap !important;
  display: flex !important;
  align-items: center !important;
}

.sidebar-collapsed .nav-group:hover > .submenu a:hover,
html.sidebar-collapsed .nav-group:hover > .submenu a:hover,
body.sidebar-collapsed .nav-group:hover > .submenu a:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  color: #ffffff !important;
}

.sidebar-collapsed .nav-group:hover > .submenu a.sub-active,
html.sidebar-collapsed .nav-group:hover > .submenu a.sub-active,
body.sidebar-collapsed .nav-group:hover > .submenu a.sub-active {
  background: rgba(37, 99, 235, 0.25) !important;
  color: #60a5fa !important;
  font-weight: 700 !important;
}

/* Collapsed Hover Tooltips for direct items without submenus */
.sidebar-collapsed a.nav-item[data-title]:hover::after,
html.sidebar-collapsed a.nav-item[data-title]:hover::after,
body.sidebar-collapsed a.nav-item[data-title]:hover::after {
  content: attr(data-title);
  position: absolute;
  right: calc(100% + 10px);
  top: 50%;
  transform: translateY(-50%);
  background: #0f172a;
  color: #f8fafc;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 6px;
  white-space: nowrap;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5), 0 0 1px 1px rgba(255, 255, 255, 0.15);
  pointer-events: none;
  z-index: 999999;
}

/* ==================== QUICK SUPPORT MODAL ==================== */
.support-modal-card {
  background: #ffffff;
  width: 95%;
  max-width: 460px;
  border-radius: 14px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  border: 1px solid #e2e8f0;
  animation: modalSlideUp 0.2s ease-out;
}
@keyframes modalSlideUp {
  from { transform: translateY(16px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.support-modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f8fafc;
}
.support-modal-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #eff6ff;
  border: 1px solid #dbeafe;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.support-modal-close {
  background: transparent;
  border: none;
  font-size: 18px;
  color: #94a3b8;
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  line-height: 1;
}
.support-modal-close:hover {
  color: #1e293b;
  background: #e2e8f0;
}
.support-modal-body {
  padding: 20px;
}
.support-id-box {
  background: #f8fafc;
  border: 1.5px dashed #cbd5e1;
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.support-id-meta {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.support-id-title {
  font-size: 11px;
  color: #64748b;
  font-weight: 700;
}
.support-id-num {
  font-size: 20px;
  font-weight: 900;
  color: #0f172a;
  letter-spacing: 1px;
  font-family: monospace;
}
.btn-copy-id {
  background: #2563eb;
  color: #ffffff;
  border: none;
  border-radius: 7px;
  padding: 8px 14px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s;
}
.btn-copy-id:hover {
  background: #1d4ed8;
}
.support-channels-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.support-channel-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #e2e8f0;
  text-decoration: none;
  transition: all 0.15s ease;
}
.support-channel-btn:hover {
  border-color: #cbd5e1;
  background: #f8fafc;
  transform: translateY(-1px);
}
.support-channel-btn .channel-icon {
  font-size: 22px;
  flex-shrink: 0;
}
.support-channel-btn .channel-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.support-channel-btn .channel-text strong {
  font-size: 13.5px;
  color: #0f172a;
}
.support-channel-btn .channel-text small {
  font-size: 11.5px;
  color: #64748b;
}

/* Main Area */
.main {
  flex: 1;
  padding: 26px 32px;
  min-width: 0;
}

.top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

h1 { font-size: 24px; font-weight: 800; margin: 0 0 4px; color: #0f172a; }
h2 { font-size: 17px; font-weight: 700; margin: 0 0 16px; color: #1e293b; }
.muted { color: var(--text-muted); font-size: 13px; }

/* Panels & Cards */
.panel {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow);
  margin-bottom: 22px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.card .label { font-size: 13px; font-weight: 600; color: var(--text-muted); }
.card .metric { font-size: 25px; font-weight: 800; margin-top: 8px; color: #0f172a; }
.card .sub { font-size: 12px; margin-top: 6px; color: var(--text-muted); }
.card.highlight { border-top: 4px solid var(--primary); }
.card.success { border-top: 4px solid var(--success); }
.card.warning { border-top: 4px solid var(--warning); }
.card.danger { border-top: 4px solid var(--danger); }

/* Quick Actions Bar */
.quick-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.quick-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: white;
  border: 1px solid var(--border);
  padding: 10px 18px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 14px;
  color: #1e293b;
  box-shadow: var(--shadow);
  transition: all 0.15s;
}

.quick-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  text-decoration: none;
  transform: translateY(-1px);
}

.quick-btn.primary {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

.quick-btn.primary:hover {
  background: var(--primary-hover);
}

/* Forms & Inputs */
.formgrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
}
label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
}
input:not([type="checkbox"]):not([type="radio"]):not([type="color"]):not([type="range"]), select, textarea {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: white;
  font: inherit;
  font-size: 14px;
  color: #0f172a;
  transition: border-color 0.15s, box-shadow 0.15s;
}
input[type="checkbox"], input[type="radio"] {
  width: auto;
  accent-color: var(--primary);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(75, 54, 227, 0.15);
}

/* Buttons */
button, .btn {
  border: 0;
  background: var(--primary);
  color: white;
  padding: 10px 18px;
  border-radius: 8px;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: background 0.15s;
}
button:hover, .btn:hover { background: var(--primary-hover); text-decoration: none; }
button.secondary, .btn.secondary {
  background: #e2e8f0;
  color: #1e293b;
}
button.secondary:hover, .btn.secondary:hover { background: #cbd5e1; }
button.danger, .btn.danger { background: var(--danger); color: white; }
button.danger:hover, .btn.danger:hover { background: #dc2626; }
button.success, .btn.success { background: var(--success); color: white; }
button.success:hover, .btn.success:hover { background: #059669; }

.actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 16px; align-items: center; }

/* Tables */
.tablewrap {
  overflow-x: auto;
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
table {
  border-collapse: collapse;
  width: 100%;
  min-width: 680px;
}
th, td {
  text-align: right;
  padding: 12px 16px;
  border-bottom: 1px solid #f1f5f9;
  font-size: 13.5px;
}
th {
  background: #f8fafc;
  color: #475467;
  font-weight: 700;
  border-bottom: 2px solid var(--border);
}
tbody tr:hover { background: #f8fafc; }
tfoot th { background: #f1f5f9; font-weight: 800; border-top: 2px solid var(--border); }

/* Badges & Alerts */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}
.badge.success { background: var(--success-light); color: #065f46; }
.badge.warning { background: var(--warning-light); color: #92400e; }
.badge.danger { background: var(--danger-light); color: #991b1b; }
.badge.info { background: var(--primary-light); color: #3728b7; }

.alert {
  padding: 14px 18px;
  border-radius: 10px;
  font-size: 14px;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.alert.success, .alert-success { background: var(--success-light); color: #065f46; border: 1px solid #a7f3d0; }
.alert.warning, .alert-warning { background: var(--warning-light); color: #92400e; border: 1px solid #fde68a; }
.alert.danger, .alert-danger { background: var(--danger-light); color: #991b1b; border: 1px solid #fecaca; }
.alert.info, .alert-info { background: var(--primary-light); color: #1e40af; border: 1px solid #bfdbfe; }

/* Dynamic Invoice Rows */
.rowline {
  display: grid;
  grid-template-columns: 3fr 1fr 1.2fr 40px;
  gap: 10px;
  margin-bottom: 8px;
  align-items: center;
}

/* POS Screen */
.pos-layout {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 20px;
}
.pos-products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 12px;
  max-height: 70vh;
  overflow-y: auto;
  padding: 4px;
}
.pos-card {
  background: white;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px;
  cursor: pointer;
  transition: all 0.15s;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.pos-card:hover {
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.pos-cart {
  background: white;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  display: flex;
  flex-direction: column;
  height: calc(100vh - 120px);
}
.pos-cart-items {
  flex: 1;
  overflow-y: auto;
  margin: 12px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 8px 0;
}

/* Printable Invoices */
.invoice-box {
  max-width: 800px;
  margin: 0 auto;
  background: white;
  padding: 40px;
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-md);
}
.invoice-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 2px solid #0f172a;
  padding-bottom: 20px;
  margin-bottom: 24px;
}
.invoice-parties {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 24px;
  background: #f8fafc;
  padding: 16px;
  border-radius: 8px;
}
.invoice-totals {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  margin-top: 24px;
}
.qr-code img {
  width: 140px;
  height: 140px;
  border: 1px solid #cbd5e1;
  padding: 4px;
  border-radius: 8px;
}

/* Global Thermal Receipt Styling (Screen & Print) */
.thermal-receipt {
  width: 76mm !important;
  max-width: 76mm !important;
  margin: 0 auto !important;
  font-size: 11px !important;
  color: #000 !important;
  background: #fff !important;
}
.thermal-receipt table {
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  table-layout: auto !important;
  margin: 6px 0 !important;
}
.thermal-receipt th, .thermal-receipt td {
  padding: 4px 2px !important;
  font-size: 11px !important;
  word-break: break-word !important;
}

/* Print Media */
@media print {
  body { background: white !important; font-size: 12pt; }
  .sidebar, .top, .actions, .no-print { display: none !important; }
  .main { padding: 0 !important; }
  .invoice-box {
    max-width: 100% !important;
    border: none !important;
    box-shadow: none !important;
    padding: 0 !important;
  }
  .thermal-receipt {
    width: 78mm !important;
    margin: 0 auto !important;
    padding: 2mm !important;
    font-size: 9pt !important;
  }
  .thermal-receipt table { font-size: 8pt !important; min-width: 100% !important; }
  .thermal-receipt .qr-code img { width: 100px !important; height: 100px !important; }
}

/* Shared table & checkbox row utilities (moved from settings.html) */
.table-custom {
  width: 100%;
  border-collapse: collapse;
  font-size: 13.5px;
}
.table-custom th,
.table-custom td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--border);
  text-align: right;
  vertical-align: middle;
}
.table-custom th {
  background: #f8fafc;
  color: var(--text-muted);
  font-weight: 700;
  font-size: 12.5px;
}
.setting-check-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #f8fafc;
  margin-bottom: 10px;
  cursor: pointer;
}
.setting-check-row input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin: 0;
  flex-shrink: 0;
}
.mobile-menu-btn {
  display: none;
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #0f172a;
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 18px;
  cursor: pointer;
}
.sidebar-mobile-backdrop {
  display: none;
}

/* Responsive */
@media (max-width: 950px) {
  .pos-layout { grid-template-columns: 1fr; }
  .sidebar { width: 220px; }
  .cards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .mobile-menu-btn { display: inline-flex; align-items: center; justify-content: center; }
  .layout { flex-direction: column; }
  .sidebar, html.sidebar-collapsed .sidebar, body.sidebar-collapsed .sidebar {
    width: 270px !important;
    max-width: 85vw !important;
    height: 100vh !important;
    position: fixed !important;
    top: 0;
    right: -290px;
    z-index: 9500 !important;
    padding: 14px !important;
    overflow-y: auto;
    transition: right 0.25s ease;
  }
  body.mobile-sidebar-open .sidebar {
    right: 0 !important;
  }
  body.mobile-sidebar-open .sidebar-mobile-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.55);
    z-index: 9400;
  }
  .sidebar-toggle-btn { display: none !important; }
  html.sidebar-collapsed .brand-info, body.sidebar-collapsed .brand-info {
    display: flex !important;
  }
  html.sidebar-collapsed .nav-item .nav-label, body.sidebar-collapsed .nav-item .nav-label,
  html.sidebar-collapsed .nav-item .nav-arrow, body.sidebar-collapsed .nav-item .nav-arrow {
    display: inline !important;
  }
  html.sidebar-collapsed .nav-left, body.sidebar-collapsed .nav-left {
    justify-content: flex-start !important;
    width: auto !important;
    gap: 10px !important;
  }
  html.sidebar-collapsed .nav-item, body.sidebar-collapsed .nav-item {
    justify-content: space-between !important;
    padding: 8.5px 12px !important;
  }
  .main { padding: 16px; }
  .cards { grid-template-columns: 1fr; }
  .rowline { grid-template-columns: 1fr 1fr; }
}

/* ==================== MODAL POPUP DIALOGS & ALIASES ==================== */
.modal-backdrop,
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
  animation: modalFadeIn 0.15s ease-out;
}

.modal-backdrop.show,
.modal-backdrop.active,
.modal-overlay.show,
.modal-overlay.active {
  display: flex !important;
}

.modal-box,
.modal-content,
.modal-overlay > .modal {
  background: white;
  border-radius: 16px;
  width: 100%;
  max-width: 650px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  border: 1px solid var(--border);
  animation: modalSlideUp 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

/* Helper layout classes */
.grid2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
}

.login {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  padding: 20px;
}

.notice {
  padding: 12px 16px;
  border-radius: var(--radius);
  background: var(--warning-light);
  border: 1px solid var(--warning);
  color: #b45309;
  margin-bottom: 16px;
  font-size: 14px;
}

.badge.secondary {
  background: #f1f5f9;
  color: #475569;
  border: 1px solid #cbd5e1;
}

.btn.active,
.cat-btn.active {
  background: var(--primary) !important;
  color: #ffffff !important;
  border-color: var(--primary) !important;
  font-weight: 700;
}

.report-tab-pane {
  display: none;
}
.report-tab-pane.active {
  display: block;
}

.modal-box.modal-lg {
  max-width: 850px;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 24px;
  border-bottom: 1px solid var(--border);
  background: #f8fafc;
}

.modal-header h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}

.modal-close {
  background: transparent;
  border: 0;
  color: #64748b;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 8px;
  transition: all 0.15s;
}

.modal-close:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.modal-body {
  padding: 22px 24px;
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  padding: 14px 24px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  background: #f8fafc;
}

@keyframes modalFadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes modalSlideUp {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Top Navbar Header Styling (Enterprise 5.0) */
.top-header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.top-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  color: #334155;
  border: 1px solid #e2e8f0;
  padding: 6px 14px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 600;
  cursor: default;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.top-pill-btn:hover {
  border-color: #cbd5e1;
  background: #f8fafc;
}

.top-user-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #ffffff;
  color: #1e293b;
  border: 1px solid #e2e8f0;
  padding: 5px 14px 5px 7px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 700;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.top-user-avatar {
  width: 28px;
  height: 28px;
  border-radius: 7px;
  background: #334155;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.top-bell-btn {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  padding: 0;
}

.top-bell-btn:hover {
  background: #f8fafc;
  color: #2563eb;
  border-color: #93c5fd;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.12);
}

.top-bell-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  border-radius: 9px;
  background: #ef4444;
  color: #ffffff;
  font-size: 10.5px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #ffffff;
  box-shadow: 0 2px 5px rgba(239, 68, 68, 0.35);
  animation: bellPulse 2s infinite;
}

@keyframes bellPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.1); box-shadow: 0 0 8px rgba(239, 68, 68, 0.6); }
  100% { transform: scale(1); }
}

.top-logout-btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  color: #ef4444;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  padding: 0;
}

.top-logout-btn:hover {
  background: #fef2f2;
  border-color: #fca5a5;
  color: #dc2626;
  transform: translateY(-1px);
}

/* Notification Dropdown Drawer */
.notification-menu {
  display: none;
  position: absolute;
  left: 0;
  top: 48px;
  width: 350px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.08);
  z-index: 1000;
  overflow: hidden;
  animation: notifSlideDown 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes notifSlideDown {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

.notif-menu-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 18px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
}

.notif-menu-header strong {
  font-size: 13.5px;
  font-weight: 700;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 8px;
}

.notif-menu-body {
  max-height: 320px;
  overflow-y: auto;
  padding: 6px 0;
}

.notif-menu-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  text-decoration: none !important;
  color: inherit;
  transition: background 0.15s ease;
  border-bottom: 1px solid #f8fafc;
}

.notif-menu-item:hover {
  background: #f1f5f9;
}

.notif-icon-circle {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 17px;
  flex-shrink: 0;
  margin-top: 2px;
}

.notif-icon-warning { background: #fef3c7; color: #b45309; }
.notif-icon-danger { background: #fee2e2; color: #dc2626; }
.notif-icon-info { background: #e0e7ff; color: #4338ca; }
.notif-icon-success { background: #dcfce7; color: #15803d; }

.notif-item-title {
  font-weight: 700;
  font-size: 13px;
  color: #0f172a;
  margin-bottom: 2px;
}

.notif-item-desc {
  font-size: 11.5px;
  color: #64748b;
  line-height: 1.45;
}

.notif-menu-empty {
  text-align: center;
  padding: 30px 16px;
  color: #64748b;
}

.notif-menu-footer {
  padding: 10px 16px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  text-align: center;
}

.notif-menu-footer a {
  font-size: 12px;
  font-weight: 600;
  color: #2563eb;
  text-decoration: none;
}

.notif-menu-footer a:hover {
  text-decoration: underline;
}

/* User Profile Dropdown Menu */
.user-menu-dropdown {
  display: none;
  position: absolute;
  left: 0;
  top: 44px;
  width: 230px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.08);
  z-index: 1000;
  overflow: hidden;
  animation: notifSlideDown 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.user-menu-header {
  padding: 14px 16px;
  border-bottom: 1px solid #f1f5f9;
  text-align: right;
}

.user-menu-name {
  font-weight: 800;
  font-size: 14px;
  color: #0f172a;
  margin-bottom: 3px;
}

.user-menu-email {
  font-size: 12px;
  color: #64748b;
  word-break: break-all;
}

.user-menu-list {
  padding: 6px 0;
}

.user-menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px;
  color: #334155;
  font-size: 13.5px;
  font-weight: 600;
  text-decoration: none !important;
  cursor: pointer;
  transition: all 0.15s ease;
  border: none;
  background: transparent;
  width: 100%;
  box-sizing: border-box;
  text-align: right;
}

.user-menu-item:hover {
  background: #f8fafc;
  color: #0f172a;
}

.user-menu-item svg {
  color: #64748b;
  flex-shrink: 0;
}

.user-menu-item:hover svg {
  color: #0f172a;
}

.user-menu-item.logout {
  color: #dc2626;
  border-top: 1px solid #f1f5f9;
  margin-top: 4px;
}

.user-menu-item.logout svg {
  color: #dc2626;
}

.user-menu-item.logout:hover {
  background: #fef2f2;
  color: #b91c1c;
}

/* ==================== MODERN DASHBOARD & TOPBAR SHORTCUTS ==================== */
.top-quick-add-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 6px 14px;
  cursor: pointer;
  font-weight: 700;
  font-size: 13.5px;
  color: #1e293b;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  transition: all 0.2s ease;
  font-family: inherit;
}

.top-quick-add-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

.quick-add-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 200px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.08);
  padding: 6px 0;
  display: none;
  z-index: 1000;
}

.quick-add-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  color: #1e293b;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: background 0.15s ease;
}

.quick-add-menu-item:hover {
  background: #f8fafc;
  color: #0f172a;
}

.quick-add-menu-item svg {
  color: #10b981;
  flex-shrink: 0;
}

.top-view-search-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 6px 14px;
  cursor: pointer;
  font-weight: 700;
  font-size: 13px;
  color: #1e293b;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  transition: all 0.2s ease;
  font-family: inherit;
}

.top-view-search-btn:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}

.top-breadcrumb-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 700;
  color: #475569;
}

/* Template Notice Banner */
.template-notice-card {
  background: #f0f7ff;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  padding: 12px 18px;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.template-notice-card .notice-icon-box {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #dbeafe;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #2563eb;
  flex-shrink: 0;
}

.template-notice-card .notice-close {
  background: transparent;
  border: none;
  font-size: 16px;
  color: #64748b;
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
}

.template-notice-card .notice-close:hover {
  color: #0f172a;
  background: #dbeafe;
}

/* Month Section Header */
.dashboard-section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.dashboard-section-header h2 {
  font-size: 19px;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
}

.dashboard-refresh-time {
  font-size: 12.5px;
  color: #64748b;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
}

.dashboard-refresh-time:hover {
  color: #2563eb;
}

/* Top 3 KPI Hero Cards */
.dashboard-hero-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}

.hero-metric-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
  transition: all 0.2s ease;
}

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

.hero-metric-label {
  font-size: 14px;
  color: #64748b;
  font-weight: 700;
  margin-bottom: 6px;
}

.hero-metric-val {
  font-size: 26px;
  font-weight: 800;
  color: #312e81;
  line-height: 1.2;
}

.hero-badge-pill {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.hero-badge-pill.up {
  background: #dcfce7;
  color: #16a34a;
}

.hero-badge-pill.down {
  background: #fee2e2;
  color: #dc2626;
}

/* Quick Action Shortcuts (Row of 6) */
.quick-shortcuts-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
  margin-bottom: 24px;
}

.shortcut-box {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 18px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.02);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.shortcut-box:hover {
  transform: translateY(-3px);
  border-color: #cbd5e1;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.06);
}

.shortcut-icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
  border: 1.5px solid currentColor;
  transition: all 0.2s ease;
}

.shortcut-box:hover .shortcut-icon-circle {
  transform: scale(1.05);
}

.shortcut-title {
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  text-align: center;
  line-height: 1.3;
}

/* Live Feed Widgets (3 Columns) */
.live-feed-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.live-feed-card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
}

.live-feed-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid #f1f5f9;
  margin-bottom: 4px;
}

.live-feed-title {
  font-size: 14.5px;
  font-weight: 800;
  color: #0f172a;
}

.live-badge-dot {
  background: #ecfdf5;
  color: #059669;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.live-feed-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 6px;
  border-bottom: 1px solid #f1f5f9;
  text-decoration: none;
  color: inherit;
  transition: background 0.15s ease;
  border-radius: 6px;
}

.live-feed-row:last-child {
  border-bottom: none;
}

.live-feed-row:hover {
  background: #f8fafc;
}

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

.live-row-primary {
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.live-row-secondary {
  font-size: 11.5px;
  color: #64748b;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.live-row-metric {
  font-size: 13.5px;
  font-weight: 800;
  color: #10b981;
  white-space: nowrap;
  flex-shrink: 0;
}

.live-row-metric.danger {
  color: #ef4444;
}

/* Low Stock Products Panel */
.low-stock-panel {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 18px 20px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
  margin-bottom: 24px;
}

.low-stock-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 12px;
  border-bottom: 1px solid #f1f5f9;
  margin-bottom: 6px;
}

.low-stock-header h3 {
  font-size: 15px;
  font-weight: 800;
  color: #0f172a;
  margin: 0;
}

.low-stock-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 6px;
  border-bottom: 1px solid #f1f5f9;
}

.low-stock-row:last-child {
  border-bottom: none;
}

.low-stock-qty {
  font-size: 13px;
  font-weight: 800;
  color: #ef4444;
  white-space: nowrap;
}

/* Responsive queries */
@media (max-width: 1024px) {
  .quick-shortcuts-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .dashboard-hero-cards {
    grid-template-columns: 1fr;
  }
  .live-feed-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .quick-shortcuts-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
